-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
388 lines (358 loc) · 17.2 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
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>QR Code</title>
<link rel="stylesheet" href="./assets/style.css" />
<link rel="icon" href="./assets/faviconD.svg" media="(prefers-color-scheme:dark)" />
<link rel="icon" href="./assets/faviconL.svg" media="(prefers-color-scheme:light)" />
</head>
<body>
<!-- UPLOADED IMG -->
<img id="pic" class="hide" src="">
<!-- CHOOSE TYPE -->
<ul id="type">
<li>
<input type="radio" name="type" id="URL" class="qr-type" checked></input>
<label class="which clickable" tabindex="0" for="URL">URL</label>
</li>
<li>
<input type="radio" name="type" id="TEXTAREA" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="TEXTAREA">Text</label>
</li>
<li>
<input type="radio" name="type" id="VCD" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="VCD">Vcard</label>
</li>
<li>
<input type="radio" name="type" id="EVENT" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="EVENT">Event</label>
</li>
<li>
<input type="radio" name="type" id="WIFI" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="WIFI">WiFi</label>
</li>
<li>
<input type="radio" name="type" id="Email" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="Email">Email</label>
</li>
<li>
<input type="radio" name="type" id="SMS" class="qr-type"></input>
<label class="which clickable" tabindex="0" for="SMS">SMS</label>
</li>
</ul>
<!-- MAIN SCREEN -->
<main class="flex column">
<!-- DATA ENTRY MODALS -->
<article id="qr-type-wrap">
<div id="modal-URL" class="modal">
<input type="url" id="content" placeholder="Enter URL and click ☑" class="hvr sq">
</div>
<div id="modal-TEXTAREA" class="modal hide">
<textarea id="content-textarea" class="hvr sq" rows="5" cols="60" width="400px"
placeholder="Enter text to encode"></textarea>
</div>
<div id="modal-VCD" class="modal hide">
<table>
<tr>
<td><input type="text" id="fullName" placeholder="Name" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="company" placeholder="Company" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="title" placeholder="Title" class="img-light"></td>
</tr>
<tr>
<td><input type="tel" id="phone" placeholder="Phone" class="img-light"></td>
</tr>
<tr>
<td><input type="email" id="email" placeholder="Email" class="img-light"></td>
</tr>
<tr>
<td><input type="url" id="vc_url" placeholder="Website" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="notes" placeholder="Notes" class="img-light"></td>
</tr>
</table>
</div>
<div id="modal-EVENT" class="modal hide">
<table>
<tr>
<td colspan="2"><input type="text" id="summary" placeholder="title of event"></td>
</tr>
<tr>
<td colspan="2"><input type="text" id="description" placeholder="description of event"></td>
</tr>
<tr>
<td colspan="2"><input type="text" id="location" placeholder="location of event"></td>
</tr>
<tr>
<td><input type="date" id="datestart" aria-label="date start"></td>
<td><input type="time" step="60" id="timestart" aria-label="time start"></td>
</tr>
<tr>
<td><input type="date" id="dateend" aria-label="date end"></td>
<td><input type="time" step="60" id="timeend" aria-label="time end"></td>
</tr>
</table>
</div>
<div id="modal-WIFI" class="modal hide">
<table>
<tr>
<td><input type="text" id="ssid" placeholder="network name | SSID" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="password" placeholder="password" class="img-light"></td>
</tr>
<tr>
<td>
<select id="encryption" title="encryption" aria-label="encryption">
<option value="WPA" selected>WPA</option>
<option value="WPA2">WPA2</option>
<option value="WEP">WEP</option>
<option value="NONE">none</option>
</select>
<span class="lbl">encryption</span>
</td>
</tr>
<tr>
<td>
<select id="hidden" title="hidden" aria-label="hidden">
<option value="1">true</option>
<option value="0" selected>false</option>
</select>
<span class="lbl">hidden</span>
</td>
</tr>
</table>
</div>
<div id="modal-Email" class="modal hide">
<table>
<tr>
<td>Not all email clients will populate the subject and body</td>
</tr>
<tr>
<td><input type="email" id="mailTo" placeholder="Email Address" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="mailSubj" placeholder="Subject (optional)" class="img-light"></td>
</tr>
<tr>
<td><input type="text" id="mailMsg" placeholder="Message (optional)" class="img-light"></td>
</tr>
</table>
</div>
<div id="modal-SMS" class="modal hide">
<table>
<tr>
<td><input type="tel" id="sendTo" placeholder="Send to number (optional)" class="img-light">
</td>
</tr>
<tr>
<td><input type="text" id="sendMsg" placeholder="Message (optional)" class="img-light"></td>
</tr>
</table>
</div>
</article>
<!-- QR CODE WRAPPER -->
<article id="qr_main_wrap" class="flex">
<div id="data" class="flex row constructor-clear clickable">
<svg id="palette" tabindex="0" class="clickable" tabindex="0" viewBox="0 0 512 512">
<path
d="M204.3 5.017C104.9 24.42 24.8 104.4 5.171 203.5c-36.1 187 131.7 326.4 258.8 306.7c41.19-6.406 61.41-54.61 42.5-91.7c-23.09-45.41 9.897-98.4 60.9-98.4h79.7c35.81 0 64.8-29.59 64.9-65.31C511.5 97.13 368.1-26.89 204.3 5.017zM96 320c-17.69 0-32-14.31-32-32c0-17.69 14.31-32.03 31.1-32.03s32 14.31 32 31.1C127.1 305.7 113.7 320 96 320zM128 192c-17.69 0-32-14.31-32-32s14.31-32 32-32s32 14.31 32 32S145.7 192 128 192zM256 128c-17.69 0-32-14.31-32-32S238.3 64.04 256 64.04s32 14.31 32 32S273.7 128 256 128zM384 192c-17.69 0-32-14.31-32-32s14.31-32 32-32s32 14.31 32 32S401.7 192 384 192z" />
</svg>
<svg tabindex="0" viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg">
<path
d="M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256s256-114.6 256-256S397.4 0 256 0zM371.8 211.8l-128 128C238.3 345.3 231.2 348 224 348s-14.34-2.719-19.81-8.188l-64-64c-10.91-10.94-10.91-28.69 0-39.63c10.94-10.94 28.69-10.94 39.63 0L224 280.4l108.2-108.2c10.94-10.94 28.69-10.94 39.63 0C382.7 183.1 382.7 200.9 371.8 211.8z" />
</svg>
</div>
<div id="modal-QRC">
<div id="canvas" alt="QR code frame"></div>
</div>
</article>
<!-- DOWNLOAD TYPES -->
<article id="extension" title="file type" class="flex">
<ul class="flex" style="margin:0">
<li>
<input type="radio" name="ext" id="png" checked />
<label class="which clickable" tabindex="0" for="png">PNG</label>
</li>
<li>
<input type="radio" name="ext" id="jpeg" />
<label class="which clickable" tabindex="0" for="jpeg">JPEG</label>
</li>
<li>
<input type="radio" name="ext" id="webp" />
<label class="which clickable" tabindex="0" for="webp">WEBP</label>
</li>
<li>
<input type="radio" name="ext" id="svg" />
<label class="which clickable" tabindex="0" for="svg">SVG</label>
</li>
<li>
<input type="radio" name="ext" id="gif" />
<label class="which clickable" tabindex="0" for="gif">GIF</label>
</li>
<li>
<input type="radio" name="ext" id="eps" />
<label class="which clickable" tabindex="0" for="eps">EPS</label>
</li>
<li>
<div id="download" class="clickable" tabindex="0">
<svg viewBox="0 0 96 96" style="width:35px;height:35px;margin:20px;cursor:pointer;fill:#4ff1f7;transform:scale(.8)">
<g>
<path
d="M90,54a5.9966,5.9966,0,0,0-6,6V78H12V60A6,6,0,0,0,0,60V84a5.9966,5.9966,0,0,0,6,6H90a5.9966,5.9966,0,0,0,6-6V60A5.9966,5.9966,0,0,0,90,54Z" />
<path
d="M43.7578,64.2422a5.9979,5.9979,0,0,0,8.4844,0l18-18a5.9994,5.9994,0,0,0-8.4844-8.4844L54,45.5156V12a6,6,0,0,0-12,0V45.5156l-7.7578-7.7578a5.9994,5.9994,0,0,0-8.4844,8.4844Z" />
</g>
</svg>
</div>
</li>
</ul>
</article>
<!-- SETTINGS -->
<article id="settings" class="flex hide">
<table>
<tr>
<td>
<div>
<input id="isBGtransparent" type="checkbox" class="clickable">
<label for="isBGtransparent" class="lbl">transparent background</label>
</div>
</td>
</tr>
<tr>
<td>
<input type="text" id="picUrl" placeholder="image location (url)">
<span class="lbl">image on the web</span>
</td>
</tr>
<tr>
<td>
<input type="file" id="picUp">
<span class="lbl">upload image</span>
</td>
</tr>
<tr>
<td>
<button id="picUploadReset">reset uploaded image</button>
</td>
</tr>
<tr>
<td>
<input title="size" type="text" id="imgSize" value="1">
<span class="lbl">image scale > 0.1</span>
</td>
</tr>
<tr>
<td>
<input title="inner margin" type="text" id="imgMargin" value="0">
<span class="lbl">image margin</span>
</td>
</tr>
<tr>
<td>
<input title="outer margin" type="text" id="qrMargin" value="0">
<span class="lbl">qr margin</span>
</td>
</tr>
<tr>
<td><input title="qr type number" type="text" id="typeNumber" value="0">
<span class="lbl">qr type (auto by default)</span>
</td>
</tr>
<tr>
<td>
<select id="backgroundData" title="hide background data" aria-label="hide background data">
<option value="1" selected>true</option>
<option value="0">false</option>
</select>
<span class="lbl">hide data behind image</span>
</td>
</tr>
<tr>
<td>
<select id="errorCorrection" title="error correction" aria-label="error correction">
<option value="H">30% high</option>
<option value="Q">25% quartile</option>
<option value="M" selected>15% medium</option>
<option value="L">7% low</option>
</select>
<span class="lbl">error correction</span>
</td>
</tr>
<tr>
<td>
<select id="dataChoices" title="data appearance" aria-label="data appearance">
<option value="square">square</option>
<option value="rounded">rounded</option>
<option value="dots" selected>circle</option>
<option value="extra-rounded">xtra-rounded</option>
</select>
<span class="lbl">data appearance</span>
</td>
</tr>
<tr>
<td>
<select id="cornerChoices" title="dot borders" aria-label="dot borders">
<option value="square">square</option>
<option value="dot" selected>circle</option>
<option value="extra-rounded">rounded</option>
</select>
<span class="lbl">corner border</span>
</td>
</tr>
<tr>
<td>
<select id="dotChoices" title="corner dots" aria-label="corner dots">
<option value="square">square</option>
<option value="dot" selected>round</option>
</select>
<span class="lbl">corner dot</span>
</td>
</tr>
<tr>
<td>
<input title="code length and width in pixels" type="text" id="QRdimensions" value="288">
<span class="lbl">dimension in px (288 px = 3 in)</span>
</td>
</tr>
<tr>
<td>
<input title="bg color" type="color" id="background" value="#ffffff"
aria-label="background color">
<span class="lbl clickable">background</span>
</td>
</tr>
<tr>
<td>
<input title="data color" type="color" id="dataColor" value="#000000" aria-label="data color">
<span class="lbl clickable">data</span>
</td>
</tr>
<tr>
<td>
<input title="corner border color" type="color" id="cornerColor" value="#000000"
aria-label="corner border color">
<span class="lbl clickable">corner border</span>
</td>
</tr>
<tr>
<td>
<input title="corner dot color" type="color" id="dotColor" value="#000000"
aria-label="corner dot color">
<span class="lbl clickable">corner dots</span>
</td>
</tr>
</table>
</article>
</main>
</body>
<script src="./assets/style.js"></script>
<script src="./assets/script.js"></script>
</html>