@luzmo/analytics-components-kit 1.0.1-alpha.4 → 1.0.1-alpha.5
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/components/async-directive-FGzMycjH-Bgeca09f.js +152 -0
- package/components/async-directive-FGzMycjH-CeG35vZ3.cjs +56 -0
- package/components/base-BjTwmyRF.cjs +24 -0
- package/components/base-D76d76ww-BiajPmzU.cjs +40 -0
- package/components/base-D76d76ww-gf0ESLsU.js +45 -0
- package/components/base-D76d76ww.js +28 -0
- package/components/button-base-CDLQV7Vk-BXgdcJZo.cjs +43 -0
- package/{lib/button-base-CtfPWS-P.js → components/button-base-CDLQV7Vk-C_3zTrbV.js} +55 -36
- package/components/checkbox-mixin-DXUIwtea-DNISZS47.cjs +45 -0
- package/components/checkbox-mixin-DXUIwtea-wiCZr_KI.js +88 -0
- package/components/directive-helpers-BLDZnGQv-DYFfxaqA.cjs +80 -0
- package/components/directive-helpers-BLDZnGQv-oKMCBvb2.js +115 -0
- package/components/display-settings/display-settings.d.ts +70 -0
- package/components/display-settings/index.cjs +105 -0
- package/components/display-settings/index.d.ts +7 -0
- package/components/display-settings/index.js +238 -0
- package/components/display-settings-binning/display-settings-binning.d.ts +32 -0
- package/components/display-settings-binning/index.cjs +51 -0
- package/components/display-settings-binning/index.d.ts +7 -0
- package/components/display-settings-binning/index.js +137 -0
- package/components/display-settings-datetime/display-settings-datetime.d.ts +85 -0
- package/{lib/draggable-data-item → components/display-settings-datetime}/index.cjs +1 -1
- package/components/display-settings-datetime/index.d.ts +7 -0
- package/{lib/draggable-data-item → components/display-settings-datetime}/index.js +2 -2
- package/components/display-settings-grand-totals/display-settings-grand-totals.d.ts +30 -0
- package/{lib/index-C4ePDYEC.cjs → components/display-settings-grand-totals/index.cjs} +4 -4
- package/components/display-settings-grand-totals/index.d.ts +7 -0
- package/components/display-settings-grand-totals/index.js +115 -0
- package/components/display-settings-numeric/display-settings-numeric.d.ts +73 -0
- package/components/display-settings-numeric/helpers/constants.d.ts +17 -0
- package/components/display-settings-numeric/index.cjs +146 -0
- package/components/display-settings-numeric/index.d.ts +7 -0
- package/{lib/index-CM80_HQw.js → components/display-settings-numeric/index.js} +106 -96
- package/components/display-settings-period-over-period/display-settings-period-over-period.d.ts +44 -0
- package/components/display-settings-period-over-period/helpers/constants.d.ts +33 -0
- package/components/display-settings-period-over-period/index.cjs +103 -0
- package/components/display-settings-period-over-period/index.d.ts +7 -0
- package/{lib/index-DJp_9h0l.js → components/display-settings-period-over-period/index.js} +104 -123
- package/components/divider.module-DwOuLGU3-B19eHVg2.js +40 -0
- package/components/divider.module-DwOuLGU3-Bg8RrFkc.cjs +36 -0
- package/components/draggable-data-item/draggable-data-item.d.ts +25 -0
- package/components/draggable-data-item/index.cjs +55 -0
- package/components/draggable-data-item/index.d.ts +7 -0
- package/components/draggable-data-item/index.js +140 -0
- package/components/draggable-data-item-level/draggable-data-item-level.d.ts +29 -0
- package/components/draggable-data-item-level/helpers/calculate-type-icon.d.ts +2 -0
- package/components/draggable-data-item-level/helpers/generate-preview.d.ts +1 -0
- package/components/draggable-data-item-level/index.cjs +36 -0
- package/components/draggable-data-item-level/index.d.ts +7 -0
- package/{lib/index-DrIA0eFE.js → components/draggable-data-item-level/index.js} +137 -236
- package/components/droppable-slot/droppable-slot.d.ts +49 -0
- package/components/droppable-slot/index.cjs +69 -0
- package/components/droppable-slot/index.d.ts +7 -0
- package/components/droppable-slot/index.js +255 -0
- package/components/droppable-slot/item-slots-configs/area-chart-slots.config.d.ts +44 -0
- package/components/droppable-slot/item-slots-configs/bar-chart-slots.config.d.ts +24 -0
- package/components/droppable-slot/item-slots-configs/donut-chart-slots.config.d.ts +20 -0
- package/components/edit-item/edit-item.d.ts +50 -0
- package/components/edit-item/index.cjs +85 -0
- package/components/edit-item/index.d.ts +7 -0
- package/components/edit-item/index.js +333 -0
- package/components/edit-option/edit-option.d.ts +22 -0
- package/components/edit-option/helpers/control-markup.d.ts +14 -0
- package/components/edit-option/helpers/control-templates/action-button-group-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/color-picker-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/multi-language-field-template.d.ts +8 -0
- package/components/edit-option/helpers/control-templates/number-field-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/picker-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/positions-number-field-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/radio-button-group.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/slider-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/switch-template.d.ts +2 -0
- package/components/edit-option/helpers/control-templates/text-field-template.d.ts +7 -0
- package/components/edit-option/helpers/generate-callback.d.ts +1 -0
- package/components/edit-option/helpers/get-control-by-key.d.ts +1 -0
- package/components/edit-option/helpers/get-extra-label-values.d.ts +7 -0
- package/components/edit-option/helpers/get-value-by-key.d.ts +1 -0
- package/components/edit-option/index.cjs +176 -0
- package/components/edit-option/index.d.ts +7 -0
- package/components/edit-option/index.js +507 -0
- package/components/edit-option/item-configs/bar-chart.config.d.ts +108 -0
- package/components/edit-option/item-configs/column-chart.config.d.ts +108 -0
- package/components/edit-option/item-configs/donut-chart.config.d.ts +102 -0
- package/components/edit-option/item-configs/imageobject.config.d.ts +128 -0
- package/components/edit-option/item-configs/line-chart.config.d.ts +96 -0
- package/components/edit-option/item-configs/textobject.config.d.ts +13 -0
- package/components/edit-option/item-translations/bar-chart.en.d.ts +48 -0
- package/components/edit-option/item-translations/bar-chart.fr.d.ts +23 -0
- package/components/edit-option/item-translations/bar-chart.nl.d.ts +23 -0
- package/components/edit-option/item-translations/donut-chart.en.d.ts +64 -0
- package/components/edit-option/item-translations/donut-chart.fr.d.ts +18 -0
- package/components/edit-option/item-translations/donut-chart.nl.d.ts +18 -0
- package/components/edit-option-action-button-group/edit-option-action-button-group.d.ts +27 -0
- package/components/edit-option-action-button-group/index.cjs +44 -0
- package/components/edit-option-action-button-group/index.d.ts +7 -0
- package/components/edit-option-action-button-group/index.js +144 -0
- package/components/edit-option-base/edit-option-base.d.ts +22 -0
- package/components/edit-option-base-DnrerC_T.cjs +53 -0
- package/components/edit-option-base-oIvlolV9.js +120 -0
- package/components/edit-option-color-picker/edit-option-color-picker.d.ts +23 -0
- package/components/edit-option-color-picker/index.cjs +472 -0
- package/components/edit-option-color-picker/index.d.ts +7 -0
- package/components/edit-option-color-picker/index.js +2553 -0
- package/components/edit-option-multi-language-field/edit-option-multi-language-field.d.ts +15 -0
- package/components/edit-option-multi-language-field/index.cjs +31 -0
- package/components/edit-option-multi-language-field/index.d.ts +7 -0
- package/components/edit-option-multi-language-field/index.js +102 -0
- package/components/edit-option-number-field/edit-option-number-field.d.ts +19 -0
- package/components/edit-option-number-field/index.cjs +32 -0
- package/components/edit-option-number-field/index.d.ts +7 -0
- package/components/edit-option-number-field/index.js +115 -0
- package/components/edit-option-picker/edit-option-picker.d.ts +22 -0
- package/components/edit-option-picker/index.cjs +35 -0
- package/components/edit-option-picker/index.d.ts +7 -0
- package/components/edit-option-picker/index.js +106 -0
- package/components/edit-option-positions-number-field/edit-option-positions-number-field.d.ts +28 -0
- package/components/edit-option-positions-number-field/index.cjs +42 -0
- package/components/edit-option-positions-number-field/index.d.ts +7 -0
- package/components/edit-option-positions-number-field/index.js +170 -0
- package/components/edit-option-radio-button-group/edit-option-radio-button-group.d.ts +18 -0
- package/components/edit-option-radio-button-group/index.cjs +36 -0
- package/components/edit-option-radio-button-group/index.d.ts +7 -0
- package/components/edit-option-radio-button-group/index.js +113 -0
- package/components/edit-option-slider/edit-option-slider.d.ts +15 -0
- package/components/edit-option-slider/index.cjs +48 -0
- package/components/edit-option-slider/index.d.ts +7 -0
- package/components/edit-option-slider/index.js +1253 -0
- package/components/edit-option-switch/edit-option-switch.d.ts +11 -0
- package/components/edit-option-switch/index.cjs +50 -0
- package/components/edit-option-switch/index.d.ts +7 -0
- package/components/edit-option-switch/index.js +171 -0
- package/components/edit-option-text-field/edit-option-text-field.d.ts +15 -0
- package/components/edit-option-text-field/index.cjs +31 -0
- package/components/edit-option-text-field/index.d.ts +7 -0
- package/components/edit-option-text-field/index.js +100 -0
- package/components/element-resolution-FCUT-wql--7ctE626.js +163 -0
- package/components/element-resolution-FCUT-wql-DSTvdyds.cjs +68 -0
- package/{lib/en-CIeY2T5K.js → components/en-BsAhbMzm.js} +101 -102
- package/components/en-CdROUdjt.cjs +202 -0
- package/{lib/en-GB-BqYHIX1v.cjs → components/en-GB-g8rSQSba.cjs} +1 -1
- package/{lib/en-GB-CYx--4nh.js → components/en-GB-qub-Kemt.js} +1 -1
- package/components/focus-group-DHeTq18L-C9l9oHwM.cjs +36 -0
- package/components/focus-group-DHeTq18L-rNUu13eb.js +237 -0
- package/{lib/get-css-variable-BHHQ0SnL.js → components/get-css-variable-Bhbr-Kr1.js} +379 -410
- package/components/get-css-variable-DLiZYZEi.cjs +24 -0
- package/components/if-defined-CYpcjGCb-Bzbg7zmM.cjs +60 -0
- package/components/if-defined-CYpcjGCb-tXzyj9Dq.js +95 -0
- package/components/if-defined-Ch2dtEOS.js +29 -0
- package/components/if-defined-DMSuo5Qx.cjs +24 -0
- package/components/index-3ewegRbb.cjs +67 -0
- package/components/index-B0cBkCaq.cjs +39 -0
- package/components/index-B2N_PZf3.js +164 -0
- package/components/index-B2z7i1-X.js +77 -0
- package/components/index-B5VaT0lQ.js +145 -0
- package/components/index-BC-nmKjU.js +104 -0
- package/{lib/droppable-slot/index.js → components/index-BD3VxQBH.js} +18 -4
- package/components/index-BGaxFTL4.js +299 -0
- package/{lib/index-B9h2L_hV.js → components/index-BRk42NQn.js} +1235 -1112
- package/components/index-Bjs6Yqet.cjs +185 -0
- package/components/index-Bofs4Q2E.cjs +36 -0
- package/components/index-BqTdFs1o.js +77 -0
- package/components/index-C2qG2Sm8-BQUlk-w0.js +935 -0
- package/components/index-C2qG2Sm8-CbVWlbag.cjs +95 -0
- package/components/index-CTPox3yS.cjs +54 -0
- package/components/index-C_3Ak4MQ.cjs +59 -0
- package/components/index-CayjvyyX.cjs +95 -0
- package/components/index-CkDDDzuJ.js +744 -0
- package/{lib/progress-circle/index.js → components/index-Cp-lHUlX.js} +53 -20
- package/components/index-CtHO6VyI.cjs +42 -0
- package/components/index-D4x-O9Uc.cjs +192 -0
- package/components/index-D9vzXhtJ.cjs +95 -0
- package/components/index-DQiQXn8N.cjs +36 -0
- package/{lib/picker/index.js → components/index-DVaeDCbe.js} +22 -6
- package/components/index-DskAouD-.js +317 -0
- package/{lib/index-CBCm4_7S.js → components/index-DszPbTTD.js} +401 -460
- package/{lib/index-Bd4cKS9O.js → components/index-EQldC-LR.js} +67 -47
- package/components/index-ON4x-yZ7.cjs +36 -0
- package/components/index-gfU9TGd5.cjs +57 -0
- package/components/index-liTHhAef.cjs +36 -0
- package/components/index.cjs +20 -0
- package/components/index.js +74 -0
- package/components/language-resolution-8yZa5r_P-CTSmbE1U.js +161 -0
- package/components/language-resolution-8yZa5r_P-DQ3rZzW5.cjs +52 -0
- package/components/localize-B6AsX_Zv.js +52 -0
- package/components/localize-DbobqcKs.cjs +20 -0
- package/components/luzmo-icons-BrtBl3E5.cjs +31 -0
- package/{lib/index-DdtjeKYI.js → components/luzmo-icons-CZEpXpvy.js} +157 -472
- package/components/observe-slot-text-BG0H7bQK-C0wmc4DO.js +221 -0
- package/components/observe-slot-text-BG0H7bQK-CrkAqUMj.cjs +86 -0
- package/{lib/popover-Bwnkg-5-.js → components/popover-bg0EQQ8p-D4-hrhIx.js} +25 -6
- package/components/popover-bg0EQQ8p-Dha09dhV.cjs +48 -0
- package/components/property-CD3dwBJC.js +1447 -0
- package/components/property-Su1Q6aME.cjs +124 -0
- package/components/query-D5qWDopr.cjs +24 -0
- package/components/query-Ddbd72Um.js +39 -0
- package/components/query-assigned-nodes-C76XVPWY-BcyGjObB.cjs +40 -0
- package/components/query-assigned-nodes-C76XVPWY-DPC6kOmH.js +55 -0
- package/components/roving-tabindex-DOg4z6ZU-DmyYPRYY.cjs +36 -0
- package/components/roving-tabindex-DOg4z6ZU-dufnVmvL.js +85 -0
- package/components/sized-mixin-PyCYpyQq-B40Ek2UB.js +82 -0
- package/components/sized-mixin-PyCYpyQq-sKzDjc75.cjs +36 -0
- package/components/slot-menu/index.cjs +55 -0
- package/components/slot-menu/index.d.ts +7 -0
- package/components/slot-menu/index.js +188 -0
- package/components/slot-menu/slot-menu.d.ts +66 -0
- package/components/slot-menu-list/index.cjs +39 -0
- package/components/slot-menu-list/index.d.ts +7 -0
- package/components/slot-menu-list/index.js +351 -0
- package/components/slot-menu-list/slot-menu-list.d.ts +33 -0
- package/components/state-B1a8XIDm.js +31 -0
- package/components/state-ByiKNRhp.cjs +24 -0
- package/components/task-BPD0PyaQ.js +120 -0
- package/components/task-HFsHfTra.cjs +24 -0
- package/components/text-field-7ITo3Lac-CKXsSqJP.cjs +131 -0
- package/components/text-field-7ITo3Lac-DqVO04kR.js +412 -0
- package/{lib/index-D_KYpfBM.js → components/utils.cjs} +1 -5
- package/{lib/droppable-slot/index.cjs → components/utils.js} +1 -1
- package/components/when-CDK1Tt5Y-BN3qcTK0.cjs +40 -0
- package/components/when-CDK1Tt5Y-C6ViXC43.js +47 -0
- package/custom-elements.json +3562 -884
- package/index.d.ts +23 -0
- package/package.json +132 -17
- package/utils/formatter/calculate-duration.d.ts +2 -0
- package/utils/formatter/decompose-numeric-format.d.ts +11 -0
- package/utils/formatter/default-local-formats.d.ts +20 -0
- package/utils/formatter/formats/cs.d.ts +20 -0
- package/utils/formatter/formats/da.d.ts +20 -0
- package/utils/formatter/formats/de.d.ts +21 -0
- package/utils/formatter/formats/en-GB.d.ts +21 -0
- package/utils/formatter/formats/en-US.d.ts +1 -0
- package/utils/formatter/formats/en.d.ts +1 -0
- package/utils/formatter/formats/es.d.ts +54 -0
- package/utils/formatter/formats/fi.d.ts +20 -0
- package/utils/formatter/formats/fr.d.ts +54 -0
- package/utils/formatter/formats/he.d.ts +20 -0
- package/utils/formatter/formats/hu.d.ts +20 -0
- package/utils/formatter/formats/it.d.ts +54 -0
- package/utils/formatter/formats/ja.d.ts +20 -0
- package/utils/formatter/formats/ko.d.ts +20 -0
- package/utils/formatter/formats/mk.d.ts +20 -0
- package/utils/formatter/formats/nl.d.ts +21 -0
- package/utils/formatter/formats/no.d.ts +21 -0
- package/utils/formatter/formats/pl.d.ts +20 -0
- package/utils/formatter/formats/pt.d.ts +20 -0
- package/utils/formatter/formats/ru.d.ts +20 -0
- package/utils/formatter/formats/sv.d.ts +20 -0
- package/utils/formatter/formats/tr.d.ts +21 -0
- package/utils/formatter/formats/zh-CN.d.ts +20 -0
- package/utils/formatter/formats/zh-TW.d.ts +20 -0
- package/utils/formatter/formatter.d.ts +9 -0
- package/utils/formatter/localize.d.ts +3 -0
- package/utils/formatter/smart-datetime-formats.const.d.ts +36 -0
- package/utils/get-css-variable.d.ts +1 -0
- package/utils/index.d.ts +1 -0
- package/utils/time/formats.const.d.ts +8 -0
- package/utils/time/periods.const.d.ts +29 -0
- package/utils/types/column.types.d.ts +56 -0
- package/utils/types/type-check.d.ts +7 -0
- package/lib/async-directive-CPjMHOPu.cjs +0 -24
- package/lib/async-directive-SCUUQ3Mh.js +0 -114
- package/lib/button-base-B4PdJFVe.cjs +0 -27
- package/lib/directive-helpers-BSB0tfc9.cjs +0 -32
- package/lib/directive-helpers-eY1rHtyn.js +0 -154
- package/lib/divider.module-BW8qaMVq.js +0 -211
- package/lib/divider.module-DEy88Ieh.cjs +0 -20
- package/lib/en-BDBzmAXX.cjs +0 -202
- package/lib/get-css-variable-D439CdH9.cjs +0 -24
- package/lib/if-defined-BbzmSG-O.js +0 -757
- package/lib/if-defined-V7yEJWI3.cjs +0 -54
- package/lib/index-0314DjEl.cjs +0 -20
- package/lib/index-BDXFsKUM.cjs +0 -146
- package/lib/index-BmAD29P2.js +0 -106
- package/lib/index-Bo1DpZ-1.cjs +0 -58
- package/lib/index-C9xEN5Ji.js +0 -82
- package/lib/index-CcF-9wyF.cjs +0 -71
- package/lib/index-CfEm5P0J.cjs +0 -196
- package/lib/index-CrWoFMZ3.cjs +0 -22
- package/lib/index-CtEJZdT0.js +0 -1627
- package/lib/index-CvX-HLY1.cjs +0 -322
- package/lib/index-D37RwuEH.js +0 -1584
- package/lib/index-D5puKlcm.cjs +0 -96
- package/lib/index-DGz6jCKo.cjs +0 -26
- package/lib/index-DSbgZduE.js +0 -501
- package/lib/index-Dj7PF4Q9.cjs +0 -63
- package/lib/index-Dq3HAOaM.js +0 -127
- package/lib/index-jt6FL_uE.cjs +0 -20
- package/lib/index-kJR406YZ.cjs +0 -112
- package/lib/index-v8ZTprPO.cjs +0 -51
- package/lib/index.cjs +0 -875
- package/lib/index.js +0 -6411
- package/lib/observe-slot-text-DOYmGOZe.js +0 -181
- package/lib/observe-slot-text-oJ0a2KY9.cjs +0 -42
- package/lib/picker/index.cjs +0 -20
- package/lib/popover-CQGN8nbX.cjs +0 -32
- package/lib/progress-circle/index.cjs +0 -35
- /package/{lib → components}/area-chart-slots.config-BLxiYX05.cjs +0 -0
- /package/{lib → components}/area-chart-slots.config-C0c2ZzBh.js +0 -0
- /package/{lib → components}/bar-chart-slots.config-GSSL7XVA.js +0 -0
- /package/{lib → components}/bar-chart-slots.config-Jx1PveTM.cjs +0 -0
- /package/{lib → components}/bar-chart.config-B57geUzJ.cjs +0 -0
- /package/{lib → components}/bar-chart.config-CQ6HAvs2.js +0 -0
- /package/{lib → components}/bar-chart.en-BqYbiHO3.cjs +0 -0
- /package/{lib → components}/bar-chart.en-FwT00qdU.js +0 -0
- /package/{lib → components}/bar-chart.fr-DGx9smEh.cjs +0 -0
- /package/{lib → components}/bar-chart.fr-DbxKiM0j.js +0 -0
- /package/{lib → components}/bar-chart.nl-BYzVExsz.cjs +0 -0
- /package/{lib → components}/bar-chart.nl-ahX1ARpH.js +0 -0
- /package/{lib → components}/column-chart.config-B57geUzJ.cjs +0 -0
- /package/{lib → components}/column-chart.config-C9hP0kX7.js +0 -0
- /package/{lib → components}/cs-DVZ0Tapy.js +0 -0
- /package/{lib → components}/cs-I9E81keK.cjs +0 -0
- /package/{lib → components}/da-DHy05oSR.js +0 -0
- /package/{lib → components}/da-QkdvupDg.cjs +0 -0
- /package/{lib → components}/de-Dn5mUzha.cjs +0 -0
- /package/{lib → components}/de-iM39JlAt.js +0 -0
- /package/{lib → components}/decompose-numeric-format-B3rVVHpO.cjs +0 -0
- /package/{lib → components}/decompose-numeric-format-BuZcjH2k.js +0 -0
- /package/{lib → components}/donut-chart-slots.config-BEwhfq27.js +0 -0
- /package/{lib → components}/donut-chart-slots.config-DIp-24lO.cjs +0 -0
- /package/{lib → components}/donut-chart.config-3DhKiSSM.js +0 -0
- /package/{lib → components}/donut-chart.config-DLWJUlHx.cjs +0 -0
- /package/{lib → components}/donut-chart.en-Blb9oSdU.cjs +0 -0
- /package/{lib → components}/donut-chart.en-CzjT4-XN.js +0 -0
- /package/{lib → components}/donut-chart.fr-BeTVa2wh.cjs +0 -0
- /package/{lib → components}/donut-chart.fr-DftPrKbG.js +0 -0
- /package/{lib → components}/donut-chart.nl-D9YGbOce.cjs +0 -0
- /package/{lib → components}/donut-chart.nl-NMatXfhK.js +0 -0
- /package/{lib → components}/es-CwyPlN5d.cjs +0 -0
- /package/{lib → components}/es-KhTq4jX8.js +0 -0
- /package/{lib → components}/fi-Dh_ebgpe.js +0 -0
- /package/{lib → components}/fi-rijeZE5V.cjs +0 -0
- /package/{lib → components}/fr-BcgE-6S_.cjs +0 -0
- /package/{lib → components}/fr-CU727YF1.js +0 -0
- /package/{lib → components}/he-Au3xg6lR.js +0 -0
- /package/{lib → components}/he-O6Ih8Bqh.cjs +0 -0
- /package/{lib → components}/hu-BnZ8y3xQ.cjs +0 -0
- /package/{lib → components}/hu-DNJ-P_MW.js +0 -0
- /package/{lib → components}/imageobject.config-B7ld9bj3.cjs +0 -0
- /package/{lib → components}/imageobject.config-DZLp9Elq.js +0 -0
- /package/{lib → components}/it-Bh5U73z6.js +0 -0
- /package/{lib → components}/it-PshtLMkq.cjs +0 -0
- /package/{lib → components}/ja-CCcHUL61.js +0 -0
- /package/{lib → components}/ja-KIS2HdaG.cjs +0 -0
- /package/{lib → components}/ko--l4qmjLV.cjs +0 -0
- /package/{lib → components}/ko-DhapsZMM.js +0 -0
- /package/{lib → components}/line-chart.config-BZcvfO2c.cjs +0 -0
- /package/{lib → components}/line-chart.config-CIVN6uLI.js +0 -0
- /package/{lib → components}/mk-B9HPSuKa.js +0 -0
- /package/{lib → components}/mk-DZlj-edb.cjs +0 -0
- /package/{lib → components}/nl-BKlDqOXb.cjs +0 -0
- /package/{lib → components}/nl-BwSt5Bf4.js +0 -0
- /package/{lib → components}/no-D-DofYnx.js +0 -0
- /package/{lib → components}/no-D_SzxhTu.cjs +0 -0
- /package/{lib → components}/pl-D_L_0Boq.js +0 -0
- /package/{lib → components}/pl-PIK23rK_.cjs +0 -0
- /package/{lib → components}/pt-B0BBS5VB.js +0 -0
- /package/{lib → components}/pt-Dqlu4MS5.cjs +0 -0
- /package/{lib → components}/ru-Vo-m3O_2.js +0 -0
- /package/{lib → components}/ru-zyNDTB04.cjs +0 -0
- /package/{lib → components}/sv-1DPTltNQ.cjs +0 -0
- /package/{lib → components}/sv-CiozMaev.js +0 -0
- /package/{lib → components}/textobject.config-C8opcGG4.js +0 -0
- /package/{lib → components}/textobject.config-DbAajFz8.cjs +0 -0
- /package/{lib → components}/tr-BkmWvOG2.cjs +0 -0
- /package/{lib → components}/tr-D_D4i5iv.js +0 -0
- /package/{lib → components}/zh-CN-DTZ4OmdP.cjs +0 -0
- /package/{lib → components}/zh-CN-wsl7eFSd.js +0 -0
- /package/{lib → components}/zh-TW-DTZ4OmdP.cjs +0 -0
- /package/{lib → components}/zh-TW-wsl7eFSd.js +0 -0
package/lib/index-Dj7PF4Q9.cjs
DELETED
@@ -1,63 +0,0 @@
|
|
1
|
-
/*! * A kit of modern Luzmo Web Components for analytics in your web application.
|
2
|
-
*
|
3
|
-
* Copyright © 2024 Luzmo
|
4
|
-
* All rights reserved.
|
5
|
-
* Luzmo web components (“Luzmo Web Components”)
|
6
|
-
* must be used according to the Luzmo Terms of Service.
|
7
|
-
* This license allows users with a current active Luzmo account
|
8
|
-
* to use the Luzmo Web Components. This license terminates
|
9
|
-
* automatically if a user no longer has an active Luzmo account.
|
10
|
-
* Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
|
11
|
-
*
|
12
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
13
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
14
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
15
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
16
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
17
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
18
|
-
* SOFTWARE.
|
19
|
-
* */
|
20
|
-
"use strict";const z=require("./index-Bo1DpZ-1.cjs"),m=require("./async-directive-CPjMHOPu.cjs"),d=require("./if-defined-V7yEJWI3.cjs"),Z=require("./directive-helpers-BSB0tfc9.cjs"),J=require("./button-base-B4PdJFVe.cjs"),Q=require("./index-CvX-HLY1.cjs"),O=Symbol("language resolver updated");class M{constructor(e){this.language=document.documentElement.lang||navigator.language,this.host=e,this.host.addController(this)}hostConnected(){this.resolveLanguage()}hostDisconnected(){var e;(e=this.unsubscribe)==null||e.call(this)}resolveLanguage(){const e=new CustomEvent("luzmo-language-context",{bubbles:!0,composed:!0,detail:{callback:(t,r)=>{const o=this.language;this.language=t,this.unsubscribe=r,this.host.requestUpdate(O,o)}},cancelable:!0});this.host.dispatchEvent(e)}}const f=["",()=>{}];class ee extends m.f{constructor(){super(...arguments),this.start=f,this.streamInside=f,this.end=f,this.streamOutside=f,this.state="off",this.handleStart=e=>{this.clearStream(),this.callHandler(this.start[1],e),!e.defaultPrevented&&(this.removeListeners(),this.addListeners("on"))},this.handleInside=e=>{this.handleStream(this.streamInside[1],e)},this.handleEnd=e=>{this.clearStream(),this.callHandler(this.end[1],e),this.removeListeners(),this.addListeners("off")},this.handleOutside=e=>{this.handleStream(this.streamOutside[1],e)}}render(e){return d.E}update(e,[{start:t,end:r,streamInside:o=f,streamOutside:i=f}]){var n;this.element!==e.element&&(this.element=e.element,this.removeListeners()),this.host=((n=e.options)==null?void 0:n.host)||this.element,this.start=t,this.end=r,this.streamInside=o,this.streamOutside=i,this.addListeners()}addListeners(e){this.state=e||this.state,this.state==="off"?(this.addListener(this.streamOutside[0],this.handleOutside),this.addListener(this.start[0],this.handleStart)):this.state==="on"&&(this.addListener(this.streamInside[0],this.handleInside),this.addListener(this.end[0],this.handleEnd))}callHandler(e,t){typeof e=="function"?e.call(this.host,t):e.handleEvent(t)}handleStream(e,t){this.stream||(this.callHandler(e,t),this.stream=requestAnimationFrame(()=>{this.stream=void 0}))}clearStream(){this.stream!=null&&(cancelAnimationFrame(this.stream),this.stream=void 0)}addListener(e,t){Array.isArray(e)?e.map(r=>{this.element.addEventListener(r,t)}):this.element.addEventListener(e,t)}removeListener(e,t){Array.isArray(e)?e.map(r=>{this.element.removeEventListener(r,t)}):this.element.removeEventListener(e,t)}removeListeners(){this.removeListener(this.start[0],this.handleStart),this.removeListener(this.streamInside[0],this.handleInside),this.removeListener(this.end[0],this.handleEnd),this.removeListener(this.streamOutside[0],this.handleOutside)}disconnected(){this.removeListeners()}reconnected(){this.addListeners()}}const A=Z.e(ee);let S=new Map,C=!1;try{C=new Intl.NumberFormat("de-DE",{signDisplay:"exceptZero"}).resolvedOptions().signDisplay==="exceptZero"}catch{}let x=!1;try{x=new Intl.NumberFormat("de-DE",{style:"unit",unit:"degree"}).resolvedOptions().style==="unit"}catch{}const B={degree:{narrow:{default:"°","ja-JP":" 度","zh-TW":"度","sl-SI":" °"}}};class k{format(e){let t="";if(!C&&this.options.signDisplay!=null?t=re(this.numberFormatter,this.options.signDisplay,e):t=this.numberFormatter.format(e),this.options.style==="unit"&&!x){var r;let{unit:o,unitDisplay:i="short",locale:n}=this.resolvedOptions();if(!o)return t;let l=(r=B[o])===null||r===void 0?void 0:r[i];t+=l[n]||l.default}return t}formatToParts(e){return this.numberFormatter.formatToParts(e)}formatRange(e,t){if(typeof this.numberFormatter.formatRange=="function")return this.numberFormatter.formatRange(e,t);if(t<e)throw new RangeError("End date must be >= start date");return`${this.format(e)} – ${this.format(t)}`}formatRangeToParts(e,t){if(typeof this.numberFormatter.formatRangeToParts=="function")return this.numberFormatter.formatRangeToParts(e,t);if(t<e)throw new RangeError("End date must be >= start date");let r=this.numberFormatter.formatToParts(e),o=this.numberFormatter.formatToParts(t);return[...r.map(i=>({...i,source:"startRange"})),{type:"literal",value:" – ",source:"shared"},...o.map(i=>({...i,source:"endRange"}))]}resolvedOptions(){let e=this.numberFormatter.resolvedOptions();return!C&&this.options.signDisplay!=null&&(e={...e,signDisplay:this.options.signDisplay}),!x&&this.options.style==="unit"&&(e={...e,style:"unit",unit:this.options.unit,unitDisplay:this.options.unitDisplay}),e}constructor(e,t={}){this.numberFormatter=te(e,t),this.options=t}}function te(s,e={}){let{numberingSystem:t}=e;if(t&&s.includes("-nu-")&&(s.includes("-u-")||(s+="-u-"),s+=`-nu-${t}`),e.style==="unit"&&!x){var r;let{unit:n,unitDisplay:l="short"}=e;if(!n)throw new Error('unit option must be provided with style: "unit"');if(!(!((r=B[n])===null||r===void 0)&&r[l]))throw new Error(`Unsupported unit ${n} with unitDisplay = ${l}`);e={...e,style:"decimal"}}let o=s+(e?Object.entries(e).sort((n,l)=>n[0]<l[0]?-1:1).join():"");if(S.has(o))return S.get(o);let i=new Intl.NumberFormat(s,e);return S.set(o,i),i}function re(s,e,t){if(e==="auto")return s.format(t);if(e==="never")return s.format(Math.abs(t));{let r=!1;if(e==="always"?r=t>0||Object.is(t,0):e==="exceptZero"&&(Object.is(t,-0)||Object.is(t,0)?t=Math.abs(t):r=t>0),r){let o=s.format(-t),i=s.format(t),n=o.replace(i,"").replace(/\u200e|\u061C/,"");return[...n].length!==1&&console.warn("@react-aria/i18n polyfill for NumberFormat signDisplay: Unsupported case"),o.replace(i,"!!!").replace(n,"+").replace("!!!",i)}else return s.format(t)}}const oe=new RegExp("^.*\\(.*\\).*$"),ie=["latn","arab","hanidec","deva","beng"];class E{parse(e){return P(this.locale,this.options,e).parse(e)}isValidPartialNumber(e,t,r){return P(this.locale,this.options,e).isValidPartialNumber(e,t,r)}getNumberingSystem(e){return P(this.locale,this.options,e).options.numberingSystem}constructor(e,t={}){this.locale=e,this.options=t}}const D=new Map;function P(s,e,t){let r=L(s,e);if(!s.includes("-nu-")&&!r.isValidPartialNumber(t)){for(let o of ie)if(o!==r.options.numberingSystem){let i=L(s+(s.includes("-u-")?"-nu-":"-u-nu-")+o,e);if(i.isValidPartialNumber(t))return i}}return r}function L(s,e){let t=s+(e?Object.entries(e).sort((o,i)=>o[0]<i[0]?-1:1).join():""),r=D.get(t);return r||(r=new se(s,e),D.set(t,r)),r}class se{parse(e){let t=this.sanitize(e);if(this.symbols.group&&(t=y(t,this.symbols.group,"")),this.symbols.decimal&&(t=t.replace(this.symbols.decimal,".")),this.symbols.minusSign&&(t=t.replace(this.symbols.minusSign,"-")),t=t.replace(this.symbols.numeral,this.symbols.index),this.options.style==="percent"){let n=t.indexOf("-");t=t.replace("-","");let l=t.indexOf(".");l===-1&&(l=t.length),t=t.replace(".",""),l-2===0?t=`0.${t}`:l-2===-1?t=`0.0${t}`:l-2===-2?t="0.00":t=`${t.slice(0,l-2)}.${t.slice(l-2)}`,n>-1&&(t=`-${t}`)}let r=t?+t:NaN;if(isNaN(r))return NaN;if(this.options.style==="percent"){var o,i;let n={...this.options,style:"decimal",minimumFractionDigits:Math.min(((o=this.options.minimumFractionDigits)!==null&&o!==void 0?o:0)+2,20),maximumFractionDigits:Math.min(((i=this.options.maximumFractionDigits)!==null&&i!==void 0?i:0)+2,20)};return new E(this.locale,n).parse(new k(this.locale,n).format(r))}return this.options.currencySign==="accounting"&&oe.test(e)&&(r=-1*r),r}sanitize(e){return e=e.replace(this.symbols.literals,""),this.symbols.minusSign&&(e=e.replace("-",this.symbols.minusSign)),this.options.numberingSystem==="arab"&&(this.symbols.decimal&&(e=e.replace(",",this.symbols.decimal),e=e.replace("،",this.symbols.decimal)),this.symbols.group&&(e=y(e,".",this.symbols.group))),this.options.locale==="fr-FR"&&(e=y(e,"."," ")),e}isValidPartialNumber(e,t=-1/0,r=1/0){return e=this.sanitize(e),this.symbols.minusSign&&e.startsWith(this.symbols.minusSign)&&t<0?e=e.slice(this.symbols.minusSign.length):this.symbols.plusSign&&e.startsWith(this.symbols.plusSign)&&r>0&&(e=e.slice(this.symbols.plusSign.length)),this.symbols.group&&e.startsWith(this.symbols.group)||this.symbols.decimal&&e.indexOf(this.symbols.decimal)>-1&&this.options.maximumFractionDigits===0?!1:(this.symbols.group&&(e=y(e,this.symbols.group,"")),e=e.replace(this.symbols.numeral,""),this.symbols.decimal&&(e=e.replace(this.symbols.decimal,"")),e.length===0)}constructor(e,t={}){this.locale=e,this.formatter=new Intl.NumberFormat(e,t),this.options=this.formatter.resolvedOptions(),this.symbols=le(e,this.formatter,this.options,t);var r,o;this.options.style==="percent"&&(((r=this.options.minimumFractionDigits)!==null&&r!==void 0?r:0)>18||((o=this.options.maximumFractionDigits)!==null&&o!==void 0?o:0)>18)&&console.warn("NumberParser cannot handle percentages with greater than 18 decimal places, please reduce the number in your options.")}}const V=new Set(["decimal","fraction","integer","minusSign","plusSign","group"]),ne=[0,4,2,1,11,20,3,7,100,21,.1,1.1];function le(s,e,t,r){var o,i,n,l;let u=new Intl.NumberFormat(s,{...t,minimumSignificantDigits:1,maximumSignificantDigits:21,roundingIncrement:1,roundingPriority:"auto",roundingMode:"halfExpand"}),c=u.formatToParts(-10000.111),g=u.formatToParts(10000.111),T=ne.map(a=>u.formatToParts(a));var F;let j=(F=(o=c.find(a=>a.type==="minusSign"))===null||o===void 0?void 0:o.value)!==null&&F!==void 0?F:"-",$=(i=g.find(a=>a.type==="plusSign"))===null||i===void 0?void 0:i.value;!$&&((r==null?void 0:r.signDisplay)==="exceptZero"||(r==null?void 0:r.signDisplay)==="always")&&($="+");let U=(n=new Intl.NumberFormat(s,{...t,minimumFractionDigits:2,maximumFractionDigits:2}).formatToParts(.001).find(a=>a.type==="decimal"))===null||n===void 0?void 0:n.value,H=(l=c.find(a=>a.type==="group"))===null||l===void 0?void 0:l.value,G=c.filter(a=>!V.has(a.type)).map(a=>I(a.value)),K=T.flatMap(a=>a.filter(p=>!V.has(p.type)).map(p=>I(p.value))),_=[...new Set([...G,...K])].sort((a,p)=>p.length-a.length),W=_.length===0?new RegExp("[\\p{White_Space}]","gu"):new RegExp(`${_.join("|")}|[\\p{White_Space}]`,"gu"),q=[...new Intl.NumberFormat(t.locale,{useGrouping:!1}).format(9876543210)].reverse(),Y=new Map(q.map((a,p)=>[a,p])),X=new RegExp(`[${q.join("")}]`,"g");return{minusSign:j,plusSign:$,decimal:U,group:H,literals:W,numeral:X,index:a=>String(Y.get(a))}}function y(s,e,t){return s.replaceAll?s.replaceAll(e,t):s.split(e).join(t)}function I(s){return s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}const de="@media (forced-colors: active){:host(:is(:active,[active])):not(:disabled),:host(:focus-visible):not(:disabled){--highcontrast-infield-button-border-color: Highlight}}@media (forced-colors: active) and (hover: hover){:host(:hover):not(:disabled){--highcontrast-infield-button-border-color: Highlight}}:host{background-color:initial;cursor:pointer;block-size:var(--luzmo-infield-button-height, var(--infield-button-height));inline-size:var(--luzmo-infield-button-width, var(--infield-button-width));padding:var(--luzmo-infield-button-edge-to-fill, var(--infield-button-edge-to-fill));color:var(--infield-button-content-color, inherit);border-style:none;justify-content:center;align-items:center;display:flex}.fill{block-size:100%;inline-size:100%;background-color:var(--luzmo-infield-button-background-color, var(--infield-button-background-color));border-width:var(--luzmo-infield-button-border-width, var(--infield-button-border-width));border-style:solid;border-color:var(--highcontrast-infield-button-border-color, var(--luzmo-infield-button-border-color, var(--infield-button-border-color)));padding:var(--luzmo-infield-button-fill-padding, var(--infield-button-fill-padding));border-start-start-radius:var(--luzmo-infield-button-border-radius, var(--infield-button-border-radius));border-start-end-radius:var(--luzmo-infield-button-border-radius, var(--infield-button-border-radius));border-end-end-radius:var(--luzmo-infield-button-border-radius, var(--infield-button-border-radius));border-end-start-radius:var(--luzmo-infield-button-border-radius, var(--infield-button-border-radius))}::slotted(*){color:var(--luzmo-infield-button-icon-color, var(--infield-button-icon-color))}:host([inline=end]) .fill{border-start-start-radius:var(--luzmo-infield-button-border-radius-reset, var(--infield-button-border-radius-reset));border-end-start-radius:var(--luzmo-infield-button-border-radius-reset, var(--infield-button-border-radius-reset))}:host([inline=start]) .fill{border-start-end-radius:var(--luzmo-infield-button-border-radius-reset, var(--infield-button-border-radius-reset));border-end-end-radius:var(--luzmo-infield-button-border-radius-reset, var(--infield-button-border-radius-reset))}:host([block=end]),:host([block=start]){--infield-button-width: var(--luzmo-infield-button-width-stacked, 28px)}:host([block=end][size=s]),:host([block=start][size=s]){--infield-button-width: var(--luzmo-infield-button-width-stacked, 20px)}:host([block=end][size=l]),:host([block=start][size=l]){--infield-button-width: var(--luzmo-infield-button-width-stacked, 36px)}:host([block=end][size=xl]),:host([block=start][size=xl]){--infield-button-width: var(--luzmo-infield-button-width-stacked, 44px)}:host([quiet]){--infield-button-background-color: var( --luzmo-infield-button-background-color-quiet, transparent );--infield-button-background-color-hover: var( --luzmo-infield-button-background-color-hover-quiet, transparent );--infield-button-background-color-down: var( --luzmo-infield-button-background-color-down-quiet, transparent );--infield-button-background-color-key-focus: var( --luzmo-infield-button-background-color-key-focus-quiet, transparent );--infield-border-color: var(--luzmo-infield-border-color-quiet, transparent);--infield-button-border-width: var( --luzmo-infield-button-border-width-quiet, 0 )}:host([quiet][disabled]){--infield-button-background-color: var( --luzmo-infield-button-background-color-quiet-disabled, transparent );--infield-button-border-color: var( --luzmo-infield-button-border-color-quiet-disabled, transparent )}:host([disabled]){--infield-button-background-color: var( --luzmo-infield-button-background-color-disabled, var(--luzmo-background-color-disabled) );--infield-button-background-color-hover: var( --luzmo-infield-button-background-color-hover-disabled, var(--luzmo-background-color-disabled) );--infield-button-background-color-down: var( --luzmo-infield-button-background-color-down-disabled, var(--luzmo-background-color-disabled) );--infield-button-border-color: var( --luzmo-infield-button-border-color-disabled, var(--luzmo-background-color-disabled) );--infield-button-content-color: var( --luzmo-infield-button-content-color-disabled, var(--luzmo-color-disabled) );--infield-button-icon-color: var( --luzmo-infield-button-icon-color-disabled, var(--luzmo-color-disabled) );--infield-button-icon-color-hover: var( --luzmo-infield-button-icon-color-hover-disabled, var(--luzmo-color-disabled) );--infield-button-icon-color-down: var( --luzmo-infield-button-icon-color-down-disabled, var(--luzmo-color-disabled) );--infield-button-icon-color-key-focus: var( --luzmo-infield-button-icon-color-key-focus-disabled, var(--luzmo-color-disabled) );cursor:auto}@media (hover: hover){:host(:hover) .fill{background-color:var(--luzmo-infield-button-background-color-hover, var(--infield-button-background-color-hover))}:host(:hover) ::slotted(*){color:var(--luzmo-infield-button-icon-color-hover, var(--infield-button-icon-color-hover))}}:host(:is(:active,[active])) .fill{background-color:var(--luzmo-infield-button-background-color-down, var(--infield-button-background-color-down))}:host(:is(:active,[active])) ::slotted(*){color:var(--luzmo-infield-button-icon-color-down, var(--infield-button-icon-color-down))}:host(:focus-visible){outline:none}:host(:focus-visible) .fill{background-color:var(--luzmo-infield-button-background-color-key-focus, var(--infield-button-background-color-key-focus))}:host(:focus-visible) ::slotted(*){color:var(--luzmo-infield-button-icon-color-key-focus, var(--infield-button-icon-color-key-focus))}.fill{align-items:center;justify-content:var(--luzmo-infield-button-fill-justify-content, var(--infield-button-fill-justify-content));display:flex}:host([block=end]),:host([block=start]){block-size:calc(var(--luzmo-infield-button-height, var(--infield-button-height)) / 2)}:host([block=end]) .fill,:host([block=start]) .fill{box-sizing:border-box;padding-inline-start:calc(var(--luzmo-infield-button-stacked-fill-padding-inline, var(--infield-button-stacked-fill-padding-inline)) - var(--luzmo-infield-button-edge-to-fill, var(--infield-button-edge-to-fill)) - var(--luzmo-infield-button-border-width, var(--infield-button-border-width)));padding-inline-end:calc(var(--luzmo-infield-button-stacked-fill-padding-inline, var(--infield-button-stacked-fill-padding-inline)) - var(--luzmo-infield-button-edge-to-fill, var(--infield-button-edge-to-fill)) - var(--luzmo-infield-button-border-width, var(--infield-button-border-width)))}:host([block=start]){padding-block-end:var(--luzmo-infield-button-inner-edge-to-fill, var(--infield-button-inner-edge-to-fill))}:host([block=start]) .fill{border-block-end:none;border-start-start-radius:var(--luzmo-infield-button-stacked-top-border-radius-start-start, var(--infield-button-stacked-top-border-radius-start-start));border-end-end-radius:var(--luzmo-infield-button-stacked-border-radius-reset, var(--infield-button-stacked-border-radius-reset));border-end-start-radius:var(--luzmo-infield-button-stacked-border-radius-reset, var(--infield-button-stacked-border-radius-reset));padding-block-start:calc(var(--luzmo-infield-button-stacked-fill-padding-outer, var(--infield-button-stacked-fill-padding-outer)) - var(--luzmo-infield-button-edge-to-fill, var(--infield-button-edge-to-fill)) - var(--luzmo-infield-button-border-width, var(--infield-button-border-width)));padding-block-end:calc(var(--luzmo-infield-button-stacked-fill-padding-inner, var(--infield-button-stacked-fill-padding-inner)) - var(--luzmo-infield-button-inner-edge-to-fill, var(--infield-button-inner-edge-to-fill)))}:host([block=end]){padding-block-start:var(--luzmo-infield-button-inner-edge-to-fill, var(--infield-button-inner-edge-to-fill))}:host([block=end]) .fill{border-block-end-width:var(--luzmo-infield-button-stacked-bottom-border-block-end-width, var(--luzmo-infield-button-border-width, var(--infield-button-border-width)));border-start-start-radius:var(--luzmo-infield-button-stacked-border-radius-reset, var(--infield-button-stacked-border-radius-reset));border-start-end-radius:var(--luzmo-infield-button-stacked-border-radius-reset, var(--infield-button-stacked-border-radius-reset));border-end-end-radius:var(--luzmo-infield-button-stacked-bottom-border-radius-end-end, var(--luzmo-infield-button-border-radius, var(--infield-button-border-radius)));border-end-start-radius:var(--luzmo-infield-button-stacked-bottom-border-radius-end-start, var(--infield-button-stacked-bottom-border-radius-end-start));padding-block-start:calc(var(--luzmo-infield-button-stacked-fill-padding-inner, var(--infield-button-stacked-fill-padding-inner)) - var(--luzmo-infield-button-edge-to-fill, var(--infield-button-edge-to-fill)) - var(--luzmo-infield-button-border-width, var(--infield-button-border-width)));padding-block-end:calc(var(--luzmo-infield-button-stacked-fill-padding-outer, var(--infield-button-stacked-fill-padding-outer)) - var(--luzmo-infield-button-inner-edge-to-fill, var(--infield-button-inner-edge-to-fill)) - var(--luzmo-infield-button-border-width, var(--infield-button-border-width)))}::slotted(*){display:initial;flex-shrink:0;margin:0!important}:host{--infield-button-border-width: var(--luzmo-border-width);--infield-button-border-color: inherit;--infield-button-border-radius: var(--luzmo-border-radius-s);--infield-button-border-radius-reset: 0;--infield-button-stacked-top-border-radius-start-start: 0;--infield-button-stacked-bottom-border-radius-end-start: 0;--infield-button-background-color: var(--luzmo-background-color);--infield-button-background-color-hover: var(--luzmo-background-color-hover);--infield-button-background-color-down: var(--luzmo-background-color-down);--infield-button-background-color-key-focus: var( --luzmo-background-color-focus );--infield-button-height: var(--luzmo-component-height);--infield-button-width: var(--luzmo-component-height);--infield-button-stacked-border-radius-reset: 0px;--infield-button-edge-to-fill: 0px;--infield-button-inner-edge-to-fill: 0px;--infield-button-fill-padding: 0px;--infield-button-stacked-fill-padding-inline: 9px;--infield-button-stacked-fill-padding-outer: 3px;--infield-button-stacked-fill-padding-inner: 3px;--infield-button-animation-duration: var(--luzmo-animation-duration);--infield-button-icon-color: var(--luzmo-font-color);--infield-button-icon-color-hover: var(--luzmo-font-color-hard);--infield-button-icon-color-down: var(--luzmo-font-color-hard);--infield-button-icon-color-key-focus: var(--luzmo-font-color-hard);--infield-button-fill-justify-content: center}:host([disabled]){--infield-button-background-color: var(--luzmo-background-color-disabled);--infield-button-background-color-hover: var( --luzmo-background-color-disabled );--infield-button-background-color-down: var( --luzmo-background-color-disabled );--infield-button-border-color: var(--luzmo-border-color-disabled);--infield-button-content-color: var(--luzmo-color-disabled);--infield-button-icon-color: var(--luzmo-color-disabled);--infield-button-icon-color-hover: var(--luzmo-color-disabled);--infield-button-icon-color-down: var(--luzmo-color-disabled);--infield-button-icon-color-key-focus: var(--luzmo-color-disabled)}:host([size=s]){--infield-button-height: var(--luzmo-component-height-s);--infield-button-width: var(--luzmo-component-height-s);--infield-button-stacked-fill-padding-inline: 7px;--infield-button-stacked-fill-padding-outer: 3px;--infield-button-stacked-fill-padding-inner: 3px}:host([size=l]){--infield-button-height: var(--luzmo-component-height-l);--infield-button-width: var(--luzmo-component-height-l);--infield-button-stacked-fill-padding-inline: 13px;--infield-button-stacked-fill-padding-outer: 4px;--infield-button-stacked-fill-padding-inner: 4px}:host([size=xl]){--infield-button-height: var(--luzmo-component-height-xl);--infield-button-width: var(--luzmo-component-height-xl);--infield-button-stacked-fill-padding-inline: 16px;--infield-button-stacked-fill-padding-outer: 5px;--infield-button-stacked-fill-padding-inner: 5px}:host([block=start]){--infield-button-width: 20px}:host([block=end]){--infield-button-width: 20px}:host([block=start][size=s]){--infield-button-width: 16px}:host([block=end][size=s]){--infield-button-width: 16px}:host([block=start][size=l]){--infield-button-width: 28px}:host([block=end][size=l]){--infield-button-width: 28px}:host([block=start][size=xl]){--infield-button-width: 36px}:host([block=end][size=xl]){--infield-button-width: 36px}:host([quiet]){--infield-button-background-color: transparent;--infield-button-background-color-hover: transparent;--infield-button-background-color-down: transparent;--infield-button-background-color-key-focus: transparent;--infield-border-color: transparent;--infield-button-border-width: 0}:host([quiet][disabled]){--infield-button-background-color: transparent;--infield-button-border-color: transparent}:host{box-sizing:border-box;-webkit-user-select:none;user-select:none}::slotted(*){--parent-element-icon-vertical-align: 1px;--icon-size: inherit}";var ae=Object.defineProperty,N=(s,e,t,r)=>{for(var o=void 0,i=s.length-1,n;i>=0;i--)(n=s[i])&&(o=n(e,t,o)||o);return o&&ae(e,t,o),o};class v extends d.SizedMixin(J.ButtonBase,{noDefaultSize:!0,validSizes:["s","m","l","xl"]}){constructor(){super(...arguments),this.quiet=!1}static get styles(){return[...super.styles,d.r(de)]}get buttonContent(){return[d.x`
|
21
|
-
<div class="fill">
|
22
|
-
<slot></slot>
|
23
|
-
</div>
|
24
|
-
`]}}N([d.n()],v.prototype,"block");N([d.n()],v.prototype,"inline");N([d.n({type:Boolean,reflect:!0})],v.prototype,"quiet");customElements.get("luzmo-infield-button")||customElements.define("luzmo-infield-button",v);const ue='#text-field{--stepper-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--stepper-min-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color, var( --luzmo-stepper-buttons-border-color, var(--stepper-buttons-border-color) ) );--luzmo-infield-button-border-width: var( --luzmo-stepper-button-border-width, var(--stepper-button-border-width) );--luzmo-infield-button-border-radius-reset: var( --stepper-button-border-radius-reset );--luzmo-text-field-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );inline-size:var(--luzmo-stepper-width, var(--stepper-width));block-size:var(--luzmo-stepper-height, var(--stepper-height));border-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));flex-flow:row;display:inline-flex;position:relative}#text-field:after{content:"";inline-size:100%;block-size:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width));position:absolute;inset-block-end:calc((var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap)) + var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width))) * -1);inset-inline-start:0}:host([focused]) #text-field,#text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var( --luzmo-stepper-buttons-border-color-focus, var(--stepper-buttons-border-color-focus) ) )}:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .input{outline:none}:host([focused]:not([disabled])) #text-field .buttons,:host([focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus .buttons,:host(:not([disabled])) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)))}:host([keyboard-focused]) #text-field,#text-field:focus-visible{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-buttons-border-color-keyboard-focus, var(--stepper-buttons-border-color-keyboard-focus) ) )}:host([keyboard-focused]:not([disabled])) #text-field,:host(:not([disabled])) #text-field:focus-visible{outline:var(--luzmo-stepper-focus-indicator-width, var(--stepper-focus-indicator-width)) solid;outline-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)));outline-offset:var(--luzmo-stepper-focus-indicator-gap, var(--stepper-focus-indicator-gap))}:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .input{outline:none}:host([keyboard-focused]:not([disabled])) #text-field .buttons,:host([keyboard-focused]:not([disabled])) #text-field .input,:host(:not([disabled])) #text-field:focus-visible .buttons,:host(:not([disabled])) #text-field:focus-visible .input{border-color:var(--highcontrast-stepper-border-color-keyboard-focus, var(--luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus)))}:host([invalid]:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-stepper-border-color-hover: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) );--luzmo-stepper-border-color-focus: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) );--luzmo-stepper-border-color-focus-hover: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) );--luzmo-stepper-border-color-keyboard-focus: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-invalid, var(--stepper-border-color-invalid) );--luzmo-text-field-icon-spacing-inline-start-invalid: 0}:host([invalid][focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-invalid, var(--stepper-border-color-focus-invalid) )}:host([invalid][keyboard-focused]:not([disabled])) #text-field,:host([invalid]:not([disabled])) #text-field:focus-visible{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-keyboard-focus-invalid, var(--stepper-border-color-keyboard-focus-invalid) )}:host([disabled]) #text-field{--luzmo-stepper-border-color: var(--stepper-button-border-color-disabled);--luzmo-stepper-border-color-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-focus-hover: var( --stepper-button-border-color-disabled );--luzmo-stepper-border-color-keyboard-focus: var( --stepper-button-border-color-disabled );--luzmo-stepper-buttons-background-color: var( --stepper-buttons-background-color-disabled );--luzmo-infield-button-border-width: var( --stepper-button-border-width-disabled );--luzmo-infield-button-border-color: var( --stepper-button-border-color-disabled );--luzmo-text-field-border-color-disabled: var( --stepper-button-border-color-disabled )}#text-field .input{border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-inline-end-width:0;border-start-end-radius:0;border-end-end-radius:0}#text-field.hide-stepper .input{border-inline-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius))}#text-field .buttons{box-sizing:border-box;block-size:var(--luzmo-stepper-height, var(--stepper-height));inline-size:var(--luzmo-stepper-button-width, var(--stepper-button-width));border-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-style:var(--luzmo-stepper-buttons-border-style, var(--stepper-buttons-border-style));border-width:var(--highcontrast-stepper-buttons-border-width, var(--luzmo-stepper-buttons-border-width, var(--stepper-buttons-border-width)));background-color:var(--highcontrast-stepper-buttons-background-color, var(--luzmo-stepper-buttons-background-color, var(--stepper-buttons-background-color)));transition:border-color var(--luzmo-stepper-animation-duration, var(--stepper-animation-duration)) ease-in-out;border-inline-start-width:0;border-start-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));border-end-end-radius:var(--luzmo-stepper-border-radius, var(--stepper-border-radius));flex-direction:column;justify-content:center;display:flex}:host([quiet]) #text-field{border-start-start-radius:0;border-start-end-radius:0;border-end-end-radius:0;border-end-start-radius:0}:host([quiet]) #text-field .input{--luzmo-text-field-focus-indicator-color: transparent}:host([quiet]) #text-field.hide-stepper .input{border-inline-end-width:0;border-end-end-radius:0}:host([quiet]) #text-field .buttons{--luzmo-infield-button-border-color: transparent;border-width:0;border-block-end-width:var(--luzmo-stepper-border-width, var(--stepper-border-width));border-block-end-color:var(--highcontrast-stepper-border-color, var(--luzmo-stepper-border-color, var(--stepper-border-color)));border-block-end-style:solid;border-end-end-radius:0}:host([quiet]) #text-field .button{--luzmo-infield-button-width-stacked: var( --luzmo-stepper-button-width-quiet, var(--stepper-button-width) );--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-quiet, var(--stepper-button-border-color-quiet) );--luzmo-infield-button-stacked-bottom-border-block-end-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) );--luzmo-infield-button-stacked-bottom-border-radius-end-end: 0;--luzmo-infield-button-stacked-bottom-border-radius-end-start: 0;--luzmo-infield-button-fill-justify-content: flex-end;padding:0}:host([quiet]) #text-field .buttons,:host([quiet]) #text-field .input{background-color:initial}:host([quiet][focused]) #text-field,:host([quiet]) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus, var(--luzmo-stepper-border-color-focus, var(--stepper-border-color-focus)) )}:host([quiet][keyboard-focused]:not([disabled])) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-keyboard-focus, var( --luzmo-stepper-border-color-keyboard-focus, var(--stepper-border-color-keyboard-focus) ) );outline:none}:host([quiet][keyboard-focused]:not([disabled])) #text-field:after{background-color:var(--highcontrast-stepper-focus-indicator-color, var(--luzmo-stepper-focus-indicator-color, var(--stepper-focus-indicator-color)))}@media (hover: hover){:host(:hover:not([disabled])) #text-field{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var( --luzmo-stepper-buttons-border-color-hover, var(--stepper-buttons-border-color-hover) ) )}:host([focused]:hover) #text-field,:host(:hover) #text-field:focus{--luzmo-stepper-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) );--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-buttons-border-color-focus-hover, var(--stepper-buttons-border-color-focus-hover) ) )}:host([focused]:hover) #text-field .buttons,:host([focused]:hover) #text-field .input,:host(:hover) #text-field:focus .buttons,:host(:hover) #text-field:focus .input{border-color:var(--highcontrast-stepper-border-color-focus-hover, var(--luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover)))}:host([invalid]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-hover-invalid, var(--stepper-border-color-hover-invalid) )}:host([invalid][focused]:not([disabled]):hover) #text-field,:host([invalid]:not([disabled]):hover) #text-field:focus{--luzmo-infield-button-border-color: var( --luzmo-stepper-border-color-focus-hover-invalid, var(--stepper-border-color-focus-hover-invalid) )}:host([quiet]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}:host([quiet]:not([disabled]):hover) #text-field .buttons{background-color:initial}:host([quiet][focused]:hover) #text-field,:host([quiet]:hover) #text-field:focus{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-focus-hover, var( --luzmo-stepper-border-color-focus-hover, var(--stepper-border-color-focus-hover) ) )}:host([quiet][keyboard-focused]:not([disabled]):hover) #text-field{--luzmo-infield-button-border-color: var( --highcontrast-stepper-border-color-hover, var(--luzmo-stepper-border-color-hover, var(--stepper-border-color-hover)) )}}@media (forced-colors: active){:host{--highcontrast-stepper-border-color: CanvasText;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: CanvasText;--highcontrast-stepper-button-background-color-default: Canvas;--highcontrast-stepper-button-background-color-hover: Canvas;--highcontrast-stepper-button-background-color-focus: Canvas;--highcontrast-stepper-button-background-color-keyboard-focus: Canvas;--highcontrast-stepper-focus-indicator-color: Highlight}:host([invalid]) #text-field{--highcontrast-stepper-border-color: Highlight;--highcontrast-stepper-border-color-hover: Highlight;--highcontrast-stepper-border-color-focus: Highlight;--highcontrast-stepper-border-color-focus-hover: Highlight;--highcontrast-stepper-border-color-keyboard-focus: Highlight;--highcontrast-infield-button-border-color: Highlight}:host([disabled]) #text-field{--highcontrast-stepper-border-color: GrayText;--highcontrast-infield-button-border-color: GrayText;--highcontrast-stepper-buttons-border-width: var( --luzmo-stepper-border-width, var(--stepper-border-width) )}}:host{--text-field-minimum-width-multiplier: 1.75;--stepper-border-width: var(--luzmo-border-width);--stepper-border-color: var(--luzmo-border-color);--stepper-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-border-color-focus-hover: var(--luzmo-border-color-full-focus);--stepper-border-color-keyboard-focus: var(--luzmo-border-color-full-focus);--stepper-border-radius: var(--luzmo-border-radius-s);--stepper-min-width-multiplier: 1.5;--stepper-animation-duration: var(--luzmo-animation-duration);--stepper-buttons-background-color: var(--luzmo-background-color);--stepper-buttons-border-style: none;--stepper-buttons-border-width: 0;--stepper-buttons-border-color: var(--luzmo-border-color);--stepper-buttons-border-color-hover: var(--luzmo-border-color-full-hover);--stepper-buttons-border-color-focus: var(--luzmo-border-color-full-focus);--stepper-buttons-border-color-keyboard-focus: var( --luzmo-border-color-focus );--stepper-button-padding: 0px;--stepper-button-border-radius-reset: 0;--stepper-button-border-width: var(--luzmo-border-width);--stepper-button-background-color-focus: var(--luzmo-background-color-focus);--stepper-button-background-color-keyboard-focus: var( --luzmo-background-color-focus );--stepper-border-color-invalid: var(--luzmo-color-negative);--stepper-border-color-hover-invalid: var(--luzmo-color-negative-hover);--stepper-border-color-focus-invalid: var(--luzmo-color-negative-focus);--stepper-border-color-focus-hover-invalid: var(--luzmo-color-negative-focus);--stepper-border-color-keyboard-focus-invalid: var( --luzmo-color-negative-focus );--stepper-focus-indicator-width: var(--luzmo-indicator-width);--stepper-focus-indicator-gap: calc(-1 * var(--luzmo-border-width));--stepper-focus-indicator-color: var(--luzmo-indicator-color);--stepper-button-border-color-quiet: transparent;--stepper-button-border-color-disabled: var(--luzmo-border-color-disabled);--stepper-button-border-width-disabled: var(--luzmo-border-width);--stepper-buttons-background-color-disabled: var( --luzmo-background-color-disabled );--stepper-button-width: 28px;--stepper-height: var(--luzmo-component-height)}:host([size=s]) #text-field{--stepper-button-width: 16px;--stepper-height: var(--luzmo-component-height-s)}:host([size=m]) #text-field{--stepper-button-width: 20px;--stepper-height: var(--luzmo-component-height)}:host([size=l]) #text-field{--stepper-button-width: 28px;--stepper-height: var(--luzmo-component-height-l)}:host([size=xl]) #text-field{--stepper-button-width: 36px;--stepper-height: var(--luzmo-component-height-xl)}:host{inline-size:var(--luzmo-stepper-width, var(--stepper-width));--swc-number-field-width: calc( var(--luzmo-stepper-height, var(--stepper-height)) * var( --luzmo-stepper-min-width-multiplier, var(--text-field-minimum-width-multiplier) ) + var(--luzmo-stepper-button-width, var(--stepper-button-width)) + var(--luzmo-stepper-border-width, var(--stepper-border-width)) * 2 );--luzmo-infield-button-border-width: var(--unset-value-resets-inheritance);--stepper-width: var(--swc-number-field-width)}:host([size=s]){--stepper-width: calc(var(--swc-number-field-width) / 5 * 4)}:host([size=l]){--stepper-width: calc(var(--swc-number-field-width) * 1.25)}:host([size=xl]){--stepper-width: calc(var(--swc-number-field-width) * 1.25 * 1.25)}#text-field{inline-size:100%}.input{font-variant-numeric:tabular-nums}:host([readonly]) .buttons{pointer-events:none;visibility:hidden}:host([readonly]:not([disabled],[invalid],[focused],[keyboard-focused])) #text-field:hover .input{border-color:transparent}:host([hide-stepper]:not([quiet])) #text-field input{border:var(--luzmo-text-field-border-width, var(--text-field-border-width)) solid var(--luzmo-text-field-border-color, var(--text-field-border-color));border-radius:var(--text-field-corner-radius)}:host([quiet]) #text-field .button{--luzmo-infield-button-border-color: var( --luzmo-infield-border-color-quiet, transparent );--luzmo-infield-button-edge-to-fill: 0;--luzmo-infield-button-border-width: var( --luzmo-infield-button-border-width-quiet, 0 )}';var ce=Object.defineProperty,be=Object.getOwnPropertyDescriptor,h=(s,e,t,r)=>{for(var o=r>1?void 0:r?be(e,t):e,i=s.length-1,n;i>=0;i--)(n=s[i])&&(o=(r?n(e,t,o):n(o))||o);return r&&o&&ce(e,t,o),o};const he=5,pe=100,w="-",R={"1":"1","2":"2","3":"3","4":"4","5":"5","6":"6","7":"7","8":"8","9":"9","0":"0","、":",",",":",","。":".",".":".","%":"%","+":"+",ー:"-",一:"1",二:"2",三:"3",四:"4",五:"5",六:"6",七:"7",八:"8",九:"9",零:"0"};class b extends Q.LuzmoTextFieldBase{constructor(){super(...arguments),this.focused=!1,this._forcedUnit="",this.formatOptions={},this.hideStepper=!1,this.indeterminate=!1,this.keyboardFocused=!1,this.managedInput=!1,this.stepModifier=10,this._value=Number.NaN,this._trackingValue="",this.decimalsChars=new Set([".",","]),this.valueBeforeFocus="",this.isIntentDecimal=!1,this.changeCount=0,this.languageResolver=new M(this),this.wasIndeterminate=!1,this.hasRecentlyReceivedPointerDown=!1,this.applyFocusElementLabel=e=>{this.appliedLabel=e},this.isComposing=!1}static get styles(){return[...super.styles,d.r(ue)]}set value(e){const t=this.validateInput(e);if(t===this.value)return;this.lastCommitedValue=t;const r=this._value;this._value=t,this.requestUpdate("value",r)}get value(){return this._value}get inputValue(){return this.indeterminate?this.formattedValue:this.inputElement.value}setValue(e=this.value){const t=this.lastCommitedValue;this.value=e,!(t===void 0||t===this.value)&&(this.lastCommitedValue=this.value,this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})))}get valueAsString(){return this._value.toString()}set valueAsString(e){this.value=this.numberParser.parse(e)}get formattedValue(){return Number.isNaN(this.value)?"":this.numberFormatter.format(this.value)+(this.focused?"":this._forcedUnit)}convertValueToNumber(e){let t=[...e].map(i=>R[i]||i).join("");const r=[...this.valueBeforeFocus].filter(i=>this.decimalsChars.has(i)),o=new Set(r);if(m.isIOS()&&this.inputElement.inputMode==="decimal"&&t!==this.valueBeforeFocus){const n=this.numberFormatter.formatToParts(1000.1).find(c=>c.type==="decimal").value;for(const c of o)!(c===n)&&!this.isIntentDecimal&&(t=t.replaceAll(new RegExp(c,"g"),""));let l=!1;const u=[...t];for(let c=u.length-1;c>=0;c--){const g=u[c];this.decimalsChars.has(g)&&(l?u[c]="":(u[c]=n,l=!0))}t=u.join("")}return this.numberParser.parse(t)}get _step(){var e;return this.step!==void 0?this.step:((e=this.formatOptions)==null?void 0:e.style)==="percent"?.01:1}handlePointerdown(e){if(e.button!==0){e.preventDefault();return}this.managedInput=!0,this.buttons.setPointerCapture(e.pointerId);const t=this.buttons.children[0].getBoundingClientRect(),r=this.buttons.children[1].getBoundingClientRect();this.findChange=o=>{o.clientX>=t.x&&o.clientY>=t.y&&o.clientX<=t.x+t.width&&o.clientY<=t.y+t.height?this.change=i=>this.increment(i.shiftKey?this.stepModifier:1):o.clientX>=r.x&&o.clientY>=r.y&&o.clientX<=r.x+r.width&&o.clientY<=r.y+r.height&&(this.change=i=>this.decrement(i.shiftKey?this.stepModifier:1))},this.findChange(e),this.startChange(e)}startChange(e){this.changeCount=0,this.doChange(e),this.safty=setTimeout(()=>{this.doNextChange(e)},400)}doChange(e){this.change(e)}handlePointermove(e){this.findChange(e)}handlePointerup(e){this.buttons.releasePointerCapture(e.pointerId),cancelAnimationFrame(this.nextChange),clearTimeout(this.safty),this.managedInput=!1,this.setValue()}doNextChange(e){return this.changeCount+=1,this.changeCount%he===0&&this.doChange(e),requestAnimationFrame(()=>{this.nextChange=this.doNextChange(e)})}stepBy(e){if(this.disabled||this.readonly)return;const t=this.min===void 0?0:this.min;let r=this.value;r+=e*this._step,Number.isNaN(this.value)&&(r=t),r=this.valueWithLimits(r),this.requestUpdate(),this._value=this.validateInput(r),this.inputElement.value=this.numberFormatter.format(r),this.inputElement.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),this.indeterminate=!1,this.focus()}increment(e=1){this.stepBy(1*e)}decrement(e=1){this.stepBy(-1*e)}handleKeydown(e){if(!this.isComposing)switch(e.code){case"ArrowUp":{e.preventDefault(),this.increment(e.shiftKey?this.stepModifier:1),this.setValue();break}case"ArrowDown":{e.preventDefault(),this.decrement(e.shiftKey?this.stepModifier:1),this.setValue();break}}}onScroll(e){e.preventDefault(),this.managedInput=!0;const t=e.shiftKey?e.deltaX/Math.abs(e.deltaX):e.deltaY/Math.abs(e.deltaY);t!==0&&!Number.isNaN(t)&&(this.stepBy(t*(e.shiftKey?this.stepModifier:1)),clearTimeout(this.queuedChangeEvent),this.queuedChangeEvent=setTimeout(()=>{this.setValue()},pe)),this.managedInput=!1}onFocus(){super.onFocus(),this._trackingValue=this.inputValue,this.keyboardFocused=!this.readonly&&!0,this.addEventListener("wheel",this.onScroll,{passive:!1}),this.valueBeforeFocus=this.inputElement.value}onBlur(e){super.onBlur(e),this.keyboardFocused=!this.readonly&&!1,this.removeEventListener("wheel",this.onScroll),this.isIntentDecimal=!1}handleFocusin(){this.focused=!this.readonly&&!0,this.keyboardFocused=!this.readonly&&!0}handleFocusout(){this.focused=!this.readonly&&!1,this.keyboardFocused=!this.readonly&&!1}handleChange(){const e=this.convertValueToNumber(this.inputValue);if(this.wasIndeterminate&&(this.wasIndeterminate=!1,this.indeterminateValue=void 0,Number.isNaN(e))){this.indeterminate=!0;return}this.setValue(e),this.inputElement.value=this.formattedValue}handleCompositionStart(){this.isComposing=!0}handleCompositionEnd(){this.isComposing=!1,requestAnimationFrame(()=>{this.inputElement.dispatchEvent(new Event("input",{composed:!0,bubbles:!0}))})}handleInputElementPointerdown(){this.hasRecentlyReceivedPointerDown=!0,this.updateComplete.then(()=>{requestAnimationFrame(()=>{this.hasRecentlyReceivedPointerDown=!1})})}handleInput(e){if(this.isComposing){if(e.data){const u=this.convertValueToNumber(e.data);Number.isNaN(u)&&(this.inputElement.value=this.indeterminate?w:this._trackingValue,this.isComposing=!1)}e.stopPropagation();return}this.indeterminate&&(this.wasIndeterminate=!0,this.indeterminateValue=this.value,this.inputElement.value=this.inputElement.value.replace(w,"")),e.data&&this.decimalsChars.has(e.data)&&(this.isIntentDecimal=!0);const{value:t,selectionStart:r}=this.inputElement,o=[...t].map(u=>R[u]||u).join("");if(this.numberParser.isValidPartialNumber(o)){this.lastCommitedValue=this.lastCommitedValue??this.value;const u=this.convertValueToNumber(o);!o&&this.indeterminateValue?(this.indeterminate=!0,this._value=this.indeterminateValue):(this.indeterminate=!1,this._value=this.validateInput(u)),this._trackingValue=o,this.inputElement.value=o,this.inputElement.setSelectionRange(r,r);return}this.inputElement.value=this.indeterminate?w:this._trackingValue,e.stopPropagation();const i=o.length,n=this._trackingValue.length,l=(r||i)-(i-n);this.inputElement.setSelectionRange(l,l)}valueWithLimits(e){let t=e;return this.min!==void 0&&(t=Math.max(this.min,t)),this.max!==void 0&&(t=Math.min(this.max,t)),t}validateInput(e){e=this.valueWithLimits(e);const t=e<0?-1:1;if(e*=t,this.step){const r=this.min===void 0?0:this.min,o=Number.parseFloat(this.valueFormatter.format((e-r)%this.step));if(o===0||(Math.round(o/this.step)===1?e+=this.step-o:e-=o),this.max!==void 0)for(;e>this.max;)e-=this.step;e=Number.parseFloat(this.valueFormatter.format(e))}return e*=t,e}get displayValue(){const e=this.focused?"":w;return this.indeterminate?e:this.formattedValue}clearNumberFormatterCache(){this._numberFormatter=void 0,this._numberParser=void 0}get numberFormatter(){if(!this._numberFormatter||!this._numberFormatterFocused){const{style:e,unit:t,unitDisplay:r,...o}=this.formatOptions;e!=="unit"&&(o.style=e),this._numberFormatterFocused=new k(this.languageResolver.language,o);try{this._numberFormatter=new k(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberFormatter.format(1)}catch{e==="unit"&&(this._forcedUnit=t),this._numberFormatter=this._numberFormatterFocused}}return this.focused?this._numberFormatterFocused:this._numberFormatter}clearValueFormatterCache(){this._valueFormatter=void 0}get valueFormatter(){if(!this._valueFormatter){const e=this.step?this.step===Math.floor(this.step)?0:this.step.toString().split(".")[1].length:0;this._valueFormatter=new k("en",{useGrouping:!1,maximumFractionDigits:e})}return this._valueFormatter}get numberParser(){if(!this._numberParser||!this._numberParserFocused){const{style:e,unit:t,unitDisplay:r,...o}=this.formatOptions;e!=="unit"&&(o.style=e),this._numberParserFocused=new E(this.languageResolver.language,o);try{this._numberParser=new E(this.languageResolver.language,this.formatOptions),this._forcedUnit="",this._numberParser.parse("0")}catch{e==="unit"&&(this._forcedUnit=t),this._numberParser=this._numberParserFocused}}return this.focused?this._numberParserFocused:this._numberParser}renderField(){return this.autocomplete="off",d.x`
|
25
|
-
${super.renderField()}
|
26
|
-
${this.hideStepper?d.E:d.x`
|
27
|
-
<span
|
28
|
-
class="buttons"
|
29
|
-
@focusin=${this.handleFocusin}
|
30
|
-
@focusout=${this.handleFocusout}
|
31
|
-
${A({start:["pointerdown",this.handlePointerdown],streamInside:[["pointermove","pointerenter","pointerleave","pointerover","pointerout"],this.handlePointermove],end:[["pointerup","pointercancel","pointerleave"],this.handlePointerup]})}
|
32
|
-
>
|
33
|
-
<luzmo-infield-button
|
34
|
-
inline="end"
|
35
|
-
block="start"
|
36
|
-
class="button step-up"
|
37
|
-
aria-hidden="true"
|
38
|
-
label=${"Increase "+this.appliedLabel}
|
39
|
-
size=${this.size}
|
40
|
-
tabindex="-1"
|
41
|
-
?focused=${this.focused}
|
42
|
-
?disabled=${this.disabled||this.readonly||this.max!==void 0&&this.value===this.max}
|
43
|
-
?quiet=${this.quiet}
|
44
|
-
>
|
45
|
-
${z.O2(z.b)}
|
46
|
-
</luzmo-infield-button>
|
47
|
-
<luzmo-infield-button
|
48
|
-
inline="end"
|
49
|
-
block="end"
|
50
|
-
class="button step-down"
|
51
|
-
aria-hidden="true"
|
52
|
-
label=${"Decrease "+this.appliedLabel}
|
53
|
-
size=${this.size}
|
54
|
-
tabindex="-1"
|
55
|
-
?focused=${this.focused}
|
56
|
-
?disabled=${this.disabled||this.readonly||this.min!==void 0&&this.value===this.min}
|
57
|
-
?quiet=${this.quiet}
|
58
|
-
>
|
59
|
-
${z.O2(z.T)}
|
60
|
-
</luzmo-infield-button>
|
61
|
-
</span>
|
62
|
-
`}
|
63
|
-
`}update(e){if((e.has("formatOptions")||e.has("resolvedLanguage"))&&this.clearNumberFormatterCache(),e.has("value")||e.has("max")||e.has("min")||e.has("step")){const t=this.numberParser.parse(this.formattedValue.replace(this._forcedUnit,""));this.value=t,this.clearValueFormatterCache()}super.update(e)}willUpdate(e){this.multiline=!1,e.has(O)&&this.clearNumberFormatterCache()}firstUpdated(e){super.firstUpdated(e),this.addEventListener("keydown",this.handleKeydown),this.addEventListener("compositionstart",this.handleCompositionStart),this.addEventListener("compositionend",this.handleCompositionEnd)}updated(e){if(!(!this.inputElement||!this.isConnected)){if(e.has("min")||e.has("formatOptions")){const t=this.min!==void 0&&this.min>=0,{maximumFractionDigits:r}=this.numberFormatter.resolvedOptions(),o=r&&r>0;let i="numeric";m.isIPhone()&&!t?i="text":(m.isIOS()&&o||m.isAndroid()&&o&&t)&&(i="decimal"),this.inputElement.inputMode=i}e.has("focused")&&this.focused&&!this.hasRecentlyReceivedPointerDown&&this.formatOptions.unit&&this.setSelectionRange(0,this.displayValue.length)}}}h([d.e(".buttons")],b.prototype,"buttons",2);h([d.n({type:Boolean,reflect:!0})],b.prototype,"focused",2);h([d.n({type:Object,attribute:"format-options"})],b.prototype,"formatOptions",2);h([d.n({type:Boolean,reflect:!0,attribute:"hide-stepper"})],b.prototype,"hideStepper",2);h([d.n({type:Boolean,reflect:!0})],b.prototype,"indeterminate",2);h([d.n({type:Boolean,reflect:!0,attribute:"keyboard-focused"})],b.prototype,"keyboardFocused",2);h([d.n({type:Number})],b.prototype,"max",2);h([d.n({type:Number})],b.prototype,"min",2);h([d.n({type:Number})],b.prototype,"step",2);h([d.n({type:Number,reflect:!0,attribute:"step-modifier"})],b.prototype,"stepModifier",2);h([d.n({type:Number})],b.prototype,"value",1);customElements.get("luzmo-number-field")||customElements.define("luzmo-number-field",b);exports.LanguageResolutionController=M;exports.LuzmoInfieldButton=v;exports.LuzmoNumberField=b;exports.streamingListener=A;
|
package/lib/index-Dq3HAOaM.js
DELETED
@@ -1,127 +0,0 @@
|
|
1
|
-
/*! * A kit of modern Luzmo Web Components for analytics in your web application.
|
2
|
-
*
|
3
|
-
* Copyright © 2024 Luzmo
|
4
|
-
* All rights reserved.
|
5
|
-
* Luzmo web components (“Luzmo Web Components”)
|
6
|
-
* must be used according to the Luzmo Terms of Service.
|
7
|
-
* This license allows users with a current active Luzmo account
|
8
|
-
* to use the Luzmo Web Components. This license terminates
|
9
|
-
* automatically if a user no longer has an active Luzmo account.
|
10
|
-
* Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
|
11
|
-
*
|
12
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
13
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
14
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
15
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
16
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
17
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
18
|
-
* SOFTWARE.
|
19
|
-
* */
|
20
|
-
import { S as b, a as h, L as m, r as p, x as r, o as u, n as g, e as c } from "./if-defined-BbzmSG-O.js";
|
21
|
-
import "./index-Bd4cKS9O.js";
|
22
|
-
import "./index-CtEJZdT0.js";
|
23
|
-
import "./index-C9xEN5Ji.js";
|
24
|
-
import "./index-CBCm4_7S.js";
|
25
|
-
import { C as v, h as z } from "./index-DdtjeKYI.js";
|
26
|
-
import { r as f } from "./directive-helpers-eY1rHtyn.js";
|
27
|
-
const y = ":host .settings-container{display:flex;flex-direction:column;gap:var(--luzmo-spacing-2)}:host .settings-row{display:flex;justify-content:flex-start;align-items:center;gap:var(--luzmo-display-settings-binning-gap, var(--display-settings-binning-gap))}:host{--display-settings-binning-gap: var(--luzmo-spacing-3)}:host([size=s]){--display-settings-binning-gap: var(--luzmo-spacing-3)}:host([size=l]){--display-settings-binning-gap: var(--luzmo-spacing-4)}:host([size=xl]){--display-settings-binning-gap: var(--luzmo-spacing-5)}";
|
28
|
-
var _ = Object.defineProperty, l = (o, t, e, a) => {
|
29
|
-
for (var i = void 0, n = o.length - 1, d; n >= 0; n--)
|
30
|
-
(d = o[n]) && (i = d(t, e, i) || i);
|
31
|
-
return i && _(t, e, i), i;
|
32
|
-
};
|
33
|
-
class s extends b(m, {
|
34
|
-
validSizes: Object.values(h)
|
35
|
-
}) {
|
36
|
-
constructor() {
|
37
|
-
super(...arguments), this.slotContent = {};
|
38
|
-
}
|
39
|
-
static get styles() {
|
40
|
-
return [p(y)];
|
41
|
-
}
|
42
|
-
willUpdate(t) {
|
43
|
-
var e, a, i, n;
|
44
|
-
t.has("slotContent") && (this._enabled = ((a = (e = this.slotContent) == null ? void 0 : e.bins) == null ? void 0 : a.enabled) ?? !1, this._binWidth = ((n = (i = this.slotContent) == null ? void 0 : i.bins) == null ? void 0 : n.number) ?? 10);
|
45
|
-
}
|
46
|
-
toggleBinning() {
|
47
|
-
this._enabled = !this._enabled, this.sendEvent();
|
48
|
-
}
|
49
|
-
setBinning() {
|
50
|
-
this._binWidth = this.binWidthElement.value, this.sendEvent();
|
51
|
-
}
|
52
|
-
sendEvent() {
|
53
|
-
const t = {
|
54
|
-
enabled: !!this._enabled,
|
55
|
-
number: this._binWidth ?? 10
|
56
|
-
};
|
57
|
-
this.dispatchEvent(
|
58
|
-
new CustomEvent("slot-content-changed", {
|
59
|
-
bubbles: !0,
|
60
|
-
composed: !0,
|
61
|
-
cancelable: !0,
|
62
|
-
detail: {
|
63
|
-
slotContent: {
|
64
|
-
...this.slotContent,
|
65
|
-
bins: t
|
66
|
-
}
|
67
|
-
}
|
68
|
-
})
|
69
|
-
);
|
70
|
-
}
|
71
|
-
renderBinWidth() {
|
72
|
-
return r`<div class="setting">
|
73
|
-
<luzmo-field-label for="bin-width">Bin width</luzmo-field-label>
|
74
|
-
<luzmo-number-field
|
75
|
-
id="bin-width"
|
76
|
-
min="0"
|
77
|
-
value=${this._binWidth ?? 10}
|
78
|
-
.size=${this.size}
|
79
|
-
@change=${this.setBinning}
|
80
|
-
></luzmo-number-field>
|
81
|
-
</div>`;
|
82
|
-
}
|
83
|
-
render() {
|
84
|
-
return r`<div class="settings-container">
|
85
|
-
<div class="settings-row">
|
86
|
-
<div class="setting">
|
87
|
-
<luzmo-field-label for="binning">Binning</luzmo-field-label>
|
88
|
-
<luzmo-action-button
|
89
|
-
id="binning"
|
90
|
-
toggles
|
91
|
-
emphasized
|
92
|
-
.size=${this.size}
|
93
|
-
?selected=${this._enabled}
|
94
|
-
class=${u(this._enabled ? "active" : "inactive")}
|
95
|
-
@click=${this.toggleBinning}
|
96
|
-
>
|
97
|
-
<luzmo-icon
|
98
|
-
slot="icon"
|
99
|
-
.icon=${this._enabled ? v : z}
|
100
|
-
></luzmo-icon>
|
101
|
-
${this._enabled ? "Enabled" : "Disabled"}
|
102
|
-
</luzmo-action-button>
|
103
|
-
</div>
|
104
|
-
${this._enabled ? this.renderBinWidth() : ""}
|
105
|
-
</div>
|
106
|
-
</div>`;
|
107
|
-
}
|
108
|
-
}
|
109
|
-
l([
|
110
|
-
g({ type: String, reflect: !0 })
|
111
|
-
], s.prototype, "language");
|
112
|
-
l([
|
113
|
-
g()
|
114
|
-
], s.prototype, "slotContent");
|
115
|
-
l([
|
116
|
-
f()
|
117
|
-
], s.prototype, "_enabled");
|
118
|
-
l([
|
119
|
-
c("#bin-width")
|
120
|
-
], s.prototype, "binWidthElement");
|
121
|
-
customElements.get("luzmo-display-settings-binning") || customElements.define(
|
122
|
-
"luzmo-display-settings-binning",
|
123
|
-
s
|
124
|
-
);
|
125
|
-
export {
|
126
|
-
s as LuzmoDisplaySettingsBinning
|
127
|
-
};
|
package/lib/index-jt6FL_uE.cjs
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
/*! * A kit of modern Luzmo Web Components for analytics in your web application.
|
2
|
-
*
|
3
|
-
* Copyright © 2024 Luzmo
|
4
|
-
* All rights reserved.
|
5
|
-
* Luzmo web components (“Luzmo Web Components”)
|
6
|
-
* must be used according to the Luzmo Terms of Service.
|
7
|
-
* This license allows users with a current active Luzmo account
|
8
|
-
* to use the Luzmo Web Components. This license terminates
|
9
|
-
* automatically if a user no longer has an active Luzmo account.
|
10
|
-
* Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
|
11
|
-
*
|
12
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
13
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
14
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
15
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
16
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
17
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
18
|
-
* SOFTWARE.
|
19
|
-
* */
|
20
|
-
"use strict";const v=require("./index-Bo1DpZ-1.cjs"),o=require("./if-defined-V7yEJWI3.cjs"),m=":host{pointer-events:none;transform:none;transform:var(--luzmo-icon-transform, none);inline-size:var(--luzmo-icon-inline-size, var(--luzmo-icon-size, var(--icon-size)));block-size:var(--luzmo-icon-block-size, var(--luzmo-icon-size, var(--icon-size)));font-size:var(--luzmo-icon-block-size, var(--luzmo-icon-size, var(--icon-size)));color:inherit;color:var(--luzmo-icon-color, inherit);fill:currentColor;display:inline-block}::slotted(svg),:host svg,:host img{--icon-vertical-align: var(--parent-element-icon-vertical-align, -.125em);vertical-align:var(--icon-vertical-align)!important}:host([block]){display:block;vertical-align:0}:host([block]) svg,:host([block]) img{--icon-vertical-align: var(--parent-element-icon-vertical-align, 0)}:host([size=xxs]){--icon-size: var(--luzmo-icon-size-xxs)}:host([size=xs]){--icon-size: var(--luzmo-icon-size-xs)}:host([size=s]){--icon-size: var(--luzmo-icon-size-s)}:host,:host([size=m]){--icon-size: var(--luzmo-icon-size-m)}:host([size=l]){--icon-size: var(--luzmo-icon-size-l)}:host([size=xl]){--icon-size: var(--luzmo-icon-size-xl)}:host([size=xxl]){--icon-size: var(--luzmo-icon-size-xxl)}:host(:not(:root)){overflow:visible}@media (forced-colors: active){:host{forced-color-adjust:auto}}img,svg,::slotted(*){height:100%;width:100%;vertical-align:top;color:inherit}@media (forced-colors: active){img,svg,::slotted(*){forced-color-adjust:auto}}";var d=Object.defineProperty,u=(t,i,n,z)=>{for(var e=void 0,s=t.length-1,l;s>=0;s--)(l=t[s])&&(e=l(i,n,e)||e);return e&&d(i,n,e),e};class a extends o.LuzmoElement{constructor(){super(...arguments),this.label=""}static get styles(){return[o.r(m)]}connectedCallback(){super.connectedCallback()}disconnectedCallback(){super.disconnectedCallback()}update(i){i.has("label")&&(this.label?this.removeAttribute("aria-hidden"):this.setAttribute("aria-hidden","true")),super.update(i)}render(){return o.x` <slot></slot> `}}u([o.n({reflect:!0})],a.prototype,"label");u([o.n({reflect:!0})],a.prototype,"size");var h=Object.defineProperty,c=(t,i,n,z)=>{for(var e=void 0,s=t.length-1,l;s>=0;s--)(l=t[s])&&(e=l(i,n,e)||e);return e&&h(i,n,e),e};class r extends a{constructor(){super(...arguments),this.block=!1}render(){return this.icon?v.O2(this.icon,this.options):this.src?o.x` <img src=${this.src} alt=${o.o(this.label)} /> `:super.render()}}c([o.n()],r.prototype,"src");c([o.n()],r.prototype,"options");c([o.n()],r.prototype,"icon");c([o.n({type:Boolean})],r.prototype,"block");customElements.get("luzmo-icon")||customElements.define("luzmo-icon",r);exports.LuzmoIcon=r;
|
package/lib/index-kJR406YZ.cjs
DELETED
@@ -1,112 +0,0 @@
|
|
1
|
-
/*! * A kit of modern Luzmo Web Components for analytics in your web application.
|
2
|
-
*
|
3
|
-
* Copyright © 2024 Luzmo
|
4
|
-
* All rights reserved.
|
5
|
-
* Luzmo web components (“Luzmo Web Components”)
|
6
|
-
* must be used according to the Luzmo Terms of Service.
|
7
|
-
* This license allows users with a current active Luzmo account
|
8
|
-
* to use the Luzmo Web Components. This license terminates
|
9
|
-
* automatically if a user no longer has an active Luzmo account.
|
10
|
-
* Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
|
11
|
-
*
|
12
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
13
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
14
|
-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
15
|
-
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
16
|
-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
17
|
-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
18
|
-
* SOFTWARE.
|
19
|
-
* */
|
20
|
-
"use strict";const C=require("./directive-helpers-BSB0tfc9.cjs"),g=require("./if-defined-V7yEJWI3.cjs"),pt=require("./index-Bo1DpZ-1.cjs"),St=require("./async-directive-CPjMHOPu.cjs");/**
|
21
|
-
* @license
|
22
|
-
* Copyright 2021 Google LLC
|
23
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
24
|
-
*/function ie(e){return(t,n)=>{const{slot:i,selector:o}=e??{},s="slot"+(i?`[name=${i}]`:":not([name])");return g.e$1(t,n,{get(){var a;const r=(a=this.renderRoot)==null?void 0:a.querySelector(s),l=(r==null?void 0:r.assignedElements(e))??[];return o===void 0?l:l.filter(c=>c.matches(o))}})}}class oe extends Event{constructor(t,n,i){super("slottable-request",{bubbles:!1,cancelable:!0,composed:!1}),this.name=t,this.data=n,this.slotName=i===void 0?t:`${t}.${i}`}}const Ot=Symbol("remove-slottable-request");/**
|
25
|
-
* @license
|
26
|
-
* Copyright 2018 Google LLC
|
27
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
28
|
-
*/const se="important",we=" !"+se,kt=C.e(class extends C.i{constructor(e){var t;if(super(e),e.type!==C.t.ATTRIBUTE||e.name!=="style"||((t=e.strings)==null?void 0:t.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(e){return Object.keys(e).reduce((t,n)=>{const i=e[n];return i==null?t:t+`${n=n.includes("-")?n:n.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${i};`},"")}update(e,[t]){const{style:n}=e.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(t)),this.render(t);for(const i of this.ft)t[i]==null&&(this.ft.delete(i),i.includes("-")?n.removeProperty(i):n[i]=null);for(const i in t){const o=t[i];if(o!=null){this.ft.add(i);const s=typeof o=="string"&&o.endsWith(we);i.includes("-")||s?n.setProperty(i,s?o.slice(0,-11):o,s?se:""):n[i]=o}}return g.T}});function Ee(e,t,n=[]){for(const[i,o]of t.entries()){const s=e[i],r=s.parentElement||s.getRootNode();n[i]&&n[i](o),r&&r!==s&&s.replaceWith(o),delete e[i]}return t}const xe=(e,t,{position:n,prepareCallback:i}={position:"beforeend"})=>{let{length:o}=e;if(o===0)return()=>e;let s=1,r=0;(n==="afterbegin"||n==="afterend")&&(s=-1,r=o-1);const l=new Array(o),a=new Array(o),c=document.createComment("placeholder for reparented element");do{const h=e[r];i&&(a[r]=i(h)),l[r]=c.cloneNode();const d=h.parentElement||h.getRootNode();d&&d!==h&&d.replaceChild(l[r],h),t.insertAdjacentElement(n,h),r+=s}while(--o>0);return function(){return Ee(l,e,a)}},Ce=1e3,Pe=1e3;class Oe{constructor(t={}){this.warmUpDelay=Ce,this.coolDownDelay=Pe,this.isWarm=!1,this.timeout=0,Object.assign(this,t)}openTimer(t){if(this.cancelCooldownTimer(),!this.component||t!==this.component)return this.component&&(this.close(this.component),this.cancelCooldownTimer()),this.component=t,this.isWarm?Promise.resolve(!1):(this.promise=new Promise(n=>{this.resolve=n,this.timeout=window.setTimeout(()=>{this.resolve&&(this.resolve(!1),this.isWarm=!0)},this.warmUpDelay)}),this.promise);if(this.promise)return this.promise;throw new Error("Inconsistent state")}close(t){this.component&&this.component===t&&(this.resetCooldownTimer(),this.timeout>0&&(clearTimeout(this.timeout),this.timeout=0),this.resolve&&(this.resolve(!0),delete this.resolve),delete this.promise,delete this.component)}resetCooldownTimer(){this.isWarm&&(this.cooldownTimeout&&window.clearTimeout(this.cooldownTimeout),this.cooldownTimeout=window.setTimeout(()=>{this.isWarm=!1,delete this.cooldownTimeout},this.coolDownDelay))}cancelCooldownTimer(){this.cooldownTimeout&&window.clearTimeout(this.cooldownTimeout),delete this.cooldownTimeout}}const Et=new Oe,tt=()=>{},zt=(e,t,n)=>{const i=new AbortController,o=new Map,s=()=>{i.abort(),n()};let r,l;const a=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{l=requestAnimationFrame(()=>{s()})})}),c=d=>{d.target===e&&(o.set(d.propertyName,o.get(d.propertyName)-1),o.get(d.propertyName)||o.delete(d.propertyName),o.size===0&&s())},h=d=>{d.target===e&&(o.has(d.propertyName)||o.set(d.propertyName,0),o.set(d.propertyName,o.get(d.propertyName)+1),cancelAnimationFrame(a),cancelAnimationFrame(r),cancelAnimationFrame(l))};e.addEventListener("transitionrun",h,{signal:i.signal}),e.addEventListener("transitionend",c,{signal:i.signal}),e.addEventListener("transitioncancel",c,{signal:i.signal}),t()};function L(){return new Promise(e=>requestAnimationFrame(()=>e()))}class rt extends g.LuzmoElement{constructor(){super(...arguments),this.dispose=tt,this.offset=0,this.willPreventClose=!1}applyFocus(t,n){}get delayed(){return!1}set delayed(t){}get disabled(){return!1}set disabled(t){}get elementResolver(){return this._elementResolver}set elementResolver(t){this._elementResolver=t}ensureOnDOM(t){}makeTransition(t){return null}manageDelay(t){}manageDialogOpen(){}managePopoverOpen(){}managePosition(){}get open(){return!1}set open(t){}get placementController(){return this._placementController}set placementController(t){this._placementController=t}requestSlottable(){}returnFocus(){}get state(){return"closed"}set state(t){}manuallyKeepOpen(){}static update(){const t=new CustomEvent("luzmo-update-overlays",{bubbles:!0,composed:!0,cancelable:!0});document.dispatchEvent(t)}static async open(t,n,i,o){await Promise.resolve().then(()=>et);const s=arguments.length===2,r=i||t,l=new this;let a=!1;const c=xe([r],l,{position:"beforeend",prepareCallback:f=>{const u=f.slot;return f.removeAttribute("slot"),()=>{f.slot=u}}});if(l.dispose=()=>{l.addEventListener("luzmo-closed",()=>{a||(c(),a=!0),requestAnimationFrame(()=>{l.remove()})}),l.open=!1,l.dispose=tt},!s&&r&&o){const f=t,u=n,p=o;return rt.applyOptions(l,{...p,delayed:p.delayed||r.hasAttribute("delayed"),trigger:p.virtualTrigger||f,type:u==="modal"?"modal":u==="hover"?"hint":"auto"}),f.after(l),await l.updateComplete,l.open=!0,l.dispose}const d=n;return l.append(r),rt.applyOptions(l,{...d,delayed:d.delayed||r.hasAttribute("delayed")}),l.updateComplete.then(()=>{l.open=!0}),l}static applyOptions(t,n){t.delayed=!!n.delayed,t.receivesFocus=n.receivesFocus??"auto",t.triggerElement=n.trigger||null,t.type=n.type||"modal",t.offset=n.offset??0,t.placement=n.placement,t.willPreventClose=!!n.notImmediatelyClosable}}const _t=e=>e.querySelector(pt.userFocusableSelector),Nt=e=>e.assignedElements().find(n=>n.matches(pt.userFocusableSelector));class Bt extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="open",this.newState="closed"}}class qt extends Event{constructor(){super("beforetoggle",{bubbles:!1,composed:!1}),this.currentState="closed",this.newState="open"}}class z extends Event{constructor(t,n,{publish:i,interaction:o,reason:s}){super(t,{bubbles:i,composed:i}),this.overlay=n,this.detail={interaction:o,reason:s}}}class at{constructor(t,n){this.x=0,this.y=0,this.x=t,this.y=n}updateBoundingClientRect(t,n){this.x=t,this.y=n,rt.update()}getBoundingClientRect(){return{width:0,height:0,top:this.y,right:this.x,y:this.y,x:this.x,bottom:this.y,left:this.x,toJSON(){}}}}function Te(e){class t extends e{async manageDialogOpen(){const i=this.open;if(await L(),await this.managePosition(),this.open!==i)return;const o=await this.dialogMakeTransition(i);this.open===i&&await this.dialogApplyFocus(i,o)}dialogMakeTransition(i){let o=null;const s=(l,a)=>()=>{if(l.open=i,!i){const h=()=>{l.removeEventListener("close",h)};l.addEventListener("close",h)}if(a>0)return;const c=i?qt:Bt;this.dispatchEvent(new c),i&&(l.matches(pt.userFocusableSelector)&&(o=l),o=o||_t(l),o||l.querySelectorAll("slot").forEach(d=>{o||(o=Nt(d))}),!(!this.isConnected||this.dialogEl.open)&&this.dialogEl.showModal())},r=(l,a)=>()=>{if(this.open!==i)return;const c=i?"luzmo-opened":"luzmo-closed";if(a>0){l.dispatchEvent(new z(c,this,{interaction:this.type,publish:!1}));return}if(!this.isConnected||i!==this.open)return;const h=async()=>{const d=this.triggerElement instanceof at;this.dispatchEvent(new z(c,this,{interaction:this.type,publish:d})),l.dispatchEvent(new z(c,this,{interaction:this.type,publish:!1})),this.triggerElement&&!d&&this.triggerElement.dispatchEvent(new z(c,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await L(),await L(),i===this.open&&i===!1&&this.requestSlottable()};!i&&this.dialogEl.open?(this.dialogEl.addEventListener("close",()=>{h()},{once:!0}),this.dialogEl.close()):h()};return this.elements.forEach((l,a)=>{zt(l,s(l,a),r(l,a))}),o}dialogApplyFocus(i,o){this.applyFocus(i,o)}}return t}function Ae(e){class t extends e{async managePopoverOpen(){await this.managePosition()}async manageDelay(i){if(i===!1||i!==this.open){Et.close(this);return}this.delayed&&await Et.openTimer(this)&&(this.open=!i)}ensureOnDOM(i){document.body.offsetHeight}makeTransition(i){if(this.open!==i)return null;let o=null;const s=(l,a)=>()=>{if(i!==this.open)return;if(l.open=i,a===0){const h=i?qt:Bt;this.dispatchEvent(new h)}if(i!==!0||(l.matches(pt.userFocusableSelector)&&(o=l),o=o||_t(l),o))return;l.querySelectorAll("slot").forEach(h=>{o||(o=Nt(h))})},r=(l,a)=>async()=>{if(this.open!==i)return;const c=i?"luzmo-opened":"luzmo-closed";if(l.dispatchEvent(new z(c,this,{interaction:this.type})),a>0)return;const h=this.triggerElement instanceof at;this.dispatchEvent(new z(c,this,{interaction:this.type,publish:h})),this.triggerElement&&!h&&this.triggerElement.dispatchEvent(new z(c,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await L(),await L(),i===this.open&&i===!1&&this.requestSlottable()};return this.elements.forEach((l,a)=>{zt(l,s(l,a),r(l,a))}),o}}return t}const Re=CSS.supports("(overlay: auto)");function Gt(e){let t=!1;try{t=e.matches(":popover-open")}catch{}let n=!1;try{n=e.matches(":open")}catch{}return t||n}function De(e){class t extends e{async manageDelay(i){if(i===!1||i!==this.open){Et.close(this);return}this.delayed&&await Et.openTimer(this)&&(this.open=!i)}shouldHidePopover(i){if(i&&this.open!==i)return;const o=async({newState:s}={})=>{s!=="open"&&await this.placementController.resetOverlayPosition()};if(!Gt(this.dialogEl)){o();return}this.dialogEl.addEventListener("toggle",o,{once:!0})}shouldShowPopover(i){let o=!1;try{o=this.dialogEl.matches(":popover-open")}catch{}let s=!1;try{s=this.dialogEl.matches(":open")}catch{}i&&this.open===i&&!o&&!s&&this.isConnected&&(this.dialogEl.showPopover(),this.managePosition())}async ensureOnDOM(i){await L(),Re||await this.shouldHidePopover(i),this.shouldShowPopover(i),await L()}makeTransition(i){if(this.open!==i)return null;let o=null;const s=(l,a)=>()=>{if(l.open=i,a===0){const h=i?qt:Bt;this.dispatchEvent(new h)}if(!i||(l.matches(pt.userFocusableSelector)&&(o=l),o=o||_t(l),o))return;l.querySelectorAll("slot").forEach(h=>{o||(o=Nt(h))})},r=(l,a)=>()=>{if(this.open!==i)return;const c=i?"luzmo-opened":"luzmo-closed";if(a>0){l.dispatchEvent(new z(c,this,{interaction:this.type,publish:!1}));return}const h=async()=>{if(this.open!==i)return;await L();const f=this.triggerElement instanceof at;this.dispatchEvent(new z(c,this,{interaction:this.type,publish:f})),l.dispatchEvent(new z(c,this,{interaction:this.type,publish:!1})),this.triggerElement&&!f&&this.triggerElement.dispatchEvent(new z(c,this,{interaction:this.type,publish:!0})),this.state=i?"opened":"closed",this.returnFocus(),await L(),await L(),i===this.open&&i===!1&&this.requestSlottable()};if(this.open!==i)return;const d=Gt(this.dialogEl);i!==!0&&d&&this.isConnected?(this.dialogEl.addEventListener("beforetoggle",()=>{h()},{once:!0}),this.dialogEl.hidePopover()):h()};return this.elements.forEach((l,a)=>{zt(l,s(l,a),r(l,a))}),o}}return t}const Se="showPopover"in document.createElement("div");class ke{constructor(){this.root=document.body,this.stack=[],this.handlePointerdown=t=>{this.pointerdownPath=t.composedPath(),this.lastOverlay=this.stack.at(-1)},this.handlePointerup=()=>{const t=this.pointerdownPath;if(this.pointerdownPath=void 0,this.stack.length===0||!(t!=null&&t.length))return;const n=this.lastOverlay;this.lastOverlay=void 0;const i=this.stack.length-1,o=this.stack.filter((s,r)=>!t.find(a=>a===s||a===(s==null?void 0:s.triggerElement)&&(s==null?void 0:s.type)==="hint"||r===i&&s!==n&&s.triggerInteraction==="longpress")&&!s.shouldPreventClose()&&s.type!=="manual"&&!(s.type==="modal"&&n!==s));o.reverse(),o.forEach(s=>{this.closeOverlay(s);let r=s.parentOverlayToForceClose;for(;r;)this.closeOverlay(r),r=r.parentOverlayToForceClose})},this.handleBeforetoggle=t=>{const{target:n,newState:i}=t;i!=="open"&&this.closeOverlay(n)},this.handleKeydown=t=>{if(t.code!=="Escape"||this.stack.length===0)return;const n=this.stack.at(-1);if((n==null?void 0:n.type)==="page"){t.preventDefault();return}Se||(n==null?void 0:n.type)!=="manual"&&n&&this.closeOverlay(n)},this.bindEvents()}get document(){return this.root.ownerDocument||document}bindEvents(){this.document.addEventListener("pointerdown",this.handlePointerdown),this.document.addEventListener("pointerup",this.handlePointerup),this.document.addEventListener("keydown",this.handleKeydown)}closeOverlay(t){const n=this.stack.indexOf(t);n!==-1&&this.stack.splice(n,1),t.open=!1}overlaysByTriggerElement(t){return this.stack.filter(n=>n.triggerElement===t)}add(t){if(this.stack.includes(t)){const n=this.stack.indexOf(t);n!==-1&&(this.stack.splice(n,1),this.stack.push(t));return}if(t.type==="auto"||t.type==="modal"||t.type==="page"){const n="luzmo-overlay-query-path",i=new Event(n,{composed:!0,bubbles:!0});t.addEventListener(n,o=>{const s=o.composedPath();this.stack.forEach(r=>{!s.find(a=>a===r)&&r.type!=="manual"&&r.type!=="modal"&&this.closeOverlay(r)})},{once:!0}),t.dispatchEvent(i)}else if(t.type==="hint"){if(this.stack.some(i=>i.type!=="manual"&&i.triggerElement&&i.triggerElement===t.triggerElement)){t.open=!1;return}this.stack.forEach(i=>{i.type==="hint"&&this.closeOverlay(i)})}requestAnimationFrame(()=>{this.stack.push(t),t.addEventListener("beforetoggle",this.handleBeforetoggle,{once:!0})})}remove(t){this.closeOverlay(t)}}const Xt=new ke,Le=':host{display:contents;pointer-events:none;--luzmo-overlay-animation-distance: .5rem}:host(:has(> luzmo-tooltip)){--luzmo-overlay-animation-distance: var( --luzmo-tooltip-animation-distance, 4px )}.dialog{margin:0;border:0;background:none;padding:0;position:fixed;overflow:visible;opacity:1!important;box-sizing:border-box;max-height:calc(100vh - 16px);max-height:calc(100dvh - 16px);max-width:calc(100vw - 16px);height:auto;inset:auto;top:0;left:0;display:flex;--luzmo-overlay-open: true}.dialog:not([is-visible]){display:none}.dialog:focus{outline:none}dialog:modal{--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}:host(:not([open])) .dialog{--luzmo-overlay-open: false}.dialog::backdrop{display:none}.dialog:before{position:absolute;top:-999em;right:-999em;bottom:-999em;left:-999em;content:"";pointer-events:auto!important}.dialog:not(.not-immediately-closable):before{display:none}.dialog>div{width:100%}::slotted(*){pointer-events:auto;visibility:visible!important}::slotted(luzmo-popover){position:static}.dialog:not([actual-placement])[placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog:not([actual-placement])[placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog:not([actual-placement])[placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=top]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:var(--luzmo-overlay-animation-distance)}.dialog[actual-placement*=right]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=bottom]{padding-block:var(--luzmo-overlay-animation-distance);margin-top:calc(-1 * var(--luzmo-overlay-animation-distance))}.dialog[actual-placement*=left]{padding-inline:var(--luzmo-overlay-animation-distance);margin-left:var(--luzmo-overlay-animation-distance)}slot[name=longpress-describedby-descriptor]{display:none}@supports selector(:open){.dialog{opacity:0}.dialog:open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports selector(:popover-open){.dialog{opacity:0}.dialog:popover-open{opacity:1;--luzmo-popover-filter: drop-shadow(0px 2px 6px rgba(0, 0, 0, .15))}}@supports (overlay: auto){.dialog{display:none;transition:all var(--luzmo-overlay-animation-duration, .13s),translate 0s,display var(--luzmo-overlay-animation-duration, .13s);transition-behavior:allow-discrete}.dialog:popover-open,.dialog:modal{display:flex}}@supports (not selector(:open)) and (not selector(:popover-open)){:host:not([open]) .dialog{pointer-events:none}.dialog[actual-placement]{z-index:calc(var(--luzmo-overlay-z-index-base, 1000) + var(--luzmo-overlay-open-count))}}',J=Math.min,S=Math.max,xt=Math.round,vt=Math.floor,M=e=>({x:e,y:e}),Fe={left:"right",right:"left",bottom:"top",top:"bottom"},$e={start:"end",end:"start"};function Lt(e,t,n){return S(e,J(t,n))}function ct(e,t){return typeof e=="function"?e(t):e}function Q(e){return e.split("-")[0]}function ht(e){return e.split("-")[1]}function re(e){return e==="x"?"y":"x"}function Ht(e){return e==="y"?"height":"width"}function nt(e){return["top","bottom"].includes(Q(e))?"y":"x"}function Mt(e){return re(nt(e))}function ze(e,t,n){n===void 0&&(n=!1);const i=ht(e),o=Mt(e),s=Ht(o);let r=o==="x"?i===(n?"end":"start")?"right":"left":i==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(r=Ct(r)),[r,Ct(r)]}function _e(e){const t=Ct(e);return[Ft(e),t,Ft(t)]}function Ft(e){return e.replace(/start|end/g,t=>$e[t])}function Ne(e,t,n){const i=["left","right"],o=["right","left"],s=["top","bottom"],r=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:i:t?i:o;case"left":case"right":return t?s:r;default:return[]}}function Be(e,t,n,i){const o=ht(e);let s=Ne(Q(e),n==="start",i);return o&&(s=s.map(r=>r+"-"+o),t&&(s=s.concat(s.map(Ft)))),s}function Ct(e){return e.replace(/left|right|bottom|top/g,t=>Fe[t])}function qe(e){return{top:0,right:0,bottom:0,left:0,...e}}function le(e){return typeof e!="number"?qe(e):{top:e,right:e,bottom:e,left:e}}function Pt(e){const{x:t,y:n,width:i,height:o}=e;return{width:i,height:o,top:n,left:t,right:t+i,bottom:n+o,x:t,y:n}}function Jt(e,t,n){let{reference:i,floating:o}=e;const s=nt(t),r=Mt(t),l=Ht(r),a=Q(t),c=s==="y",h=i.x+i.width/2-o.width/2,d=i.y+i.height/2-o.height/2,f=i[l]/2-o[l]/2;let u;switch(a){case"top":u={x:h,y:i.y-o.height};break;case"bottom":u={x:h,y:i.y+i.height};break;case"right":u={x:i.x+i.width,y:d};break;case"left":u={x:i.x-o.width,y:d};break;default:u={x:i.x,y:i.y}}switch(ht(t)){case"start":u[r]-=f*(n&&c?-1:1);break;case"end":u[r]+=f*(n&&c?-1:1);break}return u}const He=async(e,t,n)=>{const{placement:i="bottom",strategy:o="absolute",middleware:s=[],platform:r}=n,l=s.filter(Boolean),a=await(r.isRTL==null?void 0:r.isRTL(t));let c=await r.getElementRects({reference:e,floating:t,strategy:o}),{x:h,y:d}=Jt(c,i,a),f=i,u={},p=0;for(let m=0;m<l.length;m++){const{name:y,fn:v}=l[m],{x:b,y:w,data:x,reset:E}=await v({x:h,y:d,initialPlacement:i,placement:f,strategy:o,middlewareData:u,rects:c,platform:r,elements:{reference:e,floating:t}});h=b??h,d=w??d,u={...u,[y]:{...u[y],...x}},E&&p<=50&&(p++,typeof E=="object"&&(E.placement&&(f=E.placement),E.rects&&(c=E.rects===!0?await r.getElementRects({reference:e,floating:t,strategy:o}):E.rects),{x:h,y:d}=Jt(c,f,a)),m=-1)}return{x:h,y:d,placement:f,strategy:o,middlewareData:u}};async function It(e,t){var n;t===void 0&&(t={});const{x:i,y:o,platform:s,rects:r,elements:l,strategy:a}=e,{boundary:c="clippingAncestors",rootBoundary:h="viewport",elementContext:d="floating",altBoundary:f=!1,padding:u=0}=ct(t,e),p=le(u),y=l[f?d==="floating"?"reference":"floating":d],v=Pt(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(y)))==null||n?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(l.floating)),boundary:c,rootBoundary:h,strategy:a})),b=d==="floating"?{x:i,y:o,width:r.floating.width,height:r.floating.height}:r.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(l.floating)),x=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},E=Pt(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:b,offsetParent:w,strategy:a}):b);return{top:(v.top-E.top+p.top)/x.y,bottom:(E.bottom-v.bottom+p.bottom)/x.y,left:(v.left-E.left+p.left)/x.x,right:(E.right-v.right+p.right)/x.x}}const Me=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:i,placement:o,rects:s,platform:r,elements:l,middlewareData:a}=t,{element:c,padding:h=0}=ct(e,t)||{};if(c==null)return{};const d=le(h),f={x:n,y:i},u=Mt(o),p=Ht(u),m=await r.getDimensions(c),y=u==="y",v=y?"top":"left",b=y?"bottom":"right",w=y?"clientHeight":"clientWidth",x=s.reference[p]+s.reference[u]-f[u]-s.floating[p],E=f[u]-s.reference[u],F=await(r.getOffsetParent==null?void 0:r.getOffsetParent(c));let O=F?F[w]:0;(!O||!await(r.isElement==null?void 0:r.isElement(F)))&&(O=l.floating[w]||s.floating[p]);const V=x/2-E/2,B=O/2-m[p]/2-1,$=J(d[v],B),K=J(d[b],B),q=$,Y=O-m[p]-K,A=O/2-m[p]/2+V,ot=Lt(q,A,Y),U=!a.arrow&&ht(o)!=null&&A!==ot&&s.reference[p]/2-(A<q?$:K)-m[p]/2<0,H=U?A<q?A-q:A-Y:0;return{[u]:f[u]+H,data:{[u]:ot,centerOffset:A-ot-H,...U&&{alignmentOffset:H}},reset:U}}}),Ie=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,i;const{placement:o,middlewareData:s,rects:r,initialPlacement:l,platform:a,elements:c}=t,{mainAxis:h=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:u="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:m=!0,...y}=ct(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=Q(o),b=nt(l),w=Q(l)===l,x=await(a.isRTL==null?void 0:a.isRTL(c.floating)),E=f||(w||!m?[Ct(l)]:_e(l)),F=p!=="none";!f&&F&&E.push(...Be(l,m,p,x));const O=[l,...E],V=await It(t,y),B=[];let $=((i=s.flip)==null?void 0:i.overflows)||[];if(h&&B.push(V[v]),d){const A=ze(o,r,x);B.push(V[A[0]],V[A[1]])}if($=[...$,{placement:o,overflows:B}],!B.every(A=>A<=0)){var K,q;const A=(((K=s.flip)==null?void 0:K.index)||0)+1,ot=O[A];if(ot)return{data:{index:A,overflows:$},reset:{placement:ot}};let U=(q=$.filter(H=>H.overflows[0]<=0).sort((H,G)=>H.overflows[1]-G.overflows[1])[0])==null?void 0:q.placement;if(!U)switch(u){case"bestFit":{var Y;const H=(Y=$.filter(G=>{if(F){const X=nt(G.placement);return X===b||X==="y"}return!0}).map(G=>[G.placement,G.overflows.filter(X=>X>0).reduce((X,be)=>X+be,0)]).sort((G,X)=>G[1]-X[1])[0])==null?void 0:Y[0];H&&(U=H);break}case"initialPlacement":U=l;break}if(o!==U)return{reset:{placement:U}}}return{}}}};async function We(e,t){const{placement:n,platform:i,elements:o}=e,s=await(i.isRTL==null?void 0:i.isRTL(o.floating)),r=Q(n),l=ht(n),a=nt(n)==="y",c=["left","top"].includes(r)?-1:1,h=s&&a?-1:1,d=ct(t,e);let{mainAxis:f,crossAxis:u,alignmentAxis:p}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return l&&typeof p=="number"&&(u=l==="end"?p*-1:p),a?{x:u*h,y:f*c}:{x:f*c,y:u*h}}const Ve=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,i;const{x:o,y:s,placement:r,middlewareData:l}=t,a=await We(t,e);return r===((n=l.offset)==null?void 0:n.placement)&&(i=l.arrow)!=null&&i.alignmentOffset?{}:{x:o+a.x,y:s+a.y,data:{...a,placement:r}}}}},Ue=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:i,placement:o}=t,{mainAxis:s=!0,crossAxis:r=!1,limiter:l={fn:y=>{let{x:v,y:b}=y;return{x:v,y:b}}},...a}=ct(e,t),c={x:n,y:i},h=await It(t,a),d=nt(Q(o)),f=re(d);let u=c[f],p=c[d];if(s){const y=f==="y"?"top":"left",v=f==="y"?"bottom":"right",b=u+h[y],w=u-h[v];u=Lt(b,u,w)}if(r){const y=d==="y"?"top":"left",v=d==="y"?"bottom":"right",b=p+h[y],w=p-h[v];p=Lt(b,p,w)}const m=l.fn({...t,[f]:u,[d]:p});return{...m,data:{x:m.x-n,y:m.y-i,enabled:{[f]:s,[d]:r}}}}}},je=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,i;const{placement:o,rects:s,platform:r,elements:l}=t,{apply:a=()=>{},...c}=ct(e,t),h=await It(t,c),d=Q(o),f=ht(o),u=nt(o)==="y",{width:p,height:m}=s.floating;let y,v;d==="top"||d==="bottom"?(y=d,v=f===(await(r.isRTL==null?void 0:r.isRTL(l.floating))?"start":"end")?"left":"right"):(v=d,y=f==="end"?"top":"bottom");const b=m-h.top-h.bottom,w=p-h.left-h.right,x=J(m-h[y],b),E=J(p-h[v],w),F=!t.middlewareData.shift;let O=x,V=E;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(V=w),(i=t.middlewareData.shift)!=null&&i.enabled.y&&(O=b),F&&!f){const $=S(h.left,0),K=S(h.right,0),q=S(h.top,0),Y=S(h.bottom,0);u?V=p-2*($!==0||K!==0?$+K:S(h.left,h.right)):O=m-2*(q!==0||Y!==0?q+Y:S(h.top,h.bottom))}await a({...t,availableWidth:V,availableHeight:O});const B=await r.getDimensions(l.floating);return p!==B.width||m!==B.height?{reset:{rects:!0}}:{}}}};function Tt(){return typeof window<"u"}function dt(e){return ae(e)?(e.nodeName||"").toLowerCase():"#document"}function k(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function W(e){var t;return(t=(ae(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function ae(e){return Tt()?e instanceof Node||e instanceof k(e).Node:!1}function _(e){return Tt()?e instanceof Element||e instanceof k(e).Element:!1}function I(e){return Tt()?e instanceof HTMLElement||e instanceof k(e).HTMLElement:!1}function Qt(e){return!Tt()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof k(e).ShadowRoot}function ft(e){const{overflow:t,overflowX:n,overflowY:i,display:o}=N(e);return/auto|scroll|overlay|hidden|clip/.test(t+i+n)&&!["inline","contents"].includes(o)}function Ke(e){return["table","td","th"].includes(dt(e))}function At(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Wt(e){const t=Vt(),n=_(e)?N(e):e;return["transform","translate","scale","rotate","perspective"].some(i=>n[i]?n[i]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(i=>(n.willChange||"").includes(i))||["paint","layout","strict","content"].some(i=>(n.contain||"").includes(i))}function Ye(e){let t=Z(e);for(;I(t)&&!lt(t);){if(Wt(t))return t;if(At(t))return null;t=Z(t)}return null}function Vt(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function lt(e){return["html","body","#document"].includes(dt(e))}function N(e){return k(e).getComputedStyle(e)}function Rt(e){return _(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Z(e){if(dt(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Qt(e)&&e.host||W(e);return Qt(t)?t.host:t}function ce(e){const t=Z(e);return lt(t)?e.ownerDocument?e.ownerDocument.body:e.body:I(t)&&ft(t)?t:ce(t)}function ut(e,t,n){var i;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=ce(e),s=o===((i=e.ownerDocument)==null?void 0:i.body),r=k(o);if(s){const l=$t(r);return t.concat(r,r.visualViewport||[],ft(o)?o:[],l&&n?ut(l):[])}return t.concat(o,ut(o,[],n))}function $t(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function he(e){const t=N(e);let n=parseFloat(t.width)||0,i=parseFloat(t.height)||0;const o=I(e),s=o?e.offsetWidth:n,r=o?e.offsetHeight:i,l=xt(n)!==s||xt(i)!==r;return l&&(n=s,i=r),{width:n,height:i,$:l}}function Ut(e){return _(e)?e:e.contextElement}function st(e){const t=Ut(e);if(!I(t))return M(1);const n=t.getBoundingClientRect(),{width:i,height:o,$:s}=he(t);let r=(s?xt(n.width):n.width)/i,l=(s?xt(n.height):n.height)/o;return(!r||!Number.isFinite(r))&&(r=1),(!l||!Number.isFinite(l))&&(l=1),{x:r,y:l}}const Ge=M(0);function de(e){const t=k(e);return!Vt()||!t.visualViewport?Ge:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Xe(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==k(e)?!1:t}function it(e,t,n,i){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=Ut(e);let r=M(1);t&&(i?_(i)&&(r=st(i)):r=st(e));const l=Xe(s,n,i)?de(s):M(0);let a=(o.left+l.x)/r.x,c=(o.top+l.y)/r.y,h=o.width/r.x,d=o.height/r.y;if(s){const f=k(s),u=i&&_(i)?k(i):i;let p=f,m=$t(p);for(;m&&i&&u!==p;){const y=st(m),v=m.getBoundingClientRect(),b=N(m),w=v.left+(m.clientLeft+parseFloat(b.paddingLeft))*y.x,x=v.top+(m.clientTop+parseFloat(b.paddingTop))*y.y;a*=y.x,c*=y.y,h*=y.x,d*=y.y,a+=w,c+=x,p=k(m),m=$t(p)}}return Pt({width:h,height:d,x:a,y:c})}function jt(e,t){const n=Rt(e).scrollLeft;return t?t.left+n:it(W(e)).left+n}function ue(e,t,n){n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=i.left+t.scrollLeft-(n?0:jt(e,i)),s=i.top+t.scrollTop;return{x:o,y:s}}function Je(e){let{elements:t,rect:n,offsetParent:i,strategy:o}=e;const s=o==="fixed",r=W(i),l=t?At(t.floating):!1;if(i===r||l&&s)return n;let a={scrollLeft:0,scrollTop:0},c=M(1);const h=M(0),d=I(i);if((d||!d&&!s)&&((dt(i)!=="body"||ft(r))&&(a=Rt(i)),I(i))){const u=it(i);c=st(i),h.x=u.x+i.clientLeft,h.y=u.y+i.clientTop}const f=r&&!d&&!s?ue(r,a,!0):M(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-a.scrollLeft*c.x+h.x+f.x,y:n.y*c.y-a.scrollTop*c.y+h.y+f.y}}function Qe(e){return Array.from(e.getClientRects())}function Ze(e){const t=W(e),n=Rt(e),i=e.ownerDocument.body,o=S(t.scrollWidth,t.clientWidth,i.scrollWidth,i.clientWidth),s=S(t.scrollHeight,t.clientHeight,i.scrollHeight,i.clientHeight);let r=-n.scrollLeft+jt(e);const l=-n.scrollTop;return N(i).direction==="rtl"&&(r+=S(t.clientWidth,i.clientWidth)-o),{width:o,height:s,x:r,y:l}}function tn(e,t){const n=k(e),i=W(e),o=n.visualViewport;let s=i.clientWidth,r=i.clientHeight,l=0,a=0;if(o){s=o.width,r=o.height;const c=Vt();(!c||c&&t==="fixed")&&(l=o.offsetLeft,a=o.offsetTop)}return{width:s,height:r,x:l,y:a}}function en(e,t){const n=it(e,!0,t==="fixed"),i=n.top+e.clientTop,o=n.left+e.clientLeft,s=I(e)?st(e):M(1),r=e.clientWidth*s.x,l=e.clientHeight*s.y,a=o*s.x,c=i*s.y;return{width:r,height:l,x:a,y:c}}function Zt(e,t,n){let i;if(t==="viewport")i=tn(e,n);else if(t==="document")i=Ze(W(e));else if(_(t))i=en(t,n);else{const o=de(e);i={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Pt(i)}function pe(e,t){const n=Z(e);return n===t||!_(n)||lt(n)?!1:N(n).position==="fixed"||pe(n,t)}function nn(e,t){const n=t.get(e);if(n)return n;let i=ut(e,[],!1).filter(l=>_(l)&&dt(l)!=="body"),o=null;const s=N(e).position==="fixed";let r=s?Z(e):e;for(;_(r)&&!lt(r);){const l=N(r),a=Wt(r);!a&&l.position==="fixed"&&(o=null),(s?!a&&!o:!a&&l.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||ft(r)&&!a&&pe(e,r))?i=i.filter(h=>h!==r):o=l,r=Z(r)}return t.set(e,i),i}function on(e){let{element:t,boundary:n,rootBoundary:i,strategy:o}=e;const r=[...n==="clippingAncestors"?At(t)?[]:nn(t,this._c):[].concat(n),i],l=r[0],a=r.reduce((c,h)=>{const d=Zt(t,h,o);return c.top=S(d.top,c.top),c.right=J(d.right,c.right),c.bottom=J(d.bottom,c.bottom),c.left=S(d.left,c.left),c},Zt(t,l,o));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function sn(e){const{width:t,height:n}=he(e);return{width:t,height:n}}function rn(e,t,n){const i=I(t),o=W(t),s=n==="fixed",r=it(e,!0,s,t);let l={scrollLeft:0,scrollTop:0};const a=M(0);if(i||!i&&!s)if((dt(t)!=="body"||ft(o))&&(l=Rt(t)),i){const f=it(t,!0,s,t);a.x=f.x+t.clientLeft,a.y=f.y+t.clientTop}else o&&(a.x=jt(o));const c=o&&!i&&!s?ue(o,l):M(0),h=r.left+l.scrollLeft-a.x-c.x,d=r.top+l.scrollTop-a.y-c.y;return{x:h,y:d,width:r.width,height:r.height}}function Dt(e){return N(e).position==="static"}function te(e,t){if(!I(e)||N(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return W(e)===n&&(n=n.ownerDocument.body),n}function fe(e,t){const n=k(e);if(At(e))return n;if(!I(e)){let o=Z(e);for(;o&&!lt(o);){if(_(o)&&!Dt(o))return o;o=Z(o)}return n}let i=te(e,t);for(;i&&Ke(i)&&Dt(i);)i=te(i,t);return i&<(i)&&Dt(i)&&!Wt(i)?n:i||Ye(e)||n}const ln=async function(e){const t=this.getOffsetParent||fe,n=this.getDimensions,i=await n(e.floating);return{reference:rn(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function an(e){return N(e).direction==="rtl"}const cn={convertOffsetParentRelativeRectToViewportRelativeRect:Je,getDocumentElement:W,getClippingRect:on,getOffsetParent:fe,getElementRects:ln,getClientRects:Qe,getDimensions:sn,getScale:st,isElement:_,isRTL:an};function ge(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function hn(e,t){let n=null,i;const o=W(e);function s(){var l;clearTimeout(i),(l=n)==null||l.disconnect(),n=null}function r(l,a){l===void 0&&(l=!1),a===void 0&&(a=1),s();const c=e.getBoundingClientRect(),{left:h,top:d,width:f,height:u}=c;if(l||t(),!f||!u)return;const p=vt(d),m=vt(o.clientWidth-(h+f)),y=vt(o.clientHeight-(d+u)),v=vt(h),w={rootMargin:-p+"px "+-m+"px "+-y+"px "+-v+"px",threshold:S(0,J(1,a))||1};let x=!0;function E(F){const O=F[0].intersectionRatio;if(O!==a){if(!x)return r();O?r(!1,O):i=setTimeout(()=>{r(!1,1e-7)},1e3)}O===1&&!ge(c,e.getBoundingClientRect())&&r(),x=!1}try{n=new IntersectionObserver(E,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(E,w)}n.observe(e)}return r(!0),s}function ee(e,t,n,i){i===void 0&&(i={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:r=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:a=!1}=i,c=Ut(e),h=o||s?[...c?ut(c):[],...ut(t)]:[];h.forEach(v=>{o&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const d=c&&l?hn(c,n):null;let f=-1,u=null;r&&(u=new ResizeObserver(v=>{let[b]=v;b&&b.target===c&&u&&(u.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var w;(w=u)==null||w.observe(t)})),n()}),c&&!a&&u.observe(c),u.observe(t));let p,m=a?it(e):null;a&&y();function y(){const v=it(e);m&&!ge(m,v)&&n(),m=v,p=requestAnimationFrame(y)}return n(),()=>{var v;h.forEach(b=>{o&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),d==null||d(),(v=u)==null||v.disconnect(),u=null,a&&cancelAnimationFrame(p)}}const dn=Ve,un=Ue,ne=Ie,pn=je,fn=Me,gn=(e,t,n)=>{const i=new Map,o={platform:cn,...n},s={...o.platform,_c:i};return He(e,t,{...o,platform:s})};function yt(e){if(e===void 0)return 0;const t=window.devicePixelRatio||1;return Math.round(e*t)/t}const bt=8,mn=100,vn=e=>({left:["right","bottom","top"],"left-start":["right-start","bottom","top"],"left-end":["right-end","bottom","top"],right:["left","bottom","top"],"right-start":["left-start","bottom","top"],"right-end":["left-end","bottom","top"],top:["bottom","left","right"],"top-start":["bottom-start","left","right"],"top-end":["bottom-end","left","right"],bottom:["top","left","right"],"bottom-start":["top-start","left","right"],"bottom-end":["top-end","left","right"]})[e]??[e];class yn{constructor(t){this.originalPlacements=new WeakMap,this.allowPlacementUpdate=!1,this.closeForAncestorUpdate=()=>{!this.allowPlacementUpdate&&this.options.type!=="modal"&&this.cleanup&&this.target.dispatchEvent(new Event("close",{bubbles:!0})),this.allowPlacementUpdate=!1},this.updatePlacement=()=>{this.computePlacement()},this.resetOverlayPosition=()=>{!this.target||!this.options||(this.clearOverlayPosition(),this.host.offsetHeight,this.computePlacement())},this.host=t,this.host.addController(this)}placeOverlay(t=this.target,n=this.options){if(this.target=t,this.options=n,!t||!n)return;const i=ee(n.trigger,t,this.closeForAncestorUpdate,{ancestorResize:!1,elementResize:!1,layoutShift:!1}),o=ee(n.trigger,t,this.updatePlacement,{ancestorScroll:!1});this.cleanup=()=>{var s;(s=this.host.elements)==null||s.forEach(r=>{r.addEventListener("luzmo-closed",()=>{const l=this.originalPlacements.get(r);l&&r.setAttribute("placement",l),this.originalPlacements.delete(r)},{once:!0})}),i(),o()}}async computePlacement(){var f,u;const{options:t,target:n}=this;await(document.fonts?document.fonts.ready:Promise.resolve());const i=t.trigger instanceof HTMLElement?ne():ne({padding:bt,fallbackPlacements:vn(t.placement)}),[o=0,s=0]=Array.isArray(t==null?void 0:t.offset)?t.offset:[t.offset,0],r=(f=this.host.elements.find(p=>p.tipElement))==null?void 0:f.tipElement,l=[dn({mainAxis:o,crossAxis:s}),un({padding:bt}),i,pn({padding:bt,apply:({availableWidth:p,availableHeight:m,rects:{floating:y}})=>{const v=Math.max(mn,Math.floor(m)),b=y.height;this.initialHeight=this.isConstrained&&this.initialHeight||b,this.isConstrained=b<this.initialHeight||v<=b;const w=this.isConstrained?`${v}px`:"";Object.assign(n.style,{maxWidth:`${Math.floor(p)}px`,maxHeight:w})}}),...r?[fn({element:r,padding:t.tipPadding||bt})]:[]],{x:a,y:c,placement:h,middlewareData:d}=await gn(t.trigger,n,{placement:t.placement,middleware:l,strategy:"fixed"});if(Object.assign(n.style,{top:"0px",left:"0px",translate:`${yt(a)}px ${yt(c)}px`}),n.setAttribute("actual-placement",h),(u=this.host.elements)==null||u.forEach(p=>{this.originalPlacements.has(p)||this.originalPlacements.set(p,p.getAttribute("placement")),p.setAttribute("placement",h)}),r&&d.arrow){const{x:p,y:m}=d.arrow;Object.assign(r.style,{top:h.startsWith("right")||h.startsWith("left")?"0px":"",left:h.startsWith("bottom")||h.startsWith("top")?"0px":"",translate:`${yt(p)}px ${yt(m)}px`})}}clearOverlayPosition(){this.target&&(this.target.style.removeProperty("max-height"),this.target.style.removeProperty("max-width"),this.initialHeight=void 0,this.isConstrained=!1)}hostConnected(){document.addEventListener("luzmo-update-overlays",this.resetOverlayPosition)}hostUpdated(){var t;this.host.open||((t=this.cleanup)==null||t.call(this),this.cleanup=void 0)}hostDisconnected(){var t;(t=this.cleanup)==null||t.call(this),this.cleanup=void 0,document.removeEventListener("luzmo-update-overlays",this.resetOverlayPosition)}}var gt=(e=>(e[e.click=0]="click",e[e.hover=1]="hover",e[e.longpress=2]="longpress",e))(gt||{});class Kt{constructor(t,{overlay:n,isPersistent:i,handleOverlayReady:o}){this.target=t,this.isLazilyOpen=!1,this.isPersistent=!1,this.isPersistent=!!i,this.handleOverlayReady=o,this.isPersistent&&this.init(),this.overlay=n}get activelyOpening(){return!1}get open(){var t;return((t=this.overlay)==null?void 0:t.open)??this.isLazilyOpen}set open(t){if(t!==this.open){if(this.isLazilyOpen=t,this.overlay){this.overlay.open=t;return}t&&(customElements.whenDefined("luzmo-overlay").then(async()=>{const{Overlay:n}=await Promise.resolve().then(()=>et);this.overlay=new n,this.overlay.open=!0}),Promise.resolve().then(()=>et))}}get overlay(){return this._overlay}set overlay(t){var n;t&&this.overlay!==t&&(this.overlay&&this.overlay.removeController(this),this._overlay=t,this.overlay.addController(this),this.initOverlay(),this.prepareDescription(this.target),(n=this.handleOverlayReady)==null||n.call(this,this.overlay))}prepareDescription(t){}releaseDescription(){}shouldCompleteOpen(){}init(){}initOverlay(){}abort(){var t;this.releaseDescription(),(t=this.abortController)==null||t.abort()}hostConnected(){this.init()}hostDisconnected(){this.isPersistent||this.abort()}}class bn extends Kt{constructor(){super(...arguments),this.type=gt.click,this.preventNextToggle=!1}handleClick(){this.preventNextToggle||(this.open=!this.open),this.preventNextToggle=!1}handlePointerdown(){this.preventNextToggle=this.open}init(){var n;(n=this.abortController)==null||n.abort(),this.abortController=new AbortController;const{signal:t}=this.abortController;this.target.addEventListener("click",()=>this.handleClick(),{signal:t}),this.target.addEventListener("pointerdown",()=>this.handlePointerdown(),{signal:t})}}const wn=300;class En extends Kt{constructor(){super(...arguments),this.type=gt.hover,this.elementIds=[],this.focusedin=!1,this.pointerentered=!1}handleTargetFocusin(){this.target.matches(":focus-visible")&&(this.open=!0,this.focusedin=!0)}handleTargetFocusout(){this.focusedin=!1,!this.pointerentered&&(this.open=!1)}handleTargetPointerenter(){var t;this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0),!((t=this.overlay)!=null&&t.disabled)&&(this.open=!0,this.pointerentered=!0)}handleTargetPointerleave(){this.doPointerleave()}handleHostPointerenter(){this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0)}handleHostPointerleave(){this.doPointerleave()}prepareDescription(){if(this.overlay.elements.length===0)return;const t=this.target.getRootNode(),n=this.overlay.elements[0].getRootNode(),i=this.overlay.getRootNode();t===i?this.prepareOverlayRelativeDescription():t===n&&this.prepareContentRelativeDescription()}prepareOverlayRelativeDescription(){const t=C.conditionAttributeWithId(this.target,"aria-describedby",[this.overlay.id]);this.releaseDescription=()=>{t(),this.releaseDescription=tt}}prepareContentRelativeDescription(){const t=[],n=this.overlay.elements.map(o=>(t.push(o.id),o.id||(o.id=`${this.overlay.tagName.toLowerCase()}-helper-${C.randomID()}`),o.id));this.elementIds=t;const i=C.conditionAttributeWithId(this.target,"aria-describedby",n);this.releaseDescription=()=>{i(),this.overlay.elements.map((o,s)=>{o.id=this.elementIds[s]}),this.releaseDescription=tt}}doPointerleave(){this.pointerentered=!1;const t=this.target;this.focusedin&&t.matches(":focus-visible")||(this.hoverTimeout=setTimeout(()=>{this.open=!1},wn))}init(){var n;(n=this.abortController)==null||n.abort(),this.abortController=new AbortController;const{signal:t}=this.abortController;this.target.addEventListener("focusin",()=>this.handleTargetFocusin(),{signal:t}),this.target.addEventListener("focusout",()=>this.handleTargetFocusout(),{signal:t}),this.target.addEventListener("pointerenter",()=>this.handleTargetPointerenter(),{signal:t}),this.target.addEventListener("pointerleave",()=>this.handleTargetPointerleave(),{signal:t}),this.overlay&&this.initOverlay()}initOverlay(){if(!this.abortController)return;const{signal:t}=this.abortController;this.overlay.addEventListener("pointerenter",()=>this.handleHostPointerenter(),{signal:t}),this.overlay.addEventListener("pointerleave",()=>this.handleHostPointerleave(),{signal:t})}}const xn=300,Cn={touch:"Double tap and long press for additional options",keyboard:"Press Space or Alt+Down Arrow for additional options",mouse:"Click and hold for additional options"};class Pn extends Kt{constructor(){super(...arguments),this.type=gt.longpress,this.longpressState=null,this.releaseDescription=tt,this.handlePointerup=()=>{var t;clearTimeout(this.timeout),this.target&&(this.longpressState=((t=this.overlay)==null?void 0:t.state)==="opening"?"pressed":null,document.removeEventListener("pointerup",this.handlePointerup),document.removeEventListener("pointercancel",this.handlePointerup))}}get activelyOpening(){return this.longpressState==="opening"||this.longpressState==="pressed"}handleLongpress(){this.open=!0,this.longpressState=this.longpressState==="potential"?"opening":"pressed"}handlePointerdown(t){!this.target||t.button!==0||(this.longpressState="potential",document.addEventListener("pointerup",this.handlePointerup),document.addEventListener("pointercancel",this.handlePointerup),"holdAffordance"in this.target)||(this.timeout=setTimeout(()=>{this.target&&this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"pointer"}}))},xn))}handleKeydown(t){const{code:n,altKey:i}=t;i&&n==="ArrowDown"&&(t.stopPropagation(),t.stopImmediatePropagation())}handleKeyup(t){const{code:n,altKey:i}=t;if(n==="Space"||i&&n==="ArrowDown"){if(!this.target)return;t.stopPropagation(),this.target.dispatchEvent(new CustomEvent("longpress",{bubbles:!0,composed:!0,detail:{source:"keyboard"}})),setTimeout(()=>{this.longpressState=null})}}prepareDescription(t){if(this.releaseDescription!==tt||this.overlay.elements.length===0)return;const n=document.createElement("div");n.id=`longpress-describedby-descriptor-${C.randomID()}`;const i=St.isIOS()||St.isAndroid()?"touch":"keyboard";n.textContent=Cn[i],n.slot="longpress-describedby-descriptor";const o=t.getRootNode(),s=this.overlay.getRootNode();o===s?this.overlay.append(n):(n.hidden=!("host"in o),t.after(n));const r=C.conditionAttributeWithId(t,"aria-describedby",[n.id]);this.releaseDescription=()=>{r(),n.remove(),this.releaseDescription=tt}}shouldCompleteOpen(){this.longpressState=this.longpressState==="pressed"?null:this.longpressState}init(){var n;(n=this.abortController)==null||n.abort(),this.abortController=new AbortController;const{signal:t}=this.abortController;this.target.addEventListener("longpress",()=>this.handleLongpress(),{signal:t}),this.target.addEventListener("pointerdown",i=>this.handlePointerdown(i),{signal:t}),this.prepareDescription(this.target),!this.target.holdAffordance&&(this.target.addEventListener("keydown",i=>this.handleKeydown(i),{signal:t}),this.target.addEventListener("keyup",i=>this.handleKeyup(i),{signal:t}))}}const me={click:bn,longpress:Pn,hover:En};var On=Object.defineProperty,Tn=Object.getOwnPropertyDescriptor,R=(e,t,n,i)=>{for(var o=i>1?void 0:i?Tn(t,n):t,s=e.length-1,r;s>=0;s--)(r=e[s])&&(o=(i?r(t,n,o):r(o))||o);return i&&o&&On(t,n,o),o};const An="showPopover"in document.createElement("div");let wt=Te(rt);wt=An?De(wt):Ae(wt);var j;const T=(j=class extends wt{constructor(){super(...arguments),this._delayed=!1,this._disabled=!1,this.offset=0,this._open=!1,this.lastRequestSlottableState=!1,this.receivesFocus="auto",this._state="closed",this.triggerElement=null,this.type="auto",this.wasOpen=!1,this.closeOnFocusOut=t=>{if(!t.relatedTarget)return;const n=new Event("overlay-relation-query",{bubbles:!0,composed:!0});t.relatedTarget.addEventListener(n.type,i=>{i.composedPath().includes(this)||(this.open=!1)}),t.relatedTarget.dispatchEvent(n)}}get delayed(){var t;return((t=this.elements.at(-1))==null?void 0:t.hasAttribute("delayed"))||this._delayed}set delayed(t){this._delayed=t}get disabled(){return this._disabled}set disabled(t){var n;this._disabled=t,t?((n=this.strategy)==null||n.abort(),this.wasOpen=this.open,this.open=!1):(this.bindEvents(),this.open=this.open||this.wasOpen,this.wasOpen=!1)}get hasNonVirtualTrigger(){return!!this.triggerElement&&!(this.triggerElement instanceof at)}get placementController(){return this._placementController||(this._placementController=new yn(this)),this._placementController}get open(){return this._open}set open(t){var n;t&&this.disabled||t!==this.open&&((n=this.strategy)!=null&&n.activelyOpening&&!t||(this._open=t,this.open&&(j.openCount+=1),this.requestUpdate("open",!this.open),this.open&&this.requestSlottable()))}get state(){return this._state}set state(t){var i;if(t===this.state)return;const n=this.state;this._state=t,(this.state==="opened"||this.state==="closed")&&((i=this.strategy)==null||i.shouldCompleteOpen()),this.requestUpdate("state",n)}get elementResolver(){return this._elementResolver||(this._elementResolver=new C.ElementResolutionController(this)),this._elementResolver}get usesDialog(){return this.type==="modal"||this.type==="page"}get popoverValue(){if("popover"in this)switch(this.type){case"modal":case"page":return;case"hint":return"manual";default:return this.type}}get requiresPositioning(){return!(this.type==="page"||!this.open||!this.triggerElement||!this.placement&&this.type!=="hint")}managePosition(){if(!this.requiresPositioning||!this.open)return;const t=this.offset||0,n=this.triggerElement,i=this.placement||"right",o=this.tipPadding;this.placementController.placeOverlay(this.dialogEl,{offset:t,placement:i,tipPadding:o,trigger:n,type:this.type})}async managePopoverOpen(){super.managePopoverOpen();const t=this.open;if(this.open!==t||(await this.manageDelay(t),this.open!==t)||(await this.ensureOnDOM(t),this.open!==t))return;const n=await this.makeTransition(t);this.open===t&&await this.applyFocus(t,n)}async applyFocus(t,n){if(!(this.receivesFocus==="false"||this.type==="hint")){if(await L(),await L(),t===this.open&&!this.open){this.hasNonVirtualTrigger&&this.contains(this.getRootNode().activeElement)&&this.triggerElement.focus();return}n==null||n.focus()}}returnFocus(){var n;if(this.open||this.type==="hint")return;const t=()=>{var s,r;const i=[];let o=document.activeElement;for(;(s=o==null?void 0:o.shadowRoot)!=null&&s.activeElement;)o=o.shadowRoot.activeElement;for(;o;){const l=o.assignedSlot||o.parentElement||((r=o.getRootNode())==null?void 0:r.host);l&&i.push(l),o=l}return i};this.receivesFocus!=="false"&&((n=this.triggerElement)!=null&&n.focus)&&(this.contains(this.getRootNode().activeElement)||t().includes(this)||document.activeElement===document.body)&&this.triggerElement.focus()}async manageOpen(t){if(!(!this.isConnected&&this.open)&&(this.hasUpdated||await this.updateComplete,this.open?(Xt.add(this),this.willPreventClose&&(document.addEventListener("pointerup",()=>{this.dialogEl.classList.toggle("not-immediately-closable",!1),this.willPreventClose=!1},{once:!0}),this.dialogEl.classList.toggle("not-immediately-closable",!0))):(t&&this.dispose(),Xt.remove(this)),this.open&&this.state!=="opened"?this.state="opening":!this.open&&this.state!=="closed"&&(this.state="closing"),this.usesDialog?this.manageDialogOpen():this.managePopoverOpen(),this.type==="auto")){const n=this.getRootNode();this.open?n.addEventListener("focusout",this.closeOnFocusOut,{capture:!0}):n.removeEventListener("focusout",this.closeOnFocusOut,{capture:!0})}}bindEvents(){var t;(t=this.strategy)==null||t.abort(),this.strategy=void 0,this.hasNonVirtualTrigger&&this.triggerInteraction&&(this.strategy=new me[this.triggerInteraction](this.triggerElement,{overlay:this}))}handleBeforetoggle(t){t.newState!=="open"&&this.handleBrowserClose(t)}handleBrowserClose(t){var n;if(t.stopPropagation(),!((n=this.strategy)!=null&&n.activelyOpening)){this.open=!1;return}this.manuallyKeepOpen()}manuallyKeepOpen(){this.open=!0,this.placementController.allowPlacementUpdate=!0,this.manageOpen(!1)}handleSlotchange(){var t,n;this.elements.length===0?(t=this.strategy)==null||t.releaseDescription():this.hasNonVirtualTrigger&&((n=this.strategy)==null||n.prepareDescription(this.triggerElement))}shouldPreventClose(){const t=this.willPreventClose;return this.willPreventClose=!1,t}requestSlottable(){this.lastRequestSlottableState!==this.open&&(this.open||document.body.offsetHeight,this.dispatchEvent(new oe("overlay-content",this.open?{}:Ot)),this.lastRequestSlottableState=this.open)}willUpdate(t){var i;if(this.hasAttribute("id")||this.setAttribute("id",`${this.tagName.toLowerCase()}-${C.randomID()}`),t.has("open")&&(this.hasUpdated||this.open)&&this.manageOpen(t.get("open")),t.has("trigger")){const[o,s]=((i=this.trigger)==null?void 0:i.split("@"))||[];this.elementResolver.selector=o?`#${o}`:"",this.triggerInteraction=s}let n=!1;t.has(C.elementResolverUpdatedSymbol)&&(n=this.triggerElement,this.triggerElement=this.elementResolver.element),t.has("triggerElement")&&(n=t.get("triggerElement")),n!==!1&&this.bindEvents()}updated(t){super.updated(t),t.has("placement")&&(this.placement?this.dialogEl.setAttribute("actual-placement",this.placement):this.dialogEl.removeAttribute("actual-placement"),this.open&&t.get("placement")!==void 0&&this.placementController.resetOverlayPosition()),t.has("state")&&this.state==="closed"&&t.get("state")!==void 0&&this.placementController.clearOverlayPosition()}renderContent(){return g.x` <slot @slotchange=${this.handleSlotchange}></slot> `}get dialogStyleMap(){return{"--luzmo-overlay-open-count":j.openCount.toString()}}renderDialog(){return g.x`
|
29
|
-
<dialog
|
30
|
-
class="dialog"
|
31
|
-
part="dialog"
|
32
|
-
placement=${g.o(this.requiresPositioning?this.placement||"right":void 0)}
|
33
|
-
style=${kt(this.dialogStyleMap)}
|
34
|
-
@close=${this.handleBrowserClose}
|
35
|
-
@cancel=${this.handleBrowserClose}
|
36
|
-
@beforetoggle=${this.handleBeforetoggle}
|
37
|
-
?is-visible=${this.state!=="closed"}
|
38
|
-
>
|
39
|
-
${this.renderContent()}
|
40
|
-
</dialog>
|
41
|
-
`}renderPopover(){return g.x`
|
42
|
-
<div
|
43
|
-
class="dialog"
|
44
|
-
part="dialog"
|
45
|
-
placement=${g.o(this.requiresPositioning?this.placement||"right":void 0)}
|
46
|
-
popover=${g.o(this.popoverValue)}
|
47
|
-
style=${kt(this.dialogStyleMap)}
|
48
|
-
@beforetoggle=${this.handleBeforetoggle}
|
49
|
-
@close=${this.handleBrowserClose}
|
50
|
-
?is-visible=${this.state!=="closed"}
|
51
|
-
>
|
52
|
-
${this.renderContent()}
|
53
|
-
</div>
|
54
|
-
`}render(){const t=this.type==="modal"||this.type==="page";return g.x`
|
55
|
-
${t?this.renderDialog():this.renderPopover()}
|
56
|
-
<slot name="longpress-describedby-descriptor"></slot>
|
57
|
-
`}connectedCallback(){super.connectedCallback(),this.addEventListener("close",()=>{this.open=!1}),this.hasUpdated&&this.bindEvents()}disconnectedCallback(){var t;(t=this.strategy)==null||t.releaseDescription(),this.open=!1,super.disconnectedCallback()}},j.styles=[g.r(Le)],j.openCount=1,j);R([g.n({type:Boolean})],T.prototype,"delayed",1);R([g.e(".dialog")],T.prototype,"dialogEl",2);R([g.n({type:Boolean})],T.prototype,"disabled",1);R([ie({flatten:!0,selector:':not([slot="longpress-describedby-descriptor"], slot)'})],T.prototype,"elements",2);R([g.n({type:Number})],T.prototype,"offset",2);R([g.n({type:Boolean,reflect:!0})],T.prototype,"open",1);R([g.n()],T.prototype,"placement",2);R([g.n({attribute:"receives-focus"})],T.prototype,"receivesFocus",2);R([g.e("slot")],T.prototype,"slotEl",2);R([C.r()],T.prototype,"state",1);R([g.n({type:Number,attribute:"tip-padding"})],T.prototype,"tipPadding",2);R([g.n()],T.prototype,"trigger",2);R([g.n({attribute:!1})],T.prototype,"triggerElement",2);R([g.n({attribute:!1})],T.prototype,"triggerInteraction",2);R([g.n()],T.prototype,"type",2);let mt=T;const et=Object.freeze(Object.defineProperty({__proto__:null,Overlay:mt},Symbol.toStringTag,{value:"Module"})),Rn=":host([disabled]) ::slotted([slot=trigger]){pointer-events:none}slot[name=longpress-describedby-descriptor]{display:none}";var Dn=Object.defineProperty,D=(e,t,n,i)=>{for(var o=void 0,s=e.length-1,r;s>=0;s--)(r=e[s])&&(o=r(t,n,o)||o);return o&&Dn(t,n,o),o};class P extends g.LuzmoElement{constructor(){super(...arguments),this.content="click hover longpress",this.offset=6,this.disabled=!1,this.receivesFocus="auto",this.clickContent=[],this.longpressContent=[],this.hoverContent=[],this.targetContent=[]}static get styles(){return[g.r(Rn)]}getAssignedElementsFromSlot(t){return t.assignedElements({flatten:!0})}handleTriggerContent(t){this.targetContent=this.getAssignedElementsFromSlot(t.target)}handleSlotContent(t){switch(t.target.name){case"click-content":{this.clickContent=this.getAssignedElementsFromSlot(t.target);break}case"longpress-content":{this.longpressContent=this.getAssignedElementsFromSlot(t.target);break}case"hover-content":{this.hoverContent=this.getAssignedElementsFromSlot(t.target);break}}}handleBeforetoggle(t){const{target:n}=t;let i;if(n===this.clickOverlayElement)i="click";else if(n===this.longpressOverlayElement)i="longpress";else if(n===this.hoverOverlayElement)i="hover";else return;t.newState==="open"?this.open=i:this.open===i&&(this.open=void 0)}update(t){var n,i,o,s,r,l;t.has("clickContent")&&(this.clickPlacement=((n=this.clickContent[0])==null?void 0:n.getAttribute("placement"))||((i=this.clickContent[0])==null?void 0:i.getAttribute("direction"))||void 0),t.has("hoverContent")&&(this.hoverPlacement=((o=this.hoverContent[0])==null?void 0:o.getAttribute("placement"))||((s=this.hoverContent[0])==null?void 0:s.getAttribute("direction"))||void 0),t.has("longpressContent")&&(this.longpressPlacement=((r=this.longpressContent[0])==null?void 0:r.getAttribute("placement"))||((l=this.longpressContent[0])==null?void 0:l.getAttribute("direction"))||void 0),super.update(t)}renderSlot(t){return g.x`
|
58
|
-
<slot name=${t} @slotchange=${this.handleSlotContent}></slot>
|
59
|
-
`}renderClickOverlay(){Promise.resolve().then(()=>et);const t=this.renderSlot("click-content");return this.clickContent.length===0?t:g.x`
|
60
|
-
<luzmo-overlay
|
61
|
-
id="click-overlay"
|
62
|
-
?disabled=${this.disabled||this.clickContent.length===0}
|
63
|
-
?open=${this.open==="click"&&this.clickContent.length>0}
|
64
|
-
.offset=${this.offset}
|
65
|
-
.placement=${this.clickPlacement||this.placement}
|
66
|
-
.triggerElement=${this.targetContent[0]}
|
67
|
-
.triggerInteraction=${"click"}
|
68
|
-
.type=${this.type==="modal"?"modal":"auto"}
|
69
|
-
@beforetoggle=${this.handleBeforetoggle}
|
70
|
-
.receivesFocus=${this.receivesFocus}
|
71
|
-
>
|
72
|
-
${t}
|
73
|
-
</luzmo-overlay>
|
74
|
-
`}renderHoverOverlay(){Promise.resolve().then(()=>et);const t=this.renderSlot("hover-content");return this.hoverContent.length===0?t:g.x`
|
75
|
-
<luzmo-overlay
|
76
|
-
id="hover-overlay"
|
77
|
-
?open=${this.open==="hover"&&this.hoverContent.length>0}
|
78
|
-
?disabled=${this.disabled||this.hoverContent.length===0||!!this.open&&this.open!=="hover"}
|
79
|
-
.offset=${this.offset}
|
80
|
-
.placement=${this.hoverPlacement||this.placement}
|
81
|
-
.triggerElement=${this.targetContent[0]}
|
82
|
-
.triggerInteraction=${"hover"}
|
83
|
-
.type=${"hint"}
|
84
|
-
@beforetoggle=${this.handleBeforetoggle}
|
85
|
-
.receivesFocus=${this.receivesFocus}
|
86
|
-
>
|
87
|
-
${t}
|
88
|
-
</luzmo-overlay>
|
89
|
-
`}renderLongpressOverlay(){Promise.resolve().then(()=>et);const t=this.renderSlot("longpress-content");return this.longpressContent.length===0?t:g.x`
|
90
|
-
<luzmo-overlay
|
91
|
-
id="longpress-overlay"
|
92
|
-
?disabled=${this.disabled||this.longpressContent.length===0}
|
93
|
-
?open=${this.open==="longpress"&&this.longpressContent.length>0}
|
94
|
-
.offset=${this.offset}
|
95
|
-
.placement=${this.longpressPlacement||this.placement}
|
96
|
-
.triggerElement=${this.targetContent[0]}
|
97
|
-
.triggerInteraction=${"longpress"}
|
98
|
-
.type=${"auto"}
|
99
|
-
@beforetoggle=${this.handleBeforetoggle}
|
100
|
-
.receivesFocus=${this.receivesFocus}
|
101
|
-
>
|
102
|
-
${t}
|
103
|
-
</luzmo-overlay>
|
104
|
-
<slot name="longpress-describedby-descriptor"></slot>
|
105
|
-
`}render(){const t=this.content.split(" ");return g.x`
|
106
|
-
<slot
|
107
|
-
id="trigger"
|
108
|
-
name="trigger"
|
109
|
-
@slotchange=${this.handleTriggerContent}
|
110
|
-
></slot>
|
111
|
-
${[t.includes("click")?this.renderClickOverlay():g.x``,t.includes("hover")?this.renderHoverOverlay():g.x``,t.includes("longpress")?this.renderLongpressOverlay():g.x``]}
|
112
|
-
`}updated(t){if(super.updated(t),this.disabled&&t.has("disabled")){this.open=void 0;return}}async getUpdateComplete(){return await super.getUpdateComplete()}}D([g.n()],P.prototype,"content");D([g.n({reflect:!0})],P.prototype,"placement");D([g.n()],P.prototype,"type");D([g.n({type:Number})],P.prototype,"offset");D([g.n({reflect:!0})],P.prototype,"open");D([g.n({type:Boolean,reflect:!0})],P.prototype,"disabled");D([g.n({attribute:"receives-focus"})],P.prototype,"receivesFocus");D([C.r()],P.prototype,"clickContent");D([C.r()],P.prototype,"longpressContent");D([C.r()],P.prototype,"hoverContent");D([C.r()],P.prototype,"targetContent");D([g.e("#click-overlay",!0)],P.prototype,"clickOverlayElement");D([g.e("#longpress-overlay",!0)],P.prototype,"longpressOverlayElement");D([g.e("#hover-overlay",!0)],P.prototype,"hoverOverlayElement");function ve(e,t,n,i){return mt.open(e,t,n,i)}class Sn extends St.f{render(t){return g.E}update(t,[n]){this.template=n,this.target!==t.element&&(this.target=t.element,this.renderBefore=this.target.children[0]),this.listenerHost=this.target,this.init()}handleSlottableRequest(t){if(t.target!==t.currentTarget)return;const n=t.data===Ot;g.B(n?void 0:this.template(),this.target,{renderBefore:this.renderBefore})}init(){var n;(n=this.listeners)==null||n.abort(),this.listeners=new AbortController;const{signal:t}=this.listeners;this.listenerHost.addEventListener("slottable-request",i=>this.handleSlottableRequest(i),{signal:t})}disconnected(){var t;(t=this.listeners)==null||t.abort()}reconnected(){this.init()}}class Yt extends Sn{constructor(){super(...arguments),this.defaultOptions={triggerInteraction:"click",overlayOptions:{type:"auto",offset:0}},this.options={...this.defaultOptions.overlayOptions}}render(t,n){return g.E}update(t,[n,i]){var l,a,c;this.options={...this.defaultOptions.overlayOptions,...i==null?void 0:i.overlayOptions},this.insertionOptions=i==null?void 0:i.insertionOptions,this.template=n,this.host=(l=t.options)==null?void 0:l.host;let o=!1;const s=(i==null?void 0:i.triggerInteraction)||this.defaultOptions.triggerInteraction,r=gt[(a=this.strategy)==null?void 0:a.type]!==s;this.target!==t.element&&(this.target=t.element,o=!0),(o||r)&&((c=this.strategy)==null||c.abort(),this.strategy=new me[s](this.target,{isPersistent:!0,handleOverlayReady:h=>{this.listenerHost=this.overlay=h,this.init()}})),this.strategy.open=(i==null?void 0:i.open)??!1}handleSlottableRequest(t){var o,s;if(t.target!==t.currentTarget)return;const n=t.data===Ot,i={};if(this.host&&(i.host=this.host),g.B(n?void 0:this.template(),this.overlay,i),n)this.overlay.remove();else{rt.applyOptions(this.overlay,{...this.options,trigger:this.target});const r=typeof((o=this.insertionOptions)==null?void 0:o.el)=="function"?this.insertionOptions.el():((s=this.insertionOptions)==null?void 0:s.el)||this.target,{where:l="afterend"}=this.insertionOptions||{};r.insertAdjacentElement(l,this.overlay)}}}const ye=C.e(Yt);customElements.get("luzmo-overlay")||customElements.define("luzmo-overlay",mt);customElements.get("luzmo-overlay-trigger")||customElements.define("luzmo-overlay-trigger",P);const kn=Object.freeze(Object.defineProperty({__proto__:null,Overlay:mt,OverlayTrigger:P,OverlayTriggerDirective:Yt,VirtualTrigger:at,openOverlay:ve,trigger:ye},Symbol.toStringTag,{value:"Module"}));exports.Overlay=mt;exports.OverlayTrigger=P;exports.OverlayTriggerDirective=Yt;exports.SlottableRequestEvent=oe;exports.VirtualTrigger=at;exports.index=kn;exports.o=kt;exports.o$1=ie;exports.openOverlay=ve;exports.overlay=et;exports.removeSlottableRequest=Ot;exports.trigger=ye;
|