-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
406 lines (366 loc) · 22.7 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
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" media="(prefers-color-scheme: light)" content="#ddddee" />
<meta name="theme-color" media="(prefers-color-scheme: dark)" content="#111122" />
<meta
name="description"
content="Tool to view and convert Hindi/Thai text"
/>
<link rel="apple-touch-icon" href="logo192.png" />
<link rel="manifest" href="manifest.json" />
<title>Pokémon GO Hindi/Thai Text Tool</title>
<link rel="stylesheet" href="style.css">
<script src="script.js"></script>
</head>
<body id="main" class="mode-system" lang="en">
<header>
<h1><i>Pokémon GO</i> Hindi/​Thai Text Tool</h1>
<form class="colorscheme-container" onSubmit="return false">
<label for="colorscheme">Colorscheme:</label>
<select id="colorscheme" name="colorscheme">
<option value="system">System</option>
<option value="light">Light</option>
<option value="dark">Dark</option>
</select>
</form>
</header>
<form id="input-container" class="input-container" onSubmit="return false">
<label for="text-normal">How your text displays on your device:</label>
<div class="textarea-container">
<textarea id="text-normal" class="font-regular" rows="2" maxlength="" placeholder="Enter your text here..."></textarea>
<div id="text-normal-hidden" class="font-regular textarea-hidden"></div>
</div>
<label for="text-adjusted">How your text displays in <i>Pokémon GO</i>:</label>
<div class="textarea-container">
<div id="text-adjusted-canvas-container"><canvas id="text-adjusted-canvas" width="1070" height="106"></canvas></div>
<textarea id="text-adjusted" class="font-adjusted" rows="2" maxlength="" placeholder="Enter your text here..."></textarea>
<div id="text-adjusted-hidden" class="font-adjusted textarea-hidden"></div>
</div>
<div class="toolbar">
<div class="select-group">
<div class="select-container">
<label for="quality">Quality:</label>
<select id="quality" name="quality">
<option value="0.25">Lowest (¼×)</option>
<option value="0.5">Lower (½×)</option>
<option value="0.75">Low (¾×)</option>
<option value="1">Normal (1×)</option>
<option value="2">High (2×)</option>
<option value="3">Higher (3×)</option>
<option value="4">Highest (4×)</option>
</select>
</div>
<div class="select-container">
<label for="size">Size:</label>
<select id="size" name="size">
<option value="75">75%</option>
<option value="100">100%</option>
<option value="125">125%</option>
<option value="150">150%</option>
<option value="200">200%</option>
<option value="250">250%</option>
<option value="300">300%</option>
</select>
</div>
<div>
<button type="button" id="download">Download</button>
<a id="downloadLink" href="#" download></a>
</div>
</div>
<fieldset class="button-group">
<legend>Keyboard:</legend>
<div>
<input type="radio" id="keyboard-select-hindi" name="keyboard" value="hindi">
<label for="keyboard-select-hindi">Hindi</label>
</div>
<div>
<input type="radio" id="keyboard-select-thai" name="keyboard" value="thai">
<label for="keyboard-select-thai">Thai</label>
</div>
<div>
<input type="radio" id="keyboard-select-hide" name="keyboard" value="hide">
<label for="keyboard-select-hide">Hide</label>
</div>
</fieldset>
<!--
<fieldset class="button-group">
<legend>Mode:</legend>
<div>
<input type="radio" id="transform1" name="transform" value="encode">
<label for="transform1">Encode</label>
</div>
<div>
<input type="radio" id="transform2" name="transform" value="decode">
<label for="transform2">Decode</label>
</div>
<div>
<input type="radio" id="transform3" name="transform" value="identity">
<label for="transform3">Identity</label>
</div>
</fieldset>
-->
</div>
<div class="function-group">
<button type="button" id="encode">Encode</button>
<button type="button" id="decode">Decode</button>
<div>
<input type="checkbox" id="decode-zwnj" name="decode-zwnj">
<label for="decode-zwnj">Preserve explicit halant</label>
</div>
<div>
<input type="checkbox" id="decode-zwj" name="decode-zwj">
<label for="decode-zwj">Preserve half forms</label>
</div>
</div>
<div class="keyboard">
<div id="keyboard-hindi" lang="hi">
<!-- Consonants -->
<div class="keyboard-group">
<!-- Half forms (consonant + halant + ZWJ) -->
<button id="key-F33A" class="key" title="U+F33A"></button>
<button id="key-F33B" class="key" title="U+F33B"></button>
<button id="key-F33C" class="key" title="U+F33C"></button>
<button id="key-F33D" class="key" title="U+F33D"></button>
<button id="key-F33E" class="key" title="U+F33E"></button>
<!-- Full forms -->
<button id="key-F334" class="key" title="U+F334"></button>
<!-- Half forms (consonant + halant + ZWJ) -->
<button id="key-F33F" class="key" title="U+F33F"></button>
<button id="key-F340" class="key" title="U+F340"></button>
<button id="key-F343" class="key" title="U+F343"></button>
<!-- Stacked forms -->
<button id="key-F5A2" class="key" title="U+F5A2"></button>
<button id="key-F61F" class="key" title="U+F61F">◌</button>
<button id="key-F5A3" class="key" title="U+F5A3"></button>
<button id="key-F625" class="key" title="U+F625">◌</button>
<button id="key-F5A4" class="key" title="U+F5A4"></button>
<button id="key-F62B" class="key" title="U+F62B">◌</button>
<button id="key-F5A5" class="key" title="U+F5A5"></button>
<button id="key-F633" class="key" title="U+F633">◌</button>
<!-- Half forms (consonant + halant + ZWJ) -->
<button id="key-F344" class="key" title="U+F344"></button>
<button id="key-F346" class="key" title="U+F346"></button>
<button id="key-F347" class="key" title="U+F347"></button>
<button id="key-F348" class="key" title="U+F348"></button>
<button id="key-F34A" class="key" title="U+F34A"></button>
<button id="key-F34B" class="key" title="U+F34B"></button>
<button id="key-F34C" class="key" title="U+F34C"></button>
<button id="key-F390" class="key" title="U+F390"></button>
<button id="key-F34D" class="key" title="U+F34D"></button>
<button id="key-F34E" class="key" title="U+F34E"></button>
<button id="key-F350" class="key" title="U+F350"></button>
<button id="key-F351" class="key" title="U+F351"></button>
<!-- Reph -->
<button id="key-F306" class="key" title="U+F306">◌</button>
<button id="key-F000" class="key" title="U+F000">◌</button>
<button id="key-F001" class="key" title="U+F001">◌</button>
<button id="key-F002" class="key" title="U+F002">◌</button>
<button id="key-F003" class="key" title="U+F003">◌</button>
<button id="key-F004" class="key" title="U+F004">◌</button>
<button id="key-F005" class="key" title="U+F005">◌</button>
<button id="key-F006" class="key" title="U+F006">◌</button>
<button id="key-F007" class="key" title="U+F007">◌</button>
<!-- Below-base forms -->
<button id="key-F1B0" class="key" title="U+F1B0">◌</button>
<!-- Half forms (consonant + halant + ZWJ) -->
<button id="key-F352" class="key" title="U+F352"></button>
<button id="key-F353" class="key" title="U+F353"></button>
<button id="key-F355" class="key" title="U+F355"></button>
<button id="key-F356" class="key" title="U+F356"></button>
<button id="key-F357" class="key" title="U+F357"></button>
<button id="key-F35A" class="key" title="U+F35A"></button>
<button id="key-F35B" class="key" title="U+F35B"></button>
<button id="key-F35C" class="key" title="U+F35C"></button>
</div>
<!-- Conjuncts/ligatures -->
<div class="keyboard-group">
<!-- Conjuncts -->
<button id="key-F337" class="key" title="U+F337"></button>
<button id="key-F339" class="key" title="U+F339"></button>
<button id="key-F363" class="key" title="U+F363"></button>
<button id="key-F364" class="key" title="U+F364"></button>
<button id="key-F365" class="key" title="U+F365"></button>
<button id="key-F366" class="key" title="U+F366"></button>
<button id="key-F367" class="key" title="U+F367"></button>
<button id="key-F368" class="key" title="U+F368"></button>
<button id="key-F369" class="key" title="U+F369"></button>
<button id="key-F36B" class="key" title="U+F36B"></button>
<button id="key-F36C" class="key" title="U+F36C"></button>
<button id="key-F36E" class="key" title="U+F36E"></button>
<button id="key-F36F" class="key" title="U+F36F"></button>
<button id="key-F370" class="key" title="U+F370"></button>
<button id="key-F371" class="key" title="U+F371"></button>
<button id="key-F373" class="key" title="U+F373"></button>
<button id="key-F374" class="key" title="U+F374"></button>
<button id="key-F375" class="key" title="U+F375"></button>
<button id="key-F376" class="key" title="U+F376"></button>
<button id="key-F377" class="key" title="U+F377"></button>
<button id="key-F379" class="key" title="U+F379"></button>
<button id="key-F37A" class="key" title="U+F37A"></button>
<button id="key-F37B" class="key" title="U+F37B"></button>
<button id="key-F37C" class="key" title="U+F37C"></button>
<button id="key-F37D" class="key" title="U+F37D"></button>
<button id="key-F37E" class="key" title="U+F37E"></button>
<button id="key-F37F" class="key" title="U+F37F"></button>
<button id="key-F380" class="key" title="U+F380"></button>
<button id="key-F389" class="key" title="U+F389"></button>
<button id="key-F3D1" class="key" title="U+F3D1"></button>
<button id="key-F3E3" class="key" title="U+F3E3"></button>
<button id="key-F3E4" class="key" title="U+F3E4"></button>
<button id="key-F449" class="key" title="U+F449"></button>
<button id="key-F45A" class="key" title="U+F45A"></button>
<button id="key-F46A" class="key" title="U+F46A"></button>
<button id="key-F493" class="key" title="U+F493"></button>
<button id="key-F4F5" class="key" title="U+F4F5"></button>
<!-- Syllable ligature -->
<button id="key-F01A" class="key" title="U+F01A"></button>
<button id="key-F388" class="key" title="U+F388"></button>
<button id="key-F555" class="key" title="U+F555"></button>
<button id="key-F564" class="key" title="U+F564"></button>
<button id="key-F565" class="key" title="U+F565"></button>
</div>
<!-- Vowel marks/diacritics -->
<div class="keyboard-group">
<!-- Vowel marks -->
<button id="key-F30C" class="key" title="U+F30C"><span class="pl">◌</span></button>
<button id="key-F30D" class="key" title="U+F30D"><span class="pl">◌</span></button>
<button id="key-F30E" class="key" title="U+F30E"><span class="pl">◌</span></button>
<button id="key-F30F" class="key" title="U+F30F"><span class="pl">◌</span></button>
<button id="key-F310" class="key" title="U+F310"><span class="pl">◌</span></button>
<button id="key-F311" class="key" title="U+F311"><span class="pl">◌</span></button>
<button id="key-093F" class="key" title="U+093F">ि◌</button>
<button id="key-F312" class="key" title="U+F312"><span class="pl">◌</span></button>
<button id="key-F313" class="key" title="U+F313"><span class="pl">◌</span></button>
<button id="key-F314" class="key" title="U+F314"><span class="pl">◌</span></button>
<button id="key-F315" class="key" title="U+F315"><span class="pl">◌</span></button>
<button id="key-F316" class="key" title="U+F316"><span class="pl">◌</span></button>
<button id="key-F317" class="key" title="U+F317"><span class="plq">◌</span></button>
<button id="key-F318" class="key" title="U+F318"><span class="plq">◌</span></button>
<button id="key-F319" class="key" title="U+F319"><span class="plq">◌</span></button>
<button id="key-F31A" class="key" title="U+F31A"><span class="plq">◌</span></button>
<button id="key-F31B" class="key" title="U+F31B"><span class="plq">◌</span></button>
<button id="key-F31C" class="key" title="U+F31C"><span class="plh">◌</span></button>
<button id="key-F31D" class="key" title="U+F31D"><span class="plh">◌</span></button>
<button id="key-F31E" class="key" title="U+F31E"><span class="plh">◌</span></button>
<button id="key-F31F" class="key" title="U+F31F"><span class="plh">◌</span></button>
<button id="key-F320" class="key" title="U+F320"><span class="plh">◌</span></button>
<button id="key-0940" class="key" title="U+0940">◌‌ी</button>
<button id="key-F321" class="key" title="U+F321">◌</button>
<button id="key-F322" class="key" title="U+F322">◌</button>
<button id="key-F323" class="key" title="U+F323">◌</button>
<button id="key-F324" class="key" title="U+F324">◌</button>
<button id="key-F325" class="key" title="U+F325">◌</button>
<button id="key-F326" class="key" title="U+F326">◌</button>
<button id="key-F327" class="key" title="U+F327">◌</button>
<button id="key-F328" class="key" title="U+F328">◌</button>
<button id="key-F329" class="key" title="U+F329">◌</button>
<button id="key-F32A" class="key" title="U+F32A">◌</button>
<button id="key-F32B" class="key" title="U+F32B">◌</button>
<button id="key-F32C" class="key" title="U+F32C">◌</button>
<button id="key-0941" class="key" title="U+0941">◌‌ु</button>
<button id="key-F018" class="key" title="U+F018">◌</button>
<button id="key-0942" class="key" title="U+0942">◌‌ू</button>
<button id="key-F019" class="key" title="U+F019">◌</button>
<button id="key-0947" class="key" title="U+0947">◌‌े</button>
<button id="key-F008" class="key" title="U+F008">◌</button>
<button id="key-F009" class="key" title="U+F009">◌</button>
<button id="key-F00A" class="key" title="U+F00A">◌</button>
<button id="key-F00B" class="key" title="U+F00B">◌</button>
<button id="key-F00C" class="key" title="U+F00C">◌</button>
<button id="key-F00D" class="key" title="U+F00D">◌</button>
<button id="key-F00E" class="key" title="U+F00E">◌</button>
<button id="key-F00F" class="key" title="U+F00F">◌</button>
<button id="key-F387" class="key" title="U+F387">◌</button>
<button id="key-0948" class="key" title="U+0948">◌‌ै</button>
<button id="key-F010" class="key" title="U+F010">◌</button>
<button id="key-F011" class="key" title="U+F011">◌</button>
<button id="key-F012" class="key" title="U+F012">◌</button>
<button id="key-F013" class="key" title="U+F013">◌</button>
<button id="key-F014" class="key" title="U+F014">◌</button>
<button id="key-F015" class="key" title="U+F015">◌</button>
<button id="key-F016" class="key" title="U+F016">◌</button>
<button id="key-F017" class="key" title="U+F017">◌</button>
<!-- Diacritics -->
<button id="key-0901" class="key" title="U+0901">◌‌ँ</button>
<button id="key-F300" class="key" title="U+F300">◌</button>
<!-- Anusvara -->
<button id="key-0902" class="key" title="U+0902">◌‌ं</button>
<button id="key-F01B" class="key" title="U+F01B">◌</button>
</div>
</div>
<div id="keyboard-thai" lang="th">
<!-- Consonants -->
<div class="keyboard-group">
<button id="key-0E10" class="key" title="U+0E10">ฐ</button>
<button id="key-F700" class="key" title="U+F700"></button>
<button id="key-0E0D" class="key" title="U+0E0D">ญ</button>
<button id="key-F70F" class="key" title="U+F70F"></button>
</div>
<!-- Vowels -->
<div class="keyboard-group">
<button id="key-0E34" class="key" title="U+0E34">◌‌ิ</button>
<button id="key-F701" class="key" title="U+F701">◌</button>
<button id="key-0E35" class="key" title="U+0E35">◌‌ี</button>
<button id="key-F702" class="key" title="U+F702">◌</button>
<button id="key-0E36" class="key" title="U+0E36">◌‌ึ</button>
<button id="key-F703" class="key" title="U+F703">◌</button>
<button id="key-0E37" class="key" title="U+0E37">◌‌ื</button>
<button id="key-F704" class="key" title="U+F704">◌</button>
<button id="key-0E31" class="key" title="U+0E31">◌‌ั</button>
<button id="key-F710" class="key" title="U+F710">◌</button>
<button id="key-0E4D" class="key" title="U+0E4D">◌‌ํ</button>
<button id="key-F711" class="key" title="U+F711">◌</button>
<button id="key-0E47" class="key" title="U+0E47">◌‌็</button>
<button id="key-F712" class="key" title="U+F712">◌</button>
<button id="key-0E38" class="key" title="U+0E38">◌‌ุ</button>
<button id="key-F718" class="key" title="U+F718">◌</button>
<button id="key-0E39" class="key" title="U+0E39">◌‌ู</button>
<button id="key-F719" class="key" title="U+F719">◌</button>
<button id="key-0E3A" class="key" title="U+0E3A">◌‌ฺ</button>
<button id="key-F71A" class="key" title="U+F71A">◌</button>
</div>
<!-- Tone marks -->
<div class="keyboard-group">
<button id="key-F705" class="key" title="U+F705">◌</button>
<button id="key-F70A" class="key" title="U+F70A">◌</button>
<button id="key-0E48" class="key" title="U+0E48">◌‌่</button>
<button id="key-F706" class="key" title="U+F706">◌</button>
<button id="key-F70B" class="key" title="U+F70B">◌</button>
<button id="key-0E49" class="key" title="U+0E49">◌‌้</button>
<button id="key-F707" class="key" title="U+F707">◌</button>
<button id="key-F70C" class="key" title="U+F70C">◌</button>
<button id="key-0E4A" class="key" title="U+0E4A">◌‌๊</button>
<button id="key-F708" class="key" title="U+F708">◌</button>
<button id="key-F70D" class="key" title="U+F70D">◌</button>
<button id="key-0E4B" class="key" title="U+0E4B">◌‌๋</button>
<button id="key-F709" class="key" title="U+F709">◌</button>
<button id="key-F70E" class="key" title="U+F70E">◌</button>
<button id="key-0E4C" class="key" title="U+0E4C">◌‌์</button>
</div>
</div>
</div>
</form>
<h2>What is this tool?</h2>
<p>
This is a tool that allows you to preview how Hindi and Thai text will appear in <i><a href="https://pokemongolive.com/" rel="external">Pokémon GO</a></i>.
While your phone, computer, and web browser most likely support the complex text layout needed to display Brahmic scripts like Devanagari and Thai correctly, <i>Pokémon GO</i> does not.
Instead, the game uses modified fonts and encodings that allows the game's text engine to display the correct forms of characters.
</p>
<p>
To convert your text into the format used by <i>Pokémon GO</i>, tap the "Encode" button. (Hindi encoding is currently unavailable.)
To convert text from <i>Pokémon GO</i> into a readable format, tap the "Decode" button.
</p>
<h2>Additional resources</h2>
<p>
<ul>
<li><a href="https://en.wikipedia.org/wiki/Complex_text_layout" rel="external">"Complex text layout" on Wikipedia</a></li>
<li><a href="https://learn.microsoft.com/en-us/typography/script-development/devanagari" rel="external">"Developing OpenType Fonts for Devanagari Script" on Microsoft Typography</a></li>
</ul>
</p>
<footer>Created by abcboy | <a href="https://github.com/abcboy101/pogo-brahmic/issues">Report an issue</a> | <a id="contact-link" href="https://bulbapedia.bulbagarden.net/wiki/Special:EmailUser/Abcboy">Contact me</a> | <a href="https://github.com/abcboy101/pogo-brahmic">GitHub</a></footer>
</body>
</html>