-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
250 lines (231 loc) · 7.48 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PrettyCover - Create beautiful cover images for your blogs</title>
<meta
name="description"
content=" Create beautiful cover images for your blogs"
/>
<link rel="canonical" href="https://ridhikgovind.github.io/PrettyCover/">
<link rel="icon" href="icons/prettyCover-32.png">
<meta itemprop="name" content="PrettyCover">
<meta itemprop="description" content="Create beautiful cover images for your blogs">
<meta itemprop="image" content="icons/prettyCover-64.png">
<meta name="theme-color" content="fffff">
<!-- twitter -->
<meta name="twitter:card" content="summary">
<meta name="twitter:site" content="@fluffyRidz">
<meta name="twitter:creator" content="@fluffyRidz">
<meta name="twitter:url" content="https://ridhikgovind.github.io/PrettyCover/">
<meta name="twitter:title" content="PrettyCover">
<meta name="twitter:description" content="Create beautiful cover images for your blogs">
<meta name="twitter:image" content="icons/prettyCover-64">
<!-- Google font links -->
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Raleway:ital,wght@0,700;1,700&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Comfortaa:wght@700&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@1,700&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Bangers&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Jost:wght@600&display=swap"
rel="stylesheet"
/>
<link rel="stylesheet" href="index.css" />
<script src="https://html2canvas.hertzen.com/dist/html2canvas.min.js"></script>
<script src="https://unpkg.com/vanilla-picker"></script>
</head>
<body>
<main role="main" class="container">
<header>
<h1 class="app-title">PrettyCover.</h1>
<div>
<a href="https://github.com/RidhikGovind" target="_blank">
<img
src="icons/github-logo.png"
class="github-logo"
alt="github-logo"
/>
</a>
</div>
</header>
<section class="workspace">
<div class="editor">
<div id="editBoard">
<div
id="text"
class="text"
contenteditable="true"
aria-placeholder="Text goes here"
>
Text goes here
</div>
</div>
</div>
<div class="controls">
<div class="actions">
<div class="action-buttons" onclick="shuffleColors()">
<img src="icons/shuffle.svg" alt="" />
</div>
<div class="action-buttons" onclick="shuffleFonts()">
<span class="fontNameDisplay"></span>
<img src="icons/font.svg" alt="" />
</div>
<div class="action-buttons" onclick="download()">
<img src="icons/direct-download.svg" alt="" />
</div>
</div>
<div class="flex">
<h3>Background Color</h3>
<div id="background" class="color"></div>
</div>
<div class="flex">
<h3>Foreground Color</h3>
<div id="foreground" class="color"></div>
</div>
<div class="flex">
<h3>Border Color</h3>
<div id="border" class="color"></div>
</div>
<div class="flex">
<h3>Border Width</h3>
<input
type="number"
id="borderWidth"
value="0"
min="0"
max="50"
oninput="borderWidth(this)"
/>
</div>
<div class="flex">
<h3>Font size</h3>
<input
type="number"
id="fontsize"
value="40"
min="20"
max="200"
oninput="fontSize(this)"
/>
</div>
<div class="flex">
<h3>Height ratio</h3>
<input
id="heightRatio"
type="number"
value="50"
min="40"
max="100"
step="5"
oninput="heightRatio(this)"
/>
</div>
<div class="flex">
<h3>Text shadow</h3>
</div>
<div class="flex">
X<input
id="shadowX"
type="number"
value="0"
oninput="shadowX(this)"
/>
Y<input
id="shadowY"
type="number"
value="0"
oninput="shadowY(this)"
/>
Blur<input
id="shadowBlur"
type="number"
value="0"
min="0"
oninput="shadowBlur(this)"
/>
<div id="shadow" class="color"></div>
</div>
<div class="flex">
<h3>text alignment</h3>
</div>
<div style="margin: 10px">
<div class="table">
<div class="rows">
<div
class="tab"
onclick="textAlign(this, 'left', 'flex-start')"
>
⇖
</div>
<div
class="tab"
onclick="textAlign(this, 'center', 'flex-start')"
>
⇑
</div>
<div
class="tab"
onclick="textAlign(this, 'right', 'flex-start')"
>
⇗
</div>
<div class="tab" onclick="textAlign(this, 'left', 'center')">
⟸
</div>
<div
class="tab current"
onclick="textAlign(this, 'center', 'center')"
>
⚬
</div>
<div class="tab" onclick="textAlign(this, 'right', 'center')">
⇒
</div>
<div class="tab" onclick="textAlign(this, 'left', 'flex-end')">
⇙
</div>
<div
class="tab"
onclick="textAlign(this, 'center', 'flex-end')"
>
⇓
</div>
<div class="tab" onclick="textAlign(this, 'right', 'flex-end')">
⇘
</div>
</div>
</div>
</div>
<div class="flex">
<h3>background image</h3>
</div>
<div class="flex">
<span id="resetbg" class="resetbg" onclick="resetbg()">
reset
</span>
<input type="file" id="uploadImg" name="bg-image-upload" />
</div>
</div>
</section>
</main>
<script src="index.js"></script>
</body>
</html>