@astryx-vue/core 0.7.24 → 0.7.26
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.d.ts +1 -1
- package/dist/AlertDialog/index.js +1 -1
- package/dist/{AlertDialog-DsPFYRxB.js → AlertDialog-DZpJzvOC.js} +30 -15
- package/dist/AppShell/index.d.ts +1 -1
- package/dist/AppShell/index.js +1 -1
- package/dist/{AppShell--izaf9Fx.js → AppShell-D7ik41g-.js} +3 -3
- package/dist/Avatar/index.d.ts +1 -1
- package/dist/Avatar/index.js +1 -1
- package/dist/{Avatar-cNntRBEo.js → Avatar-D_C9RBJb.js} +27 -21
- package/dist/AvatarGroup/index.d.ts +1 -1
- package/dist/AvatarGroup/index.js +1 -1
- package/dist/{AvatarGroup-CiJia58o.js → AvatarGroup-CFvNDgU-.js} +17 -7
- package/dist/Badge/index.js +1 -1
- package/dist/Badge-BbPS_49c.js +41 -0
- package/dist/Banner/index.d.ts +1 -1
- package/dist/Banner/index.js +1 -1
- package/dist/{Banner-C8f377q3.js → Banner-C1B7DsHS.js} +3 -3
- package/dist/BottomSheet/index.d.ts +1 -1
- package/dist/BottomSheet/index.js +2 -2
- package/dist/{BottomSheet-BKeyoL9N.js → BottomSheet-BECeWtEy.js} +2 -2
- package/dist/{BottomSheet-CMukh1iI.js → BottomSheet-CgOzQHaA.js} +4 -2
- package/dist/Breadcrumbs/index.d.ts +2 -2
- package/dist/Breadcrumbs/index.js +2 -2
- package/dist/{Breadcrumbs-CXJNJ93V.js → Breadcrumbs-BgiZY7un.js} +9 -8
- package/dist/Button/index.d.ts +2 -2
- package/dist/Button/index.js +1 -1
- package/dist/{Button-Dgm5wCch.js → Button-DsjdehLZ.js} +181 -18
- package/dist/ButtonGroup/index.d.ts +1 -1
- package/dist/ButtonGroup/index.js +1 -1
- package/dist/{ButtonGroup-UgiGP61q.js → ButtonGroup-CSW7a9vq.js} +14 -2
- package/dist/Calendar/index.d.ts +1 -1
- package/dist/Calendar/index.js +1 -1
- package/dist/{Calendar-d_uOkvFE.js → Calendar-Bzgi-XyF.js} +12 -3
- package/dist/Card/index.d.ts +1 -1
- package/dist/Card/index.js +1 -1
- package/dist/{Card-H4571ZKi.js → Card-BbKFHWuD.js} +2 -0
- package/dist/Carousel/index.js +1 -1
- package/dist/{Carousel-BWTArLIP.js → Carousel--VycM-Sa.js} +64 -19
- package/dist/Chat/index.d.ts +1 -1
- package/dist/Chat/index.js +1 -1
- package/dist/{Chat-DKZWVA3Q.js → Chat-C1DlnlCQ.js} +30 -28
- package/dist/CheckboxInput/index.d.ts +1 -1
- package/dist/CheckboxInput/index.js +1 -1
- package/dist/{CheckboxInput-B4pDfjvr.js → CheckboxInput-uk8nuCEf.js} +4 -4
- package/dist/CheckboxList/index.d.ts +1 -1
- package/dist/CheckboxList/index.js +1 -1
- package/dist/{CheckboxList-DtxfdHRI.js → CheckboxList-Dr4kQ-BC.js} +7 -7
- package/dist/Citation/index.js +1 -1
- package/dist/{Citation-CCu6QWG7.js → Citation-BAFsn6N1.js} +4 -2
- package/dist/ClickableCard/index.d.ts +1 -1
- package/dist/ClickableCard/index.js +1 -1
- package/dist/{ClickableCard-jEBZbzHE.js → ClickableCard-CvxSKkXh.js} +16 -6
- package/dist/Code/index.d.ts +1 -1
- package/dist/Code/index.js +2 -2
- package/dist/{Code-PDhTfE2w.js → Code-6GS0nAkR.js} +1 -1
- package/dist/{CodeBlock-BrE72i6C.js → CodeBlock-PSnUWX57.js} +21 -10
- package/dist/Collapsible/index.d.ts +1 -1
- package/dist/Collapsible/index.js +1 -1
- package/dist/{Collapsible-BsPZ8CoN.js → Collapsible-C_tl5-L0.js} +2 -2
- package/dist/CommandPalette/index.js +1 -1
- package/dist/{CommandPalette-0Kg-dJg3.js → CommandPalette-lewtyQrO.js} +7 -7
- package/dist/ComplexSelector/index.d.ts +1 -1
- package/dist/ComplexSelector/index.js +1 -1
- package/dist/{ComplexSelector-BrGVG8c7.js → ComplexSelector-BUnqjeW5.js} +16 -8
- package/dist/ComponentIcon-BRXBBKeG.js +37 -0
- package/dist/ContextMenu/index.d.ts +2 -2
- package/dist/ContextMenu/index.js +2 -2
- package/dist/{ContextMenu-CgSIWUYh.js → ContextMenu-IDkvorRp.js} +10 -9
- package/dist/DateInput/index.d.ts +1 -1
- package/dist/DateInput/index.js +1 -1
- package/dist/{DateInput-vV0tc4a4.js → DateInput-DTxxFz9-.js} +15 -13
- package/dist/DateRangeInput/index.d.ts +1 -1
- package/dist/DateRangeInput/index.js +1 -1
- package/dist/{DateRangeInput-DcM1Zntr.js → DateRangeInput-D4Us58KW.js} +9 -9
- package/dist/DateTimeInput/index.d.ts +1 -1
- package/dist/DateTimeInput/index.js +1 -1
- package/dist/{DateTimeInput-DbbVU3bk.js → DateTimeInput-CliLnI7P.js} +10 -10
- package/dist/Dialog/index.d.ts +1 -1
- package/dist/Dialog/index.js +3 -3
- package/dist/{Dialog-vPGLWE3o.js → Dialog-B_s-w66_.js} +1 -1
- package/dist/{Dialog-D4V2ZnuS.js → Dialog-BtPktuiy.js} +3 -1
- package/dist/{DialogHeader-D1sgjPC7.js → DialogHeader-Hk419KW1.js} +4 -4
- 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-CaZF_-lH.js → Drawer-DoQ9hjKz.js} +2 -2
- package/dist/DropdownMenu/index.d.ts +2 -2
- package/dist/DropdownMenu/index.js +3 -3
- package/dist/{DropdownMenu-B3R5WLsl.js → DropdownMenu-B2iga1fe.js} +18 -13
- package/dist/{DropdownMenu-BjE_cTDM.js → DropdownMenu-BF2Z5T4h.js} +9 -9
- package/dist/{DropdownMenuRadioItem.vue-z0XU7pZS.d.ts → DropdownMenuRadioItem.vue-D455cIQQ.d.ts} +1 -1
- package/dist/EmptyState/index.js +1 -1
- package/dist/{EmptyState-BQrzgh2f.js → EmptyState-v1cvHKav.js} +2 -2
- package/dist/Field/index.d.ts +2 -2
- package/dist/Field/index.js +3 -3
- package/dist/{Field-DLg-trP2.js → Field-if5a58LO.js} +2 -2
- package/dist/{FieldIcon-CxTnEb4Y.js → FieldIcon-DMtfe1Ne.js} +1 -1
- package/dist/{FieldInfoTip-D5IOQrVA.js → FieldInfoTip-BJAaKJjM.js} +2 -2
- package/dist/{FieldLabel-D5_Pap_W.js → FieldLabel-C-IaUcP4.js} +3 -3
- package/dist/FieldStatus/index.d.ts +1 -1
- package/dist/FieldStatus/index.js +1 -1
- package/dist/{FieldStatus-D6Vo_dU5.js → FieldStatus-DSUCli4W.js} +1 -1
- package/dist/FileInput/index.d.ts +1 -1
- package/dist/FileInput/index.js +1 -1
- package/dist/{FileInput-CKYpJtuU.js → FileInput-0zBWfO8h.js} +9 -9
- package/dist/Grid/index.d.ts +1 -1
- package/dist/Grid/index.js +1 -1
- package/dist/{Grid-D1onTzyC.js → Grid-C0mp7fha.js} +1 -1
- package/dist/Heading/index.d.ts +1 -1
- package/dist/Heading/index.js +1 -1
- package/dist/Heading-C10qO8wg.js +114 -0
- package/dist/HoverCard/index.d.ts +1 -1
- package/dist/HoverCard/index.js +1 -1
- package/dist/{HoverCard-B9uadAzT.js → HoverCard-CLcbBLBN.js} +4 -3
- package/dist/Icon/index.d.ts +4 -4
- package/dist/Icon/index.js +4 -2
- package/dist/Icon/plugin.js +1 -1
- package/dist/Icon-B2aULLnn.js +15 -0
- package/dist/{Icon-CU3412Fe.js → Icon-BCHo7W0x.js} +48 -86
- package/dist/IconButton/index.d.ts +1 -1
- package/dist/IconButton/index.js +1 -1
- package/dist/{IconButton-B6AQLlx9.js → IconButton-Crtfruc0.js} +1 -1
- package/dist/Indicator/index.d.ts +2 -2
- package/dist/Indicator/index.js +1 -1
- package/dist/InfoTip/index.d.ts +1 -1
- package/dist/InfoTip/index.js +1 -1
- package/dist/{InfoTip-BlOySTNC.js → InfoTip-DNQy7wqB.js} +3 -3
- package/dist/{InputClearButton-BbFXoxWi.js → InputClearButton-DhvxPkK6.js} +3 -3
- package/dist/InputGroup/index.d.ts +1 -1
- package/dist/InputGroup/index.js +2 -2
- package/dist/{InputGroup-BleRgc6W.js → InputGroup-B1kG0rBN.js} +42 -18
- package/dist/InternationalizationProvider/index.d.ts +1 -1
- package/dist/InternationalizationProvider/index.js +1 -1
- package/dist/{InternationalizationProvider-CWJDt7Qb.js → InternationalizationProvider-CUEIHCf4.js} +3 -3
- package/dist/{Item-X9wgYWoD.js → Item-Cfv4ALls.js} +29 -6
- package/dist/Kbd/index.d.ts +1 -1
- package/dist/Kbd/index.js +1 -1
- package/dist/{Kbd-CV3LO2Ge.js → Kbd-DyxKNYtE.js} +58 -30
- package/dist/Layout/index.js +2 -2
- package/dist/{Layout-mHcy28k7.js → Layout-OHKb6r7D.js} +8 -5
- package/dist/{LayoutPanel-DpbBk6rj.js → LayoutPanel-D-rpTtC-.js} +6 -3
- package/dist/Lightbox/index.js +1 -1
- package/dist/{Lightbox-DLZzT9un.js → Lightbox-B8uMFPOS.js} +96 -17
- package/dist/Link/index.d.ts +2 -2
- package/dist/Link/index.js +1 -1
- package/dist/{Link-Qhzs2lcO.js → Link-Kc2RQFHc.js} +59 -70
- package/dist/List/index.d.ts +1 -1
- package/dist/List/index.js +2 -2
- package/dist/{ListItem-CertehfW.js → ListItem-2evjQQ7n.js} +2 -2
- package/dist/Markdown/index.js +2 -2
- package/dist/{Markdown-DGTG02tI.js → Markdown-NVkHi_tk.js} +6 -6
- package/dist/{MediaTheme-CnSOALNj.js → MediaTheme-Bt7WBTkq.js} +1 -1
- package/dist/MetadataList/index.js +1 -1
- package/dist/{MetadataList-wOngshS5.js → MetadataList-4GnMi6s9.js} +1 -1
- package/dist/MobileNav/index.js +1 -1
- package/dist/{MobileNavToggle-C8KAzhRl.js → MobileNavToggle-TMDrnXfG.js} +2 -2
- package/dist/MoreMenu/index.d.ts +1 -1
- package/dist/MoreMenu/index.js +1 -1
- package/dist/{MoreMenu-B_NLxMJW.js → MoreMenu-CpGEXWCd.js} +10 -10
- package/dist/MultiSelector/index.d.ts +1 -1
- package/dist/MultiSelector/index.js +1 -1
- package/dist/{MultiSelector-B0TQuJ5d.js → MultiSelector-Baca6xNx.js} +17 -16
- package/dist/{NavDisclosure-BbRWuyhq.js → NavDisclosure-DG4jls5z.js} +1 -1
- package/dist/{NavHeadingSurface-B2HkXx6S.js → NavHeadingSurface-j2gzMVKt.js} +3 -3
- package/dist/NavItem/index.d.ts +1 -1
- package/dist/NavItem/index.js +1 -1
- package/dist/{NavItem-DfHMmSsw.js → NavItem-BZLN0U5a.js} +1 -1
- package/dist/NavMenu/index.js +3 -3
- package/dist/{NavMenu-mZVfqNxt.js → NavMenu-t7WN2bcq.js} +1 -1
- package/dist/{NavMenuItem-DkfXIdxs.js → NavMenuItem-DIMQohIa.js} +2 -2
- package/dist/NumberInput/index.d.ts +1 -1
- package/dist/NumberInput/index.js +1 -1
- package/dist/{NumberInput-DEv4_fDj.js → NumberInput-BBFGZ4Fg.js} +27 -17
- package/dist/Outline/index.js +1 -1
- package/dist/{Outline-Bbu16_MT.js → Outline-BgDOI3ar.js} +3 -3
- package/dist/OverflowList/index.d.ts +1 -1
- package/dist/OverflowList/index.js +1 -1
- package/dist/{OverflowList-CjIOYKLM.js → OverflowList-D4fC5s_q.js} +3 -3
- package/dist/Pagination/index.d.ts +1 -1
- package/dist/Pagination/index.js +1 -1
- package/dist/{Pagination-Bcq0T9qo.js → Pagination-Do_MIlo4.js} +16 -4
- package/dist/Popover/index.d.ts +1 -1
- package/dist/Popover/index.js +1 -1
- package/dist/{Popover-9Xt2lYdo.js → Popover-Bd93LlDd.js} +7 -7
- package/dist/PowerSearch/index.d.ts +1 -1
- package/dist/PowerSearch/index.js +1 -1
- package/dist/{PowerSearch-DXz85xcx.js → PowerSearch-DyqItMHo.js} +111 -42
- package/dist/ProgressBar/index.d.ts +1 -1
- package/dist/ProgressBar/index.js +1 -1
- package/dist/{ProgressBar-Dt5AS0GY.js → ProgressBar-gsm2A_cR.js} +1 -1
- package/dist/Radio/index.d.ts +1 -1
- package/dist/Radio/index.js +1 -1
- package/dist/{RadioGroup-B2lYTCeV.js → RadioGroup-Dzp4qSgm.js} +5 -5
- package/dist/RadioList/index.d.ts +1 -1
- package/dist/RadioList/index.js +1 -1
- package/dist/{RadioList-CieZtXzY.js → RadioList-CAIgB1j_.js} +1 -1
- package/dist/Resizable/index.d.ts +1 -1
- package/dist/Resizable/index.js +1 -1
- package/dist/{ResizeHandle-uBJj4W1M.js → ResizeHandle-GAmiHb0-.js} +2 -2
- package/dist/ScrollableArea/index.d.ts +1 -1
- package/dist/SegmentedControl/index.js +1 -1
- package/dist/{SegmentedControl-BmDn1avo.js → SegmentedControl-Bs74LlvS.js} +3 -2
- package/dist/SelectableCard/index.d.ts +1 -1
- package/dist/SelectableCard/index.js +1 -1
- package/dist/{SelectableCard-2a2gsxys.js → SelectableCard-BFCwgtWf.js} +12 -7
- package/dist/Selector/index.d.ts +1 -1
- package/dist/Selector/index.js +1 -1
- package/dist/{Selector-CgrXQtte.js → Selector-B9lINQRM.js} +15 -13
- package/dist/SideNav/index.d.ts +1 -1
- package/dist/SideNav/index.js +1 -1
- package/dist/{SideNav-DW4jXGp5.js → SideNav-DzZ12DIq.js} +8 -8
- package/dist/Slider/index.d.ts +1 -1
- package/dist/Slider/index.js +1 -1
- package/dist/{Slider-CEhy-D-R.js → Slider-Cuk2ul9w.js} +4 -4
- package/dist/Spinner/index.js +1 -1
- package/dist/{Spinner-CTWLR75x.js → Spinner-ke63bQPv.js} +1 -1
- package/dist/StatusDot/index.js +1 -1
- package/dist/{StatusDot-Bu_nCu0I.js → StatusDot-DF5wK42f.js} +1 -1
- package/dist/Stepper/index.js +1 -1
- package/dist/{Stepper-DVXisudw.js → Stepper-C68f_iJG.js} +3 -3
- package/dist/Switch/index.d.ts +1 -1
- package/dist/Switch/index.js +1 -1
- package/dist/{Switch-DXShvaDA.js → Switch-bnxiN6Qe.js} +4 -4
- package/dist/TabList/index.d.ts +1 -1
- package/dist/TabList/index.js +1 -1
- package/dist/{TabList-Bo4pjQhj.js → TabList-8dlO0Ws6.js} +13 -8
- package/dist/Table/index.d.ts +1 -1
- package/dist/Table/index.js +1 -1
- package/dist/{Table-Bd8BQ8X_.js → Table-j_DCDbcI.js} +107 -49
- package/dist/Text/index.d.ts +2 -2
- package/dist/Text/index.js +3 -2
- package/dist/{Text-Wk-iDAzh.js → Text-WB-fpFne.js} +38 -29
- package/dist/TextArea/index.d.ts +1 -1
- package/dist/TextArea/index.js +1 -1
- package/dist/{TextArea-8bifudmD.js → TextArea-Bzz_KcKT.js} +11 -11
- package/dist/TextInput/index.d.ts +1 -1
- package/dist/TextInput/index.js +1 -1
- package/dist/{TextInput-Bb25yDd0.js → TextInput-givkH9HQ.js} +22 -20
- package/dist/Theme/index.d.ts +2 -2
- package/dist/Theme/index.js +2 -2
- package/dist/{Theme-D7_fQWgb.js → Theme-BQe--DY6.js} +42 -9
- package/dist/Thumbnail/index.js +1 -1
- package/dist/{Thumbnail-CYVlnYws.js → Thumbnail-CZOWP5HN.js} +42 -14
- package/dist/{TimeField-dDDrUtI4.js → TimeField-ByoS5s_I.js} +8 -8
- package/dist/TimeInput/index.d.ts +1 -1
- package/dist/TimeInput/index.js +1 -1
- package/dist/{TimeInput-BvGVUfWy.js → TimeInput-D9kvMQso.js} +7 -5
- package/dist/Timer/index.js +1 -1
- package/dist/{Timer-DL_MPa_h.js → Timer-BD2gSoQ3.js} +1 -1
- package/dist/Timestamp/index.d.ts +1 -1
- package/dist/Timestamp/index.js +1 -1
- package/dist/{Timestamp-CJSVY4tS.js → Timestamp-CEdNhKc5.js} +17 -13
- package/dist/Toast/index.js +1 -1
- package/dist/{Toast-cXs5Cbr4.js → Toast-CnZrcU-G.js} +5 -5
- package/dist/ToggleButton/index.d.ts +1 -1
- package/dist/ToggleButton/index.js +1 -1
- package/dist/{ToggleButton-DFiJDsOV.js → ToggleButton-BMn4yJXe.js} +27 -8
- package/dist/Token/index.js +1 -1
- package/dist/{Token-BJDLztV6.js → Token-DWCDMawn.js} +101 -28
- package/dist/Tokenizer/index.d.ts +1 -1
- package/dist/Tokenizer/index.js +1 -1
- package/dist/{Tokenizer-yz0873oG.js → Tokenizer-R0eC1BOk.js} +93 -10
- package/dist/Toolbar/index.d.ts +1 -1
- package/dist/Toolbar/index.js +1 -1
- package/dist/{Toolbar-D5UI1JLe.js → Toolbar-BH_E0F0G.js} +4 -1
- package/dist/Tooltip/index.d.ts +1 -1
- package/dist/Tooltip/index.js +2 -2
- package/dist/{Tooltip-BfKegFfq.js → Tooltip-CGHpFMnc.js} +1 -1
- package/dist/TopNav/index.d.ts +1 -1
- package/dist/TopNav/index.js +1 -1
- package/dist/{TopNav-CWksqYD8.js → TopNav-DHunql9h.js} +7 -7
- package/dist/TreeList/index.d.ts +1 -1
- package/dist/TreeList/index.js +1 -1
- package/dist/{TreeList-tcEjVfb0.js → TreeList-Dg5gtkOu.js} +24 -17
- package/dist/Typeahead/index.d.ts +1 -1
- package/dist/Typeahead/index.js +2 -2
- package/dist/{Typeahead-ClidGB0O.js → Typeahead-BkmCC6DX.js} +52 -27
- package/dist/{TypeaheadMenu-Bu9HO-wZ.js → TypeaheadMenu-CFeJCv-6.js} +1 -1
- package/dist/componentIcons-CFr2L6o3.js +106 -0
- package/dist/composables/index.d.ts +2 -2
- package/dist/composables/index.js +13 -11
- package/dist/{composables-BWDrzi3J.js → composables-DqJzanJ5.js} +5 -24
- package/dist/context-Bg7eSJ47.js +17 -0
- package/dist/{context-BLSiTojH.js → context-CV6TrhJY.js} +57 -3
- package/dist/context-CZP3jfy-.js +125 -0
- package/dist/{context-Bv6lAoqu.js → context-CjX2RSDn.js} +14 -2
- package/dist/devBuild-G249YcdZ.js +17 -0
- package/dist/{fieldParts--SyRZVQG.js → fieldParts-CDOlBdy6.js} +2 -2
- package/dist/{index-CM8KfpBL.d.ts → index--uIQXVJ7.d.ts} +2 -2
- package/dist/{index-CL8JvxHW.d.ts → index-B3yTdknp.d.ts} +1 -1
- package/dist/{index-rszZajcw.d.ts → index-B449gOMC.d.ts} +2 -2
- package/dist/{index-B3PTchxx.d.ts → index-B7brdDVR.d.ts} +5 -5
- package/dist/{index-BO9TY87G.d.ts → index-BOCb89V9.d.ts} +3 -3
- package/dist/{index-Gnewu6-J.d.ts → index-BPyRH3WL.d.ts} +1 -1
- package/dist/{index-DEQ5cnUV.d.ts → index-BTljzczH.d.ts} +4 -1
- package/dist/{index-f3d9cVtj.d.ts → index-BU78NOP-.d.ts} +1 -1
- package/dist/{index-BfQ85cS8.d.ts → index-BZuEYd9y.d.ts} +1 -1
- package/dist/{index-D_K1wfRa.d.ts → index-BfSZhAVv.d.ts} +2 -2
- package/dist/{index-CFm1rPma.d.ts → index-BjbPK91B.d.ts} +1 -1
- package/dist/{index-C3f1zsJR.d.ts → index-BngdKVro.d.ts} +1 -1
- package/dist/{index-RW8kvEwf.d.ts → index-BnqDF_AX.d.ts} +11 -6
- package/dist/{index-Be7N3B5F.d.ts → index-BqEPgwku.d.ts} +2 -2
- package/dist/{index-DxxudRgB.d.ts → index-C16d2Fc4.d.ts} +1 -1
- package/dist/{index-D97pQbua.d.ts → index-C89cIh4E.d.ts} +3 -5
- package/dist/{index-D05JGsT3.d.ts → index-C8wfe0Mr.d.ts} +1 -1
- package/dist/{index-IvAfdGCC.d.ts → index-CAoenU4T.d.ts} +1 -1
- package/dist/{index-BaxM-pFP.d.ts → index-CM2L3SUw.d.ts} +6 -4
- package/dist/{index-Bgk1Rj2A.d.ts → index-CTjkJP4x.d.ts} +1 -1
- package/dist/{index-Bo-ofFyg.d.ts → index-CbNLiaWw.d.ts} +2 -2
- package/dist/{index-YKCx03zD.d.ts → index-CdvmnNMH.d.ts} +1 -1
- package/dist/{index-BMCjAlq6.d.ts → index-CfPGC9aW.d.ts} +1 -1
- package/dist/index-CtYlR9Cu.d.ts +46 -0
- package/dist/{index--tm6L1ot.d.ts → index-Cun6cXGP.d.ts} +1 -1
- package/dist/{index-C9gAlDt_.d.ts → index-CvquEEGw.d.ts} +8 -2
- package/dist/{index-QWh122EV.d.ts → index-D57GW53K.d.ts} +1 -1
- package/dist/{index-DX4HQToB.d.ts → index-D6pP-H_N.d.ts} +1 -1
- package/dist/{index-dcT6zeY_.d.ts → index-DCU6dy7n.d.ts} +25 -5
- package/dist/{index-DqaYENaT.d.ts → index-DFDadgys.d.ts} +68 -68
- package/dist/{index-DEm3kRBO.d.ts → index-DN1RqxjP.d.ts} +1 -1
- package/dist/{index-BzZC2Y7c.d.ts → index-DTfA4uE3.d.ts} +1 -1
- package/dist/{index-BZchpRgm.d.ts → index-DZKv1WNB.d.ts} +2 -2
- package/dist/{index-BUZDSd-n.d.ts → index-Dc52pmSr.d.ts} +4 -2
- package/dist/{index-uqEqPcmR.d.ts → index-DhMCql2U.d.ts} +1 -1
- package/dist/{index-O9y23OPJ.d.ts → index-DneQgJfI.d.ts} +1 -1
- package/dist/{index-Dj1_1t3j.d.ts → index-IFFGXlhq.d.ts} +1 -1
- package/dist/{index-DaXzQxos.d.ts → index-MEix_m1o.d.ts} +2 -2
- package/dist/{index-B1eCxBCY.d.ts → index-TXcNH86P.d.ts} +1 -1
- package/dist/{index-D21zdEgS.d.ts → index-Uh-ddE5F.d.ts} +1 -1
- package/dist/{index-BtrAhmSP.d.ts → index-fuztfDLA.d.ts} +10 -6
- package/dist/{index-BRXgpLcd.d.ts → index-mJ_aqK5M.d.ts} +3 -3
- package/dist/{index-3t5RAfNP.d.ts → index-mkbGYz8f.d.ts} +2 -2
- package/dist/{index-BEZ4ezJk.d.ts → index-wY6dKz6c.d.ts} +2 -2
- package/dist/{index-Dacg7XTH.d.ts → index-wkeCkhTi.d.ts} +16 -6
- package/dist/index.d.ts +53 -53
- package/dist/index.js +134 -130
- package/dist/layerSurfacePress-C3PjPpJP.js +29 -0
- package/dist/{loadCatalog-85MyL2bm.js → loadCatalog-Bulk4H7U.js} +2 -2
- package/dist/{loadCatalog-DSRSkHnY.d.ts → loadCatalog-D_uf2uX1.d.ts} +36 -0
- package/dist/locale/index.d.ts +2 -2
- package/dist/locale/index.js +4 -4
- package/dist/{locale-C7RSY-JG.js → locale-BA52q_fh.js} +1 -1
- package/dist/pressFeedback-Bwwpex9q.js +578 -0
- package/dist/{registry-C7OZb0PJ.js → registry-fNY3jasS.js} +23 -4
- package/dist/{searchResultMessage-T4H3r8Vz.js → searchResultMessage-CFmIy2Da.js} +2 -2
- package/dist/semantic-CXHSMwPK.d.ts +118 -0
- package/dist/{sharedResizeObserver-9EFWnSWH.js → sharedResizeObserver-BekhnB3E.js} +5 -1
- package/dist/slotContent-CNWOrGOr.js +14 -0
- package/dist/{slug-DAK6hdbr.js → slug-D6ln5PTq.js} +3 -1
- package/dist/strayClick-CY-_ImKv.js +60 -0
- package/dist/textClampContext-o3-nLErq.js +15 -0
- package/dist/textDirection-D4ObTwbB.js +32 -0
- package/dist/themeIcons-CqGF0fwW.js +128 -0
- package/dist/tooltipTriggerRules-Bg4tG8w2.js +53 -0
- package/dist/{types-CsqwQkf1.d.ts → types-Bq4Yl6CS.d.ts} +68 -7
- package/dist/{types-Bb7OGivY.d.ts → types-BwVJBE-G.d.ts} +1 -1
- package/dist/{types-C5GQ2KCK.d.ts → types-Dcai2Icw.d.ts} +55 -1
- package/dist/{types-DnrU3HYQ.d.ts → types-hB0M54I7.d.ts} +1 -1
- package/dist/unicodeRegExp-B7yQnpFC.js +14 -0
- package/dist/{upstreamMap-CZUPxbc9.js → upstreamMap-DrkVNtXW.js} +2 -0
- package/dist/useActionGroupTracking-BncJjk1A.js +131 -0
- package/dist/{useAnchoredListbox-6t5zSSz1.js → useAnchoredListbox-9Gn8asBR.js} +3 -2
- package/dist/useCoarsePointer-GItEMrjX.js +21 -0
- package/dist/{useDevWarning-DznOpOHT.js → useDevWarning-B2fsk2B-.js} +1 -4
- package/dist/{usePositionedLayer-psKf3ano.js → useDismiss-0-Z-9D0A.js} +52 -52
- package/dist/{useFileSelection-BPtaegqK.js → useFileSelection-B44UpbvF.js} +14 -4
- package/dist/{useIndicator-BvF_KY9S.js → useIndicator--9mGGlT2.js} +2 -2
- package/dist/{useInputContainer-CLcYrby4.js → useInputContainer-BpLtCA-U.js} +1 -1
- package/dist/{useInputStatusIcon-BSVFtRQG.js → useInputStatusIcon-DCnx00BM.js} +2 -2
- package/dist/{useLayer-Byjda3dD.js → useLayer-CED-g4Q2.js} +1 -1
- package/dist/{useMenuDrillIn-C36Z89W3.js → useMenuDrillIn-C5eJCuO1.js} +2 -2
- package/dist/{useMenuPress-8foxY8z4.js → useMenuPress-BLPwY_m1.js} +2 -59
- package/dist/usePressFeedback-Bcjsw9vv.js +49 -0
- package/dist/{useTooltip-BKsCTWdb.js → useTooltip-D8Tq7-yd.js} +36 -22
- package/dist/{useTranslator-BDUOzbP_.js → useTranslator-Q85hi4qz.js} +2 -2
- package/dist/useTruncation-C4pdlaXa.js +135 -0
- package/dist/useTruncationTooltip-BNk2xslw.js +106 -0
- package/dist/utils/index.js +1 -1
- package/dist/{utils-ClVseK2w.js → utils-BTkg5Ie9.js} +7 -2
- package/locales/en.json +8 -0
- package/package.json +1 -1
- package/styles/alert-dialog.css +19 -0
- package/styles/avatar.css +18 -3
- package/styles/badge.css +20 -2
- package/styles/banner.css +6 -0
- package/styles/button-group.css +38 -2
- package/styles/button.css +76 -4
- package/styles/calendar.css +34 -0
- package/styles/carousel.css +19 -11
- package/styles/chat.css +2 -0
- package/styles/checkbox-indicator.css +9 -9
- package/styles/checkbox-input.css +4 -1
- package/styles/citation.css +2 -1
- package/styles/clickable-card.css +19 -5
- package/styles/code.css +6 -0
- package/styles/context-menu.css +11 -0
- package/styles/dialog-header.css +2 -0
- package/styles/dialog.css +7 -0
- package/styles/dropdown-menu.css +11 -0
- package/styles/field.css +2 -0
- package/styles/heading.css +4 -0
- package/styles/hover-card.css +2 -0
- package/styles/icon.css +18 -12
- package/styles/input-group.css +1 -0
- package/styles/kbd.css +2 -0
- package/styles/layer.css +2 -0
- package/styles/lightbox.css +78 -0
- package/styles/link.css +25 -1
- package/styles/list.css +10 -1
- package/styles/metadata-list.css +1 -1
- package/styles/more-menu.css +6 -0
- package/styles/popover.css +7 -0
- package/styles/pressable.css +7 -0
- package/styles/radio-indicator.css +21 -4
- package/styles/slider.css +2 -0
- package/styles/switch.css +2 -1
- package/styles/table.css +25 -1
- package/styles/text.css +8 -0
- package/styles/thumbnail.css +25 -0
- package/styles/toast.css +2 -0
- package/styles/toggle-button.css +17 -0
- package/styles/token.css +14 -9
- package/styles/toolbar.css +19 -0
- package/dist/Badge-CjDQPF5g.js +0 -30
- package/dist/Heading-D0zL1j5T.js +0 -99
- package/dist/context-B6UElI5X.js +0 -5
- package/dist/context-Cws_tXTr.js +0 -7
- package/dist/context-IvbU9c3T.js +0 -8
- package/dist/index-LySSG_PR.d.ts +0 -27
- package/dist/semantic-BF_AjLvk.d.ts +0 -57
- package/dist/useClickableContainer-CdGp_Cev.js +0 -112
- package/dist/usePressFeedback-Dhnfc3ee.js +0 -336
- package/dist/useTruncation-C02rA1-c.js +0 -102
- package/dist/{useRestoreFocus-XEKs5-gp.js → useRestoreFocus-CEG0n2AK.js} +1 -1
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { o as IconSize, r as IconName, u as IconVariant } from "./types-Dcai2Icw.js";
|
|
2
|
+
//#region src/Icon/componentIcons.d.ts
|
|
3
|
+
/**
|
|
4
|
+
* The themeable icons components own, by slot. A slot names why an icon is
|
|
5
|
+
* in one component (`<component-kebab>-<role>`), not its artwork. A theme
|
|
6
|
+
* maps a slot to a shared icon name through `defineTheme({ componentIcons })`.
|
|
7
|
+
*
|
|
8
|
+
* The value is `true` for a stateless slot, or the state the component
|
|
9
|
+
* passes to a theme's slot function. A package adds its own slots by
|
|
10
|
+
* augmenting this interface.
|
|
11
|
+
*/
|
|
12
|
+
interface ComponentIconSlotMap {
|
|
13
|
+
/** CodeBlock's copy button. `copied` is true while the copied feedback shows. */
|
|
14
|
+
'code-block-copy': {
|
|
15
|
+
readonly copied: boolean;
|
|
16
|
+
};
|
|
17
|
+
/** A Timestamp hover card row's copy button. */
|
|
18
|
+
'timestamp-copy': {
|
|
19
|
+
readonly copied: boolean;
|
|
20
|
+
};
|
|
21
|
+
/** A sortable Table column's sort indicator, by the column's sort direction. */
|
|
22
|
+
'table-sort-indicator': {
|
|
23
|
+
readonly direction: 'ascending' | 'descending' | 'none';
|
|
24
|
+
};
|
|
25
|
+
/** A Table row's expansion toggle, by whether the row is expanded. */
|
|
26
|
+
'table-row-expand': {
|
|
27
|
+
readonly expanded: boolean;
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
/** A slot name from the augmentable {@link ComponentIconSlotMap}. */
|
|
31
|
+
type ComponentIconSlotName = keyof ComponentIconSlotMap & string;
|
|
32
|
+
/**
|
|
33
|
+
* A partial request for a slot's icon. A field left out keeps what the
|
|
34
|
+
* component would draw. `icon: null` hides the icon. `size` changes only the
|
|
35
|
+
* icon, never the control around it.
|
|
36
|
+
*/
|
|
37
|
+
interface ComponentIconRequest<Variant extends string = IconVariant> {
|
|
38
|
+
readonly icon?: IconName | null;
|
|
39
|
+
readonly variant?: Variant;
|
|
40
|
+
readonly size?: IconSize;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* A theme's value for a slot: a shared icon name, `null` to hide the icon, a
|
|
44
|
+
* partial request, or, for a slot with state, a pure synchronous function of
|
|
45
|
+
* that state. A function that returns `null` hides the icon; one that
|
|
46
|
+
* returns `undefined` changes nothing.
|
|
47
|
+
*/
|
|
48
|
+
type ComponentIconValue<State, Variant extends string = IconVariant> = IconName | null | ComponentIconRequest<Variant> | ((state: Readonly<State>) => ComponentIconRequest<Variant> | null | undefined);
|
|
49
|
+
/** A theme's `componentIcons`, keyed by slot. */
|
|
50
|
+
type ComponentIconMap<Variant extends string = IconVariant> = { [Slot in ComponentIconSlotName]?: ComponentIconSlotMap[Slot] extends true ? IconName | null | ComponentIconRequest<Variant> : ComponentIconValue<ComponentIconSlotMap[Slot], Variant>; };
|
|
51
|
+
/** The static view of `componentIcons`: names, `null`, and requests. Function slots are left out. */
|
|
52
|
+
type ComponentIconStaticMap = Partial<Record<ComponentIconSlotName, IconName | null | ComponentIconRequest<string>>>;
|
|
53
|
+
/** A stored slot value, function included. */
|
|
54
|
+
type StoredComponentIconValue = IconName | null | ComponentIconRequest<string> | ((state: never) => ComponentIconRequest<string> | null | undefined);
|
|
55
|
+
/** What a component draws for a slot when the theme maps nothing. */
|
|
56
|
+
interface ResolvedComponentIcon {
|
|
57
|
+
readonly icon: IconName | null;
|
|
58
|
+
readonly variant?: string;
|
|
59
|
+
readonly size?: IconSize;
|
|
60
|
+
}
|
|
61
|
+
//#endregion
|
|
62
|
+
//#region src/Icon/semantic.d.ts
|
|
63
|
+
/**
|
|
64
|
+
* Semantic name to Iconify id.
|
|
65
|
+
*
|
|
66
|
+
* The names describe the job (close, search, check). The id is the drawing.
|
|
67
|
+
* Lucide matches the upstream themes. A theme replaces any of these, or adds
|
|
68
|
+
* its own keys, through `defineTheme({ icons })`.
|
|
69
|
+
*
|
|
70
|
+
* The drawing is used only after that collection is registered. Until then
|
|
71
|
+
* the built-in glyph stays, so a missing collection does not blank the icon.
|
|
72
|
+
*
|
|
73
|
+
* `upload` is its own name, not `arrowUp`: a theme can redraw the upload
|
|
74
|
+
* affordance without changing sort arrows or the send button.
|
|
75
|
+
*/
|
|
76
|
+
declare const defaultSemanticIcons: {
|
|
77
|
+
readonly close: "lucide:x";
|
|
78
|
+
readonly chevronDown: "lucide:chevron-down";
|
|
79
|
+
readonly chevronLeft: "lucide:chevron-left";
|
|
80
|
+
readonly chevronRight: "lucide:chevron-right";
|
|
81
|
+
readonly chevronsLeft: "lucide:chevrons-left";
|
|
82
|
+
readonly chevronsRight: "lucide:chevrons-right";
|
|
83
|
+
readonly check: "lucide:check";
|
|
84
|
+
readonly success: "lucide:circle-check";
|
|
85
|
+
readonly error: "lucide:circle-x";
|
|
86
|
+
readonly warning: "lucide:triangle-alert";
|
|
87
|
+
readonly info: "lucide:info";
|
|
88
|
+
readonly calendar: "lucide:calendar";
|
|
89
|
+
readonly clock: "lucide:clock";
|
|
90
|
+
readonly externalLink: "lucide:external-link";
|
|
91
|
+
readonly menu: "lucide:menu";
|
|
92
|
+
readonly moreHorizontal: "lucide:ellipsis";
|
|
93
|
+
readonly search: "lucide:search";
|
|
94
|
+
readonly upload: "lucide:upload";
|
|
95
|
+
readonly arrowUp: "lucide:arrow-up";
|
|
96
|
+
readonly arrowDown: "lucide:arrow-down";
|
|
97
|
+
readonly arrowsUpDown: "lucide:arrow-up-down";
|
|
98
|
+
readonly funnel: "lucide:funnel";
|
|
99
|
+
readonly eyeSlash: "lucide:eye-off";
|
|
100
|
+
readonly viewColumns: "lucide:columns-3";
|
|
101
|
+
readonly copy: "lucide:copy";
|
|
102
|
+
readonly checkDouble: "lucide:check-check";
|
|
103
|
+
readonly wrench: "lucide:wrench";
|
|
104
|
+
readonly stop: "lucide:square";
|
|
105
|
+
readonly microphone: "lucide:mic";
|
|
106
|
+
readonly image: "lucide:image";
|
|
107
|
+
};
|
|
108
|
+
type SemanticIconMap = Readonly<Record<string, string>>;
|
|
109
|
+
/**
|
|
110
|
+
* The Iconify id for a semantic name.
|
|
111
|
+
*
|
|
112
|
+
* Theme entries win, including keys the package does not ship, such as a
|
|
113
|
+
* namespaced `numberInput:stepperDown`. An unknown name with no theme entry
|
|
114
|
+
* returns undefined, so a CSS class can still pass through `icon`.
|
|
115
|
+
*/
|
|
116
|
+
declare function resolveSemanticIcon(name: string | undefined, icons?: SemanticIconMap): string | undefined;
|
|
117
|
+
//#endregion
|
|
118
|
+
export { ComponentIconRequest as a, ComponentIconStaticMap as c, StoredComponentIconValue as d, ComponentIconMap as i, ComponentIconValue as l, defaultSemanticIcons as n, ComponentIconSlotMap as o, resolveSemanticIcon as r, ComponentIconSlotName as s, SemanticIconMap as t, ResolvedComponentIcon as u };
|
|
@@ -16,6 +16,10 @@ function getObserver() {
|
|
|
16
16
|
});
|
|
17
17
|
return observer;
|
|
18
18
|
}
|
|
19
|
+
/** Whether the shared observer already watches `element`. Internal. */
|
|
20
|
+
function isResizeObserved(element) {
|
|
21
|
+
return callbacks.has(element);
|
|
22
|
+
}
|
|
19
23
|
/**
|
|
20
24
|
* Observe an element's size via a shared ResizeObserver singleton.
|
|
21
25
|
*
|
|
@@ -84,4 +88,4 @@ function unobserveResize(element, callback) {
|
|
|
84
88
|
}
|
|
85
89
|
}
|
|
86
90
|
//#endregion
|
|
87
|
-
export {
|
|
91
|
+
export { observeResize as n, unobserveResize as r, isResizeObserved as t };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { t as isRenderable } from "./isRenderable-BnKHIqfd.js";
|
|
2
|
+
//#region src/composables/internal/slotContent.ts
|
|
3
|
+
/**
|
|
4
|
+
* 插槽这次渲染出来的东西算不算内容。
|
|
5
|
+
*
|
|
6
|
+
* 没传插槽、或者插槽只留下 `v-if` 的注释、空字符串、只有空白的文字、空 Fragment,都算没内容,
|
|
7
|
+
* 包着插槽的那层元素也就不该画出来;文字 `0` 和任何元素都算内容。
|
|
8
|
+
* 要在渲染时调用(模板里或渲染函数里),这样插槽里依赖的响应式数据变了会重新判断。
|
|
9
|
+
*/
|
|
10
|
+
function hasSlotContent(slot) {
|
|
11
|
+
return slot != null && isRenderable(slot());
|
|
12
|
+
}
|
|
13
|
+
//#endregion
|
|
14
|
+
export { hasSlotContent as t };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import { t as unicodeRegExp } from "./unicodeRegExp-B7yQnpFC.js";
|
|
1
2
|
//#region src/Markdown/slug.ts
|
|
3
|
+
const NON_SLUG_CHARACTERS = unicodeRegExp("[^\\p{Letter}\\p{Number}]+", "gu");
|
|
2
4
|
/** URL slug for a heading. Letters and numbers from any language are kept. */
|
|
3
5
|
function slugify(value) {
|
|
4
|
-
return value.trim().toLowerCase().replace(/['"]/g, "").replace(
|
|
6
|
+
return value.trim().toLowerCase().replace(/['"]/g, "").replace(NON_SLUG_CHARACTERS, "-").replace(/^-+|-+$/g, "");
|
|
5
7
|
}
|
|
6
8
|
/**
|
|
7
9
|
* `setup`, then `setup-1`, then `setup-2`. An empty slug becomes `section`.
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
let isModelActivation = false;
|
|
2
|
+
/**
|
|
3
|
+
* 按压模型派发的那次行激活是不是正在进行。只在那次派发的同步过程中为真,
|
|
4
|
+
* 所以把激活转交给里面链接的行,能分清这是模型的 click 还是浏览器多出来的那个。
|
|
5
|
+
*/
|
|
6
|
+
function isMenuPressActivation() {
|
|
7
|
+
return isModelActivation;
|
|
8
|
+
}
|
|
9
|
+
/** 在「模型激活」标记下执行一段同步代码。 */
|
|
10
|
+
function runAsMenuPressActivation(run) {
|
|
11
|
+
isModelActivation = true;
|
|
12
|
+
try {
|
|
13
|
+
run();
|
|
14
|
+
} finally {
|
|
15
|
+
isModelActivation = false;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
let swallower = null;
|
|
19
|
+
function disarm() {
|
|
20
|
+
if (swallower == null) return;
|
|
21
|
+
swallower.isArmed = false;
|
|
22
|
+
if (swallower.timer != null) {
|
|
23
|
+
clearTimeout(swallower.timer);
|
|
24
|
+
swallower.timer = null;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
function onWindowClickCapture(event) {
|
|
28
|
+
if (swallower == null || !swallower.isArmed) return;
|
|
29
|
+
if (event.detail === 0 || isModelActivation) return;
|
|
30
|
+
event.preventDefault();
|
|
31
|
+
event.stopImmediatePropagation();
|
|
32
|
+
disarm();
|
|
33
|
+
}
|
|
34
|
+
/** 布下吞 click 的口子。同一个文档只装一次监听。 */
|
|
35
|
+
function armStrayClick(doc) {
|
|
36
|
+
const view = doc.defaultView;
|
|
37
|
+
if (view == null) return;
|
|
38
|
+
if (swallower == null || swallower.doc !== doc) {
|
|
39
|
+
if (swallower != null) {
|
|
40
|
+
swallower.doc.defaultView?.removeEventListener("click", onWindowClickCapture, true);
|
|
41
|
+
swallower.doc.removeEventListener("pointerdown", disarm, true);
|
|
42
|
+
}
|
|
43
|
+
view.addEventListener("click", onWindowClickCapture, true);
|
|
44
|
+
doc.addEventListener("pointerdown", disarm, true);
|
|
45
|
+
swallower = {
|
|
46
|
+
doc,
|
|
47
|
+
isArmed: false,
|
|
48
|
+
timer: null
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
disarm();
|
|
52
|
+
swallower.isArmed = true;
|
|
53
|
+
swallower.timer = setTimeout(disarm, 400);
|
|
54
|
+
}
|
|
55
|
+
/** 撤掉已经布下的口子。卸载和测试里用。 */
|
|
56
|
+
function resetMenuPress() {
|
|
57
|
+
disarm();
|
|
58
|
+
}
|
|
59
|
+
//#endregion
|
|
60
|
+
export { runAsMenuPressActivation as i, isMenuPressActivation as n, resetMenuPress as r, armStrayClick as t };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { t as defineLayerScopedKey } from "./scopedProvide-C-Df7c15.js";
|
|
2
|
+
import { computed } from "vue";
|
|
3
|
+
//#region src/Text/textClampContext.ts
|
|
4
|
+
/**
|
|
5
|
+
* @file textClampContext.ts
|
|
6
|
+
* @output TextClampContext:在一段会截断行数的 Text 里面时为 true
|
|
7
|
+
* @position 内部;Text 提供,Link 读取
|
|
8
|
+
*
|
|
9
|
+
* 链接放在 `<Text :max-lines>` 里时,要变成普通的行内元素,截断才能从链接中间切开;
|
|
10
|
+
* 一个 inline-flex 的盒子是整块的,截断切不动它。
|
|
11
|
+
* 浮层里的内容已经不在那段文字里,所以进浮层就重置回 false。
|
|
12
|
+
*/
|
|
13
|
+
const TextClampContext = defineLayerScopedKey("astryx-text-clamp", computed(() => false));
|
|
14
|
+
//#endregion
|
|
15
|
+
export { TextClampContext as t };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { t as unicodeRegExp } from "./unicodeRegExp-B7yQnpFC.js";
|
|
2
|
+
//#region src/utils/textDirection.ts
|
|
3
|
+
/**
|
|
4
|
+
* @file textDirection.ts
|
|
5
|
+
* @input 组件里装调用方文字的那段内容(字符串、数字,或别的节点)
|
|
6
|
+
* @output textDirection:纯文字里一个从右往左的字母都没有时答 `'ltr'`,
|
|
7
|
+
* 其余情况答 `undefined`,让文字沿用页面方向
|
|
8
|
+
* @position 内部工具,不从包里导出。Badge、Token、InputGroupText 把它放在
|
|
9
|
+
* 装调用方文字的元素上,和 `unicode-bidi: isolate` 搭配使用
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* Unicode 双向算法里的强右到左字符(Bidi_Class `R` 和 `AL`)。在用的文字按名字列出
|
|
13
|
+
* (阿拉伯字母标记 U+061C 属于阿拉伯文),再加上右到左标记 U+200F;
|
|
14
|
+
* 两段码位范围覆盖辅助平面里的古代右到左文字和 Adlam。
|
|
15
|
+
*/
|
|
16
|
+
const STRONG_RTL = unicodeRegExp("[\\p{Script=Arabic}\\p{Script=Hebrew}\\p{Script=Mandaic}\\p{Script=Nko}\\p{Script=Samaritan}\\p{Script=Syriac}\\p{Script=Thaana}\\u200F\\u{10800}-\\u{10FFF}\\u{1E800}-\\u{1EFFF}]");
|
|
17
|
+
/** 文字里有没有任何一个强右到左字符。 */
|
|
18
|
+
function hasStrongRightToLeft(text) {
|
|
19
|
+
for (const character of text) if (STRONG_RTL.test(character)) return true;
|
|
20
|
+
return false;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* 右到左页面上,左到右文字里的弱字符和中性字符会被重排(`https://` 显示成 `//:https`,
|
|
24
|
+
* `+3` 显示成 `3+`)。所以没有右到左字母的纯文字按左到右排;有的就沿用页面方向,
|
|
25
|
+
* 这样以拉丁词开头的右到左标签仍然从右往左读。别的节点不管,由调用方在自己的内容上标方向。
|
|
26
|
+
*/
|
|
27
|
+
function textDirection(content) {
|
|
28
|
+
if (typeof content !== "string" && typeof content !== "number") return void 0;
|
|
29
|
+
return hasStrongRightToLeft(String(content)) ? void 0 : "ltr";
|
|
30
|
+
}
|
|
31
|
+
//#endregion
|
|
32
|
+
export { textDirection as t };
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
//#region src/Theme/context.ts
|
|
2
|
+
const themeContextKey = Symbol("astryx-theme");
|
|
3
|
+
/** Present when this component is already inside a Theme. */
|
|
4
|
+
const themeNestingKey = Symbol("astryx-theme-nesting");
|
|
5
|
+
const mediaThemeKey = Symbol("astryx-media-theme");
|
|
6
|
+
//#endregion
|
|
7
|
+
//#region src/Icon/semantic.ts
|
|
8
|
+
/**
|
|
9
|
+
* Semantic name to Iconify id.
|
|
10
|
+
*
|
|
11
|
+
* The names describe the job (close, search, check). The id is the drawing.
|
|
12
|
+
* Lucide matches the upstream themes. A theme replaces any of these, or adds
|
|
13
|
+
* its own keys, through `defineTheme({ icons })`.
|
|
14
|
+
*
|
|
15
|
+
* The drawing is used only after that collection is registered. Until then
|
|
16
|
+
* the built-in glyph stays, so a missing collection does not blank the icon.
|
|
17
|
+
*
|
|
18
|
+
* `upload` is its own name, not `arrowUp`: a theme can redraw the upload
|
|
19
|
+
* affordance without changing sort arrows or the send button.
|
|
20
|
+
*/
|
|
21
|
+
const defaultSemanticIcons = {
|
|
22
|
+
close: "lucide:x",
|
|
23
|
+
chevronDown: "lucide:chevron-down",
|
|
24
|
+
chevronLeft: "lucide:chevron-left",
|
|
25
|
+
chevronRight: "lucide:chevron-right",
|
|
26
|
+
chevronsLeft: "lucide:chevrons-left",
|
|
27
|
+
chevronsRight: "lucide:chevrons-right",
|
|
28
|
+
check: "lucide:check",
|
|
29
|
+
success: "lucide:circle-check",
|
|
30
|
+
error: "lucide:circle-x",
|
|
31
|
+
warning: "lucide:triangle-alert",
|
|
32
|
+
info: "lucide:info",
|
|
33
|
+
calendar: "lucide:calendar",
|
|
34
|
+
clock: "lucide:clock",
|
|
35
|
+
externalLink: "lucide:external-link",
|
|
36
|
+
menu: "lucide:menu",
|
|
37
|
+
moreHorizontal: "lucide:ellipsis",
|
|
38
|
+
search: "lucide:search",
|
|
39
|
+
upload: "lucide:upload",
|
|
40
|
+
arrowUp: "lucide:arrow-up",
|
|
41
|
+
arrowDown: "lucide:arrow-down",
|
|
42
|
+
arrowsUpDown: "lucide:arrow-up-down",
|
|
43
|
+
funnel: "lucide:funnel",
|
|
44
|
+
eyeSlash: "lucide:eye-off",
|
|
45
|
+
viewColumns: "lucide:columns-3",
|
|
46
|
+
copy: "lucide:copy",
|
|
47
|
+
checkDouble: "lucide:check-check",
|
|
48
|
+
wrench: "lucide:wrench",
|
|
49
|
+
stop: "lucide:square",
|
|
50
|
+
microphone: "lucide:mic",
|
|
51
|
+
image: "lucide:image"
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* The Iconify id for a semantic name.
|
|
55
|
+
*
|
|
56
|
+
* Theme entries win, including keys the package does not ship, such as a
|
|
57
|
+
* namespaced `numberInput:stepperDown`. An unknown name with no theme entry
|
|
58
|
+
* returns undefined, so a CSS class can still pass through `icon`.
|
|
59
|
+
*/
|
|
60
|
+
function resolveSemanticIcon(name, icons) {
|
|
61
|
+
if (name == null || name === "") return void 0;
|
|
62
|
+
const override = icons?.[name];
|
|
63
|
+
if (override) return override;
|
|
64
|
+
return defaultSemanticIcons[name];
|
|
65
|
+
}
|
|
66
|
+
//#endregion
|
|
67
|
+
//#region src/Icon/themeIcons.ts
|
|
68
|
+
/** The size every one-argument read uses: `useSemanticIcon`, `theme.icons`. */
|
|
69
|
+
const PUBLIC_ICON_REQUEST = { size: "md" };
|
|
70
|
+
/**
|
|
71
|
+
* The Iconify id a theme maps a name to for one request.
|
|
72
|
+
*
|
|
73
|
+
* - `undefined`: the theme does not map the name, so the built-in id stays.
|
|
74
|
+
* - `null`: a function entry answered with nothing, which is final.
|
|
75
|
+
* - a string: the id to draw.
|
|
76
|
+
*
|
|
77
|
+
* A function entry receives `variant` only when the active theme lists it
|
|
78
|
+
* and, for an inherited entry, the theme that defined the entry lists it too.
|
|
79
|
+
*/
|
|
80
|
+
function resolveThemeIcon(name, theme, request) {
|
|
81
|
+
const entry = theme?.iconEntries?.[name] ?? theme?.icons?.[name];
|
|
82
|
+
if (entry == null || entry === "") return void 0;
|
|
83
|
+
if (typeof entry === "string") return entry;
|
|
84
|
+
const active = theme?.iconVariants;
|
|
85
|
+
const owners = theme?.iconEntryVariants;
|
|
86
|
+
const defining = owners != null && Object.hasOwn(owners, name) ? owners[name] : active;
|
|
87
|
+
const { size, variant } = request;
|
|
88
|
+
const result = entry(variant !== void 0 && active?.includes(variant) === true && defining?.includes(variant) === true ? {
|
|
89
|
+
size,
|
|
90
|
+
variant
|
|
91
|
+
} : { size });
|
|
92
|
+
return typeof result === "string" && result !== "" ? result : null;
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* The id view of a theme's entries: each function read at `md`. An entry
|
|
96
|
+
* that answers nothing at `md` is left out. Entries without a function come
|
|
97
|
+
* back as the same object.
|
|
98
|
+
*/
|
|
99
|
+
function readThemeIconIds(entries) {
|
|
100
|
+
if (entries == null || !Object.values(entries).some((entry) => typeof entry === "function")) return entries;
|
|
101
|
+
const ids = {};
|
|
102
|
+
for (const [name, entry] of Object.entries(entries)) {
|
|
103
|
+
const id = typeof entry === "function" ? entry(PUBLIC_ICON_REQUEST) : entry;
|
|
104
|
+
if (typeof id === "string" && id !== "") ids[name] = id;
|
|
105
|
+
}
|
|
106
|
+
return ids;
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* For each function entry a theme inherits, the variant list of the theme
|
|
110
|
+
* that defined it, where that list is not the theme's own. Entries the theme
|
|
111
|
+
* defines itself use its own list and need no record.
|
|
112
|
+
*/
|
|
113
|
+
function resolveIconEntryVariants(entries, ownEntries, base, iconVariants) {
|
|
114
|
+
if (entries == null || base == null) return void 0;
|
|
115
|
+
const baseRecord = base.iconEntryVariants;
|
|
116
|
+
let record;
|
|
117
|
+
for (const [name, entry] of Object.entries(entries)) {
|
|
118
|
+
if (typeof entry !== "function" || ownEntries != null && Object.hasOwn(ownEntries, name)) continue;
|
|
119
|
+
const defining = baseRecord != null && Object.hasOwn(baseRecord, name) ? baseRecord[name] : base.iconVariants;
|
|
120
|
+
if (defining !== iconVariants) {
|
|
121
|
+
record ??= {};
|
|
122
|
+
record[name] = defining;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
return record;
|
|
126
|
+
}
|
|
127
|
+
//#endregion
|
|
128
|
+
export { resolveSemanticIcon as a, themeNestingKey as c, defaultSemanticIcons as i, resolveIconEntryVariants as n, mediaThemeKey as o, resolveThemeIcon as r, themeContextKey as s, readThemeIconIds as t };
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
//#region src/Tooltip/tooltipTriggerRules.ts
|
|
2
|
+
/** 自己带动作的触发器:`touchTrigger="auto"` 时轻点它不开提示。 */
|
|
3
|
+
const ACTION_TAGS = [
|
|
4
|
+
"A",
|
|
5
|
+
"BUTTON",
|
|
6
|
+
"INPUT",
|
|
7
|
+
"SELECT",
|
|
8
|
+
"TEXTAREA"
|
|
9
|
+
];
|
|
10
|
+
/** 不能输入文字的 input 类型。 */
|
|
11
|
+
const NON_TEXT_INPUT_TYPES = /* @__PURE__ */ new Set([
|
|
12
|
+
"button",
|
|
13
|
+
"checkbox",
|
|
14
|
+
"color",
|
|
15
|
+
"file",
|
|
16
|
+
"hidden",
|
|
17
|
+
"image",
|
|
18
|
+
"radio",
|
|
19
|
+
"range",
|
|
20
|
+
"reset",
|
|
21
|
+
"submit"
|
|
22
|
+
]);
|
|
23
|
+
function matchesFocusVisible(element) {
|
|
24
|
+
try {
|
|
25
|
+
return element.matches(":focus-visible");
|
|
26
|
+
} catch {
|
|
27
|
+
return false;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
function isActionTrigger(trigger) {
|
|
31
|
+
return ACTION_TAGS.includes(trigger.tagName);
|
|
32
|
+
}
|
|
33
|
+
function isTextEntryControl(element) {
|
|
34
|
+
const tag = element.tagName;
|
|
35
|
+
if (tag === "TEXTAREA") return true;
|
|
36
|
+
if (tag === "INPUT") return !NON_TEXT_INPUT_TYPES.has((element.getAttribute("type") ?? "text").toLowerCase());
|
|
37
|
+
return element instanceof HTMLElement && element.isContentEditable;
|
|
38
|
+
}
|
|
39
|
+
function isDisabled(element) {
|
|
40
|
+
return element.matches(":disabled") || element.getAttribute("aria-disabled") === "true";
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* 轻点落在触发器里的可输入控件上(文本框、多行文本框、可编辑区)时,只让它获得焦点,
|
|
44
|
+
* 不开也不关提示,免得提示盖住正要输入的文字。触发器本身就是输入框、或输入框已禁用时不算。
|
|
45
|
+
*/
|
|
46
|
+
function isTextEntryTap(trigger, tapEvent) {
|
|
47
|
+
const target = tapEvent?.target;
|
|
48
|
+
if (!(target instanceof Element)) return false;
|
|
49
|
+
for (let node = target; node != null && node !== trigger; node = node.parentElement) if (isTextEntryControl(node)) return !isDisabled(node) && trigger.contains(node);
|
|
50
|
+
return false;
|
|
51
|
+
}
|
|
52
|
+
//#endregion
|
|
53
|
+
export { isTextEntryTap as n, matchesFocusVisible as r, isActionTrigger as t };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { f as StoredIconEntry, p as ThemeIconEntries } from "./types-Dcai2Icw.js";
|
|
1
2
|
import { i as SyntaxThemeDefinition } from "./syntaxTheme-CwVEcVDk.js";
|
|
2
|
-
import { t as SemanticIconMap } from "./semantic-
|
|
3
|
+
import { c as ComponentIconStaticMap, d as StoredComponentIconValue, i as ComponentIconMap, t as SemanticIconMap } from "./semantic-CXHSMwPK.js";
|
|
3
4
|
import { Component } from "vue";
|
|
4
5
|
//#region src/Indicator/types.d.ts
|
|
5
6
|
/**
|
|
@@ -314,7 +315,26 @@ interface TypographyConfig {
|
|
|
314
315
|
heading?: TypographyRole;
|
|
315
316
|
code?: TypographyRole;
|
|
316
317
|
}
|
|
317
|
-
|
|
318
|
+
/**
|
|
319
|
+
* The icon variant names a base theme lists: exact for a theme from
|
|
320
|
+
* `defineTheme`, none without a base.
|
|
321
|
+
*/
|
|
322
|
+
type BaseThemeIconVariant<Base> = Base extends {
|
|
323
|
+
__iconVariant?(variant: infer Variant): void;
|
|
324
|
+
} ? Extract<Variant, string> : never;
|
|
325
|
+
/** A theme's own `iconVariants` when it sets the field, otherwise the inherited list. */
|
|
326
|
+
type ThemeIconVariant<IconVariants extends readonly string[] | undefined, Base> = [IconVariants] extends [readonly (infer Variant extends string)[]] ? Variant : BaseThemeIconVariant<Base>;
|
|
327
|
+
/**
|
|
328
|
+
* The same names, as a type `defineTheme` does not infer from: only
|
|
329
|
+
* `iconVariants` and `extends` decide them, never an entry's parameter type.
|
|
330
|
+
*/
|
|
331
|
+
type ThemeIconEntryVariant<IconVariants extends readonly string[] | undefined, Base> = [ThemeIconVariant<IconVariants, Base>][IconVariants extends unknown ? 0 : never];
|
|
332
|
+
/**
|
|
333
|
+
* Input to `defineTheme`. `IconVariants` is the theme's own `iconVariants`
|
|
334
|
+
* list and `Base` its `extends` theme; together they type the `variant` an
|
|
335
|
+
* icon entry function receives. `defineTheme` infers both.
|
|
336
|
+
*/
|
|
337
|
+
interface DefineThemeInput<IconVariants extends readonly string[] | undefined = readonly string[] | undefined, Base extends ThemeDefinition | undefined = ThemeDefinition | undefined> {
|
|
318
338
|
/** Theme name. Used as `data-astryx-theme`. */
|
|
319
339
|
name: string;
|
|
320
340
|
/** Semantic token overrides. These win over generated values, token by token. */
|
|
@@ -345,7 +365,7 @@ interface DefineThemeInput {
|
|
|
345
365
|
*/
|
|
346
366
|
components?: ComponentStyleMap;
|
|
347
367
|
/** Another theme to start from. This theme's own values win. */
|
|
348
|
-
extends?:
|
|
368
|
+
extends?: Base;
|
|
349
369
|
/** Syntax colors for code in this subtree, unless a SyntaxTheme is closer. */
|
|
350
370
|
syntax?: SyntaxThemeDefinition;
|
|
351
371
|
/** Extra tokens and component styles for content on a dark surface. */
|
|
@@ -376,8 +396,27 @@ interface DefineThemeInput {
|
|
|
376
396
|
*
|
|
377
397
|
* Entries replace the built-in map by name and merge with the theme this
|
|
378
398
|
* one extends. A name that is not listed keeps the built-in id.
|
|
399
|
+
*
|
|
400
|
+
* An entry may also be a pure synchronous function of `{ size, variant }`
|
|
401
|
+
* that returns an id. `Icon` calls it with the size it renders at, so the
|
|
402
|
+
* theme can pick artwork per size. Its result is final: `null` draws no
|
|
403
|
+
* glyph instead of falling back to the built-in id.
|
|
379
404
|
*/
|
|
380
|
-
icons?:
|
|
405
|
+
icons?: ThemeIconEntries<ThemeIconEntryVariant<IconVariants, Base>>;
|
|
406
|
+
/**
|
|
407
|
+
* The icon variant names this theme supports, listed once for the whole
|
|
408
|
+
* theme. Icon entry functions receive `variant` typed as these names.
|
|
409
|
+
* A list set here replaces the inherited one; an omitted list is inherited.
|
|
410
|
+
*/
|
|
411
|
+
iconVariants?: IconVariants;
|
|
412
|
+
/**
|
|
413
|
+
* Which shared icon a component's own icon role uses, by slot, such as
|
|
414
|
+
* `code-block-copy`. A value is a shared icon name, `null` to hide the
|
|
415
|
+
* icon, a partial `{ icon, variant, size }` request, or, for a slot with
|
|
416
|
+
* state, a pure function of that state that returns one. An entry
|
|
417
|
+
* replaces the inherited entry for the same slot.
|
|
418
|
+
*/
|
|
419
|
+
componentIcons?: ComponentIconMap<ThemeIconEntryVariant<IconVariants, Base>>;
|
|
381
420
|
/**
|
|
382
421
|
* Indicator graphics, replaced by name.
|
|
383
422
|
*
|
|
@@ -386,7 +425,7 @@ interface DefineThemeInput {
|
|
|
386
425
|
*/
|
|
387
426
|
indicators?: IndicatorRegistry;
|
|
388
427
|
}
|
|
389
|
-
interface ThemeDefinition {
|
|
428
|
+
interface ThemeDefinition<IconVariant extends string = string> {
|
|
390
429
|
name: string;
|
|
391
430
|
/** Token values already written as CSS, with the `--astryx-` prefix. */
|
|
392
431
|
tokens: Readonly<Record<string, string>>;
|
|
@@ -401,8 +440,30 @@ interface ThemeDefinition {
|
|
|
401
440
|
/** Component styles on a light MediaTheme surface. */
|
|
402
441
|
onLightComponents?: ComponentStyleMap;
|
|
403
442
|
syntax?: SyntaxThemeDefinition;
|
|
404
|
-
/**
|
|
443
|
+
/**
|
|
444
|
+
* Semantic icon overrides as ids. A function entry is read at size `md`.
|
|
445
|
+
* Absent when this theme does not set any.
|
|
446
|
+
*/
|
|
405
447
|
icons?: SemanticIconMap;
|
|
448
|
+
/** Icon entries with their functions. Only icon resolution reads it. */
|
|
449
|
+
iconEntries?: Readonly<Record<string, StoredIconEntry>>;
|
|
450
|
+
/** The icon variant names this theme lists, its own or inherited. */
|
|
451
|
+
iconVariants?: readonly string[];
|
|
452
|
+
/**
|
|
453
|
+
* The variant list of the theme that defined each inherited function
|
|
454
|
+
* entry, where it differs from `iconVariants`.
|
|
455
|
+
*/
|
|
456
|
+
iconEntryVariants?: Readonly<Record<string, readonly string[] | undefined>>;
|
|
457
|
+
/** Component icon slots: names, `null`, and static requests. Function slots are left out. */
|
|
458
|
+
componentIcons?: ComponentIconStaticMap;
|
|
459
|
+
/** Component icon slot values with their functions. Only slot resolution reads it. */
|
|
460
|
+
componentIconValues?: Readonly<Record<string, StoredComponentIconValue | undefined>>;
|
|
461
|
+
/**
|
|
462
|
+
* Type-only: the names in `iconVariants`, so a theme that extends this one
|
|
463
|
+
* types its icon entries by the list it inherits. Never set. Method
|
|
464
|
+
* syntax keeps themes with different lists assignable to each other.
|
|
465
|
+
*/
|
|
466
|
+
__iconVariant?(variant: IconVariant): void;
|
|
406
467
|
/** Indicator overrides. Absent when this theme does not set any. */
|
|
407
468
|
indicators?: IndicatorRegistry;
|
|
408
469
|
/**
|
|
@@ -450,4 +511,4 @@ interface MediaThemeProps {
|
|
|
450
511
|
fallback?: 'dark' | 'light';
|
|
451
512
|
}
|
|
452
513
|
//#endregion
|
|
453
|
-
export {
|
|
514
|
+
export { expandMotionScale as A, IndicatorProps as B, WidthBreakpointName as C, RadiusScaleConfig as D, expandTypeScale as E, IndicatorFamily as F, IndicatorSize as H, IndicatorFamilyMap as I, IndicatorMap as L, expandColorScale as M, CoreIndicatorName as N, expandRadiusScale as O, IndicatorComponent as P, IndicatorName as R, WIDTH_BREAKPOINT_NAMES as S, TypeScaleConfig as T, IndicatorState as U, IndicatorRegistry as V, ThemeAdaptationRule as _, StyleOverrides as a, ThemeAdaptationWidthCondition as b, ThemeMode as c, ThemeTokenValue as d, ThemeTokens as f, ThemeAdaptationCondition as g, DEFAULT_WIDTH_BREAKPOINTS as h, MediaThemeProps as i, ColorScaleConfig as j, MotionScaleConfig as k, ThemeProps as l, TypographyRole as m, DefineThemeInput as n, ThemeDefinition as o, TypographyConfig as p, MediaThemeMode as r, ThemeIconVariant as s, ComponentStyleMap as t, ThemeSurfaceInput as u, ThemeAdaptationTypographyConfig as v, WidthBreakpoints as w, ThemeAdaptations as x, ThemeAdaptationValue as y, IndicatorPosition as z };
|
|
@@ -1,4 +1,47 @@
|
|
|
1
1
|
import { Component, VNodeChild } from "vue";
|
|
2
|
+
//#region src/Icon/themeIcons.d.ts
|
|
3
|
+
/**
|
|
4
|
+
* Icon variant names an application uses. Astryx defines none: a theme lists
|
|
5
|
+
* the names it supports in `defineTheme({ iconVariants })`, and an
|
|
6
|
+
* application augments this map with the names it requests.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```ts
|
|
10
|
+
* declare module '@astryx-vue/core/Icon' {
|
|
11
|
+
* interface IconVariantMap {
|
|
12
|
+
* outline: true
|
|
13
|
+
* filled: true
|
|
14
|
+
* }
|
|
15
|
+
* }
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
interface IconVariantMap {}
|
|
19
|
+
/** A variant name from the augmentable {@link IconVariantMap}. */
|
|
20
|
+
type IconVariant = keyof IconVariantMap & string;
|
|
21
|
+
/**
|
|
22
|
+
* What `Icon` asks a function entry for: the size it renders at (explicit
|
|
23
|
+
* `size`, then the owning component's default, then `md`) and a variant the
|
|
24
|
+
* entry can receive, or none.
|
|
25
|
+
*/
|
|
26
|
+
interface IconRequest<Variant extends string = IconVariant> {
|
|
27
|
+
readonly size: IconSize;
|
|
28
|
+
readonly variant?: Variant;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* A theme's icon entry: an Iconify id, or a pure synchronous function of the
|
|
32
|
+
* {@link IconRequest} that returns one.
|
|
33
|
+
*
|
|
34
|
+
* A function reads only the request: no composables, DOM measurement,
|
|
35
|
+
* browser globals, or mutable state. Its result is final: `null`,
|
|
36
|
+
* `undefined`, or an empty string draws no glyph instead of falling back to
|
|
37
|
+
* the built-in id.
|
|
38
|
+
*/
|
|
39
|
+
type ThemeIconEntry<Variant extends string = IconVariant> = string | ((request: IconRequest<Variant>) => string | null | undefined);
|
|
40
|
+
/** A theme's icon entries by semantic name or namespaced key. */
|
|
41
|
+
type ThemeIconEntries<Variant extends string = IconVariant> = Readonly<Record<string, ThemeIconEntry<Variant>>>;
|
|
42
|
+
/** How resolution holds any entry, whatever variant names it was typed for. */
|
|
43
|
+
type StoredIconEntry = ThemeIconEntry<never>;
|
|
44
|
+
//#endregion
|
|
2
45
|
//#region src/Icon/types.d.ts
|
|
3
46
|
/**
|
|
4
47
|
* Icon sizes are expressed in `rem` so they scale with the root font-size.
|
|
@@ -111,6 +154,17 @@ interface IconProps {
|
|
|
111
154
|
* supplied by an owning astryx-vue component, then falls back to `md`.
|
|
112
155
|
*/
|
|
113
156
|
size?: IconSize;
|
|
157
|
+
/**
|
|
158
|
+
* Requests the nearest theme's alternate artwork for a semantic name, such
|
|
159
|
+
* as `filled`. Names come from the augmentable `IconVariantMap`.
|
|
160
|
+
*
|
|
161
|
+
* A theme's function entry receives the variant only when the theme lists
|
|
162
|
+
* it in `iconVariants` and, for an inherited entry, the theme that defined
|
|
163
|
+
* the entry lists it too. Otherwise the entry draws its normal artwork.
|
|
164
|
+
* `name`, a CSS class, a component, and the default slot ignore it, and it
|
|
165
|
+
* is never written to the DOM.
|
|
166
|
+
*/
|
|
167
|
+
variant?: IconVariant;
|
|
114
168
|
/**
|
|
115
169
|
* Accessible name for the icon.
|
|
116
170
|
*
|
|
@@ -132,4 +186,4 @@ interface IconSlots {
|
|
|
132
186
|
default?: () => VNodeChild;
|
|
133
187
|
}
|
|
134
188
|
//#endregion
|
|
135
|
-
export { IconRegistry as a, NamespacedIconName as c, IconProps as i, IconColor as n, IconSize as o, IconName as r, IconSlots as s, ExtendedIconName as t };
|
|
189
|
+
export { IconRegistry as a, NamespacedIconName as c, IconVariantMap as d, StoredIconEntry as f, IconProps as i, IconRequest as l, ThemeIconEntry as m, IconColor as n, IconSize as o, ThemeIconEntries as p, IconName as r, IconSlots as s, ExtendedIconName as t, IconVariant as u };
|