@expressivecss/expressive 0.15.0 → 0.16.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/CHANGELOG.md +1502 -1
- package/README.md +9 -8
- package/dist/css/expressive.css +19247 -11923
- package/dist/css/expressive.css.map +1 -1
- package/dist/css/expressive.min.css +1 -1
- package/dist/css/expressive.min.css.map +1 -1
- package/dist/fonts/LICENSE-noto-sans-arabic +93 -0
- package/dist/fonts/LICENSE-noto-sans-hebrew +93 -0
- package/dist/fonts/LICENSE-noto-sans-thai +93 -0
- package/dist/fonts/material-symbols-outlined.woff2 +0 -0
- package/dist/fonts/material-symbols-rounded.woff2 +0 -0
- package/dist/fonts/material-symbols-sharp.woff2 +0 -0
- package/dist/fonts/noto-sans-arabic-arabic-400.woff2 +0 -0
- package/dist/fonts/noto-sans-arabic-arabic-500.woff2 +0 -0
- package/dist/fonts/noto-sans-arabic-arabic-700.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-400.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-500.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-700.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-ext-400.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-ext-500.woff2 +0 -0
- package/dist/fonts/noto-sans-cyrillic-ext-700.woff2 +0 -0
- package/dist/fonts/noto-sans-devanagari-400.woff2 +0 -0
- package/dist/fonts/noto-sans-devanagari-500.woff2 +0 -0
- package/dist/fonts/noto-sans-devanagari-700.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-400.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-500.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-700.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-ext-400.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-ext-500.woff2 +0 -0
- package/dist/fonts/noto-sans-greek-ext-700.woff2 +0 -0
- package/dist/fonts/noto-sans-hebrew-hebrew-400.woff2 +0 -0
- package/dist/fonts/noto-sans-hebrew-hebrew-500.woff2 +0 -0
- package/dist/fonts/noto-sans-hebrew-hebrew-700.woff2 +0 -0
- package/dist/fonts/noto-sans-latin-700.woff2 +0 -0
- package/dist/fonts/noto-sans-latin-ext-400.woff2 +0 -0
- package/dist/fonts/noto-sans-latin-ext-500.woff2 +0 -0
- package/dist/fonts/noto-sans-latin-ext-700.woff2 +0 -0
- package/dist/fonts/noto-sans-thai-thai-400.woff2 +0 -0
- package/dist/fonts/noto-sans-thai-thai-500.woff2 +0 -0
- package/dist/fonts/noto-sans-thai-thai-700.woff2 +0 -0
- package/dist/fonts/noto-sans-vietnamese-400.woff2 +0 -0
- package/dist/fonts/noto-sans-vietnamese-500.woff2 +0 -0
- package/dist/fonts/noto-sans-vietnamese-700.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-400.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-500.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-700.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-ext-400.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-ext-500.woff2 +0 -0
- package/dist/fonts/roboto-cyrillic-ext-700.woff2 +0 -0
- package/dist/fonts/roboto-greek-400.woff2 +0 -0
- package/dist/fonts/roboto-greek-500.woff2 +0 -0
- package/dist/fonts/roboto-greek-700.woff2 +0 -0
- package/dist/fonts/roboto-greek-ext-400.woff2 +0 -0
- package/dist/fonts/roboto-greek-ext-500.woff2 +0 -0
- package/dist/fonts/roboto-greek-ext-700.woff2 +0 -0
- package/dist/fonts/roboto-latin-700.woff2 +0 -0
- package/dist/fonts/roboto-latin-ext-400.woff2 +0 -0
- package/dist/fonts/roboto-latin-ext-500.woff2 +0 -0
- package/dist/fonts/roboto-latin-ext-700.woff2 +0 -0
- package/dist/fonts/roboto-vietnamese-400.woff2 +0 -0
- package/dist/fonts/roboto-vietnamese-500.woff2 +0 -0
- package/dist/fonts/roboto-vietnamese-700.woff2 +0 -0
- package/dist/js/chunks/chunk-2CS6TITK.mjs +219 -0
- package/dist/js/chunks/chunk-2CS6TITK.mjs.map +7 -0
- package/dist/js/chunks/chunk-2RLBDFH4.mjs +108 -0
- package/dist/js/chunks/chunk-2RLBDFH4.mjs.map +7 -0
- package/dist/js/chunks/chunk-3L3QIYLC.mjs +85 -0
- package/dist/js/chunks/chunk-3L3QIYLC.mjs.map +7 -0
- package/dist/js/chunks/chunk-4EWGD4V2.mjs +75 -0
- package/dist/js/chunks/chunk-4EWGD4V2.mjs.map +7 -0
- package/dist/js/chunks/chunk-4IKVPCSU.mjs +7 -0
- package/dist/js/chunks/chunk-4IKVPCSU.mjs.map +7 -0
- package/dist/js/chunks/chunk-4PIXLDNJ.mjs +127 -0
- package/dist/js/chunks/chunk-4PIXLDNJ.mjs.map +7 -0
- package/dist/js/chunks/{chunk-KVJAVDBC.mjs → chunk-4QUCNFSD.mjs} +64 -113
- package/dist/js/chunks/chunk-4QUCNFSD.mjs.map +7 -0
- package/dist/js/chunks/{chunk-UETTGDLI.mjs → chunk-4TRZ2AER.mjs} +35 -41
- package/dist/js/chunks/chunk-4TRZ2AER.mjs.map +7 -0
- package/dist/js/chunks/{chunk-C6CHEWYP.mjs → chunk-5KIHWJI2.mjs} +40 -26
- package/dist/js/chunks/chunk-5KIHWJI2.mjs.map +7 -0
- package/dist/js/chunks/{chunk-L27Q6ZMI.mjs → chunk-67ZPPKXS.mjs} +20 -33
- package/dist/js/chunks/chunk-67ZPPKXS.mjs.map +7 -0
- package/dist/js/chunks/{chunk-XAEAEHIX.mjs → chunk-6FSEUFVW.mjs} +39 -26
- package/dist/js/chunks/chunk-6FSEUFVW.mjs.map +7 -0
- package/dist/js/chunks/chunk-752ADW4M.mjs +225 -0
- package/dist/js/chunks/chunk-752ADW4M.mjs.map +7 -0
- package/dist/js/chunks/{chunk-CK2XCICY.mjs → chunk-75E5EDJF.mjs} +3 -11
- package/dist/js/chunks/chunk-75E5EDJF.mjs.map +7 -0
- package/dist/js/chunks/{chunk-KHXZ2A4K.mjs → chunk-7NLUI3RR.mjs} +139 -66
- package/dist/js/chunks/chunk-7NLUI3RR.mjs.map +7 -0
- package/dist/js/chunks/chunk-7W7TV6NY.mjs +108 -0
- package/dist/js/chunks/chunk-7W7TV6NY.mjs.map +7 -0
- package/dist/js/chunks/chunk-7YQBHTK3.mjs +225 -0
- package/dist/js/chunks/chunk-7YQBHTK3.mjs.map +7 -0
- package/dist/js/chunks/chunk-7YZ5CN3V.mjs +33 -0
- package/dist/js/chunks/chunk-7YZ5CN3V.mjs.map +7 -0
- package/dist/js/chunks/chunk-AI73GJKG.mjs +28 -0
- package/dist/js/chunks/chunk-AI73GJKG.mjs.map +7 -0
- package/dist/js/chunks/{chunk-LQWUDNHZ.mjs → chunk-ANKFWNWT.mjs} +21 -45
- package/dist/js/chunks/chunk-ANKFWNWT.mjs.map +7 -0
- package/dist/js/chunks/{chunk-5CEAOLUA.mjs → chunk-B7DQFHA5.mjs} +30 -47
- package/dist/js/chunks/chunk-B7DQFHA5.mjs.map +7 -0
- package/dist/js/chunks/chunk-BIGU5RCJ.mjs +153 -0
- package/dist/js/chunks/chunk-BIGU5RCJ.mjs.map +7 -0
- package/dist/js/chunks/{chunk-VGNYF6FB.mjs → chunk-BPF3I2MN.mjs} +109 -24
- package/dist/js/chunks/chunk-BPF3I2MN.mjs.map +7 -0
- package/dist/js/chunks/chunk-CMGXGYUC.mjs +74 -0
- package/dist/js/chunks/chunk-CMGXGYUC.mjs.map +7 -0
- package/dist/js/chunks/{chunk-NUHMOAOY.mjs → chunk-CSYWKEK3.mjs} +310 -196
- package/dist/js/chunks/chunk-CSYWKEK3.mjs.map +7 -0
- package/dist/js/chunks/chunk-CZSQHXEV.mjs +227 -0
- package/dist/js/chunks/chunk-CZSQHXEV.mjs.map +7 -0
- package/dist/js/chunks/chunk-DZYVU75J.mjs +121 -0
- package/dist/js/chunks/chunk-DZYVU75J.mjs.map +7 -0
- package/dist/js/chunks/{chunk-74MXKKLN.mjs → chunk-EC26RU2D.mjs} +11 -29
- package/dist/js/chunks/chunk-EC26RU2D.mjs.map +7 -0
- package/dist/js/chunks/{chunk-WDK4T63U.mjs → chunk-EVCVFEV3.mjs} +235 -146
- package/dist/js/chunks/chunk-EVCVFEV3.mjs.map +7 -0
- package/dist/js/chunks/chunk-FCNF4GRJ.mjs +445 -0
- package/dist/js/chunks/chunk-FCNF4GRJ.mjs.map +7 -0
- package/dist/js/chunks/chunk-GCWWEZKO.mjs +342 -0
- package/dist/js/chunks/chunk-GCWWEZKO.mjs.map +7 -0
- package/dist/js/chunks/chunk-GNRSYMVH.mjs +1 -0
- package/dist/js/chunks/chunk-GVZQH2H5.mjs +54 -0
- package/dist/js/chunks/chunk-GVZQH2H5.mjs.map +7 -0
- package/dist/js/chunks/chunk-GWZ76SR4.mjs +435 -0
- package/dist/js/chunks/chunk-GWZ76SR4.mjs.map +7 -0
- package/dist/js/chunks/{chunk-PDG64UHF.mjs → chunk-ILDRRG7T.mjs} +21 -23
- package/dist/js/chunks/chunk-ILDRRG7T.mjs.map +7 -0
- package/dist/js/chunks/chunk-INLZWHLY.mjs +80 -0
- package/dist/js/chunks/chunk-INLZWHLY.mjs.map +7 -0
- package/dist/js/chunks/chunk-JUKBBN6P.mjs +175 -0
- package/dist/js/chunks/chunk-JUKBBN6P.mjs.map +7 -0
- package/dist/js/chunks/chunk-KYIEG4U3.mjs +730 -0
- package/dist/js/chunks/chunk-KYIEG4U3.mjs.map +7 -0
- package/dist/js/chunks/{chunk-BGZLF6JZ.mjs → chunk-KZPSAXIU.mjs} +142 -32
- package/dist/js/chunks/chunk-KZPSAXIU.mjs.map +7 -0
- package/dist/js/chunks/chunk-LDXCC2L3.mjs +438 -0
- package/dist/js/chunks/chunk-LDXCC2L3.mjs.map +7 -0
- package/dist/js/chunks/chunk-NAC72P7R.mjs +137 -0
- package/dist/js/chunks/chunk-NAC72P7R.mjs.map +7 -0
- package/dist/js/chunks/chunk-NBJAUGPP.mjs +244 -0
- package/dist/js/chunks/chunk-NBJAUGPP.mjs.map +7 -0
- package/dist/js/chunks/chunk-NNHVANQA.mjs +113 -0
- package/dist/js/chunks/chunk-NNHVANQA.mjs.map +7 -0
- package/dist/js/chunks/chunk-NVQ5EHCU.mjs +376 -0
- package/dist/js/chunks/chunk-NVQ5EHCU.mjs.map +7 -0
- package/dist/js/chunks/{chunk-DXGRXYYL.mjs → chunk-OP43LLIC.mjs} +28 -45
- package/dist/js/chunks/chunk-OP43LLIC.mjs.map +7 -0
- package/dist/js/chunks/chunk-OUCHKSAW.mjs +63 -0
- package/dist/js/chunks/chunk-OUCHKSAW.mjs.map +7 -0
- package/dist/js/chunks/{chunk-TSZYSW7F.mjs → chunk-OYNUDOHR.mjs} +19 -47
- package/dist/js/chunks/chunk-OYNUDOHR.mjs.map +7 -0
- package/dist/js/chunks/{chunk-UAZSDUVP.mjs → chunk-P6DRQ6KS.mjs} +36 -30
- package/dist/js/chunks/chunk-P6DRQ6KS.mjs.map +7 -0
- package/dist/js/chunks/chunk-PA7NU5AK.mjs +99 -0
- package/dist/js/chunks/chunk-PA7NU5AK.mjs.map +7 -0
- package/dist/js/chunks/chunk-QACZ6TUP.mjs +224 -0
- package/dist/js/chunks/chunk-QACZ6TUP.mjs.map +7 -0
- package/dist/js/chunks/{chunk-GJL6GCIU.mjs → chunk-QXKWVHBD.mjs} +265 -161
- package/dist/js/chunks/chunk-QXKWVHBD.mjs.map +7 -0
- package/dist/js/chunks/{chunk-X4ISMKE2.mjs → chunk-ROH2HDB4.mjs} +7 -6
- package/dist/js/chunks/chunk-ROH2HDB4.mjs.map +7 -0
- package/dist/js/chunks/chunk-S23RJ3XY.mjs +86 -0
- package/dist/js/chunks/chunk-S23RJ3XY.mjs.map +7 -0
- package/dist/js/chunks/{chunk-SMY7GJSS.mjs → chunk-SPPHF7YZ.mjs} +36 -29
- package/dist/js/chunks/chunk-SPPHF7YZ.mjs.map +7 -0
- package/dist/js/chunks/chunk-T3BNSRP3.mjs +152 -0
- package/dist/js/chunks/chunk-T3BNSRP3.mjs.map +7 -0
- package/dist/js/chunks/chunk-TFABTUAZ.mjs +108 -0
- package/dist/js/chunks/chunk-TFABTUAZ.mjs.map +7 -0
- package/dist/js/chunks/chunk-U4B3VHFS.mjs +507 -0
- package/dist/js/chunks/chunk-U4B3VHFS.mjs.map +7 -0
- package/dist/js/chunks/chunk-UGJHCHXG.mjs +341 -0
- package/dist/js/chunks/chunk-UGJHCHXG.mjs.map +7 -0
- package/dist/js/chunks/chunk-VFV75DHF.mjs +70 -0
- package/dist/js/chunks/chunk-VFV75DHF.mjs.map +7 -0
- package/dist/js/chunks/{chunk-ZX6M7SWO.mjs → chunk-VGY4M57S.mjs} +266 -120
- package/dist/js/chunks/chunk-VGY4M57S.mjs.map +7 -0
- package/dist/js/chunks/chunk-VH4BMAZS.mjs +167 -0
- package/dist/js/chunks/chunk-VH4BMAZS.mjs.map +7 -0
- package/dist/js/chunks/chunk-VJVQIXHC.mjs +123 -0
- package/dist/js/chunks/chunk-VJVQIXHC.mjs.map +7 -0
- package/dist/js/chunks/{chunk-SFI2U4YW.mjs → chunk-VMY55K2X.mjs} +76 -109
- package/dist/js/chunks/chunk-VMY55K2X.mjs.map +7 -0
- package/dist/js/chunks/{chunk-KUFHW3DS.mjs → chunk-VR3L2WN5.mjs} +11 -17
- package/dist/js/chunks/chunk-VR3L2WN5.mjs.map +7 -0
- package/dist/js/chunks/chunk-W6FAL3TI.mjs +38 -0
- package/dist/js/chunks/chunk-W6FAL3TI.mjs.map +7 -0
- package/dist/js/chunks/chunk-WU7XJ4RR.mjs +450 -0
- package/dist/js/chunks/chunk-WU7XJ4RR.mjs.map +7 -0
- package/dist/js/chunks/chunk-X7SDA2J5.mjs +116 -0
- package/dist/js/chunks/chunk-X7SDA2J5.mjs.map +7 -0
- package/dist/js/chunks/chunk-Y6H2X7ZC.mjs +209 -0
- package/dist/js/chunks/chunk-Y6H2X7ZC.mjs.map +7 -0
- package/dist/js/chunks/chunk-Y6TLRA3U.mjs +129 -0
- package/dist/js/chunks/chunk-Y6TLRA3U.mjs.map +7 -0
- package/dist/js/chunks/chunk-Z4GICXR2.mjs +190 -0
- package/dist/js/chunks/chunk-Z4GICXR2.mjs.map +7 -0
- package/dist/js/chunks/chunk-Z4OARDZ7.mjs +442 -0
- package/dist/js/chunks/chunk-Z4OARDZ7.mjs.map +7 -0
- package/dist/js/chunks/{chunk-FM5CZOUB.mjs → chunk-ZJNLAGY5.mjs} +19 -30
- package/dist/js/chunks/chunk-ZJNLAGY5.mjs.map +7 -0
- package/dist/js/chunks/chunk-ZKWUWBUB.mjs +81 -0
- package/dist/js/chunks/chunk-ZKWUWBUB.mjs.map +7 -0
- package/dist/js/chunks/chunk-ZM3XBHWV.mjs +746 -0
- package/dist/js/chunks/chunk-ZM3XBHWV.mjs.map +7 -0
- package/dist/js/chunks/chunk-ZO6ZLHFF.mjs +48 -0
- package/dist/js/chunks/chunk-ZO6ZLHFF.mjs.map +7 -0
- package/dist/js/chunks/chunk-ZVLOUDIJ.mjs +251 -0
- package/dist/js/chunks/chunk-ZVLOUDIJ.mjs.map +7 -0
- package/dist/js/expressive.cjs +10613 -4327
- package/dist/js/expressive.cjs.map +4 -4
- package/dist/js/expressive.js +10613 -4327
- package/dist/js/expressive.js.map +4 -4
- package/dist/js/expressive.min.js +23 -22
- package/dist/js/expressive.min.js.map +4 -4
- package/dist/js/expressive.mjs +182 -71
- package/dist/js/expressive.mjs.map +2 -2
- package/dist/js/internal/behaviors/bottomSheets.mjs +4 -3
- package/dist/js/internal/behaviors/copy.mjs +9 -0
- package/dist/js/internal/behaviors/copy.mjs.map +7 -0
- package/dist/js/internal/behaviors/dataTables.mjs +10 -0
- package/dist/js/internal/behaviors/dataTables.mjs.map +7 -0
- package/dist/js/internal/behaviors/dialogs.mjs +2 -2
- package/dist/js/internal/behaviors/forms.mjs +2 -2
- package/dist/js/internal/behaviors/imageCompare.mjs +8 -0
- package/dist/js/internal/behaviors/imageCompare.mjs.map +7 -0
- package/dist/js/internal/behaviors/lists.mjs +8 -0
- package/dist/js/internal/behaviors/lists.mjs.map +7 -0
- package/dist/js/internal/behaviors/paneResize.mjs +8 -0
- package/dist/js/internal/behaviors/paneResize.mjs.map +7 -0
- package/dist/js/internal/behaviors/sheetDrag.mjs +7 -2
- package/dist/js/internal/behaviors/sideSheets.mjs +4 -3
- package/dist/js/internal/behaviors/sortable.mjs +8 -0
- package/dist/js/internal/behaviors/sortable.mjs.map +7 -0
- package/dist/js/internal/behaviors/theme.mjs +8 -0
- package/dist/js/internal/behaviors/theme.mjs.map +7 -0
- package/dist/js/internal/behaviors/tour.mjs +8 -0
- package/dist/js/internal/behaviors/tour.mjs.map +7 -0
- package/dist/js/internal/behaviors/transferList.mjs +8 -0
- package/dist/js/internal/behaviors/transferList.mjs.map +7 -0
- package/dist/js/internal/components/appBar.mjs +3 -2
- package/dist/js/internal/components/autocomplete.mjs +4 -4
- package/dist/js/internal/components/backToTop.mjs +9 -0
- package/dist/js/internal/components/backToTop.mjs.map +7 -0
- package/dist/js/internal/components/barChart.mjs +5 -4
- package/dist/js/internal/components/buttonGroup.mjs +3 -2
- package/dist/js/internal/components/buttons.mjs +3 -3
- package/dist/js/internal/components/cards.mjs +3 -3
- package/dist/js/internal/components/carousel.mjs +3 -3
- package/dist/js/internal/components/cascader.mjs +10 -0
- package/dist/js/internal/components/cascader.mjs.map +7 -0
- package/dist/js/internal/components/characterCounter.mjs +3 -2
- package/dist/js/internal/components/chips.mjs +6 -5
- package/dist/js/internal/components/colorPicker.mjs +9 -0
- package/dist/js/internal/components/colorPicker.mjs.map +7 -0
- package/dist/js/internal/components/columnChart.mjs +4 -3
- package/dist/js/internal/components/commandPalette.mjs +3 -3
- package/dist/js/internal/components/confetti.mjs +3 -2
- package/dist/js/internal/components/currencyInput.mjs +9 -0
- package/dist/js/internal/components/currencyInput.mjs.map +7 -0
- package/dist/js/internal/components/datepicker.mjs +11 -8
- package/dist/js/internal/components/expandingCard.mjs +3 -3
- package/dist/js/internal/components/funnelChart.mjs +10 -0
- package/dist/js/internal/components/funnelChart.mjs.map +7 -0
- package/dist/js/internal/components/heatmapChart.mjs +4 -3
- package/dist/js/internal/components/hoverCard.mjs +9 -0
- package/dist/js/internal/components/hoverCard.mjs.map +7 -0
- package/dist/js/internal/components/index.mjs +131 -66
- package/dist/js/internal/components/inputMask.mjs +9 -0
- package/dist/js/internal/components/inputMask.mjs.map +7 -0
- package/dist/js/internal/components/keypad.mjs +3 -3
- package/dist/js/internal/components/lightbox.mjs +3 -3
- package/dist/js/internal/components/lineChart.mjs +25 -4
- package/dist/js/internal/components/loadingOverlay.mjs +9 -0
- package/dist/js/internal/components/loadingOverlay.mjs.map +7 -0
- package/dist/js/internal/components/mapView.mjs +3 -3
- package/dist/js/internal/components/menu.mjs +3 -3
- package/dist/js/internal/components/menubar.mjs +10 -0
- package/dist/js/internal/components/menubar.mjs.map +7 -0
- package/dist/js/internal/components/messageScroller.mjs +3 -3
- package/dist/js/internal/components/mixedChart.mjs +5 -4
- package/dist/js/internal/components/navigationRail.mjs +3 -2
- package/dist/js/internal/components/particles.mjs +3 -2
- package/dist/js/internal/components/pieChart.mjs +4 -3
- package/dist/js/internal/components/pullToRefresh.mjs +9 -0
- package/dist/js/internal/components/pullToRefresh.mjs.map +7 -0
- package/dist/js/internal/components/questionnaire.mjs +3 -3
- package/dist/js/internal/components/radarChart.mjs +4 -3
- package/dist/js/internal/components/radialChart.mjs +4 -3
- package/dist/js/internal/components/registry.mjs +59 -41
- package/dist/js/internal/components/richTextEditor.mjs +3 -3
- package/dist/js/internal/components/sankeyChart.mjs +10 -0
- package/dist/js/internal/components/sankeyChart.mjs.map +7 -0
- package/dist/js/internal/components/scatterChart.mjs +10 -0
- package/dist/js/internal/components/scatterChart.mjs.map +7 -0
- package/dist/js/internal/components/scrollspy.mjs +3 -2
- package/dist/js/internal/components/select.mjs +4 -4
- package/dist/js/internal/components/showMore.mjs +9 -0
- package/dist/js/internal/components/showMore.mjs.map +7 -0
- package/dist/js/internal/components/slider.mjs +3 -3
- package/dist/js/internal/components/snackbar.mjs +2 -2
- package/dist/js/internal/components/swipeActions.mjs +9 -0
- package/dist/js/internal/components/swipeActions.mjs.map +7 -0
- package/dist/js/internal/components/tabs.mjs +3 -4
- package/dist/js/internal/components/timepicker.mjs +5 -4
- package/dist/js/internal/components/tooltip.mjs +3 -3
- package/dist/js/internal/components/treeSelect.mjs +13 -0
- package/dist/js/internal/components/treeSelect.mjs.map +7 -0
- package/dist/js/internal/components/treemapChart.mjs +10 -0
- package/dist/js/internal/components/treemapChart.mjs.map +7 -0
- package/dist/js/internal/core/component.mjs +2 -1
- package/dist/js/internal/core/formControl.mjs +12 -0
- package/dist/js/internal/core/formControl.mjs.map +7 -0
- package/dist/js/internal/core/spring.mjs +11 -0
- package/dist/js/internal/core/spring.mjs.map +7 -0
- package/dist/js/internal/core/utils.mjs +11 -3
- package/dist/js/internal/plugins/dockedDisplayPlugin.mjs +2 -2
- package/dist/js/internal/plugins/modalDisplayPlugin.mjs +13 -0
- package/dist/js/internal/plugins/modalDisplayPlugin.mjs.map +7 -0
- package/dist/js/modular.mjs +173 -71
- package/dist/types/behaviors/bottomSheets.d.ts +19 -3
- package/dist/types/behaviors/copy.d.ts +18 -0
- package/dist/types/behaviors/dataTables.d.ts +129 -0
- package/dist/types/behaviors/dialogs.d.ts +27 -1
- package/dist/types/behaviors/forms.d.ts +68 -2
- package/dist/types/behaviors/imageCompare.d.ts +12 -0
- package/dist/types/behaviors/lists.d.ts +12 -0
- package/dist/types/behaviors/paneResize.d.ts +29 -0
- package/dist/types/behaviors/sheetDrag.d.ts +18 -0
- package/dist/types/behaviors/sideSheets.d.ts +1 -1
- package/dist/types/behaviors/sortable.d.ts +28 -0
- package/dist/types/behaviors/theme.d.ts +22 -0
- package/dist/types/behaviors/tour.d.ts +36 -0
- package/dist/types/behaviors/transferList.d.ts +51 -0
- package/dist/types/components/appBar.d.ts +5 -6
- package/dist/types/components/autocomplete.d.ts +91 -17
- package/dist/types/components/backToTop.d.ts +36 -0
- package/dist/types/components/barChart.d.ts +3 -6
- package/dist/types/components/buttonGroup.d.ts +2 -4
- package/dist/types/components/buttons.d.ts +5 -5
- package/dist/types/components/cards.d.ts +3 -16
- package/dist/types/components/carousel.d.ts +9 -15
- package/dist/types/components/cascader.d.ts +130 -0
- package/dist/types/components/characterCounter.d.ts +2 -15
- package/dist/types/components/chips.d.ts +65 -19
- package/dist/types/components/colorPicker.d.ts +42 -0
- package/dist/types/components/columnChart.d.ts +23 -10
- package/dist/types/components/commandPalette.d.ts +11 -16
- package/dist/types/components/confetti.d.ts +2 -4
- package/dist/types/components/currencyInput.d.ts +59 -0
- package/dist/types/components/datepicker.d.ts +56 -32
- package/dist/types/components/expandingCard.d.ts +4 -6
- package/dist/types/components/funnelChart.d.ts +38 -0
- package/dist/types/components/heatmapChart.d.ts +39 -8
- package/dist/types/components/hoverCard.d.ts +58 -0
- package/dist/types/components/index.d.ts +16 -1
- package/dist/types/components/inputMask.d.ts +30 -0
- package/dist/types/components/keypad.d.ts +38 -6
- package/dist/types/components/lightbox.d.ts +14 -20
- package/dist/types/components/lineChart.d.ts +172 -10
- package/dist/types/components/loadingOverlay.d.ts +42 -0
- package/dist/types/components/mapView.d.ts +26 -17
- package/dist/types/components/menu.d.ts +60 -22
- package/dist/types/components/menubar.d.ts +37 -0
- package/dist/types/components/messageScroller.d.ts +2 -14
- package/dist/types/components/mixedChart.d.ts +15 -6
- package/dist/types/components/navigationRail.d.ts +16 -5
- package/dist/types/components/particles.d.ts +8 -4
- package/dist/types/components/pieChart.d.ts +32 -7
- package/dist/types/components/pullToRefresh.d.ts +80 -0
- package/dist/types/components/questionnaire.d.ts +58 -16
- package/dist/types/components/radarChart.d.ts +10 -6
- package/dist/types/components/radialChart.d.ts +58 -7
- package/dist/types/components/registry.d.ts +73 -3
- package/dist/types/components/richTextEditor.d.ts +6 -14
- package/dist/types/components/sankeyChart.d.ts +72 -0
- package/dist/types/components/scatterChart.d.ts +102 -0
- package/dist/types/components/scrollspy.d.ts +3 -5
- package/dist/types/components/select.d.ts +43 -30
- package/dist/types/components/showMore.d.ts +51 -0
- package/dist/types/components/slider.d.ts +3 -15
- package/dist/types/components/snackbar.d.ts +61 -0
- package/dist/types/components/swipeActions.d.ts +81 -0
- package/dist/types/components/tabs.d.ts +89 -27
- package/dist/types/components/timepicker.d.ts +113 -21
- package/dist/types/components/tooltip.d.ts +56 -20
- package/dist/types/components/treeSelect.d.ts +106 -0
- package/dist/types/components/treemapChart.d.ts +56 -0
- package/dist/types/core/component.d.ts +43 -25
- package/dist/types/core/formControl.d.ts +21 -0
- package/dist/types/core/spring.d.ts +20 -0
- package/dist/types/core/utils.d.ts +85 -72
- package/dist/types/modular.d.ts +33 -1
- package/dist/types/plugins/dockedDisplayPlugin.d.ts +10 -8
- package/dist/types/plugins/modalDisplayPlugin.d.ts +32 -0
- package/package.json +10 -8
- package/src/sass/README.md +27 -18
- package/src/sass/abstracts/_elevation.scss +13 -7
- package/src/sass/abstracts/_index.scss +1 -0
- package/src/sass/abstracts/_mixins.scss +422 -36
- package/src/sass/abstracts/_spring.scss +63 -0
- package/src/sass/abstracts/_variables.scss +39 -21
- package/src/sass/base/_fonts.scss +61 -48
- package/src/sass/base/_global.scss +104 -24
- package/src/sass/base/_index.scss +2 -0
- package/src/sass/base/_normalize.scss +59 -114
- package/src/sass/base/_print.scss +21 -0
- package/src/sass/base/_prose.scss +68 -0
- package/src/sass/base/_typography.scss +9 -5
- package/src/sass/components/_accordion.scss +9 -16
- package/src/sass/components/_alert.scss +102 -0
- package/src/sass/components/_aura.scss +8 -3
- package/src/sass/components/_avatar.scss +3 -3
- package/src/sass/components/_back-to-top.scss +38 -0
- package/src/sass/components/_badges.scss +6 -5
- package/src/sass/components/_bar-chart.scss +41 -19
- package/src/sass/components/_bottom-sheet.scss +44 -16
- package/src/sass/components/_breadcrumb.scss +8 -1
- package/src/sass/components/_button-groups.scss +15 -25
- package/src/sass/components/_buttons.scss +156 -63
- package/src/sass/components/_calendar.scss +246 -0
- package/src/sass/components/_cards.scss +36 -44
- package/src/sass/components/_carousel.scss +27 -103
- package/src/sass/components/_cascader.scss +142 -0
- package/src/sass/components/_chips.scss +36 -46
- package/src/sass/components/_column-chart.scss +19 -12
- package/src/sass/components/_command-palette.scss +4 -7
- package/src/sass/components/_confetti.scss +0 -2
- package/src/sass/components/_countdown.scss +1 -1
- package/src/sass/components/_data-table.scss +162 -25
- package/src/sass/components/_datepicker.scss +54 -40
- package/src/sass/components/_description-list.scss +85 -0
- package/src/sass/components/_dialog.scss +42 -41
- package/src/sass/components/_docked-display.scss +1 -3
- package/src/sass/components/_drag-handle.scss +16 -20
- package/src/sass/components/_expanding-card.scss +20 -9
- package/src/sass/components/_fab-menu.scss +44 -32
- package/src/sass/components/_funnel-chart.scss +124 -0
- package/src/sass/components/_heatmap-chart.scss +111 -22
- package/src/sass/components/_icon-buttons.scss +7 -7
- package/src/sass/components/_icons-material-design.scss +2 -2
- package/src/sass/components/_image-compare.scss +108 -0
- package/src/sass/components/_index.scss +20 -0
- package/src/sass/components/_keypad.scss +39 -19
- package/src/sass/components/_kpi.scss +6 -11
- package/src/sass/components/_lightbox.scss +24 -13
- package/src/sass/components/_line-chart.scss +16 -2
- package/src/sass/components/_list.scss +59 -14
- package/src/sass/components/_loading-indicator.scss +1 -0
- package/src/sass/components/_loading-overlay.scss +105 -0
- package/src/sass/components/_map.scss +33 -11
- package/src/sass/components/_marquee.scss +3 -2
- package/src/sass/components/_mega-menu.scss +137 -0
- package/src/sass/components/_menu.scss +143 -123
- package/src/sass/components/_menubar.scss +59 -0
- package/src/sass/components/_message-scroller.scss +2 -2
- package/src/sass/components/_message.scss +3 -3
- package/src/sass/components/_mixed-chart.scss +37 -9
- package/src/sass/components/_modal-display.scss +21 -0
- package/src/sass/components/_navbar.scss +34 -20
- package/src/sass/components/_navigation-bar.scss +15 -77
- package/src/sass/components/_navigation-rail.scss +151 -92
- package/src/sass/components/_org-chart.scss +192 -0
- package/src/sass/components/_page-footer.scss +1 -1
- package/src/sass/components/_pagination.scss +6 -13
- package/src/sass/components/_panes.scss +32 -26
- package/src/sass/components/_particles.scss +0 -2
- package/src/sass/components/_pie-chart.scss +91 -11
- package/src/sass/components/_popover.scss +18 -5
- package/src/sass/components/_progress.scss +152 -31
- package/src/sass/components/_pull-to-refresh.scss +90 -0
- package/src/sass/components/_questionnaire.scss +74 -3
- package/src/sass/components/_radar-chart.scss +38 -10
- package/src/sass/components/_radial-chart.scss +113 -5
- package/src/sass/components/_rich-text-editor.scss +2 -2
- package/src/sass/components/_sankey-chart.scss +114 -0
- package/src/sass/components/_scatter-chart.scss +153 -0
- package/src/sass/components/_scrim.scss +0 -2
- package/src/sass/components/_scrollspy.scss +0 -2
- package/src/sass/components/_search.scss +26 -22
- package/src/sass/components/_show-more.scss +8 -0
- package/src/sass/components/_side-sheet.scss +23 -37
- package/src/sass/components/_skeleton.scss +2 -4
- package/src/sass/components/_snackbar.scss +27 -21
- package/src/sass/components/_split-button.scss +5 -5
- package/src/sass/components/_stat.scss +3 -8
- package/src/sass/components/_stepper.scss +1 -1
- package/src/sass/components/_swipe-actions.scss +71 -0
- package/src/sass/components/_tabs.scss +51 -32
- package/src/sass/components/_timeline.scss +12 -12
- package/src/sass/components/_timepicker.scss +109 -78
- package/src/sass/components/_toolbar.scss +35 -43
- package/src/sass/components/_tooltip.scss +21 -12
- package/src/sass/components/_tour.scss +89 -0
- package/src/sass/components/_transfer-list.scss +73 -0
- package/src/sass/components/_transitions.scss +4 -4
- package/src/sass/components/_tree.scss +3 -16
- package/src/sass/components/_treemap-chart.scss +122 -0
- package/src/sass/components/forms/_checkboxes.scss +106 -24
- package/src/sass/components/forms/_color-picker.scss +135 -0
- package/src/sass/components/forms/_color-swatches.scss +85 -0
- package/src/sass/components/forms/_drop-zone.scss +15 -9
- package/src/sass/components/forms/_fieldset.scss +7 -7
- package/src/sass/components/forms/_file-input.scss +6 -8
- package/src/sass/components/forms/_index.scss +3 -1
- package/src/sass/components/forms/_input-fields.scss +254 -90
- package/src/sass/components/forms/_radio-buttons.scss +33 -94
- package/src/sass/components/forms/_rating.scss +2 -32
- package/src/sass/components/forms/_select.scss +199 -20
- package/src/sass/components/forms/_slider.scss +91 -94
- package/src/sass/components/forms/_switches.scss +53 -164
- package/src/sass/custom.scss +10 -1
- package/src/sass/expressive.scss +3 -63
- package/src/sass/tokens/_contrast.scss +94 -0
- package/src/sass/tokens/_elevation.scss +16 -0
- package/src/sass/tokens/_index.scss +5 -0
- package/src/sass/tokens/_motion.scss +109 -0
- package/src/sass/tokens/_reference.scss +72 -141
- package/src/sass/tokens/_shape.scss +38 -0
- package/src/sass/tokens/_stacking.scss +27 -0
- package/src/sass/tokens/_state.scss +0 -2
- package/src/sass/tokens/_theme.scss +10 -1
- package/src/sass/tokens/_vibrant.scss +2 -5
- package/src/sass/utilities/_defer-render.scss +17 -0
- package/src/sass/utilities/_helpers.scss +183 -26
- package/src/sass/utilities/_index.scss +1 -0
- package/src/sass/utilities/_scroll-area.scss +0 -2
- package/src/sass/utilities/_spacing.scss +52 -34
- package/src/sass/utilities/_typescale.scss +8 -1
- package/src/sass/utilities/_visibility.scss +47 -76
- package/src/sass/utilities/_z-depth.scss +7 -4
- package/dist/js/chunks/chunk-33QVDDGR.mjs +0 -270
- package/dist/js/chunks/chunk-33QVDDGR.mjs.map +0 -7
- package/dist/js/chunks/chunk-45FER6RI.mjs +0 -59
- package/dist/js/chunks/chunk-45FER6RI.mjs.map +0 -7
- package/dist/js/chunks/chunk-5CEAOLUA.mjs.map +0 -7
- package/dist/js/chunks/chunk-6VATUZC6.mjs +0 -295
- package/dist/js/chunks/chunk-6VATUZC6.mjs.map +0 -7
- package/dist/js/chunks/chunk-74MXKKLN.mjs.map +0 -7
- package/dist/js/chunks/chunk-AIURVCG6.mjs +0 -55
- package/dist/js/chunks/chunk-AIURVCG6.mjs.map +0 -7
- package/dist/js/chunks/chunk-BGZLF6JZ.mjs.map +0 -7
- package/dist/js/chunks/chunk-C6CHEWYP.mjs.map +0 -7
- package/dist/js/chunks/chunk-CK2XCICY.mjs.map +0 -7
- package/dist/js/chunks/chunk-CXXM2L4F.mjs +0 -344
- package/dist/js/chunks/chunk-CXXM2L4F.mjs.map +0 -7
- package/dist/js/chunks/chunk-DXGRXYYL.mjs.map +0 -7
- package/dist/js/chunks/chunk-FM5CZOUB.mjs.map +0 -7
- package/dist/js/chunks/chunk-GJL6GCIU.mjs.map +0 -7
- package/dist/js/chunks/chunk-K3HZMFMD.mjs +0 -135
- package/dist/js/chunks/chunk-K3HZMFMD.mjs.map +0 -7
- package/dist/js/chunks/chunk-KHXZ2A4K.mjs.map +0 -7
- package/dist/js/chunks/chunk-KQACNQ22.mjs +0 -7
- package/dist/js/chunks/chunk-KQACNQ22.mjs.map +0 -7
- package/dist/js/chunks/chunk-KUFHW3DS.mjs.map +0 -7
- package/dist/js/chunks/chunk-KVJAVDBC.mjs.map +0 -7
- package/dist/js/chunks/chunk-L27Q6ZMI.mjs.map +0 -7
- package/dist/js/chunks/chunk-LQWUDNHZ.mjs.map +0 -7
- package/dist/js/chunks/chunk-M372EDXD.mjs +0 -322
- package/dist/js/chunks/chunk-M372EDXD.mjs.map +0 -7
- package/dist/js/chunks/chunk-M3MURWMB.mjs +0 -82
- package/dist/js/chunks/chunk-M3MURWMB.mjs.map +0 -7
- package/dist/js/chunks/chunk-NUHMOAOY.mjs.map +0 -7
- package/dist/js/chunks/chunk-OWG3LMUL.mjs +0 -169
- package/dist/js/chunks/chunk-OWG3LMUL.mjs.map +0 -7
- package/dist/js/chunks/chunk-PD6HYHAE.mjs +0 -48
- package/dist/js/chunks/chunk-PD6HYHAE.mjs.map +0 -7
- package/dist/js/chunks/chunk-PDG64UHF.mjs.map +0 -7
- package/dist/js/chunks/chunk-PO3AXVR3.mjs +0 -546
- package/dist/js/chunks/chunk-PO3AXVR3.mjs.map +0 -7
- package/dist/js/chunks/chunk-QYGK36OG.mjs +0 -181
- package/dist/js/chunks/chunk-QYGK36OG.mjs.map +0 -7
- package/dist/js/chunks/chunk-SFI2U4YW.mjs.map +0 -7
- package/dist/js/chunks/chunk-SMY7GJSS.mjs.map +0 -7
- package/dist/js/chunks/chunk-TCCA2HDG.mjs +0 -414
- package/dist/js/chunks/chunk-TCCA2HDG.mjs.map +0 -7
- package/dist/js/chunks/chunk-TSZYSW7F.mjs.map +0 -7
- package/dist/js/chunks/chunk-UAZSDUVP.mjs.map +0 -7
- package/dist/js/chunks/chunk-UBRZZWRA.mjs +0 -127
- package/dist/js/chunks/chunk-UBRZZWRA.mjs.map +0 -7
- package/dist/js/chunks/chunk-UCOE7ZDL.mjs +0 -287
- package/dist/js/chunks/chunk-UCOE7ZDL.mjs.map +0 -7
- package/dist/js/chunks/chunk-UETTGDLI.mjs.map +0 -7
- package/dist/js/chunks/chunk-UNCRDLP6.mjs +0 -136
- package/dist/js/chunks/chunk-UNCRDLP6.mjs.map +0 -7
- package/dist/js/chunks/chunk-VGNYF6FB.mjs.map +0 -7
- package/dist/js/chunks/chunk-VGPGBNGL.mjs +0 -68
- package/dist/js/chunks/chunk-VGPGBNGL.mjs.map +0 -7
- package/dist/js/chunks/chunk-VKAUVTQY.mjs +0 -1
- package/dist/js/chunks/chunk-VM4FTS7L.mjs +0 -48
- package/dist/js/chunks/chunk-VM4FTS7L.mjs.map +0 -7
- package/dist/js/chunks/chunk-WDK4T63U.mjs.map +0 -7
- package/dist/js/chunks/chunk-WOCCTVUF.mjs +0 -185
- package/dist/js/chunks/chunk-WOCCTVUF.mjs.map +0 -7
- package/dist/js/chunks/chunk-WQYN5L4E.mjs +0 -107
- package/dist/js/chunks/chunk-WQYN5L4E.mjs.map +0 -7
- package/dist/js/chunks/chunk-X4ISMKE2.mjs.map +0 -7
- package/dist/js/chunks/chunk-XAEAEHIX.mjs.map +0 -7
- package/dist/js/chunks/chunk-ZX6M7SWO.mjs.map +0 -7
- /package/dist/js/chunks/{chunk-VKAUVTQY.mjs.map → chunk-GNRSYMVH.mjs.map} +0 -0
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
import {
|
|
2
|
+
LineChart,
|
|
3
|
+
rowLegend,
|
|
4
|
+
seriesColor
|
|
5
|
+
} from "./chunk-ZM3XBHWV.mjs";
|
|
6
|
+
import {
|
|
7
|
+
svgNode
|
|
8
|
+
} from "./chunk-ZVLOUDIJ.mjs";
|
|
9
|
+
|
|
10
|
+
// src/ts/components/radialChart.ts
|
|
11
|
+
var RADIUS = 46;
|
|
12
|
+
var FILL = 0.8;
|
|
13
|
+
var RadialChart = class extends LineChart {
|
|
14
|
+
get _type() {
|
|
15
|
+
return "radial-chart";
|
|
16
|
+
}
|
|
17
|
+
/** The rings fill to data-max, so there is no value axis. */
|
|
18
|
+
get _axis() {
|
|
19
|
+
return false;
|
|
20
|
+
}
|
|
21
|
+
get _points() {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
get _circular() {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
get _gauge() {
|
|
28
|
+
return this.el.classList.contains("gauge");
|
|
29
|
+
}
|
|
30
|
+
/** Whether .labels names the rings, which a sparkline never does. */
|
|
31
|
+
get _labeled() {
|
|
32
|
+
const list = this.el.classList;
|
|
33
|
+
return list.contains("labels") && !list.contains("sparkline");
|
|
34
|
+
}
|
|
35
|
+
/** How much of a circle a full ring spans. */
|
|
36
|
+
get _span() {
|
|
37
|
+
if (this._gauge) return 0.5;
|
|
38
|
+
return this._labeled ? 0.75 : 1;
|
|
39
|
+
}
|
|
40
|
+
/** The number of segments data-segments asks for, or 0 for whole rings. */
|
|
41
|
+
get _segments() {
|
|
42
|
+
const segments = Math.round(this._number("segments") ?? 0);
|
|
43
|
+
return segments > 1 ? segments : 0;
|
|
44
|
+
}
|
|
45
|
+
/** A share as drawn: with segments, to the nearest whole segment. */
|
|
46
|
+
_lit(fraction) {
|
|
47
|
+
const segments = this._segments;
|
|
48
|
+
return segments ? Math.round(fraction * segments) / segments : fraction;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* A ring's dash pattern for a share of its span. Round caps reach half the
|
|
52
|
+
* width past each end of a dash, so a capped dash is one width shorter and
|
|
53
|
+
* its gap one width longer; one shorter than the width is a dot. With
|
|
54
|
+
* segments, each lit segment is a dash with the ring gap after it, and
|
|
55
|
+
* the last gap runs out the circle so the pattern does not repeat.
|
|
56
|
+
*/
|
|
57
|
+
_dash(fraction, length, capped) {
|
|
58
|
+
const [cap, segments, span] = [capped ? this._width : 0, this._segments, this._span * length];
|
|
59
|
+
if (!segments) return `${Math.max(1e-3, fraction * span - cap).toFixed(3)} ${length.toFixed(3)}`;
|
|
60
|
+
const size = span / segments;
|
|
61
|
+
const dash = Math.max(1e-3, size - this._gap - cap);
|
|
62
|
+
const lit = Array.from({ length: Math.round(fraction * segments) }, () => `${dash.toFixed(3)} ${(size - dash).toFixed(3)}`);
|
|
63
|
+
return `${lit.join(" ").replace(/ [\d.]+$/, "") || 0} ${length.toFixed(3)}`;
|
|
64
|
+
}
|
|
65
|
+
/** The distance between rings' middles, or one ring's width. */
|
|
66
|
+
get _step() {
|
|
67
|
+
return this._radii.length > 1 ? this._radii[0] - this._radii[1] : this._width;
|
|
68
|
+
}
|
|
69
|
+
show(index) {
|
|
70
|
+
if (!this._tooltip || index === this.activeIndex) return;
|
|
71
|
+
super.show(index);
|
|
72
|
+
this._rings.forEach((ring, i) => ring.classList.toggle("active", i === index));
|
|
73
|
+
this._sweeps.forEach((sweep, i) => sweep?.classList.toggle("active", i === index));
|
|
74
|
+
if (this._tooltip.hidden) return;
|
|
75
|
+
const color = seriesColor(index);
|
|
76
|
+
this._tooltip.querySelectorAll("[data-series]").forEach((span) => {
|
|
77
|
+
span.dataset.series = color;
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
/** The tooltip sits where the ring's fill ends. */
|
|
81
|
+
_place(index) {
|
|
82
|
+
const turn = this._turn(this._fractions[index]);
|
|
83
|
+
const r = this._radii[index];
|
|
84
|
+
const [x, y] = [r * Math.sin(turn * 2 * Math.PI), -r * Math.cos(turn * 2 * Math.PI)];
|
|
85
|
+
this._tooltip.style.left = `${50 + x}%`;
|
|
86
|
+
this._tooltip.style.top = `${(50 + y) / (this._gauge ? 50 : 100) * 100}%`;
|
|
87
|
+
this._tooltip.classList.toggle("end", x > 0);
|
|
88
|
+
}
|
|
89
|
+
/** A fraction of the ring as a turn clockwise from the top. */
|
|
90
|
+
_turn(fraction) {
|
|
91
|
+
return fraction * this._span - (this._gauge ? 0.25 : 0);
|
|
92
|
+
}
|
|
93
|
+
/** For more than one row, a legend of every row with its color and cell. */
|
|
94
|
+
_guides() {
|
|
95
|
+
if (this.labels.length < 2) return [];
|
|
96
|
+
const text = this.series[0].text;
|
|
97
|
+
const colors = this.labels.map((_, i) => seriesColor(i));
|
|
98
|
+
return [rowLegend("radial-chart-legend", colors, this.labels.map((label, i) => [label, text[i]]))];
|
|
99
|
+
}
|
|
100
|
+
/** The ring under the pointer by its distance from the middle, or -1. */
|
|
101
|
+
_indexAt(e) {
|
|
102
|
+
const box = this._plot.getBoundingClientRect();
|
|
103
|
+
const [x, y] = [e.clientX - box.left - box.width / 2, e.clientY - box.top - box.width / 2];
|
|
104
|
+
if (this._gauge && y > 0) return this._nameAt(e);
|
|
105
|
+
const distance = this._distance(x, y, box.width);
|
|
106
|
+
return this._radii.findIndex((r) => Math.abs(distance - r) <= this._step / 2);
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* How far a point is from the middle in the SVG's 100-unit box. In the
|
|
110
|
+
* top left quarter .labels leaves empty, the names run straight across,
|
|
111
|
+
* so only the height counts and a name picks its own ring.
|
|
112
|
+
*/
|
|
113
|
+
_distance(x, y, width) {
|
|
114
|
+
if (this._span === 0.75 && x < 0 && y < 0) return -y / width * 100;
|
|
115
|
+
return Math.hypot(x, y) / width * 100;
|
|
116
|
+
}
|
|
117
|
+
/** Under a gauge's base line, the ring whose name is under the pointer, or -1. */
|
|
118
|
+
_nameAt(e) {
|
|
119
|
+
const name = e.target.closest(".radial-chart-names > span");
|
|
120
|
+
return name ? [...name.parentElement.children].indexOf(name) : -1;
|
|
121
|
+
}
|
|
122
|
+
/** The rings' turn, from three o'clock to the top or, for a gauge, to nine, and the SVG's box. */
|
|
123
|
+
get _frame() {
|
|
124
|
+
return this._gauge ? ["rotate(180)", "-50 -50 100 50"] : ["rotate(-90)", "-50 -50 100 100"];
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* With .gradient, a ring's fill drawn again in HTML: a conic gradient from
|
|
128
|
+
* a tint of its colour at the ring's start to the full colour where the
|
|
129
|
+
* fill ends, masked to the fill's own dash, so it follows the ring round.
|
|
130
|
+
* An SVG stroke takes no conic gradient.
|
|
131
|
+
*/
|
|
132
|
+
_sweep(r, i, length) {
|
|
133
|
+
const fraction = this._fractions[i];
|
|
134
|
+
if (!fraction || !this.el.classList.contains("gradient")) return null;
|
|
135
|
+
const [transform, viewBox] = this._frame;
|
|
136
|
+
const width = this._width.toFixed(3);
|
|
137
|
+
const dash = this._dash(fraction, length, true);
|
|
138
|
+
const image = `<svg xmlns='http://www.w3.org/2000/svg' viewBox='${viewBox}'><circle r='${r.toFixed(3)}' stroke-width='${width}' transform='${transform}' stroke-dasharray='${dash}' stroke-dashoffset='${(-this._width / 2).toFixed(3)}' stroke-linecap='round' fill='none' stroke='black'/></svg>`;
|
|
139
|
+
const sweep = document.createElement("div");
|
|
140
|
+
sweep.className = "radial-chart-sweep";
|
|
141
|
+
sweep.dataset.series = seriesColor(i);
|
|
142
|
+
sweep.style.setProperty("--radial-chart-shape", `url("data:image/svg+xml,${encodeURIComponent(image)}")`);
|
|
143
|
+
sweep.style.setProperty("--radial-chart-from", `${this._turn(0)}turn`);
|
|
144
|
+
sweep.style.setProperty("--radial-chart-to", `${fraction * this._span}turn`);
|
|
145
|
+
return sweep;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* With .labels, each row's name left of its ring's start at the top,
|
|
149
|
+
* ending at the middle line. CSS shrinks the text to fit crowded rings.
|
|
150
|
+
* A gauge's names hang under its base line in a row each, innermost
|
|
151
|
+
* first, starting below their rings' starts.
|
|
152
|
+
*/
|
|
153
|
+
_names() {
|
|
154
|
+
if (!this._labeled) return [];
|
|
155
|
+
const count = this._radii.length;
|
|
156
|
+
const names = document.createElement("div");
|
|
157
|
+
names.className = "radial-chart-names";
|
|
158
|
+
names.style.setProperty("--radial-chart-step", this._step.toFixed(3));
|
|
159
|
+
this._plot.style.setProperty("--radial-chart-rows", String(count));
|
|
160
|
+
names.append(...this._radii.map((r, i) => {
|
|
161
|
+
const name = document.createElement("span");
|
|
162
|
+
name.style.setProperty("--radial-chart-at", `${(50 - r).toFixed(3)}%`);
|
|
163
|
+
name.style.setProperty("--radial-chart-row", String(count - 1 - i));
|
|
164
|
+
name.textContent = this.labels[i];
|
|
165
|
+
return name;
|
|
166
|
+
}));
|
|
167
|
+
return [names];
|
|
168
|
+
}
|
|
169
|
+
/**
|
|
170
|
+
* An SVG of rings in a -50 to 50 box, the top half for a gauge. Each row
|
|
171
|
+
* is a track circle and a fill circle whose dash is its share; CSS draws
|
|
172
|
+
* them from --radial-chart-dash. The total is HTML over it.
|
|
173
|
+
*/
|
|
174
|
+
_draw() {
|
|
175
|
+
const style = getComputedStyle(this.el);
|
|
176
|
+
const token = (name, fallback) => {
|
|
177
|
+
const value = parseFloat(style.getPropertyValue(`--md-comp-radial-chart-${name}`));
|
|
178
|
+
return Number.isFinite(value) ? value : fallback;
|
|
179
|
+
};
|
|
180
|
+
const count = this.labels.length;
|
|
181
|
+
let [width, gap] = [Math.max(0, token("thickness", 8)), Math.max(0, token("gap", 2))];
|
|
182
|
+
const scale = Math.min(1, RADIUS * FILL / (count * width + (count - 1) * gap || 1));
|
|
183
|
+
[width, gap] = [width * scale, gap * scale];
|
|
184
|
+
[this._width, this._gap] = [width, gap];
|
|
185
|
+
this._radii = this.labels.map((_, i) => RADIUS - width / 2 - i * (width + gap));
|
|
186
|
+
const max = [parseFloat(this.el.dataset.max ?? ""), this.options.max ?? NaN, 100].find((value) => value > 0);
|
|
187
|
+
this._fractions = this.series[0].values.map((value) => this._lit(Math.min(1, Math.max(0, (value ?? 0) / max))));
|
|
188
|
+
const [transform, viewBox] = this._frame;
|
|
189
|
+
const svg = svgNode("svg", { viewBox, focusable: "false" });
|
|
190
|
+
const span = this._span;
|
|
191
|
+
this._sweeps = [];
|
|
192
|
+
this._rings = this._radii.map((r, i) => {
|
|
193
|
+
const length = 2 * Math.PI * r;
|
|
194
|
+
const circle = (name, fraction, capped) => {
|
|
195
|
+
const ring2 = svgNode("circle", { class: name, r: r.toFixed(3), transform, "stroke-width": width.toFixed(3) });
|
|
196
|
+
ring2.style.setProperty("--radial-chart-dash", this._dash(fraction, length, capped));
|
|
197
|
+
if (capped) {
|
|
198
|
+
ring2.style.setProperty("--radial-chart-offset", (-width / 2).toFixed(3));
|
|
199
|
+
ring2.classList.add("capped");
|
|
200
|
+
}
|
|
201
|
+
return ring2;
|
|
202
|
+
};
|
|
203
|
+
const ring = circle("radial-chart-ring", this._fractions[i], true);
|
|
204
|
+
ring.dataset.series = seriesColor(i);
|
|
205
|
+
if (!this._fractions[i]) ring.classList.add("empty");
|
|
206
|
+
svg.append(circle("radial-chart-track", 1, span < 1 || !!this._segments), ring);
|
|
207
|
+
this._sweeps.push(this._sweep(r, i, length));
|
|
208
|
+
return ring;
|
|
209
|
+
});
|
|
210
|
+
const rings = document.createElement("div");
|
|
211
|
+
rings.className = "radial-chart-rings";
|
|
212
|
+
rings.setAttribute("aria-hidden", "true");
|
|
213
|
+
rings.style.setProperty("--radial-chart-middle", `${(this._radii[count - 1] - this._width / 2) * 2}%`);
|
|
214
|
+
rings.append(svg, ...this._sweeps.filter((sweep) => sweep !== null), ...this._names());
|
|
215
|
+
const total = this._total("radial-chart-total");
|
|
216
|
+
if (total) rings.append(total);
|
|
217
|
+
return rings;
|
|
218
|
+
}
|
|
219
|
+
};
|
|
220
|
+
RadialChart.key = "Expressive_RadialChart";
|
|
221
|
+
|
|
222
|
+
export {
|
|
223
|
+
RadialChart
|
|
224
|
+
};
|
|
225
|
+
//# sourceMappingURL=chunk-7YQBHTK3.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/ts/components/radialChart.ts"],
|
|
4
|
+
"sourcesContent": ["import { LineChart, LineChartOptions, rowLegend, seriesColor } from './lineChart';\nimport { svgNode as node } from '../core/utils';\n\nexport type RadialChartOptions = LineChartOptions;\n\n/** The outer ring's outer edge in a 100-unit box. */\nconst RADIUS = 46;\n/** The rings never fill more of the radius than this, leaving a middle. */\nconst FILL = 0.8;\n\n/**\n * Radial chart. It reads its <table> like LineChart, but draws each row of\n * the first value column as a ring, outermost first, filled clockwise from\n * the top as a share of `data-max` above zero (100 by default). With `.gauge` the rings\n * are half circles over the middle. With `.labels` they are three quarters\n * of a circle, leaving the top left quarter for each row's name at the\n * ring's start; a gauge's names hang under its base line instead.\n * `data-segments` splits each ring into that many segments, filled whole,\n * and `.gradient` shades each fill along the ring, from a light tint at its\n * start to its full color at its end. A <tfoot>\n * row shows in the middle, and\n * a legend lists the rows when there is more than one. Further columns show\n * in the tooltip.\n *\n * Call `update()` after changing the ring tokens, and after changing the table\n * unless it was started with `watch` or `data-watch`.\n */\nexport class RadialChart extends LineChart {\n // No initializers: LineChart's constructor draws before they would run.\n /** Each ring's middle radius, and their shared width. */\n private _radii: number[];\n private _width: number;\n /** The gap between rings, and between segments. */\n private _gap: number;\n /** Each row's share of the maximum, from 0 to 1. */\n private _fractions: number[];\n private _rings: SVGCircleElement[];\n /** With .gradient, each ring's fill drawn again as a conic gradient, or null for none. */\n private _sweeps: (HTMLElement | null)[];\n\n protected get _type() {\n return 'radial-chart';\n }\n\n /** The rings fill to data-max, so there is no value axis. */\n protected get _axis() {\n return false;\n }\n\n protected get _points() {\n return false;\n }\n\n protected get _circular() {\n return true;\n }\n\n private get _gauge() {\n return this.el.classList.contains('gauge');\n }\n\n /** Whether .labels names the rings, which a sparkline never does. */\n private get _labeled() {\n const list = this.el.classList;\n return list.contains('labels') && !list.contains('sparkline');\n }\n\n /** How much of a circle a full ring spans. */\n private get _span() {\n if (this._gauge) return 0.5;\n return this._labeled ? 0.75 : 1;\n }\n\n /** The number of segments data-segments asks for, or 0 for whole rings. */\n private get _segments() {\n const segments = Math.round(this._number('segments') ?? 0);\n return segments > 1 ? segments : 0;\n }\n\n /** A share as drawn: with segments, to the nearest whole segment. */\n private _lit(fraction: number) {\n const segments = this._segments;\n return segments ? Math.round(fraction * segments) / segments : fraction;\n }\n\n /**\n * A ring's dash pattern for a share of its span. Round caps reach half the\n * width past each end of a dash, so a capped dash is one width shorter and\n * its gap one width longer; one shorter than the width is a dot. With\n * segments, each lit segment is a dash with the ring gap after it, and\n * the last gap runs out the circle so the pattern does not repeat.\n */\n private _dash(fraction: number, length: number, capped: boolean) {\n const [cap, segments, span] = [capped ? this._width : 0, this._segments, this._span * length];\n if (!segments) return `${Math.max(0.001, fraction * span - cap).toFixed(3)} ${length.toFixed(3)}`;\n // A dash and its gap make one segment, even where a small ring leaves\n // too little room for the gap and the caps.\n const size = span / segments;\n const dash = Math.max(0.001, size - this._gap - cap);\n const lit = Array.from({ length: Math.round(fraction * segments) }, () => `${dash.toFixed(3)} ${(size - dash).toFixed(3)}`);\n return `${lit.join(' ').replace(/ [\\d.]+$/, '') || 0} ${length.toFixed(3)}`;\n }\n\n /** The distance between rings' middles, or one ring's width. */\n private get _step() {\n return this._radii.length > 1 ? this._radii[0] - this._radii[1] : this._width;\n }\n\n static key = 'Expressive_RadialChart';\n\n show(index: number) {\n if (!this._tooltip || index === this.activeIndex) return;\n super.show(index);\n this._rings.forEach((ring, i) => ring.classList.toggle('active', i === index));\n this._sweeps.forEach((sweep, i) => sweep?.classList.toggle('active', i === index));\n // LineChart hides the tooltip for -1 and for an index past the last row.\n if (this._tooltip.hidden) return;\n const color = seriesColor(index);\n this._tooltip.querySelectorAll<HTMLElement>('[data-series]').forEach((span) => {\n span.dataset.series = color;\n });\n }\n\n /** The tooltip sits where the ring's fill ends. */\n protected _place(index: number) {\n const turn = this._turn(this._fractions[index]);\n const r = this._radii[index];\n const [x, y] = [r * Math.sin(turn * 2 * Math.PI), -r * Math.cos(turn * 2 * Math.PI)];\n this._tooltip.style.left = `${50 + x}%`;\n this._tooltip.style.top = `${((50 + y) / (this._gauge ? 50 : 100)) * 100}%`;\n // On the right half it opens leftwards, over the rings.\n this._tooltip.classList.toggle('end', x > 0);\n }\n\n /** A fraction of the ring as a turn clockwise from the top. */\n private _turn(fraction: number) {\n // A gauge starts at nine o'clock.\n return fraction * this._span - (this._gauge ? 0.25 : 0);\n }\n\n /** For more than one row, a legend of every row with its color and cell. */\n protected _guides(): Element[] {\n if (this.labels.length < 2) return [];\n const text = this.series[0].text;\n const colors = this.labels.map((_, i) => seriesColor(i));\n return [rowLegend('radial-chart-legend', colors, this.labels.map((label, i) => [label, text[i]]))];\n }\n\n /** The ring under the pointer by its distance from the middle, or -1. */\n protected _indexAt(e: PointerEvent) {\n const box = this._plot.getBoundingClientRect();\n // The middle is half the width down in both shapes.\n const [x, y] = [e.clientX - box.left - box.width / 2, e.clientY - box.top - box.width / 2];\n if (this._gauge && y > 0) return this._nameAt(e);\n // A gap belongs to a ring beside it.\n const distance = this._distance(x, y, box.width);\n return this._radii.findIndex((r) => Math.abs(distance - r) <= this._step / 2);\n }\n\n /**\n * How far a point is from the middle in the SVG's 100-unit box. In the\n * top left quarter .labels leaves empty, the names run straight across,\n * so only the height counts and a name picks its own ring.\n */\n private _distance(x: number, y: number, width: number) {\n // Only three-quarter rings leave that quarter empty.\n if (this._span === 0.75 && x < 0 && y < 0) return (-y / width) * 100;\n return (Math.hypot(x, y) / width) * 100;\n }\n\n /** Under a gauge's base line, the ring whose name is under the pointer, or -1. */\n private _nameAt(e: PointerEvent) {\n const name = (e.target as Element).closest('.radial-chart-names > span');\n return name ? [...name.parentElement!.children].indexOf(name) : -1;\n }\n\n /** The rings' turn, from three o'clock to the top or, for a gauge, to nine, and the SVG's box. */\n private get _frame(): [transform: string, viewBox: string] {\n return this._gauge ? ['rotate(180)', '-50 -50 100 50'] : ['rotate(-90)', '-50 -50 100 100'];\n }\n\n /**\n * With .gradient, a ring's fill drawn again in HTML: a conic gradient from\n * a tint of its colour at the ring's start to the full colour where the\n * fill ends, masked to the fill's own dash, so it follows the ring round.\n * An SVG stroke takes no conic gradient.\n */\n private _sweep(r: number, i: number, length: number) {\n const fraction = this._fractions[i];\n if (!fraction || !this.el.classList.contains('gradient')) return null;\n const [transform, viewBox] = this._frame;\n const width = this._width.toFixed(3);\n const dash = this._dash(fraction, length, true);\n const image = `<svg xmlns='http://www.w3.org/2000/svg' viewBox='${viewBox}'><circle r='${r.toFixed(3)}' stroke-width='${width}' transform='${transform}' stroke-dasharray='${dash}' stroke-dashoffset='${(-this._width / 2).toFixed(3)}' stroke-linecap='round' fill='none' stroke='black'/></svg>`;\n const sweep = document.createElement('div');\n sweep.className = 'radial-chart-sweep';\n sweep.dataset.series = seriesColor(i);\n sweep.style.setProperty('--radial-chart-shape', `url(\"data:image/svg+xml,${encodeURIComponent(image)}\")`);\n sweep.style.setProperty('--radial-chart-from', `${this._turn(0)}turn`);\n sweep.style.setProperty('--radial-chart-to', `${fraction * this._span}turn`);\n return sweep;\n }\n\n /**\n * With .labels, each row's name left of its ring's start at the top,\n * ending at the middle line. CSS shrinks the text to fit crowded rings.\n * A gauge's names hang under its base line in a row each, innermost\n * first, starting below their rings' starts.\n */\n private _names(): Element[] {\n if (!this._labeled) return [];\n const count = this._radii.length;\n const names = document.createElement('div');\n names.className = 'radial-chart-names';\n names.style.setProperty('--radial-chart-step', this._step.toFixed(3));\n // The plot leaves room under a gauge for the rows.\n this._plot.style.setProperty('--radial-chart-rows', String(count));\n names.append(...this._radii.map((r, i) => {\n const name = document.createElement('span');\n // The ring's top, or a gauge ring's start along the base line.\n name.style.setProperty('--radial-chart-at', `${(50 - r).toFixed(3)}%`);\n name.style.setProperty('--radial-chart-row', String(count - 1 - i));\n name.textContent = this.labels[i];\n return name;\n }));\n return [names];\n }\n\n /**\n * An SVG of rings in a -50 to 50 box, the top half for a gauge. Each row\n * is a track circle and a fill circle whose dash is its share; CSS draws\n * them from --radial-chart-dash. The total is HTML over it.\n */\n protected _draw(): Element {\n const style = getComputedStyle(this.el);\n const token = (name: string, fallback: number) => {\n const value = parseFloat(style.getPropertyValue(`--md-comp-radial-chart-${name}`));\n return Number.isFinite(value) ? value : fallback;\n };\n const count = this.labels.length;\n let [width, gap] = [Math.max(0, token('thickness', 8)), Math.max(0, token('gap', 2))];\n // Too many rings to leave a middle thin, with their gaps, to fit.\n // ponytail: past about 18 rings they are hairlines; that many values want a bar chart.\n const scale = Math.min(1, (RADIUS * FILL) / (count * width + (count - 1) * gap || 1));\n [width, gap] = [width * scale, gap * scale];\n [this._width, this._gap] = [width, gap];\n this._radii = this.labels.map((_, i) => RADIUS - width / 2 - i * (width + gap));\n // A maximum of zero or less means nothing, so it falls back.\n const max = [parseFloat(this.el.dataset.max ?? ''), this.options.max ?? NaN, 100].find((value) => value > 0)!;\n this._fractions = this.series[0].values.map((value) => this._lit(Math.min(1, Math.max(0, (value ?? 0) / max))));\n\n const [transform, viewBox] = this._frame;\n const svg = node('svg', { viewBox, focusable: 'false' });\n const span = this._span;\n this._sweeps = [];\n this._rings = this._radii.map((r, i) => {\n const length = 2 * Math.PI * r;\n // A capped dash starts half a width in, where its round cap ends.\n const circle = (name: string, fraction: number, capped: boolean) => {\n const ring = node('circle', { class: name, r: r.toFixed(3), transform, 'stroke-width': width.toFixed(3) });\n ring.style.setProperty('--radial-chart-dash', this._dash(fraction, length, capped));\n if (capped) {\n ring.style.setProperty('--radial-chart-offset', (-width / 2).toFixed(3));\n ring.classList.add('capped');\n }\n return ring;\n };\n const ring = circle('radial-chart-ring', this._fractions[i], true) as SVGCircleElement;\n ring.dataset.series = seriesColor(i);\n // An empty ring would still draw its round cap.\n if (!this._fractions[i]) ring.classList.add('empty');\n // Only a track short of a whole circle, or in segments, has ends to round.\n svg.append(circle('radial-chart-track', 1, span < 1 || !!this._segments), ring);\n this._sweeps.push(this._sweep(r, i, length));\n return ring;\n });\n\n const rings = document.createElement('div');\n rings.className = 'radial-chart-rings';\n rings.setAttribute('aria-hidden', 'true');\n rings.style.setProperty('--radial-chart-middle', `${(this._radii[count - 1] - this._width / 2) * 2}%`);\n rings.append(svg, ...this._sweeps.filter((sweep) => sweep !== null), ...this._names());\n\n const total = this._total('radial-chart-total');\n if (total) rings.append(total);\n return rings;\n }\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;AAMA,IAAM,SAAS;AAEf,IAAM,OAAO;AAmBN,IAAM,cAAN,cAA0B,UAAU;AAAA,EAazC,IAAc,QAAQ;AACpB,WAAO;AAAA,EACT;AAAA;AAAA,EAGA,IAAc,QAAQ;AACpB,WAAO;AAAA,EACT;AAAA,EAEA,IAAc,UAAU;AACtB,WAAO;AAAA,EACT;AAAA,EAEA,IAAc,YAAY;AACxB,WAAO;AAAA,EACT;AAAA,EAEA,IAAY,SAAS;AACnB,WAAO,KAAK,GAAG,UAAU,SAAS,OAAO;AAAA,EAC3C;AAAA;AAAA,EAGA,IAAY,WAAW;AACrB,UAAM,OAAO,KAAK,GAAG;AACrB,WAAO,KAAK,SAAS,QAAQ,KAAK,CAAC,KAAK,SAAS,WAAW;AAAA,EAC9D;AAAA;AAAA,EAGA,IAAY,QAAQ;AAClB,QAAI,KAAK,OAAQ,QAAO;AACxB,WAAO,KAAK,WAAW,OAAO;AAAA,EAChC;AAAA;AAAA,EAGA,IAAY,YAAY;AACtB,UAAM,WAAW,KAAK,MAAM,KAAK,QAAQ,UAAU,KAAK,CAAC;AACzD,WAAO,WAAW,IAAI,WAAW;AAAA,EACnC;AAAA;AAAA,EAGQ,KAAK,UAAkB;AAC7B,UAAM,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QAAQ,GAAG,QAAQ,CAAC,CAAC;AACvE,UAAAA,MAAK,UAAU,IAAI,QAAQ;AAAA,QAC7B;AACA,eAAOA;AAAA,MACT;AACA,YAAM,OAAO,OAAO,qBAAqB,KAAK,WAAW,CAAC,GAAG,IAAI;AACjE,WAAK,QAAQ,SAAS,YAAY,CAAC;AAEnC,UAAI,CAAC,KAAK,WAAW,CAAC,EAAG,MAAK,UAAU,IAAI,OAAO;AAEnD,UAAI,OAAO,OAAO,sBAAsB,GAAG,OAAO,KAAK,CAAC,CAAC,KAAK,SAAS,GAAG,IAAI;AAC9E,WAAK,QAAQ,KAAK,KAAK,OAAO,GAAG,GAAG,MAAM,CAAC;AAC3C,aAAO;AAAA,IACT,CAAC;AAED,UAAM,QAAQ,SAAS,cAAc,KAAK;AAC1C,UAAM,YAAY;AAClB,UAAM,aAAa,eAAe,MAAM;AACxC,UAAM,MAAM,YAAY,yBAAyB,IAAI,KAAK,OAAO,QAAQ,CAAC,IAAI,KAAK,SAAS,KAAK,CAAC,GAAG;AACrG,UAAM,OAAO,KAAK,GAAG,KAAK,QAAQ,OAAO,CAAC,UAAU,UAAU,IAAI,GAAG,GAAG,KAAK,OAAO,CAAC;AAErF,UAAM,QAAQ,KAAK,OAAO,oBAAoB;AAC9C,QAAI,MAAO,OAAM,OAAO,KAAK;AAC7B,WAAO;AAAA,EACT;AACF;AApQa,YAiFJ,MAAM;",
|
|
6
|
+
"names": ["ring"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Utils
|
|
3
|
+
} from "./chunk-ZVLOUDIJ.mjs";
|
|
4
|
+
|
|
5
|
+
// src/ts/behaviors/imageCompare.ts
|
|
6
|
+
var rangeSelector = '.image-compare > input[type="range"]';
|
|
7
|
+
var _ImageCompare = class _ImageCompare {
|
|
8
|
+
static Init() {
|
|
9
|
+
if (_ImageCompare._initialized || typeof document === "undefined") return;
|
|
10
|
+
_ImageCompare._initialized = true;
|
|
11
|
+
document.addEventListener("input", (e) => {
|
|
12
|
+
const range = Utils.eventTarget(e);
|
|
13
|
+
if (range?.matches(rangeSelector)) _ImageCompare.sync(range);
|
|
14
|
+
});
|
|
15
|
+
Utils.onDocumentReady(() => {
|
|
16
|
+
document.querySelectorAll(rangeSelector).forEach((range) => _ImageCompare.sync(range));
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
/** Moves the divider of a compare to its range's current value. */
|
|
20
|
+
static sync(range) {
|
|
21
|
+
const min = parseFloat(range.min) || 0;
|
|
22
|
+
const max = Number.isNaN(parseFloat(range.max)) ? 100 : parseFloat(range.max);
|
|
23
|
+
const fraction = max === min ? 0 : (parseFloat(range.value) - min) / (max - min);
|
|
24
|
+
range.parentElement.style.setProperty("--md-comp-image-compare-position", `${fraction * 100}%`);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
_ImageCompare._initialized = false;
|
|
28
|
+
var ImageCompare = _ImageCompare;
|
|
29
|
+
|
|
30
|
+
export {
|
|
31
|
+
ImageCompare
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=chunk-7YZ5CN3V.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/ts/behaviors/imageCompare.ts"],
|
|
4
|
+
"sourcesContent": ["import { Utils } from '../core/utils';\n\nconst rangeSelector = '.image-compare > input[type=\"range\"]';\n\n/**\n * Image compare. Keeps `--md-comp-image-compare-position` on each\n * `.image-compare` in step with its range input, so the divider and the\n * revealed image follow the value. Listens on the document, so compares added\n * later follow too once moved; `ImageCompare.sync(el)` sets one at once.\n */\nexport class ImageCompare {\n private static _initialized = false;\n\n static Init() {\n if (ImageCompare._initialized || typeof document === 'undefined') return;\n ImageCompare._initialized = true;\n document.addEventListener('input', (e) => {\n const range = Utils.eventTarget(e);\n if (range?.matches(rangeSelector)) ImageCompare.sync(<HTMLInputElement>range);\n });\n Utils.onDocumentReady(() => {\n document.querySelectorAll<HTMLInputElement>(rangeSelector).forEach((range) => ImageCompare.sync(range));\n });\n }\n\n /** Moves the divider of a compare to its range's current value. */\n static sync(range: HTMLInputElement) {\n const min = parseFloat(range.min) || 0;\n const max = Number.isNaN(parseFloat(range.max)) ? 100 : parseFloat(range.max);\n const fraction = max === min ? 0 : (parseFloat(range.value) - min) / (max - min);\n range.parentElement.style.setProperty('--md-comp-image-compare-position', `${fraction * 100}%`);\n }\n}\n"],
|
|
5
|
+
"mappings": ";;;;;AAEA,IAAM,gBAAgB;AAQf,IAAM,gBAAN,MAAM,cAAa;AAAA,EAGxB,OAAO,OAAO;AACZ,QAAI,cAAa,gBAAgB,OAAO,aAAa,YAAa;AAClE,kBAAa,eAAe;AAC5B,aAAS,iBAAiB,SAAS,CAAC,MAAM;AACxC,YAAM,QAAQ,MAAM,YAAY,CAAC;AACjC,UAAI,OAAO,QAAQ,aAAa,EAAG,eAAa,KAAuB,KAAK;AAAA,IAC9E,CAAC;AACD,UAAM,gBAAgB,MAAM;AAC1B,eAAS,iBAAmC,aAAa,EAAE,QAAQ,CAAC,UAAU,cAAa,KAAK,KAAK,CAAC;AAAA,IACxG,CAAC;AAAA,EACH;AAAA;AAAA,EAGA,OAAO,KAAK,OAAyB;AACnC,UAAM,MAAM,WAAW,MAAM,GAAG,KAAK;AACrC,UAAM,MAAM,OAAO,MAAM,WAAW,MAAM,GAAG,CAAC,IAAI,MAAM,WAAW,MAAM,GAAG;AAC5E,UAAM,WAAW,QAAQ,MAAM,KAAK,WAAW,MAAM,KAAK,IAAI,QAAQ,MAAM;AAC5E,UAAM,cAAc,MAAM,YAAY,oCAAoC,GAAG,WAAW,GAAG,GAAG;AAAA,EAChG;AACF;AAtBa,cACI,eAAe;AADzB,IAAM,eAAN;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Utils
|
|
3
|
+
} from "./chunk-ZVLOUDIJ.mjs";
|
|
4
|
+
|
|
5
|
+
// src/ts/behaviors/lists.ts
|
|
6
|
+
var rowTarget = ":scope > li > :is(a[href], button):only-child";
|
|
7
|
+
var STEPS = { ArrowUp: -1, ArrowDown: 1 };
|
|
8
|
+
var _Lists = class _Lists {
|
|
9
|
+
// A second Init adds nothing: addEventListener ignores a listener it has.
|
|
10
|
+
static Init() {
|
|
11
|
+
if (typeof document === "undefined") return;
|
|
12
|
+
document.addEventListener("keydown", _Lists._onKeydown);
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
_Lists._onKeydown = (e) => {
|
|
16
|
+
const list = Utils.eventTarget(e)?.closest(".list");
|
|
17
|
+
if (!list) return;
|
|
18
|
+
const target = Utils.focusTarget([...list.querySelectorAll(rowTarget)], e, STEPS);
|
|
19
|
+
if (!target) return;
|
|
20
|
+
e.preventDefault();
|
|
21
|
+
target.focus();
|
|
22
|
+
};
|
|
23
|
+
var Lists = _Lists;
|
|
24
|
+
|
|
25
|
+
export {
|
|
26
|
+
Lists
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=chunk-AI73GJKG.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/ts/behaviors/lists.ts"],
|
|
4
|
+
"sourcesContent": ["import { Utils } from '../core/utils';\n\n/** A row that is one link or button from edge to edge, as the list docs write it. */\nconst rowTarget = ':scope > li > :is(a[href], button):only-child';\n\nconst STEPS = { ArrowUp: -1, ArrowDown: 1 };\n\n/**\n * Keys for lists of actionable rows. In a `.list` whose rows are each a\n * single link or button, Up and Down move focus to the row before or after,\n * and Home and End to the first and last, skipping disabled rows. Every row\n * stays a Tab stop and keeps its own role, so the keys are a shortcut on\n * top of native navigation rather than a listbox. Radio rows already move\n * with the arrows, and other lists are left alone.\n */\nexport class Lists {\n // A second Init adds nothing: addEventListener ignores a listener it has.\n static Init() {\n if (typeof document === 'undefined') return;\n document.addEventListener('keydown', Lists._onKeydown);\n }\n\n private static _onKeydown = (e: KeyboardEvent) => {\n const list = Utils.eventTarget(e)?.closest('.list');\n if (!list) return;\n const target = Utils.focusTarget([...list.querySelectorAll<HTMLElement>(rowTarget)], e, STEPS);\n if (!target) return;\n e.preventDefault();\n target.focus();\n };\n}\n"],
|
|
5
|
+
"mappings": ";;;;;AAGA,IAAM,YAAY;AAElB,IAAM,QAAQ,EAAE,SAAS,IAAI,WAAW,EAAE;AAUnC,IAAM,SAAN,MAAM,OAAM;AAAA;AAAA,EAEjB,OAAO,OAAO;AACZ,QAAI,OAAO,aAAa,YAAa;AACrC,aAAS,iBAAiB,WAAW,OAAM,UAAU;AAAA,EACvD;AAUF;AAfa,OAOI,aAAa,CAAC,MAAqB;AAChD,QAAM,OAAO,MAAM,YAAY,CAAC,GAAG,QAAQ,OAAO;AAClD,MAAI,CAAC,KAAM;AACX,QAAM,SAAS,MAAM,YAAY,CAAC,GAAG,KAAK,iBAA8B,SAAS,CAAC,GAAG,GAAG,KAAK;AAC7F,MAAI,CAAC,OAAQ;AACb,IAAE,eAAe;AACjB,SAAO,MAAM;AACf;AAdK,IAAM,QAAN;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Utils
|
|
3
|
-
} from "./chunk-M372EDXD.mjs";
|
|
4
1
|
import {
|
|
5
2
|
Component
|
|
6
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-CMGXGYUC.mjs";
|
|
4
|
+
import {
|
|
5
|
+
Utils
|
|
6
|
+
} from "./chunk-ZVLOUDIJ.mjs";
|
|
7
7
|
|
|
8
8
|
// src/ts/components/messageScroller.ts
|
|
9
9
|
var _defaults = {
|
|
@@ -14,9 +14,9 @@ var _defaults = {
|
|
|
14
14
|
var EDGE = 2;
|
|
15
15
|
var UP_KEYS = /* @__PURE__ */ new Set(["ArrowUp", "PageUp", "Home"]);
|
|
16
16
|
var RELEASE_EVENTS = ["pointerup", "pointercancel", "touchend", "touchcancel"];
|
|
17
|
-
var MessageScroller = class
|
|
17
|
+
var MessageScroller = class extends Component {
|
|
18
18
|
constructor(el, options) {
|
|
19
|
-
super(el, options
|
|
19
|
+
super(el, options);
|
|
20
20
|
this._opened = false;
|
|
21
21
|
this._following = false;
|
|
22
22
|
/** A press is down: it may be a tap or a scrollbar drag. */
|
|
@@ -65,10 +65,10 @@ var MessageScroller = class _MessageScroller extends Component {
|
|
|
65
65
|
this._handleMutations = (records) => {
|
|
66
66
|
for (const record of records) {
|
|
67
67
|
record.addedNodes.forEach((node) => {
|
|
68
|
-
if (node instanceof Element) this._resizeObserver
|
|
68
|
+
if (node instanceof Element) this._resizeObserver.observe(node);
|
|
69
69
|
});
|
|
70
70
|
record.removedNodes.forEach((node) => {
|
|
71
|
-
if (node instanceof Element) this._resizeObserver
|
|
71
|
+
if (node instanceof Element) this._resizeObserver.unobserve(node);
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
74
|
const previous = this._last;
|
|
@@ -101,11 +101,6 @@ var MessageScroller = class _MessageScroller extends Component {
|
|
|
101
101
|
}
|
|
102
102
|
this._sync();
|
|
103
103
|
};
|
|
104
|
-
this.el["Expressive_MessageScroller"] = this;
|
|
105
|
-
this.options = {
|
|
106
|
-
..._MessageScroller.defaults,
|
|
107
|
-
...options
|
|
108
|
-
};
|
|
109
104
|
this.viewport = el.querySelector(":scope > .message-scroller-viewport");
|
|
110
105
|
this.button = el.querySelector(":scope > .message-scroller-button");
|
|
111
106
|
if (!this.viewport) {
|
|
@@ -114,49 +109,29 @@ var MessageScroller = class _MessageScroller extends Component {
|
|
|
114
109
|
}
|
|
115
110
|
this._last = this.viewport.lastElementChild;
|
|
116
111
|
if (this.viewport.clientHeight > 0) this._open();
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
for (const item of Array.from(this.viewport.children)) this._resizeObserver.observe(item);
|
|
121
|
-
}
|
|
112
|
+
this._resizeObserver = new ResizeObserver(this._handleResize);
|
|
113
|
+
this._resizeObserver.observe(this.viewport, { box: "border-box" });
|
|
114
|
+
for (const item of Array.from(this.viewport.children)) this._resizeObserver.observe(item);
|
|
122
115
|
this._mutationObserver = new MutationObserver(this._handleMutations);
|
|
123
116
|
this._mutationObserver.observe(this.viewport, { childList: true });
|
|
124
|
-
|
|
117
|
+
const { signal } = this._events;
|
|
118
|
+
this.viewport.addEventListener("scroll", this._handleScroll, { passive: true, signal });
|
|
125
119
|
for (const type of ["wheel", "touchstart", "pointerdown", "keydown"]) {
|
|
126
|
-
this.viewport.addEventListener(type, this._handleUserScroll, { passive: true });
|
|
120
|
+
this.viewport.addEventListener(type, this._handleUserScroll, { passive: true, signal });
|
|
127
121
|
}
|
|
128
|
-
for (const type of RELEASE_EVENTS) document.addEventListener(type, this._handleRelease);
|
|
129
|
-
this.button?.addEventListener("click", this._handleButtonClick);
|
|
122
|
+
for (const type of RELEASE_EVENTS) document.addEventListener(type, this._handleRelease, { signal });
|
|
123
|
+
this.button?.addEventListener("click", this._handleButtonClick, { signal });
|
|
130
124
|
}
|
|
131
125
|
static get defaults() {
|
|
132
126
|
return _defaults;
|
|
133
127
|
}
|
|
134
|
-
/**
|
|
135
|
-
* Initializes instances of MessageScroller.
|
|
136
|
-
* @param els HTML elements.
|
|
137
|
-
* @param options Component options.
|
|
138
|
-
*/
|
|
139
|
-
static init(els, options = {}) {
|
|
140
|
-
return super.init(els, options, _MessageScroller);
|
|
141
|
-
}
|
|
142
|
-
static getInstance(el) {
|
|
143
|
-
return el["Expressive_MessageScroller"];
|
|
144
|
-
}
|
|
145
128
|
destroy() {
|
|
146
|
-
|
|
129
|
+
super.destroy();
|
|
147
130
|
if (!this.viewport) return;
|
|
148
131
|
this._resizeObserver?.disconnect();
|
|
149
132
|
this._mutationObserver?.disconnect();
|
|
150
|
-
this.viewport.removeEventListener("scroll", this._handleScroll);
|
|
151
|
-
for (const type of ["wheel", "touchstart", "pointerdown", "keydown"]) {
|
|
152
|
-
this.viewport.removeEventListener(type, this._handleUserScroll);
|
|
153
|
-
}
|
|
154
|
-
for (const type of RELEASE_EVENTS) document.removeEventListener(type, this._handleRelease);
|
|
155
133
|
this.viewport.style.removeProperty("--md-comp-message-scroller-spacer");
|
|
156
|
-
if (this.button)
|
|
157
|
-
this.button.removeEventListener("click", this._handleButtonClick);
|
|
158
|
-
this.button.inert = false;
|
|
159
|
-
}
|
|
134
|
+
if (this.button) this.button.inert = false;
|
|
160
135
|
}
|
|
161
136
|
/** Scrolls to the latest message and resumes following. */
|
|
162
137
|
scrollToEnd() {
|
|
@@ -214,7 +189,7 @@ var MessageScroller = class _MessageScroller extends Component {
|
|
|
214
189
|
}
|
|
215
190
|
this._target = target;
|
|
216
191
|
this._distance = Infinity;
|
|
217
|
-
const reduce =
|
|
192
|
+
const reduce = matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
218
193
|
v.scrollTo({
|
|
219
194
|
top: target === "end" ? v.scrollHeight : target,
|
|
220
195
|
behavior: reduce ? "auto" : "smooth"
|
|
@@ -285,8 +260,9 @@ var MessageScroller = class _MessageScroller extends Component {
|
|
|
285
260
|
this.button.inert = idle;
|
|
286
261
|
}
|
|
287
262
|
};
|
|
263
|
+
MessageScroller.key = "Expressive_MessageScroller";
|
|
288
264
|
|
|
289
265
|
export {
|
|
290
266
|
MessageScroller
|
|
291
267
|
};
|
|
292
|
-
//# sourceMappingURL=chunk-
|
|
268
|
+
//# sourceMappingURL=chunk-ANKFWNWT.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/ts/components/messageScroller.ts"],
|
|
4
|
+
"sourcesContent": ["import { Utils } from '../core/utils';\nimport { Component, BaseOptions } from '../core/component';\n\nexport interface MessageScrollerOptions extends BaseOptions {\n /**\n * If true, the viewport follows new content while the reader is at the\n * end, and a newly appended scroll anchor is brought to the top.\n * @default true\n */\n autoScroll: boolean;\n /**\n * Where the transcript opens: `'end'`, `'start'`, or `'last-anchor'`, the\n * start of the last anchored turn. `'last-anchor'` opens at the end when\n * that turn already fits in the viewport.\n * @default 'end'\n */\n defaultScrollPosition: 'start' | 'end' | 'last-anchor';\n /**\n * Pixels of the previous message left visible above an anchored turn or a\n * message reached with `scrollToMessage()`.\n * @default 64\n */\n peek: number;\n}\n\nconst _defaults: MessageScrollerOptions = {\n autoScroll: true,\n defaultScrollPosition: 'end',\n peek: 64\n};\n\n// Distance from a scroll target, in px, that still counts as reaching it.\n// Fractional layouts rarely land on the exact pixel.\nconst EDGE = 2;\n\n// Keys that scroll toward the start. They release following at once, before\n// the next streamed chunk can pull the viewport back to the end.\nconst UP_KEYS = new Set(['ArrowUp', 'PageUp', 'Home']);\n\n// Listened on the document: a scrollbar drag can end outside the viewport.\nconst RELEASE_EVENTS = ['pointerup', 'pointercancel', 'touchend', 'touchcancel'];\n\ntype Target = number | 'end';\n\n/**\n * A chat scroll container: a `.message-scroller` frame holding a scrolling\n * `.message-scroller-viewport` of messages and an optional\n * `.message-scroller-button`. Every child of the viewport is one message.\n *\n * While the reader is at the end, the viewport follows streamed output.\n * Scrolling toward the start releases it; reaching the end again, or the\n * button, resumes it. An appended message marked `data-scroll-anchor` starts a\n * turn and is scrolled to the top, with blank space below it until the reply\n * fills the viewport. Messages added above keep the reader's place.\n */\nexport class MessageScroller extends Component<MessageScrollerOptions> {\n /** The scrolling element. */\n viewport: HTMLElement;\n /** The scroll-to-latest button, if present. */\n button: HTMLButtonElement | null;\n private _opened = false;\n private _following = false;\n /** A press is down: it may be a tap or a scrollbar drag. */\n private _holding = false;\n private _lastTop = 0;\n /** Where a programmatic scroll is heading; null when none is running. */\n private _target: Target | null = null;\n /** Distance left to the target at the last scroll event. */\n private _distance = Infinity;\n /** The first visible message and its offset from the viewport top. */\n private _ref: Element | null = null;\n private _refOffset = 0;\n /** The latest anchored turn, which the spacer lets reach the top. */\n private _anchor: Element | null = null;\n private _spacer = 0;\n private _last: Element | null = null;\n private _resizeObserver: ResizeObserver | null = null;\n private _mutationObserver: MutationObserver | null = null;\n\n constructor(el: HTMLElement, options: Partial<MessageScrollerOptions>) {\n super(el, options);\n this.viewport = el.querySelector(':scope > .message-scroller-viewport');\n this.button = el.querySelector(':scope > .message-scroller-button');\n if (!this.viewport) {\n console.error('MessageScroller needs a .message-scroller-viewport child.');\n return;\n }\n this._last = this.viewport.lastElementChild;\n // A viewport that is not rendered yet (a closed dialog, a hidden tab)\n // has no size to position against; it opens on its first resize.\n if (this.viewport.clientHeight > 0) this._open();\n this._resizeObserver = new ResizeObserver(this._handleResize);\n // Border box: the spacer changes the padding, which must not count.\n this._resizeObserver.observe(this.viewport, { box: 'border-box' });\n for (const item of Array.from(this.viewport.children)) this._resizeObserver.observe(item);\n this._mutationObserver = new MutationObserver(this._handleMutations);\n this._mutationObserver.observe(this.viewport, { childList: true });\n const { signal } = this._events;\n this.viewport.addEventListener('scroll', this._handleScroll, { passive: true, signal });\n for (const type of ['wheel', 'touchstart', 'pointerdown', 'keydown']) {\n this.viewport.addEventListener(type, this._handleUserScroll, { passive: true, signal });\n }\n for (const type of RELEASE_EVENTS) document.addEventListener(type, this._handleRelease, { signal });\n this.button?.addEventListener('click', this._handleButtonClick, { signal });\n }\n\n static get defaults(): MessageScrollerOptions {\n return _defaults;\n }\n\n static key = 'Expressive_MessageScroller';\n\n destroy() {\n super.destroy();\n if (!this.viewport) return;\n this._resizeObserver?.disconnect();\n this._mutationObserver?.disconnect();\n this.viewport.style.removeProperty('--md-comp-message-scroller-spacer');\n if (this.button) this.button.inert = false;\n }\n\n /** Scrolls to the latest message and resumes following. */\n scrollToEnd() {\n // Set now: output streaming faster than the scroll can end it early.\n this._following = this.options.autoScroll;\n this._scrollTo('end');\n }\n\n /** Scrolls to the first message. */\n scrollToStart() {\n this._following = false;\n this._scrollTo(0);\n }\n\n /**\n * Scrolls the element with this id to the top of the viewport, below the\n * peek, and stops following.\n * @returns false when no such element is inside the viewport.\n */\n scrollToMessage(id: string): boolean {\n const target = Utils.getElementById(this.viewport, id);\n if (!target || !this.viewport.contains(target)) return false;\n this._following = false;\n this._scrollTo(this._top(target) - this.options.peek);\n return true;\n }\n\n private _open() {\n this._opened = true;\n const v = this.viewport;\n const position = this.options.defaultScrollPosition;\n const anchors = v.querySelectorAll(':scope > [data-scroll-anchor]');\n const anchor = position === 'last-anchor' ? anchors[anchors.length - 1] : null;\n if (position === 'start') v.scrollTop = 0;\n else if (anchor && this._contentEnd() - this._top(anchor) + this.options.peek > v.clientHeight) {\n v.scrollTop = this._top(anchor) - this.options.peek;\n } else v.scrollTop = v.scrollHeight;\n this._settle();\n }\n\n /**\n * Records where the reader is once no programmatic scroll is running.\n * Content can grow between a scroll and the resize that re-pins the end,\n * so only moving toward the start releases following.\n */\n private _settle() {\n const top = this.viewport.scrollTop;\n const kept = this._following && top >= this._lastTop - EDGE;\n this._following = this.options.autoScroll && (kept || this._atEnd());\n this._lastTop = top;\n this._capture();\n this._sync();\n }\n\n // A programmatic scroll ends when it arrives, or when a scroll moves away\n // from its target because something else took over.\n private _handleScroll = () => {\n if (this._target !== null) {\n const distance = Math.abs(this.viewport.scrollTop - this._resolve(this._target));\n if (distance > EDGE && distance < this._distance) {\n this._distance = distance;\n return;\n }\n this._target = null;\n }\n this._settle();\n };\n\n private _handleUserScroll = (e: Event) => {\n if (e.type === 'wheel' && (e as WheelEvent).deltaY >= 0) return;\n if (e.type === 'keydown' && !UP_KEYS.has((e as KeyboardEvent).key)) return;\n this._target = null;\n // A press may be a tap on a message or the start of a drag. Hold the end\n // until it is released; a scroll toward the start releases following.\n if (e.type === 'pointerdown' || e.type === 'touchstart') this._holding = true;\n else this._following = false;\n };\n\n private _handleRelease = () => {\n if (!this._holding) return;\n this._holding = false;\n if (this._following) this.viewport.scrollTop = this.viewport.scrollHeight;\n this._sync();\n };\n\n private _handleButtonClick = () => this.scrollToEnd();\n\n private _handleMutations = (records: MutationRecord[]) => {\n for (const record of records) {\n record.addedNodes.forEach((node) => {\n if (node instanceof Element) this._resizeObserver.observe(node);\n });\n record.removedNodes.forEach((node) => {\n if (node instanceof Element) this._resizeObserver.unobserve(node);\n });\n }\n const previous = this._last;\n this._last = this.viewport.lastElementChild;\n if (!this._opened) return;\n // Restore here, not only on resize: this runs before any scroll event\n // that could record the shifted position as the reader's place.\n if (!this._following && this._target === null) this._restore();\n if (!this.options.autoScroll) return;\n // Only messages appended after the previous last one start a new turn;\n // anchors in prepended history do not. If the last one was removed, the\n // list was replaced and nothing counts as appended.\n if (previous && previous.parentElement !== this.viewport) return;\n for (let item = this._last; item && item !== previous; item = item.previousElementSibling) {\n if (item.hasAttribute('data-scroll-anchor')) {\n this._anchor = item;\n this._updateSpacer();\n // Follow the reply once the turn reaches the top, unless the reader\n // scrolls away first. _settle keeps it because the scroll went down.\n this._following = true;\n this._scrollTo(this._top(item) - this.options.peek);\n return;\n }\n }\n };\n\n private _handleResize = () => {\n if (!this._opened) {\n if (this.viewport.clientHeight > 0) this._open();\n return;\n }\n this._updateSpacer();\n const v = this.viewport;\n if (this._target === 'end') this._scrollTo('end');\n else if (this._target === null) {\n if (this._following && !this._holding) v.scrollTop = v.scrollHeight;\n else this._restore();\n }\n this._sync();\n };\n\n private _scrollTo(target: Target) {\n const v = this.viewport;\n if (Math.abs(v.scrollTop - this._resolve(target)) <= EDGE) {\n this._target = null;\n this._settle();\n return;\n }\n this._target = target;\n this._distance = Infinity;\n const reduce = matchMedia('(prefers-reduced-motion: reduce)').matches;\n v.scrollTo({\n top: target === 'end' ? v.scrollHeight : target,\n behavior: reduce ? 'auto' : 'smooth'\n });\n }\n\n private _resolve(target: Target) {\n const max = this.viewport.scrollHeight - this.viewport.clientHeight;\n return target === 'end' ? max : Math.max(0, Math.min(target, max));\n }\n\n private _atEnd() {\n const v = this.viewport;\n return v.scrollHeight - v.scrollTop - v.clientHeight <= EDGE;\n }\n\n /** Offset of an element from the top of the scrolled content. */\n private _top(el: Element) {\n const v = this.viewport;\n return el.getBoundingClientRect().top - v.getBoundingClientRect().top - v.clientTop + v.scrollTop;\n }\n\n /** Bottom of the content without the spacer, padding included. */\n private _contentEnd() {\n const last = this.viewport.lastElementChild;\n if (!last) return 0;\n const padding = parseFloat(getComputedStyle(this.viewport).paddingBlockEnd) - this._spacer;\n return this._top(last) + last.getBoundingClientRect().height + padding;\n }\n\n /** Remembers the first visible message so prepends can keep it in place. */\n private _capture() {\n const items = this.viewport.children;\n const top = this.viewport.getBoundingClientRect().top + this.viewport.clientTop;\n let low = 0;\n let high = items.length - 1;\n while (low < high) {\n const mid = (low + high) >> 1;\n if (items[mid].getBoundingClientRect().bottom > top) high = mid;\n else low = mid + 1;\n }\n this._ref = items[low] ?? null;\n this._refOffset = this._ref ? this._ref.getBoundingClientRect().top - top : 0;\n }\n\n /** Moves the remembered message back to where the reader last saw it. */\n private _restore() {\n if (this._ref?.parentElement !== this.viewport) {\n this._capture();\n return;\n }\n const top = this.viewport.getBoundingClientRect().top + this.viewport.clientTop;\n const delta = this._ref.getBoundingClientRect().top - top - this._refOffset;\n if (Math.abs(delta) >= 1) this.viewport.scrollTop += delta;\n }\n\n /** Sizes the blank space that lets the latest anchored turn reach the top. */\n private _updateSpacer() {\n let space = 0;\n if (this._anchor?.parentElement === this.viewport) {\n const room = this._top(this._anchor) - this.options.peek + this.viewport.clientHeight;\n space = Math.max(0, Math.ceil(room - this._contentEnd()));\n } else this._anchor = null;\n if (space === this._spacer) return;\n this._spacer = space;\n if (space) this.viewport.style.setProperty('--md-comp-message-scroller-spacer', `${space}px`);\n else this.viewport.style.removeProperty('--md-comp-message-scroller-spacer');\n }\n\n /** The button is inert while there is nothing below. */\n private _sync() {\n if (!this.button) return;\n const idle = this._atEnd();\n // The button's own root: inside a shadow root, document.activeElement is the host.\n const root = this.button.getRootNode() as Document | ShadowRoot;\n if (idle && root.activeElement === this.button) this.viewport.focus({ preventScroll: true });\n this.button.inert = idle;\n }\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;AAyBA,IAAM,YA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