@diagrammo/dgmo 0.50.1 → 0.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/advanced.d.ts +6640 -0
- package/dist/advanced.js +207 -161
- package/dist/{analyzer-UYKBXAKR.js → analyzer-BJ54GIFB.js} +3 -3
- package/dist/auto.css +31 -8
- package/dist/auto.d.ts +60 -0
- package/dist/auto.js +169 -133
- package/dist/auto.mjs +2245 -1030
- package/dist/block.css +28 -8
- package/dist/block.d.ts +130 -0
- package/dist/block.js +103 -68
- package/dist/{charts-d3-LR6D3D7A.js → charts-d3-7E4B4IMW.js} +9 -9
- package/dist/{chunk-6IAA2QQ2.js → chunk-2EQMXBBQ.js} +2 -2
- package/dist/{chunk-XJLKLU4D.js → chunk-2ILHQOL3.js} +3 -3
- package/dist/{chunk-SXRTRMEE.js → chunk-2UJSV2VT.js} +3 -3
- package/dist/{chunk-LE4MYMLI.js → chunk-32XPAAET.js} +5 -5
- package/dist/{chunk-NU3XLTGP.js → chunk-332ZR4QU.js} +4 -4
- package/dist/{chunk-F7BFXWNQ.js → chunk-3JLKYGBQ.js} +2 -2
- package/dist/{chunk-QROYX7TT.js → chunk-3LV2NCB6.js} +3 -3
- package/dist/{chunk-ZAD4HV2G.js → chunk-3ODS2VGL.js} +99 -99
- package/dist/{chunk-3XGZF2QJ.js → chunk-3YSQZ75W.js} +6 -6
- package/dist/{chunk-FJUNPCYI.js → chunk-467TVMQL.js} +2 -2
- package/dist/{chunk-HHXOONLX.js → chunk-4B5YISOR.js} +38 -1
- package/dist/{chunk-6HJBFVLO.js → chunk-4QZ43D7I.js} +3 -3
- package/dist/{chunk-4S52SK6G.js → chunk-4VWJ4LW2.js} +15 -8
- package/dist/chunk-4XFBQT5O.js +35 -0
- package/dist/{chunk-2C56LEML.js → chunk-5F5ELR3V.js} +3 -3
- package/dist/{chunk-EAMEADTV.js → chunk-5PDTIBLV.js} +83 -21
- package/dist/{chunk-C2CVAM3U.js → chunk-5PZT4DQG.js} +160 -87
- package/dist/{chunk-IAEC4KLA.js → chunk-5QKQSSPO.js} +2 -2
- package/dist/{chunk-5OWVC2A6.js → chunk-5SVOCD5W.js} +6 -6
- package/dist/{chunk-VBYSIOOY.js → chunk-5WPNFSXP.js} +3 -3
- package/dist/{chunk-4MJ7M6YL.js → chunk-5X6YQA2J.js} +7 -7
- package/dist/{chunk-JJUOHGX2.js → chunk-65WJYYKJ.js} +4 -4
- package/dist/{chunk-3UIKSPFB.js → chunk-6BQFET7X.js} +3 -3
- package/dist/{chunk-U2HGPLZS.js → chunk-6H7O2OPM.js} +14 -1
- package/dist/{chunk-DZXYF2F5.js → chunk-6K2M4VSR.js} +3 -3
- package/dist/{chunk-PGEGPSCZ.js → chunk-6MNGECP2.js} +2 -2
- package/dist/{chunk-3XPUDB7B.js → chunk-6NFYEQDX.js} +266 -38
- package/dist/{chunk-4XK3FLFB.js → chunk-6NYWYNBI.js} +3 -3
- package/dist/{chunk-TWQUYVP3.js → chunk-7DF4J4RL.js} +4 -4
- package/dist/{chunk-H73FP42Q.js → chunk-7DYOELRK.js} +3 -3
- package/dist/{chunk-L3UHP6TD.js → chunk-7L4UJOY6.js} +1 -2
- package/dist/{chunk-QJP6PG7F.js → chunk-AB7INMR5.js} +9 -9
- package/dist/{chunk-3LKM6FMW.js → chunk-AE7II3E3.js} +2 -2
- package/dist/{chunk-BTUTZMPT.js → chunk-AFIEPDLX.js} +97 -42
- package/dist/chunk-APKUAJ2L.js +220 -0
- package/dist/{chunk-X6EZPSW6.js → chunk-AXW3M6OQ.js} +7 -7
- package/dist/{chunk-66RUL3XF.js → chunk-B63YB7X3.js} +5 -5
- package/dist/{chunk-DSWVNQVS.js → chunk-BGP54HVR.js} +4 -59
- package/dist/{chunk-3NODSS6A.js → chunk-BYJBIALT.js} +7 -7
- package/dist/{chunk-3YPY3OXD.js → chunk-CC4YRBWV.js} +2 -2
- package/dist/{chunk-HLJVEAOF.js → chunk-DY7XLRHK.js} +8 -33
- package/dist/{chunk-OMNGQPEZ.js → chunk-E7Y3SYKW.js} +3 -3
- package/dist/{chunk-HTMN2Z6U.js → chunk-EDA6C7MV.js} +50 -7
- package/dist/{chunk-7L3R6I3U.js → chunk-ENRS56GC.js} +3 -3
- package/dist/{chunk-2KGXHFYK.js → chunk-EXOQP75F.js} +7 -7
- package/dist/{chunk-BBGDM4NQ.js → chunk-F3FYUFUH.js} +26 -8
- package/dist/{chunk-GL5UZ6NY.js → chunk-FC5I2KXV.js} +3 -3
- package/dist/{chunk-VVW3F3MD.js → chunk-FTBZV6NE.js} +9 -9
- package/dist/{chunk-7QKLIMRZ.js → chunk-G3PF3S7P.js} +41 -46
- package/dist/{chunk-J6K7RP6P.js → chunk-GD6L76WD.js} +3 -3
- package/dist/{chunk-I2WKW7C7.js → chunk-GGHRAITI.js} +3 -3
- package/dist/{chunk-YIA4LEX4.js → chunk-GNSFLJAA.js} +96 -4
- package/dist/{chunk-IUMPEA64.js → chunk-GROLTAWZ.js} +4 -4
- package/dist/{chunk-Q4V4XQWV.js → chunk-GTWKD3QT.js} +2 -2
- package/dist/{chunk-F2L5GCQ4.js → chunk-GU46PPT3.js} +3 -3
- package/dist/{chunk-6IUAK7RZ.js → chunk-H6PI3KJT.js} +2 -2
- package/dist/{chunk-SCQ5VPUF.js → chunk-HFMYN6N2.js} +2 -2
- package/dist/{chunk-GKC3HILQ.js → chunk-I2QZFCS2.js} +27 -4
- package/dist/{chunk-MCZ5LBZD.js → chunk-IE477RQZ.js} +7 -7
- package/dist/{chunk-3Y2DRD7S.js → chunk-IEDMFNU7.js} +3 -3
- package/dist/{chunk-M5RXSRO2.js → chunk-IEWG6J7C.js} +4 -4
- package/dist/{chunk-P7CE7LXL.js → chunk-IUJODQKX.js} +6 -6
- package/dist/{chunk-NWED7CYO.js → chunk-IUO34HKW.js} +6 -6
- package/dist/{chunk-NX4EQS3U.js → chunk-J76PIKAT.js} +2 -2
- package/dist/{chunk-O7WP4ZD4.js → chunk-JED6ZDEE.js} +2 -2
- package/dist/{chunk-6BFZKBGD.js → chunk-JJXGQIRV.js} +2 -2
- package/dist/{chunk-O7NUCTFU.js → chunk-JM4LEPY3.js} +2 -2
- package/dist/{chunk-VDOOQZUD.js → chunk-JSSX2SX4.js} +4 -4
- package/dist/{chunk-SQLNBA64.js → chunk-KFNWFNAA.js} +3 -3
- package/dist/{chunk-VVZRV54S.js → chunk-KJGG2JKQ.js} +143 -82
- package/dist/{chunk-OTAL43EH.js → chunk-LV4BETUU.js} +8 -2
- package/dist/{chunk-VUJGMJE6.js → chunk-MVN25IF6.js} +4 -4
- package/dist/{chunk-CLD2OKV7.js → chunk-MX2EY5Y7.js} +2 -2
- package/dist/{chunk-Y4RNXEAO.js → chunk-ND76YJCN.js} +139 -25
- package/dist/{chunk-KFZYNWWO.js → chunk-NEQ6GJXB.js} +4 -4
- package/dist/{chunk-PFHVU7UA.js → chunk-NI3XQBPB.js} +2 -2
- package/dist/{chunk-WW32K72E.js → chunk-OJTXTQA2.js} +9 -9
- package/dist/{chunk-YNRDWYZP.js → chunk-OQKP2X3D.js} +170 -51
- package/dist/{chunk-AHGF2YYA.js → chunk-OTOHI4JO.js} +2 -2
- package/dist/{chunk-HEVYAHLW.js → chunk-OU7HLO7I.js} +4 -4
- package/dist/{chunk-GBE54KY6.js → chunk-OZPBJM5Q.js} +3 -3
- package/dist/{chunk-EOFPYPAU.js → chunk-P3NRSSUU.js} +51 -11
- package/dist/{chunk-TSA237IM.js → chunk-PZDBOK2Q.js} +2 -2
- package/dist/{chunk-3P2DKJCG.js → chunk-Q62FEYK3.js} +2 -2
- package/dist/{chunk-DFTFPYUD.js → chunk-QHI5XVUJ.js} +7 -7
- package/dist/{chunk-HQCHYB5F.js → chunk-QOOUC2J5.js} +2 -2
- package/dist/{chunk-XDXNDSKO.js → chunk-QZPEGJOM.js} +5 -2
- package/dist/{chunk-TN35C5KM.js → chunk-RAHVMKBG.js} +2 -2
- package/dist/chunk-RBDIYLA5.js +267 -0
- package/dist/{chunk-OTQKUHRS.js → chunk-RBHWPDBB.js} +3 -3
- package/dist/{chunk-BH3UYK36.js → chunk-RLFVAKEO.js} +3 -3
- package/dist/{chunk-3LH5CLP4.js → chunk-RXKTSFDL.js} +150 -5
- package/dist/{chunk-RZ6YKEUJ.js → chunk-TK2VQQX2.js} +6 -6
- package/dist/{chunk-I7F2A35O.js → chunk-TMACGPW5.js} +25 -47
- package/dist/{chunk-5GJYGP5Z.js → chunk-TRM2J7ZN.js} +8 -8
- package/dist/{chunk-BCYVE3N5.js → chunk-TYS6CSS5.js} +2 -2
- package/dist/{chunk-7PQYTZMA.js → chunk-U5SI5NIM.js} +95 -232
- package/dist/{chunk-KHEYDLMT.js → chunk-VB4UJ3H2.js} +2 -2
- package/dist/{chunk-HGN652MU.js → chunk-VL2O2F3W.js} +2 -2
- package/dist/{chunk-ONA5KPV3.js → chunk-VNSXLA6G.js} +4 -4
- package/dist/{chunk-CMCR5WBW.js → chunk-WBRZJOEC.js} +3 -3
- package/dist/{chunk-5LWQH6QV.js → chunk-WCT3NYCV.js} +1 -1
- package/dist/{chunk-T4VOVZT5.js → chunk-WJ7RW65H.js} +4 -4
- package/dist/{chunk-SCHXJTZL.js → chunk-WQLMU7VG.js} +2 -2
- package/dist/{chunk-C4GQDB5L.js → chunk-WRNFDFPU.js} +2 -2
- package/dist/{chunk-66NVRO4K.js → chunk-X7EC3L2H.js} +7 -7
- package/dist/{chunk-QXKWYZNR.js → chunk-XEQXCIBC.js} +3 -3
- package/dist/{chunk-C63UWAKM.js → chunk-Y2ZE3MSG.js} +2 -2
- package/dist/{chunk-FA6K3FWM.js → chunk-Y6GBQTBK.js} +6 -6
- package/dist/{chunk-7UEMZREK.js → chunk-YAA6IID3.js} +2 -2
- package/dist/{chunk-PZFVK3IH.js → chunk-YGJZWZTY.js} +2 -2
- package/dist/{chunk-7TV5Y53Y.js → chunk-ZJ3LS7DW.js} +3 -3
- package/dist/{chunk-PH5X4GIP.js → chunk-ZO27FGJS.js} +2 -2
- package/dist/cli.cjs +163 -147
- package/dist/clock.js +91 -5
- package/dist/countdown.js +208 -82
- package/dist/dgmo-router-Y2VEX46B.js +86 -0
- package/dist/dimensions-F7B5C4BJ.js +22 -0
- package/dist/editor.js +14 -1
- package/dist/element.d.ts +68 -0
- package/dist/element.js +170 -134
- package/dist/element.mjs +2209 -1015
- package/dist/{flowchart-parser-OE4WHLTF.js → flowchart-parser-MY53QWTZ.js} +4 -4
- package/dist/{flowchart-renderer-GPCSMTOR.js → flowchart-renderer-AQSMEMYF.js} +8 -8
- package/dist/highlight.js +14 -1
- package/dist/index.d.ts +185 -0
- package/dist/index.js +57 -53
- package/dist/{layout-7SKMFYHL.js → layout-46N4JJYK.js} +5 -5
- package/dist/layout-4DIUOX2T.js +14 -0
- package/dist/{layout-7H4H46CS.js → layout-7QXCNOVS.js} +3 -3
- package/dist/{layout-NXG63LWH.js → layout-AM2JWW3X.js} +4 -4
- package/dist/{layout-7MZ5NF2N.js → layout-CBCLPMSG.js} +5 -5
- package/dist/{layout-DC4TVXER.js → layout-EE6GE46Y.js} +5 -5
- package/dist/{layout-FGQWRYYW.js → layout-F4WO357A.js} +3 -3
- package/dist/layout-G23F7LDH.js +9 -0
- package/dist/{layout-QNUQLEHU.js → layout-HYZPWAK5.js} +3 -3
- package/dist/{layout-FWODLIMP.js → layout-JDJAEQ3P.js} +6 -6
- package/dist/layout-MUPRALE5.js +14 -0
- package/dist/{layout-34CLNICW.js → layout-OAC4PEAC.js} +5 -5
- package/dist/{layout-5BG6DFCU.js → layout-YVTNOTN4.js} +6 -6
- package/dist/{layout-PUQCB6AN.js → layout-ZDOSXL5G.js} +7 -7
- package/dist/{layout-search-QS44PI5R.js → layout-search-55FU6HD3.js} +6 -157
- package/dist/map-data/gazetteer.json +1 -1
- package/dist/{parser-36HVKU5U.js → parser-2Q2T4C3B.js} +6 -5
- package/dist/{parser-B5FVS7O6.js → parser-3A42DZ72.js} +3 -3
- package/dist/{parser-CSFUN3CT.js → parser-4RFTKAQX.js} +5 -4
- package/dist/{parser-IJBMRXMC.js → parser-57ILIFZ2.js} +5 -5
- package/dist/{parser-DFFEDKHH.js → parser-5A2UWU6B.js} +3 -3
- package/dist/{parser-H3XEPFPV.js → parser-5PDYJGWA.js} +4 -4
- package/dist/{parser-O4HIUN6G.js → parser-6BJEXUFX.js} +4 -4
- package/dist/{parser-MTOMTWTD.js → parser-6ZKABF5S.js} +6 -5
- package/dist/{parser-WAV5JRPT.js → parser-AIMHGJRR.js} +4 -4
- package/dist/{parser-TXND652E.js → parser-AZJ25OKK.js} +4 -4
- package/dist/{parser-4AI5ZN5F.js → parser-B77S5SZM.js} +3 -3
- package/dist/{parser-IBWNAPY4.js → parser-BEPSWJAD.js} +3 -3
- package/dist/{parser-D5VILGN2.js → parser-BKI42XBQ.js} +4 -4
- package/dist/{parser-LWKKBNSA.js → parser-C3D7MVXY.js} +3 -3
- package/dist/{parser-HYRTF3DO.js → parser-CDG7CHV5.js} +3 -3
- package/dist/{parser-CVMEDULU.js → parser-CZOJ7XQ6.js} +4 -4
- package/dist/{parser-AXKBDGNO.js → parser-E2RL6JYF.js} +5 -5
- package/dist/{parser-PSA4UBSP.js → parser-EH5VE7ZN.js} +4 -4
- package/dist/{parser-K3XXLMUW.js → parser-FQ6GZFMR.js} +4 -4
- package/dist/{parser-RV4M6AS2.js → parser-GKLZKEIK.js} +4 -4
- package/dist/{parser-MPCE5JBG.js → parser-H6ABKHZZ.js} +4 -4
- package/dist/{parser-RZPVAQVX.js → parser-I6GGFKOQ.js} +4 -3
- package/dist/{parser-W4PQUGX3.js → parser-JA7JQ7NF.js} +4 -4
- package/dist/{parser-5OXGPNBF.js → parser-KKTJ6M3Y.js} +5 -5
- package/dist/parser-OK22AC6Y.js +14 -0
- package/dist/{parser-4NO6VZ6S.js → parser-OK2ILHRT.js} +4 -4
- package/dist/{parser-YS7TOS2K.js → parser-OUTPNJWC.js} +3 -3
- package/dist/{parser-KCR2WS3V.js → parser-PORDUX5E.js} +4 -4
- package/dist/{parser-VKOJM7KS.js → parser-SRVFR7PM.js} +4 -4
- package/dist/{parser-TGQZJ5OT.js → parser-UKFFZCFJ.js} +4 -4
- package/dist/{parser-JJR52VAT.js → parser-UMWPLORP.js} +5 -5
- package/dist/{parser-AGVYTQXV.js → parser-Z4TZV2CB.js} +4 -4
- package/dist/{renderer-A5VE5BCI.js → renderer-2AUFT3E2.js} +8 -8
- package/dist/{renderer-FPE3J5VZ.js → renderer-2HTNBIF2.js} +11 -11
- package/dist/{renderer-R2WNIC2C.js → renderer-3K3IB7D5.js} +8 -8
- package/dist/{renderer-2AZ5HJFK.js → renderer-3YNIWF5I.js} +4 -4
- package/dist/{renderer-PJM35LJN.js → renderer-3YPZHMOU.js} +3 -3
- package/dist/{renderer-JCCHNECZ.js → renderer-4WR6WMVF.js} +9 -9
- package/dist/{renderer-HDCCZURL.js → renderer-66MERVQ2.js} +9 -9
- package/dist/{renderer-2QPMJ2DA.js → renderer-6RKQPNJI.js} +9 -9
- package/dist/{renderer-FYSVXL7M.js → renderer-ARMJBP6C.js} +11 -11
- package/dist/{renderer-6OKF44KS.js → renderer-CO2DW7S7.js} +13 -13
- package/dist/{renderer-BSR2O2H6.js → renderer-EDJ2O4S5.js} +13 -12
- package/dist/{renderer-CYB4LK3G.js → renderer-F7U3MFCV.js} +9 -9
- package/dist/{renderer-72LGR2YF.js → renderer-GD2COXVL.js} +4 -2
- package/dist/{renderer-B5TBNZJE.js → renderer-GQIESYEM.js} +8 -8
- package/dist/{renderer-ODUUOPVT.js → renderer-HCKJDFXD.js} +13 -13
- package/dist/{renderer-QAOBLRXV.js → renderer-HYGHO4SJ.js} +10 -10
- package/dist/{renderer-5DSEWF74.js → renderer-JC3RDUT7.js} +8 -8
- package/dist/{renderer-7RH2SI3B.js → renderer-KQB7UGDS.js} +3 -3
- package/dist/{renderer-45PSOL3E.js → renderer-NKJ24TEA.js} +5 -5
- package/dist/{renderer-AUW2BE6G.js → renderer-OYO67VZK.js} +9 -9
- package/dist/{renderer-DAXMXIKD.js → renderer-QIWVHWZO.js} +3 -3
- package/dist/{renderer-PSMMZCKH.js → renderer-QRWACQRI.js} +8 -8
- package/dist/{renderer-4ITCHBT7.js → renderer-QXGN5H3A.js} +5 -5
- package/dist/renderer-QXPP4TA2.js +27 -0
- package/dist/{renderer-KS7YZJE2.js → renderer-RGIYOTKJ.js} +10 -10
- package/dist/{renderer-FF24KZCI.js → renderer-RHT4MHFU.js} +8 -8
- package/dist/{renderer-PPIHO5FI.js → renderer-RYR3TJ46.js} +12 -11
- package/dist/{renderer-NGXZTRK6.js → renderer-SRKDNDFB.js} +8 -8
- package/dist/{renderer-SBS3YWU5.js → renderer-TGTUABCI.js} +8 -8
- package/dist/{renderer-7SD6MSBS.js → renderer-TXJFKPOG.js} +11 -11
- package/dist/{renderer-HVCU2C3Z.js → renderer-UV6MI64M.js} +3 -3
- package/dist/renderer-radial-FWABAZHB.js +21 -0
- package/dist/{resolver-FHBCO3PL.js → resolver-EMTGNR3D.js} +4 -3
- package/dist/{state-parser-3REXRK3R.js → state-parser-6T6CNMPX.js} +4 -4
- package/dist/{state-renderer-XYLNRWXR.js → state-renderer-AWZ3ECAX.js} +8 -8
- package/dist/themes-32xj5ZTW.d.ts +943 -0
- package/docs/language-reference.md +98 -10
- package/gallery/fixtures/clock.dgmo +3 -3
- package/gallery/fixtures/countdown-far.dgmo +2 -0
- package/gallery/fixtures/countdown-tz.dgmo +5 -0
- package/package.json +1 -1
- package/dist/dgmo-router-YTU3ENAX.js +0 -84
- package/dist/dimensions-OTBKC5M6.js +0 -22
- package/dist/layout-6RDJHS6E.js +0 -9
- package/dist/layout-J36454XU.js +0 -14
- package/dist/layout-LD6XTLD6.js +0 -14
- package/dist/parser-4WQQQXCG.js +0 -13
- package/dist/renderer-UYMQQCJK.js +0 -24
- package/dist/renderer-radial-F7X5F2VU.js +0 -21
|
@@ -1,6 +1,102 @@
|
|
|
1
1
|
// src/countdown/resolve.ts
|
|
2
2
|
var DAY_MS = 864e5;
|
|
3
3
|
var WEEK_MS = 7 * DAY_MS;
|
|
4
|
+
var ZONE_WD = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
|
|
5
|
+
function zoneFields(ms, tz) {
|
|
6
|
+
const d = new Date(ms);
|
|
7
|
+
if (!tz) {
|
|
8
|
+
return {
|
|
9
|
+
year: d.getFullYear(),
|
|
10
|
+
month: d.getMonth(),
|
|
11
|
+
day: d.getDate(),
|
|
12
|
+
hour: d.getHours(),
|
|
13
|
+
minute: d.getMinutes(),
|
|
14
|
+
second: d.getSeconds(),
|
|
15
|
+
weekday: d.getDay()
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
try {
|
|
19
|
+
const o = {};
|
|
20
|
+
new Intl.DateTimeFormat("en-US", {
|
|
21
|
+
timeZone: tz,
|
|
22
|
+
hour12: false,
|
|
23
|
+
year: "numeric",
|
|
24
|
+
month: "2-digit",
|
|
25
|
+
day: "2-digit",
|
|
26
|
+
hour: "2-digit",
|
|
27
|
+
minute: "2-digit",
|
|
28
|
+
second: "2-digit",
|
|
29
|
+
weekday: "short"
|
|
30
|
+
}).formatToParts(d).forEach((x) => {
|
|
31
|
+
o[x.type] = x.value;
|
|
32
|
+
});
|
|
33
|
+
return {
|
|
34
|
+
year: Number(o["year"]),
|
|
35
|
+
month: Number(o["month"]) - 1,
|
|
36
|
+
day: Number(o["day"]),
|
|
37
|
+
hour: Number(o["hour"]) % 24,
|
|
38
|
+
minute: Number(o["minute"]),
|
|
39
|
+
second: Number(o["second"]),
|
|
40
|
+
weekday: Math.max(0, ZONE_WD.indexOf(o["weekday"] ?? "Sun"))
|
|
41
|
+
};
|
|
42
|
+
} catch {
|
|
43
|
+
return {
|
|
44
|
+
year: d.getUTCFullYear(),
|
|
45
|
+
month: d.getUTCMonth(),
|
|
46
|
+
day: d.getUTCDate(),
|
|
47
|
+
hour: d.getUTCHours(),
|
|
48
|
+
minute: d.getUTCMinutes(),
|
|
49
|
+
second: d.getUTCSeconds(),
|
|
50
|
+
weekday: d.getUTCDay()
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
function zoneOffsetMs(tz, ms) {
|
|
55
|
+
const f = zoneFields(ms, tz);
|
|
56
|
+
const asUTC = Date.UTC(f.year, f.month, f.day, f.hour, f.minute, f.second);
|
|
57
|
+
return asUTC - Math.floor(ms / 1e3) * 1e3;
|
|
58
|
+
}
|
|
59
|
+
function wallToMs(y, mo, d, h, mi, tz) {
|
|
60
|
+
if (!tz) return new Date(y, mo, d, h, mi).getTime();
|
|
61
|
+
const guess = Date.UTC(y, mo, d, h, mi);
|
|
62
|
+
const off1 = zoneOffsetMs(tz, guess);
|
|
63
|
+
const ms = guess - off1;
|
|
64
|
+
const off2 = zoneOffsetMs(tz, ms);
|
|
65
|
+
return off2 === off1 ? ms : guess - off2;
|
|
66
|
+
}
|
|
67
|
+
function zoneOffsetLabel(ms, tz) {
|
|
68
|
+
if (!tz) return "";
|
|
69
|
+
try {
|
|
70
|
+
const off = new Intl.DateTimeFormat("en-US", {
|
|
71
|
+
timeZone: tz,
|
|
72
|
+
timeZoneName: "shortOffset"
|
|
73
|
+
}).formatToParts(new Date(ms)).find((x) => x.type === "timeZoneName");
|
|
74
|
+
return off ? off.value.replace("GMT", "UTC") : "";
|
|
75
|
+
} catch {
|
|
76
|
+
return "";
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
var DATE_ONLY_RE = /^\d{4}-\d{2}-\d{2}$/;
|
|
80
|
+
var LOCAL_DT_RE = /^(\d{4})-(\d{2})-(\d{2})[T ](\d{2}):(\d{2})(?::(\d{2}))?$/;
|
|
81
|
+
function targetToMs(target, tz = null) {
|
|
82
|
+
const s = target.trim();
|
|
83
|
+
if (DATE_ONLY_RE.test(s)) {
|
|
84
|
+
const [y, m, d] = s.split("-").map(Number);
|
|
85
|
+
return wallToMs(y, m - 1, d, 0, 0, tz);
|
|
86
|
+
}
|
|
87
|
+
const dt = LOCAL_DT_RE.exec(s);
|
|
88
|
+
if (dt) {
|
|
89
|
+
return wallToMs(
|
|
90
|
+
Number(dt[1]),
|
|
91
|
+
Number(dt[2]) - 1,
|
|
92
|
+
Number(dt[3]),
|
|
93
|
+
Number(dt[4]),
|
|
94
|
+
Number(dt[5]),
|
|
95
|
+
tz
|
|
96
|
+
);
|
|
97
|
+
}
|
|
98
|
+
return new Date(s).getTime();
|
|
99
|
+
}
|
|
4
100
|
function monthIndex(token) {
|
|
5
101
|
const t = token.trim().toLowerCase().slice(0, 3);
|
|
6
102
|
const i = [
|
|
@@ -37,16 +133,24 @@ function ordinalWord(n) {
|
|
|
37
133
|
function applyOrdinalTemplate(template, n) {
|
|
38
134
|
return template.replace(/\bNth\b/g, ordinalWord(n)).replace(/\bN\b/g, String(n));
|
|
39
135
|
}
|
|
40
|
-
function dayStart(ms) {
|
|
41
|
-
const
|
|
42
|
-
return
|
|
136
|
+
function dayStart(ms, tz = null) {
|
|
137
|
+
const f = zoneFields(ms, tz);
|
|
138
|
+
return wallToMs(f.year, f.month, f.day, 0, 0, tz);
|
|
139
|
+
}
|
|
140
|
+
function dayDelta(a, b, tz = null) {
|
|
141
|
+
return Math.round((dayStart(b, tz) - dayStart(a, tz)) / DAY_MS);
|
|
142
|
+
}
|
|
143
|
+
function sameDay(a, b, tz = null) {
|
|
144
|
+
const x = zoneFields(a, tz);
|
|
145
|
+
const y = zoneFields(b, tz);
|
|
146
|
+
return x.year === y.year && x.month === y.month && x.day === y.day;
|
|
43
147
|
}
|
|
44
|
-
function nthWeekdayOfMonth(year, month, weekday, nth, hour, minute) {
|
|
148
|
+
function nthWeekdayOfMonth(year, month, weekday, nth, hour, minute, tz) {
|
|
45
149
|
if (nth < 0) {
|
|
46
150
|
const last = new Date(year, month + 1, 0).getDate();
|
|
47
151
|
for (let d = last; d >= 1; d--) {
|
|
48
152
|
if (new Date(year, month, d).getDay() === weekday) {
|
|
49
|
-
return
|
|
153
|
+
return wallToMs(year, month, d, hour, minute, tz);
|
|
50
154
|
}
|
|
51
155
|
}
|
|
52
156
|
return null;
|
|
@@ -55,20 +159,21 @@ function nthWeekdayOfMonth(year, month, weekday, nth, hour, minute) {
|
|
|
55
159
|
const offset = (weekday - firstDow + 7) % 7;
|
|
56
160
|
const day = 1 + offset + (nth - 1) * 7;
|
|
57
161
|
if (day > new Date(year, month + 1, 0).getDate()) return null;
|
|
58
|
-
return
|
|
162
|
+
return wallToMs(year, month, day, hour, minute, tz);
|
|
59
163
|
}
|
|
60
164
|
function resolveNext(rule, now) {
|
|
61
|
-
const
|
|
165
|
+
const tz = rule.tz ?? null;
|
|
166
|
+
const nowF = zoneFields(now, tz);
|
|
62
167
|
const { hour, minute } = rule;
|
|
63
|
-
const passes = rule.allDay ? (t) => dayStart(t) >= dayStart(now) : (t) => t > now;
|
|
168
|
+
const passes = rule.allDay ? (t) => dayStart(t, tz) >= dayStart(now, tz) : (t) => t > now;
|
|
64
169
|
const dayExists = (y, m, d) => new Date(y, m, d).getMonth() === m;
|
|
65
170
|
switch (rule.kind) {
|
|
66
171
|
case "month-day": {
|
|
67
172
|
const month = rule.month;
|
|
68
173
|
const day = rule.day;
|
|
69
|
-
for (let y =
|
|
174
|
+
for (let y = nowF.year; ; y++) {
|
|
70
175
|
if (!dayExists(y, month, day)) continue;
|
|
71
|
-
const t =
|
|
176
|
+
const t = wallToMs(y, month, day, hour, minute, tz);
|
|
72
177
|
if (passes(t)) return t;
|
|
73
178
|
}
|
|
74
179
|
}
|
|
@@ -76,10 +181,10 @@ function resolveNext(rule, now) {
|
|
|
76
181
|
case "last-weekday": {
|
|
77
182
|
const weekday = rule.weekday;
|
|
78
183
|
const nth = rule.kind === "last-weekday" ? -1 : rule.nth;
|
|
79
|
-
let y =
|
|
80
|
-
let m =
|
|
184
|
+
let y = nowF.year;
|
|
185
|
+
let m = nowF.month;
|
|
81
186
|
for (let i = 0; i < 24; i++) {
|
|
82
|
-
const t = nthWeekdayOfMonth(y, m, weekday, nth, hour, minute);
|
|
187
|
+
const t = nthWeekdayOfMonth(y, m, weekday, nth, hour, minute, tz);
|
|
83
188
|
if (t !== null && passes(t)) return t;
|
|
84
189
|
m++;
|
|
85
190
|
if (m > 11) {
|
|
@@ -92,14 +197,17 @@ function resolveNext(rule, now) {
|
|
|
92
197
|
case "weekly": {
|
|
93
198
|
const weekday = rule.weekday;
|
|
94
199
|
for (let i = 0; i < 8; i++) {
|
|
95
|
-
const
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
200
|
+
const cal = new Date(nowF.year, nowF.month, nowF.day + i);
|
|
201
|
+
if (cal.getDay() !== weekday) continue;
|
|
202
|
+
const t = wallToMs(
|
|
203
|
+
cal.getFullYear(),
|
|
204
|
+
cal.getMonth(),
|
|
205
|
+
cal.getDate(),
|
|
99
206
|
hour,
|
|
100
|
-
minute
|
|
207
|
+
minute,
|
|
208
|
+
tz
|
|
101
209
|
);
|
|
102
|
-
if (
|
|
210
|
+
if (passes(t)) return t;
|
|
103
211
|
}
|
|
104
212
|
return now + WEEK_MS;
|
|
105
213
|
}
|
|
@@ -107,15 +215,15 @@ function resolveNext(rule, now) {
|
|
|
107
215
|
const n = rule.intervalN ?? 1;
|
|
108
216
|
const anchor = rule.anchorMs ?? now;
|
|
109
217
|
if (rule.intervalUnit === "month") {
|
|
110
|
-
const a =
|
|
111
|
-
const day = a.
|
|
218
|
+
const a = zoneFields(anchor, tz);
|
|
219
|
+
const day = a.day;
|
|
112
220
|
for (let k = 0; ; k++) {
|
|
113
|
-
const y = a.
|
|
114
|
-
const m = a.
|
|
221
|
+
const y = a.year;
|
|
222
|
+
const m = a.month + k * n;
|
|
115
223
|
const yy = y + Math.floor(m / 12);
|
|
116
224
|
const mm = (m % 12 + 12) % 12;
|
|
117
225
|
if (!dayExists(yy, mm, day)) continue;
|
|
118
|
-
const t2 =
|
|
226
|
+
const t2 = wallToMs(yy, mm, day, hour, minute, tz);
|
|
119
227
|
if (passes(t2)) return t2;
|
|
120
228
|
}
|
|
121
229
|
}
|
|
@@ -176,6 +284,10 @@ function formatCount(remainingMs, opts) {
|
|
|
176
284
|
const dayPrefix = has("d") && days > 0 ? `${days}d${clock ? " " : ""}` : "";
|
|
177
285
|
return dayPrefix + clock || plural(days, "day");
|
|
178
286
|
}
|
|
287
|
+
function splitClockSeconds(s) {
|
|
288
|
+
const m = /^(.+:\d{2}):(\d{2})$/.exec(s);
|
|
289
|
+
return m ? { lead: m[1], sec: ":" + m[2] } : { lead: s, sec: null };
|
|
290
|
+
}
|
|
179
291
|
function formatWordsDetail(remainingMs) {
|
|
180
292
|
const totalMin = Math.floor(Math.max(0, remainingMs) / 6e4);
|
|
181
293
|
const d = Math.floor(totalMin / 1440);
|
|
@@ -187,15 +299,15 @@ function formatWordsDetail(remainingMs) {
|
|
|
187
299
|
parts.push(`${m} minute${m === 1 ? "" : "s"}`);
|
|
188
300
|
return parts.join(" ");
|
|
189
301
|
}
|
|
190
|
-
function breakdown(nowMs, targetMs) {
|
|
191
|
-
const n =
|
|
192
|
-
const t =
|
|
193
|
-
let y = t.
|
|
194
|
-
let mo = t.
|
|
195
|
-
let d = t.
|
|
196
|
-
let h = t.
|
|
197
|
-
let mi = t.
|
|
198
|
-
let s = t.
|
|
302
|
+
function breakdown(nowMs, targetMs, tz = null) {
|
|
303
|
+
const n = zoneFields(nowMs, tz);
|
|
304
|
+
const t = zoneFields(targetMs, tz);
|
|
305
|
+
let y = t.year - n.year;
|
|
306
|
+
let mo = t.month - n.month;
|
|
307
|
+
let d = t.day - n.day;
|
|
308
|
+
let h = t.hour - n.hour;
|
|
309
|
+
let mi = t.minute - n.minute;
|
|
310
|
+
let s = t.second - n.second;
|
|
199
311
|
if (s < 0) {
|
|
200
312
|
s += 60;
|
|
201
313
|
mi--;
|
|
@@ -209,7 +321,7 @@ function breakdown(nowMs, targetMs) {
|
|
|
209
321
|
d--;
|
|
210
322
|
}
|
|
211
323
|
if (d < 0) {
|
|
212
|
-
d += new Date(t.
|
|
324
|
+
d += new Date(t.year, t.month, 0).getDate();
|
|
213
325
|
mo--;
|
|
214
326
|
}
|
|
215
327
|
if (mo < 0) {
|
|
@@ -218,8 +330,8 @@ function breakdown(nowMs, targetMs) {
|
|
|
218
330
|
}
|
|
219
331
|
return { years: y, months: mo, days: d, hours: h, minutes: mi, seconds: s };
|
|
220
332
|
}
|
|
221
|
-
function humanUnits(nowMs, targetMs) {
|
|
222
|
-
const b = breakdown(nowMs, targetMs);
|
|
333
|
+
function humanUnits(nowMs, targetMs, tz = null) {
|
|
334
|
+
const b = breakdown(nowMs, targetMs, tz);
|
|
223
335
|
return [
|
|
224
336
|
[b.years, "year"],
|
|
225
337
|
[b.months, "month"],
|
|
@@ -228,8 +340,8 @@ function humanUnits(nowMs, targetMs) {
|
|
|
228
340
|
[b.minutes, "minute"]
|
|
229
341
|
];
|
|
230
342
|
}
|
|
231
|
-
function formatHuman(nowMs, targetMs) {
|
|
232
|
-
const units = humanUnits(nowMs, targetMs);
|
|
343
|
+
function formatHuman(nowMs, targetMs, tz = null) {
|
|
344
|
+
const units = humanUnits(nowMs, targetMs, tz);
|
|
233
345
|
let i = 0;
|
|
234
346
|
while (i < units.length - 1 && units[i][0] === 0) i++;
|
|
235
347
|
const rest = units.slice(i);
|
|
@@ -238,8 +350,8 @@ function formatHuman(nowMs, targetMs) {
|
|
|
238
350
|
const secondary = rest.slice(2).filter((p) => p[0] > 0);
|
|
239
351
|
return { big: say(primary) || "now", sub: say(secondary) };
|
|
240
352
|
}
|
|
241
|
-
function formatCompound(nowMs, targetMs, maxUnits = 2) {
|
|
242
|
-
const all = humanUnits(nowMs, targetMs);
|
|
353
|
+
function formatCompound(nowMs, targetMs, maxUnits = 2, tz = null) {
|
|
354
|
+
const all = humanUnits(nowMs, targetMs, tz);
|
|
243
355
|
let i = 0;
|
|
244
356
|
while (i < all.length - 1 && all[i][0] === 0) i++;
|
|
245
357
|
const chosen = all.slice(i, i + maxUnits).filter((p, idx) => p[0] > 0 || idx === 0);
|
|
@@ -261,35 +373,42 @@ var MONTH_ABBR = [
|
|
|
261
373
|
"Nov",
|
|
262
374
|
"Dec"
|
|
263
375
|
];
|
|
264
|
-
function formatDate(ms) {
|
|
265
|
-
const
|
|
266
|
-
return `${WEEKDAY_ABBR[
|
|
376
|
+
function formatDate(ms, tz = null) {
|
|
377
|
+
const f = zoneFields(ms, tz);
|
|
378
|
+
return `${WEEKDAY_ABBR[f.weekday]} ${MONTH_ABBR[f.month]} ${f.day} ${f.year}`;
|
|
267
379
|
}
|
|
268
|
-
function formatDateShort(ms) {
|
|
269
|
-
const
|
|
270
|
-
return `${MONTH_ABBR[
|
|
380
|
+
function formatDateShort(ms, tz = null) {
|
|
381
|
+
const f = zoneFields(ms, tz);
|
|
382
|
+
return `${MONTH_ABBR[f.month]} ${f.day} ${f.year}`;
|
|
271
383
|
}
|
|
272
|
-
function formatFooter(resolvedMs, hasTime) {
|
|
273
|
-
const parts = [formatDate(resolvedMs)];
|
|
384
|
+
function formatFooter(resolvedMs, hasTime, tz = null) {
|
|
385
|
+
const parts = [formatDate(resolvedMs, tz)];
|
|
274
386
|
if (hasTime) {
|
|
275
|
-
const
|
|
276
|
-
parts.push(`${pad2(
|
|
387
|
+
const f = zoneFields(resolvedMs, tz);
|
|
388
|
+
parts.push(`${pad2(f.hour)}:${pad2(f.minute)}`);
|
|
389
|
+
const label = zoneOffsetLabel(resolvedMs, tz);
|
|
390
|
+
if (label) parts.push(label);
|
|
277
391
|
}
|
|
278
392
|
return parts.join(" \xB7 ");
|
|
279
393
|
}
|
|
280
394
|
|
|
281
395
|
export {
|
|
282
396
|
DAY_MS,
|
|
397
|
+
targetToMs,
|
|
283
398
|
monthIndex,
|
|
284
399
|
weekdayIndex,
|
|
285
400
|
applyOrdinalTemplate,
|
|
401
|
+
dayStart,
|
|
402
|
+
dayDelta,
|
|
403
|
+
sameDay,
|
|
286
404
|
resolveNext,
|
|
287
405
|
ordinalFor,
|
|
288
406
|
formatCount,
|
|
407
|
+
splitClockSeconds,
|
|
289
408
|
formatWordsDetail,
|
|
290
409
|
formatHuman,
|
|
291
410
|
formatCompound,
|
|
292
411
|
formatDateShort,
|
|
293
412
|
formatFooter
|
|
294
413
|
};
|
|
295
|
-
//# sourceMappingURL=chunk-
|
|
414
|
+
//# sourceMappingURL=chunk-OQKP2X3D.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
measureText
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-WCT3NYCV.js";
|
|
4
4
|
|
|
5
5
|
// src/utils/card.ts
|
|
6
6
|
function renderNodeCard(container, opts) {
|
|
@@ -44,4 +44,4 @@ export {
|
|
|
44
44
|
renderNodeCard,
|
|
45
45
|
renderCollapseBar
|
|
46
46
|
};
|
|
47
|
-
//# sourceMappingURL=chunk-
|
|
47
|
+
//# sourceMappingURL=chunk-OTOHI4JO.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
computeLegendLayout
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-YAA6IID3.js";
|
|
4
4
|
import {
|
|
5
5
|
FONT_FAMILY
|
|
6
6
|
} from "./chunk-6KFWC4CO.js";
|
|
@@ -14,14 +14,14 @@ import {
|
|
|
14
14
|
LEGEND_TOGGLE_DOT_R,
|
|
15
15
|
LEGEND_TOGGLE_OFF_OPACITY,
|
|
16
16
|
measureLegendText
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-QOOUC2J5.js";
|
|
18
18
|
import {
|
|
19
19
|
mix,
|
|
20
20
|
valueRampStops
|
|
21
21
|
} from "./chunk-P6T66CCZ.js";
|
|
22
22
|
import {
|
|
23
23
|
tagAttrKey
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-467TVMQL.js";
|
|
25
25
|
|
|
26
26
|
// src/utils/legend-d3.ts
|
|
27
27
|
var LEGEND_TEXT_DY = "0.32em";
|
|
@@ -293,4 +293,4 @@ export {
|
|
|
293
293
|
renderLegendD3,
|
|
294
294
|
renderIntegratedLegend
|
|
295
295
|
};
|
|
296
|
-
//# sourceMappingURL=chunk-
|
|
296
|
+
//# sourceMappingURL=chunk-OU7HLO7I.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-I46X5VUA.js";
|
|
4
4
|
import {
|
|
5
5
|
tryCollectNote
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-WQLMU7VG.js";
|
|
7
7
|
import {
|
|
8
8
|
resolveNotes
|
|
9
9
|
} from "./chunk-FMDSF3OV.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
measureIndent,
|
|
21
21
|
parseFirstLine,
|
|
22
22
|
tryParseSharedOption
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-LV4BETUU.js";
|
|
24
24
|
import {
|
|
25
25
|
NAME_DIAGNOSTIC_CODES,
|
|
26
26
|
emit,
|
|
@@ -467,4 +467,4 @@ export {
|
|
|
467
467
|
looksLikeFlowchart,
|
|
468
468
|
extractSymbols
|
|
469
469
|
};
|
|
470
|
-
//# sourceMappingURL=chunk-
|
|
470
|
+
//# sourceMappingURL=chunk-OZPBJM5Q.js.map
|
|
@@ -9,7 +9,12 @@ import {
|
|
|
9
9
|
} from "./chunk-I5IGB56C.js";
|
|
10
10
|
import {
|
|
11
11
|
MAP_DX
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-4B5YISOR.js";
|
|
13
|
+
import {
|
|
14
|
+
formatOffsetLabel,
|
|
15
|
+
isValidZone,
|
|
16
|
+
parseFixedOffset
|
|
17
|
+
} from "./chunk-APKUAJ2L.js";
|
|
13
18
|
import {
|
|
14
19
|
emit,
|
|
15
20
|
formatDgmoError,
|
|
@@ -311,13 +316,13 @@ function resolveMap(parsed, data) {
|
|
|
311
316
|
diagnostics.push(emit(MAP_DX.UNKNOWN_PLACE, line, { name, hint }));
|
|
312
317
|
return { kind: "miss" };
|
|
313
318
|
}
|
|
314
|
-
let cands = idxs.map((i) => data.gazetteer.cities[i]);
|
|
319
|
+
let cands = idxs.map((i) => ({ i, c: data.gazetteer.cities[i] }));
|
|
315
320
|
const scopeUse = scope ?? scopeHint;
|
|
316
321
|
if (scopeUse) {
|
|
317
322
|
const bareState = usStateFromBareScope(scopeUse);
|
|
318
323
|
const subScope = /^[A-Za-z]{2}-/.test(scopeUse) ? scopeUse : bareState;
|
|
319
324
|
const filtered = cands.filter(
|
|
320
|
-
(c2) => subScope ? c2[5] === subScope : c2[2] === scopeUse
|
|
325
|
+
({ c: c2 }) => subScope ? c2[5] === subScope : c2[2] === scopeUse
|
|
321
326
|
);
|
|
322
327
|
if (filtered.length) cands = filtered;
|
|
323
328
|
else if (scope) {
|
|
@@ -331,10 +336,10 @@ function resolveMap(parsed, data) {
|
|
|
331
336
|
if (!allowAmbiguous && !scopeUse) {
|
|
332
337
|
return { kind: "defer" };
|
|
333
338
|
}
|
|
334
|
-
cands = [...cands].sort((a, b) => b[3] - a[3]);
|
|
339
|
+
cands = [...cands].sort((a, b) => b.c[3] - a.c[3]);
|
|
335
340
|
if (!scope) diagnostics.push(emit(MAP_DX.AMBIGUOUS_NAME, line, { name }));
|
|
336
341
|
}
|
|
337
|
-
const c = cands[0];
|
|
342
|
+
const { i: cityIdx, c } = cands[0];
|
|
338
343
|
if (data.airports?.airportIata?.[f] !== void 0 && !shadowedAirports.has(f)) {
|
|
339
344
|
shadowedAirports.add(f);
|
|
340
345
|
const code = name.toUpperCase();
|
|
@@ -342,7 +347,15 @@ function resolveMap(parsed, data) {
|
|
|
342
347
|
emit(MAP_DX.AIRPORT_SHADOWED_BY_CITY, line, { name, code })
|
|
343
348
|
);
|
|
344
349
|
}
|
|
345
|
-
|
|
350
|
+
const zoneId = data.gazetteer.tz?.[cityIdx];
|
|
351
|
+
const gazTz = zoneId !== void 0 && zoneId >= 0 ? data.gazetteer.zones?.[zoneId] : void 0;
|
|
352
|
+
return {
|
|
353
|
+
kind: "ok",
|
|
354
|
+
lat: c[0],
|
|
355
|
+
lon: c[1],
|
|
356
|
+
iso: c[2],
|
|
357
|
+
...gazTz !== void 0 && { tz: gazTz }
|
|
358
|
+
};
|
|
346
359
|
};
|
|
347
360
|
const poiIdFor = (pos, alias) => {
|
|
348
361
|
if (alias) return fold(alias);
|
|
@@ -377,7 +390,7 @@ function resolveMap(parsed, data) {
|
|
|
377
390
|
);
|
|
378
391
|
if (got.kind === "ok") {
|
|
379
392
|
noteCountry(got.iso);
|
|
380
|
-
addResolvedPoi(got.lat, got.lon, p);
|
|
393
|
+
addResolvedPoi(got.lat, got.lon, p, got.tz);
|
|
381
394
|
} else if (got.kind === "defer") {
|
|
382
395
|
deferred.push(p);
|
|
383
396
|
}
|
|
@@ -395,12 +408,13 @@ function resolveMap(parsed, data) {
|
|
|
395
408
|
);
|
|
396
409
|
if (got.kind === "ok") {
|
|
397
410
|
noteCountry(got.iso);
|
|
398
|
-
addResolvedPoi(got.lat, got.lon, p);
|
|
411
|
+
addResolvedPoi(got.lat, got.lon, p, got.tz);
|
|
399
412
|
}
|
|
400
413
|
}
|
|
401
|
-
function addResolvedPoi(lat, lon, p) {
|
|
414
|
+
function addResolvedPoi(lat, lon, p, gazTz) {
|
|
402
415
|
const id = poiIdFor(p.pos, p.alias);
|
|
403
416
|
const name = p.pos.kind === "name" ? p.pos.name : p.alias;
|
|
417
|
+
const tz = resolveTz(p, gazTz);
|
|
404
418
|
const poi = {
|
|
405
419
|
id,
|
|
406
420
|
...name !== void 0 && { name },
|
|
@@ -410,10 +424,36 @@ function resolveMap(parsed, data) {
|
|
|
410
424
|
...p.color !== void 0 && { color: p.color },
|
|
411
425
|
tags: p.tags,
|
|
412
426
|
meta: p.meta,
|
|
413
|
-
lineNumber: p.lineNumber
|
|
427
|
+
lineNumber: p.lineNumber,
|
|
428
|
+
...tz !== void 0 && { tz: tz.zone },
|
|
429
|
+
...tz?.fixedOffsetMin !== void 0 && {
|
|
430
|
+
tzFixedOffsetMin: tz.fixedOffsetMin
|
|
431
|
+
}
|
|
414
432
|
};
|
|
415
433
|
registerPoi(id, poi, p.lineNumber);
|
|
416
434
|
}
|
|
435
|
+
function resolveTz(p, gazTz) {
|
|
436
|
+
if (!p.clock) return void 0;
|
|
437
|
+
const raw = p.meta["clock"]?.trim();
|
|
438
|
+
const line = p.lineNumber;
|
|
439
|
+
if (raw) {
|
|
440
|
+
const off = parseFixedOffset(raw);
|
|
441
|
+
if (off !== null)
|
|
442
|
+
return { zone: formatOffsetLabel(off), fixedOffsetMin: off };
|
|
443
|
+
if (isValidZone(raw)) {
|
|
444
|
+
if (gazTz && raw !== gazTz)
|
|
445
|
+
diagnostics.push(
|
|
446
|
+
emit(MAP_DX.CLOCK_TZ_OVERRIDE, line, { name: raw, tz: gazTz })
|
|
447
|
+
);
|
|
448
|
+
return { zone: raw };
|
|
449
|
+
}
|
|
450
|
+
diagnostics.push(emit(MAP_DX.CLOCK_TZ_INVALID, line, { name: raw }));
|
|
451
|
+
return void 0;
|
|
452
|
+
}
|
|
453
|
+
if (gazTz) return { zone: gazTz };
|
|
454
|
+
diagnostics.push(emit(MAP_DX.CLOCK_TZ_NEEDED, line, {}));
|
|
455
|
+
return void 0;
|
|
456
|
+
}
|
|
417
457
|
const declaredByName = /* @__PURE__ */ new Map();
|
|
418
458
|
for (const p of pois) {
|
|
419
459
|
const fn = p.name ? fold(p.name) : void 0;
|
|
@@ -735,4 +775,4 @@ export {
|
|
|
735
775
|
isSubNationalUsExtent,
|
|
736
776
|
resolveMap
|
|
737
777
|
};
|
|
738
|
-
//# sourceMappingURL=chunk-
|
|
778
|
+
//# sourceMappingURL=chunk-P3NRSSUU.js.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
parseFirstLine,
|
|
6
6
|
splitNameAndMeta,
|
|
7
7
|
warnUnknownMetaKeys
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-LV4BETUU.js";
|
|
9
9
|
import {
|
|
10
10
|
makeDgmoError,
|
|
11
11
|
makeFail,
|
|
@@ -332,4 +332,4 @@ function assignGlobalNumbers(result) {
|
|
|
332
332
|
export {
|
|
333
333
|
parseTechRadar
|
|
334
334
|
};
|
|
335
|
-
//# sourceMappingURL=chunk-
|
|
335
|
+
//# sourceMappingURL=chunk-PZDBOK2Q.js.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
splitNameAndMeta,
|
|
6
6
|
tryParseSharedOption,
|
|
7
7
|
warnUnknownMetaKeys
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-LV4BETUU.js";
|
|
9
9
|
import {
|
|
10
10
|
makeDgmoError,
|
|
11
11
|
makeFail
|
|
@@ -127,4 +127,4 @@ function parsePyramid(content) {
|
|
|
127
127
|
export {
|
|
128
128
|
parsePyramid
|
|
129
129
|
};
|
|
130
|
-
//# sourceMappingURL=chunk-
|
|
130
|
+
//# sourceMappingURL=chunk-Q62FEYK3.js.map
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
layoutC4Containers,
|
|
5
5
|
layoutC4Context,
|
|
6
6
|
layoutC4Deployment
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-NEQ6GJXB.js";
|
|
8
8
|
import {
|
|
9
9
|
renderInlineText
|
|
10
10
|
} from "./chunk-3HDBAXF5.js";
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
} from "./chunk-3CIOJ5YJ.js";
|
|
18
18
|
import {
|
|
19
19
|
renderIntegratedLegend
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-OU7HLO7I.js";
|
|
21
21
|
import {
|
|
22
22
|
TITLE_FONT_SIZE,
|
|
23
23
|
TITLE_FONT_WEIGHT
|
|
@@ -27,14 +27,14 @@ import {
|
|
|
27
27
|
} from "./chunk-6KFWC4CO.js";
|
|
28
28
|
import {
|
|
29
29
|
LEGEND_HEIGHT
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-QOOUC2J5.js";
|
|
31
31
|
import {
|
|
32
32
|
measureText,
|
|
33
33
|
wrapTextToWidth
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-WCT3NYCV.js";
|
|
35
35
|
import {
|
|
36
36
|
parseC4
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-3LV2NCB6.js";
|
|
38
38
|
import {
|
|
39
39
|
preprocessDescriptionLine
|
|
40
40
|
} from "./chunk-IYULMRBE.js";
|
|
@@ -45,7 +45,7 @@ import {
|
|
|
45
45
|
} from "./chunk-P6T66CCZ.js";
|
|
46
46
|
import {
|
|
47
47
|
tagAttrKey
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-467TVMQL.js";
|
|
49
49
|
|
|
50
50
|
// src/c4/renderer.ts
|
|
51
51
|
import * as d3Selection from "d3-selection";
|
|
@@ -1035,4 +1035,4 @@ export {
|
|
|
1035
1035
|
renderC4Deployment,
|
|
1036
1036
|
renderC4DeploymentForExport
|
|
1037
1037
|
};
|
|
1038
|
-
//# sourceMappingURL=chunk-
|
|
1038
|
+
//# sourceMappingURL=chunk-QHI5XVUJ.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
measureText,
|
|
3
3
|
truncateText
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-WCT3NYCV.js";
|
|
5
5
|
|
|
6
6
|
// src/utils/legend-constants.ts
|
|
7
7
|
var LEGEND_HEIGHT = 28;
|
|
@@ -49,4 +49,4 @@ export {
|
|
|
49
49
|
LEGEND_TOGGLE_OFF_OPACITY,
|
|
50
50
|
LEGEND_GEAR_PILL_W
|
|
51
51
|
};
|
|
52
|
-
//# sourceMappingURL=chunk-
|
|
52
|
+
//# sourceMappingURL=chunk-QOOUC2J5.js.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
normalizeNumericToken,
|
|
6
6
|
parseFirstLine,
|
|
7
7
|
parseSeriesNames
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-LV4BETUU.js";
|
|
9
9
|
import {
|
|
10
10
|
RECOGNIZED_COLOR_NAMES,
|
|
11
11
|
resolveColorWithDiagnostic
|
|
@@ -45,6 +45,7 @@ var KNOWN_BOOLEANS = /* @__PURE__ */ new Set([
|
|
|
45
45
|
"orientation-horizontal",
|
|
46
46
|
"solid-fill",
|
|
47
47
|
"no-title",
|
|
48
|
+
"no-auto-y",
|
|
48
49
|
"fill",
|
|
49
50
|
"hole"
|
|
50
51
|
]);
|
|
@@ -176,6 +177,8 @@ function parseChart(content, palette) {
|
|
|
176
177
|
result.solidFill = true;
|
|
177
178
|
} else if (firstToken === "no-title") {
|
|
178
179
|
result.noTitle = true;
|
|
180
|
+
} else if (firstToken === "no-auto-y") {
|
|
181
|
+
result.noAutoY = true;
|
|
179
182
|
} else if (firstToken === "fill") {
|
|
180
183
|
result.fill = true;
|
|
181
184
|
} else if (firstToken === "hole") {
|
|
@@ -1054,4 +1057,4 @@ export {
|
|
|
1054
1057
|
getSimpleChartLegendGroups,
|
|
1055
1058
|
getExtendedChartLegendGroups
|
|
1056
1059
|
};
|
|
1057
|
-
//# sourceMappingURL=chunk-
|
|
1060
|
+
//# sourceMappingURL=chunk-QZPEGJOM.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildMapProjection
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-32XPAAET.js";
|
|
4
4
|
import {
|
|
5
5
|
TITLE_FONT_SIZE,
|
|
6
6
|
TITLE_Y
|
|
@@ -51,4 +51,4 @@ export {
|
|
|
51
51
|
mapContentAspect,
|
|
52
52
|
mapExportDimensions
|
|
53
53
|
};
|
|
54
|
-
//# sourceMappingURL=chunk-
|
|
54
|
+
//# sourceMappingURL=chunk-RAHVMKBG.js.map
|