@diagrammo/dgmo 0.51.0 → 0.53.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/.cursorrules +74 -77
- package/.github/copilot-instructions.md +74 -77
- package/.windsurfrules +74 -77
- package/SKILL.md +74 -77
- package/dist/advanced.d.ts +109 -246
- package/dist/advanced.js +296 -633
- package/dist/analyzer-TDN5KJFP.js +15 -0
- package/dist/auto.css +14 -6
- package/dist/auto.js +141 -129
- package/dist/auto.mjs +2062 -937
- package/dist/block.css +14 -6
- package/dist/block.js +123 -73
- package/dist/calculator-VBIT6GQF.js +11 -0
- package/dist/chart-meta-CPNVUZ5J.d.ts +232 -0
- package/dist/chart-meta.d.ts +2 -0
- package/dist/chart-meta.js +105 -0
- package/dist/charts-d3-DH2XA45I.js +26 -0
- package/dist/{chunk-RLFVAKEO.js → chunk-22OQWBWD.js} +25 -8
- package/dist/{chunk-I2QZFCS2.js → chunk-27STWBOK.js} +10 -8
- package/dist/{chunk-5PZT4DQG.js → chunk-2QC4HXCY.js} +41 -21
- package/dist/{chunk-HFMYN6N2.js → chunk-3B2GXZCX.js} +4 -3
- package/dist/{chunk-F3FYUFUH.js → chunk-3BEKKRH5.js} +18 -17
- package/dist/{chunk-2UJSV2VT.js → chunk-3CZLWOCI.js} +17 -7
- package/dist/{chunk-JEUJOX5X.js → chunk-3IUHKMJI.js} +2 -2
- package/dist/{chunk-7L4UJOY6.js → chunk-3TYUXC7D.js} +2 -2
- package/dist/{chunk-Y2ZE3MSG.js → chunk-43E26CDA.js} +2 -2
- package/dist/{chunk-ZO27FGJS.js → chunk-4ASVFYB2.js} +10 -7
- package/dist/{chunk-WCT3NYCV.js → chunk-4ASYQ347.js} +33 -8
- package/dist/{chunk-2ILHQOL3.js → chunk-4K42RUGC.js} +41 -13
- package/dist/{chunk-I5IGB56C.js → chunk-4QV26TEG.js} +41 -1
- package/dist/{chunk-QOOUC2J5.js → chunk-4RGZFA7H.js} +2 -2
- package/dist/{chunk-CXK4DZH3.js → chunk-4W2PE66Q.js} +12 -2
- package/dist/{chunk-EXOQP75F.js → chunk-4WGMGKCZ.js} +53 -33
- package/dist/{chunk-JED6ZDEE.js → chunk-5HWPEYWB.js} +2 -2
- package/dist/{chunk-3YSQZ75W.js → chunk-65V6IRFN.js} +46 -33
- package/dist/{chunk-TMACGPW5.js → chunk-6AUZPPAV.js} +4 -4
- package/dist/{chunk-6H7O2OPM.js → chunk-6DCOIN4W.js} +36 -6
- package/dist/{chunk-GTWKD3QT.js → chunk-6HTRCTAS.js} +7 -6
- package/dist/{chunk-VB4UJ3H2.js → chunk-6KY7OCZC.js} +21 -11
- package/dist/{chunk-YAA6IID3.js → chunk-774C2FF3.js} +2 -2
- package/dist/{chunk-WJ7RW65H.js → chunk-7GUF6SDR.js} +22 -20
- package/dist/{chunk-QYTPPDAO.js → chunk-7JDTNFAK.js} +3 -3
- package/dist/{chunk-U6EQI3U6.js → chunk-ADYKAKE3.js} +3 -3
- package/dist/{chunk-VNSXLA6G.js → chunk-AHXIMHDQ.js} +84 -20
- package/dist/chunk-AIMLCDAO.js +404 -0
- package/dist/{chunk-6MNGECP2.js → chunk-ALYZ3MAA.js} +4 -4
- package/dist/{chunk-5F5ELR3V.js → chunk-AN2DQB3G.js} +151 -20
- package/dist/{chunk-IEWG6J7C.js → chunk-AZNXGWDC.js} +91 -36
- package/dist/{chunk-4XFBQT5O.js → chunk-B4XS2AF2.js} +3 -3
- package/dist/{chunk-CC4YRBWV.js → chunk-BD3WGY4T.js} +18 -8
- package/dist/{chunk-RAHVMKBG.js → chunk-BFDVEO5R.js} +2 -2
- package/dist/{chunk-332ZR4QU.js → chunk-BR7AYN76.js} +8 -8
- package/dist/{chunk-P3NRSSUU.js → chunk-BULHGPHK.js} +3 -3
- package/dist/{chunk-PZDBOK2Q.js → chunk-CK2GMDXD.js} +11 -5
- package/dist/{chunk-467TVMQL.js → chunk-CMVZWP32.js} +3 -3
- package/dist/{chunk-GNSFLJAA.js → chunk-CQFNIIQN.js} +7 -7
- package/dist/{chunk-RBDIYLA5.js → chunk-DAOFNU6J.js} +17 -1
- package/dist/{chunk-AFIEPDLX.js → chunk-DWUMPMV2.js} +23 -11
- package/dist/{chunk-USZW2HHU.js → chunk-EQW6HOP4.js} +4 -3
- package/dist/{chunk-6BQFET7X.js → chunk-FFXCKZOU.js} +12 -4
- package/dist/{chunk-WRNFDFPU.js → chunk-FGDSTT3F.js} +2 -2
- package/dist/{chunk-6NFYEQDX.js → chunk-FLDC7ZAK.js} +34 -7
- package/dist/{chunk-IUJODQKX.js → chunk-FT7TPPZ5.js} +25 -23
- package/dist/{chunk-IEDMFNU7.js → chunk-FUKNRLIJ.js} +19 -7
- package/dist/{chunk-JJXGQIRV.js → chunk-FXCB7H5O.js} +4 -4
- package/dist/{chunk-GGHRAITI.js → chunk-GABSL6TH.js} +4 -4
- package/dist/{chunk-RXKTSFDL.js → chunk-GAWKIIPO.js} +35 -43
- package/dist/{chunk-ZJ3LS7DW.js → chunk-GMAH572Z.js} +6 -6
- package/dist/{chunk-TRM2J7ZN.js → chunk-GMIJ35PW.js} +28 -29
- package/dist/{chunk-AB7INMR5.js → chunk-GQ644SPD.js} +26 -25
- package/dist/{chunk-5QKQSSPO.js → chunk-GRM2A4BG.js} +4 -4
- package/dist/{chunk-3ODS2VGL.js → chunk-GWQJKTFS.js} +161 -704
- package/dist/{chunk-OTOHI4JO.js → chunk-H3HFC3SQ.js} +2 -2
- package/dist/{chunk-JSSX2SX4.js → chunk-HE5J53SZ.js} +4 -4
- package/dist/{chunk-2EQMXBBQ.js → chunk-HNBY6CNV.js} +3 -3
- package/dist/{chunk-J76PIKAT.js → chunk-HO3RCNF6.js} +3 -3
- package/dist/{chunk-OJTXTQA2.js → chunk-HORZ5H2L.js} +38 -31
- package/dist/{chunk-MX2EY5Y7.js → chunk-HOXKNRON.js} +2 -2
- package/dist/{chunk-E7Y3SYKW.js → chunk-I64ECJX3.js} +18 -8
- package/dist/{chunk-JM4LEPY3.js → chunk-IQJCVREL.js} +11 -8
- package/dist/{chunk-3JLKYGBQ.js → chunk-J7HI6G3G.js} +9 -6
- package/dist/{chunk-Q62FEYK3.js → chunk-JHOAH4TI.js} +3 -3
- package/dist/{chunk-OZPBJM5Q.js → chunk-JTMSWEIW.js} +11 -8
- package/dist/{chunk-P6T66CCZ.js → chunk-JYDMBWRP.js} +37 -19
- package/dist/{chunk-7DF4J4RL.js → chunk-KKHCNSKK.js} +17 -11
- package/dist/{chunk-ENRS56GC.js → chunk-KUSAVOWZ.js} +11 -8
- package/dist/{chunk-BYJBIALT.js → chunk-LC3FFD43.js} +23 -18
- package/dist/{chunk-65WJYYKJ.js → chunk-LHILKFDP.js} +16 -11
- package/dist/{chunk-NEQ6GJXB.js → chunk-LQHVDZYC.js} +52 -16
- package/dist/{chunk-5WPNFSXP.js → chunk-MA3HJZHB.js} +5 -5
- package/dist/{chunk-Z6XJQ6KO.js → chunk-MEQYZZFR.js} +3 -3
- package/dist/{chunk-MVN25IF6.js → chunk-NNUMX6WX.js} +42 -12
- package/dist/{chunk-7DYOELRK.js → chunk-NNYFQOTK.js} +78 -38
- package/dist/{chunk-NNAAJVBU.js → chunk-NR5HCAUD.js} +1 -1
- package/dist/{chunk-H6PI3KJT.js → chunk-ODUT5WMC.js} +2 -2
- package/dist/{chunk-5PDTIBLV.js → chunk-P3H7QVDH.js} +56 -19
- package/dist/{chunk-ND76YJCN.js → chunk-PIXZTCKH.js} +84 -117
- package/dist/{chunk-3LV2NCB6.js → chunk-PKNNHU7H.js} +22 -9
- package/dist/{chunk-TK2VQQX2.js → chunk-PT4SW76W.js} +20 -18
- package/dist/{chunk-AE7II3E3.js → chunk-PV2QO7QL.js} +4 -4
- package/dist/{chunk-FTBZV6NE.js → chunk-PYO4TJJ3.js} +34 -26
- package/dist/{chunk-QZPEGJOM.js → chunk-Q7AH665U.js} +28 -14
- package/dist/{chunk-QHI5XVUJ.js → chunk-QAALSCKI.js} +27 -26
- package/dist/{chunk-GD6L76WD.js → chunk-QI3BOLQB.js} +23 -11
- package/dist/{chunk-Y6GBQTBK.js → chunk-QWIBT6DS.js} +50 -28
- package/dist/{chunk-GU46PPT3.js → chunk-QXGACPS2.js} +5 -5
- package/dist/{chunk-FMDSF3OV.js → chunk-QZAW5SFH.js} +2 -2
- package/dist/{chunk-YGJZWZTY.js → chunk-R5NH5BZG.js} +12 -9
- package/dist/{chunk-U5SI5NIM.js → chunk-RJ5LBZ5U.js} +43 -26
- package/dist/{chunk-XHVV4NVW.js → chunk-RT7ACF77.js} +12 -2
- package/dist/{chunk-XEQXCIBC.js → chunk-RW5PEJ7D.js} +18 -6
- package/dist/{chunk-4VWJ4LW2.js → chunk-SG4PRYO3.js} +61 -49
- package/dist/{chunk-RBHWPDBB.js → chunk-SGPFVDUL.js} +18 -7
- package/dist/{chunk-KJGG2JKQ.js → chunk-SQCBSFT5.js} +84 -79
- package/dist/{chunk-5X6YQA2J.js → chunk-U7NKYLX2.js} +18 -16
- package/dist/chunk-U7VO6JAA.js +566 -0
- package/dist/{chunk-32XPAAET.js → chunk-UFQJMOVZ.js} +10 -10
- package/dist/{chunk-Z72XRXD4.js → chunk-UJRTPOHH.js} +3 -3
- package/dist/{chunk-EDA6C7MV.js → chunk-UK6DKJLD.js} +34 -14
- package/dist/{chunk-GROLTAWZ.js → chunk-UKP5HWB5.js} +149 -89
- package/dist/{chunk-DY7XLRHK.js → chunk-UQRIKAMH.js} +28 -27
- package/dist/{chunk-TYS6CSS5.js → chunk-UU6LUYUH.js} +2 -2
- package/dist/{chunk-NI3XQBPB.js → chunk-UVDCHR4E.js} +18 -6
- package/dist/{chunk-6K2M4VSR.js → chunk-VAO6ANGC.js} +23 -10
- package/dist/{chunk-6NYWYNBI.js → chunk-VGNIDAPQ.js} +4 -4
- package/dist/{chunk-VL2O2F3W.js → chunk-VHO3YBTB.js} +2 -2
- package/dist/{chunk-IUO34HKW.js → chunk-VIRANCNY.js} +36 -32
- package/dist/{chunk-4QZ43D7I.js → chunk-VJHBSPGF.js} +12 -14
- package/dist/{chunk-BGP54HVR.js → chunk-VKNCC2GX.js} +12 -8
- package/dist/{chunk-FC5I2KXV.js → chunk-VRRDUYOK.js} +7 -7
- package/dist/{chunk-G3PF3S7P.js → chunk-W2DINCHL.js} +15 -15
- package/dist/{chunk-OU7HLO7I.js → chunk-W5KMNC5U.js} +8 -8
- package/dist/{chunk-FFUN5D66.js → chunk-WF64MW5G.js} +2 -2
- package/dist/{chunk-X7EC3L2H.js → chunk-X3RXGSCZ.js} +48 -30
- package/dist/{chunk-KFNWFNAA.js → chunk-XEAQDIMF.js} +7 -6
- package/dist/{chunk-AXW3M6OQ.js → chunk-XG4NWFPY.js} +38 -27
- package/dist/{chunk-B63YB7X3.js → chunk-XQ4KN6JQ.js} +127 -65
- package/dist/{chunk-WBRZJOEC.js → chunk-XY3UDKKH.js} +4 -4
- package/dist/{chunk-IE477RQZ.js → chunk-YG2BEIQU.js} +14 -13
- package/dist/{chunk-LV4BETUU.js → chunk-YJVA3QUU.js} +55 -5
- package/dist/{chunk-5SVOCD5W.js → chunk-YR43LJT5.js} +20 -16
- package/dist/{chunk-TLVIHFRO.js → chunk-ZKPPI6BF.js} +2 -2
- package/dist/{chunk-WQLMU7VG.js → chunk-ZXUAPTCK.js} +3 -3
- package/dist/cli.cjs +158 -155
- package/dist/clock.js +25 -23
- package/dist/countdown.js +4 -3
- package/dist/dgmo-router-B4S23EBH.js +86 -0
- package/dist/dimensions-K6PGYYGT.js +22 -0
- package/dist/editor.js +36 -6
- package/dist/element.js +143 -131
- package/dist/element.mjs +2062 -937
- package/dist/flowchart-parser-LALR6J6F.js +21 -0
- package/dist/{flowchart-renderer-AQSMEMYF.js → flowchart-renderer-DXYB5YRF.js} +14 -14
- package/dist/highlight.d.ts +21 -1
- package/dist/highlight.js +129 -8
- package/dist/index.d.ts +4 -2
- package/dist/index.js +80 -75
- package/dist/layout-3BVDMKXI.js +15 -0
- package/dist/layout-3M5UYJHY.js +14 -0
- package/dist/{layout-JDJAEQ3P.js → layout-3V2A4MUE.js} +8 -8
- package/dist/layout-4IHCMWZN.js +19 -0
- package/dist/layout-5XGYNYVT.js +9 -0
- package/dist/layout-AZUPXWSK.js +15 -0
- package/dist/{layout-F4WO357A.js → layout-CAAKQX4W.js} +3 -3
- package/dist/layout-CB3XWCOI.js +10 -0
- package/dist/{layout-OAC4PEAC.js → layout-E6HR6PXH.js} +7 -7
- package/dist/{layout-7QXCNOVS.js → layout-HBWT2G23.js} +3 -3
- package/dist/layout-KPQWJNAG.js +14 -0
- package/dist/layout-OL2XFJXA.js +17 -0
- package/dist/layout-WCAIKGZG.js +19 -0
- package/dist/layout-WSMPBQ4Q.js +17 -0
- package/dist/layout-ZE5DRJWX.js +20 -0
- package/dist/{layout-search-55FU6HD3.js → layout-search-34DPZD43.js} +51 -35
- package/dist/legend-constants-P5EQWRQQ.js +49 -0
- package/dist/{palettes-PRJ2RI6D.js → palettes-FGTNFARW.js} +4 -4
- package/dist/{parser-KKTJ6M3Y.js → parser-275KP7JO.js} +8 -8
- package/dist/parser-27Z76SN3.js +22 -0
- package/dist/parser-3CODK6RG.js +15 -0
- package/dist/{parser-EH5VE7ZN.js → parser-3KIGEEJM.js} +6 -6
- package/dist/parser-3VSWEKBF.js +15 -0
- package/dist/parser-4E4I3GNT.js +13 -0
- package/dist/parser-5FGJSQNS.js +12 -0
- package/dist/parser-5HQXCNOS.js +12 -0
- package/dist/parser-5QPFOB5F.js +12 -0
- package/dist/parser-6B6SSZT7.js +11 -0
- package/dist/parser-6PPHAXXH.js +14 -0
- package/dist/parser-7JHWEWXM.js +13 -0
- package/dist/{parser-5PDYJGWA.js → parser-7JVIDLLR.js} +7 -7
- package/dist/parser-CKA3QMAG.js +18 -0
- package/dist/parser-CRKLXGW7.js +13 -0
- package/dist/parser-EXNBDNGY.js +11 -0
- package/dist/parser-FF4BMRSB.js +16 -0
- package/dist/parser-FOOFEJQU.js +13 -0
- package/dist/parser-G26MTBFS.js +11 -0
- package/dist/parser-GKP2MHHL.js +11 -0
- package/dist/parser-GN2MM5CC.js +11 -0
- package/dist/parser-IKWK2ZU3.js +18 -0
- package/dist/parser-IVGHXLZP.js +14 -0
- package/dist/parser-NNIL3HXU.js +11 -0
- package/dist/parser-RNLTBIJ6.js +19 -0
- package/dist/parser-UWRX52PC.js +16 -0
- package/dist/parser-VOERD6XR.js +14 -0
- package/dist/parser-XNKJCMMA.js +13 -0
- package/dist/parser-XVPTRWZ4.js +15 -0
- package/dist/parser-YSLNDFLV.js +22 -0
- package/dist/parser-ZGNXYFPS.js +15 -0
- package/dist/parser-ZQDQTB4X.js +20 -0
- package/dist/pert.d.ts +4 -2
- package/dist/registry-CaSw0PSH.d.ts +350 -0
- package/dist/renderer-2C6DJRYN.js +24 -0
- package/dist/renderer-5MPN7CXZ.js +19 -0
- package/dist/renderer-6EN5XXJZ.js +27 -0
- package/dist/renderer-6WRYVM5R.js +24 -0
- package/dist/renderer-7NQSTQMQ.js +16 -0
- package/dist/renderer-7ZNVOVFG.js +16 -0
- package/dist/{renderer-KQB7UGDS.js → renderer-AK2WO4EI.js} +7 -6
- package/dist/renderer-COLQFSFV.js +26 -0
- package/dist/renderer-CWEFGEIC.js +36 -0
- package/dist/renderer-D3BRNOMV.js +29 -0
- package/dist/renderer-HIFQVEJA.js +22 -0
- package/dist/renderer-JCZG6AYU.js +28 -0
- package/dist/{renderer-6RKQPNJI.js → renderer-JTCX6PCG.js} +13 -13
- package/dist/renderer-JWGQSTMR.js +37 -0
- package/dist/{renderer-3YPZHMOU.js → renderer-K7XLVPH5.js} +6 -6
- package/dist/renderer-KARQF3F3.js +22 -0
- package/dist/renderer-LVZAHRP6.js +34 -0
- package/dist/{renderer-QXGN5H3A.js → renderer-NE5W7CQP.js} +8 -8
- package/dist/renderer-QD2SJF2I.js +34 -0
- package/dist/renderer-RLMOTXZ6.js +37 -0
- package/dist/renderer-SQ54MDSA.js +26 -0
- package/dist/{renderer-UV6MI64M.js → renderer-TYHGXAVT.js} +7 -6
- package/dist/renderer-UKXW2QPE.js +23 -0
- package/dist/renderer-UPF7NRTI.js +28 -0
- package/dist/renderer-VMH6L6CP.js +24 -0
- package/dist/{renderer-GHPZMFU2.js → renderer-WCWI4I6A.js} +5 -5
- package/dist/renderer-WFSUBKUL.js +25 -0
- package/dist/renderer-WNFXYYGL.js +21 -0
- package/dist/{renderer-RGIYOTKJ.js → renderer-XTXSOK3L.js} +14 -14
- package/dist/renderer-YUKPS27O.js +24 -0
- package/dist/renderer-YUXGXGSW.js +27 -0
- package/dist/renderer-ZBTEX2JK.js +16 -0
- package/dist/renderer-radial-WF6VOUOD.js +21 -0
- package/dist/{resolver-EMTGNR3D.js → resolver-WFKZYBJ2.js} +4 -4
- package/dist/state-parser-L7DHZIQO.js +19 -0
- package/dist/state-renderer-TFEUOP4H.js +38 -0
- package/dist/{themes-32xj5ZTW.d.ts → themes-tbBkIVsn.d.ts} +2 -349
- package/docs/ai-integration.md +74 -77
- package/docs/language-reference.md +329 -290
- package/fonts/Inter-Bold.woff2 +0 -0
- package/fonts/Inter-Regular.woff2 +0 -0
- package/gallery/fixtures/boxes-and-lines-diverging.dgmo +1 -2
- package/gallery/fixtures/boxes-and-lines.dgmo +1 -1
- package/gallery/fixtures/clock.dgmo +1 -1
- package/gallery/fixtures/event-line.dgmo +1 -1
- package/gallery/fixtures/gantt-full.dgmo +1 -1
- package/gallery/fixtures/gantt-sprints.dgmo +9 -9
- package/gallery/fixtures/gantt.dgmo +1 -1
- package/gallery/fixtures/legacy-syntax-backcompat.dgmo +16 -0
- package/gallery/fixtures/state-tags.dgmo +40 -0
- package/gallery/fixtures/swimlane.dgmo +1 -1
- package/gallery/fixtures/timeline-intraday.dgmo +1 -1
- package/package.json +5 -1
- package/dist/analyzer-BJ54GIFB.js +0 -15
- package/dist/calculator-LDYQCDDY.js +0 -11
- package/dist/charts-d3-7E4B4IMW.js +0 -26
- package/dist/dgmo-router-Y2VEX46B.js +0 -86
- package/dist/dimensions-F7B5C4BJ.js +0 -22
- package/dist/flowchart-parser-MY53QWTZ.js +0 -21
- package/dist/layout-46366KBT.js +0 -10
- package/dist/layout-46N4JJYK.js +0 -17
- package/dist/layout-4DIUOX2T.js +0 -14
- package/dist/layout-AM2JWW3X.js +0 -15
- package/dist/layout-CBCLPMSG.js +0 -15
- package/dist/layout-EE6GE46Y.js +0 -17
- package/dist/layout-G23F7LDH.js +0 -9
- package/dist/layout-HYZPWAK5.js +0 -18
- package/dist/layout-MUPRALE5.js +0 -14
- package/dist/layout-YVTNOTN4.js +0 -20
- package/dist/layout-ZDOSXL5G.js +0 -19
- package/dist/parser-2Q2T4C3B.js +0 -22
- package/dist/parser-3A42DZ72.js +0 -11
- package/dist/parser-4RFTKAQX.js +0 -15
- package/dist/parser-57ILIFZ2.js +0 -20
- package/dist/parser-5A2UWU6B.js +0 -11
- package/dist/parser-6BJEXUFX.js +0 -13
- package/dist/parser-6ZKABF5S.js +0 -22
- package/dist/parser-AIMHGJRR.js +0 -19
- package/dist/parser-AZJ25OKK.js +0 -13
- package/dist/parser-B77S5SZM.js +0 -11
- package/dist/parser-BEPSWJAD.js +0 -11
- package/dist/parser-BKI42XBQ.js +0 -16
- package/dist/parser-C3D7MVXY.js +0 -11
- package/dist/parser-CDG7CHV5.js +0 -14
- package/dist/parser-CZOJ7XQ6.js +0 -15
- package/dist/parser-E2RL6JYF.js +0 -18
- package/dist/parser-FQ6GZFMR.js +0 -13
- package/dist/parser-GKLZKEIK.js +0 -13
- package/dist/parser-H6ABKHZZ.js +0 -12
- package/dist/parser-I6GGFKOQ.js +0 -12
- package/dist/parser-JA7JQ7NF.js +0 -15
- package/dist/parser-OK22AC6Y.js +0 -14
- package/dist/parser-OK2ILHRT.js +0 -16
- package/dist/parser-OUTPNJWC.js +0 -11
- package/dist/parser-PORDUX5E.js +0 -15
- package/dist/parser-SRVFR7PM.js +0 -13
- package/dist/parser-UKFFZCFJ.js +0 -14
- package/dist/parser-UMWPLORP.js +0 -18
- package/dist/parser-Z4TZV2CB.js +0 -12
- package/dist/renderer-2AUFT3E2.js +0 -24
- package/dist/renderer-2HTNBIF2.js +0 -34
- package/dist/renderer-3K3IB7D5.js +0 -22
- package/dist/renderer-3YNIWF5I.js +0 -16
- package/dist/renderer-4WR6WMVF.js +0 -26
- package/dist/renderer-66MERVQ2.js +0 -24
- package/dist/renderer-ARMJBP6C.js +0 -28
- package/dist/renderer-CO2DW7S7.js +0 -37
- package/dist/renderer-EDJ2O4S5.js +0 -34
- package/dist/renderer-F7U3MFCV.js +0 -22
- package/dist/renderer-GD2COXVL.js +0 -16
- package/dist/renderer-GQIESYEM.js +0 -25
- package/dist/renderer-HCKJDFXD.js +0 -37
- package/dist/renderer-HYGHO4SJ.js +0 -28
- package/dist/renderer-JC3RDUT7.js +0 -23
- package/dist/renderer-NKJ24TEA.js +0 -19
- package/dist/renderer-OYO67VZK.js +0 -26
- package/dist/renderer-QIWVHWZO.js +0 -15
- package/dist/renderer-QRWACQRI.js +0 -21
- package/dist/renderer-QXPP4TA2.js +0 -27
- package/dist/renderer-RHT4MHFU.js +0 -24
- package/dist/renderer-RYR3TJ46.js +0 -36
- package/dist/renderer-SRKDNDFB.js +0 -27
- package/dist/renderer-TGTUABCI.js +0 -24
- package/dist/renderer-TXJFKPOG.js +0 -29
- package/dist/renderer-radial-FWABAZHB.js +0 -21
- package/dist/state-parser-6T6CNMPX.js +0 -18
- package/dist/state-renderer-AWZ3ECAX.js +0 -34
|
@@ -8,14 +8,17 @@ import {
|
|
|
8
8
|
import {
|
|
9
9
|
FONT_FAMILY
|
|
10
10
|
} from "./chunk-6KFWC4CO.js";
|
|
11
|
-
import {
|
|
12
|
-
measureText
|
|
13
|
-
} from "./chunk-WCT3NYCV.js";
|
|
14
11
|
import {
|
|
15
12
|
contrastText,
|
|
16
13
|
mix,
|
|
17
14
|
shapeFill
|
|
18
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-JYDMBWRP.js";
|
|
16
|
+
import {
|
|
17
|
+
measureText
|
|
18
|
+
} from "./chunk-4ASYQ347.js";
|
|
19
|
+
import {
|
|
20
|
+
fillModeFromOptions
|
|
21
|
+
} from "./chunk-YJVA3QUU.js";
|
|
19
22
|
|
|
20
23
|
// src/wireframe/renderer.ts
|
|
21
24
|
import * as d3Selection from "d3-selection";
|
|
@@ -59,7 +62,7 @@ function renderWireframe(container, parsed, layout, palette, isDark, _onClickIte
|
|
|
59
62
|
isTransparent: effectiveTheme === "transparent",
|
|
60
63
|
isDark,
|
|
61
64
|
showGroupLabels: opts.showGroupLabels ?? true,
|
|
62
|
-
|
|
65
|
+
fillMode: fillModeFromOptions(parsed.options)
|
|
63
66
|
};
|
|
64
67
|
if (!ctx.isTransparent) {
|
|
65
68
|
svg.append("rect").attr("width", layout.width).attr("height", layout.height).attr("fill", palette.bg).attr("rx", 8);
|
|
@@ -443,7 +446,7 @@ function renderAlert(g, node, ctx) {
|
|
|
443
446
|
const { palette, isDark, isTransparent } = ctx;
|
|
444
447
|
const el = node.element;
|
|
445
448
|
const color = getElementSemanticColor(el, palette) || palette.accent;
|
|
446
|
-
const fill = isTransparent ? null : shapeFill(palette, color, isDark, {
|
|
449
|
+
const fill = isTransparent ? null : shapeFill(palette, color, isDark, { mode: ctx.fillMode });
|
|
447
450
|
if (fill) {
|
|
448
451
|
g.append("rect").attr("width", node.width).attr("height", node.height).attr("fill", fill).attr("rx", 4);
|
|
449
452
|
}
|
|
@@ -551,4 +554,4 @@ function renderModal(parent, node, ctx) {
|
|
|
551
554
|
export {
|
|
552
555
|
renderWireframe
|
|
553
556
|
};
|
|
554
|
-
//# sourceMappingURL=chunk-
|
|
557
|
+
//# sourceMappingURL=chunk-4ASVFYB2.js.map
|
|
@@ -88,23 +88,38 @@ var CHAR_W = {
|
|
|
88
88
|
};
|
|
89
89
|
var DEFAULT_W = 0.56;
|
|
90
90
|
var CHAR_WIDTH_RATIO = DEFAULT_W;
|
|
91
|
-
|
|
92
|
-
|
|
91
|
+
var MEASURE_CACHE = /* @__PURE__ */ new Map();
|
|
92
|
+
var MEASURE_CACHE_MAX = 1e4;
|
|
93
|
+
function extendWidth(acc, text, fontSize) {
|
|
94
|
+
let w = acc;
|
|
93
95
|
for (let i = 0; i < text.length; i++) {
|
|
94
96
|
w += (CHAR_W[text.charAt(i)] ?? DEFAULT_W) * fontSize;
|
|
95
97
|
}
|
|
96
98
|
return w;
|
|
97
99
|
}
|
|
100
|
+
function measureText(text, fontSize) {
|
|
101
|
+
const key = `${fontSize}|${text}`;
|
|
102
|
+
const cached = MEASURE_CACHE.get(key);
|
|
103
|
+
if (cached !== void 0) return cached;
|
|
104
|
+
const w = extendWidth(0, text, fontSize);
|
|
105
|
+
if (MEASURE_CACHE.size >= MEASURE_CACHE_MAX) MEASURE_CACHE.clear();
|
|
106
|
+
MEASURE_CACHE.set(key, w);
|
|
107
|
+
return w;
|
|
108
|
+
}
|
|
98
109
|
function truncateText(text, fontSize, maxWidth) {
|
|
99
110
|
if (measureText(text, fontSize) <= maxWidth) return text;
|
|
100
111
|
const ellipsis = "\u2026";
|
|
101
112
|
const ellipsisW = measureText(ellipsis, fontSize);
|
|
102
113
|
if (ellipsisW > maxWidth) return "";
|
|
114
|
+
const prefix = [0];
|
|
115
|
+
for (let i = 0; i < text.length; i++) {
|
|
116
|
+
prefix.push(extendWidth(prefix[i], text.charAt(i), fontSize));
|
|
117
|
+
}
|
|
103
118
|
let lo = 0;
|
|
104
119
|
let hi = text.length;
|
|
105
120
|
while (lo < hi) {
|
|
106
121
|
const mid = Math.ceil((lo + hi) / 2);
|
|
107
|
-
if (
|
|
122
|
+
if (prefix[mid] + ellipsisW <= maxWidth) {
|
|
108
123
|
lo = mid;
|
|
109
124
|
} else {
|
|
110
125
|
hi = mid - 1;
|
|
@@ -116,15 +131,19 @@ function wrapTextToWidth(text, fontSize, maxWidth, opts) {
|
|
|
116
131
|
const words = text.split(/\s+/).filter((w) => w.length > 0);
|
|
117
132
|
if (words.length === 0) return [""];
|
|
118
133
|
const hardBreak = opts?.hardBreak ?? false;
|
|
134
|
+
const spaceW = (CHAR_W[" "] ?? DEFAULT_W) * fontSize;
|
|
119
135
|
const lines = [];
|
|
120
136
|
let current = "";
|
|
137
|
+
let currentW = 0;
|
|
121
138
|
const pushWord = (word) => {
|
|
122
|
-
const
|
|
123
|
-
if (
|
|
124
|
-
current =
|
|
139
|
+
const testW = extendWidth(current ? currentW + spaceW : 0, word, fontSize);
|
|
140
|
+
if (testW <= maxWidth || !current) {
|
|
141
|
+
current = current ? `${current} ${word}` : word;
|
|
142
|
+
currentW = testW;
|
|
125
143
|
} else {
|
|
126
144
|
lines.push(current);
|
|
127
145
|
current = word;
|
|
146
|
+
currentW = extendWidth(0, word, fontSize);
|
|
128
147
|
}
|
|
129
148
|
};
|
|
130
149
|
for (const word of words) {
|
|
@@ -132,17 +151,23 @@ function wrapTextToWidth(text, fontSize, maxWidth, opts) {
|
|
|
132
151
|
if (current) {
|
|
133
152
|
lines.push(current);
|
|
134
153
|
current = "";
|
|
154
|
+
currentW = 0;
|
|
135
155
|
}
|
|
136
156
|
let chunk = "";
|
|
157
|
+
let chunkW = 0;
|
|
137
158
|
for (const ch of word) {
|
|
138
|
-
|
|
159
|
+
const candW = extendWidth(chunkW, ch, fontSize);
|
|
160
|
+
if (chunk && candW > maxWidth) {
|
|
139
161
|
lines.push(chunk);
|
|
140
162
|
chunk = ch;
|
|
163
|
+
chunkW = extendWidth(0, ch, fontSize);
|
|
141
164
|
} else {
|
|
142
165
|
chunk += ch;
|
|
166
|
+
chunkW = candW;
|
|
143
167
|
}
|
|
144
168
|
}
|
|
145
169
|
current = chunk;
|
|
170
|
+
currentW = chunkW;
|
|
146
171
|
continue;
|
|
147
172
|
}
|
|
148
173
|
pushWord(word);
|
|
@@ -157,4 +182,4 @@ export {
|
|
|
157
182
|
truncateText,
|
|
158
183
|
wrapTextToWidth
|
|
159
184
|
};
|
|
160
|
-
//# sourceMappingURL=chunk-
|
|
185
|
+
//# sourceMappingURL=chunk-4ASYQ347.js.map
|
|
@@ -7,10 +7,11 @@ import {
|
|
|
7
7
|
tagAttrKey,
|
|
8
8
|
validateTagGroupNames,
|
|
9
9
|
validateTagValues
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-CMVZWP32.js";
|
|
11
11
|
import {
|
|
12
12
|
TREEMAP_REGISTRY,
|
|
13
13
|
extractColor,
|
|
14
|
+
fillModeFromToken,
|
|
14
15
|
measureIndent,
|
|
15
16
|
parseFirstLine,
|
|
16
17
|
peelRampColors,
|
|
@@ -18,14 +19,14 @@ import {
|
|
|
18
19
|
stripQuotes,
|
|
19
20
|
warnUnknownMetaKeys,
|
|
20
21
|
withTagAliases
|
|
21
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-YJVA3QUU.js";
|
|
22
23
|
import {
|
|
23
24
|
emit,
|
|
24
25
|
formatDgmoError,
|
|
25
26
|
makeDgmoError,
|
|
26
27
|
makeFail,
|
|
27
28
|
suggest
|
|
28
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-4W2PE66Q.js";
|
|
29
30
|
|
|
30
31
|
// src/treemap/diagnostics.ts
|
|
31
32
|
var TREEMAP_DX = {
|
|
@@ -71,7 +72,7 @@ function parseTreemap(content, palette) {
|
|
|
71
72
|
noPercent: false,
|
|
72
73
|
noHeaders: false,
|
|
73
74
|
noLegend: false,
|
|
74
|
-
|
|
75
|
+
fillMode: void 0,
|
|
75
76
|
radial: false
|
|
76
77
|
};
|
|
77
78
|
const result = {
|
|
@@ -245,7 +246,7 @@ function parseTreemap(content, palette) {
|
|
|
245
246
|
validateTagGroupNames(result.tagGroups, pushWarning);
|
|
246
247
|
cascadeTagMetadata(result.roots, result.tagGroups);
|
|
247
248
|
}
|
|
248
|
-
result.defaultColorMode = resolveDefaultColorMode(result);
|
|
249
|
+
result.defaultColorMode = resolveDefaultColorMode(result, pushWarning);
|
|
249
250
|
if (result.roots.length === 0 && !result.error) {
|
|
250
251
|
const diag = makeDgmoError(1, "No nodes found in treemap");
|
|
251
252
|
result.diagnostics.push(diag);
|
|
@@ -279,18 +280,27 @@ function handleDirective(trimmed, options, result, pushWarning, lineNumber) {
|
|
|
279
280
|
result.hasHeat = true;
|
|
280
281
|
return true;
|
|
281
282
|
}
|
|
282
|
-
const
|
|
283
|
+
const activeTagMatch = trimmed.match(/^active-tag\s+(.+)$/i);
|
|
284
|
+
if (activeTagMatch) {
|
|
285
|
+
result.activeTag = activeTagMatch[1].trim();
|
|
286
|
+
result.activeTagLineNumber = lineNumber;
|
|
287
|
+
return true;
|
|
288
|
+
}
|
|
289
|
+
const noMatch = trimmed.match(/^no-(values?|percent|headers|legend)\s*$/i);
|
|
283
290
|
if (noMatch) {
|
|
284
291
|
const key = noMatch[1].toLowerCase();
|
|
285
|
-
if (key === "values") options.noValues = true;
|
|
292
|
+
if (key === "value" || key === "values") options.noValues = true;
|
|
286
293
|
else if (key === "percent") options.noPercent = true;
|
|
287
294
|
else if (key === "headers") options.noHeaders = true;
|
|
288
295
|
else if (key === "legend") options.noLegend = true;
|
|
289
296
|
return true;
|
|
290
297
|
}
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
298
|
+
{
|
|
299
|
+
const fm = fillModeFromToken(trimmed);
|
|
300
|
+
if (fm !== null) {
|
|
301
|
+
options.fillMode = fm === "tint" ? void 0 : fm;
|
|
302
|
+
return true;
|
|
303
|
+
}
|
|
294
304
|
}
|
|
295
305
|
if (/^radial\s*$/i.test(trimmed)) {
|
|
296
306
|
options.radial = true;
|
|
@@ -298,9 +308,27 @@ function handleDirective(trimmed, options, result, pushWarning, lineNumber) {
|
|
|
298
308
|
}
|
|
299
309
|
return false;
|
|
300
310
|
}
|
|
301
|
-
function resolveDefaultColorMode(result) {
|
|
302
|
-
|
|
311
|
+
function resolveDefaultColorMode(result, pushWarning) {
|
|
312
|
+
const at = result.activeTag?.trim();
|
|
313
|
+
if (at) {
|
|
314
|
+
const lv = at.toLowerCase();
|
|
315
|
+
if (lv === "none") return "branch";
|
|
316
|
+
const heatName = result.options.heatLabel;
|
|
317
|
+
const heatHit = heatName !== void 0 ? lv === heatName.toLowerCase() : lv === "value" || lv === "heat";
|
|
318
|
+
if (result.hasHeat && heatHit) return "heat";
|
|
319
|
+
if (result.tagGroups.some((g) => g.name.toLowerCase() === lv)) return "tag";
|
|
320
|
+
const dims = [
|
|
321
|
+
...result.tagGroups.map((g) => g.name),
|
|
322
|
+
...result.hasHeat ? [heatName ?? "Value"] : []
|
|
323
|
+
];
|
|
324
|
+
const hint = dims.length ? ` Available: ${dims.join(", ")}, none.` : " No tag groups or heat are declared.";
|
|
325
|
+
pushWarning(
|
|
326
|
+
result.activeTagLineNumber ?? 0,
|
|
327
|
+
`active-tag "${at}" does not match a declared tag group or the heat label.${hint}`
|
|
328
|
+
);
|
|
329
|
+
}
|
|
303
330
|
if (result.hasHeat) return "heat";
|
|
331
|
+
if (result.tagGroups.length > 0) return "tag";
|
|
304
332
|
return "branch";
|
|
305
333
|
}
|
|
306
334
|
function parseNodeLine(trimmed, lineNumber, counter, aliasMap, diagnostics) {
|
|
@@ -377,4 +405,4 @@ export {
|
|
|
377
405
|
TREEMAP_DIAGNOSTICS,
|
|
378
406
|
parseTreemap
|
|
379
407
|
};
|
|
380
|
-
//# sourceMappingURL=chunk-
|
|
408
|
+
//# sourceMappingURL=chunk-4K42RUGC.js.map
|
|
@@ -100,11 +100,50 @@ function pointInGeometry(geometry, lon, lat) {
|
|
|
100
100
|
}
|
|
101
101
|
return false;
|
|
102
102
|
}
|
|
103
|
+
var planarBboxCache = /* @__PURE__ */ new WeakMap();
|
|
104
|
+
function planarGeometryBbox(geometry) {
|
|
105
|
+
const g = geometry;
|
|
106
|
+
if (!g) return null;
|
|
107
|
+
const polys = g.type === "Polygon" ? [g.coordinates] : g.type === "MultiPolygon" ? g.coordinates : [];
|
|
108
|
+
let minLon = Infinity;
|
|
109
|
+
let minLat = Infinity;
|
|
110
|
+
let maxLon = -Infinity;
|
|
111
|
+
let maxLat = -Infinity;
|
|
112
|
+
let seen = false;
|
|
113
|
+
for (const rings of polys) {
|
|
114
|
+
const outer = rings[0];
|
|
115
|
+
if (!outer) continue;
|
|
116
|
+
for (const pt of outer) {
|
|
117
|
+
const x = pt[0];
|
|
118
|
+
const y = pt[1];
|
|
119
|
+
if (x < minLon) minLon = x;
|
|
120
|
+
if (x > maxLon) maxLon = x;
|
|
121
|
+
if (y < minLat) minLat = y;
|
|
122
|
+
if (y > maxLat) maxLat = y;
|
|
123
|
+
seen = true;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
return seen ? [minLon, minLat, maxLon, maxLat] : null;
|
|
127
|
+
}
|
|
128
|
+
function featurePlanarBbox(f) {
|
|
129
|
+
let bbox = planarBboxCache.get(f);
|
|
130
|
+
if (bbox === void 0) {
|
|
131
|
+
bbox = planarGeometryBbox(f.geometry);
|
|
132
|
+
planarBboxCache.set(f, bbox);
|
|
133
|
+
}
|
|
134
|
+
return bbox;
|
|
135
|
+
}
|
|
136
|
+
function bboxRejects(f, lon, lat) {
|
|
137
|
+
const b = featurePlanarBbox(f);
|
|
138
|
+
if (!b) return false;
|
|
139
|
+
return lon < b[0] - EDGE_EPS || lon > b[2] + EDGE_EPS || lat < b[1] - EDGE_EPS || lat > b[3] + EDGE_EPS;
|
|
140
|
+
}
|
|
103
141
|
function regionAt(lonLat, countries, states) {
|
|
104
142
|
const lon = lonLat[0];
|
|
105
143
|
const lat = lonLat[1];
|
|
106
144
|
let country = null;
|
|
107
145
|
for (const f of countries) {
|
|
146
|
+
if (bboxRejects(f, lon, lat)) continue;
|
|
108
147
|
if (pointInGeometry(f.geometry, lon, lat)) {
|
|
109
148
|
country = { iso: f.id, name: f.properties.name };
|
|
110
149
|
break;
|
|
@@ -113,6 +152,7 @@ function regionAt(lonLat, countries, states) {
|
|
|
113
152
|
let state = null;
|
|
114
153
|
if (country?.iso === "US" && states) {
|
|
115
154
|
for (const f of states) {
|
|
155
|
+
if (bboxRejects(f, lon, lat)) continue;
|
|
116
156
|
if (pointInGeometry(f.geometry, lon, lat)) {
|
|
117
157
|
state = { iso: f.id, name: f.properties.name };
|
|
118
158
|
break;
|
|
@@ -252,4 +292,4 @@ export {
|
|
|
252
292
|
featureBboxPrimary,
|
|
253
293
|
unionExtent
|
|
254
294
|
};
|
|
255
|
-
//# sourceMappingURL=chunk-
|
|
295
|
+
//# sourceMappingURL=chunk-4QV26TEG.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
measureText,
|
|
3
3
|
truncateText
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-4ASYQ347.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-4RGZFA7H.js.map
|
|
@@ -98,6 +98,15 @@ var METADATA_DIAGNOSTIC_CODES = {
|
|
|
98
98
|
function emptyMetadataValueMessage(key) {
|
|
99
99
|
return `Metadata key '${key}:' has no value \u2014 the pair is dropped. Provide a value or remove the key.`;
|
|
100
100
|
}
|
|
101
|
+
var TITLE_DIRECTIVE_DX = {
|
|
102
|
+
code: "E_TITLE_DIRECTIVE",
|
|
103
|
+
severity: "error",
|
|
104
|
+
chartType: null,
|
|
105
|
+
title: "title directive on a data chart",
|
|
106
|
+
message: "The `title` directive is not supported \u2014 the chart title is line 1 \u2014 remove the title directive.",
|
|
107
|
+
hint: "Put the title on the declaration line (`bar My Chart`) and delete the `title` line.",
|
|
108
|
+
example: "bar Revenue\ntitle Revenue\nQ1 100"
|
|
109
|
+
};
|
|
101
110
|
|
|
102
111
|
export {
|
|
103
112
|
makeDgmoError,
|
|
@@ -109,6 +118,7 @@ export {
|
|
|
109
118
|
NAME_DIAGNOSTIC_CODES,
|
|
110
119
|
nameMergedMessage,
|
|
111
120
|
METADATA_DIAGNOSTIC_CODES,
|
|
112
|
-
emptyMetadataValueMessage
|
|
121
|
+
emptyMetadataValueMessage,
|
|
122
|
+
TITLE_DIRECTIVE_DX
|
|
113
123
|
};
|
|
114
|
-
//# sourceMappingURL=chunk-
|
|
124
|
+
//# sourceMappingURL=chunk-4W2PE66Q.js.map
|
|
@@ -3,10 +3,10 @@ import {
|
|
|
3
3
|
layoutJourneyMap,
|
|
4
4
|
scoreToColor,
|
|
5
5
|
scoreToCurveY
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-J7HI6G3G.js";
|
|
7
7
|
import {
|
|
8
8
|
wrapNoteBody
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-UU6LUYUH.js";
|
|
10
10
|
import {
|
|
11
11
|
NOTE_BULLET_INDENT
|
|
12
12
|
} from "./chunk-5DH3KYFH.js";
|
|
@@ -21,27 +21,31 @@ import {
|
|
|
21
21
|
} from "./chunk-YYVTBZZC.js";
|
|
22
22
|
import {
|
|
23
23
|
renderIntegratedLegend
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-W5KMNC5U.js";
|
|
25
25
|
import {
|
|
26
26
|
FONT_FAMILY
|
|
27
27
|
} from "./chunk-6KFWC4CO.js";
|
|
28
|
-
import {
|
|
29
|
-
measureText,
|
|
30
|
-
truncateText,
|
|
31
|
-
wrapTextToWidth
|
|
32
|
-
} from "./chunk-WCT3NYCV.js";
|
|
33
28
|
import {
|
|
34
29
|
parseJourneyMap
|
|
35
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-VJHBSPGF.js";
|
|
36
31
|
import {
|
|
37
32
|
contrastText,
|
|
38
33
|
mix,
|
|
39
|
-
shapeFill
|
|
40
|
-
|
|
34
|
+
shapeFill,
|
|
35
|
+
themeBaseBg
|
|
36
|
+
} from "./chunk-JYDMBWRP.js";
|
|
37
|
+
import {
|
|
38
|
+
measureText,
|
|
39
|
+
truncateText,
|
|
40
|
+
wrapTextToWidth
|
|
41
|
+
} from "./chunk-4ASYQ347.js";
|
|
41
42
|
import {
|
|
42
43
|
resolveActiveTagGroup,
|
|
43
44
|
tagAttrKey
|
|
44
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-CMVZWP32.js";
|
|
46
|
+
import {
|
|
47
|
+
fillModeFromOptions
|
|
48
|
+
} from "./chunk-YJVA3QUU.js";
|
|
45
49
|
|
|
46
50
|
// src/journey-map/renderer.ts
|
|
47
51
|
import * as d3 from "d3-selection";
|
|
@@ -76,7 +80,7 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
76
80
|
const onActiveTagGroupChange = options?.onActiveTagGroupChange;
|
|
77
81
|
const collapsedPhases = options?.collapsedPhases ?? /* @__PURE__ */ new Set();
|
|
78
82
|
const onPhaseToggle = options?.onPhaseToggle;
|
|
79
|
-
const
|
|
83
|
+
const fillMode = fillModeFromOptions(parsed.options);
|
|
80
84
|
const layout = layoutJourneyMap(parsed, palette, {
|
|
81
85
|
collapsedPhases,
|
|
82
86
|
...exportDims !== void 0 && { exportDims },
|
|
@@ -131,7 +135,9 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
131
135
|
const textX = panelX + CARD_PADDING_X;
|
|
132
136
|
const clipId = "persona-clip";
|
|
133
137
|
defs.append("clipPath").attr("id", clipId).append("rect").attr("x", panelX).attr("y", panelY).attr("width", panelWidth).attr("height", panelHeight).attr("rx", CARD_RADIUS);
|
|
134
|
-
const personaFill = shapeFill(palette, personaColor, isDark, {
|
|
138
|
+
const personaFill = shapeFill(palette, personaColor, isDark, {
|
|
139
|
+
mode: fillMode
|
|
140
|
+
});
|
|
135
141
|
const onPersonaText = contrastText(
|
|
136
142
|
personaFill,
|
|
137
143
|
palette.textOnFillLight,
|
|
@@ -139,12 +145,21 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
139
145
|
);
|
|
140
146
|
personaG.append("rect").attr("x", panelX).attr("y", panelY).attr("width", panelWidth).attr("height", panelHeight).attr("rx", CARD_RADIUS).attr("fill", personaFill);
|
|
141
147
|
if (descLines.length > 0) {
|
|
142
|
-
personaG.append("line").attr("x1", panelX + 1).attr("x2", panelX + panelWidth - silhouetteZone).attr("y1", panelY + titleRowH).attr("y2", panelY + titleRowH).attr("stroke", solid ? onPersonaText : personaColor).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
|
|
148
|
+
personaG.append("line").attr("x1", panelX + 1).attr("x2", panelX + panelWidth - silhouetteZone).attr("y1", panelY + titleRowH).attr("y2", panelY + titleRowH).attr("stroke", fillMode === "solid" ? onPersonaText : personaColor).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
|
|
143
149
|
}
|
|
144
150
|
const silX = panelX + panelWidth - 32;
|
|
145
151
|
const silY = panelY + panelHeight / 2 - 6;
|
|
146
152
|
const silClip = personaG.append("g").attr("clip-path", `url(#${clipId})`);
|
|
147
|
-
renderPersonaSilhouette(
|
|
153
|
+
renderPersonaSilhouette(
|
|
154
|
+
silClip,
|
|
155
|
+
silX,
|
|
156
|
+
silY,
|
|
157
|
+
personaColor,
|
|
158
|
+
palette,
|
|
159
|
+
isDark,
|
|
160
|
+
1.2,
|
|
161
|
+
fillMode
|
|
162
|
+
);
|
|
148
163
|
personaG.append("rect").attr("x", panelX).attr("y", panelY).attr("width", panelWidth).attr("height", panelHeight).attr("rx", CARD_RADIUS).attr("fill", "none").attr("stroke", personaColor).attr("stroke-width", CARD_STROKE_WIDTH);
|
|
149
164
|
personaG.append("text").attr("x", textX).attr("y", panelY + CARD_PADDING_Y + FONT_SIZE_STEP).attr("font-size", FONT_SIZE_STEP).attr("font-weight", "500").attr("fill", onPersonaText).text(parsed.persona.name);
|
|
150
165
|
for (let li = 0; li < descLines.length; li++) {
|
|
@@ -280,7 +295,9 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
280
295
|
pt.y,
|
|
281
296
|
pt.score,
|
|
282
297
|
palette,
|
|
283
|
-
isDark
|
|
298
|
+
isDark,
|
|
299
|
+
void 0,
|
|
300
|
+
fillMode
|
|
284
301
|
);
|
|
285
302
|
addEmotionLabel(faceG, pt, palette);
|
|
286
303
|
if (step) {
|
|
@@ -313,7 +330,9 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
313
330
|
pt.y,
|
|
314
331
|
pt.score,
|
|
315
332
|
palette,
|
|
316
|
-
isDark
|
|
333
|
+
isDark,
|
|
334
|
+
void 0,
|
|
335
|
+
fillMode
|
|
317
336
|
);
|
|
318
337
|
addEmotionLabel(faceG, pt, palette);
|
|
319
338
|
if (step) {
|
|
@@ -398,7 +417,7 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
398
417
|
palette,
|
|
399
418
|
stepColor ?? palette.primary,
|
|
400
419
|
isDark,
|
|
401
|
-
{
|
|
420
|
+
{ mode: fillMode }
|
|
402
421
|
);
|
|
403
422
|
const rowStroke = stepColor ?? palette.textMuted;
|
|
404
423
|
itemG.append("rect").attr("x", listX).attr("y", itemY).attr("width", cardW).attr("height", COLLAPSED_CARD_H).attr("rx", CARD_RADIUS).attr("fill", rowFill).attr("stroke", rowStroke).attr("stroke-width", CARD_STROKE_WIDTH);
|
|
@@ -412,7 +431,8 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
412
431
|
step.score,
|
|
413
432
|
palette,
|
|
414
433
|
isDark,
|
|
415
|
-
COLLAPSED_FACE_R
|
|
434
|
+
COLLAPSED_FACE_R,
|
|
435
|
+
fillMode
|
|
416
436
|
);
|
|
417
437
|
faceG.attr("data-line-number", step.lineNumber);
|
|
418
438
|
faceG.attr("data-score", step.score);
|
|
@@ -441,7 +461,7 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
441
461
|
effectiveActiveGroup,
|
|
442
462
|
parsed.tagGroups,
|
|
443
463
|
onNavigateToLine,
|
|
444
|
-
|
|
464
|
+
fillMode
|
|
445
465
|
);
|
|
446
466
|
}
|
|
447
467
|
}
|
|
@@ -456,7 +476,7 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
456
476
|
effectiveActiveGroup,
|
|
457
477
|
parsed.tagGroups,
|
|
458
478
|
onNavigateToLine,
|
|
459
|
-
|
|
479
|
+
fillMode
|
|
460
480
|
);
|
|
461
481
|
}
|
|
462
482
|
}
|
|
@@ -530,7 +550,7 @@ function renderJourneyMap(container, parsed, palette, isDark, options) {
|
|
|
530
550
|
);
|
|
531
551
|
const by = Math.max(PADDING, fcy - FACE_HOVER_R - THOUGHT_GAP - bh);
|
|
532
552
|
const scoreColor = scoreToColor(score, palette);
|
|
533
|
-
const tintedBg = mix(scoreColor, palette.surface, 20);
|
|
553
|
+
const tintedBg = fillMode === "outline" ? themeBaseBg(palette, isDark) : mix(scoreColor, palette.surface, 20);
|
|
534
554
|
const g = overlayG.append("g").attr("class", "journey-thought-hover");
|
|
535
555
|
g.append("rect").attr("x", bx).attr("y", by).attr("width", bw).attr("height", bh).attr("rx", CARD_RADIUS).attr("fill", tintedBg).attr("stroke", scoreColor).attr("stroke-width", CARD_STROKE_WIDTH);
|
|
536
556
|
g.append("line").attr("x1", fcx).attr("y1", by + bh).attr("x2", fcx).attr("y2", fcy - FACE_HOVER_R - 1).attr("stroke", scoreColor).attr("stroke-width", CARD_STROKE_WIDTH);
|
|
@@ -624,7 +644,7 @@ function resolveStepColor(step, scoreColor, activeGroup, tagGroups, _palette) {
|
|
|
624
644
|
);
|
|
625
645
|
return entry?.color;
|
|
626
646
|
}
|
|
627
|
-
function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onNavigateToLine,
|
|
647
|
+
function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onNavigateToLine, fillMode) {
|
|
628
648
|
const stepG = parent.append("g").attr("class", "journey-step").attr("data-line-number", sl.step.lineNumber);
|
|
629
649
|
if (sl.step.score !== void 0) {
|
|
630
650
|
stepG.attr("data-score", sl.step.score);
|
|
@@ -645,7 +665,7 @@ function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onN
|
|
|
645
665
|
palette,
|
|
646
666
|
resolvedColor ?? palette.primary,
|
|
647
667
|
isDark,
|
|
648
|
-
{
|
|
668
|
+
{ mode: fillMode }
|
|
649
669
|
);
|
|
650
670
|
const cardStroke = resolvedColor ?? palette.textMuted;
|
|
651
671
|
const onCardText = contrastText(
|
|
@@ -663,7 +683,7 @@ function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onN
|
|
|
663
683
|
const cardAnnotations = sl.step.annotations;
|
|
664
684
|
const hasContent = sl.step.description || cardAnnotations.length > 0;
|
|
665
685
|
if (hasContent) {
|
|
666
|
-
stepG.append("line").attr("x1", cx).attr("y1", cy + titleBlockH).attr("x2", cx + sl.width).attr("y2", cy + titleBlockH).attr("stroke", solid ? onCardText : cardStroke).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
|
|
686
|
+
stepG.append("line").attr("x1", cx).attr("y1", cy + titleBlockH).attr("x2", cx + sl.width).attr("y2", cy + titleBlockH).attr("stroke", fillMode === "solid" ? onCardText : cardStroke).attr("stroke-opacity", 0.3).attr("stroke-width", 1);
|
|
667
687
|
}
|
|
668
688
|
let metaY = cy + titleBlockH + CARD_META_LINE_HEIGHT;
|
|
669
689
|
if (sl.step.description) {
|
|
@@ -685,7 +705,7 @@ function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onN
|
|
|
685
705
|
const annoColor = annotationColor(anno.type, palette);
|
|
686
706
|
const iconPaths = annotationIconPaths(anno.type);
|
|
687
707
|
const annoLines = wrapText(anno.text, annoTextW, FONT_SIZE_META);
|
|
688
|
-
const iconColor = solid ? onCardText : annoColor;
|
|
708
|
+
const iconColor = fillMode === "solid" ? onCardText : annoColor;
|
|
689
709
|
renderAnnotationIcon(
|
|
690
710
|
stepG,
|
|
691
711
|
cx + CARD_PADDING_X,
|
|
@@ -710,7 +730,7 @@ function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onN
|
|
|
710
730
|
const TAG_GAP = 6;
|
|
711
731
|
const stripY = cy - TAG_STRIP_HEIGHT - TAG_GAP;
|
|
712
732
|
const stripFill = shapeFill(palette, stripColor, isDark, {
|
|
713
|
-
|
|
733
|
+
mode: fillMode
|
|
714
734
|
});
|
|
715
735
|
stepG.append("rect").attr("x", cx).attr("y", stripY).attr("width", sl.width).attr("height", TAG_STRIP_HEIGHT).attr("rx", CARD_RADIUS).attr("fill", stripFill).attr("stroke", stripColor).attr("stroke-width", CARD_STROKE_WIDTH);
|
|
716
736
|
const stripTextColor = contrastText(
|
|
@@ -727,8 +747,8 @@ function renderStepCard(parent, sl, palette, isDark, activeGroup, tagGroups, onN
|
|
|
727
747
|
});
|
|
728
748
|
}
|
|
729
749
|
}
|
|
730
|
-
function renderPersonaSilhouette(parent, cx, cy, color, palette, scale = 1) {
|
|
731
|
-
const fill = mix(color, palette.bg, 70);
|
|
750
|
+
function renderPersonaSilhouette(parent, cx, cy, color, palette, isDark, scale = 1, fillMode) {
|
|
751
|
+
const fill = fillMode === "outline" ? themeBaseBg(palette, isDark) : mix(color, palette.bg, 70);
|
|
732
752
|
const stroke = color;
|
|
733
753
|
const s = scale;
|
|
734
754
|
parent.append("path").attr(
|
|
@@ -740,12 +760,12 @@ function renderPersonaSilhouette(parent, cx, cy, color, palette, scale = 1) {
|
|
|
740
760
|
`M ${cx} ${cy - 12 * s} C ${cx + 10 * s} ${cy - 12 * s}, ${cx + 9 * s} ${cy + 2 * s}, ${cx + 6 * s} ${cy + 6 * s} Q ${cx} ${cy + 9 * s}, ${cx - 6 * s} ${cy + 6 * s} C ${cx - 9 * s} ${cy + 2 * s}, ${cx - 10 * s} ${cy - 12 * s}, ${cx} ${cy - 12 * s} Z`
|
|
741
761
|
).attr("fill", fill).attr("stroke", stroke).attr("stroke-width", 1.2);
|
|
742
762
|
}
|
|
743
|
-
function renderScoreFace(parent, cx, cy, score, palette, isDark, radius) {
|
|
763
|
+
function renderScoreFace(parent, cx, cy, score, palette, isDark, radius, fillMode) {
|
|
744
764
|
const r = radius ?? FACE_RADIUS;
|
|
745
765
|
const color = scoreToColor(score, palette);
|
|
746
766
|
const g = parent.append("g").attr("class", "journey-face").attr("data-cx", cx).attr("data-cy", cy);
|
|
747
767
|
const iconG = g.append("g").attr("class", "journey-face-icon");
|
|
748
|
-
const faceFill = shapeFill(palette, color, isDark);
|
|
768
|
+
const faceFill = fillMode === "outline" ? shapeFill(palette, color, isDark, { mode: "outline" }) : shapeFill(palette, color, isDark);
|
|
749
769
|
iconG.append("circle").attr("cx", cx).attr("cy", cy).attr("r", r + 1).attr("fill", palette.bg);
|
|
750
770
|
iconG.append("circle").attr("cx", cx).attr("cy", cy).attr("r", r).attr("fill", faceFill).attr("stroke", color).attr("stroke-width", 2);
|
|
751
771
|
const eyeColor = color;
|
|
@@ -848,4 +868,4 @@ export {
|
|
|
848
868
|
renderJourneyMap,
|
|
849
869
|
renderJourneyMapForExport
|
|
850
870
|
};
|
|
851
|
-
//# sourceMappingURL=chunk-
|
|
871
|
+
//# sourceMappingURL=chunk-4WGMGKCZ.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-6EK55ART.js";
|
|
4
4
|
import {
|
|
5
5
|
noteBoxSize
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-UU6LUYUH.js";
|
|
7
7
|
|
|
8
8
|
// src/utils/notes/build.ts
|
|
9
9
|
function buildPlacedNotes(anchors, noteByNode, direction, collapsedNotes) {
|
|
@@ -70,4 +70,4 @@ function buildPlacedNotes(anchors, noteByNode, direction, collapsedNotes) {
|
|
|
70
70
|
export {
|
|
71
71
|
buildPlacedNotes
|
|
72
72
|
};
|
|
73
|
-
//# sourceMappingURL=chunk-
|
|
73
|
+
//# sourceMappingURL=chunk-5HWPEYWB.js.map
|