@astryx-vue/core 0.33.1 → 0.33.3
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/AlertDialog/index.js +1 -1
- package/dist/{AlertDialog-C9mhy7gH.js → AlertDialog-BwH9WU-t.js} +9 -9
- package/dist/AppShell/index.js +1 -1
- package/dist/{AppShell-B4S-gbL3.js → AppShell-BwzRYOky.js} +5 -5
- package/dist/Avatar/index.js +1 -1
- package/dist/{Avatar-B93MdEmI.js → Avatar-C6E6TYbe.js} +1 -1
- package/dist/AvatarGroup/index.d.ts +1 -1
- package/dist/AvatarGroup/index.js +1 -1
- package/dist/{AvatarGroup-CCFMtKks.js → AvatarGroup-C0V--ipx.js} +1 -1
- package/dist/Banner/index.d.ts +1 -1
- package/dist/Banner/index.js +1 -1
- package/dist/{Banner-DfsrHUDP.js → Banner-Ds5KIeES.js} +36 -16
- package/dist/BottomSheet/index.d.ts +1 -1
- package/dist/BottomSheet/index.js +2 -2
- package/dist/{BottomSheet-E_OjhAa7.js → BottomSheet-BmmGemH5.js} +1 -1
- package/dist/{BottomSheet-DxqAIVZ3.js → BottomSheet-DKEUVLe5.js} +9 -9
- package/dist/Breadcrumbs/index.js +2 -2
- package/dist/{Breadcrumbs-DMytkhxA.js → Breadcrumbs-DWAYp-JJ.js} +1 -1
- package/dist/Button/index.d.ts +1 -1
- package/dist/Button/index.js +1 -1
- package/dist/{Button-BoZJv7eb.js → Button-X-Q_ghg8.js} +4 -4
- package/dist/ButtonGroup/index.d.ts +1 -1
- package/dist/ButtonGroup/index.js +1 -1
- package/dist/{ButtonGroup-D5E7QLWI.js → ButtonGroup-DsYdUmF1.js} +2 -2
- package/dist/Calendar/index.d.ts +1 -1
- package/dist/Carousel/index.d.ts +1 -1
- package/dist/Carousel/index.js +1 -1
- package/dist/{Carousel-TvReEgJA.js → Carousel-D8uVV1J_.js} +1 -1
- package/dist/Chat/index.d.ts +1 -1
- package/dist/Chat/index.js +1 -1
- package/dist/{Chat-C_tNbXbn.js → Chat-Dy-icS2C.js} +6 -6
- package/dist/CheckboxInput/index.d.ts +1 -1
- package/dist/CheckboxInput/index.js +1 -1
- package/dist/{CheckboxInput-D6KNni6p.js → CheckboxInput-CiUtutIS.js} +4 -4
- package/dist/CheckboxList/index.d.ts +1 -1
- package/dist/CheckboxList/index.js +1 -1
- package/dist/{CheckboxListItem-wNOHsMMr.js → CheckboxListItem-B6sV7-Og.js} +5 -5
- package/dist/ClickableCard/index.d.ts +1 -1
- package/dist/ClickableCard/index.js +1 -1
- package/dist/{ClickableCard-CLXCxaxo.js → ClickableCard-DDk_RtHd.js} +1 -1
- package/dist/Code/index.js +1 -1
- package/dist/{CodeBlock-U2zFJsc5.js → CodeBlock-r2-MlpBB.js} +1 -1
- package/dist/Collapsible/index.js +1 -1
- package/dist/{Collapsible-Cf9evVsQ.js → Collapsible-0XI3tKgj.js} +3 -3
- package/dist/CommandPalette/index.js +1 -1
- package/dist/{CommandPalette-D5PGSXWz.js → CommandPalette-BYR0Lxxd.js} +3 -3
- package/dist/ComplexSelector/index.d.ts +1 -1
- package/dist/ComplexSelector/index.js +1 -1
- package/dist/{ComplexSelector-Co1jUTYQ.js → ComplexSelector-CIXrqCoX.js} +3 -3
- package/dist/ContextMenu/index.d.ts +1 -1
- package/dist/ContextMenu/index.js +2 -2
- package/dist/{ContextMenu-DBvZgAbg.js → ContextMenu-CfVyaP5v.js} +7 -7
- package/dist/DateInput/index.d.ts +1 -1
- package/dist/DateInput/index.js +1 -1
- package/dist/{DateInput-XLGBkH4g.js → DateInput-DRzZ8dY7.js} +5 -5
- package/dist/DateRangeInput/index.d.ts +1 -1
- package/dist/DateRangeInput/index.js +1 -1
- package/dist/{DateRangeInput-BNpkwtVh.js → DateRangeInput-DL2aOQXJ.js} +4 -4
- package/dist/DateTimeInput/index.d.ts +1 -1
- package/dist/DateTimeInput/index.js +1 -1
- package/dist/{DateTimeInput-CewV_JRI.js → DateTimeInput-KWkpamG4.js} +6 -6
- package/dist/Dialog/index.js +3 -3
- package/dist/{Dialog-BbDjvBqX.js → Dialog-BM5VEE8z.js} +2 -2
- package/dist/{Dialog-CYcDiMtZ.js → Dialog-CJzq1gms.js} +1 -1
- package/dist/{DialogHeader-efWB4QQA.js → DialogHeader-Do4EOX2f.js} +2 -2
- package/dist/Divider/index.d.ts +1 -1
- package/dist/Drawer/index.d.ts +1 -1
- package/dist/Drawer/index.js +1 -1
- package/dist/{Drawer-BswIXZSo.js → Drawer-DuQ620WO.js} +2 -2
- package/dist/DropdownMenu/index.js +2 -2
- package/dist/{DropdownMenu-CCOjKL7v.js → DropdownMenu-CbENfJOq.js} +10 -10
- package/dist/EmptyState/index.js +1 -1
- package/dist/{EmptyState-BkQ3jktt.js → EmptyState-BAP8BpDj.js} +2 -2
- package/dist/Field/index.js +3 -3
- package/dist/{Field-CYfzJEFg.js → Field-B1fsgAqp.js} +1 -1
- package/dist/{FieldInfoTip-DccDjDnf.js → FieldInfoTip-CntJCcnM.js} +1 -1
- package/dist/{FieldLabel-SiRzxGz8.js → FieldLabel-D56uJrRE.js} +1 -1
- package/dist/FileInput/index.js +1 -1
- package/dist/{FileInput-BxeGABmG.js → FileInput-EjlruVVX.js} +4 -4
- package/dist/Heading/index.js +1 -1
- package/dist/{Heading-D_7K6-23.js → Heading-D94VFJtm.js} +1 -1
- package/dist/HoverCard/index.d.ts +1 -1
- package/dist/HoverCard/index.js +1 -1
- package/dist/{HoverCard-Bkh1HZ3b.js → HoverCard-rwpyd6nt.js} +4 -4
- package/dist/IconButton/index.js +1 -1
- package/dist/{IconButton-DEhvVDmO.js → IconButton-CXg9qTRM.js} +1 -1
- package/dist/InfoTip/index.d.ts +1 -1
- package/dist/InfoTip/index.js +1 -1
- package/dist/{InfoTip-BZDG21HF.js → InfoTip-jFet-iAx.js} +2 -2
- package/dist/{InputClearButton-DezS64Mz.js → InputClearButton-DBTrsrSH.js} +1 -1
- package/dist/InputGroup/index.js +1 -1
- package/dist/{InputGroup-CENlnU_O.js → InputGroup-D7UBxktR.js} +1 -1
- package/dist/InternationalizationProvider/index.d.ts +1 -1
- package/dist/InternationalizationProvider/index.js +1 -1
- package/dist/{InternationalizationProvider-BAUKUK7N.js → InternationalizationProvider-BGtwZDY0.js} +1 -1
- package/dist/{Item-tVHjgQDe.js → Item-DbalBZXc.js} +2 -2
- package/dist/{LayerContentBoundary-D6GcF2T3.js → LayerContentBoundary-CTjEpdM4.js} +1 -1
- package/dist/Layout/index.js +2 -2
- package/dist/{Layout-DJ6CQLw2.js → Layout-BEJwZon4.js} +1 -1
- package/dist/{LayoutPanel-Bqh82ULc.js → LayoutPanel-BgJdL0KV.js} +1 -1
- package/dist/Lightbox/index.js +1 -1
- package/dist/{Lightbox-Dbwep-L-.js → Lightbox-DJXB22k0.js} +1 -1
- package/dist/Link/index.d.ts +1 -1
- package/dist/Link/index.js +1 -1
- package/dist/{Link-Csw2YXAQ.js → Link-eXwB0Hjg.js} +2 -2
- package/dist/List/index.d.ts +1 -1
- package/dist/List/index.js +2 -2
- package/dist/{ListItem-B60jTcXy.js → ListItem-C5B8uYyn.js} +4 -4
- package/dist/Markdown/index.d.ts +1 -1
- package/dist/Markdown/index.js +1 -1
- package/dist/{Markdown-CTRMjOpY.js → Markdown-COub2yng.js} +3 -3
- package/dist/MobileNav/index.js +1 -1
- package/dist/{MobileNavToggle-Ce8cVqzp.js → MobileNavToggle-DI5yDKfp.js} +2 -2
- package/dist/MoreMenu/index.d.ts +1 -1
- package/dist/MoreMenu/index.js +1 -1
- package/dist/{MoreMenu-CfUKxxnB.js → MoreMenu-C7gie2PE.js} +8 -8
- package/dist/MultiSelector/index.d.ts +1 -1
- package/dist/MultiSelector/index.js +1 -1
- package/dist/{MultiSelector-BG0oQjhR.js → MultiSelector-CnGUU8P3.js} +7 -7
- package/dist/{NavDisclosure-lQVs4eJB.js → NavDisclosure-CSnUZY3k.js} +1 -1
- package/dist/{NavHeadingSurface-CkDdgQV1.js → NavHeadingSurface-C3fTf5--.js} +1 -1
- package/dist/NavItem/index.js +1 -1
- package/dist/{NavItem-B7xpLk_x.js → NavItem-Cciu9aok.js} +1 -1
- package/dist/NavMenu/index.js +3 -3
- package/dist/{NavMenu-Bf_rGSbX.js → NavMenu--iyy_m84.js} +2 -2
- package/dist/{NavMenuItem-BblWAGof.js → NavMenuItem-BmAm-Cv8.js} +3 -3
- package/dist/NumberInput/index.d.ts +1 -1
- package/dist/NumberInput/index.js +1 -1
- package/dist/{NumberInput-CLQ1dgsb.js → NumberInput-CD9sHbON.js} +3 -3
- package/dist/Outline/index.js +1 -1
- package/dist/{Outline-coqRQ06s.js → Outline-vieAJS2J.js} +3 -3
- package/dist/OverflowList/index.d.ts +1 -1
- package/dist/OverflowList/index.js +1 -1
- package/dist/{OverflowList-V728L06i.js → OverflowList-YLVHypB3.js} +2 -2
- package/dist/Pagination/index.d.ts +1 -1
- package/dist/Pagination/index.js +1 -1
- package/dist/{Pagination-B71t50Xl.js → Pagination-Bnkp4oAA.js} +2 -2
- package/dist/PanGestureRecognizer-CzIWpazn.js +681 -0
- package/dist/Popover/index.js +1 -1
- package/dist/{Popover-BX8Qy08n.js → Popover-CYJ1z_7L.js} +10 -10
- package/dist/PowerSearch/index.d.ts +1 -1
- package/dist/PowerSearch/index.js +1 -1
- package/dist/{PowerSearch-ZfZNn-68.js → PowerSearch-DEpXEmgs.js} +27 -27
- package/dist/PressTracker-L5-Ark_9.js +190 -0
- package/dist/ProgressBar/index.d.ts +1 -1
- package/dist/ProgressBar/index.js +1 -1
- package/dist/ProgressBar-ChgsiVRR.js +325 -0
- package/dist/Radio/index.d.ts +1 -1
- package/dist/Radio/index.js +1 -1
- package/dist/{RadioGroup-8KAVhDTz.js → RadioGroup-BdO-xZv0.js} +5 -5
- package/dist/RadioList/index.d.ts +1 -1
- package/dist/RadioList/index.js +1 -1
- package/dist/{RadioListItem-FY0cSKWR.js → RadioListItem-DzGPuWTt.js} +1 -1
- package/dist/Resizable/index.d.ts +1 -1
- package/dist/Resizable/index.js +1 -1
- package/dist/{ResizeHandle-ezvpdXTS.js → ResizeHandle-Dcel1HkU.js} +2 -2
- package/dist/ScrollableArea/index.d.ts +1 -1
- package/dist/SegmentedControl/index.d.ts +1 -1
- package/dist/SegmentedControl/index.js +1 -1
- package/dist/{SegmentedControl-BdbqWErg.js → SegmentedControl-BURyE9XU.js} +2 -2
- package/dist/SelectableCard/index.d.ts +1 -1
- package/dist/SelectableCard/index.js +1 -1
- package/dist/{SelectableCard-Dj2fRvfe.js → SelectableCard-BZTF6qw-.js} +1 -1
- package/dist/Selector/index.d.ts +1 -1
- package/dist/Selector/index.js +1 -1
- package/dist/{Selector-DjZSKGCz.js → Selector-SkwSbf4j.js} +5 -5
- package/dist/SideNav/index.d.ts +1 -1
- package/dist/SideNav/index.js +2 -2
- package/dist/{SideNav-DjPwCh4O.js → SideNav-BxJfJU95.js} +9 -9
- package/dist/Skeleton/index.d.ts +1 -1
- package/dist/Slider/index.js +1 -1
- package/dist/Slider-ORmi7QJ7.js +1785 -0
- package/dist/Spinner/index.d.ts +1 -1
- package/dist/Spinner/index.js +1 -1
- package/dist/Spinner-D1adu3uH.js +266 -0
- package/dist/Stack/index.d.ts +1 -1
- package/dist/StatusDot/index.js +1 -1
- package/dist/{StatusDot-C4_Zj3oZ.js → StatusDot-D7nVuPg7.js} +1 -1
- package/dist/Stepper/index.d.ts +1 -1
- package/dist/Stepper/index.js +1 -1
- package/dist/{Stepper-C3ZFN-Gp.js → Stepper-C4-wtxn4.js} +149 -103
- package/dist/Switch/index.d.ts +1 -1
- package/dist/Switch/index.js +1 -1
- package/dist/Switch-Cw1UKVjQ.js +1468 -0
- package/dist/TabList/index.js +1 -1
- package/dist/{TabList-D70Pl_ob.js → TabList-DNDe2ipJ.js} +3 -3
- package/dist/Table/index.d.ts +1 -1
- package/dist/Table/index.js +1 -1
- package/dist/{Table-8Vj50mYm.js → Table-CqppyRk8.js} +14 -14
- package/dist/Text/index.js +1 -1
- package/dist/{Text-6_wt88Br.js → Text-kwsIut3C.js} +1 -1
- package/dist/TextArea/index.d.ts +1 -1
- package/dist/TextArea/index.js +1 -1
- package/dist/{TextArea-DMMHiOEb.js → TextArea-I3ghDb9r.js} +4 -4
- package/dist/TextInput/index.d.ts +1 -1
- package/dist/TextInput/index.js +1 -1
- package/dist/{TextInput-JuggLbDZ.js → TextInput-Xz_ibpOl.js} +4 -4
- package/dist/Thumbnail/index.js +1 -1
- package/dist/{Thumbnail-Sq-2e8zN.js → Thumbnail-bS62Tr_f.js} +4 -4
- package/dist/{TimeField-CuRkZZlx.js → TimeField-Bsb8n22d.js} +4 -4
- package/dist/TimeInput/index.d.ts +1 -1
- package/dist/TimeInput/index.js +1 -1
- package/dist/{TimeInput-CREpxTpG.js → TimeInput-D40_6GrX.js} +2 -2
- package/dist/Timer/index.d.ts +1 -1
- package/dist/Timer/index.js +1 -1
- package/dist/{Timer-C18tBgls.js → Timer-B-9sSJWK.js} +1 -1
- package/dist/Timestamp/index.d.ts +1 -1
- package/dist/Timestamp/index.js +1 -1
- package/dist/{Timestamp-BL8R7ZQ8.js → Timestamp-Bt9ZR975.js} +3 -3
- package/dist/Toast/index.js +1 -1
- package/dist/{Toast-BtJHuIen.js → Toast-BQxfIeVU.js} +5 -3
- package/dist/ToggleButton/index.d.ts +1 -1
- package/dist/ToggleButton/index.js +1 -1
- package/dist/{ToggleButton-DrnT3-jX.js → ToggleButton-IFhFMpQh.js} +3 -3
- package/dist/Token/index.js +1 -1
- package/dist/{Token-DZmmnHEj.js → Token-CpmqfG4i.js} +1 -1
- package/dist/Tokenizer/index.d.ts +1 -1
- package/dist/Tokenizer/index.js +1 -1
- package/dist/{Tokenizer-BRFlVyMv.js → Tokenizer-Dvr7ICpS.js} +16 -15
- package/dist/Toolbar/index.d.ts +1 -1
- package/dist/Tooltip/index.d.ts +1 -1
- package/dist/Tooltip/index.js +2 -2
- package/dist/{Tooltip-Dwr0XREF.js → Tooltip-DyGaJUbl.js} +1 -1
- package/dist/TopNav/index.d.ts +1 -1
- package/dist/TopNav/index.js +1 -1
- package/dist/{TopNav-GwsSkeei.js → TopNav-Cw_dcKpf.js} +5 -5
- package/dist/TreeList/index.js +1 -1
- package/dist/{TreeList-BGHHEcg1.js → TreeList-CBfKKbUQ.js} +4 -4
- package/dist/Typeahead/index.js +2 -2
- package/dist/{Typeahead-H3uWMS7i.js → Typeahead-D9-WjsCU.js} +6 -6
- package/dist/{VelocityTracker-DVbtTSXR.js → VelocityTracker-CPFBHDpy.js} +1 -1
- package/dist/{accessibleName-Bjt5L8jX.js → accessibleName-Cw9s1690.js} +2 -2
- package/dist/{animator-DLWdws2R.js → animator-ozeBZ_zC.js} +4 -3
- package/dist/{assertOptions-BdLvkG6M.js → assertOptions-V_jJxpn9.js} +1 -1
- package/dist/{clickGuard-C3VmOLhI.js → clickGuard-CxqcfBCJ.js} +2 -2
- package/dist/{coarsePointer-BfMx3H23.js → coarsePointer-DGnAPIcU.js} +1 -1
- package/dist/composables/index.js +10 -10
- package/dist/{composables-OL_sC9Qy.js → composables-BJoAw6XA.js} +12 -10
- package/dist/{context-BcJmSPj1.js → context-WDet15_N.js} +1 -1
- package/dist/{useAttachment-BohgLE3o.js → geometry-CoQRz-F1.js} +12 -710
- package/dist/{gestures-C8VhWve7.js → gestures-yKyyMqeQ.js} +226 -2
- package/dist/{holdEntranceInput-DgimbgGm.js → holdEntranceInput-BsusS3bM.js} +2 -2
- package/dist/{index-Dpz-JUMl.d.ts → index--kbwaSXW.d.ts} +2 -2
- package/dist/{index-X4S7_dmq.d.ts → index-BA8exXNP.d.ts} +1 -1
- package/dist/{index-0RIgvtdm.d.ts → index-BI1QLuYB.d.ts} +1 -1
- package/dist/{index-yaS9_EpM.d.ts → index-BVi16JNo.d.ts} +2 -2
- package/dist/{index-DvrrgBYc.d.ts → index-BVx-HFp8.d.ts} +1 -1
- package/dist/{index-BB9acgK8.d.ts → index-BgT6mH3U.d.ts} +1 -1
- package/dist/{index-QC9FDUDA.d.ts → index-BqQlY3fL.d.ts} +2 -2
- package/dist/{index-Cb-rvc1W.d.ts → index-BtqvPjAf.d.ts} +2 -2
- package/dist/{index-CZ29Xu_E.d.ts → index-Bwh8O-v8.d.ts} +1 -1
- package/dist/{index-D05JGsT3.d.ts → index-C8wfe0Mr.d.ts} +1 -1
- package/dist/{index-51CkIKnI.d.ts → index-C93nwgTW.d.ts} +1 -1
- package/dist/{index-CiVrhGUJ.d.ts → index-C9ZssPUV.d.ts} +1 -1
- package/dist/{index-BaFphczL.d.ts → index-COgrQZIL.d.ts} +1 -1
- package/dist/{index-AgTJRqUY.d.ts → index-CQi9WGWE.d.ts} +2 -2
- package/dist/{index-D33x3IfY.d.ts → index-CTv55aOa.d.ts} +1 -1
- package/dist/{index-18IUS3l0.d.ts → index-CY0KtUSC.d.ts} +53 -53
- package/dist/{index-CUwmD3Ph.d.ts → index-D1JOMiI5.d.ts} +3 -3
- package/dist/{index-MvrDMqnQ.d.ts → index-DPhQZXYw.d.ts} +2 -2
- package/dist/{index-B2XndRvV.d.ts → index-DuxRUPMc.d.ts} +2 -2
- package/dist/{index-EAKu_r6h.d.ts → index-GyRgg1-v.d.ts} +3 -3
- package/dist/{index-DVX2jlTQ.d.ts → index-JE1HrzdJ.d.ts} +2 -2
- package/dist/{index-Dt_9IR_M.d.ts → index-JGPd3Ghy.d.ts} +1 -1
- package/dist/{index-Q1oG9yIT.d.ts → index-Pad9p8CU.d.ts} +3 -1
- package/dist/index.d.ts +24 -24
- package/dist/index.js +107 -107
- package/dist/{inputHold-DW2LYHb5.js → inputHold-BJtjc9iI.js} +4 -4
- package/dist/{inputHoldState-xntIqr5W.js → inputHoldState-BYi5FKZl.js} +2 -2
- package/dist/{inputStream-bPd9eB2b.js → inputStream-HXw2lZ-3.js} +1 -1
- package/dist/{landing-Dx9vPF0t.js → landing-Qk_FHR-s.js} +1 -1
- package/dist/{layerDepth-D-80Ay8B.js → layerDepth-SGFJ5L6X.js} +1 -1
- package/dist/{lazyBottomSheet-s0ckIf0f.js → lazyBottomSheet-Bg5E8lr3.js} +1 -1
- package/dist/{linearEasing-BxWjPql6.js → linearEasing-VHwy6xl_.js} +136 -87
- package/dist/{loadCatalog-VYidi1Xi.d.ts → loadCatalog-BODWYaNy.d.ts} +2 -0
- package/dist/{loadCatalog-zJKVLZ89.js → loadCatalog-DMOOMWtw.js} +3 -2
- package/dist/locale/index.d.ts +2 -2
- package/dist/locale/index.js +3 -3
- package/dist/{locale-C9LWi1y1.js → locale-C8X7gJlc.js} +1 -1
- package/dist/{presentation-Cy_yf56y.js → presentation-twEOzzJq.js} +1 -1
- package/dist/{presentationHold-B4tK68sd.js → presentationHold-CZsVmjlY.js} +1 -1
- package/dist/{pressFeedback-CPzGi_88.js → pressFeedback-9ogipvI4.js} +4 -4
- package/dist/{pressGesture-BV4fYPIG.js → pressGesture-B3Efxs_z.js} +1 -1
- package/dist/{rubberBand-DecgmtDj.js → projection-qPcLQcwK.js} +2 -50
- package/dist/{reportChange-BkOEttEP.js → reportChange-BUTgduu-.js} +5 -4
- package/dist/{resizableChannel-DS0idC-X.js → resizableChannel-_j_AW2B6.js} +5 -5
- package/dist/{resolveMotion-BLdMNTpf.js → resolveMotion-DftkGFw6.js} +2 -2
- package/dist/{resolveSnapPoint-DygD-wmL.js → resolveSnapPoint-A4dhS5jj.js} +1 -1
- package/dist/{roles-CPMsH5Ob.js → roles-DWH31Bn3.js} +126 -1
- package/dist/rubberBand-DDd5ElTe.js +65 -0
- package/dist/{sharedRealm-H1OrlP0V.js → sharedRealm-DBtNH73I.js} +9 -1
- package/dist/{springs-BR66JuIm.js → springs-DjAn_oV5.js} +2 -2
- package/dist/{stepper-BMSGF96H.js → stepper-D7L_3xxU.js} +4 -2
- package/dist/{stillPointerGate-CrsrgFyo.js → stillPointerGate-BvCX7ddI.js} +1 -1
- package/dist/{themeTiming-BA_wpgEn.js → themeTiming-ClYaZxGf.js} +1 -1
- package/dist/{tooltipFocusRules-BWcYZXu8.js → tooltipFocusRules-CxIlSnHw.js} +2 -2
- package/dist/{tooltipTriggerRules-DFPKbHJc.js → tooltipTriggerRules-CHNpQ6RL.js} +1 -1
- package/dist/{touchHold-DXtx7npm.js → touchHold-CjNjGH7O.js} +1 -1
- package/dist/{useActionGroupTracking-iv0p__dY.js → useActionGroupTracking-ByLJoM-8.js} +3 -3
- package/dist/{useAnimatedLayout-BC1mJaxA.js → useAnimatedLayout-IcX0UfS4.js} +1 -1
- package/dist/useAttachment-CGiD9rt6.js +24 -0
- package/dist/{useChatStreamScroll-CuMzkXgD.js → useChatStreamScroll-DcNKcNTj.js} +1 -1
- package/dist/{useDismiss-Di0mkAl_.js → useDismiss-6SGAlkB_.js} +1 -1
- package/dist/{useHeldPresentation-BF5vGVUn.js → useHeldPresentation-DJEthuMT.js} +1 -1
- package/dist/{useInputStatusIcon-Dese9hBA.js → useInputStatusIcon-D0q4S1Ye.js} +1 -1
- package/dist/{useMenuEntranceHold-HznOwIry.js → useMenuEntranceHold-B7f9ShX2.js} +1 -1
- package/dist/{useMenuPress-RFwJ3jGS.js → useMenuPress-cBIQyTsN.js} +4 -4
- package/dist/{usePressFeedback-BuyFZkQO.js → usePressFeedback-Dx-a3i82.js} +1 -1
- package/dist/{useResizable-K9hlQr8i.js → useResizable-JvgYydox.js} +6 -5
- package/dist/{useTooltip-48Smw61m.js → useTooltip-owvVSn_m.js} +4 -4
- package/dist/{useTouchHitArea-Dsz80HzY.js → useTouchHitArea-BGkvMAyp.js} +2 -2
- package/dist/{useTouchTriggerInternal-CUiq_FYD.js → useTouchTriggerInternal-5ExaYYSy.js} +1 -1
- package/dist/{useTruncationTooltip-D1Iwku73.js → useTruncationTooltip-DHI6q_EV.js} +3 -3
- package/dist/{useTypeaheadMenuConfig-CiTAlquw.js → useTypeaheadMenuConfig-COiZ4isy.js} +2 -2
- package/package.json +1 -1
- package/styles/progress-bar.css +69 -5
- package/styles/skeleton.css +62 -5
- package/styles/slider.css +59 -12
- package/styles/spinner.css +30 -7
- package/styles/switch.css +101 -34
- package/dist/ProgressBar-jtD4zcDW.js +0 -166
- package/dist/Slider-TpbMaQ4Q.js +0 -735
- package/dist/Spinner-DEVPDsD0.js +0 -201
- package/dist/Switch-CW27rVAy.js +0 -355
package/dist/Spinner-DEVPDsD0.js
DELETED
|
@@ -1,201 +0,0 @@
|
|
|
1
|
-
import { o as useComponentMessages } from "./context-B8IEFCDR.js";
|
|
2
|
-
import { t as spinnerMessages } from "./spinner-DVia-eDf.js";
|
|
3
|
-
import { computed, createElementBlock, createElementVNode, createTextVNode, defineComponent, mergeProps, normalizeStyle, openBlock, renderSlot, toDisplayString, useAttrs, useId, useSlots } from "vue";
|
|
4
|
-
import "../styles/spinner.css";
|
|
5
|
-
//#region src/Spinner/spinnerGeometry.ts
|
|
6
|
-
const RESOLVED_GEOMETRY = ["--_spinner-ring-diameter", "--_spinner-ring-stroke"];
|
|
7
|
-
let registered = false;
|
|
8
|
-
/**
|
|
9
|
-
* 把圆环的直径和描边登记成长度。
|
|
10
|
-
* 这样主题写成 `0` 时,它是 0px,而不是把 `calc()` 里的加法变成非法值。
|
|
11
|
-
* 公开变量不登记,避免整份文档都带着一个初始值。
|
|
12
|
-
*/
|
|
13
|
-
function registerSpinnerGeometry() {
|
|
14
|
-
if (registered || typeof CSS === "undefined" || typeof CSS.registerProperty !== "function") return;
|
|
15
|
-
registered = true;
|
|
16
|
-
for (const name of RESOLVED_GEOMETRY) try {
|
|
17
|
-
CSS.registerProperty({
|
|
18
|
-
name,
|
|
19
|
-
syntax: "<length>",
|
|
20
|
-
inherits: true,
|
|
21
|
-
initialValue: "0px"
|
|
22
|
-
});
|
|
23
|
-
} catch {}
|
|
24
|
-
}
|
|
25
|
-
//#endregion
|
|
26
|
-
//#region src/Spinner/spinnerPhase.ts
|
|
27
|
-
const pending = /* @__PURE__ */ new Set();
|
|
28
|
-
let scheduled = false;
|
|
29
|
-
function pinPendingRings() {
|
|
30
|
-
scheduled = false;
|
|
31
|
-
const animations = [];
|
|
32
|
-
for (const svg of pending) if (typeof svg.getAnimations === "function") animations.push(...svg.getAnimations({ subtree: true }));
|
|
33
|
-
pending.clear();
|
|
34
|
-
for (const animation of animations) animation.startTime = 0;
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* 把这条弧的动画起点钉在文档时间线的 0。
|
|
38
|
-
* 后出现的加载圈因此和先出现的停在同一相位,而不是各自从挂载的那一帧开始。
|
|
39
|
-
*/
|
|
40
|
-
function bindSpinnerPhase(svg) {
|
|
41
|
-
if (typeof svg.getAnimations !== "function") return () => {};
|
|
42
|
-
pending.add(svg);
|
|
43
|
-
if (!scheduled) {
|
|
44
|
-
scheduled = true;
|
|
45
|
-
requestAnimationFrame(pinPendingRings);
|
|
46
|
-
}
|
|
47
|
-
return () => {
|
|
48
|
-
pending.delete(svg);
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
//#endregion
|
|
52
|
-
//#region src/Spinner/Spinner.vue
|
|
53
|
-
const _hoisted_1 = ["data-size", "data-shade"];
|
|
54
|
-
const _hoisted_2 = ["aria-label", "aria-labelledby"];
|
|
55
|
-
const _hoisted_3 = ["width", "height"];
|
|
56
|
-
const _hoisted_4 = ["r", "stroke-width"];
|
|
57
|
-
const _hoisted_5 = [
|
|
58
|
-
"r",
|
|
59
|
-
"stroke-width",
|
|
60
|
-
"stroke-dasharray"
|
|
61
|
-
];
|
|
62
|
-
const _hoisted_6 = [
|
|
63
|
-
"data-size",
|
|
64
|
-
"data-shade",
|
|
65
|
-
"aria-label"
|
|
66
|
-
];
|
|
67
|
-
const _hoisted_7 = ["width", "height"];
|
|
68
|
-
const _hoisted_8 = ["r", "stroke-width"];
|
|
69
|
-
const _hoisted_9 = [
|
|
70
|
-
"r",
|
|
71
|
-
"stroke-width",
|
|
72
|
-
"stroke-dasharray"
|
|
73
|
-
];
|
|
74
|
-
const ARC_FRACTION = .375;
|
|
75
|
-
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
76
|
-
name: "AstryxSpinner",
|
|
77
|
-
inheritAttrs: false,
|
|
78
|
-
__name: "Spinner",
|
|
79
|
-
props: {
|
|
80
|
-
size: { default: "md" },
|
|
81
|
-
shade: { default: "default" },
|
|
82
|
-
label: {}
|
|
83
|
-
},
|
|
84
|
-
setup(__props) {
|
|
85
|
-
const props = __props;
|
|
86
|
-
const RING = {
|
|
87
|
-
sm: {
|
|
88
|
-
diameter: 10,
|
|
89
|
-
stroke: 2
|
|
90
|
-
},
|
|
91
|
-
md: {
|
|
92
|
-
diameter: 14,
|
|
93
|
-
stroke: 3
|
|
94
|
-
},
|
|
95
|
-
lg: {
|
|
96
|
-
diameter: 18,
|
|
97
|
-
stroke: 3
|
|
98
|
-
},
|
|
99
|
-
xl: {
|
|
100
|
-
diameter: 28,
|
|
101
|
-
stroke: 4
|
|
102
|
-
}
|
|
103
|
-
};
|
|
104
|
-
registerSpinnerGeometry();
|
|
105
|
-
const attrs = useAttrs();
|
|
106
|
-
const slots = useSlots();
|
|
107
|
-
const messages = useComponentMessages({ spinner: spinnerMessages });
|
|
108
|
-
const labelId = `astryx-spinner-label-${useId()}`;
|
|
109
|
-
const hasLabel = computed(() => Boolean(props.label) || Boolean(slots.label));
|
|
110
|
-
const ariaLabel = computed(() => attrs["aria-label"]);
|
|
111
|
-
const namedByVisibleLabel = computed(() => Boolean(props.label) && !ariaLabel.value);
|
|
112
|
-
const ringLabelledBy = computed(() => namedByVisibleLabel.value ? labelId : void 0);
|
|
113
|
-
const ringAriaLabel = computed(() => {
|
|
114
|
-
if (namedByVisibleLabel.value) return void 0;
|
|
115
|
-
return ariaLabel.value ?? props.label ?? messages.value.spinner.loading;
|
|
116
|
-
});
|
|
117
|
-
const rootAttrs = computed(() => Object.fromEntries(Object.entries(attrs).filter(([key]) => key !== "aria-label" && key !== "style")));
|
|
118
|
-
const geometry = computed(() => RING[props.size]);
|
|
119
|
-
const frameSize = computed(() => geometry.value.diameter + geometry.value.stroke * 2);
|
|
120
|
-
const arcLength = computed(() => Math.PI * geometry.value.diameter * ARC_FRACTION);
|
|
121
|
-
const gapLength = computed(() => Math.PI * geometry.value.diameter - arcLength.value);
|
|
122
|
-
const boxStyle = computed(() => ({
|
|
123
|
-
width: `var(--_spinner-box-size, ${frameSize.value}px)`,
|
|
124
|
-
height: `var(--_spinner-box-size, ${frameSize.value}px)`
|
|
125
|
-
}));
|
|
126
|
-
const callerStyle = computed(() => attrs.style);
|
|
127
|
-
const rootStyle = computed(() => [callerStyle.value, hasLabel.value ? void 0 : boxStyle.value]);
|
|
128
|
-
let releasePhase;
|
|
129
|
-
function onRing(element) {
|
|
130
|
-
releasePhase?.();
|
|
131
|
-
releasePhase = void 0;
|
|
132
|
-
if (element instanceof SVGSVGElement) releasePhase = bindSpinnerPhase(element);
|
|
133
|
-
}
|
|
134
|
-
return (_ctx, _cache) => {
|
|
135
|
-
return hasLabel.value ? (openBlock(), createElementBlock("div", mergeProps({ key: 0 }, rootAttrs.value, {
|
|
136
|
-
class: "astryx-spinner astryx-spinner-group",
|
|
137
|
-
"data-size": __props.size,
|
|
138
|
-
"data-shade": __props.shade,
|
|
139
|
-
style: callerStyle.value
|
|
140
|
-
}), [createElementVNode("span", {
|
|
141
|
-
class: "astryx-spinner-box",
|
|
142
|
-
role: "status",
|
|
143
|
-
"aria-label": ringAriaLabel.value,
|
|
144
|
-
"aria-labelledby": ringLabelledBy.value,
|
|
145
|
-
style: normalizeStyle(boxStyle.value)
|
|
146
|
-
}, [(openBlock(), createElementBlock("svg", {
|
|
147
|
-
ref: onRing,
|
|
148
|
-
class: "astryx-spinner__ring",
|
|
149
|
-
width: frameSize.value,
|
|
150
|
-
height: frameSize.value,
|
|
151
|
-
"aria-hidden": "true",
|
|
152
|
-
focusable: "false"
|
|
153
|
-
}, [createElementVNode("circle", {
|
|
154
|
-
class: "astryx-spinner__track",
|
|
155
|
-
cx: "50%",
|
|
156
|
-
cy: "50%",
|
|
157
|
-
r: geometry.value.diameter / 2,
|
|
158
|
-
"stroke-width": geometry.value.stroke
|
|
159
|
-
}, null, 8, _hoisted_4), createElementVNode("circle", {
|
|
160
|
-
class: "astryx-spinner__arc",
|
|
161
|
-
cx: "50%",
|
|
162
|
-
cy: "50%",
|
|
163
|
-
r: geometry.value.diameter / 2,
|
|
164
|
-
"stroke-width": geometry.value.stroke,
|
|
165
|
-
"stroke-dasharray": `${arcLength.value} ${gapLength.value}`
|
|
166
|
-
}, null, 8, _hoisted_5)], 8, _hoisted_3))], 12, _hoisted_2), createElementVNode("span", {
|
|
167
|
-
id: labelId,
|
|
168
|
-
class: "astryx-spinner-label"
|
|
169
|
-
}, [renderSlot(_ctx.$slots, "label", {}, () => [createTextVNode(toDisplayString(__props.label), 1)])])], 16, _hoisted_1)) : (openBlock(), createElementBlock("span", mergeProps({ key: 1 }, rootAttrs.value, {
|
|
170
|
-
class: "astryx-spinner astryx-spinner-box",
|
|
171
|
-
role: "status",
|
|
172
|
-
"data-size": __props.size,
|
|
173
|
-
"data-shade": __props.shade,
|
|
174
|
-
"aria-label": ringAriaLabel.value,
|
|
175
|
-
style: rootStyle.value
|
|
176
|
-
}), [(openBlock(), createElementBlock("svg", {
|
|
177
|
-
ref: onRing,
|
|
178
|
-
class: "astryx-spinner__ring",
|
|
179
|
-
width: frameSize.value,
|
|
180
|
-
height: frameSize.value,
|
|
181
|
-
"aria-hidden": "true",
|
|
182
|
-
focusable: "false"
|
|
183
|
-
}, [createElementVNode("circle", {
|
|
184
|
-
class: "astryx-spinner__track",
|
|
185
|
-
cx: "50%",
|
|
186
|
-
cy: "50%",
|
|
187
|
-
r: geometry.value.diameter / 2,
|
|
188
|
-
"stroke-width": geometry.value.stroke
|
|
189
|
-
}, null, 8, _hoisted_8), createElementVNode("circle", {
|
|
190
|
-
class: "astryx-spinner__arc",
|
|
191
|
-
cx: "50%",
|
|
192
|
-
cy: "50%",
|
|
193
|
-
r: geometry.value.diameter / 2,
|
|
194
|
-
"stroke-width": geometry.value.stroke,
|
|
195
|
-
"stroke-dasharray": `${arcLength.value} ${gapLength.value}`
|
|
196
|
-
}, null, 8, _hoisted_9)], 8, _hoisted_7))], 16, _hoisted_6));
|
|
197
|
-
};
|
|
198
|
-
}
|
|
199
|
-
});
|
|
200
|
-
//#endregion
|
|
201
|
-
export { _sfc_main as t };
|
package/dist/Switch-CW27rVAy.js
DELETED
|
@@ -1,355 +0,0 @@
|
|
|
1
|
-
import { t as usePressFeedback } from "./usePressFeedback-BuyFZkQO.js";
|
|
2
|
-
import { t as _sfc_main$1 } from "./VisuallyHidden-cpmsV-0M.js";
|
|
3
|
-
import { t as _sfc_main$2 } from "./ButtonTooltip-ZpQP-aQg.js";
|
|
4
|
-
import { t as useButtonTooltip } from "./useButtonTooltip-DjCaZMp_.js";
|
|
5
|
-
import { t as useAnnounce } from "./announce-GU01Oix2.js";
|
|
6
|
-
import { o as useComponentMessages } from "./context-B8IEFCDR.js";
|
|
7
|
-
import { r as withholdCallerHandlers } from "./disabledInteraction-Bqoyhoss.js";
|
|
8
|
-
import { t as ariaRequired } from "./context-CrVCeUUK.js";
|
|
9
|
-
import { t as _sfc_main$3 } from "./FieldLabel-SiRzxGz8.js";
|
|
10
|
-
import { t as _sfc_main$4 } from "./FieldStatus-DmCWPT6U.js";
|
|
11
|
-
import { t as switchMessages } from "./switch-B9xwxdOU.js";
|
|
12
|
-
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createTextVNode, createVNode, defineComponent, mergeModels, mergeProps, nextTick, normalizeClass, normalizeStyle, onBeforeUnmount, onMounted, onUpdated, openBlock, renderSlot, shallowRef, toDisplayString, unref, useAttrs, useId, useModel, useTemplateRef, watch, withCtx } from "vue";
|
|
13
|
-
import "../styles/switch.css";
|
|
14
|
-
//#region src/Switch/useSwitchAction.ts
|
|
15
|
-
function useSwitchAction(options) {
|
|
16
|
-
const optimistic = shallowRef(null);
|
|
17
|
-
const pendingCount = shallowRef(0);
|
|
18
|
-
let revision = 0;
|
|
19
|
-
watch(options.model, () => {
|
|
20
|
-
optimistic.value = null;
|
|
21
|
-
});
|
|
22
|
-
function commit(value, event) {
|
|
23
|
-
const current = ++revision;
|
|
24
|
-
const changeEvent = new CustomEvent("change", {
|
|
25
|
-
cancelable: true,
|
|
26
|
-
detail: {
|
|
27
|
-
value,
|
|
28
|
-
originalEvent: event
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
if (event.defaultPrevented) changeEvent.preventDefault();
|
|
32
|
-
optimistic.value = value;
|
|
33
|
-
options.model.value = value;
|
|
34
|
-
options.emitChange(value, changeEvent);
|
|
35
|
-
const action = options.changeAction();
|
|
36
|
-
if (!action || changeEvent.defaultPrevented) {
|
|
37
|
-
optimistic.value = null;
|
|
38
|
-
return;
|
|
39
|
-
}
|
|
40
|
-
pendingCount.value += 1;
|
|
41
|
-
const finish = () => {
|
|
42
|
-
pendingCount.value -= 1;
|
|
43
|
-
if (current === revision) optimistic.value = null;
|
|
44
|
-
};
|
|
45
|
-
try {
|
|
46
|
-
const result = action(value, changeEvent);
|
|
47
|
-
if (result == null) {
|
|
48
|
-
finish();
|
|
49
|
-
return;
|
|
50
|
-
}
|
|
51
|
-
Promise.resolve(result).then(finish, (error) => {
|
|
52
|
-
finish();
|
|
53
|
-
options.emitError(error, value, changeEvent);
|
|
54
|
-
});
|
|
55
|
-
} catch (error) {
|
|
56
|
-
finish();
|
|
57
|
-
options.emitError(error, value, changeEvent);
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
return {
|
|
61
|
-
commit,
|
|
62
|
-
value: computed(() => optimistic.value ?? options.model.value),
|
|
63
|
-
isPending: computed(() => pendingCount.value > 0)
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
//#endregion
|
|
67
|
-
//#region src/Switch/Switch.vue
|
|
68
|
-
const _hoisted_1 = [
|
|
69
|
-
"data-size",
|
|
70
|
-
"data-label-position",
|
|
71
|
-
"data-label-spacing",
|
|
72
|
-
"data-status",
|
|
73
|
-
"data-blocked"
|
|
74
|
-
];
|
|
75
|
-
const _hoisted_2 = { class: "astryx-switch-control" };
|
|
76
|
-
const _hoisted_3 = [
|
|
77
|
-
"id",
|
|
78
|
-
"checked",
|
|
79
|
-
"name",
|
|
80
|
-
"form",
|
|
81
|
-
"readonly",
|
|
82
|
-
"required",
|
|
83
|
-
"aria-checked",
|
|
84
|
-
"aria-labelledby",
|
|
85
|
-
"aria-describedby",
|
|
86
|
-
"aria-disabled",
|
|
87
|
-
"aria-readonly",
|
|
88
|
-
"aria-busy",
|
|
89
|
-
"aria-required",
|
|
90
|
-
"aria-invalid"
|
|
91
|
-
];
|
|
92
|
-
const _hoisted_4 = {
|
|
93
|
-
class: "astryx-switch-track",
|
|
94
|
-
"aria-hidden": "true"
|
|
95
|
-
};
|
|
96
|
-
const _hoisted_5 = {
|
|
97
|
-
key: 0,
|
|
98
|
-
class: "astryx-switch-spinner"
|
|
99
|
-
};
|
|
100
|
-
const _hoisted_6 = { class: "astryx-switch-label" };
|
|
101
|
-
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
102
|
-
name: "AstryxSwitch",
|
|
103
|
-
inheritAttrs: false,
|
|
104
|
-
__name: "Switch",
|
|
105
|
-
props: /*@__PURE__*/ mergeModels({
|
|
106
|
-
id: {},
|
|
107
|
-
size: { default: "md" },
|
|
108
|
-
labelPosition: { default: "end" },
|
|
109
|
-
labelSpacing: { default: "hug" },
|
|
110
|
-
isReadOnly: { type: Boolean },
|
|
111
|
-
disabledMessage: {},
|
|
112
|
-
status: {},
|
|
113
|
-
statusVariant: { default: "detached" },
|
|
114
|
-
changeAction: {},
|
|
115
|
-
isLoading: { type: Boolean },
|
|
116
|
-
description: {},
|
|
117
|
-
width: {},
|
|
118
|
-
hasAutoFocus: { type: Boolean },
|
|
119
|
-
htmlName: {},
|
|
120
|
-
form: {},
|
|
121
|
-
loadingLabel: {},
|
|
122
|
-
label: {},
|
|
123
|
-
isLabelHidden: { type: Boolean },
|
|
124
|
-
isDisabled: { type: Boolean },
|
|
125
|
-
isOptional: { type: Boolean },
|
|
126
|
-
isRequired: { type: Boolean },
|
|
127
|
-
labelIcon: {},
|
|
128
|
-
labelTooltip: {},
|
|
129
|
-
optionalLabel: {},
|
|
130
|
-
requiredLabel: {},
|
|
131
|
-
targetClass: {}
|
|
132
|
-
}, {
|
|
133
|
-
"modelValue": {
|
|
134
|
-
type: Boolean,
|
|
135
|
-
required: true
|
|
136
|
-
},
|
|
137
|
-
"modelModifiers": {}
|
|
138
|
-
}),
|
|
139
|
-
emits: /*@__PURE__*/ mergeModels(["change", "actionError"], ["update:modelValue"]),
|
|
140
|
-
setup(__props, { expose: __expose, emit: __emit }) {
|
|
141
|
-
const props = __props;
|
|
142
|
-
const emit = __emit;
|
|
143
|
-
const ariaRequired$1 = computed(() => ariaRequired(props.isRequired, props.isOptional, void 0));
|
|
144
|
-
const messages = useComponentMessages({ switch: switchMessages });
|
|
145
|
-
const announce = useAnnounce();
|
|
146
|
-
const press = usePressFeedback({ hasOverlay: false });
|
|
147
|
-
const model = useModel(__props, "modelValue");
|
|
148
|
-
const attrs = useAttrs();
|
|
149
|
-
const input = useTemplateRef("input");
|
|
150
|
-
const generatedId = `astryx-switch-${useId()}`;
|
|
151
|
-
const inputId = computed(() => props.id ?? generatedId);
|
|
152
|
-
const descriptionId = computed(() => props.description ? `${inputId.value}-description` : void 0);
|
|
153
|
-
const statusId = computed(() => props.status?.message ? props.status.messageId ?? `${inputId.value}-status` : void 0);
|
|
154
|
-
const disabledId = `${generatedId}-disabled`;
|
|
155
|
-
const showsDisabledMessage = computed(() => !!props.isDisabled && !!props.disabledMessage?.trim());
|
|
156
|
-
const tooltip = useButtonTooltip(showsDisabledMessage);
|
|
157
|
-
const action = useSwitchAction({
|
|
158
|
-
model,
|
|
159
|
-
changeAction: () => props.changeAction,
|
|
160
|
-
emitChange: (value, event) => emit("change", value, event),
|
|
161
|
-
emitError: (error, value, event) => emit("actionError", error, value, event)
|
|
162
|
-
});
|
|
163
|
-
const busy = computed(() => !!props.isLoading || action.isPending.value);
|
|
164
|
-
const blocked = computed(() => props.isDisabled || props.isReadOnly || busy.value);
|
|
165
|
-
const loadingText = computed(() => props.loadingLabel || messages.value.switch.loading);
|
|
166
|
-
watch(busy, (isBusy) => {
|
|
167
|
-
if (isBusy) announce(loadingText.value);
|
|
168
|
-
}, { immediate: true });
|
|
169
|
-
const widthStyle = computed(() => ({ width: typeof props.width === "number" ? `${props.width}px` : props.width }));
|
|
170
|
-
const element = computed(() => input.value ?? null);
|
|
171
|
-
function focus(options) {
|
|
172
|
-
input.value?.focus(options);
|
|
173
|
-
}
|
|
174
|
-
function blur() {
|
|
175
|
-
input.value?.blur();
|
|
176
|
-
}
|
|
177
|
-
__expose({
|
|
178
|
-
element,
|
|
179
|
-
focus,
|
|
180
|
-
blur
|
|
181
|
-
});
|
|
182
|
-
const controlledAttrs = /* @__PURE__ */ new Set([
|
|
183
|
-
"class",
|
|
184
|
-
"style",
|
|
185
|
-
"id",
|
|
186
|
-
"type",
|
|
187
|
-
"checked",
|
|
188
|
-
"disabled",
|
|
189
|
-
"readonly",
|
|
190
|
-
"autofocus",
|
|
191
|
-
"role",
|
|
192
|
-
"aria-checked",
|
|
193
|
-
"aria-labelledby",
|
|
194
|
-
"aria-describedby",
|
|
195
|
-
"aria-disabled",
|
|
196
|
-
"aria-readonly",
|
|
197
|
-
"aria-required",
|
|
198
|
-
"aria-busy"
|
|
199
|
-
]);
|
|
200
|
-
function inputAttrs() {
|
|
201
|
-
return Object.fromEntries(Object.entries(withholdCallerHandlers(attrs, !!props.isDisabled)).filter(([key]) => !controlledAttrs.has(key)));
|
|
202
|
-
}
|
|
203
|
-
function describedBy() {
|
|
204
|
-
return [
|
|
205
|
-
attrs["aria-describedby"],
|
|
206
|
-
descriptionId.value,
|
|
207
|
-
statusId.value,
|
|
208
|
-
showsDisabledMessage.value ? disabledId : void 0
|
|
209
|
-
].filter(Boolean).join(" ") || void 0;
|
|
210
|
-
}
|
|
211
|
-
function labelledBy() {
|
|
212
|
-
const external = attrs["aria-labelledby"];
|
|
213
|
-
if (typeof external === "string" && external.trim() !== "") return external;
|
|
214
|
-
return `${inputId.value}-label`;
|
|
215
|
-
}
|
|
216
|
-
function syncNative() {
|
|
217
|
-
if (input.value) input.value.checked = action.value.value;
|
|
218
|
-
}
|
|
219
|
-
function click(event) {
|
|
220
|
-
if (blocked.value) {
|
|
221
|
-
event.preventDefault();
|
|
222
|
-
nextTick(syncNative);
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
function change(event) {
|
|
226
|
-
if (!blocked.value && input.value) action.commit(input.value.checked, event);
|
|
227
|
-
nextTick(syncNative);
|
|
228
|
-
}
|
|
229
|
-
function reset(event) {
|
|
230
|
-
if (event.target === input.value?.form) nextTick(syncNative);
|
|
231
|
-
}
|
|
232
|
-
function keydown(event) {
|
|
233
|
-
if (event.key === "Escape") tooltip.hideImmediately();
|
|
234
|
-
}
|
|
235
|
-
let ownerDocument;
|
|
236
|
-
onMounted(() => {
|
|
237
|
-
syncNative();
|
|
238
|
-
ownerDocument = input.value?.ownerDocument;
|
|
239
|
-
ownerDocument?.addEventListener("reset", reset, true);
|
|
240
|
-
if (props.hasAutoFocus) focus({ preventScroll: true });
|
|
241
|
-
});
|
|
242
|
-
onUpdated(syncNative);
|
|
243
|
-
onBeforeUnmount(() => ownerDocument?.removeEventListener("reset", reset, true));
|
|
244
|
-
return (_ctx, _cache) => {
|
|
245
|
-
return openBlock(), createElementBlock(Fragment, null, [createElementVNode("div", {
|
|
246
|
-
class: normalizeClass(["astryx-switch", unref(attrs).class]),
|
|
247
|
-
style: normalizeStyle([widthStyle.value, unref(attrs).style]),
|
|
248
|
-
"data-size": __props.size,
|
|
249
|
-
"data-label-position": __props.labelPosition !== "end" ? __props.labelPosition : void 0,
|
|
250
|
-
"data-label-spacing": __props.labelSpacing !== "hug" ? __props.labelSpacing : void 0,
|
|
251
|
-
"data-status": __props.status?.type,
|
|
252
|
-
"data-blocked": blocked.value || void 0
|
|
253
|
-
}, [
|
|
254
|
-
createElementVNode("div", mergeProps({ class: "astryx-switch-row" }, blocked.value ? void 0 : unref(press).pressableProps, {
|
|
255
|
-
onPointerenter: _cache[2] || (_cache[2] = (...args) => unref(tooltip).onPointerEnter && unref(tooltip).onPointerEnter(...args)),
|
|
256
|
-
onPointerleave: _cache[3] || (_cache[3] = (...args) => unref(tooltip).onPointerLeave && unref(tooltip).onPointerLeave(...args))
|
|
257
|
-
}), [createElementVNode("span", _hoisted_2, [createElementVNode("input", mergeProps(inputAttrs(), {
|
|
258
|
-
id: inputId.value,
|
|
259
|
-
ref_key: "input",
|
|
260
|
-
ref: input,
|
|
261
|
-
class: "astryx-switch-native",
|
|
262
|
-
type: "checkbox",
|
|
263
|
-
role: "switch",
|
|
264
|
-
checked: unref(action).value.value,
|
|
265
|
-
name: __props.isDisabled ? void 0 : __props.htmlName ?? inputAttrs().name,
|
|
266
|
-
form: __props.isDisabled ? "" : inputAttrs().form,
|
|
267
|
-
readonly: __props.isReadOnly || showsDisabledMessage.value,
|
|
268
|
-
required: __props.isRequired && !__props.isOptional,
|
|
269
|
-
"aria-checked": unref(action).value.value,
|
|
270
|
-
"aria-labelledby": labelledBy(),
|
|
271
|
-
"aria-describedby": describedBy(),
|
|
272
|
-
"aria-disabled": __props.isDisabled || void 0,
|
|
273
|
-
"aria-readonly": __props.isReadOnly || void 0,
|
|
274
|
-
"aria-busy": busy.value || void 0,
|
|
275
|
-
"aria-required": ariaRequired$1.value,
|
|
276
|
-
"aria-invalid": __props.status?.type === "error" ? true : __props.isRequired ? false : inputAttrs()["aria-invalid"],
|
|
277
|
-
onClick: click,
|
|
278
|
-
onChange: change,
|
|
279
|
-
onKeydown: keydown,
|
|
280
|
-
onFocus: _cache[0] || (_cache[0] = (...args) => unref(tooltip).onFocus && unref(tooltip).onFocus(...args)),
|
|
281
|
-
onBlur: _cache[1] || (_cache[1] = (...args) => unref(tooltip).onBlur && unref(tooltip).onBlur(...args))
|
|
282
|
-
}), null, 16, _hoisted_3), createElementVNode("span", _hoisted_4, [_cache[4] || (_cache[4] = createElementVNode("span", { class: "astryx-switch-thumb" }, null, -1)), busy.value ? (openBlock(), createElementBlock("span", _hoisted_5)) : createCommentVNode("v-if", true)])]), createElementVNode("div", _hoisted_6, [createVNode(_sfc_main$3, {
|
|
283
|
-
label: __props.label,
|
|
284
|
-
"input-id": inputId.value,
|
|
285
|
-
"label-id": `${inputId.value}-label`,
|
|
286
|
-
description: __props.description,
|
|
287
|
-
"description-id": descriptionId.value,
|
|
288
|
-
"is-label-hidden": __props.isLabelHidden,
|
|
289
|
-
"is-disabled": __props.isDisabled,
|
|
290
|
-
"is-optional": __props.isOptional,
|
|
291
|
-
"is-required": __props.isRequired,
|
|
292
|
-
"target-class": "astryx-switch-label",
|
|
293
|
-
"label-icon": __props.labelIcon,
|
|
294
|
-
"label-tooltip": __props.labelTooltip,
|
|
295
|
-
"optional-label": __props.optionalLabel,
|
|
296
|
-
"required-label": __props.requiredLabel
|
|
297
|
-
}, createSlots({ _: 2 }, [_ctx.$slots.labelIcon ? {
|
|
298
|
-
name: "labelIcon",
|
|
299
|
-
fn: withCtx(() => [renderSlot(_ctx.$slots, "labelIcon")]),
|
|
300
|
-
key: "0"
|
|
301
|
-
} : void 0]), 1032, [
|
|
302
|
-
"label",
|
|
303
|
-
"input-id",
|
|
304
|
-
"label-id",
|
|
305
|
-
"description",
|
|
306
|
-
"description-id",
|
|
307
|
-
"is-label-hidden",
|
|
308
|
-
"is-disabled",
|
|
309
|
-
"is-optional",
|
|
310
|
-
"is-required",
|
|
311
|
-
"label-icon",
|
|
312
|
-
"label-tooltip",
|
|
313
|
-
"optional-label",
|
|
314
|
-
"required-label"
|
|
315
|
-
])])], 16),
|
|
316
|
-
__props.status?.message ? (openBlock(), createBlock(_sfc_main$4, {
|
|
317
|
-
key: 0,
|
|
318
|
-
id: statusId.value,
|
|
319
|
-
type: __props.status.type,
|
|
320
|
-
message: __props.status.message,
|
|
321
|
-
variant: __props.statusVariant === "attached" ? "attached" : "detached"
|
|
322
|
-
}, null, 8, [
|
|
323
|
-
"id",
|
|
324
|
-
"type",
|
|
325
|
-
"message",
|
|
326
|
-
"variant"
|
|
327
|
-
])) : createCommentVNode("v-if", true),
|
|
328
|
-
showsDisabledMessage.value ? (openBlock(), createBlock(_sfc_main$1, {
|
|
329
|
-
key: 1,
|
|
330
|
-
id: disabledId
|
|
331
|
-
}, {
|
|
332
|
-
default: withCtx(() => [createTextVNode(toDisplayString(__props.disabledMessage), 1)]),
|
|
333
|
-
_: 1
|
|
334
|
-
})) : createCommentVNode("v-if", true)
|
|
335
|
-
], 14, _hoisted_1), showsDisabledMessage.value ? (openBlock(), createBlock(_sfc_main$2, {
|
|
336
|
-
key: 0,
|
|
337
|
-
id: `${generatedId}-tooltip`,
|
|
338
|
-
anchor: input.value,
|
|
339
|
-
open: unref(tooltip).isOpen.value,
|
|
340
|
-
text: __props.disabledMessage ?? "",
|
|
341
|
-
onPointerEnter: unref(tooltip).onTooltipPointerEnter,
|
|
342
|
-
onPointerLeave: unref(tooltip).onTooltipPointerLeave
|
|
343
|
-
}, null, 8, [
|
|
344
|
-
"id",
|
|
345
|
-
"anchor",
|
|
346
|
-
"open",
|
|
347
|
-
"text",
|
|
348
|
-
"onPointerEnter",
|
|
349
|
-
"onPointerLeave"
|
|
350
|
-
])) : createCommentVNode("v-if", true)], 64);
|
|
351
|
-
};
|
|
352
|
-
}
|
|
353
|
-
});
|
|
354
|
-
//#endregion
|
|
355
|
-
export { _sfc_main as t };
|