@sprawlify/primitives 0.0.62 → 0.0.63
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/anatomy.d.cts +1 -1
- package/dist/anatomy.d.mts +1 -1
- package/dist/anatomy.mjs +1 -1
- package/dist/{aria-hidden-kcYiyWLo.cjs → aria-hidden-CHWfuKk2.cjs} +1 -1
- package/dist/{aria-hidden-CVIz-P9c.mjs → aria-hidden-Csp0PkO_.mjs} +1 -1
- package/dist/aria-hidden.cjs +2 -2
- package/dist/aria-hidden.mjs +2 -2
- package/dist/{auto-resize-C55IrFLZ.cjs → auto-resize-BL8ul-hb.cjs} +1 -1
- package/dist/{auto-resize-R0jCGBHZ.mjs → auto-resize-jPUJLPa4.mjs} +1 -1
- package/dist/auto-resize.cjs +2 -2
- package/dist/auto-resize.mjs +2 -2
- package/dist/{collection-CjwZd09Z.mjs → collection-DHyEg4g5.mjs} +30 -30
- package/dist/{collection-Q52RkxUe.cjs → collection-Fkg4kgPn.cjs} +30 -30
- package/dist/collection.cjs +2 -2
- package/dist/collection.d.cts +4 -4
- package/dist/collection.d.mts +4 -4
- package/dist/collection.mjs +2 -2
- package/dist/{color-utils-BekVyYIJ.mjs → color-utils-CaqLeEog.mjs} +3 -3
- package/dist/{color-utils-BVq_rh8L.cjs → color-utils-eUlz6Gq4.cjs} +3 -3
- package/dist/color-utils.cjs +2 -2
- package/dist/color-utils.d.cts +1 -1
- package/dist/color-utils.d.mts +1 -1
- package/dist/color-utils.mjs +2 -2
- package/dist/{core-CsVTCpQ_.cjs → core-CHsDFMV3.cjs} +7 -7
- package/dist/{core-CujC6Y2H.mjs → core-owywCQ2e.mjs} +7 -7
- package/dist/core.cjs +3 -3
- package/dist/core.d.cts +2 -2
- package/dist/core.d.mts +2 -2
- package/dist/core.mjs +3 -3
- package/dist/{date-utils-_Hu9b5fQ.cjs → date-utils-BDBOiT_6.cjs} +22 -23
- package/dist/{date-utils-d1Jt6z5f.mjs → date-utils-LnVS7q0z.mjs} +22 -23
- package/dist/date-utils.cjs +1 -1
- package/dist/date-utils.d.cts +6 -6
- package/dist/date-utils.d.mts +1 -1
- package/dist/date-utils.mjs +1 -1
- package/dist/{defineProperty-bTDhmYM0.mjs → defineProperty-DR_NxfHn.mjs} +8 -8
- package/dist/{defineProperty-xA1FicUs.cjs → defineProperty-_bOnJOii.cjs} +8 -8
- package/dist/{dismissable-D0YyXTJv.mjs → dismissable-BlZazbp3.mjs} +7 -7
- package/dist/{dismissable-D9NEAGMU.cjs → dismissable-DSFGuAU6.cjs} +7 -7
- package/dist/{dismissable-layer-C39y-V3t.d.mts → dismissable-layer-B2bSyA07.d.cts} +2 -2
- package/dist/{dismissable-layer-D-7fwQL8.d.cts → dismissable-layer-CpUMMV1f.d.mts} +2 -2
- package/dist/dismissable.cjs +4 -4
- package/dist/dismissable.d.cts +2 -2
- package/dist/dismissable.d.mts +2 -2
- package/dist/dismissable.mjs +4 -4
- package/dist/{dom-query-xZuxOsD4.cjs → dom-query-CAFhX43H.cjs} +25 -25
- package/dist/{dom-query-CUb85Z22.mjs → dom-query-CQFBCdpo.mjs} +25 -25
- package/dist/dom-query.cjs +1 -1
- package/dist/dom-query.d.cts +7 -7
- package/dist/dom-query.d.mts +7 -7
- package/dist/dom-query.mjs +1 -1
- package/dist/{file-utils-G9_tYexo.cjs → file-utils-Bkp18nrt.cjs} +6 -6
- package/dist/{file-utils-5E6-AtJ9.mjs → file-utils-lcjM-YjV.mjs} +6 -6
- package/dist/file-utils.cjs +1 -1
- package/dist/file-utils.d.cts +1 -1
- package/dist/file-utils.d.mts +1 -1
- package/dist/file-utils.mjs +1 -1
- package/dist/{focus-trap-KZbY4M-m.mjs → focus-trap-BXT0oBtL.mjs} +7 -7
- package/dist/{focus-trap-DcDcihd5.cjs → focus-trap-zaIiaoqE.cjs} +7 -7
- package/dist/focus-trap.cjs +2 -2
- package/dist/focus-trap.mjs +2 -2
- package/dist/{focus-visible-Ddho9PEA.cjs → focus-visible-3pXNNo-l.cjs} +1 -1
- package/dist/{focus-visible-Bm2uoacD.mjs → focus-visible-DjGDsaLn.mjs} +1 -1
- package/dist/focus-visible.cjs +2 -2
- package/dist/focus-visible.mjs +2 -2
- package/dist/highlight-word.cjs +3 -3
- package/dist/highlight-word.mjs +3 -3
- package/dist/hotkeys.cjs +8 -8
- package/dist/hotkeys.mjs +8 -8
- package/dist/{i18n-utils-B3KjZ58Q.cjs → i18n-utils-CK27xonZ.cjs} +1 -1
- package/dist/{i18n-utils-85PCPQ3H.mjs → i18n-utils-KuoJj66z.mjs} +1 -1
- package/dist/i18n-utils.cjs +2 -2
- package/dist/i18n-utils.mjs +2 -2
- package/dist/{index-BuUzJjaP.d.mts → index-CafmAesU.d.mts} +3 -3
- package/dist/{index-Bqw3r34-.d.cts → index-D1U_WMQ9.d.cts} +3 -3
- package/dist/{interact-outside-xKQjln5u.mjs → interact-outside-CRmkKF6k.mjs} +4 -4
- package/dist/{interact-outside-xGMuVVaa.cjs → interact-outside-Dk2otQqs.cjs} +4 -4
- package/dist/interact-outside.cjs +3 -3
- package/dist/interact-outside.d.cts +1 -1
- package/dist/interact-outside.d.mts +1 -1
- package/dist/interact-outside.mjs +3 -3
- package/dist/json-tree-utils.cjs +30 -30
- package/dist/json-tree-utils.mjs +30 -30
- package/dist/{list-collection-BvMwDNHf.d.cts → list-collection-C9XUe75n.d.mts} +1 -1
- package/dist/{list-collection-CTt1eong.d.mts → list-collection-DwMgPYoA.d.cts} +1 -1
- package/dist/live-region.d.cts +1 -1
- package/dist/live-region.d.mts +1 -1
- package/dist/live-region.mjs +1 -1
- package/dist/machines/accordion/index.cjs +34 -34
- package/dist/machines/accordion/index.d.cts +3 -3
- package/dist/machines/accordion/index.d.mts +3 -3
- package/dist/machines/accordion/index.mjs +36 -36
- package/dist/machines/angle-slider/index.cjs +13 -13
- package/dist/machines/angle-slider/index.d.cts +4 -4
- package/dist/machines/angle-slider/index.d.mts +4 -4
- package/dist/machines/angle-slider/index.mjs +15 -15
- package/dist/machines/async-list/index.cjs +3 -3
- package/dist/machines/async-list/index.d.cts +1 -1
- package/dist/machines/async-list/index.d.mts +1 -1
- package/dist/machines/async-list/index.mjs +3 -3
- package/dist/machines/avatar/index.cjs +3 -3
- package/dist/machines/avatar/index.d.cts +3 -3
- package/dist/machines/avatar/index.d.mts +3 -3
- package/dist/machines/avatar/index.mjs +5 -5
- package/dist/machines/bottom-sheet/index.cjs +15 -15
- package/dist/machines/bottom-sheet/index.d.cts +6 -6
- package/dist/machines/bottom-sheet/index.d.mts +6 -6
- package/dist/machines/bottom-sheet/index.mjs +17 -17
- package/dist/machines/carousel/index.cjs +38 -38
- package/dist/machines/carousel/index.d.cts +4 -4
- package/dist/machines/carousel/index.d.mts +4 -4
- package/dist/machines/carousel/index.mjs +40 -40
- package/dist/machines/checkbox/index.cjs +11 -11
- package/dist/machines/checkbox/index.d.cts +4 -4
- package/dist/machines/checkbox/index.d.mts +4 -4
- package/dist/machines/checkbox/index.mjs +13 -13
- package/dist/machines/clipboard/index.cjs +7 -7
- package/dist/machines/clipboard/index.d.cts +4 -4
- package/dist/machines/clipboard/index.d.mts +4 -4
- package/dist/machines/clipboard/index.mjs +9 -9
- package/dist/machines/collapsible/index.cjs +3 -3
- package/dist/machines/collapsible/index.d.cts +3 -3
- package/dist/machines/collapsible/index.d.mts +3 -3
- package/dist/machines/collapsible/index.mjs +5 -5
- package/dist/machines/color-picker/index.cjs +58 -58
- package/dist/machines/color-picker/index.d.cts +7 -7
- package/dist/machines/color-picker/index.d.mts +7 -7
- package/dist/machines/color-picker/index.mjs +60 -60
- package/dist/machines/combobox/index.cjs +108 -108
- package/dist/machines/combobox/index.d.cts +8 -8
- package/dist/machines/combobox/index.d.mts +8 -8
- package/dist/machines/combobox/index.mjs +110 -110
- package/dist/machines/date-picker/index.cjs +113 -113
- package/dist/machines/date-picker/index.d.cts +8 -8
- package/dist/machines/date-picker/index.d.mts +8 -8
- package/dist/machines/date-picker/index.mjs +120 -120
- package/dist/machines/dialog/index.cjs +12 -12
- package/dist/machines/dialog/index.d.cts +6 -6
- package/dist/machines/dialog/index.d.mts +6 -6
- package/dist/machines/dialog/index.mjs +14 -14
- package/dist/machines/editable/index.cjs +14 -14
- package/dist/machines/editable/index.d.cts +5 -5
- package/dist/machines/editable/index.d.mts +5 -5
- package/dist/machines/editable/index.mjs +16 -16
- package/dist/machines/file-upload/index.cjs +27 -27
- package/dist/machines/file-upload/index.d.cts +5 -5
- package/dist/machines/file-upload/index.d.mts +5 -5
- package/dist/machines/file-upload/index.mjs +29 -29
- package/dist/machines/floating-panel/index.cjs +25 -25
- package/dist/machines/floating-panel/index.d.cts +5 -5
- package/dist/machines/floating-panel/index.d.mts +5 -5
- package/dist/machines/floating-panel/index.mjs +27 -27
- package/dist/machines/hover-card/index.cjs +11 -11
- package/dist/machines/hover-card/index.d.cts +6 -6
- package/dist/machines/hover-card/index.d.mts +6 -6
- package/dist/machines/hover-card/index.mjs +13 -13
- package/dist/machines/image-cropper/index.cjs +39 -39
- package/dist/machines/image-cropper/index.d.cts +4 -4
- package/dist/machines/image-cropper/index.d.mts +4 -4
- package/dist/machines/image-cropper/index.mjs +41 -41
- package/dist/machines/listbox/index.cjs +94 -94
- package/dist/machines/listbox/index.d.cts +8 -8
- package/dist/machines/listbox/index.d.mts +8 -8
- package/dist/machines/listbox/index.mjs +96 -96
- package/dist/machines/marquee/index.cjs +11 -11
- package/dist/machines/marquee/index.d.cts +6 -6
- package/dist/machines/marquee/index.d.mts +6 -6
- package/dist/machines/marquee/index.mjs +13 -13
- package/dist/machines/menu/index.cjs +59 -59
- package/dist/machines/menu/index.d.cts +9 -9
- package/dist/machines/menu/index.d.mts +9 -9
- package/dist/machines/menu/index.mjs +61 -61
- package/dist/machines/navigation-menu/index.cjs +66 -66
- package/dist/machines/navigation-menu/index.d.cts +4 -4
- package/dist/machines/navigation-menu/index.d.mts +4 -4
- package/dist/machines/navigation-menu/index.mjs +68 -68
- package/dist/machines/number-input/index.cjs +10 -10
- package/dist/machines/number-input/index.d.cts +4 -4
- package/dist/machines/number-input/index.d.mts +4 -4
- package/dist/machines/number-input/index.mjs +12 -12
- package/dist/machines/pagination/index.cjs +12 -12
- package/dist/machines/pagination/index.d.cts +4 -4
- package/dist/machines/pagination/index.d.mts +4 -4
- package/dist/machines/pagination/index.mjs +14 -14
- package/dist/machines/password-input/index.cjs +6 -6
- package/dist/machines/password-input/index.d.cts +4 -4
- package/dist/machines/password-input/index.d.mts +4 -4
- package/dist/machines/password-input/index.mjs +8 -8
- package/dist/machines/pin-input/index.cjs +9 -9
- package/dist/machines/pin-input/index.d.cts +4 -4
- package/dist/machines/pin-input/index.d.mts +4 -4
- package/dist/machines/pin-input/index.mjs +11 -11
- package/dist/machines/popover/index.cjs +16 -16
- package/dist/machines/popover/index.d.cts +7 -7
- package/dist/machines/popover/index.d.mts +7 -7
- package/dist/machines/popover/index.mjs +18 -18
- package/dist/machines/presence/index.cjs +6 -6
- package/dist/machines/presence/index.d.cts +2 -2
- package/dist/machines/presence/index.d.mts +2 -2
- package/dist/machines/presence/index.mjs +7 -7
- package/dist/machines/progress/index.cjs +19 -19
- package/dist/machines/progress/index.d.cts +4 -4
- package/dist/machines/progress/index.d.mts +4 -4
- package/dist/machines/progress/index.mjs +21 -21
- package/dist/machines/qr-code/index.cjs +7 -7
- package/dist/machines/qr-code/index.d.cts +4 -4
- package/dist/machines/qr-code/index.d.mts +4 -4
- package/dist/machines/qr-code/index.mjs +9 -9
- package/dist/machines/radio-group/index.cjs +39 -39
- package/dist/machines/radio-group/index.d.cts +4 -4
- package/dist/machines/radio-group/index.d.mts +4 -4
- package/dist/machines/radio-group/index.mjs +41 -41
- package/dist/machines/rating-group/index.cjs +16 -16
- package/dist/machines/rating-group/index.d.cts +4 -4
- package/dist/machines/rating-group/index.d.mts +4 -4
- package/dist/machines/rating-group/index.mjs +18 -18
- package/dist/machines/scroll-area/index.cjs +13 -13
- package/dist/machines/scroll-area/index.d.cts +4 -4
- package/dist/machines/scroll-area/index.d.mts +4 -4
- package/dist/machines/scroll-area/index.mjs +15 -15
- package/dist/machines/select/index.cjs +50 -50
- package/dist/machines/select/index.d.cts +9 -9
- package/dist/machines/select/index.d.mts +9 -9
- package/dist/machines/select/index.mjs +52 -52
- package/dist/machines/signature-pad/index.cjs +11 -11
- package/dist/machines/signature-pad/index.d.cts +4 -4
- package/dist/machines/signature-pad/index.d.mts +4 -4
- package/dist/machines/signature-pad/index.mjs +13 -13
- package/dist/machines/slider/index.cjs +42 -43
- package/dist/machines/slider/index.d.cts +4 -4
- package/dist/machines/slider/index.d.mts +4 -4
- package/dist/machines/slider/index.mjs +44 -45
- package/dist/machines/splitter/index.cjs +62 -62
- package/dist/machines/splitter/index.d.cts +3 -3
- package/dist/machines/splitter/index.d.mts +3 -3
- package/dist/machines/splitter/index.mjs +64 -64
- package/dist/machines/steps/index.cjs +27 -27
- package/dist/machines/steps/index.d.cts +4 -4
- package/dist/machines/steps/index.d.mts +4 -4
- package/dist/machines/steps/index.mjs +29 -29
- package/dist/machines/switch/index.cjs +10 -10
- package/dist/machines/switch/index.d.cts +4 -4
- package/dist/machines/switch/index.d.mts +4 -4
- package/dist/machines/switch/index.mjs +12 -12
- package/dist/machines/tabs/index.cjs +14 -14
- package/dist/machines/tabs/index.d.cts +4 -4
- package/dist/machines/tabs/index.d.mts +4 -4
- package/dist/machines/tabs/index.mjs +16 -16
- package/dist/machines/tags-input/index.cjs +30 -30
- package/dist/machines/tags-input/index.d.cts +6 -6
- package/dist/machines/tags-input/index.d.mts +6 -6
- package/dist/machines/tags-input/index.mjs +33 -33
- package/dist/machines/timer/index.cjs +19 -19
- package/dist/machines/timer/index.d.cts +4 -4
- package/dist/machines/timer/index.d.mts +4 -4
- package/dist/machines/timer/index.mjs +21 -21
- package/dist/machines/toast/index.cjs +11 -11
- package/dist/machines/toast/index.d.cts +5 -6
- package/dist/machines/toast/index.d.mts +5 -6
- package/dist/machines/toast/index.mjs +12 -12
- package/dist/machines/toggle/index.cjs +5 -5
- package/dist/machines/toggle/index.d.cts +3 -3
- package/dist/machines/toggle/index.d.mts +3 -3
- package/dist/machines/toggle/index.mjs +7 -7
- package/dist/machines/toggle-group/index.cjs +16 -16
- package/dist/machines/toggle-group/index.d.cts +3 -3
- package/dist/machines/toggle-group/index.d.mts +3 -3
- package/dist/machines/toggle-group/index.mjs +18 -18
- package/dist/machines/tooltip/index.cjs +12 -12
- package/dist/machines/tooltip/index.d.cts +5 -5
- package/dist/machines/tooltip/index.d.mts +5 -5
- package/dist/machines/tooltip/index.mjs +14 -14
- package/dist/machines/tour/index.cjs +19 -19
- package/dist/machines/tour/index.d.cts +7 -7
- package/dist/machines/tour/index.d.mts +7 -7
- package/dist/machines/tour/index.mjs +21 -21
- package/dist/machines/tree-view/index.cjs +161 -161
- package/dist/machines/tree-view/index.d.cts +7 -7
- package/dist/machines/tree-view/index.d.mts +7 -7
- package/dist/machines/tree-view/index.mjs +163 -163
- package/dist/{popper-TNUpC0Kp.cjs → popper-CY3ptPbm.cjs} +4 -4
- package/dist/{popper-DbfXVgrC.mjs → popper-DxgokNha.mjs} +4 -4
- package/dist/popper.cjs +3 -3
- package/dist/popper.d.cts +1 -1
- package/dist/popper.d.mts +1 -1
- package/dist/popper.mjs +3 -3
- package/dist/{rect-utils-CDBAit19.mjs → rect-utils-BobE6Wut.mjs} +9 -9
- package/dist/{rect-utils-ChBPj9XR.cjs → rect-utils-DtqZwNtZ.cjs} +9 -9
- package/dist/rect-utils.cjs +1 -1
- package/dist/rect-utils.d.cts +1 -1
- package/dist/rect-utils.d.mts +1 -1
- package/dist/rect-utils.mjs +1 -1
- package/dist/{remove-scroll-DNoftRvo.mjs → remove-scroll-DcPV6nZy.mjs} +1 -1
- package/dist/{remove-scroll-D5aUrYvL.cjs → remove-scroll-DgJgF1C5.cjs} +1 -1
- package/dist/{scroll-snap-tDsdAemJ.mjs → scroll-snap-D_M1Q8ZQ.mjs} +1 -1
- package/dist/{scroll-snap-DhVLyRe-.cjs → scroll-snap-DpEzlrHP.cjs} +1 -1
- package/dist/scroll-snap.cjs +2 -2
- package/dist/scroll-snap.mjs +2 -2
- package/dist/{selection-JDFmyke7.d.mts → selection-CPTdpru8.d.mts} +2 -2
- package/dist/{selection-vng1guNc.d.cts → selection-wfybIxD3.d.cts} +2 -2
- package/dist/{store-DDjfrUhd.cjs → store-B9Ewi-zx.cjs} +4 -4
- package/dist/{store-CpMJ6RZR.mjs → store-DMXvGOAu.mjs} +4 -4
- package/dist/store.cjs +1 -1
- package/dist/store.mjs +1 -1
- package/dist/{tree-collection-CmehimuO.d.cts → tree-collection-1g4DXuqa.d.mts} +1 -2
- package/dist/{tree-collection-CqXQBHwY.d.mts → tree-collection-CPcsMvje.d.cts} +1 -2
- package/dist/{types-DL5AIQk5.d.mts → types-BM4oVvZZ.d.mts} +10 -10
- package/dist/{types-DejIu60O.d.cts → types-fB7F7BBP.d.cts} +10 -10
- package/dist/types.d.cts +1 -1
- package/dist/types.d.mts +1 -1
- package/dist/types.mjs +1 -1
- package/dist/{utils-B4_qn2dt.cjs → utils-CJsQZljH.cjs} +21 -21
- package/dist/{utils-DSBXwmDm.mjs → utils-Vs04rt8f.mjs} +21 -21
- package/dist/utils.cjs +1 -1
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.mts +1 -1
- package/dist/utils.mjs +1 -1
- package/package.json +1 -1
- /package/dist/{color-Bcy-SLQ1.d.mts → color-B3sgFAa6.d.mts} +0 -0
- /package/dist/{color-Bj20c2qw.d.cts → color-BhaNI8oR.d.cts} +0 -0
- /package/dist/{create-anatomy-DHVOqZET.d.mts → create-anatomy-9eFQs7lO.d.cts} +0 -0
- /package/dist/{create-anatomy-CArN8dVu.mjs → create-anatomy-BVqM_FJ6.mjs} +0 -0
- /package/dist/{create-anatomy-smWrirg1.d.cts → create-anatomy-UNZ__hxH.d.mts} +0 -0
- /package/dist/{create-props-SRSjdUTq.mjs → create-props-Dtoa4OUk.mjs} +0 -0
- /package/dist/{data-url-C3ITPVRX.d.cts → data-url-BrR6WHXH.d.cts} +0 -0
- /package/dist/{data-url-mcVoUiET.d.mts → data-url-lOYkmlVX.d.mts} +0 -0
- /package/dist/{functions-7V6veSov.d.cts → functions-Box4pxDB.d.cts} +0 -0
- /package/dist/{functions-CjitT5Gr.d.mts → functions-Du4c1Rcz.d.mts} +0 -0
- /package/dist/{index-CygfPLvT.d.mts → index-B2rsdD3v.d.cts} +0 -0
- /package/dist/{index-Bvn6ocEE.d.mts → index-CXu0elLS.d.mts} +0 -0
- /package/dist/{index-C9-feK5c.d.cts → index-Cf0hysnI.d.cts} +0 -0
- /package/dist/{index-Owca7uxB.d.cts → index-DIJJrhP_.d.mts} +0 -0
- /package/dist/{index-BTi1wETB.d.mts → index-DJ1MHM3z.d.mts} +0 -0
- /package/dist/{index-BqhWpjZh.d.mts → index-DLbWwJUT.d.mts} +0 -0
- /package/dist/{live-region-BcSdQIM8.mjs → live-region-CBp2K1JK.mjs} +0 -0
- /package/dist/{node-CHGS3acf.d.mts → node-BGWAyUGo.d.mts} +0 -0
- /package/dist/{node-CSsuPZVZ.d.cts → node-D8Ztr9Hg.d.cts} +0 -0
- /package/dist/{raf-BV1049GE.d.mts → raf-B8md2utS.d.mts} +0 -0
- /package/dist/{raf-Cd2FGy0z.d.cts → raf-DWPAf0Nd.d.cts} +0 -0
- /package/dist/{typeahead-BdNwVP09.d.cts → typeahead-BhNtyjQC.d.cts} +0 -0
- /package/dist/{typeahead-DMSwLv1e.d.mts → typeahead-D4TUCBly.d.mts} +0 -0
- /package/dist/{types-D5ziaMrd.d.cts → types-B--gFZVP.d.cts} +0 -0
- /package/dist/{types-DddL75YY.d.cts → types-C1F7Y-Hc.d.cts} +0 -0
- /package/dist/{types-CADkcKtr.d.cts → types-CBWaEVU4.d.cts} +0 -0
- /package/dist/{types-D-ZRl1jP.d.mts → types-CW-uU8Nz.d.mts} +0 -0
- /package/dist/{types-Df8ZhdY-.d.mts → types-D0tsc4Jo.d.mts} +0 -0
- /package/dist/{types-GxLIgJib.d.cts → types-DTZZ5wsp.d.cts} +0 -0
- /package/dist/{types-J14X3oxU.d.mts → types-Dw1I6cFP.d.mts} +0 -0
- /package/dist/{types-F-0xFywm.d.cts → types-oR0sELNB.d.cts} +0 -0
- /package/dist/{wait-for-ChpX25fU.d.cts → wait-for-CVZu6XNU.d.mts} +0 -0
- /package/dist/{wait-for-DxY1szJ6.d.mts → wait-for-D5gBQyam.d.cts} +0 -0
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { n as AnatomyInstance } from "../../create-anatomy-
|
|
2
|
-
import { r as CollectionOptions, t as CollectionItem } from "../../types-
|
|
3
|
-
import { t as ListCollection } from "../../list-collection-
|
|
4
|
-
import { i as GridCollectionOptions, n as SelectionMode, r as GridCollection, t as Selection } from "../../selection-
|
|
5
|
-
import { p as Machine, u as EventObject, y as Service } from "../../types-
|
|
6
|
-
import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-
|
|
7
|
-
import { n as TypeaheadState } from "../../typeahead-
|
|
1
|
+
import { n as AnatomyInstance } from "../../create-anatomy-9eFQs7lO.cjs";
|
|
2
|
+
import { r as CollectionOptions, t as CollectionItem } from "../../types-CBWaEVU4.cjs";
|
|
3
|
+
import { t as ListCollection } from "../../list-collection-DwMgPYoA.cjs";
|
|
4
|
+
import { i as GridCollectionOptions, n as SelectionMode, r as GridCollection, t as Selection } from "../../selection-wfybIxD3.cjs";
|
|
5
|
+
import { p as Machine, u as EventObject, y as Service } from "../../types-fB7F7BBP.cjs";
|
|
6
|
+
import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-D1U_WMQ9.cjs";
|
|
7
|
+
import { n as TypeaheadState } from "../../typeahead-BhNtyjQC.cjs";
|
|
8
8
|
|
|
9
9
|
//#region src/machines/listbox/listbox.anatomy.d.ts
|
|
10
|
-
declare const anatomy: AnatomyInstance<"root" | "
|
|
10
|
+
declare const anatomy: AnatomyInstance<"root" | "label" | "valueText" | "input" | "content" | "item" | "itemIndicator" | "itemText" | "itemGroup" | "itemGroupLabel">;
|
|
11
11
|
//#endregion
|
|
12
12
|
//#region src/machines/listbox/listbox.collection.d.ts
|
|
13
13
|
declare const collection: {
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { n as AnatomyInstance } from "../../create-anatomy-
|
|
2
|
-
import { r as CollectionOptions, t as CollectionItem } from "../../types-
|
|
3
|
-
import { t as ListCollection } from "../../list-collection-
|
|
4
|
-
import { i as GridCollectionOptions, n as SelectionMode, r as GridCollection, t as Selection } from "../../selection-
|
|
5
|
-
import { p as Machine, u as EventObject, y as Service } from "../../types-
|
|
6
|
-
import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-
|
|
7
|
-
import { n as TypeaheadState } from "../../typeahead-
|
|
1
|
+
import { n as AnatomyInstance } from "../../create-anatomy-UNZ__hxH.mjs";
|
|
2
|
+
import { r as CollectionOptions, t as CollectionItem } from "../../types-D0tsc4Jo.mjs";
|
|
3
|
+
import { t as ListCollection } from "../../list-collection-C9XUe75n.mjs";
|
|
4
|
+
import { i as GridCollectionOptions, n as SelectionMode, r as GridCollection, t as Selection } from "../../selection-CPTdpru8.mjs";
|
|
5
|
+
import { p as Machine, u as EventObject, y as Service } from "../../types-BM4oVvZZ.mjs";
|
|
6
|
+
import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-CafmAesU.mjs";
|
|
7
|
+
import { n as TypeaheadState } from "../../typeahead-D4TUCBly.mjs";
|
|
8
8
|
|
|
9
9
|
//#region src/machines/listbox/listbox.anatomy.d.ts
|
|
10
|
-
declare const anatomy: AnatomyInstance<"root" | "
|
|
10
|
+
declare const anatomy: AnatomyInstance<"root" | "label" | "valueText" | "input" | "content" | "item" | "itemIndicator" | "itemText" | "itemGroup" | "itemGroupLabel">;
|
|
11
11
|
//#endregion
|
|
12
12
|
//#region src/machines/listbox/listbox.collection.d.ts
|
|
13
13
|
declare const collection: {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { t as createAnatomy } from "../../create-anatomy-
|
|
2
|
-
import { I as scrollIntoView, W as raf, Zt as contains, _t as isCtrlOrMetaKey, cn as isEditableElement, ht as isComposingEvent, mt as getNativeEvent, pt as getEventTarget, s as getByTypeahead, ut as getEventKey, vn as ariaAttr, yn as dataAttr, z as observeAttributes } from "../../dom-query-
|
|
3
|
-
import { ft as isEqual, t as ensure, u as createSplitProps } from "../../utils-
|
|
4
|
-
import { a as GridCollection, i as Selection, o as isGridCollection, s as ListCollection } from "../../collection-
|
|
5
|
-
import { o as setup } from "../../core-
|
|
6
|
-
import { a as trackFocusVisible, t as getInteractionModality } from "../../focus-visible-
|
|
7
|
-
import { t as createProps } from "../../create-props-
|
|
1
|
+
import { t as createAnatomy } from "../../create-anatomy-BVqM_FJ6.mjs";
|
|
2
|
+
import { I as scrollIntoView, W as raf, Zt as contains, _t as isCtrlOrMetaKey, cn as isEditableElement, ht as isComposingEvent, mt as getNativeEvent, pt as getEventTarget, s as getByTypeahead, ut as getEventKey, vn as ariaAttr, yn as dataAttr, z as observeAttributes } from "../../dom-query-CQFBCdpo.mjs";
|
|
3
|
+
import { ft as isEqual, t as ensure, u as createSplitProps } from "../../utils-Vs04rt8f.mjs";
|
|
4
|
+
import { a as GridCollection, i as Selection, o as isGridCollection, s as ListCollection } from "../../collection-DHyEg4g5.mjs";
|
|
5
|
+
import { o as setup } from "../../core-owywCQ2e.mjs";
|
|
6
|
+
import { a as trackFocusVisible, t as getInteractionModality } from "../../focus-visible-DjGDsaLn.mjs";
|
|
7
|
+
import { t as createProps } from "../../create-props-Dtoa4OUk.mjs";
|
|
8
8
|
|
|
9
9
|
//#region src/machines/listbox/listbox.anatomy.ts
|
|
10
10
|
const anatomy = createAnatomy("listbox").parts("label", "input", "item", "itemText", "itemIndicator", "itemGroup", "itemGroupLabel", "content", "root", "valueText");
|
|
@@ -44,8 +44,8 @@ const getItemEl = (ctx, id) => ctx.getById(getItemId(ctx, id));
|
|
|
44
44
|
function connect(service, normalize) {
|
|
45
45
|
const { context, prop, scope, computed, send, refs } = service;
|
|
46
46
|
const disabled = prop("disabled");
|
|
47
|
-
const collection
|
|
48
|
-
const layout = isGridCollection(collection
|
|
47
|
+
const collection = prop("collection");
|
|
48
|
+
const layout = isGridCollection(collection) ? "grid" : "list";
|
|
49
49
|
const focused = context.get("focused");
|
|
50
50
|
const focusVisible = refs.get("focusVisible") && focused;
|
|
51
51
|
const inputState = refs.get("inputState");
|
|
@@ -56,18 +56,18 @@ function connect(service, normalize) {
|
|
|
56
56
|
const isTypingAhead = computed("isTypingAhead");
|
|
57
57
|
const interactive = computed("isInteractive");
|
|
58
58
|
const ariaActiveDescendant = highlightedValue ? getItemId(scope, highlightedValue) : void 0;
|
|
59
|
-
function getItemState(props
|
|
60
|
-
const itemDisabled = collection
|
|
61
|
-
const value
|
|
62
|
-
ensure(value
|
|
63
|
-
const highlighted = highlightedValue === value
|
|
59
|
+
function getItemState(props) {
|
|
60
|
+
const itemDisabled = collection.getItemDisabled(props.item);
|
|
61
|
+
const value = collection.getItemValue(props.item);
|
|
62
|
+
ensure(value, () => `[sprawlify-js] No value found for item ${JSON.stringify(props.item)}`);
|
|
63
|
+
const highlighted = highlightedValue === value;
|
|
64
64
|
return {
|
|
65
|
-
value
|
|
65
|
+
value,
|
|
66
66
|
disabled: Boolean(disabled || itemDisabled),
|
|
67
67
|
focused: highlighted && focused,
|
|
68
68
|
focusVisible: highlighted && focusVisible,
|
|
69
69
|
highlighted: highlighted && (inputState.focused ? focused : focusVisible),
|
|
70
|
-
selected: context.get("value").includes(value
|
|
70
|
+
selected: context.get("value").includes(value)
|
|
71
71
|
};
|
|
72
72
|
}
|
|
73
73
|
return {
|
|
@@ -84,37 +84,37 @@ function connect(service, normalize) {
|
|
|
84
84
|
hasSelectedItems: computed("hasSelectedItems"),
|
|
85
85
|
value,
|
|
86
86
|
valueAsString: computed("valueAsString"),
|
|
87
|
-
collection
|
|
87
|
+
collection,
|
|
88
88
|
disabled: !!disabled,
|
|
89
|
-
selectValue(value
|
|
89
|
+
selectValue(value) {
|
|
90
90
|
send({
|
|
91
91
|
type: "ITEM.SELECT",
|
|
92
|
-
value
|
|
92
|
+
value
|
|
93
93
|
});
|
|
94
94
|
},
|
|
95
|
-
setValue(value
|
|
95
|
+
setValue(value) {
|
|
96
96
|
send({
|
|
97
97
|
type: "VALUE.SET",
|
|
98
|
-
value
|
|
98
|
+
value
|
|
99
99
|
});
|
|
100
100
|
},
|
|
101
101
|
selectAll() {
|
|
102
102
|
if (!computed("multiple")) throw new Error("[sprawlify-js] Cannot select all items in a single-select listbox");
|
|
103
103
|
send({
|
|
104
104
|
type: "VALUE.SET",
|
|
105
|
-
value: collection
|
|
105
|
+
value: collection.getValues()
|
|
106
106
|
});
|
|
107
107
|
},
|
|
108
|
-
highlightValue(value
|
|
108
|
+
highlightValue(value) {
|
|
109
109
|
send({
|
|
110
110
|
type: "HIGHLIGHTED_VALUE.SET",
|
|
111
|
-
value
|
|
111
|
+
value
|
|
112
112
|
});
|
|
113
113
|
},
|
|
114
|
-
clearValue(value
|
|
115
|
-
if (value
|
|
114
|
+
clearValue(value) {
|
|
115
|
+
if (value) send({
|
|
116
116
|
type: "ITEM.CLEAR",
|
|
117
|
-
value
|
|
117
|
+
value
|
|
118
118
|
});
|
|
119
119
|
else send({ type: "VALUE.CLEAR" });
|
|
120
120
|
},
|
|
@@ -128,7 +128,7 @@ function connect(service, normalize) {
|
|
|
128
128
|
"data-disabled": dataAttr(disabled)
|
|
129
129
|
});
|
|
130
130
|
},
|
|
131
|
-
getInputProps(props
|
|
131
|
+
getInputProps(props = {}) {
|
|
132
132
|
return normalize.input({
|
|
133
133
|
...parts.input.attrs,
|
|
134
134
|
dir: prop("dir"),
|
|
@@ -146,7 +146,7 @@ function connect(service, normalize) {
|
|
|
146
146
|
queueMicrotask(() => {
|
|
147
147
|
send({
|
|
148
148
|
type: "INPUT.FOCUS",
|
|
149
|
-
autoHighlight: !!props
|
|
149
|
+
autoHighlight: !!props?.autoHighlight
|
|
150
150
|
});
|
|
151
151
|
});
|
|
152
152
|
},
|
|
@@ -157,7 +157,7 @@ function connect(service, normalize) {
|
|
|
157
157
|
});
|
|
158
158
|
},
|
|
159
159
|
onInput(event) {
|
|
160
|
-
if (!props
|
|
160
|
+
if (!props?.autoHighlight) return;
|
|
161
161
|
if (event.currentTarget.value.trim()) return;
|
|
162
162
|
queueMicrotask(() => {
|
|
163
163
|
send({
|
|
@@ -178,7 +178,7 @@ function connect(service, normalize) {
|
|
|
178
178
|
switch (nativeEvent.key) {
|
|
179
179
|
case "ArrowLeft":
|
|
180
180
|
case "ArrowRight":
|
|
181
|
-
if (!isGridCollection(collection
|
|
181
|
+
if (!isGridCollection(collection)) return;
|
|
182
182
|
if (event.ctrlKey) return;
|
|
183
183
|
forwardEvent();
|
|
184
184
|
case "Home":
|
|
@@ -218,8 +218,8 @@ function connect(service, normalize) {
|
|
|
218
218
|
"data-disabled": dataAttr(disabled)
|
|
219
219
|
});
|
|
220
220
|
},
|
|
221
|
-
getItemProps(props
|
|
222
|
-
const itemState = getItemState(props
|
|
221
|
+
getItemProps(props) {
|
|
222
|
+
const itemState = getItemState(props);
|
|
223
223
|
return normalize.element({
|
|
224
224
|
id: getItemId(scope, itemState.value),
|
|
225
225
|
role: "option",
|
|
@@ -235,7 +235,7 @@ function connect(service, normalize) {
|
|
|
235
235
|
"data-disabled": dataAttr(itemState.disabled),
|
|
236
236
|
"aria-disabled": ariaAttr(itemState.disabled),
|
|
237
237
|
onPointerMove(event) {
|
|
238
|
-
if (!props
|
|
238
|
+
if (!props.highlightOnHover) return;
|
|
239
239
|
if (itemState.disabled || event.pointerType !== "mouse") return;
|
|
240
240
|
if (itemState.highlighted) return;
|
|
241
241
|
send({
|
|
@@ -260,8 +260,8 @@ function connect(service, normalize) {
|
|
|
260
260
|
}
|
|
261
261
|
});
|
|
262
262
|
},
|
|
263
|
-
getItemTextProps(props
|
|
264
|
-
const itemState = getItemState(props
|
|
263
|
+
getItemTextProps(props) {
|
|
264
|
+
const itemState = getItemState(props);
|
|
265
265
|
return normalize.element({
|
|
266
266
|
...parts.itemText.attrs,
|
|
267
267
|
"data-state": itemState.selected ? "checked" : "unchecked",
|
|
@@ -269,8 +269,8 @@ function connect(service, normalize) {
|
|
|
269
269
|
"data-highlighted": dataAttr(itemState.highlighted)
|
|
270
270
|
});
|
|
271
271
|
},
|
|
272
|
-
getItemIndicatorProps(props
|
|
273
|
-
const itemState = getItemState(props
|
|
272
|
+
getItemIndicatorProps(props) {
|
|
273
|
+
const itemState = getItemState(props);
|
|
274
274
|
return normalize.element({
|
|
275
275
|
...parts.itemIndicator.attrs,
|
|
276
276
|
"aria-hidden": true,
|
|
@@ -278,8 +278,8 @@ function connect(service, normalize) {
|
|
|
278
278
|
hidden: !itemState.selected
|
|
279
279
|
});
|
|
280
280
|
},
|
|
281
|
-
getItemGroupLabelProps(props
|
|
282
|
-
const { htmlFor } = props
|
|
281
|
+
getItemGroupLabelProps(props) {
|
|
282
|
+
const { htmlFor } = props;
|
|
283
283
|
return normalize.element({
|
|
284
284
|
...parts.itemGroupLabel.attrs,
|
|
285
285
|
id: getItemGroupLabelId(scope, htmlFor),
|
|
@@ -287,13 +287,13 @@ function connect(service, normalize) {
|
|
|
287
287
|
role: "presentation"
|
|
288
288
|
});
|
|
289
289
|
},
|
|
290
|
-
getItemGroupProps(props
|
|
291
|
-
const { id } = props
|
|
290
|
+
getItemGroupProps(props) {
|
|
291
|
+
const { id } = props;
|
|
292
292
|
return normalize.element({
|
|
293
293
|
...parts.itemGroup.attrs,
|
|
294
294
|
"data-disabled": dataAttr(disabled),
|
|
295
295
|
"data-orientation": prop("orientation"),
|
|
296
|
-
"data-empty": dataAttr(collection
|
|
296
|
+
"data-empty": dataAttr(collection.size === 0),
|
|
297
297
|
id: getItemGroupId(scope, id),
|
|
298
298
|
"aria-labelledby": getItemGroupLabelId(scope, id),
|
|
299
299
|
role: "group",
|
|
@@ -313,8 +313,8 @@ function connect(service, normalize) {
|
|
|
313
313
|
"aria-labelledby": getLabelId(scope),
|
|
314
314
|
tabIndex: 0,
|
|
315
315
|
"data-layout": layout,
|
|
316
|
-
"data-empty": dataAttr(collection
|
|
317
|
-
style: { "--column-count": isGridCollection(collection
|
|
316
|
+
"data-empty": dataAttr(collection.size === 0),
|
|
317
|
+
style: { "--column-count": isGridCollection(collection) ? collection.columnCount : 1 },
|
|
318
318
|
onFocus() {
|
|
319
319
|
send({ type: "CONTENT.FOCUS" });
|
|
320
320
|
},
|
|
@@ -326,13 +326,13 @@ function connect(service, normalize) {
|
|
|
326
326
|
if (!contains(event.currentTarget, getEventTarget(event))) return;
|
|
327
327
|
const shiftKey = event.shiftKey;
|
|
328
328
|
const keyMap = {
|
|
329
|
-
ArrowUp(event
|
|
329
|
+
ArrowUp(event) {
|
|
330
330
|
let nextValue = null;
|
|
331
|
-
if (isGridCollection(collection
|
|
332
|
-
else if (highlightedValue) nextValue = collection
|
|
333
|
-
if (!nextValue && (prop("loopFocus") || !highlightedValue)) nextValue = collection
|
|
331
|
+
if (isGridCollection(collection) && highlightedValue) nextValue = collection.getPreviousRowValue(highlightedValue);
|
|
332
|
+
else if (highlightedValue) nextValue = collection.getPreviousValue(highlightedValue);
|
|
333
|
+
if (!nextValue && (prop("loopFocus") || !highlightedValue)) nextValue = collection.lastValue;
|
|
334
334
|
if (!nextValue) return;
|
|
335
|
-
event
|
|
335
|
+
event.preventDefault();
|
|
336
336
|
send({
|
|
337
337
|
type: "NAVIGATE",
|
|
338
338
|
value: nextValue,
|
|
@@ -340,13 +340,13 @@ function connect(service, normalize) {
|
|
|
340
340
|
anchorValue: highlightedValue
|
|
341
341
|
});
|
|
342
342
|
},
|
|
343
|
-
ArrowDown(event
|
|
343
|
+
ArrowDown(event) {
|
|
344
344
|
let nextValue = null;
|
|
345
|
-
if (isGridCollection(collection
|
|
346
|
-
else if (highlightedValue) nextValue = collection
|
|
347
|
-
if (!nextValue && (prop("loopFocus") || !highlightedValue)) nextValue = collection
|
|
345
|
+
if (isGridCollection(collection) && highlightedValue) nextValue = collection.getNextRowValue(highlightedValue);
|
|
346
|
+
else if (highlightedValue) nextValue = collection.getNextValue(highlightedValue);
|
|
347
|
+
if (!nextValue && (prop("loopFocus") || !highlightedValue)) nextValue = collection.firstValue;
|
|
348
348
|
if (!nextValue) return;
|
|
349
|
-
event
|
|
349
|
+
event.preventDefault();
|
|
350
350
|
send({
|
|
351
351
|
type: "NAVIGATE",
|
|
352
352
|
value: nextValue,
|
|
@@ -355,9 +355,9 @@ function connect(service, normalize) {
|
|
|
355
355
|
});
|
|
356
356
|
},
|
|
357
357
|
ArrowLeft() {
|
|
358
|
-
if (!isGridCollection(collection
|
|
359
|
-
let nextValue = highlightedValue ? collection
|
|
360
|
-
if (!nextValue && prop("loopFocus")) nextValue = collection
|
|
358
|
+
if (!isGridCollection(collection) && prop("orientation") === "vertical") return;
|
|
359
|
+
let nextValue = highlightedValue ? collection.getPreviousValue(highlightedValue) : null;
|
|
360
|
+
if (!nextValue && prop("loopFocus")) nextValue = collection.lastValue;
|
|
361
361
|
if (!nextValue) return;
|
|
362
362
|
event.preventDefault();
|
|
363
363
|
send({
|
|
@@ -368,9 +368,9 @@ function connect(service, normalize) {
|
|
|
368
368
|
});
|
|
369
369
|
},
|
|
370
370
|
ArrowRight() {
|
|
371
|
-
if (!isGridCollection(collection
|
|
372
|
-
let nextValue = highlightedValue ? collection
|
|
373
|
-
if (!nextValue && prop("loopFocus")) nextValue = collection
|
|
371
|
+
if (!isGridCollection(collection) && prop("orientation") === "vertical") return;
|
|
372
|
+
let nextValue = highlightedValue ? collection.getNextValue(highlightedValue) : null;
|
|
373
|
+
if (!nextValue && prop("loopFocus")) nextValue = collection.firstValue;
|
|
374
374
|
if (!nextValue) return;
|
|
375
375
|
event.preventDefault();
|
|
376
376
|
send({
|
|
@@ -380,9 +380,9 @@ function connect(service, normalize) {
|
|
|
380
380
|
anchorValue: highlightedValue
|
|
381
381
|
});
|
|
382
382
|
},
|
|
383
|
-
Home(event
|
|
384
|
-
event
|
|
385
|
-
let nextValue = collection
|
|
383
|
+
Home(event) {
|
|
384
|
+
event.preventDefault();
|
|
385
|
+
let nextValue = collection.firstValue;
|
|
386
386
|
send({
|
|
387
387
|
type: "NAVIGATE",
|
|
388
388
|
value: nextValue,
|
|
@@ -390,9 +390,9 @@ function connect(service, normalize) {
|
|
|
390
390
|
anchorValue: highlightedValue
|
|
391
391
|
});
|
|
392
392
|
},
|
|
393
|
-
End(event
|
|
394
|
-
event
|
|
395
|
-
let nextValue = collection
|
|
393
|
+
End(event) {
|
|
394
|
+
event.preventDefault();
|
|
395
|
+
let nextValue = collection.lastValue;
|
|
396
396
|
send({
|
|
397
397
|
type: "NAVIGATE",
|
|
398
398
|
value: nextValue,
|
|
@@ -406,26 +406,26 @@ function connect(service, normalize) {
|
|
|
406
406
|
value: highlightedValue
|
|
407
407
|
});
|
|
408
408
|
},
|
|
409
|
-
a(event
|
|
410
|
-
if (isCtrlOrMetaKey(event
|
|
411
|
-
event
|
|
409
|
+
a(event) {
|
|
410
|
+
if (isCtrlOrMetaKey(event) && computed("multiple") && !prop("disallowSelectAll")) {
|
|
411
|
+
event.preventDefault();
|
|
412
412
|
send({
|
|
413
413
|
type: "VALUE.SET",
|
|
414
|
-
value: collection
|
|
414
|
+
value: collection.getValues()
|
|
415
415
|
});
|
|
416
416
|
}
|
|
417
417
|
},
|
|
418
|
-
Space(event
|
|
418
|
+
Space(event) {
|
|
419
419
|
if (isTypingAhead && prop("typeahead")) send({
|
|
420
420
|
type: "CONTENT.TYPEAHEAD",
|
|
421
|
-
key: event
|
|
421
|
+
key: event.key
|
|
422
422
|
});
|
|
423
|
-
else keyMap.Enter?.(event
|
|
423
|
+
else keyMap.Enter?.(event);
|
|
424
424
|
},
|
|
425
|
-
Escape(event
|
|
425
|
+
Escape(event) {
|
|
426
426
|
if (prop("deselectable") && value.length > 0) {
|
|
427
|
-
event
|
|
428
|
-
event
|
|
427
|
+
event.preventDefault();
|
|
428
|
+
event.stopPropagation();
|
|
429
429
|
send({ type: "VALUE.CLEAR" });
|
|
430
430
|
}
|
|
431
431
|
}
|
|
@@ -454,7 +454,7 @@ function connect(service, normalize) {
|
|
|
454
454
|
const { guards, createMachine } = setup();
|
|
455
455
|
const { or } = guards;
|
|
456
456
|
const machine = createMachine({
|
|
457
|
-
props({ props
|
|
457
|
+
props({ props }) {
|
|
458
458
|
return {
|
|
459
459
|
loopFocus: false,
|
|
460
460
|
composite: true,
|
|
@@ -464,7 +464,7 @@ const machine = createMachine({
|
|
|
464
464
|
collection: collection.empty(),
|
|
465
465
|
orientation: "vertical",
|
|
466
466
|
selectionMode: "single",
|
|
467
|
-
...props
|
|
467
|
+
...props
|
|
468
468
|
};
|
|
469
469
|
},
|
|
470
470
|
context({ prop, bindable }) {
|
|
@@ -588,7 +588,7 @@ const machine = createMachine({
|
|
|
588
588
|
const highlightedValue = context.get("highlightedValue");
|
|
589
589
|
if (highlightedValue == null) return;
|
|
590
590
|
if (getInteractionModality() !== "keyboard") return;
|
|
591
|
-
const contentEl
|
|
591
|
+
const contentEl = getContentEl(scope);
|
|
592
592
|
const scrollToIndexFn = prop("scrollToIndexFn");
|
|
593
593
|
if (scrollToIndexFn) {
|
|
594
594
|
const highlightedIndex = prop("collection").indexOf(highlightedValue);
|
|
@@ -602,7 +602,7 @@ const machine = createMachine({
|
|
|
602
602
|
return;
|
|
603
603
|
}
|
|
604
604
|
scrollIntoView(getItemEl(scope, highlightedValue), {
|
|
605
|
-
rootEl: contentEl
|
|
605
|
+
rootEl: contentEl,
|
|
606
606
|
block: "nearest"
|
|
607
607
|
});
|
|
608
608
|
};
|
|
@@ -620,30 +620,30 @@ const machine = createMachine({
|
|
|
620
620
|
actions: {
|
|
621
621
|
selectHighlightedItem({ context, prop, event, computed }) {
|
|
622
622
|
const value = event.value ?? context.get("highlightedValue");
|
|
623
|
-
const collection
|
|
624
|
-
if (value == null || !collection
|
|
623
|
+
const collection = prop("collection");
|
|
624
|
+
if (value == null || !collection.has(value)) return;
|
|
625
625
|
const selection = computed("selection");
|
|
626
626
|
if (event.shiftKey && computed("multiple") && event.anchorValue) {
|
|
627
|
-
const next = selection.extendSelection(collection
|
|
627
|
+
const next = selection.extendSelection(collection, event.anchorValue, value);
|
|
628
628
|
invokeOnSelect(selection, next, prop("onSelect"));
|
|
629
629
|
context.set("value", Array.from(next));
|
|
630
630
|
} else {
|
|
631
|
-
const next = selection.select(collection
|
|
631
|
+
const next = selection.select(collection, value, event.metaKey);
|
|
632
632
|
invokeOnSelect(selection, next, prop("onSelect"));
|
|
633
633
|
context.set("value", Array.from(next));
|
|
634
634
|
}
|
|
635
635
|
},
|
|
636
636
|
selectWithKeyboard({ context, prop, event, computed }) {
|
|
637
637
|
const selection = computed("selection");
|
|
638
|
-
const collection
|
|
638
|
+
const collection = prop("collection");
|
|
639
639
|
if (event.shiftKey && computed("multiple") && event.anchorValue) {
|
|
640
|
-
const next = selection.extendSelection(collection
|
|
640
|
+
const next = selection.extendSelection(collection, event.anchorValue, event.value);
|
|
641
641
|
invokeOnSelect(selection, next, prop("onSelect"));
|
|
642
642
|
context.set("value", Array.from(next));
|
|
643
643
|
return;
|
|
644
644
|
}
|
|
645
645
|
if (prop("selectOnHighlight")) {
|
|
646
|
-
const next = selection.replaceSelection(collection
|
|
646
|
+
const next = selection.replaceSelection(collection, event.value);
|
|
647
647
|
invokeOnSelect(selection, next, prop("onSelect"));
|
|
648
648
|
context.set("value", Array.from(next));
|
|
649
649
|
}
|
|
@@ -666,9 +666,9 @@ const machine = createMachine({
|
|
|
666
666
|
context.set("highlightedValue", null);
|
|
667
667
|
},
|
|
668
668
|
selectItem({ context, prop, event, computed }) {
|
|
669
|
-
const collection
|
|
669
|
+
const collection = prop("collection");
|
|
670
670
|
const selection = computed("selection");
|
|
671
|
-
const next = selection.select(collection
|
|
671
|
+
const next = selection.select(collection, event.value);
|
|
672
672
|
invokeOnSelect(selection, next, prop("onSelect"));
|
|
673
673
|
context.set("value", Array.from(next));
|
|
674
674
|
},
|
|
@@ -683,21 +683,21 @@ const machine = createMachine({
|
|
|
683
683
|
context.set("value", []);
|
|
684
684
|
},
|
|
685
685
|
syncSelectedItems({ context, prop }) {
|
|
686
|
-
const collection
|
|
686
|
+
const collection = prop("collection");
|
|
687
687
|
const prevSelectedItems = context.get("selectedItems");
|
|
688
688
|
const selectedItems = context.get("value").map((value) => {
|
|
689
|
-
return prevSelectedItems.find((item) => collection
|
|
689
|
+
return prevSelectedItems.find((item) => collection.getItemValue(item) === value) || collection.find(value);
|
|
690
690
|
});
|
|
691
691
|
context.set("selectedItems", selectedItems);
|
|
692
692
|
},
|
|
693
693
|
syncHighlightedItem({ context, prop }) {
|
|
694
|
-
const collection
|
|
694
|
+
const collection = prop("collection");
|
|
695
695
|
const highlightedValue = context.get("highlightedValue");
|
|
696
|
-
const highlightedItem = highlightedValue ? collection
|
|
696
|
+
const highlightedItem = highlightedValue ? collection.find(highlightedValue) : null;
|
|
697
697
|
context.set("highlightedItem", highlightedItem);
|
|
698
698
|
},
|
|
699
699
|
syncHighlightedValue({ context, prop, refs }) {
|
|
700
|
-
const collection
|
|
700
|
+
const collection = prop("collection");
|
|
701
701
|
const highlightedValue = context.get("highlightedValue");
|
|
702
702
|
const { autoHighlight } = refs.get("inputState");
|
|
703
703
|
if (autoHighlight) {
|
|
@@ -706,7 +706,7 @@ const machine = createMachine({
|
|
|
706
706
|
});
|
|
707
707
|
return;
|
|
708
708
|
}
|
|
709
|
-
if (highlightedValue != null && !collection
|
|
709
|
+
if (highlightedValue != null && !collection.has(highlightedValue)) queueMicrotask(() => {
|
|
710
710
|
context.set("highlightedValue", null);
|
|
711
711
|
});
|
|
712
712
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
|
|
2
|
-
const require_dom_query = require('../../dom-query-
|
|
3
|
-
const require_utils = require('../../utils-
|
|
4
|
-
const require_core = require('../../core-
|
|
2
|
+
const require_dom_query = require('../../dom-query-CAFhX43H.cjs');
|
|
3
|
+
const require_utils = require('../../utils-CJsQZljH.cjs');
|
|
4
|
+
const require_core = require('../../core-CHsDFMV3.cjs');
|
|
5
5
|
const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
|
|
6
6
|
|
|
7
7
|
//#region src/machines/marquee/marquee.anatomy.ts
|
|
@@ -139,8 +139,8 @@ function connect(service, normalize) {
|
|
|
139
139
|
}
|
|
140
140
|
});
|
|
141
141
|
},
|
|
142
|
-
getContentProps(props
|
|
143
|
-
const { index } = props
|
|
142
|
+
getContentProps(props) {
|
|
143
|
+
const { index } = props;
|
|
144
144
|
const clone = index > 0;
|
|
145
145
|
return normalize.element({
|
|
146
146
|
...parts.content.attrs,
|
|
@@ -167,20 +167,20 @@ function connect(service, normalize) {
|
|
|
167
167
|
}
|
|
168
168
|
});
|
|
169
169
|
},
|
|
170
|
-
getEdgeProps(props
|
|
171
|
-
const { side
|
|
170
|
+
getEdgeProps(props) {
|
|
171
|
+
const { side } = props;
|
|
172
172
|
const dir = prop("dir");
|
|
173
173
|
return normalize.element({
|
|
174
174
|
...parts.edge.attrs,
|
|
175
175
|
dir,
|
|
176
176
|
"data-part": "edge",
|
|
177
|
-
"data-side": side
|
|
177
|
+
"data-side": side,
|
|
178
178
|
"data-orientation": orientation,
|
|
179
179
|
style: {
|
|
180
180
|
pointerEvents: "none",
|
|
181
181
|
position: "absolute",
|
|
182
182
|
...getEdgePositionStyles({
|
|
183
|
-
side
|
|
183
|
+
side,
|
|
184
184
|
dir
|
|
185
185
|
})
|
|
186
186
|
}
|
|
@@ -199,7 +199,7 @@ function connect(service, normalize) {
|
|
|
199
199
|
//#endregion
|
|
200
200
|
//#region src/machines/marquee/marquee.machine.ts
|
|
201
201
|
const machine = require_core.createMachine({
|
|
202
|
-
props({ props
|
|
202
|
+
props({ props }) {
|
|
203
203
|
return {
|
|
204
204
|
dir: "ltr",
|
|
205
205
|
side: "start",
|
|
@@ -212,7 +212,7 @@ const machine = require_core.createMachine({
|
|
|
212
212
|
reverse: false,
|
|
213
213
|
defaultPaused: false,
|
|
214
214
|
translations: { root: "Marquee content" },
|
|
215
|
-
...props
|
|
215
|
+
...props
|
|
216
216
|
};
|
|
217
217
|
},
|
|
218
218
|
refs() {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { n as AnatomyInstance } from "../../create-anatomy-
|
|
2
|
-
import { p as Machine, u as EventObject, y as Service } from "../../types-
|
|
3
|
-
import { b as NormalizeProps, d as Orientation, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-
|
|
1
|
+
import { n as AnatomyInstance } from "../../create-anatomy-9eFQs7lO.cjs";
|
|
2
|
+
import { p as Machine, u as EventObject, y as Service } from "../../types-fB7F7BBP.cjs";
|
|
3
|
+
import { b as NormalizeProps, d as Orientation, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-D1U_WMQ9.cjs";
|
|
4
4
|
|
|
5
5
|
//#region src/machines/marquee/marquee.anatomy.d.ts
|
|
6
|
-
declare const anatomy: AnatomyInstance<"root" | "
|
|
6
|
+
declare const anatomy: AnatomyInstance<"root" | "viewport" | "content" | "item" | "edge">;
|
|
7
7
|
//#endregion
|
|
8
8
|
//#region src/machines/marquee/marquee.types.d.ts
|
|
9
9
|
interface PauseStatusDetails {
|
|
@@ -96,7 +96,7 @@ declare function connect<T extends PropTypes>(service: MarqueeService, normalize
|
|
|
96
96
|
declare const machine: Machine<MarqueeSchema>;
|
|
97
97
|
//#endregion
|
|
98
98
|
//#region src/machines/marquee/marquee.props.d.ts
|
|
99
|
-
declare const props: ("ids" | "
|
|
100
|
-
declare const splitProps: <Props extends Partial<UserDefinedContext>>(props: Props) => [Partial<UserDefinedContext>, Omit<Props, "ids" | "
|
|
99
|
+
declare const props: ("ids" | "id" | "getRootNode" | "paused" | "onComplete" | ("dir" | "reverse" | "translations" | "side" | "speed" | "delay" | "loopCount" | "spacing" | "autoFill" | "pauseOnInteraction" | "defaultPaused") | "onPauseChange" | "onLoopComplete")[];
|
|
100
|
+
declare const splitProps: <Props extends Partial<UserDefinedContext>>(props: Props) => [Partial<UserDefinedContext>, Omit<Props, "ids" | "id" | "getRootNode" | "paused" | "onComplete" | ("dir" | "reverse" | "translations" | "side" | "speed" | "delay" | "loopCount" | "spacing" | "autoFill" | "pauseOnInteraction" | "defaultPaused") | "onPauseChange" | "onLoopComplete">];
|
|
101
101
|
//#endregion
|
|
102
102
|
export { type MarqueeApi as Api, type ContentProps, type DimensionSnapshot, type EdgeProps, type ElementIds, type IntlTranslations, type MarqueeMachine as Machine, type Orientation, type PauseStatusDetails, type MarqueeProps as Props, type MarqueeService as Service, type Side, type UserDefinedContext, anatomy, connect, machine, props, splitProps };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { n as AnatomyInstance } from "../../create-anatomy-
|
|
2
|
-
import { p as Machine, u as EventObject, y as Service } from "../../types-
|
|
3
|
-
import { b as NormalizeProps, d as Orientation, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-
|
|
1
|
+
import { n as AnatomyInstance } from "../../create-anatomy-UNZ__hxH.mjs";
|
|
2
|
+
import { p as Machine, u as EventObject, y as Service } from "../../types-BM4oVvZZ.mjs";
|
|
3
|
+
import { b as NormalizeProps, d as Orientation, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-CafmAesU.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/machines/marquee/marquee.anatomy.d.ts
|
|
6
|
-
declare const anatomy: AnatomyInstance<"root" | "
|
|
6
|
+
declare const anatomy: AnatomyInstance<"root" | "viewport" | "content" | "item" | "edge">;
|
|
7
7
|
//#endregion
|
|
8
8
|
//#region src/machines/marquee/marquee.types.d.ts
|
|
9
9
|
interface PauseStatusDetails {
|
|
@@ -96,7 +96,7 @@ declare function connect<T extends PropTypes>(service: MarqueeService, normalize
|
|
|
96
96
|
declare const machine: Machine<MarqueeSchema>;
|
|
97
97
|
//#endregion
|
|
98
98
|
//#region src/machines/marquee/marquee.props.d.ts
|
|
99
|
-
declare const props: ("ids" | "
|
|
100
|
-
declare const splitProps: <Props extends Partial<UserDefinedContext>>(props: Props) => [Partial<UserDefinedContext>, Omit<Props, "ids" | "
|
|
99
|
+
declare const props: ("ids" | "id" | "getRootNode" | "paused" | "onComplete" | ("dir" | "reverse" | "translations" | "side" | "speed" | "delay" | "loopCount" | "spacing" | "autoFill" | "pauseOnInteraction" | "defaultPaused") | "onPauseChange" | "onLoopComplete")[];
|
|
100
|
+
declare const splitProps: <Props extends Partial<UserDefinedContext>>(props: Props) => [Partial<UserDefinedContext>, Omit<Props, "ids" | "id" | "getRootNode" | "paused" | "onComplete" | ("dir" | "reverse" | "translations" | "side" | "speed" | "delay" | "loopCount" | "spacing" | "autoFill" | "pauseOnInteraction" | "defaultPaused") | "onPauseChange" | "onLoopComplete">];
|
|
101
101
|
//#endregion
|
|
102
102
|
export { type MarqueeApi as Api, type ContentProps, type DimensionSnapshot, type EdgeProps, type ElementIds, type IntlTranslations, type MarqueeMachine as Machine, type Orientation, type PauseStatusDetails, type MarqueeProps as Props, type MarqueeService as Service, type Side, type UserDefinedContext, anatomy, connect, machine, props, splitProps };
|