@persona/design-system 0.1.5-pre.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +461 -0
- package/LICENSE +77 -0
- package/README.md +9 -0
- package/dist/Action-B10lxofb.d.mts +35 -0
- package/dist/Action-uduFOh2m.d.cts +35 -0
- package/dist/Action.d.cts +2 -0
- package/dist/Action.d.mts +2 -0
- package/dist/Attribute.d.cts +107 -0
- package/dist/Attribute.d.mts +107 -0
- package/dist/AttributeGrid.d.cts +40 -0
- package/dist/AttributeGrid.d.mts +41 -0
- package/dist/Badge-BqLnhb4n.mjs +34 -0
- package/dist/Badge-BqLnhb4n.mjs.map +1 -0
- package/dist/Badge-BwAZD9BH.cjs +41 -0
- package/dist/Badge-BwAZD9BH.cjs.map +1 -0
- package/dist/Badge.d.cts +25 -0
- package/dist/Badge.d.mts +25 -0
- package/dist/Banner.d.cts +48 -0
- package/dist/Banner.d.mts +48 -0
- package/dist/Button-C_3p5Xfi.d.cts +101 -0
- package/dist/Button-DqDLGURJ.d.mts +101 -0
- package/dist/Button.d.cts +2 -0
- package/dist/Button.d.mts +2 -0
- package/dist/ButtonGroup.d.cts +20 -0
- package/dist/ButtonGroup.d.mts +20 -0
- package/dist/Calendar.d.cts +11 -0
- package/dist/Calendar.d.mts +12 -0
- package/dist/CalendarBase.d.mts +12 -0
- package/dist/CalendarCell.d.mts +18 -0
- package/dist/CalendarGrid.d.mts +18 -0
- package/dist/Card-CcU9cKCd.d.mts +52 -0
- package/dist/Card-CrQL0hXm.d.cts +52 -0
- package/dist/Card-CyCKL-M5.cjs +248 -0
- package/dist/Card-CyCKL-M5.cjs.map +1 -0
- package/dist/Card-DeJSt5ys.mjs +205 -0
- package/dist/Card-DeJSt5ys.mjs.map +1 -0
- package/dist/Card.d.cts +2 -0
- package/dist/Card.d.mts +2 -0
- package/dist/Card2.d.cts +95 -0
- package/dist/Card2.d.mts +96 -0
- package/dist/Checkbox-BWJNAP27.d.mts +46 -0
- package/dist/Checkbox-BmjK0Wac.d.cts +46 -0
- package/dist/Checkbox-C5bGcb-r.mjs +176 -0
- package/dist/Checkbox-C5bGcb-r.mjs.map +1 -0
- package/dist/Checkbox-D4nv7eNs.cjs +183 -0
- package/dist/Checkbox-D4nv7eNs.cjs.map +1 -0
- package/dist/Checkbox.d.cts +2 -0
- package/dist/Checkbox.d.mts +2 -0
- package/dist/CheckboxGroupField.d.cts +24 -0
- package/dist/CheckboxGroupField.d.mts +25 -0
- package/dist/Combobox-B_-swcix.mjs +1672 -0
- package/dist/Combobox-B_-swcix.mjs.map +1 -0
- package/dist/Combobox-B_oe33Re.cjs +1692 -0
- package/dist/Combobox-B_oe33Re.cjs.map +1 -0
- package/dist/Combobox-DjbJYK_u.d.mts +11 -0
- package/dist/Combobox.d.cts +12 -0
- package/dist/Combobox.d.mts +3 -0
- package/dist/ComboboxBase-D2wypeXf.d.cts +320 -0
- package/dist/ComboboxBase-INya0Csa.d.mts +320 -0
- package/dist/ComboboxBase.d.cts +2 -0
- package/dist/ComboboxBase.d.mts +2 -0
- package/dist/ComboboxMultiSelect-Dn8cRZ6Z.d.cts +47 -0
- package/dist/ComboboxMultiSelect-Dq9DGH8S.d.mts +47 -0
- package/dist/ComboboxMultiSelect.d.cts +2 -0
- package/dist/ComboboxMultiSelect.d.mts +2 -0
- package/dist/ComboboxSingleSelect-D8YM7GKP.d.cts +35 -0
- package/dist/ComboboxSingleSelect-WwBJRb0e.d.mts +35 -0
- package/dist/ComboboxSingleSelect.d.cts +2 -0
- package/dist/ComboboxSingleSelect.d.mts +2 -0
- package/dist/ConfigFormGroup.d.cts +7 -0
- package/dist/ConfigFormGroup.d.mts +7 -0
- package/dist/DateField-Bwe_0qm9.d.cts +24 -0
- package/dist/DateField-Chko9oLb.d.mts +24 -0
- package/dist/DateField.d.cts +2 -0
- package/dist/DateField.d.mts +2 -0
- package/dist/DatePicker.d.cts +19 -0
- package/dist/DatePicker.d.mts +19 -0
- package/dist/DateRangePicker.d.cts +46 -0
- package/dist/DateRangePicker.d.mts +47 -0
- package/dist/DropdownButton-DO4NqvWR.cjs +33 -0
- package/dist/DropdownButton-DO4NqvWR.cjs.map +1 -0
- package/dist/DropdownButton-k9kEcexu.mjs +27 -0
- package/dist/DropdownButton-k9kEcexu.mjs.map +1 -0
- package/dist/DropdownButton.d.cts +26 -0
- package/dist/DropdownButton.d.mts +26 -0
- package/dist/DropdownMenu-BTk--LWo.mjs +60 -0
- package/dist/DropdownMenu-BTk--LWo.mjs.map +1 -0
- package/dist/DropdownMenu-Bm2QqLEq.d.cts +75 -0
- package/dist/DropdownMenu-D2fzpkX2.cjs +74 -0
- package/dist/DropdownMenu-D2fzpkX2.cjs.map +1 -0
- package/dist/DropdownMenu-rWgROxQe.d.mts +75 -0
- package/dist/DropdownMenu.d.cts +2 -0
- package/dist/DropdownMenu.d.mts +2 -0
- package/dist/ErrorProps-DLdVsYlk.d.cts +8 -0
- package/dist/ErrorProps-DYUKygmd.d.mts +8 -0
- package/dist/ErrorProps.d.cts +2 -0
- package/dist/ErrorProps.d.mts +2 -0
- package/dist/FormControl-BXHqI_2D.mjs +168 -0
- package/dist/FormControl-BXHqI_2D.mjs.map +1 -0
- package/dist/FormControl-CM7wTn1P.d.mts +60 -0
- package/dist/FormControl-DiR2e7Od.cjs +212 -0
- package/dist/FormControl-DiR2e7Od.cjs.map +1 -0
- package/dist/FormControl-KkeIYuBa.d.cts +60 -0
- package/dist/FormControl.d.cts +2 -0
- package/dist/FormControl.d.mts +2 -0
- package/dist/FormField-19ownwjH.d.cts +69 -0
- package/dist/FormField-CdMru4s5.d.mts +69 -0
- package/dist/FormField.d.cts +2 -0
- package/dist/FormField.d.mts +2 -0
- package/dist/Header-D8oDtnIL.d.cts +35 -0
- package/dist/Header-t1plnZc0.d.mts +35 -0
- package/dist/Header.d.cts +2 -0
- package/dist/Header.d.mts +2 -0
- package/dist/HelperTooltip-Cd7I0Ucq.d.mts +20 -0
- package/dist/HelperTooltip-oXdyk2At.d.cts +20 -0
- package/dist/HelperTooltip.d.cts +2 -0
- package/dist/HelperTooltip.d.mts +2 -0
- package/dist/IconButton-B1ZL8BqW.cjs +372 -0
- package/dist/IconButton-B1ZL8BqW.cjs.map +1 -0
- package/dist/IconButton-C28qxOdi.mjs +341 -0
- package/dist/IconButton-C28qxOdi.mjs.map +1 -0
- package/dist/IconButton-DsXbc3nQ.d.mts +24 -0
- package/dist/IconButton-ZcyTFjPn.d.cts +24 -0
- package/dist/IconButton.d.cts +2 -0
- package/dist/IconButton.d.mts +2 -0
- package/dist/ImageTile.d.cts +60 -0
- package/dist/ImageTile.d.mts +60 -0
- package/dist/Input-Cv5qieRg.d.mts +65 -0
- package/dist/Input-DHOsR4cl.cjs +210 -0
- package/dist/Input-DHOsR4cl.cjs.map +1 -0
- package/dist/Input-XppkvfUf.d.cts +65 -0
- package/dist/Input-eoFk39bE.mjs +191 -0
- package/dist/Input-eoFk39bE.mjs.map +1 -0
- package/dist/Input.d.cts +2 -0
- package/dist/Input.d.mts +2 -0
- package/dist/InputProps-BHu05fX0.d.mts +16 -0
- package/dist/InputProps-CitGo8QA.d.cts +16 -0
- package/dist/InputProps.d.cts +2 -0
- package/dist/InputProps.d.mts +2 -0
- package/dist/Link.d.cts +43 -0
- package/dist/Link.d.mts +43 -0
- package/dist/ListBox-AyjzT6ra.d.mts +138 -0
- package/dist/ListBox-CE3mfDSB.cjs +383 -0
- package/dist/ListBox-CE3mfDSB.cjs.map +1 -0
- package/dist/ListBox-DbyZFy2W.d.cts +138 -0
- package/dist/ListBox-Z1y0LG1H.mjs +369 -0
- package/dist/ListBox-Z1y0LG1H.mjs.map +1 -0
- package/dist/ListBox.d.cts +2 -0
- package/dist/ListBox.d.mts +2 -0
- package/dist/ListBoxField.d.cts +46 -0
- package/dist/ListBoxField.d.mts +47 -0
- package/dist/LoadingShimmer-CNE6JUVF.mjs +67 -0
- package/dist/LoadingShimmer-CNE6JUVF.mjs.map +1 -0
- package/dist/LoadingShimmer-DMK9RC4N.cjs +92 -0
- package/dist/LoadingShimmer-DMK9RC4N.cjs.map +1 -0
- package/dist/LoadingShimmer.d.cts +38 -0
- package/dist/LoadingShimmer.d.mts +38 -0
- package/dist/MaskedInput.d.cts +10 -0
- package/dist/MaskedInput.d.mts +10 -0
- package/dist/MatchHighlight.d.cts +11 -0
- package/dist/MatchHighlight.d.mts +11 -0
- package/dist/Menu-BpkjNO81.cjs +217 -0
- package/dist/Menu-BpkjNO81.cjs.map +1 -0
- package/dist/Menu-DIFkRQ6x.d.mts +70 -0
- package/dist/Menu-DNRHo2i_.mjs +167 -0
- package/dist/Menu-DNRHo2i_.mjs.map +1 -0
- package/dist/Menu-DPrNMatb.d.cts +70 -0
- package/dist/Menu.d.cts +2 -0
- package/dist/Menu.d.mts +2 -0
- package/dist/Modal.d.cts +141 -0
- package/dist/Modal.d.mts +141 -0
- package/dist/PageHeader.d.cts +26 -0
- package/dist/PageHeader.d.mts +26 -0
- package/dist/PageSelector.d.cts +30 -0
- package/dist/PageSelector.d.mts +30 -0
- package/dist/PageSizeSelector.d.mts +22 -0
- package/dist/Pagination.d.cts +33 -0
- package/dist/Pagination.d.mts +33 -0
- package/dist/Pii.d.cts +16 -0
- package/dist/Pii.d.mts +17 -0
- package/dist/Popover-BSdyxuja.mjs +124 -0
- package/dist/Popover-BSdyxuja.mjs.map +1 -0
- package/dist/Popover-C2dBSwiU.cjs +168 -0
- package/dist/Popover-C2dBSwiU.cjs.map +1 -0
- package/dist/Popover.d.cts +90 -0
- package/dist/Popover.d.mts +90 -0
- package/dist/ProgressBar.d.cts +83 -0
- package/dist/ProgressBar.d.mts +83 -0
- package/dist/ProgressIndicator.d.cts +64 -0
- package/dist/ProgressIndicator.d.mts +64 -0
- package/dist/PseudoClassProps-C5jpj6Rp.d.cts +12 -0
- package/dist/PseudoClassProps-mZgO_iZJ.d.mts +12 -0
- package/dist/PseudoClassProps.d.cts +2 -0
- package/dist/PseudoClassProps.d.mts +2 -0
- package/dist/Radio-mFfT6G3d.cjs +154 -0
- package/dist/Radio-mFfT6G3d.cjs.map +1 -0
- package/dist/Radio-w-L3Otuk.mjs +147 -0
- package/dist/Radio-w-L3Otuk.mjs.map +1 -0
- package/dist/Radio.d.cts +21 -0
- package/dist/Radio.d.mts +21 -0
- package/dist/RadioGroup-B8htTzsS.mjs +50 -0
- package/dist/RadioGroup-B8htTzsS.mjs.map +1 -0
- package/dist/RadioGroup-BjDmweRK.cjs +57 -0
- package/dist/RadioGroup-BjDmweRK.cjs.map +1 -0
- package/dist/RadioGroup-D5ueuC6a.d.cts +21 -0
- package/dist/RadioGroup-Ls0vPsP_.d.mts +21 -0
- package/dist/RadioGroup.d.cts +2 -0
- package/dist/RadioGroup.d.mts +2 -0
- package/dist/RangeCalendar.d.mts +33 -0
- package/dist/RangeCalendarPresets.d.mts +25 -0
- package/dist/RegisterComponent-BDb43KvI.d.mts +34 -0
- package/dist/RegisterComponent-CpXIR-51.d.cts +34 -0
- package/dist/Section.d.mts +67 -0
- package/dist/SectionHeading-DVSXofwK.d.cts +72 -0
- package/dist/SectionHeading-QvAmhVmD.d.mts +72 -0
- package/dist/SectionHeading.d.cts +2 -0
- package/dist/SectionHeading.d.mts +2 -0
- package/dist/SegmentedControl-CvznPXgC.cjs +124 -0
- package/dist/SegmentedControl-CvznPXgC.cjs.map +1 -0
- package/dist/SegmentedControl-DRtXdbLe.d.cts +59 -0
- package/dist/SegmentedControl-Dk5S4Dhz.d.mts +59 -0
- package/dist/SegmentedControl-DnwNjYre.mjs +111 -0
- package/dist/SegmentedControl-DnwNjYre.mjs.map +1 -0
- package/dist/SegmentedControl.d.cts +2 -0
- package/dist/SegmentedControl.d.mts +2 -0
- package/dist/Select-BdPdgtfU.d.cts +77 -0
- package/dist/Select-CVB-Q1g1.cjs +266 -0
- package/dist/Select-CVB-Q1g1.cjs.map +1 -0
- package/dist/Select-Cl3AOq0-.mjs +246 -0
- package/dist/Select-Cl3AOq0-.mjs.map +1 -0
- package/dist/Select-DRnRqMAL.d.mts +77 -0
- package/dist/Select.d.cts +2 -0
- package/dist/Select.d.mts +2 -0
- package/dist/Slider-D3gz7otf.d.mts +56 -0
- package/dist/Slider-uH5MOu2D.d.cts +56 -0
- package/dist/Slider.d.cts +2 -0
- package/dist/Slider.d.mts +2 -0
- package/dist/SliderRHF-Cc-9RuPe.d.cts +984 -0
- package/dist/SliderRHF-DIV-tCEv.d.mts +984 -0
- package/dist/SliderRHF.d.cts +2 -0
- package/dist/SliderRHF.d.mts +2 -0
- package/dist/SliderThumb.d.mts +139 -0
- package/dist/Spacer-DWGkX170.cjs +20 -0
- package/dist/Spacer-DWGkX170.cjs.map +1 -0
- package/dist/Spacer-DxH_sQrV.mjs +13 -0
- package/dist/Spacer-DxH_sQrV.mjs.map +1 -0
- package/dist/Spacer.d.cts +17 -0
- package/dist/Spacer.d.mts +18 -0
- package/dist/Spinner-C05An_fn.mjs +41 -0
- package/dist/Spinner-C05An_fn.mjs.map +1 -0
- package/dist/Spinner-z7DrPE1d.cjs +48 -0
- package/dist/Spinner-z7DrPE1d.cjs.map +1 -0
- package/dist/Spinner.d.cts +26 -0
- package/dist/Spinner.d.mts +26 -0
- package/dist/Stack-BHb3ZB2A.cjs +53 -0
- package/dist/Stack-BHb3ZB2A.cjs.map +1 -0
- package/dist/Stack-BntgUvsW.d.mts +47 -0
- package/dist/Stack-hwgS2FU1.mjs +40 -0
- package/dist/Stack-hwgS2FU1.mjs.map +1 -0
- package/dist/Stack-toDRLy--.d.cts +47 -0
- package/dist/Stack.d.cts +2 -0
- package/dist/Stack.d.mts +2 -0
- package/dist/StatusIndicator.d.cts +54 -0
- package/dist/StatusIndicator.d.mts +54 -0
- package/dist/Sticker-Bd7KkekO.d.mts +68 -0
- package/dist/Sticker-D6bwBTGr.mjs +215 -0
- package/dist/Sticker-D6bwBTGr.mjs.map +1 -0
- package/dist/Sticker-D_dutvp_.cjs +246 -0
- package/dist/Sticker-D_dutvp_.cjs.map +1 -0
- package/dist/Sticker-S6QWjlEJ.d.cts +68 -0
- package/dist/Sticker.d.cts +2 -0
- package/dist/Sticker.d.mts +2 -0
- package/dist/SwatchPicker.d.cts +18 -0
- package/dist/SwatchPicker.d.mts +18 -0
- package/dist/Tab.d.cts +26 -0
- package/dist/Tab.d.mts +26 -0
- package/dist/TabBar-BMv8dAS3.cjs +297 -0
- package/dist/TabBar-BMv8dAS3.cjs.map +1 -0
- package/dist/TabBar-Bf89XksH.mjs +266 -0
- package/dist/TabBar-Bf89XksH.mjs.map +1 -0
- package/dist/TabBar.d.cts +33 -0
- package/dist/TabBar.d.mts +33 -0
- package/dist/TabBarContext.d.mts +10 -0
- package/dist/TabBarIconButton.d.cts +10 -0
- package/dist/TabBarIconButton.d.mts +11 -0
- package/dist/Table-34f5m7w5.d.mts +13 -0
- package/dist/Table-DkAA1lt_.d.cts +13 -0
- package/dist/Table.d.cts +2 -0
- package/dist/Table.d.mts +2 -0
- package/dist/TableBody-5QcVMPP_.d.cts +9 -0
- package/dist/TableBody-Clf34yzJ.d.mts +9 -0
- package/dist/TableBody.d.cts +2 -0
- package/dist/TableBody.d.mts +2 -0
- package/dist/TableCell-DIs9h97h.d.cts +75 -0
- package/dist/TableCell-Dog4Blfq.d.mts +75 -0
- package/dist/TableCell.d.cts +2 -0
- package/dist/TableCell.d.mts +2 -0
- package/dist/TableHead-9LLM1B8I.d.cts +12 -0
- package/dist/TableHead-DJBGHoUD.d.mts +12 -0
- package/dist/TableHead.d.cts +2 -0
- package/dist/TableHead.d.mts +2 -0
- package/dist/TableHeaderCell-25lC9tNk.d.cts +17 -0
- package/dist/TableHeaderCell-DzYZq7SG.d.mts +17 -0
- package/dist/TableHeaderCell.d.cts +2 -0
- package/dist/TableHeaderCell.d.mts +2 -0
- package/dist/TableLayout-BA3jbdbi.d.mts +19 -0
- package/dist/TableLayout-CmDKOu10.d.cts +19 -0
- package/dist/TableLayout.d.cts +2 -0
- package/dist/TableLayout.d.mts +2 -0
- package/dist/TableRow-CBKpDeUV.d.mts +13 -0
- package/dist/TableRow-IPjQnK2q.d.cts +13 -0
- package/dist/TableRow.d.cts +2 -0
- package/dist/TableRow.d.mts +2 -0
- package/dist/TableTH.d.cts +2 -0
- package/dist/TableTH.d.mts +2 -0
- package/dist/Text-CnXedFut.d.mts +42 -0
- package/dist/Text-CrGiWG2E.d.cts +42 -0
- package/dist/Text-DOTYjIt0.mjs +58 -0
- package/dist/Text-DOTYjIt0.mjs.map +1 -0
- package/dist/Text-DVz8erdF.cjs +95 -0
- package/dist/Text-DVz8erdF.cjs.map +1 -0
- package/dist/Text.d.cts +2 -0
- package/dist/Text.d.mts +2 -0
- package/dist/TextArea-1bHvaq9p.d.mts +10 -0
- package/dist/TextArea-B1kitxCl.mjs +33 -0
- package/dist/TextArea-B1kitxCl.mjs.map +1 -0
- package/dist/TextArea-MVgGGM6r.cjs +40 -0
- package/dist/TextArea-MVgGGM6r.cjs.map +1 -0
- package/dist/TextArea-j43fhp2P.d.cts +10 -0
- package/dist/TextArea.d.cts +2 -0
- package/dist/TextArea.d.mts +2 -0
- package/dist/TextUnderlineTooltip-BDMs4iXn.d.cts +18 -0
- package/dist/TextUnderlineTooltip-z4sSGL91.d.mts +18 -0
- package/dist/TextUnderlineTooltip.d.cts +2 -0
- package/dist/TextUnderlineTooltip.d.mts +2 -0
- package/dist/Tile.d.cts +63 -0
- package/dist/Tile.d.mts +63 -0
- package/dist/Toast.d.cts +27 -0
- package/dist/Toast.d.mts +27 -0
- package/dist/Toggle-8GNRxyvE.mjs +167 -0
- package/dist/Toggle-8GNRxyvE.mjs.map +1 -0
- package/dist/Toggle-B3Cdyf7T.d.mts +54 -0
- package/dist/Toggle-BjkbL_uf.d.cts +54 -0
- package/dist/Toggle-CVdg5iQ0.cjs +174 -0
- package/dist/Toggle-CVdg5iQ0.cjs.map +1 -0
- package/dist/Toggle.d.cts +2 -0
- package/dist/Toggle.d.mts +2 -0
- package/dist/Tooltip-0i_15ysU.cjs +152 -0
- package/dist/Tooltip-0i_15ysU.cjs.map +1 -0
- package/dist/Tooltip-C0PS5InA.d.mts +100 -0
- package/dist/Tooltip-CE1oH6Iz.d.cts +100 -0
- package/dist/Tooltip-T7RQpy_a.mjs +120 -0
- package/dist/Tooltip-T7RQpy_a.mjs.map +1 -0
- package/dist/Tooltip.d.cts +2 -0
- package/dist/Tooltip.d.mts +2 -0
- package/dist/TruncatedText-0Tf8CwFX.d.mts +18 -0
- package/dist/TruncatedText-D8f3AiBL.d.cts +18 -0
- package/dist/chunk-Bpcn9VDT.mjs +39 -0
- package/dist/chunk-CoPdw6nB.cjs +64 -0
- package/dist/common.d.mts +7 -0
- package/dist/components/Attribute/index.cjs +210 -0
- package/dist/components/Attribute/index.cjs.map +1 -0
- package/dist/components/Attribute/index.d.cts +3 -0
- package/dist/components/Attribute/index.d.mts +3 -0
- package/dist/components/Attribute/index.mjs +198 -0
- package/dist/components/Attribute/index.mjs.map +1 -0
- package/dist/components/Badge/index.cjs +8 -0
- package/dist/components/Badge/index.d.cts +2 -0
- package/dist/components/Badge/index.d.mts +2 -0
- package/dist/components/Badge/index.mjs +2 -0
- package/dist/components/Banner/index.cjs +100 -0
- package/dist/components/Banner/index.cjs.map +1 -0
- package/dist/components/Banner/index.d.cts +2 -0
- package/dist/components/Banner/index.d.mts +2 -0
- package/dist/components/Banner/index.mjs +93 -0
- package/dist/components/Banner/index.mjs.map +1 -0
- package/dist/components/Button/index.cjs +12 -0
- package/dist/components/Button/index.d.cts +3 -0
- package/dist/components/Button/index.d.mts +3 -0
- package/dist/components/Button/index.mjs +2 -0
- package/dist/components/ButtonGroup/index.cjs +112 -0
- package/dist/components/ButtonGroup/index.cjs.map +1 -0
- package/dist/components/ButtonGroup/index.d.cts +2 -0
- package/dist/components/ButtonGroup/index.d.mts +2 -0
- package/dist/components/ButtonGroup/index.mjs +103 -0
- package/dist/components/ButtonGroup/index.mjs.map +1 -0
- package/dist/components/Card/index.cjs +13 -0
- package/dist/components/Card/index.d.cts +3 -0
- package/dist/components/Card/index.d.mts +3 -0
- package/dist/components/Card/index.mjs +2 -0
- package/dist/components/CardV2/index.cjs +512 -0
- package/dist/components/CardV2/index.cjs.map +1 -0
- package/dist/components/CardV2/index.d.cts +3 -0
- package/dist/components/CardV2/index.d.mts +3 -0
- package/dist/components/CardV2/index.mjs +511 -0
- package/dist/components/CardV2/index.mjs.map +1 -0
- package/dist/components/Checkbox/index.cjs +8 -0
- package/dist/components/Checkbox/index.d.cts +2 -0
- package/dist/components/Checkbox/index.d.mts +2 -0
- package/dist/components/Checkbox/index.mjs +2 -0
- package/dist/components/Combobox/index.cjs +10 -0
- package/dist/components/Combobox/index.d.cts +3 -0
- package/dist/components/Combobox/index.d.mts +3 -0
- package/dist/components/Combobox/index.mjs +2 -0
- package/dist/components/ConfigFormGroup/index.cjs +37 -0
- package/dist/components/ConfigFormGroup/index.cjs.map +1 -0
- package/dist/components/ConfigFormGroup/index.d.cts +3 -0
- package/dist/components/ConfigFormGroup/index.d.mts +3 -0
- package/dist/components/ConfigFormGroup/index.mjs +28 -0
- package/dist/components/ConfigFormGroup/index.mjs.map +1 -0
- package/dist/components/DatePicker/index.cjs +11503 -0
- package/dist/components/DatePicker/index.cjs.map +1 -0
- package/dist/components/DatePicker/index.d.cts +5 -0
- package/dist/components/DatePicker/index.d.mts +5 -0
- package/dist/components/DatePicker/index.mjs +11491 -0
- package/dist/components/DatePicker/index.mjs.map +1 -0
- package/dist/components/DropdownButton/index.cjs +8 -0
- package/dist/components/DropdownButton/index.d.cts +2 -0
- package/dist/components/DropdownButton/index.d.mts +2 -0
- package/dist/components/DropdownButton/index.mjs +2 -0
- package/dist/components/DropdownMenu/index.cjs +8 -0
- package/dist/components/DropdownMenu/index.d.cts +2 -0
- package/dist/components/DropdownMenu/index.d.mts +2 -0
- package/dist/components/DropdownMenu/index.mjs +2 -0
- package/dist/components/FormControl/index.cjs +16 -0
- package/dist/components/FormControl/index.d.cts +3 -0
- package/dist/components/FormControl/index.d.mts +3 -0
- package/dist/components/FormControl/index.mjs +3 -0
- package/dist/components/FormField/index.cjs +385 -0
- package/dist/components/FormField/index.cjs.map +1 -0
- package/dist/components/FormField/index.d.cts +5 -0
- package/dist/components/FormField/index.d.mts +5 -0
- package/dist/components/FormField/index.mjs +367 -0
- package/dist/components/FormField/index.mjs.map +1 -0
- package/dist/components/ImageTile/index.cjs +228 -0
- package/dist/components/ImageTile/index.cjs.map +1 -0
- package/dist/components/ImageTile/index.d.cts +2 -0
- package/dist/components/ImageTile/index.d.mts +2 -0
- package/dist/components/ImageTile/index.mjs +221 -0
- package/dist/components/ImageTile/index.mjs.map +1 -0
- package/dist/components/Input/index.cjs +15 -0
- package/dist/components/Input/index.cjs.map +1 -0
- package/dist/components/Input/index.d.cts +2 -0
- package/dist/components/Input/index.d.mts +2 -0
- package/dist/components/Input/index.mjs +7 -0
- package/dist/components/Input/index.mjs.map +1 -0
- package/dist/components/Link/index.cjs +87 -0
- package/dist/components/Link/index.cjs.map +1 -0
- package/dist/components/Link/index.d.cts +2 -0
- package/dist/components/Link/index.d.mts +2 -0
- package/dist/components/Link/index.mjs +80 -0
- package/dist/components/Link/index.mjs.map +1 -0
- package/dist/components/ListBox/index.cjs +9 -0
- package/dist/components/ListBox/index.d.cts +2 -0
- package/dist/components/ListBox/index.d.mts +2 -0
- package/dist/components/ListBox/index.mjs +2 -0
- package/dist/components/LoadingShimmer/index.cjs +7 -0
- package/dist/components/LoadingShimmer/index.d.cts +2 -0
- package/dist/components/LoadingShimmer/index.d.mts +2 -0
- package/dist/components/LoadingShimmer/index.mjs +2 -0
- package/dist/components/MaskedInput/index.cjs +29 -0
- package/dist/components/MaskedInput/index.cjs.map +1 -0
- package/dist/components/MaskedInput/index.d.cts +2 -0
- package/dist/components/MaskedInput/index.d.mts +2 -0
- package/dist/components/MaskedInput/index.mjs +24 -0
- package/dist/components/MaskedInput/index.mjs.map +1 -0
- package/dist/components/MatchHighlight/index.cjs +31 -0
- package/dist/components/MatchHighlight/index.cjs.map +1 -0
- package/dist/components/MatchHighlight/index.d.cts +2 -0
- package/dist/components/MatchHighlight/index.d.mts +2 -0
- package/dist/components/MatchHighlight/index.mjs +24 -0
- package/dist/components/MatchHighlight/index.mjs.map +1 -0
- package/dist/components/Menu/index.cjs +15 -0
- package/dist/components/Menu/index.d.cts +2 -0
- package/dist/components/Menu/index.d.mts +2 -0
- package/dist/components/Menu/index.mjs +2 -0
- package/dist/components/Modal/index.cjs +285 -0
- package/dist/components/Modal/index.cjs.map +1 -0
- package/dist/components/Modal/index.d.cts +2 -0
- package/dist/components/Modal/index.d.mts +2 -0
- package/dist/components/Modal/index.mjs +276 -0
- package/dist/components/Modal/index.mjs.map +1 -0
- package/dist/components/PageHeader/index.cjs +71 -0
- package/dist/components/PageHeader/index.cjs.map +1 -0
- package/dist/components/PageHeader/index.d.cts +2 -0
- package/dist/components/PageHeader/index.d.mts +2 -0
- package/dist/components/PageHeader/index.mjs +64 -0
- package/dist/components/PageHeader/index.mjs.map +1 -0
- package/dist/components/Pagination/index.cjs +211 -0
- package/dist/components/Pagination/index.cjs.map +1 -0
- package/dist/components/Pagination/index.d.cts +3 -0
- package/dist/components/Pagination/index.d.mts +3 -0
- package/dist/components/Pagination/index.mjs +203 -0
- package/dist/components/Pagination/index.mjs.map +1 -0
- package/dist/components/Pii/index.cjs +20 -0
- package/dist/components/Pii/index.cjs.map +1 -0
- package/dist/components/Pii/index.d.cts +2 -0
- package/dist/components/Pii/index.d.mts +2 -0
- package/dist/components/Pii/index.mjs +19 -0
- package/dist/components/Pii/index.mjs.map +1 -0
- package/dist/components/Popover/index.cjs +13 -0
- package/dist/components/Popover/index.d.cts +2 -0
- package/dist/components/Popover/index.d.mts +2 -0
- package/dist/components/Popover/index.mjs +2 -0
- package/dist/components/ProgressBar/index.cjs +177 -0
- package/dist/components/ProgressBar/index.cjs.map +1 -0
- package/dist/components/ProgressBar/index.d.cts +2 -0
- package/dist/components/ProgressBar/index.d.mts +2 -0
- package/dist/components/ProgressBar/index.mjs +168 -0
- package/dist/components/ProgressBar/index.mjs.map +1 -0
- package/dist/components/ProgressIndicator/index.cjs +185 -0
- package/dist/components/ProgressIndicator/index.cjs.map +1 -0
- package/dist/components/ProgressIndicator/index.d.cts +2 -0
- package/dist/components/ProgressIndicator/index.d.mts +2 -0
- package/dist/components/ProgressIndicator/index.mjs +178 -0
- package/dist/components/ProgressIndicator/index.mjs.map +1 -0
- package/dist/components/Radio/index.cjs +8 -0
- package/dist/components/Radio/index.d.cts +2 -0
- package/dist/components/Radio/index.d.mts +2 -0
- package/dist/components/Radio/index.mjs +2 -0
- package/dist/components/RadioGroup/index.cjs +8 -0
- package/dist/components/RadioGroup/index.d.cts +2 -0
- package/dist/components/RadioGroup/index.d.mts +2 -0
- package/dist/components/RadioGroup/index.mjs +2 -0
- package/dist/components/SegmentedControl/index.cjs +9 -0
- package/dist/components/SegmentedControl/index.d.cts +2 -0
- package/dist/components/SegmentedControl/index.d.mts +2 -0
- package/dist/components/SegmentedControl/index.mjs +2 -0
- package/dist/components/Select/index.cjs +10 -0
- package/dist/components/Select/index.d.cts +2 -0
- package/dist/components/Select/index.d.mts +2 -0
- package/dist/components/Select/index.mjs +2 -0
- package/dist/components/Slider/index.cjs +1507 -0
- package/dist/components/Slider/index.cjs.map +1 -0
- package/dist/components/Slider/index.d.cts +3 -0
- package/dist/components/Slider/index.d.mts +3 -0
- package/dist/components/Slider/index.mjs +1497 -0
- package/dist/components/Slider/index.mjs.map +1 -0
- package/dist/components/Spacer/index.cjs +3 -0
- package/dist/components/Spacer/index.d.cts +2 -0
- package/dist/components/Spacer/index.d.mts +2 -0
- package/dist/components/Spacer/index.mjs +2 -0
- package/dist/components/Spinner/index.cjs +8 -0
- package/dist/components/Spinner/index.d.cts +2 -0
- package/dist/components/Spinner/index.d.mts +2 -0
- package/dist/components/Spinner/index.mjs +2 -0
- package/dist/components/Stack/index.cjs +9 -0
- package/dist/components/Stack/index.d.cts +2 -0
- package/dist/components/Stack/index.d.mts +2 -0
- package/dist/components/Stack/index.mjs +2 -0
- package/dist/components/StatusIndicator/index.cjs +174 -0
- package/dist/components/StatusIndicator/index.cjs.map +1 -0
- package/dist/components/StatusIndicator/index.d.cts +2 -0
- package/dist/components/StatusIndicator/index.d.mts +2 -0
- package/dist/components/StatusIndicator/index.mjs +167 -0
- package/dist/components/StatusIndicator/index.mjs.map +1 -0
- package/dist/components/Sticker/index.cjs +12 -0
- package/dist/components/Sticker/index.d.cts +2 -0
- package/dist/components/Sticker/index.d.mts +2 -0
- package/dist/components/Sticker/index.mjs +2 -0
- package/dist/components/SwatchPicker/index.cjs +65 -0
- package/dist/components/SwatchPicker/index.cjs.map +1 -0
- package/dist/components/SwatchPicker/index.d.cts +2 -0
- package/dist/components/SwatchPicker/index.d.mts +2 -0
- package/dist/components/SwatchPicker/index.mjs +58 -0
- package/dist/components/SwatchPicker/index.mjs.map +1 -0
- package/dist/components/TabBar/index.cjs +12 -0
- package/dist/components/TabBar/index.d.cts +4 -0
- package/dist/components/TabBar/index.d.mts +4 -0
- package/dist/components/TabBar/index.mjs +2 -0
- package/dist/components/Table/index.cjs +400 -0
- package/dist/components/Table/index.cjs.map +1 -0
- package/dist/components/Table/index.d.cts +8 -0
- package/dist/components/Table/index.d.mts +8 -0
- package/dist/components/Table/index.mjs +379 -0
- package/dist/components/Table/index.mjs.map +1 -0
- package/dist/components/Text/index.cjs +9 -0
- package/dist/components/Text/index.d.cts +2 -0
- package/dist/components/Text/index.d.mts +2 -0
- package/dist/components/Text/index.mjs +2 -0
- package/dist/components/TextArea/index.cjs +8 -0
- package/dist/components/TextArea/index.d.cts +2 -0
- package/dist/components/TextArea/index.d.mts +2 -0
- package/dist/components/TextArea/index.mjs +2 -0
- package/dist/components/Tile/index.cjs +103 -0
- package/dist/components/Tile/index.cjs.map +1 -0
- package/dist/components/Tile/index.d.cts +2 -0
- package/dist/components/Tile/index.d.mts +2 -0
- package/dist/components/Tile/index.mjs +96 -0
- package/dist/components/Tile/index.mjs.map +1 -0
- package/dist/components/Toast/index.cjs +141 -0
- package/dist/components/Toast/index.cjs.map +1 -0
- package/dist/components/Toast/index.d.cts +2 -0
- package/dist/components/Toast/index.d.mts +2 -0
- package/dist/components/Toast/index.mjs +136 -0
- package/dist/components/Toast/index.mjs.map +1 -0
- package/dist/components/Toggle/index.cjs +8 -0
- package/dist/components/Toggle/index.d.cts +2 -0
- package/dist/components/Toggle/index.d.mts +2 -0
- package/dist/components/Toggle/index.mjs +2 -0
- package/dist/components/Tooltip/index.cjs +12 -0
- package/dist/components/Tooltip/index.d.cts +4 -0
- package/dist/components/Tooltip/index.d.mts +4 -0
- package/dist/components/Tooltip/index.mjs +2 -0
- package/dist/constants.d.mts +5 -0
- package/dist/ids-Cr-NW2RJ.d.mts +11 -0
- package/dist/ids-e4V5Y3Ub.d.cts +11 -0
- package/dist/index-1-AkepUA.d.mts +1 -0
- package/dist/index-7in8TPrM.d.mts +1 -0
- package/dist/index-8R9vlM2B.d.mts +83 -0
- package/dist/index-B2KLYYkM.d.cts +1 -0
- package/dist/index-BBDa5smF.d.cts +1 -0
- package/dist/index-BJ8-FA6N.d.cts +1 -0
- package/dist/index-BM1DqNZf.d.cts +628 -0
- package/dist/index-BPSCxsMC.d.cts +1 -0
- package/dist/index-BPiqSRRl.d.mts +1 -0
- package/dist/index-BUYyA1Xh.d.cts +1 -0
- package/dist/index-CCt0lwyI.d.mts +1 -0
- package/dist/index-CEDY7cmG.d.cts +1 -0
- package/dist/index-CEqOS-7M.d.mts +1 -0
- package/dist/index-CExuKKOI.d.cts +218 -0
- package/dist/index-CIABef8t.d.mts +1 -0
- package/dist/index-CIBxlpQo.d.mts +1 -0
- package/dist/index-CKu60b9I.d.mts +154 -0
- package/dist/index-CP2eJYlK.d.mts +1 -0
- package/dist/index-CRo77wc3.d.mts +1 -0
- package/dist/index-CiBIKhMu.d.cts +1 -0
- package/dist/index-Cii4Qb1X.d.mts +1 -0
- package/dist/index-CspKFJM1.d.cts +1 -0
- package/dist/index-CsuikFeJ.d.mts +1 -0
- package/dist/index-Cz6N-KeS.d.cts +1 -0
- package/dist/index-D-BciAtf.d.cts +1 -0
- package/dist/index-D26lpgQi.d.cts +1 -0
- package/dist/index-D2HUTZ-d.d.cts +1 -0
- package/dist/index-D4DUvwPf.d.mts +1 -0
- package/dist/index-D4ELpJXS.d.cts +1 -0
- package/dist/index-D6CnpA_r.d.cts +1 -0
- package/dist/index-DLoAMD9J.d.cts +1 -0
- package/dist/index-DQvVmqvS.d.mts +628 -0
- package/dist/index-DWfPppPU.d.mts +1 -0
- package/dist/index-DcU87nuJ2.d.cts +1 -0
- package/dist/index-DkrC-i1D.d.mts +1 -0
- package/dist/index-DvuJXuAN.d.mts +1 -0
- package/dist/index-OEBbnNdr.d.mts +1 -0
- package/dist/index-QbUkWSLh.d.mts +1 -0
- package/dist/index-VmEFGBxN.d.cts +1 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.cts +2 -0
- package/dist/index.d.mts +2 -0
- package/dist/index.mjs +0 -0
- package/dist/index2.d.cts +1 -0
- package/dist/index2.d.mts +1 -0
- package/dist/input-BCmP106-.d.mts +17 -0
- package/dist/input-Bm_anD8X.d.cts +17 -0
- package/dist/inputFields.d.cts +83 -0
- package/dist/inputFields.d.mts +83 -0
- package/dist/intersperse.d.mts +18 -0
- package/dist/lib/ConfigContext.cjs +15 -0
- package/dist/lib/ConfigContext.cjs.map +1 -0
- package/dist/lib/ConfigContext.d.cts +16 -0
- package/dist/lib/ConfigContext.d.mts +17 -0
- package/dist/lib/ConfigContext.mjs +15 -0
- package/dist/lib/ConfigContext.mjs.map +1 -0
- package/dist/lib/HeadlessAriaButton.cjs +33 -0
- package/dist/lib/HeadlessAriaButton.cjs.map +1 -0
- package/dist/lib/HeadlessAriaButton.d.cts +12 -0
- package/dist/lib/HeadlessAriaButton.d.mts +12 -0
- package/dist/lib/HeadlessAriaButton.mjs +30 -0
- package/dist/lib/HeadlessAriaButton.mjs.map +1 -0
- package/dist/lib/PDSProvider.cjs +20 -0
- package/dist/lib/PDSProvider.cjs.map +1 -0
- package/dist/lib/PDSProvider.d.cts +12 -0
- package/dist/lib/PDSProvider.d.mts +13 -0
- package/dist/lib/PDSProvider.mjs +19 -0
- package/dist/lib/PDSProvider.mjs.map +1 -0
- package/dist/lib/TruncatedText.cjs +39 -0
- package/dist/lib/TruncatedText.cjs.map +1 -0
- package/dist/lib/TruncatedText.d.cts +2 -0
- package/dist/lib/TruncatedText.d.mts +2 -0
- package/dist/lib/TruncatedText.mjs +31 -0
- package/dist/lib/TruncatedText.mjs.map +1 -0
- package/dist/lib/TruncatedTextWithTooltip.cjs +34 -0
- package/dist/lib/TruncatedTextWithTooltip.cjs.map +1 -0
- package/dist/lib/TruncatedTextWithTooltip.d.cts +15 -0
- package/dist/lib/TruncatedTextWithTooltip.d.mts +15 -0
- package/dist/lib/TruncatedTextWithTooltip.mjs +28 -0
- package/dist/lib/TruncatedTextWithTooltip.mjs.map +1 -0
- package/dist/lib/comboboxHelper.cjs +46 -0
- package/dist/lib/comboboxHelper.cjs.map +1 -0
- package/dist/lib/comboboxHelper.d.cts +24 -0
- package/dist/lib/comboboxHelper.d.mts +24 -0
- package/dist/lib/comboboxHelper.mjs +42 -0
- package/dist/lib/comboboxHelper.mjs.map +1 -0
- package/dist/lib/datePickerHelper.cjs +3568 -0
- package/dist/lib/datePickerHelper.cjs.map +1 -0
- package/dist/lib/datePickerHelper.d.cts +19 -0
- package/dist/lib/datePickerHelper.d.mts +19 -0
- package/dist/lib/datePickerHelper.mjs +3566 -0
- package/dist/lib/datePickerHelper.mjs.map +1 -0
- package/dist/lib/pseudoClass.cjs +32 -0
- package/dist/lib/pseudoClass.cjs.map +1 -0
- package/dist/lib/pseudoClass.d.cts +45 -0
- package/dist/lib/pseudoClass.d.mts +45 -0
- package/dist/lib/pseudoClass.mjs +18 -0
- package/dist/lib/pseudoClass.mjs.map +1 -0
- package/dist/lib/register/RegisterComponent.cjs +91 -0
- package/dist/lib/register/RegisterComponent.cjs.map +1 -0
- package/dist/lib/register/RegisterComponent.d.cts +2 -0
- package/dist/lib/register/RegisterComponent.d.mts +2 -0
- package/dist/lib/register/RegisterComponent.mjs +88 -0
- package/dist/lib/register/RegisterComponent.mjs.map +1 -0
- package/dist/lib/register/ids.cjs +31 -0
- package/dist/lib/register/ids.cjs.map +1 -0
- package/dist/lib/register/ids.d.cts +2 -0
- package/dist/lib/register/ids.d.mts +2 -0
- package/dist/lib/register/ids.mjs +28 -0
- package/dist/lib/register/ids.mjs.map +1 -0
- package/dist/lib/register/index.cjs +8 -0
- package/dist/lib/register/index.d.cts +4 -0
- package/dist/lib/register/index.d.mts +4 -0
- package/dist/lib/register/index.mjs +3 -0
- package/dist/lib/register/types.cjs +1 -0
- package/dist/lib/register/types.d.cts +2 -0
- package/dist/lib/register/types.d.mts +2 -0
- package/dist/lib/register/types.mjs +0 -0
- package/dist/lib/reorderItems.cjs +39 -0
- package/dist/lib/reorderItems.cjs.map +1 -0
- package/dist/lib/reorderItems.d.cts +26 -0
- package/dist/lib/reorderItems.d.mts +26 -0
- package/dist/lib/reorderItems.mjs +36 -0
- package/dist/lib/reorderItems.mjs.map +1 -0
- package/dist/lib/selectHelper.cjs +22 -0
- package/dist/lib/selectHelper.cjs.map +1 -0
- package/dist/lib/selectHelper.d.cts +14 -0
- package/dist/lib/selectHelper.d.mts +14 -0
- package/dist/lib/selectHelper.mjs +20 -0
- package/dist/lib/selectHelper.mjs.map +1 -0
- package/dist/lib/useControlled.cjs +20 -0
- package/dist/lib/useControlled.cjs.map +1 -0
- package/dist/lib/useControlled.d.cts +16 -0
- package/dist/lib/useControlled.d.mts +17 -0
- package/dist/lib/useControlled.mjs +19 -0
- package/dist/lib/useControlled.mjs.map +1 -0
- package/dist/lib/useIsOverflow.cjs +58 -0
- package/dist/lib/useIsOverflow.cjs.map +1 -0
- package/dist/lib/useIsOverflow.d.cts +11 -0
- package/dist/lib/useIsOverflow.d.mts +11 -0
- package/dist/lib/useIsOverflow.mjs +56 -0
- package/dist/lib/useIsOverflow.mjs.map +1 -0
- package/dist/lib/useOutsideClick.cjs +19 -0
- package/dist/lib/useOutsideClick.cjs.map +1 -0
- package/dist/lib/useOutsideClick.d.cts +13 -0
- package/dist/lib/useOutsideClick.d.mts +13 -0
- package/dist/lib/useOutsideClick.mjs +17 -0
- package/dist/lib/useOutsideClick.mjs.map +1 -0
- package/dist/lib/zindex.cjs +27 -0
- package/dist/lib/zindex.cjs.map +1 -0
- package/dist/lib/zindex.d.cts +25 -0
- package/dist/lib/zindex.d.mts +25 -0
- package/dist/lib/zindex.mjs +25 -0
- package/dist/lib/zindex.mjs.map +1 -0
- package/dist/mergeRefs-BZinWopc.cjs +31 -0
- package/dist/mergeRefs-BZinWopc.cjs.map +1 -0
- package/dist/mergeRefs-BgcbK0Qy.mjs +26 -0
- package/dist/mergeRefs-BgcbK0Qy.mjs.map +1 -0
- package/dist/mixins/focus.cjs +39 -0
- package/dist/mixins/focus.cjs.map +1 -0
- package/dist/mixins/focus.d.cts +11 -0
- package/dist/mixins/focus.d.mts +11 -0
- package/dist/mixins/focus.mjs +34 -0
- package/dist/mixins/focus.mjs.map +1 -0
- package/dist/mixins/hoverable.cjs +38 -0
- package/dist/mixins/hoverable.cjs.map +1 -0
- package/dist/mixins/hoverable.d.cts +16 -0
- package/dist/mixins/hoverable.d.mts +16 -0
- package/dist/mixins/hoverable.mjs +32 -0
- package/dist/mixins/hoverable.mjs.map +1 -0
- package/dist/mixins/input.cjs +95 -0
- package/dist/mixins/input.cjs.map +1 -0
- package/dist/mixins/input.d.cts +2 -0
- package/dist/mixins/input.d.mts +2 -0
- package/dist/mixins/input.mjs +94 -0
- package/dist/mixins/input.mjs.map +1 -0
- package/dist/mixins/menuItem.cjs +110 -0
- package/dist/mixins/menuItem.cjs.map +1 -0
- package/dist/mixins/menuItem.d.cts +30 -0
- package/dist/mixins/menuItem.d.mts +31 -0
- package/dist/mixins/menuItem.mjs +109 -0
- package/dist/mixins/menuItem.mjs.map +1 -0
- package/dist/mixins/print/index.cjs +25 -0
- package/dist/mixins/print/index.cjs.map +1 -0
- package/dist/mixins/print/index.d.cts +11 -0
- package/dist/mixins/print/index.d.mts +11 -0
- package/dist/mixins/print/index.mjs +23 -0
- package/dist/mixins/print/index.mjs.map +1 -0
- package/dist/mixins/text.cjs +93 -0
- package/dist/mixins/text.cjs.map +1 -0
- package/dist/mixins/text.d.cts +2 -0
- package/dist/mixins/text.d.mts +2 -0
- package/dist/mixins/text.mjs +88 -0
- package/dist/mixins/text.mjs.map +1 -0
- package/dist/motion-DoikasqZ.mjs +7483 -0
- package/dist/motion-DoikasqZ.mjs.map +1 -0
- package/dist/motion-QW6imSxE.cjs +7488 -0
- package/dist/motion-QW6imSxE.cjs.map +1 -0
- package/dist/react.esm-C-es35jP.cjs +11441 -0
- package/dist/react.esm-C-es35jP.cjs.map +1 -0
- package/dist/react.esm-Dv1lMDRs.mjs +11397 -0
- package/dist/react.esm-Dv1lMDRs.mjs.map +1 -0
- package/dist/text-BrSUs-88.d.mts +14 -0
- package/dist/text-PmH5oc61.d.cts +14 -0
- package/dist/theme-Cadb1xzQ.d.cts +154 -0
- package/dist/theme-DGAqgnUa.d.mts +154 -0
- package/dist/theme.cjs +353 -0
- package/dist/theme.cjs.map +1 -0
- package/dist/theme.d.cts +2 -0
- package/dist/theme.d.mts +2 -0
- package/dist/theme.mjs +346 -0
- package/dist/theme.mjs.map +1 -0
- package/dist/types-DzHQ5MGm.d.mts +69 -0
- package/dist/types-N-cXznfM.d.cts +69 -0
- package/dist/useFormField-Ba0CQ43u.d.cts +30 -0
- package/dist/useFormField-BmtItl8y.d.mts +30 -0
- package/dist/useFormField-DN3gpEEV.cjs +37 -0
- package/dist/useFormField-DN3gpEEV.cjs.map +1 -0
- package/dist/useFormField-eftOPiXj.mjs +25 -0
- package/dist/useFormField-eftOPiXj.mjs.map +1 -0
- package/dist/useFormField.d.cts +2 -0
- package/dist/useFormField.d.mts +2 -0
- package/dist/useFormGroup-BMukAMAd.mjs +14 -0
- package/dist/useFormGroup-BMukAMAd.mjs.map +1 -0
- package/dist/useFormGroup-B_mFNoN9.cjs +26 -0
- package/dist/useFormGroup-B_mFNoN9.cjs.map +1 -0
- package/dist/useFormGroup.d.cts +18 -0
- package/dist/useFormGroup.d.mts +18 -0
- package/dist/useLabel-BcbghpIU.cjs +1465 -0
- package/dist/useLabel-BcbghpIU.cjs.map +1 -0
- package/dist/useLabel-DHGzNIKw.mjs +1212 -0
- package/dist/useLabel-DHGzNIKw.mjs.map +1 -0
- package/dist/useModalInsetRight.d.mts +21 -0
- package/dist/useToggle-0zLL1E7s.mjs +21 -0
- package/dist/useToggle-0zLL1E7s.mjs.map +1 -0
- package/dist/useToggle-DNrEsTpr.cjs +27 -0
- package/dist/useToggle-DNrEsTpr.cjs.map +1 -0
- package/dist/useToggle.d.mts +17 -0
- package/dist/useTruncation.d.mts +12 -0
- package/dist/utilities-C8Jf-xpi.d.cts +9 -0
- package/dist/utilities-w1K54IAy.d.mts +9 -0
- package/dist/utilities.d.cts +2 -0
- package/dist/utilities.d.mts +2 -0
- package/dist/utils/storybook.cjs +13 -0
- package/dist/utils/storybook.cjs.map +1 -0
- package/dist/utils/storybook.mjs +11 -0
- package/dist/utils/storybook.mjs.map +1 -0
- package/dist/utils/testing.cjs +50 -0
- package/dist/utils/testing.cjs.map +1 -0
- package/dist/utils/testing.d.cts +370 -0
- package/dist/utils/testing.d.mts +370 -0
- package/dist/utils/testing.mjs +45 -0
- package/dist/utils/testing.mjs.map +1 -0
- package/dist/variables/color.cjs +23 -0
- package/dist/variables/color.cjs.map +1 -0
- package/dist/variables/color.d.cts +19 -0
- package/dist/variables/color.d.mts +19 -0
- package/dist/variables/color.mjs +21 -0
- package/dist/variables/color.mjs.map +1 -0
- package/dist/variables/effect.cjs +27 -0
- package/dist/variables/effect.cjs.map +1 -0
- package/dist/variables/effect.d.cts +21 -0
- package/dist/variables/effect.d.mts +21 -0
- package/dist/variables/effect.mjs +24 -0
- package/dist/variables/effect.mjs.map +1 -0
- package/dist/variables/keyframes.cjs +22 -0
- package/dist/variables/keyframes.cjs.map +1 -0
- package/dist/variables/keyframes.d.cts +8 -0
- package/dist/variables/keyframes.d.mts +8 -0
- package/dist/variables/keyframes.mjs +19 -0
- package/dist/variables/keyframes.mjs.map +1 -0
- package/dist/variables/spacing.cjs +11 -0
- package/dist/variables/spacing.cjs.map +1 -0
- package/dist/variables/spacing.d.cts +8 -0
- package/dist/variables/spacing.d.mts +8 -0
- package/dist/variables/spacing.mjs +9 -0
- package/dist/variables/spacing.mjs.map +1 -0
- package/dist/variables/text.cjs +14 -0
- package/dist/variables/text.cjs.map +1 -0
- package/dist/variables/text.d.cts +10 -0
- package/dist/variables/text.d.mts +10 -0
- package/dist/variables/text.mjs +12 -0
- package/dist/variables/text.mjs.map +1 -0
- package/dist/variables/transitions.cjs +25 -0
- package/dist/variables/transitions.cjs.map +1 -0
- package/dist/variables/transitions.d.cts +19 -0
- package/dist/variables/transitions.d.mts +19 -0
- package/dist/variables/transitions.mjs +22 -0
- package/dist/variables/transitions.mjs.map +1 -0
- package/package.json +781 -0
|
@@ -0,0 +1,341 @@
|
|
|
1
|
+
import { isDisabled, isHovered, isNotDisabled } from "./lib/pseudoClass.mjs";
|
|
2
|
+
import { focusOutlineControlled } from "./mixins/focus.mjs";
|
|
3
|
+
import "./variables/transitions.mjs";
|
|
4
|
+
import { printMixins } from "./mixins/print/index.mjs";
|
|
5
|
+
import { paragraphMixins } from "./mixins/text.mjs";
|
|
6
|
+
import { t as useToggle } from "./useToggle-0zLL1E7s.mjs";
|
|
7
|
+
import { rotate } from "./variables/keyframes.mjs";
|
|
8
|
+
import { BorderRadius, Color, Spacing } from "@persona/design-tokens";
|
|
9
|
+
import styled, { css } from "styled-components";
|
|
10
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
11
|
+
import { forwardRef, useCallback } from "react";
|
|
12
|
+
import { Link } from "react-router-dom";
|
|
13
|
+
import { LoaderIcon } from "@persona/icons";
|
|
14
|
+
import { isEmpty, isFunction } from "lodash/fp.js";
|
|
15
|
+
//#region components/Button/Button.tsx
|
|
16
|
+
const noop = () => void 0;
|
|
17
|
+
const isActive = ({ active }) => active ? "" : ":active:enabled";
|
|
18
|
+
const sizeStyles = {
|
|
19
|
+
md: css`
|
|
20
|
+
${paragraphMixins.md}
|
|
21
|
+
height: ${({ theme }) => theme.button.height.md};
|
|
22
|
+
padding: ${Spacing[2]};
|
|
23
|
+
svg {
|
|
24
|
+
height: 16px;
|
|
25
|
+
width: 16px;
|
|
26
|
+
}
|
|
27
|
+
`,
|
|
28
|
+
sm: css`
|
|
29
|
+
${paragraphMixins.sm}
|
|
30
|
+
height: ${({ theme }) => theme.button.height.sm};
|
|
31
|
+
padding: ${Spacing[1]} 6px;
|
|
32
|
+
svg {
|
|
33
|
+
height: 16px;
|
|
34
|
+
width: 16px;
|
|
35
|
+
}
|
|
36
|
+
`
|
|
37
|
+
};
|
|
38
|
+
const widthStyles = {
|
|
39
|
+
full: css`
|
|
40
|
+
width: 100%;
|
|
41
|
+
`,
|
|
42
|
+
auto: css`
|
|
43
|
+
width: auto;
|
|
44
|
+
`,
|
|
45
|
+
button: css`
|
|
46
|
+
width: ${({ theme }) => theme.element.width.md};
|
|
47
|
+
`,
|
|
48
|
+
icon: css`
|
|
49
|
+
width: ${({ theme, size }) => {
|
|
50
|
+
return theme.button.height[size];
|
|
51
|
+
}};
|
|
52
|
+
padding: 0;
|
|
53
|
+
flex: none;
|
|
54
|
+
`
|
|
55
|
+
};
|
|
56
|
+
const StyledButton = styled.button.attrs(({ to, target }) => {
|
|
57
|
+
if (isEmpty(to)) return "button";
|
|
58
|
+
else if (typeof to === "string" && to.startsWith("https://")) return {
|
|
59
|
+
as: "a",
|
|
60
|
+
href: to,
|
|
61
|
+
target: target ?? "_blank",
|
|
62
|
+
rel: "noreferrer"
|
|
63
|
+
};
|
|
64
|
+
else return { as: Link };
|
|
65
|
+
})`
|
|
66
|
+
cursor: pointer;
|
|
67
|
+
border: none;
|
|
68
|
+
box-sizing: border-box;
|
|
69
|
+
white-space: nowrap;
|
|
70
|
+
${({ theme, variant }) => {
|
|
71
|
+
const palette = theme.color.variants[variant];
|
|
72
|
+
return css`
|
|
73
|
+
&:disabled {
|
|
74
|
+
background-color: ${palette.disabled};
|
|
75
|
+
color: ${palette.textDisabled};
|
|
76
|
+
svg path {
|
|
77
|
+
stroke: ${palette.textDisabled};
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/* For backwards compatibility with current coloring scheme (targeting stroke property) */
|
|
81
|
+
svg.pds-icon {
|
|
82
|
+
path {
|
|
83
|
+
stroke: unset;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/* Support icons with stroke */
|
|
87
|
+
path[stroke] {
|
|
88
|
+
stroke: currentColor;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
user-select: none;
|
|
93
|
+
}
|
|
94
|
+
`;
|
|
95
|
+
}}
|
|
96
|
+
|
|
97
|
+
${({ variant }) => variant === "outline" && css`
|
|
98
|
+
border: 1px solid ${({ theme }) => theme.color.border.input};
|
|
99
|
+
`}
|
|
100
|
+
|
|
101
|
+
display: flex;
|
|
102
|
+
align-items: center;
|
|
103
|
+
justify-content: center;
|
|
104
|
+
|
|
105
|
+
/* To properly position loading spinner */
|
|
106
|
+
position: relative;
|
|
107
|
+
|
|
108
|
+
border-radius: ${({ theme }) => theme.button.borderRadius};
|
|
109
|
+
|
|
110
|
+
transition-duration: ${"200ms"};
|
|
111
|
+
transition-property: background-color, color, border-color, width, height;
|
|
112
|
+
|
|
113
|
+
${({ size }) => {
|
|
114
|
+
return sizeStyles[size];
|
|
115
|
+
}}
|
|
116
|
+
${({ width }) => {
|
|
117
|
+
return widthStyles[width];
|
|
118
|
+
}}
|
|
119
|
+
|
|
120
|
+
/* Variant styling */
|
|
121
|
+
${({ theme, variant, $isPending, $onSecondaryBackground }) => {
|
|
122
|
+
let palette = theme.color.variants[variant];
|
|
123
|
+
if (variant === "basic" && $onSecondaryBackground) palette = {
|
|
124
|
+
...palette,
|
|
125
|
+
default: Color.CoreSlate300,
|
|
126
|
+
hover: Color.CoreSlate400,
|
|
127
|
+
active: Color.CoreSlate400,
|
|
128
|
+
disabled: Color.CoreSlate100
|
|
129
|
+
};
|
|
130
|
+
return css`
|
|
131
|
+
background-color: ${palette.default};
|
|
132
|
+
color: ${palette.text};
|
|
133
|
+
svg path {
|
|
134
|
+
stroke: ${palette.text};
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
svg.pds-icon {
|
|
138
|
+
path {
|
|
139
|
+
stroke: unset;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
path[stroke] {
|
|
143
|
+
stroke: currentColor;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
&${isHovered}${isNotDisabled} {
|
|
148
|
+
background-color: ${palette.hover};
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
&${isDisabled} {
|
|
152
|
+
cursor: not-allowed;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
&${isActive} {
|
|
156
|
+
background-color: ${palette.active};
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
${focusOutlineControlled}
|
|
160
|
+
|
|
161
|
+
${$isPending && css`
|
|
162
|
+
cursor: default;
|
|
163
|
+
background-color: ${palette.active};
|
|
164
|
+
&:disabled {
|
|
165
|
+
background-color: ${({ theme }) => {
|
|
166
|
+
return theme.color.variants[variant].active;
|
|
167
|
+
}};
|
|
168
|
+
user-select: none;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
svg path {
|
|
172
|
+
stroke: ${palette.highlightDark};
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
// For backwards compatibility with current coloring scheme (targeting stroke property)
|
|
176
|
+
svg.pds-icon {
|
|
177
|
+
path {
|
|
178
|
+
stroke: unset;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
path[stroke] {
|
|
182
|
+
stroke: currentColor;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
`}
|
|
186
|
+
`;
|
|
187
|
+
}}
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
${printMixins.hide}
|
|
191
|
+
`;
|
|
192
|
+
const LoaderContainer = styled.div`
|
|
193
|
+
position: absolute;
|
|
194
|
+
height: 100%;
|
|
195
|
+
width: 100%;
|
|
196
|
+
top: 0;
|
|
197
|
+
display: flex;
|
|
198
|
+
align-items: center;
|
|
199
|
+
justify-content: center;
|
|
200
|
+
transition: opacity 2s;
|
|
201
|
+
opacity: ${({ isPending }) => isPending ? "1" : "0"};
|
|
202
|
+
`;
|
|
203
|
+
const Loader = styled(LoaderIcon)`
|
|
204
|
+
animation: ${rotate} linear 1s infinite;
|
|
205
|
+
`;
|
|
206
|
+
const ButtonChildren = styled("div").attrs(({ isPending }) => ({ ["aria-hidden"]: isPending }))`
|
|
207
|
+
width: 100%;
|
|
208
|
+
display: flex;
|
|
209
|
+
flex-wrap: nowrap;
|
|
210
|
+
align-items: center;
|
|
211
|
+
justify-content: center;
|
|
212
|
+
transition: opacity ${"200ms"};
|
|
213
|
+
opacity: ${({ isPending }) => isPending ? "0" : "1"};
|
|
214
|
+
gap: ${Spacing[1]};
|
|
215
|
+
`;
|
|
216
|
+
const PrefixIconContainer = styled.div`
|
|
217
|
+
display: flex;
|
|
218
|
+
align-items: center;
|
|
219
|
+
`;
|
|
220
|
+
const InheritPrefixIconContainer = styled.div`
|
|
221
|
+
display: flex;
|
|
222
|
+
align-items: center;
|
|
223
|
+
|
|
224
|
+
& svg {
|
|
225
|
+
width: inherit;
|
|
226
|
+
height: inherit;
|
|
227
|
+
}
|
|
228
|
+
`;
|
|
229
|
+
const SuffixIconContainer = styled(PrefixIconContainer)`
|
|
230
|
+
margin-right: 0;
|
|
231
|
+
flex-grow: 1;
|
|
232
|
+
justify-content: flex-end;
|
|
233
|
+
`;
|
|
234
|
+
const ButtonText = styled.span`
|
|
235
|
+
position: relative;
|
|
236
|
+
|
|
237
|
+
/* Needed to align for browsers that don't support text-box yet
|
|
238
|
+
(which at this time, is firefox, and opera, and a few niche browsers)
|
|
239
|
+
This checks firefox. Otherwise, it will default back to the original
|
|
240
|
+
which is a slightly misaligned button
|
|
241
|
+
*/
|
|
242
|
+
|
|
243
|
+
/* Was trying to use this with @supports not, but genuinely could not figure out why this wouldn't
|
|
244
|
+
work */
|
|
245
|
+
|
|
246
|
+
line-height: ${({ width }) => width === "icon" ? "0" : "inherit"};
|
|
247
|
+
@-moz-document url-prefix() {
|
|
248
|
+
top: ${({ size }) => size === "md" ? "1px" : "0.5px"};
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
@supports (text-box: cap alphabetic) {
|
|
252
|
+
text-box: ${({ width }) => width === "icon" ? "normal" : "cap alphabetic"};
|
|
253
|
+
}
|
|
254
|
+
`;
|
|
255
|
+
const Button = forwardRef(function Button({ id, children, prefixIcon, suffixIcon, disabled, isPending, type = "button", prefixIconType = "basic", variant = "primary", size = "md", width = "full", onClick, onSecondaryBackground, ...props }, ref) {
|
|
256
|
+
const [isResolving, { enable, disable }] = useToggle(false);
|
|
257
|
+
const innerOnClick = isFunction(onClick) ? onClick : noop;
|
|
258
|
+
const loading = isPending || isResolving;
|
|
259
|
+
const handleClick = useCallback(async (e) => {
|
|
260
|
+
if (loading) return;
|
|
261
|
+
const maybePromise = innerOnClick(e);
|
|
262
|
+
if (maybePromise instanceof Promise) {
|
|
263
|
+
enable();
|
|
264
|
+
await maybePromise;
|
|
265
|
+
disable();
|
|
266
|
+
}
|
|
267
|
+
}, [loading, innerOnClick]);
|
|
268
|
+
return /* @__PURE__ */ jsxs(StyledButton, {
|
|
269
|
+
id,
|
|
270
|
+
type,
|
|
271
|
+
"data-test": "button__" + variant,
|
|
272
|
+
variant,
|
|
273
|
+
size,
|
|
274
|
+
width,
|
|
275
|
+
disabled: disabled || loading,
|
|
276
|
+
$isPending: loading,
|
|
277
|
+
$onSecondaryBackground: onSecondaryBackground,
|
|
278
|
+
...props,
|
|
279
|
+
onClick: handleClick,
|
|
280
|
+
ref,
|
|
281
|
+
children: [loading && /* @__PURE__ */ jsx(LoaderContainer, {
|
|
282
|
+
isPending: loading,
|
|
283
|
+
children: /* @__PURE__ */ jsx(Loader, { "aria-label": `Loading ${props["aria-label"] || ""}` })
|
|
284
|
+
}), /* @__PURE__ */ jsxs(ButtonChildren, {
|
|
285
|
+
isPending: loading,
|
|
286
|
+
children: [
|
|
287
|
+
prefixIcon != null && /* @__PURE__ */ jsxs(Fragment, { children: [prefixIconType === "basic" && /* @__PURE__ */ jsx(PrefixIconContainer, { children: prefixIcon }), prefixIconType === "inherit" && /* @__PURE__ */ jsx(InheritPrefixIconContainer, { children: prefixIcon })] }),
|
|
288
|
+
children && /* @__PURE__ */ jsx(ButtonText, {
|
|
289
|
+
width,
|
|
290
|
+
size,
|
|
291
|
+
children
|
|
292
|
+
}),
|
|
293
|
+
suffixIcon != null && /* @__PURE__ */ jsx(SuffixIconContainer, { children: suffixIcon })
|
|
294
|
+
]
|
|
295
|
+
})]
|
|
296
|
+
});
|
|
297
|
+
});
|
|
298
|
+
//#endregion
|
|
299
|
+
//#region components/Button/IconButton.tsx
|
|
300
|
+
const BUTTON_SIZE_MAP = {
|
|
301
|
+
xs: "16px",
|
|
302
|
+
sm: "24px",
|
|
303
|
+
md: "32px"
|
|
304
|
+
};
|
|
305
|
+
const ICON_SIZE_MAP = {
|
|
306
|
+
xs: "12px",
|
|
307
|
+
sm: "16px",
|
|
308
|
+
md: "16px"
|
|
309
|
+
};
|
|
310
|
+
const IconBtn = styled(Button).attrs({
|
|
311
|
+
width: "icon",
|
|
312
|
+
variant: "basic"
|
|
313
|
+
})`
|
|
314
|
+
background-color: transparent;
|
|
315
|
+
padding: 0;
|
|
316
|
+
border-radius: ${BorderRadius.Md};
|
|
317
|
+
|
|
318
|
+
${({ size }) => css`
|
|
319
|
+
height: ${BUTTON_SIZE_MAP[size]};
|
|
320
|
+
width: ${BUTTON_SIZE_MAP[size]};
|
|
321
|
+
|
|
322
|
+
svg {
|
|
323
|
+
width: ${ICON_SIZE_MAP[size]};
|
|
324
|
+
height: ${ICON_SIZE_MAP[size]};
|
|
325
|
+
}
|
|
326
|
+
`}
|
|
327
|
+
`;
|
|
328
|
+
/**
|
|
329
|
+
* Use to render icon-only buttons. Ensure buttons have proper aria properties.
|
|
330
|
+
*/
|
|
331
|
+
const IconButton = forwardRef(function IconButton({ size = "xs", ...props }, ref) {
|
|
332
|
+
return /* @__PURE__ */ jsx(IconBtn, {
|
|
333
|
+
size,
|
|
334
|
+
ref,
|
|
335
|
+
...props
|
|
336
|
+
});
|
|
337
|
+
});
|
|
338
|
+
//#endregion
|
|
339
|
+
export { SuffixIconContainer as a, StyledButton as i, Button as n, ButtonChildren as r, IconButton as t };
|
|
340
|
+
|
|
341
|
+
//# sourceMappingURL=IconButton-C28qxOdi.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IconButton-C28qxOdi.mjs","names":[],"sources":["../components/Button/Button.tsx","../components/Button/IconButton.tsx"],"sourcesContent":["import { Color, Spacing } from '@persona/design-tokens';\nimport { LoaderIcon } from '@persona/icons';\nimport { isEmpty, isFunction } from 'lodash/fp';\nimport {\n type ComponentPropsWithoutRef,\n forwardRef,\n type MouseEvent,\n type ReactNode,\n type Ref,\n useCallback,\n} from 'react';\nimport { Link, type LinkProps } from 'react-router-dom';\nimport styled, {\n css,\n type DefaultTheme,\n type FlattenInterpolation,\n type ThemeProps,\n} from 'styled-components';\n\nimport { isDisabled, isHovered, isNotDisabled } from 'design-system/lib/pseudoClass';\nimport useToggle from 'design-system/lib/useToggle';\nimport { focusOutlineControlled } from 'design-system/mixins/focus';\nimport { printMixins } from 'design-system/mixins/print';\nimport { paragraphMixins } from 'design-system/mixins/text';\nimport type PseudoClassProps from 'design-system/types/PseudoClassProps';\nimport { rotate } from 'design-system/variables/keyframes';\nimport { TransitionDuration } from 'design-system/variables/transitions';\n\nconst noop = (): void => undefined;\n\n// TODO(joseph): Bring this fix back to pseudoClass\nconst isActive = ({ active }: PseudoClassProps) => (active ? '' : ':active:enabled');\n\n/* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\nconst sizeStyles: Record<ButtonProps['size'], FlattenInterpolation<ThemeProps<DefaultTheme>>> = {\n md: css`\n ${paragraphMixins.md}\n height: ${({ theme }) => theme.button.height.md};\n padding: ${Spacing[2]};\n svg {\n height: 16px;\n width: 16px;\n }\n `,\n sm: css`\n ${paragraphMixins.sm}\n height: ${({ theme }) => theme.button.height.sm};\n padding: ${Spacing[1]} 6px;\n svg {\n height: 16px;\n width: 16px;\n }\n `,\n};\n\n/* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\nconst widthStyles: Record<ButtonProps['width'], FlattenInterpolation<ThemeProps<DefaultTheme>>> = {\n full: css`\n width: 100%;\n `,\n auto: css`\n width: auto;\n `,\n // TODO: rename this prop to 'element' as a standard unresponsive element width\n button: css`\n width: ${({ theme }) => theme.element.width.md};\n `,\n icon: css<ButtonProps>`\n width: ${({ theme, size }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n return theme.button.height[size];\n }};\n padding: 0;\n flex: none;\n `,\n};\n\ninterface ButtonPropsWithTransientProps extends Omit<ButtonProps, 'isPending'> {\n $isPending: boolean;\n $onSecondaryBackground?: boolean;\n}\n\nexport const StyledButton = styled.button.attrs<ButtonPropsWithTransientProps>(({ to, target }) => {\n if (isEmpty(to)) {\n return 'button';\n } else if (typeof to === 'string' && to.startsWith('https://')) {\n return {\n as: 'a',\n href: to,\n target: target ?? '_blank',\n rel: 'noreferrer',\n };\n } else {\n return {\n as: Link,\n };\n }\n})<ButtonPropsWithTransientProps>`\n cursor: pointer;\n border: none;\n box-sizing: border-box;\n white-space: nowrap;\n ${({ theme, variant }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n const palette = theme.color.variants[variant] as any;\n return css`\n &:disabled {\n background-color: ${palette.disabled};\n color: ${palette.textDisabled};\n svg path {\n stroke: ${palette.textDisabled};\n }\n\n /* For backwards compatibility with current coloring scheme (targeting stroke property) */\n svg.pds-icon {\n path {\n stroke: unset;\n }\n\n /* Support icons with stroke */\n path[stroke] {\n stroke: currentColor;\n }\n }\n\n user-select: none;\n }\n `;\n }}\n\n ${({ variant }) =>\n variant === 'outline' &&\n css`\n border: 1px solid ${({ theme }) => theme.color.border.input};\n `}\n\n display: flex;\n align-items: center;\n justify-content: center;\n\n /* To properly position loading spinner */\n position: relative;\n\n border-radius: ${({ theme }) => theme.button.borderRadius};\n\n transition-duration: ${TransitionDuration.Fast};\n transition-property: background-color, color, border-color, width, height;\n\n ${({ size }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n return sizeStyles[size];\n }}\n ${({ width }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n return widthStyles[width];\n }}\n\n /* Variant styling */\n ${({ theme, variant, $isPending, $onSecondaryBackground }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n let palette = theme.color.variants[variant] as any;\n\n if (variant === 'basic' && $onSecondaryBackground) {\n palette = {\n ...palette,\n // eslint-disable-next-line rulesdir/no-core-color-tokens\n default: Color.CoreSlate300,\n // eslint-disable-next-line rulesdir/no-core-color-tokens\n hover: Color.CoreSlate400,\n // eslint-disable-next-line rulesdir/no-core-color-tokens\n active: Color.CoreSlate400,\n // eslint-disable-next-line rulesdir/no-core-color-tokens\n disabled: Color.CoreSlate100,\n };\n }\n\n return css`\n background-color: ${palette.default};\n color: ${palette.text};\n svg path {\n stroke: ${palette.text};\n }\n\n svg.pds-icon {\n path {\n stroke: unset;\n }\n\n path[stroke] {\n stroke: currentColor;\n }\n }\n\n &${isHovered}${isNotDisabled} {\n background-color: ${palette.hover};\n }\n\n &${isDisabled} {\n cursor: not-allowed;\n }\n\n &${isActive} {\n background-color: ${palette.active};\n }\n\n ${focusOutlineControlled}\n\n ${\n $isPending &&\n css`\n cursor: default;\n background-color: ${palette.active};\n &:disabled {\n background-color: ${({ theme }) => {\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n return theme.color.variants[variant].active;\n }};\n user-select: none;\n }\n\n svg path {\n stroke: ${palette.highlightDark};\n }\n\n // For backwards compatibility with current coloring scheme (targeting stroke property)\n svg.pds-icon {\n path {\n stroke: unset;\n }\n\n path[stroke] {\n stroke: currentColor;\n }\n }\n `\n }\n `;\n }}\n\n\n ${printMixins.hide}\n`;\n\ntype WithPendingProps = Pick<ButtonProps, 'isPending'>;\n\nconst LoaderContainer = styled.div<WithPendingProps>`\n position: absolute;\n height: 100%;\n width: 100%;\n top: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: opacity 2s;\n opacity: ${({ isPending }) => (isPending ? '1' : '0')};\n`;\n\nconst Loader = styled(LoaderIcon)`\n animation: ${rotate} linear 1s infinite;\n`;\n\nexport const ButtonChildren = styled('div').attrs(({ isPending }: WithPendingProps) => ({\n ['aria-hidden']: isPending,\n}))<WithPendingProps>`\n width: 100%;\n display: flex;\n flex-wrap: nowrap;\n align-items: center;\n justify-content: center;\n transition: opacity ${TransitionDuration.Fast};\n opacity: ${({ isPending }) => (isPending ? '0' : '1')};\n gap: ${Spacing[1]};\n`;\n\nconst PrefixIconContainer = styled.div`\n display: flex;\n align-items: center;\n`;\n\nconst InheritPrefixIconContainer = styled.div`\n display: flex;\n align-items: center;\n\n & svg {\n width: inherit;\n height: inherit;\n }\n`;\n\nexport const SuffixIconContainer = styled(PrefixIconContainer)`\n margin-right: 0;\n flex-grow: 1;\n justify-content: flex-end;\n`;\n\nconst ButtonText = styled.span<{ size: 'md' | 'sm'; width: 'full' | 'auto' | 'button' | 'icon' }>`\n position: relative;\n\n /* Needed to align for browsers that don't support text-box yet\n (which at this time, is firefox, and opera, and a few niche browsers)\n This checks firefox. Otherwise, it will default back to the original\n which is a slightly misaligned button\n */\n\n /* Was trying to use this with @supports not, but genuinely could not figure out why this wouldn't\n work */\n\n line-height: ${({ width }) => (width === 'icon' ? '0' : 'inherit')};\n @-moz-document url-prefix() {\n top: ${({ size }) => (size === 'md' ? '1px' : '0.5px')};\n }\n\n @supports (text-box: cap alphabetic) {\n text-box: ${({ width }) => (width === 'icon' ? 'normal' : 'cap alphabetic')};\n }\n`;\n\ntype MaybePromise =\n | ((e: MouseEvent<HTMLButtonElement>) => void)\n | ((e: MouseEvent<HTMLButtonElement>) => Promise<void>);\n\nexport interface ButtonProps\n extends ComponentPropsWithoutRef<'button'>, Omit<PseudoClassProps, 'checked'> {\n /**\n * Visual style of the button.\n *\n * - `primary` – filled brand colour, for the primary action on a surface.\n * - `basic` – subtle grey fill, for secondary actions.\n * - `outline` – transparent with a border, alternative secondary style.\n * - `text` – no background or border, for tertiary / inline actions.\n * - `inverse` – inverted fill for use on dark/coloured backgrounds.\n * - `danger` – red fill, for destructive actions.\n *\n * @defaultValue 'primary'\n */\n variant?: 'basic' | 'primary' | 'inverse' | 'danger' | 'text' | 'outline';\n /**\n * Shows a loading spinner and disables the button. Also triggers automatically\n * when `onClick` returns a Promise, clearing once the promise settles.\n */\n isPending?: boolean;\n /**\n * Icon rendered to the left of the button label.\n * Import from `@persona-id/icons`.\n */\n prefixIcon?: ReactNode;\n /**\n * Controls how the prefix icon inherits sizing.\n *\n * - `basic` – icon is rendered inside a fixed-size container.\n * - `inherit` – icon stretches to fill the surrounding element's dimensions.\n *\n * @defaultValue 'basic'\n */\n prefixIconType?: 'basic' | 'inherit';\n\n /**\n * Icon rendered to the right of the button label.\n * Import from `@persona-id/icons`.\n */\n suffixIcon?: ReactNode;\n\n /**\n * Height and typography scale of the button.\n *\n * @defaultValue 'md'\n */\n size?: 'md' | 'sm';\n\n /**\n * Changes the button into a link.\n * Pass a relative path to use `react-router-dom` `<Link>`, or an absolute\n * `https://` URL to render an `<a>` tag that opens in a new tab.\n */\n to?: LinkProps['to'];\n\n /**\n * Overrides the target of the link if `to` is provided and is an external link.\n */\n target?: LinkProps['target'];\n\n /**\n * Note: we may want to default this to 'button' in the future, but many instances of this Button component\n * in dashboard currently rely on the default 'submit' behavior that occurs when using this in redux-form\n * so we'll have to comb through and manually add the type='submit' prop.\n */\n type?: 'button' | 'reset' | 'submit';\n /**\n * Controls the width of the button.\n *\n * - `full` – stretches to fill its container (`width: 100%`).\n * - `auto` – shrinks to fit its content.\n * - `button` – a fixed medium element width (from design tokens).\n * - `icon` – square, sized to match the button height; use for icon-only buttons.\n *\n * @defaultValue 'full'\n */\n width?: 'full' | 'auto' | 'button' | 'icon';\n onClick?: MaybePromise;\n ref?: Ref<HTMLButtonElement>;\n\n /**\n * In some cases we render a button on a secondary background, which needs an adjustment\n * for certain variants.\n */\n onSecondaryBackground?: boolean;\n}\n\nconst Button = forwardRef<HTMLButtonElement, ButtonProps>(function Button(\n {\n id,\n children,\n prefixIcon,\n suffixIcon,\n disabled,\n isPending,\n type = 'button',\n prefixIconType = 'basic',\n variant = 'primary',\n size = 'md',\n width = 'full',\n onClick,\n onSecondaryBackground,\n ...props\n }: ButtonProps,\n ref,\n) {\n const [isResolving, { enable, disable }] = useToggle(false);\n const innerOnClick: MaybePromise = isFunction(onClick) ? onClick : noop;\n const loading = isPending || isResolving;\n\n const handleClick = useCallback(\n async (e: MouseEvent<HTMLButtonElement>) => {\n if (loading) {\n return;\n }\n\n const maybePromise = innerOnClick(e);\n\n if (maybePromise instanceof Promise) {\n enable();\n await maybePromise;\n disable();\n }\n },\n [loading, innerOnClick],\n );\n\n return (\n <StyledButton\n id={id}\n type={type}\n data-test={'button__' + variant}\n variant={variant}\n size={size}\n width={width}\n disabled={disabled || loading}\n $isPending={loading}\n $onSecondaryBackground={onSecondaryBackground}\n {...props}\n onClick={handleClick}\n ref={ref}\n >\n {loading && (\n <LoaderContainer isPending={loading}>\n <Loader aria-label={`Loading ${props['aria-label'] || ''}`} />\n </LoaderContainer>\n )}\n <ButtonChildren isPending={loading}>\n {prefixIcon != null && (\n <>\n {prefixIconType === 'basic' && <PrefixIconContainer>{prefixIcon}</PrefixIconContainer>}\n {prefixIconType === 'inherit' && (\n <InheritPrefixIconContainer>{prefixIcon}</InheritPrefixIconContainer>\n )}\n </>\n )}\n {children && (\n <ButtonText width={width} size={size}>\n {children}\n </ButtonText>\n )}\n {suffixIcon != null && <SuffixIconContainer>{suffixIcon}</SuffixIconContainer>}\n </ButtonChildren>\n </StyledButton>\n );\n});\n\nexport default Button;\n","import { BorderRadius } from '@persona/design-tokens';\nimport { forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport Button, { type ButtonProps } from './Button';\n\nconst BUTTON_SIZE_MAP = {\n xs: '16px',\n sm: '24px',\n md: '32px',\n};\n\nconst ICON_SIZE_MAP = {\n xs: '12px',\n sm: '16px',\n md: '16px',\n};\n\ntype IconBtnSize = keyof typeof BUTTON_SIZE_MAP;\n\nconst IconBtn = styled(Button).attrs({\n width: 'icon',\n variant: 'basic',\n})`\n background-color: transparent;\n padding: 0;\n border-radius: ${BorderRadius.Md};\n\n ${({ size }) => css`\n height: ${BUTTON_SIZE_MAP[size as IconBtnSize]};\n width: ${BUTTON_SIZE_MAP[size as IconBtnSize]};\n\n svg {\n width: ${ICON_SIZE_MAP[size as IconBtnSize]};\n height: ${ICON_SIZE_MAP[size as IconBtnSize]};\n }\n `}\n`;\n\nexport interface IconButtonProps extends Omit<\n ButtonProps,\n 'width' | 'prefixIcon' | 'prefixIconType' | 'suffixIcon' | 'variant' | 'size'\n> {\n /**\n * `xs` - 16px. `sm` - 24px. `md` - 32px.\n * Pair with a PDS icon in the prescribed size.\n */\n size?: IconBtnSize;\n}\n\n/**\n * Use to render icon-only buttons. Ensure buttons have proper aria properties.\n */\nconst IconButton = forwardRef<HTMLButtonElement, IconButtonProps>(function IconButton(\n { size = 'xs', ...props },\n ref,\n) {\n return <IconBtn size={size as ButtonProps['size']} ref={ref} {...props} />;\n});\n\nexport default IconButton;\n"],"mappings":"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"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { r as ButtonProps } from "./Button-DqDLGURJ.mjs";
|
|
2
|
+
import * as _$react from "react";
|
|
3
|
+
|
|
4
|
+
//#region components/Button/IconButton.d.ts
|
|
5
|
+
declare const BUTTON_SIZE_MAP: {
|
|
6
|
+
xs: string;
|
|
7
|
+
sm: string;
|
|
8
|
+
md: string;
|
|
9
|
+
};
|
|
10
|
+
type IconBtnSize = keyof typeof BUTTON_SIZE_MAP;
|
|
11
|
+
interface IconButtonProps extends Omit<ButtonProps, 'width' | 'prefixIcon' | 'prefixIconType' | 'suffixIcon' | 'variant' | 'size'> {
|
|
12
|
+
/**
|
|
13
|
+
* `xs` - 16px. `sm` - 24px. `md` - 32px.
|
|
14
|
+
* Pair with a PDS icon in the prescribed size.
|
|
15
|
+
*/
|
|
16
|
+
size?: IconBtnSize;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Use to render icon-only buttons. Ensure buttons have proper aria properties.
|
|
20
|
+
*/
|
|
21
|
+
declare const IconButton: _$react.ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & _$react.RefAttributes<HTMLButtonElement>>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { IconButtonProps as n, IconButton as t };
|
|
24
|
+
//# sourceMappingURL=IconButton-DsXbc3nQ.d.mts.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { r as ButtonProps } from "./Button-C_3p5Xfi.cjs";
|
|
2
|
+
import * as _$react from "react";
|
|
3
|
+
|
|
4
|
+
//#region components/Button/IconButton.d.ts
|
|
5
|
+
declare const BUTTON_SIZE_MAP: {
|
|
6
|
+
xs: string;
|
|
7
|
+
sm: string;
|
|
8
|
+
md: string;
|
|
9
|
+
};
|
|
10
|
+
type IconBtnSize = keyof typeof BUTTON_SIZE_MAP;
|
|
11
|
+
interface IconButtonProps extends Omit<ButtonProps, 'width' | 'prefixIcon' | 'prefixIconType' | 'suffixIcon' | 'variant' | 'size'> {
|
|
12
|
+
/**
|
|
13
|
+
* `xs` - 16px. `sm` - 24px. `md` - 32px.
|
|
14
|
+
* Pair with a PDS icon in the prescribed size.
|
|
15
|
+
*/
|
|
16
|
+
size?: IconBtnSize;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Use to render icon-only buttons. Ensure buttons have proper aria properties.
|
|
20
|
+
*/
|
|
21
|
+
declare const IconButton: _$react.ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & _$react.RefAttributes<HTMLButtonElement>>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { IconButtonProps as n, IconButton as t };
|
|
24
|
+
//# sourceMappingURL=IconButton-ZcyTFjPn.d.cts.map
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { i as TextAction } from "./Action-uduFOh2m.cjs";
|
|
2
|
+
import { ComponentPropsWithoutRef, MouseEvent, ReactNode } from "react";
|
|
3
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime.js";
|
|
4
|
+
|
|
5
|
+
//#region components/ImageTile/ImageTile.d.ts
|
|
6
|
+
interface ImageTileProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
7
|
+
/** URL of the thumbnail. While loading shows shimmer; on error shows the empty fallback. */
|
|
8
|
+
src: string | null;
|
|
9
|
+
/** Alt text for the thumbnail. Also seeds the default checkbox label. */
|
|
10
|
+
alt?: string;
|
|
11
|
+
/** How the thumbnail fills its area. `cover` crops overflow; `contain` letterboxes to fit. Defaults to `cover`. */
|
|
12
|
+
objectFit?: 'cover' | 'contain';
|
|
13
|
+
/** Enables the selection checkbox (top-left). */
|
|
14
|
+
selectable?: boolean;
|
|
15
|
+
/** Controlled checked state for the selection checkbox. */
|
|
16
|
+
selected?: boolean;
|
|
17
|
+
/** Called with the new checked value when the checkbox is toggled. */
|
|
18
|
+
onSelectedChange?: (selected: boolean) => void;
|
|
19
|
+
/** Accessible label for the checkbox. Defaults to "Select {alt}" or "Select image". */
|
|
20
|
+
selectionLabel?: string;
|
|
21
|
+
/**
|
|
22
|
+
* Action menu items rendered behind a 3-dot IconButton in the top-right.
|
|
23
|
+
* Ignored when `locked` is true. Pass an empty array (or omit) to hide the menu.
|
|
24
|
+
*/
|
|
25
|
+
actions?: TextAction[];
|
|
26
|
+
/**
|
|
27
|
+
* Replaces the action menu with a non-interactive lock icon. Indicates the
|
|
28
|
+
* viewer does not have permission to edit. `actions` are ignored.
|
|
29
|
+
*/
|
|
30
|
+
locked?: boolean;
|
|
31
|
+
/** Tooltip string shown when hovering the lock icon. */
|
|
32
|
+
lockedTooltip?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Metadata rows rendered beneath the thumbnail. Each entry becomes a
|
|
35
|
+
* full-width, left-aligned row in a vertical Stack. Block content fills the
|
|
36
|
+
* row; inline content (e.g. a Sticker) hugs the left. Region is omitted when
|
|
37
|
+
* the array is empty or undefined.
|
|
38
|
+
*/
|
|
39
|
+
metadata?: ReactNode[];
|
|
40
|
+
/** Optional click handler for the whole tile. When provided, the tile is keyboard-activatable. */
|
|
41
|
+
onClick?: (e: MouseEvent<HTMLDivElement>) => void;
|
|
42
|
+
}
|
|
43
|
+
declare const ImageTile: ({
|
|
44
|
+
src,
|
|
45
|
+
alt,
|
|
46
|
+
objectFit,
|
|
47
|
+
selectable,
|
|
48
|
+
selected,
|
|
49
|
+
onSelectedChange,
|
|
50
|
+
selectionLabel,
|
|
51
|
+
actions,
|
|
52
|
+
locked,
|
|
53
|
+
lockedTooltip,
|
|
54
|
+
metadata,
|
|
55
|
+
onClick,
|
|
56
|
+
...props
|
|
57
|
+
}: ImageTileProps) => _$react_jsx_runtime0.JSX.Element;
|
|
58
|
+
//#endregion
|
|
59
|
+
export { ImageTile, ImageTile as default, ImageTileProps };
|
|
60
|
+
//# sourceMappingURL=ImageTile.d.cts.map
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { i as TextAction } from "./Action-B10lxofb.mjs";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
import { ComponentPropsWithoutRef, MouseEvent, ReactNode } from "react";
|
|
4
|
+
|
|
5
|
+
//#region components/ImageTile/ImageTile.d.ts
|
|
6
|
+
interface ImageTileProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
7
|
+
/** URL of the thumbnail. While loading shows shimmer; on error shows the empty fallback. */
|
|
8
|
+
src: string | null;
|
|
9
|
+
/** Alt text for the thumbnail. Also seeds the default checkbox label. */
|
|
10
|
+
alt?: string;
|
|
11
|
+
/** How the thumbnail fills its area. `cover` crops overflow; `contain` letterboxes to fit. Defaults to `cover`. */
|
|
12
|
+
objectFit?: 'cover' | 'contain';
|
|
13
|
+
/** Enables the selection checkbox (top-left). */
|
|
14
|
+
selectable?: boolean;
|
|
15
|
+
/** Controlled checked state for the selection checkbox. */
|
|
16
|
+
selected?: boolean;
|
|
17
|
+
/** Called with the new checked value when the checkbox is toggled. */
|
|
18
|
+
onSelectedChange?: (selected: boolean) => void;
|
|
19
|
+
/** Accessible label for the checkbox. Defaults to "Select {alt}" or "Select image". */
|
|
20
|
+
selectionLabel?: string;
|
|
21
|
+
/**
|
|
22
|
+
* Action menu items rendered behind a 3-dot IconButton in the top-right.
|
|
23
|
+
* Ignored when `locked` is true. Pass an empty array (or omit) to hide the menu.
|
|
24
|
+
*/
|
|
25
|
+
actions?: TextAction[];
|
|
26
|
+
/**
|
|
27
|
+
* Replaces the action menu with a non-interactive lock icon. Indicates the
|
|
28
|
+
* viewer does not have permission to edit. `actions` are ignored.
|
|
29
|
+
*/
|
|
30
|
+
locked?: boolean;
|
|
31
|
+
/** Tooltip string shown when hovering the lock icon. */
|
|
32
|
+
lockedTooltip?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Metadata rows rendered beneath the thumbnail. Each entry becomes a
|
|
35
|
+
* full-width, left-aligned row in a vertical Stack. Block content fills the
|
|
36
|
+
* row; inline content (e.g. a Sticker) hugs the left. Region is omitted when
|
|
37
|
+
* the array is empty or undefined.
|
|
38
|
+
*/
|
|
39
|
+
metadata?: ReactNode[];
|
|
40
|
+
/** Optional click handler for the whole tile. When provided, the tile is keyboard-activatable. */
|
|
41
|
+
onClick?: (e: MouseEvent<HTMLDivElement>) => void;
|
|
42
|
+
}
|
|
43
|
+
declare const ImageTile: ({
|
|
44
|
+
src,
|
|
45
|
+
alt,
|
|
46
|
+
objectFit,
|
|
47
|
+
selectable,
|
|
48
|
+
selected,
|
|
49
|
+
onSelectedChange,
|
|
50
|
+
selectionLabel,
|
|
51
|
+
actions,
|
|
52
|
+
locked,
|
|
53
|
+
lockedTooltip,
|
|
54
|
+
metadata,
|
|
55
|
+
onClick,
|
|
56
|
+
...props
|
|
57
|
+
}: ImageTileProps) => _$react_jsx_runtime0.JSX.Element;
|
|
58
|
+
//#endregion
|
|
59
|
+
export { ImageTile, ImageTile as default, ImageTileProps };
|
|
60
|
+
//# sourceMappingURL=ImageTile.d.mts.map
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { t as PseudoClassProps } from "./PseudoClassProps-mZgO_iZJ.mjs";
|
|
2
|
+
import { r as ButtonProps } from "./Button-DqDLGURJ.mjs";
|
|
3
|
+
import { n as InputSizes, t as InputMixinProps } from "./input-BCmP106-.mjs";
|
|
4
|
+
import * as _$styled_components0 from "styled-components";
|
|
5
|
+
import * as _$react from "react";
|
|
6
|
+
import { ComponentPropsWithoutRef, MouseEventHandler, ReactElement, ReactNode } from "react";
|
|
7
|
+
|
|
8
|
+
//#region components/Input/Input.d.ts
|
|
9
|
+
declare const ClearButton: _$styled_components0.StyledComponent<_$react.ForwardRefExoticComponent<Omit<ButtonProps, "ref"> & _$react.RefAttributes<HTMLButtonElement>>, any, {
|
|
10
|
+
width: "icon";
|
|
11
|
+
variant: "basic";
|
|
12
|
+
} & PseudoClassProps, "variant" | "width">;
|
|
13
|
+
interface StyledInputProps extends InputMixinProps {
|
|
14
|
+
$leftIcon?: ReactNode;
|
|
15
|
+
$hasRightItem?: boolean;
|
|
16
|
+
}
|
|
17
|
+
interface InputProps extends Omit<ComponentPropsWithoutRef<'input'>, 'size'>, Omit<InputMixinProps, '$size'> {
|
|
18
|
+
/**
|
|
19
|
+
* Size of the input. If you need the HTML size attr, use inputSize.
|
|
20
|
+
*/
|
|
21
|
+
size?: InputSizes;
|
|
22
|
+
/**
|
|
23
|
+
* `size` HTML attr on `<input>`
|
|
24
|
+
*/
|
|
25
|
+
inputSize?: ComponentPropsWithoutRef<'input'>['size'];
|
|
26
|
+
leftIcon?: StyledInputProps['$leftIcon'];
|
|
27
|
+
hasRightItem?: boolean;
|
|
28
|
+
}
|
|
29
|
+
declare const Input: _$react.ForwardRefExoticComponent<InputProps & _$react.RefAttributes<HTMLInputElement>>;
|
|
30
|
+
interface InputGroupProps extends ComponentPropsWithoutRef<'div'>, Omit<InputMixinProps, '$size'> {
|
|
31
|
+
/**
|
|
32
|
+
* Input
|
|
33
|
+
*/
|
|
34
|
+
children: ReactElement<InputProps>;
|
|
35
|
+
/**
|
|
36
|
+
* Size of the input. If you need the HTML size attr, use inputSize.
|
|
37
|
+
*/
|
|
38
|
+
size?: InputSizes;
|
|
39
|
+
/**
|
|
40
|
+
* Icon to render to the left of the input field.
|
|
41
|
+
*
|
|
42
|
+
* Import icon from `@persona-id/icons`. Use 24px for `lg` input size.
|
|
43
|
+
*/
|
|
44
|
+
leftIcon?: ReactNode;
|
|
45
|
+
/**
|
|
46
|
+
* Renders clear button to the right and calls function upon click.
|
|
47
|
+
*/
|
|
48
|
+
onClear?: MouseEventHandler<HTMLButtonElement>;
|
|
49
|
+
/**
|
|
50
|
+
* Button to be rendered to the right of the input
|
|
51
|
+
*/
|
|
52
|
+
rightButton?: ReactElement<ButtonProps>;
|
|
53
|
+
/**
|
|
54
|
+
* Disabled prop will be passed down to `<Input>`
|
|
55
|
+
*/
|
|
56
|
+
disabled?: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* Suffix text to be shown to the right of the input (inside the input field)
|
|
59
|
+
*/
|
|
60
|
+
suffix?: string;
|
|
61
|
+
}
|
|
62
|
+
declare const InputGroup: _$react.ForwardRefExoticComponent<InputGroupProps & _$react.RefAttributes<HTMLDivElement>>;
|
|
63
|
+
//#endregion
|
|
64
|
+
export { InputProps as a, InputGroupProps as i, Input as n, InputGroup as r, ClearButton as t };
|
|
65
|
+
//# sourceMappingURL=Input-Cv5qieRg.d.mts.map
|