-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcalendrical-demo-en.html
547 lines (542 loc) · 20.2 KB
/
calendrical-demo-en.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
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Custom calendars and extended date display</title>
<!-- Version M2024-07-01 See GitHub for details
-->
<meta name="creator" content="Louis-Aimé de Fouquières">
<meta name="description" content="Custom calendars and extended date display">
<meta name="keywords" content="Unicode, calendars, javascript">
<meta name="viewport" content="width=device-width">
<!-- page environment -->
<link href="dialsandpanels.css" rel="stylesheet"/>
<script type="application/javascript" src="calendrical-init.js"></script>
<script type="application/javascript" src="calendrical-demo.js"></script>
<style>
.panel {height: 460px;}
</style>
</head>
<body class="centered">
<section class="centered"><h1 class="panelhead">Custom calendars and extended date display</h1></section>
<div>
<section class="panel"><h2 class="panelhead">Date, time, mode</h2>
<section class="centered"><!-- setting date -->
<table class="centered">
<tr>
<th><button id="customCalend" class="textline">Calendar</button></th>
<th>Year</th>
<th>Month</th>
<th>Day</th>
<th> </th>
</tr>
<form name="custom">
<tr>
<td><select name="calend" size="1" class="centered">
<option value="iso_8601" selected>ISO 8601</option>
<option value="milesian" >Milesian</option>
<option value="julian">Julian</option>
<option value="gregorian" selected>Gregorian</option>
<option value="frenchrev">French republic</option>
<option value="persian33">Persian 33</option>
</select></td>
<td><input name="year" type="number" value="1752" class="centered digit4"> </td>
<td><input name="monthname" type="number" value="9" min="1" max="13" class="centered digit2"></td>
<td><input name="day" type="number" value="2" min="1" max="31" class="centered digit2"> </td>
<td><button class="textline">Ok</button></td>
</form>
</tr>
</table>
<table class="centered">
<tr>
<form name="week">
<th>Weeks</th><td><input name="weekyear" type="number" class="centered digit4"></td>
<td><input name="weeknumber" type="number" min="0" max="56" class="centered digit2"></td>
<td><input name="weekday" type="number" min="0" max="30" class="centered digit2"> </td>
<td><button class="textline">Ok</button></td>
</tr>
<tr>
<td>Week day</td>
<td><input name="dayofweek" type="text" class="centered" size="12" disabled="disabled" /></td>
<td colspan="2">Weeks in year</td>
<td><input name="weeksinyear" type="number" min="0" max="56" class="centered digit2" disabled="disabled"></td>
</tr>
</form>
</table>
</section>
<section class="centered"><!-- date navigation -->
<form name="control">
<table class="centered">
<tr>
<td><button name="now" class="textline" type="button">Now</button></td>
<th>+/- days : </th>
<td><button name="minus" type="button" class="textline symbol">-</button></td>
<td><input name="shift" type="number" value="1" min="0" step="any" class="centered digit4"></td>
<td><button name="plus" type="button" class="textline symbol">+</button></td>
</tr>
</table>
</form>
</section>
<section><h4 class="panelhead">Gregorian calendar: switchover to new style</h4>
<table class="centered">
<form name="gregorianswitch">
<tr>
<th>Year</th>
<th>Month</th>
<th>Day</th>
<th> </th>
</tr>
<tr>
<td><input name="year" type="number" value="1752" min="1582" max="275760" class="centered digit4"></td>
<td>
<select name="month" size="1" class="centered">
<option value="1">January</option>
<option value="2">February</option>
<option value="3">March</option>
<option value="4">April</option>
<option value="5">May</option>
<option value="6">June</option>
<option value="7">July</option>
<option value="8">August</option>
<option value="9" selected>September</option>
<option value="10">October</option>
<option value="11">November</option>
<option value="12">December</option>
</select> </td>
<td><input name="day" type="number" value="14" min="1" max="31" class="centered digit2"></td>
<td><button class="textline">Ok</button></td>
</tr>
</form>
</table>
</section>
<section class="centered"><h3 class="panelhead">Time and time zone mode (local / UTC)</h3>
<form name="time">
<table class="centered">
<tr>
<td><input name="hours" type="number" value="0" min="0" max="23" class="centered digit2">h</td>
<td><input name="mins" type="number" value="0" min="0" max="59" class="centered digit2">min</td>
<td><input name="secs" type="number" value="0" min="0" max="59" class="centered digit2">s</td>
<td><input name="ms" type="number" value="0" min="0" max="999" class="centered digit4">ms</td>
<td><button class="textline">Ok</button></td>
</tr>
</table>
</form>
</section>
<section class="centered"><!-- time navigation -->
<form name="timeShift">
<table class="centered">
<tr>
<td>+/- ms</td>
<td><button name="minus" type="button" class="textline symbol">-</button></td>
<td><input name="shift" type="number" value="60000" min="1" class="centered char8"></td>
<td><button name="plus" type="button" class="textline symbol">+</button></td>
</tr>
</table>
</form>
</section>
<section class="centered"><!-- time zone option -->
<form name="TZmode">
<table class="centered">
<tr><th>Mode : </th>
<td>
<select name="TZcontrol" size="1" class="centered">
<option value="UTC">UTC</option>
<option value="" selected>System time zone</option>
</select></td>
<td><button class="textline">Ok</button></td>
</tr>
</table>
<table class="centered">
<tr>
<th>Real offset (UTC-local) : </th>
<td id="realTZOffset"></td>
</tr><tr>
<th>TZOffset result : </th>
<td><span id="sysTZoffset"></span> min</td>
</tr>
</table>
</form>
</section>
<section class="centered"><!-- setting preselected time -->
<table class="centered">
<tr>
<th>Same date at</th>
<td><button id="h0" class="textline" type="button">0 h</button></td>
<td><button id="h12" class="textline" type="button">12 h</button></td>
<th>UTC</th>
</tr>
</table>
</section>
</section>
<section class="panel centered autoscroll"><h2 class="panelhead">General options</h2>
<form name="Locale">
<section class="centered">
<table class="centered">
<tr>
<td><button type="reset" class="textline">No option</button></td>
<td><button class="textline" >Ok</button></td> <td></td>
</tr>
</table>
</section>
<section class="centered"><h3 class="panelhead">Options resolution</h3>
<table class="centered">
<tr><th>Locale</th><th>Options</th></tr>
<tr>
<td><select name="LocaleMatcher" class="centered" size="1">
<option value="" selected>Default</option>
<option value="lookup">Lookup BCP</option>
<option value="best fit">Best fit</option>
</select></td>
<td><select name="FormatMatcher" class="centered" size="1">
<option value="" selected>Default</option>
<option value="basic">Basic choice</option>
<option value="best fit">Best fit</option>
</select></td>
</tr>
</table>
<table class="centered">
<tr>
<th>Locale : </th>
<td><input name="Locale" autocomplete="language" type="text" class="centered" size="30"> </td>
</tr>
<tr>
<th>Extension : </th>
<td><input name="UnicodeExt" type="text" class="centered" size="30"></td>
</tr>
<tr>
<td>Resolved : </td><td colspan="3"><input name="Elocale" type="text" disabled="disabled" class="centered" size="30"></td>
</tr>
<tr>
<tr>
<td>Numb. syst. : </td>
<td><input name="Enum" type="text" disabled="disabled" class="centered"></td>
</tr>
<th>Calendar : </th>
<td>
<select name="Calendar" size="1" class="centered">
<option value="">Default</option>
<option value="buddhist">buddhist</option>
<option value="chinese">chinese (luni-solar)</option>
<option value="coptic">coptic</option>
<option value="dangi">dangi (Korea)</option>
<option value="ethioaa">ethiopian Amete Alem (5493 BC) </option>
<option value="ethiopic">ethiopian Amete Mihret (8 AD)</option>
<option value="gregory">gregorian (proleptic)</option>
<option value="hebrew">hebrew</option>
<option value="indian">indian (1957)</option>
<option value="islamic">islamic standard</option>
<option value="islamic-umalqura">islamic Umm al-Qura</option>
<option value="islamic-tbla">islamic astronomical</option>
<option value="islamic-civil">islamic civil</option>
<option value="islamic-rgsa">islamic of Saudi Arabia</option>
<option value="iso8601">ISO 8601</option>
<option value="japanese">japanese</option>
<option value="persian">persian</option>
<option value="roc">people's republic of China</option>
</select>
</td>
</tr>
<tr>
<td>Resolved : </td>
<td><input name="Ecalend" type="text" disabled="disabled" class="centered"></td>
</tr>
<tr><th>Time zone : </th>
<td><input name="TimeZone" type="text" autocomplete="country" class="centered" size="30"> </td>
</tr>
<tr><td>Resolved TZ : </td><td><input name="EtimeZone" type="text" disabled="disabled" class="centered" size="30"></td></tr>
</table>
</section>
<section class="centered"><h3 class="panelhead">Style options</h3>
<table class="centered">
<tr>
<th></th><th>Date style</th><th>Time style</th>
</tr>
<tr>
<th>Ask.</th>
<td><select name="DateStyle" class="centered" size="1">
<option value="" selected>default</option>
<option value="short">short</option>
<option value="medium">medium</option>
<option value="long">long</option>
<option value="full">full</option>
</select></td>
<td><select name="TimeStyle" class="centered" size="1">
<option value="" selected>default</option>
<option value="short">short</option>
<option value="medium">medium</option>
<option value="long">long</option>
<option value="full">full</option>
</select></td>
</tr>
<tr>
<th>Resolved</th>
<td><input class="centered char8" name="EdateStyle" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="EtimeStyle" type="text" disabled="disabled"></td>
</tr>
</table>
</section>
</form>
</section>
<section class="panel centered autoscroll"><h2 class="panelhead">Field options : date</h2>
<form name="dateOptions">
<section>
<table class="centered">
<tr>
<td><button class="textline" type="reset">Iinitial options</button></td>
<td><button class="textline" >Ok</button></td> <td></td>
</tr>
</table>
</section>
<section><h3 class="panelhead">Experimental options</h3>
<table class="centered">
<tr>
<th>Era display</th>
<td><select name="eraDisplay" class="centered" size="1">
<option value="" selected>default</option>
<option value="never">never</option>
<option value="always">always</option>
<option value="auto">auto</option>
</select></td>
</tr>
</table>
</section>
<section class="centered"><h3 class="panelhead">Standard date options</h3>
<table class="centered">
<tr>
<th></th><th>Day</th><th>Month</th><th>Year</th>
</tr>
<tr>
<th>Ask.</th>
<td><select name="Day" class="centered" size="1">
<option value="">default</option>
<option value="numeric" selected>numeric</option>
<option value="2-digit">2-digit</option>
</select></td>
<td><select name="Month" class="centered" size="1">
<option value="">default</option>
<option value="numeric">numeric</option>
<option value="2-digit">2-digit</option>
<option value="narrow">narrow</option>
<option value="short">short</option>
<option value="long" selected>long</option>
</select></td>
<td><select name="Year" class="centered" size="1">
<option value="">default</option>
<option value="numeric" selected>numeric</option>
<option value="2-digit">2-digit</option>
</select></td>
</tr>
<tr>
<th>Intl</th>
<td><input class="centered char8" name="Eday" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Emonth" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Eyear" type="text" disabled="disabled"></td>
</tr>
<tr>
<th>Ext.</th>
<td><input class="centered char8" name="Xday" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Xmonth" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Xyear" type="text" disabled="disabled"></td>
</tr>
</table>
<table class="centered">
<tr>
<th></th><th>Day of week</th><th>Era</th>
</tr>
<tr>
<th>Ask.</th>
<td><select name="Weekday" class="centered" size="1">
<option value="">default</option>
<option value="narrow">narrow</option>
<option value="short">short</option>
<option value="long" selected>long</option>
</select></td>
<td><select name="Era" class="centered" size="1">
<option value="" selected>default</option>
<option value="narrow">narrow</option>
<option value="short">short</option>
<option value="long">long</option>
</select></td>
</tr>
<tr>
<th>Intl</th>
<td><input class="centered char8" name="Eweekday" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Eera" type="text" disabled="disabled"></td>
</tr>
<tr>
<th>Ext.</th>
<td><input class="centered char8" name="Xweekday" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Xera" type="text" disabled="disabled"></td>
</tr>
</table>
</section>
</form>
</section>
<section class="panel centered autoscroll"><h2 class="panelhead">Field options : time</h2>
<form name="timeOptions">
<table class="centered">
<tr>
<td><button class="textline" type="reset">No option</button></td>
<td><button class="textline" >Ok</button></td> <td></td>
</tr>
</table>
<table class="centered">
<tr>
<th></th><th>Hour</th><th>Minute</th><th>Second</th>
</tr>
<tr>
<th>Ask.</th>
<td><select name="Hour" class="centered" size="1">
<option value="">default</option>
<option value="numeric" selected>numeric</option>
<option value="2-digit">2-digit</option>
</select></td>
<td><select name="Minute" class="centered" size="1">
<option value="">default</option>
<option value="numeric" selected>numeric</option>
<option value="2-digit">2-digit</option>
</select></td>
<td><select name="Second" class="centered" size="1">
<option value="" selected>default</option>
<option value="numeric">numeric</option>
<option value="2-digit">2-digit</option>
</select></td>
</tr>
<tr>
<th>Intl</th>
<td><input class="centered char8" name="Ehour" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Eminute" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Esecond" type="text" disabled="disabled"></td>
</tr>
<tr>
<th>Ext.</th>
<td><input class="centered char8" name="Xhour" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Xminute" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="Xsecond" type="text" disabled="disabled"></td>
</tr>
</table>
<table class="centered">
<tr>
<th></th><th>Fract. secs.</th><th>Time zone</th><th>am/pm</th>
</tr>
<tr>
<th>Ask.</th>
<td><input class="centered digit2" name="Msdigits" type="number" min="0" max="3"></td>
<td><select name="TimeZoneName" class="centered" size="1">
<option value="" selected>default</option>
<option value="short">short</option>
<option value="long">long</option>
</select></td>
<td><select name="AmPm" size="1" class="centered">
<option value="" selected>default</option>
<option value="narrow">narrow</option>
<option value="short">short</option>
<option value="long">long</option>
</select></td>
</tr>
<tr>
<th>Intl</th>
<td><input class="centered digit2" name="Emsdigits" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="EtimeZoneName" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="EAmPm" type="text" disabled="disabled"></td>
</tr>
<tr>
<th>Ext.</th>
<td><input class="centered digit2" name="Xmsdigits" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="XtimeZoneName" type="text" disabled="disabled"></td>
<td><input class="centered char8" name="XAmPm" type="text" disabled="disabled"></td>
</tr>
</table>
<table class="centered">
<tr>
<th></th><th colspan="2">12 h</th><th>Hour cycle</th>
</tr>
<tr>
<th>Ask.</th>
<td colspan="2"><select name="Hour12" size="1" class="centered">
<option value="" selected>default</option>
<option value="true">12 h</option>
<option value="false">24 h</option>
</select></td>
<td><select name="HourCycle" size="1" class="centered">
<option value="" selected>default</option>
<option value="h11">h11</option>
<option value="h12">h12</option>
<option value="h23">h23</option>
<option value="h24">h24</option>
</select></td>
</tr>
<tr>
<th>Intl</th>
<td>12 h</td>
<td><input class="centered" name="Ehour12" type="checkbox" disabled="disabled"></td>
<td><input class="centered char8" name="EhourCycle" type="text" disabled="disabled"></td>
</tr>
<tr>
<th>Ext.</th>
<td>12 h</td>
<td><input class="centered" name="Xhour12" type="checkbox" disabled="disabled"></td>
<td><input class="centered char8" name="XhourCycle" type="text" disabled="disabled"></td>
</tr>
</table>
</form>
</section>
</div>
<section><h2 class="panelhead">Display</h2></section>
<div class="centered autoscroll">
<section class="outdisplay"><h3 class="panelhead">Unicode calendar</h3>
<table class="centered">
<tr><th>Calendar:</th><td id="Calendname"></td></tr>
</table>
<h4 class="panelhead">Standard display (Intl)</h4>
<table class="centered">
<tr><td id="Ustring"></td></tr>
</table>
<h4 class="panelhead">Extended display</h4>
<table class="centered">
<tr><td id="Xstring"></td></tr>
</table>
</section>
<section class="outdisplay"><h3 class="panelhead">Custom calendar</h3>
<table class="centered">
<tr><th>Calendar:</th><td id="Customname"></td></tr>
</table>
<table class="centered"><form name="yeartype">
<tr><th colspan="2">Full year & year type</th></tr>
<tr><td id="fullyear"></td><td>
<select name="leapyear" disabled class="centered" size="1">
<option value="false">common</option>
<option value="true">leap</option>
</select></td>
</tr>
</form></table> <h4 class="panelhead">Extended display</h4>
<table class="centered">
<tr><td id="Cstring"></td></tr>
</table>
</section>
<section class="outdisplay"><h3 class="panelhead">Date strings</h3>
<table class="centered">
<tr><th colspan="2">Standard strings</th></tr>
<tr>
<th>ISO 8601 :</th>
<td id="ISOdatetime"></td>
</tr>
<tr>
<th>calendar :</th>
<td id="dateString"></td>
</tr>
<tr>
<th>Timestamp :</th>
<td id="Posixnumber"></td>
</tr>
</table>
</section>
</div>
<footer class="centered">
<p>References :
<a target="_blank" href="http://www.iana.org/assignments/language-subtag-registry/language-subtag-registry">Language subtag registry</a>,
<a target="_blank" href="http://twiki.org/cgi-bin/xtra/tzdatepick.html">Time zone names</a>
<br>© 2017-2024 <a href="http://www.calendriermilesien.org">www.calendriermilesien.org</a></p>
</footer>
</body>
</html>