@arc-ui/components 11.4.2 → 11.6.0
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/Alert/Alert.cjs.d.ts +57 -0
- package/dist/Alert/Alert.cjs.js +142 -0
- package/dist/Alert/Alert.esm.d.ts +57 -0
- package/dist/Alert/Alert.esm.js +134 -0
- package/dist/Alert/package.json +7 -0
- package/dist/Align/Align.cjs.js +6 -6
- package/dist/Align/Align.esm.js +2 -2
- package/dist/Badge/Badge.cjs.js +7 -7
- package/dist/Badge/Badge.esm.js +4 -4
- package/dist/Base/Base.cjs.d.ts +1 -1
- package/dist/Base/Base.cjs.js +2 -2
- package/dist/Base/Base.esm.d.ts +1 -1
- package/dist/Base/Base.esm.js +2 -2
- package/dist/BrandLogo/BrandLogo.cjs.d.ts +1 -1
- package/dist/BrandLogo/BrandLogo.cjs.js +4 -4
- package/dist/BrandLogo/BrandLogo.esm.d.ts +1 -1
- package/dist/BrandLogo/BrandLogo.esm.js +4 -4
- package/dist/Breadcrumbs/Breadcrumbs.cjs.d.ts +1 -61
- package/dist/Breadcrumbs/Breadcrumbs.cjs.js +11 -643
- package/dist/Breadcrumbs/Breadcrumbs.esm.d.ts +1 -61
- package/dist/Breadcrumbs/Breadcrumbs.esm.js +10 -642
- package/dist/Button/Button.cjs.d.ts +1 -1
- package/dist/Button/Button.cjs.js +6 -5
- package/dist/Button/Button.esm.d.ts +1 -1
- package/dist/Button/Button.esm.js +6 -5
- package/dist/Card/Card.cjs.d.ts +1 -130
- package/dist/Card/Card.cjs.js +12 -119
- package/dist/Card/Card.esm.d.ts +1 -130
- package/dist/Card/Card.esm.js +11 -118
- package/dist/Checkbox/Checkbox.cjs.d.ts +1 -59
- package/dist/Checkbox/Checkbox.cjs.js +13 -55
- package/dist/Checkbox/Checkbox.esm.d.ts +1 -59
- package/dist/Checkbox/Checkbox.esm.js +12 -54
- package/dist/Clock/Clock.cjs.js +6 -6
- package/dist/Clock/Clock.esm.js +1 -1
- package/dist/Columns/Columns.cjs.d.ts +1 -76
- package/dist/Columns/Columns.cjs.js +6 -52
- package/dist/Columns/Columns.esm.d.ts +1 -76
- package/dist/Columns/Columns.esm.js +5 -51
- package/dist/Curve/Curve.cjs.d.ts +1 -1
- package/dist/Curve/Curve.cjs.js +3 -3
- package/dist/Curve/Curve.esm.d.ts +1 -1
- package/dist/Curve/Curve.esm.js +3 -3
- package/dist/Disclosure/Disclosure.cjs.d.ts +1 -1
- package/dist/Disclosure/Disclosure.cjs.js +8 -8
- package/dist/Disclosure/Disclosure.esm.d.ts +1 -1
- package/dist/Disclosure/Disclosure.esm.js +4 -4
- package/dist/DisclosureMini/DisclosureMini.cjs.d.ts +1 -0
- package/dist/DisclosureMini/DisclosureMini.cjs.js +16 -0
- package/dist/DisclosureMini/DisclosureMini.esm.d.ts +1 -0
- package/dist/DisclosureMini/DisclosureMini.esm.js +8 -0
- package/dist/DisclosureMini/package.json +7 -0
- package/dist/Elevation/Elevation.cjs.d.ts +4 -0
- package/dist/Elevation/Elevation.cjs.js +7 -5
- package/dist/Elevation/Elevation.esm.d.ts +4 -0
- package/dist/Elevation/Elevation.esm.js +4 -2
- package/dist/Filter/Filter.cjs.d.ts +1 -0
- package/dist/Filter/Filter.cjs.js +13 -0
- package/dist/Filter/Filter.esm.d.ts +1 -0
- package/dist/Filter/Filter.esm.js +5 -0
- package/dist/Filter/package.json +7 -0
- package/dist/FormControl/FormControl.cjs.d.ts +1 -1
- package/dist/FormControl/FormControl.cjs.js +8 -6
- package/dist/FormControl/FormControl.esm.d.ts +1 -1
- package/dist/FormControl/FormControl.esm.js +8 -6
- package/dist/Group/Group.cjs.d.ts +1 -46
- package/dist/Group/Group.cjs.js +6 -43
- package/dist/Group/Group.esm.d.ts +1 -46
- package/dist/Group/Group.esm.js +5 -42
- package/dist/Heading/Heading.cjs.d.ts +1 -1
- package/dist/Heading/Heading.cjs.js +4 -4
- package/dist/Heading/Heading.esm.d.ts +1 -1
- package/dist/Heading/Heading.esm.js +4 -4
- package/dist/Icon/Icon.cjs.d.ts +1 -1
- package/dist/Icon/Icon.cjs.js +4 -4
- package/dist/Icon/Icon.esm.d.ts +1 -1
- package/dist/Icon/Icon.esm.js +4 -4
- package/dist/Image/Image.cjs.d.ts +1 -1
- package/dist/Image/Image.cjs.js +3 -3
- package/dist/Image/Image.esm.d.ts +1 -1
- package/dist/Image/Image.esm.js +3 -3
- package/dist/Markup/Markup.cjs.js +6 -6
- package/dist/Markup/Markup.esm.js +2 -2
- package/dist/Pagination/Pagination.cjs.d.ts +20 -0
- package/dist/Pagination/Pagination.cjs.js +87 -0
- package/dist/Pagination/Pagination.esm.d.ts +20 -0
- package/dist/Pagination/Pagination.esm.js +79 -0
- package/dist/Pagination/package.json +7 -0
- package/dist/PaginationSimple/PaginationSimple.cjs.d.ts +28 -0
- package/dist/PaginationSimple/PaginationSimple.cjs.js +47 -0
- package/dist/PaginationSimple/PaginationSimple.esm.d.ts +28 -0
- package/dist/PaginationSimple/PaginationSimple.esm.js +39 -0
- package/dist/PaginationSimple/package.json +7 -0
- package/dist/Poster/Poster.cjs.d.ts +1 -81
- package/dist/Poster/Poster.cjs.js +8 -45
- package/dist/Poster/Poster.esm.d.ts +1 -81
- package/dist/Poster/Poster.esm.js +7 -44
- package/dist/ProgressBar/ProgressBar.cjs.js +22 -41
- package/dist/ProgressBar/ProgressBar.esm.js +13 -32
- package/dist/RadioGroup/RadioGroup.cjs.d.ts +1 -85
- package/dist/RadioGroup/RadioGroup.cjs.js +12 -68
- package/dist/RadioGroup/RadioGroup.esm.d.ts +1 -85
- package/dist/RadioGroup/RadioGroup.esm.js +11 -67
- package/dist/Rule/Rule.cjs.js +5 -5
- package/dist/Rule/Rule.esm.js +2 -2
- package/dist/ScrollToTop/ScrollToTop.cjs.d.ts +25 -0
- package/dist/ScrollToTop/ScrollToTop.cjs.js +68 -0
- package/dist/ScrollToTop/ScrollToTop.esm.d.ts +25 -0
- package/dist/ScrollToTop/ScrollToTop.esm.js +60 -0
- package/dist/ScrollToTop/package.json +7 -0
- package/dist/Section/Section.cjs.d.ts +1 -1
- package/dist/Section/Section.cjs.js +2 -2
- package/dist/Section/Section.esm.d.ts +1 -1
- package/dist/Section/Section.esm.js +2 -2
- package/dist/Select/Select.cjs.d.ts +2 -2
- package/dist/Select/Select.cjs.js +9 -8
- package/dist/Select/Select.esm.d.ts +2 -2
- package/dist/Select/Select.esm.js +9 -8
- package/dist/SiteFooter/SiteFooter.cjs.d.ts +2 -62
- package/dist/SiteFooter/SiteFooter.cjs.js +14 -69
- package/dist/SiteFooter/SiteFooter.esm.d.ts +2 -62
- package/dist/SiteFooter/SiteFooter.esm.js +13 -67
- package/dist/SiteHeader/SiteHeader.cjs.d.ts +2 -252
- package/dist/SiteHeader/SiteHeader.cjs.js +17 -661
- package/dist/SiteHeader/SiteHeader.esm.d.ts +2 -252
- package/dist/SiteHeader/SiteHeader.esm.js +15 -659
- package/dist/Surface/Surface.cjs.d.ts +1 -1
- package/dist/Surface/Surface.cjs.js +2 -2
- package/dist/Surface/Surface.esm.d.ts +1 -1
- package/dist/Surface/Surface.esm.js +2 -2
- package/dist/Switch/Switch.cjs.d.ts +2 -2
- package/dist/Switch/Switch.cjs.js +10 -8
- package/dist/Switch/Switch.esm.d.ts +2 -2
- package/dist/Switch/Switch.esm.js +10 -8
- package/dist/Tag/Tag.cjs.js +39 -18
- package/dist/Tag/Tag.esm.js +31 -10
- package/dist/Text/Text.cjs.d.ts +1 -1
- package/dist/Text/Text.cjs.js +4 -4
- package/dist/Text/Text.esm.d.ts +1 -1
- package/dist/Text/Text.esm.js +4 -4
- package/dist/TextArea/TextArea.cjs.d.ts +61 -0
- package/dist/TextArea/TextArea.cjs.js +87 -0
- package/dist/TextArea/TextArea.esm.d.ts +61 -0
- package/dist/TextArea/TextArea.esm.js +79 -0
- package/dist/TextArea/package.json +7 -0
- package/dist/TextInput/TextInput.cjs.d.ts +1 -75
- package/dist/TextInput/TextInput.cjs.js +13 -76
- package/dist/TextInput/TextInput.esm.d.ts +1 -75
- package/dist/TextInput/TextInput.esm.js +12 -75
- package/dist/UniversalHeader/UniversalHeader.cjs.d.ts +1 -26
- package/dist/UniversalHeader/UniversalHeader.cjs.js +5 -30
- package/dist/UniversalHeader/UniversalHeader.esm.d.ts +1 -26
- package/dist/UniversalHeader/UniversalHeader.esm.js +4 -29
- package/dist/VerticalSpace/VerticalSpace.cjs.d.ts +1 -1
- package/dist/VerticalSpace/VerticalSpace.cjs.js +2 -2
- package/dist/VerticalSpace/VerticalSpace.esm.d.ts +1 -1
- package/dist/VerticalSpace/VerticalSpace.esm.js +2 -2
- package/dist/_shared/cjs/{Base-e2b846fe.js → Base-569e4334.js} +3 -3
- package/dist/_shared/cjs/{BrandLogo-3c6102ef.js → BrandLogo-8008f0c4.js} +7 -7
- package/dist/_shared/cjs/Breadcrumbs-8b554370.d.ts +61 -0
- package/dist/_shared/cjs/Breadcrumbs-8b554370.js +106 -0
- package/dist/_shared/cjs/BtIconAlert-637db790.js +38 -0
- package/dist/_shared/cjs/BtIconChevronLeftMid-df952a3e.js +31 -0
- package/dist/_shared/cjs/BtIconCrossAlt2Px-30dc2688.js +29 -0
- package/dist/_shared/cjs/{Button-1af6868c.js → Button-27512fee.js} +16 -37
- package/dist/_shared/cjs/Card-804ab0e5.d.ts +136 -0
- package/dist/_shared/cjs/Card-804ab0e5.js +124 -0
- package/dist/_shared/cjs/Checkbox-21d3c4f6.d.ts +64 -0
- package/dist/_shared/cjs/Checkbox-21d3c4f6.js +62 -0
- package/dist/_shared/cjs/Columns-e90798f8.d.ts +76 -0
- package/dist/_shared/cjs/Columns-e90798f8.js +57 -0
- package/dist/_shared/cjs/{Curve-e72ce25b.js → Curve-b05589d8.js} +6 -6
- package/dist/_shared/cjs/DisclosureMini-067e0319.d.ts +37 -0
- package/dist/_shared/cjs/DisclosureMini-067e0319.js +44 -0
- package/dist/_shared/cjs/Filter-f7d2fbda.d.ts +83 -0
- package/dist/_shared/cjs/Filter-f7d2fbda.js +121 -0
- package/dist/_shared/cjs/{FormControl-d4d9c665.d.ts → FormControl-9aaddd54.d.ts} +6 -29
- package/dist/_shared/cjs/FormControl-9aaddd54.js +96 -0
- package/dist/_shared/cjs/Group-d83f8c2e.d.ts +46 -0
- package/dist/_shared/cjs/Group-d83f8c2e.js +48 -0
- package/dist/_shared/cjs/{Heading-cc38c3ec.js → Heading-d45f6a7f.js} +7 -7
- package/dist/_shared/cjs/{Icon-719d13d4.js → Icon-9ae8dbe1.js} +7 -7
- package/dist/_shared/cjs/{Image-fe760a06.js → Image-3bf4b4f3.js} +8 -8
- package/dist/_shared/cjs/ItemGroup-5af4d600.d.ts +27 -0
- package/dist/_shared/cjs/NavItem-df20237c.d.ts +43 -0
- package/dist/_shared/cjs/NavItemWithSubNav-65f21828.d.ts +49 -0
- package/dist/_shared/cjs/Poster-e05bbe13.d.ts +81 -0
- package/dist/_shared/cjs/Poster-e05bbe13.js +50 -0
- package/dist/_shared/cjs/RadioGroup-81805ef9.d.ts +97 -0
- package/dist/_shared/cjs/RadioGroup-81805ef9.js +70 -0
- package/dist/_shared/cjs/{Section-780f2377.js → Section-48aca5f5.js} +5 -5
- package/dist/_shared/cjs/SiteFooter-c540b5f1.d.ts +62 -0
- package/dist/_shared/cjs/SiteFooter-c540b5f1.js +73 -0
- package/dist/_shared/cjs/SiteHeader-c25ee36e.d.ts +78 -0
- package/dist/_shared/cjs/SiteHeader.rehydrator-f7fa2efe.d.ts +78 -0
- package/dist/_shared/cjs/SiteHeader.rehydrator-f7fa2efe.js +673 -0
- package/dist/_shared/cjs/SubNavItem-a84d1bf4.d.ts +48 -0
- package/dist/_shared/cjs/{Surface-d6b8010e.js → Surface-6da0a78e.js} +8 -8
- package/dist/_shared/cjs/{Text-1d3844be.js → Text-6f2827e6.js} +7 -7
- package/dist/_shared/cjs/TextInput-33314fc4.d.ts +10 -0
- package/dist/_shared/cjs/TextInput-33314fc4.js +78 -0
- package/dist/_shared/cjs/TextInput-7ed03a48.d.ts +75 -0
- package/dist/_shared/cjs/UniversalHeader-cc1d9e5a.d.ts +26 -0
- package/dist/_shared/cjs/UniversalHeader-cc1d9e5a.js +35 -0
- package/dist/_shared/cjs/{VerticalSpace-7aed88ab.js → VerticalSpace-86f697e7.js} +5 -5
- package/dist/_shared/cjs/debounce-506538c5.js +544 -0
- package/dist/_shared/cjs/{index-78b35bc1.js → filter-data-attrs-a30dcf5f.js} +12 -12
- package/dist/_shared/cjs/index-699086a7.d.ts +2 -0
- package/dist/_shared/cjs/index-74488a9f.d.ts +2 -0
- package/dist/_shared/cjs/index-9483ad5f.d.ts +2 -2
- package/dist/_shared/cjs/index-c81c9401.d.ts +3 -3
- package/dist/_shared/cjs/index-e340924e.d.ts +2 -0
- package/dist/_shared/cjs/index-e6d20018.d.ts +3 -0
- package/dist/_shared/cjs/index-eb06f640.d.ts +2 -0
- package/dist/_shared/cjs/index-f419cf04.d.ts +2 -0
- package/dist/_shared/cjs/{suffix-modifier-edf7851e.js → suffix-modifier-1ee2da04.js} +2 -2
- package/dist/_shared/esm/{Base-c235dc45.js → Base-6c01e0ec.js} +1 -1
- package/dist/_shared/esm/{BrandLogo-4f13fe85.js → BrandLogo-56699561.js} +3 -3
- package/dist/_shared/esm/Breadcrumbs-04590057.d.ts +61 -0
- package/dist/_shared/esm/Breadcrumbs-04590057.js +100 -0
- package/dist/_shared/esm/BtIconAlert-55a6ed5c.js +32 -0
- package/dist/_shared/esm/BtIconChevronLeftMid-9f4f3a3d.js +25 -0
- package/dist/_shared/esm/BtIconCrossAlt2Px-a6a9f431.js +23 -0
- package/dist/_shared/esm/{Button-10700df4.js → Button-d319fa11.js} +6 -27
- package/dist/_shared/esm/Card-e79eb6c8.d.ts +136 -0
- package/dist/_shared/esm/Card-e79eb6c8.js +118 -0
- package/dist/_shared/esm/Checkbox-94300d8c.d.ts +64 -0
- package/dist/_shared/esm/Checkbox-94300d8c.js +56 -0
- package/dist/_shared/esm/Columns-8704515b.d.ts +76 -0
- package/dist/_shared/esm/Columns-8704515b.js +51 -0
- package/dist/_shared/esm/{Curve-50697f7e.js → Curve-3e87b1bc.js} +2 -2
- package/dist/_shared/esm/DisclosureMini-022beae3.d.ts +37 -0
- package/dist/_shared/esm/DisclosureMini-022beae3.js +38 -0
- package/dist/_shared/esm/Filter-41b391e3.d.ts +83 -0
- package/dist/_shared/esm/Filter-41b391e3.js +115 -0
- package/dist/_shared/esm/{FormControl-2cb96de7.d.ts → FormControl-5e3fdca3.d.ts} +6 -29
- package/dist/_shared/esm/FormControl-5e3fdca3.js +88 -0
- package/dist/_shared/esm/Group-d62c3f56.d.ts +46 -0
- package/dist/_shared/esm/Group-d62c3f56.js +42 -0
- package/dist/_shared/esm/{Heading-eb1e42db.js → Heading-b61432fb.js} +3 -3
- package/dist/_shared/esm/{Icon-61f7237a.js → Icon-fd247973.js} +3 -3
- package/dist/_shared/esm/{Image-c0f3d42f.js → Image-3596ce55.js} +2 -2
- package/dist/_shared/esm/ItemGroup-5af4d600.d.ts +27 -0
- package/dist/_shared/esm/NavItem-df20237c.d.ts +43 -0
- package/dist/_shared/esm/NavItemWithSubNav-65f21828.d.ts +49 -0
- package/dist/_shared/esm/Poster-107d6954.d.ts +81 -0
- package/dist/_shared/esm/Poster-107d6954.js +44 -0
- package/dist/_shared/esm/RadioGroup-1fd0f389.d.ts +97 -0
- package/dist/_shared/esm/RadioGroup-1fd0f389.js +64 -0
- package/dist/_shared/esm/{Section-7bc71e26.js → Section-b8038d66.js} +1 -1
- package/dist/_shared/esm/SiteFooter-8075a9bd.d.ts +62 -0
- package/dist/_shared/esm/SiteFooter-8075a9bd.js +67 -0
- package/dist/_shared/esm/SiteHeader-c25ee36e.d.ts +78 -0
- package/dist/_shared/esm/SiteHeader.rehydrator-4da8ac64.d.ts +78 -0
- package/dist/_shared/esm/SiteHeader.rehydrator-4da8ac64.js +666 -0
- package/dist/_shared/esm/SubNavItem-a84d1bf4.d.ts +48 -0
- package/dist/_shared/esm/{Surface-bf201530.js → Surface-bb100ef8.js} +1 -1
- package/dist/_shared/esm/{Text-6b958ad8.js → Text-00e9743b.js} +3 -3
- package/dist/_shared/esm/TextInput-1631dbc4.d.ts +10 -0
- package/dist/_shared/esm/TextInput-1631dbc4.js +72 -0
- package/dist/_shared/esm/TextInput-7ed03a48.d.ts +75 -0
- package/dist/_shared/esm/UniversalHeader-7926abde.d.ts +26 -0
- package/dist/_shared/esm/UniversalHeader-7926abde.js +29 -0
- package/dist/_shared/esm/{VerticalSpace-3579b20e.js → VerticalSpace-93980c9c.js} +1 -1
- package/dist/_shared/esm/debounce-e228705f.js +542 -0
- package/dist/_shared/esm/{index-229fc864.js → filter-data-attrs-afdb7d32.js} +12 -12
- package/dist/_shared/esm/index-699086a7.d.ts +2 -0
- package/dist/_shared/esm/index-74488a9f.d.ts +2 -0
- package/dist/_shared/esm/index-9483ad5f.d.ts +2 -2
- package/dist/_shared/esm/index-c81c9401.d.ts +3 -3
- package/dist/_shared/esm/index-e340924e.d.ts +2 -0
- package/dist/_shared/esm/index-e6d20018.d.ts +3 -0
- package/dist/_shared/esm/index-eb06f640.d.ts +2 -0
- package/dist/_shared/esm/index-f419cf04.d.ts +2 -0
- package/dist/_shared/esm/{suffix-modifier-f5e28822.js → suffix-modifier-7e640670.js} +1 -1
- package/dist/index.es.js +304 -113
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +534 -341
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/types/components/Alert/Alert.d.ts +56 -0
- package/dist/types/components/Alert/index.d.ts +1 -0
- package/dist/types/components/Checkbox/Checkbox.d.ts +6 -1
- package/dist/types/components/DisclosureMini/DisclosureMini.d.ts +36 -0
- package/dist/types/components/DisclosureMini/index.d.ts +1 -0
- package/dist/types/components/Elevation/Elevation.d.ts +4 -0
- package/dist/types/components/Filter/Filter.d.ts +38 -0
- package/dist/types/components/Filter/FilterControls/FilterControl/FilterControl.d.ts +16 -0
- package/dist/types/components/Filter/FilterControls/FilterControls.d.ts +12 -0
- package/dist/types/components/Filter/FilterItems/FilterItem/FilterItem.d.ts +12 -0
- package/dist/types/components/Filter/FilterItems/FilterItems.d.ts +12 -0
- package/dist/types/components/Filter/index.d.ts +1 -0
- package/dist/types/components/FormControl/FormControl.d.ts +4 -0
- package/dist/types/components/Pagination/Pagination.d.ts +19 -0
- package/dist/types/components/Pagination/index.d.ts +1 -0
- package/dist/types/components/PaginationSimple/PaginationSimple.d.ts +27 -0
- package/dist/types/components/PaginationSimple/index.d.ts +1 -0
- package/dist/types/components/RadioGroup/RadioGroup.d.ts +1 -1
- package/dist/types/components/ScrollToTop/ScrollToTop.d.ts +24 -0
- package/dist/types/components/ScrollToTop/index.d.ts +1 -0
- package/dist/types/components/Select/Select.d.ts +1 -1
- package/dist/types/components/SiteHeader/SiteHeader.d.ts +2 -0
- package/dist/types/components/SiteHeader/components/NodeItem/NodeItem.d.ts +8 -0
- package/dist/types/components/Switch/Switch.d.ts +1 -1
- package/dist/types/components/TextArea/TextArea.d.ts +60 -0
- package/dist/types/components/TextArea/index.d.ts +1 -0
- package/dist/types/components/TextInput/TextInput.d.ts +1 -1
- package/dist/types/components/index.d.ts +2 -0
- package/dist/types/hooks/use-pagination.d.ts +1 -0
- package/dist/types/styles.d.ts +10 -4
- package/package.json +4 -4
- package/dist/_shared/cjs/FormControl-d4d9c665.js +0 -148
- package/dist/_shared/esm/FormControl-2cb96de7.js +0 -139
- package/dist/types/components/FormControl/FormControlDisclosure/FormControlDisclosure.d.ts +0 -28
- package/dist/types/components/FormControl/FormControlDisclosure/index.d.ts +0 -1
- /package/dist/_shared/cjs/{Base-e2b846fe.d.ts → Base-569e4334.d.ts} +0 -0
- /package/dist/_shared/cjs/{BrandLogo-3c6102ef.d.ts → BrandLogo-8008f0c4.d.ts} +0 -0
- /package/dist/_shared/cjs/{Button-1af6868c.d.ts → Button-27512fee.d.ts} +0 -0
- /package/dist/_shared/cjs/{Curve-e72ce25b.d.ts → Curve-b05589d8.d.ts} +0 -0
- /package/dist/_shared/cjs/{Heading-cc38c3ec.d.ts → Heading-d45f6a7f.d.ts} +0 -0
- /package/dist/_shared/cjs/{Icon-719d13d4.d.ts → Icon-9ae8dbe1.d.ts} +0 -0
- /package/dist/_shared/cjs/{Image-fe760a06.d.ts → Image-3bf4b4f3.d.ts} +0 -0
- /package/dist/_shared/cjs/{Section-780f2377.d.ts → Section-48aca5f5.d.ts} +0 -0
- /package/dist/_shared/cjs/{Surface-d6b8010e.d.ts → Surface-6da0a78e.d.ts} +0 -0
- /package/dist/_shared/cjs/{Text-1d3844be.d.ts → Text-6f2827e6.d.ts} +0 -0
- /package/dist/_shared/cjs/{VerticalSpace-7aed88ab.d.ts → VerticalSpace-86f697e7.d.ts} +0 -0
- /package/dist/_shared/cjs/{index-78b35bc1.d.ts → filter-data-attrs-a30dcf5f.d.ts} +0 -0
- /package/dist/_shared/cjs/{suffix-modifier-edf7851e.d.ts → suffix-modifier-1ee2da04.d.ts} +0 -0
- /package/dist/_shared/esm/{Base-c235dc45.d.ts → Base-6c01e0ec.d.ts} +0 -0
- /package/dist/_shared/esm/{BrandLogo-4f13fe85.d.ts → BrandLogo-56699561.d.ts} +0 -0
- /package/dist/_shared/esm/{Button-10700df4.d.ts → Button-d319fa11.d.ts} +0 -0
- /package/dist/_shared/esm/{Curve-50697f7e.d.ts → Curve-3e87b1bc.d.ts} +0 -0
- /package/dist/_shared/esm/{Heading-eb1e42db.d.ts → Heading-b61432fb.d.ts} +0 -0
- /package/dist/_shared/esm/{Icon-61f7237a.d.ts → Icon-fd247973.d.ts} +0 -0
- /package/dist/_shared/esm/{Image-c0f3d42f.d.ts → Image-3596ce55.d.ts} +0 -0
- /package/dist/_shared/esm/{Section-7bc71e26.d.ts → Section-b8038d66.d.ts} +0 -0
- /package/dist/_shared/esm/{Surface-bf201530.d.ts → Surface-bb100ef8.d.ts} +0 -0
- /package/dist/_shared/esm/{Text-6b958ad8.d.ts → Text-00e9743b.d.ts} +0 -0
- /package/dist/_shared/esm/{VerticalSpace-3579b20e.d.ts → VerticalSpace-93980c9c.d.ts} +0 -0
- /package/dist/_shared/esm/{index-229fc864.d.ts → filter-data-attrs-afdb7d32.d.ts} +0 -0
- /package/dist/_shared/esm/{suffix-modifier-f5e28822.d.ts → suffix-modifier-7e640670.d.ts} +0 -0
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var React = require('react');
|
|
4
|
+
var debounce = require('./debounce-506538c5.js');
|
|
5
|
+
var BtIconChevronRight2Px = require('./BtIconChevronRight2Px-a8e40136.js');
|
|
6
|
+
var Icon = require('./Icon-9ae8dbe1.js');
|
|
7
|
+
var filterDataAttrs = require('./filter-data-attrs-a30dcf5f.js');
|
|
8
|
+
var index = require('./index-45bfb67b.js');
|
|
9
|
+
var handleLinkClick = require('./handle-link-click-17a44cf4.js');
|
|
10
|
+
|
|
11
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
|
+
|
|
13
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
14
|
+
|
|
15
|
+
var BreadcrumbsItem = function (_a) {
|
|
16
|
+
var spacerIconAfter = _a.spacerIconAfter, spacerIconBefore = _a.spacerIconBefore, children = _a.children;
|
|
17
|
+
return (React__default["default"].createElement("li", { className: "arc-Breadcrumbs-item" },
|
|
18
|
+
spacerIconBefore && (React__default["default"].createElement("div", { className: "arc-Breadcrumbs-spacerIcon", "data-testid": "arc-chevron-left-2px" },
|
|
19
|
+
React__default["default"].createElement(Icon.Icon, { icon: BtIconChevronRight2Px.BtIconChevronLeft2Px_2 }))),
|
|
20
|
+
children,
|
|
21
|
+
spacerIconAfter && (React__default["default"].createElement("div", { className: "arc-Breadcrumbs-spacerIcon" },
|
|
22
|
+
React__default["default"].createElement(Icon.Icon, { icon: BtIconChevronRight2Px.BtIconChevronRight2Px_2 })))));
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
var BreadcrumbsLink = React__default["default"].forwardRef(function (_a, ref) {
|
|
26
|
+
var onClick = _a.onClick, href = _a.href, isActive = _a.isActive, children = _a.children;
|
|
27
|
+
return (React__default["default"].createElement(React__default["default"].Fragment, null, isActive || href === undefined ? (React__default["default"].createElement("span", filterDataAttrs.__assign({}, (isActive && { "aria-hidden": "true" }), { onClick: onClick, className: index.classNames({
|
|
28
|
+
"arc-Breadcrumbs-text": true,
|
|
29
|
+
"arc-Breadcrumbs-text--active": isActive
|
|
30
|
+
}) }), children)) : (React__default["default"].createElement("a", filterDataAttrs.__assign({}, (onClick && ref
|
|
31
|
+
? { onClick: onClick }
|
|
32
|
+
: { onClick: handleLinkClick.handleLinkClick({ handler: onClick }) }), { className: "arc-Breadcrumbs-text", ref: ref, href: href }), children))));
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
/** Use `Breadcrumbs` to add a secondary navigation scheme that reveals the user’s location. Each item should be wrapped with `Breadcrumbs.Item` */
|
|
36
|
+
var Breadcrumbs = function (_a) {
|
|
37
|
+
var isLight = _a.isLight, children = _a.children;
|
|
38
|
+
var breadcrumbsList = React.useRef(null);
|
|
39
|
+
var _b = React.useState(false), isCompressed = _b[0], setIsCompressed = _b[1];
|
|
40
|
+
var _c = React.useState(false), showBackTrail = _c[0], setShowBackTrail = _c[1];
|
|
41
|
+
React.useEffect(function () {
|
|
42
|
+
React__default["default"].Children.map(children, function (item) {
|
|
43
|
+
if (item && item.type !== BreadcrumbsItem) {
|
|
44
|
+
throw new Error("Illegal child passed to <Breadcrumbs />. Ensure to only use <Breadcrumbs.Item />");
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
}, [children]);
|
|
48
|
+
React.useEffect(function () {
|
|
49
|
+
var handleResize = debounce.debounce_1(function () {
|
|
50
|
+
var _a;
|
|
51
|
+
setShowBackTrail(false);
|
|
52
|
+
setIsCompressed(false);
|
|
53
|
+
if (window.innerWidth < 426) {
|
|
54
|
+
setShowBackTrail(true);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* TODO! Revise this if statement
|
|
58
|
+
*/
|
|
59
|
+
if (children != null &&
|
|
60
|
+
React__default["default"].Children.count(children) > 2 &&
|
|
61
|
+
breadcrumbsList.current != null &&
|
|
62
|
+
(breadcrumbsList.current.offsetWidth ===
|
|
63
|
+
((_a = breadcrumbsList.current.parentElement) === null || _a === void 0 ? void 0 : _a.offsetWidth) ||
|
|
64
|
+
breadcrumbsList.current.offsetHeight > 24)) {
|
|
65
|
+
setIsCompressed(true);
|
|
66
|
+
}
|
|
67
|
+
}, 200);
|
|
68
|
+
handleResize();
|
|
69
|
+
window.addEventListener("resize", handleResize);
|
|
70
|
+
return function () {
|
|
71
|
+
window.removeEventListener("resize", handleResize);
|
|
72
|
+
};
|
|
73
|
+
// eslint-disable-next-line
|
|
74
|
+
}, []);
|
|
75
|
+
var items = React__default["default"].Children.toArray(children);
|
|
76
|
+
return (React__default["default"].createElement("nav", { "aria-label": "Breadcrumbs", role: "navigation", className: index.classNames({
|
|
77
|
+
"arc-Breadcrumbs": true,
|
|
78
|
+
"arc-Breadcrumbs--dark": isLight
|
|
79
|
+
}) },
|
|
80
|
+
React__default["default"].createElement("ul", { className: "arc-Breadcrumbs-list", ref: breadcrumbsList }, showBackTrail ? (React__default["default"].createElement(React__default["default"].Fragment, null, items.length < 3 ? (React__default["default"].createElement(Breadcrumbs.Item, { spacerIconBefore: true }, items[0].props.children)) : (React__default["default"].createElement(Breadcrumbs.Item, { spacerIconBefore: true }, items[items.length - 2].props.children)))) : (React__default["default"].createElement(React__default["default"].Fragment, null, isCompressed ? (React__default["default"].createElement(React__default["default"].Fragment, null,
|
|
81
|
+
React__default["default"].createElement(Breadcrumbs.Item, { spacerIconAfter: true }, items[0].props.children),
|
|
82
|
+
React__default["default"].createElement(Breadcrumbs.Item, { spacerIconAfter: true },
|
|
83
|
+
React__default["default"].createElement("button", { className: "arc-Breadcrumbs-expand arc-Breadcrumbs-text", onClick: function () { return setIsCompressed(false); }, "aria-label": "Expand Breadcrumbs", type: "button", "data-testid": "expand-ellipsis" }, "...")),
|
|
84
|
+
React__default["default"].createElement(Breadcrumbs.Item, null, items[items.length - 1].props &&
|
|
85
|
+
items[items.length - 1].props.children &&
|
|
86
|
+
React__default["default"].cloneElement(items[items.length - 1].props.children, {
|
|
87
|
+
isActive: true
|
|
88
|
+
})))) : (React__default["default"].createElement(React__default["default"].Fragment, null,
|
|
89
|
+
items
|
|
90
|
+
.slice(0, items.length - 1)
|
|
91
|
+
.map(function (item, index) {
|
|
92
|
+
return (React__default["default"].createElement(React__default["default"].Fragment, { key: "listItem-".concat(index) },
|
|
93
|
+
React__default["default"].createElement(Breadcrumbs.Item, { spacerIconAfter: true }, item.props.children)));
|
|
94
|
+
}),
|
|
95
|
+
React__default["default"].createElement(Breadcrumbs.Item, null, items[items.length - 1].props &&
|
|
96
|
+
items[items.length - 1].props.children &&
|
|
97
|
+
React__default["default"].cloneElement(items[items.length - 1].props.children, {
|
|
98
|
+
isActive: items.length > 1
|
|
99
|
+
})))))))));
|
|
100
|
+
};
|
|
101
|
+
BreadcrumbsItem.displayName = "Breadcrumbs.Item";
|
|
102
|
+
BreadcrumbsLink.displayName = "Breadcrumbs.Link";
|
|
103
|
+
Breadcrumbs.Item = BreadcrumbsItem;
|
|
104
|
+
Breadcrumbs.Link = BreadcrumbsLink;
|
|
105
|
+
|
|
106
|
+
exports.Breadcrumbs = Breadcrumbs;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var React$1 = require('react');
|
|
4
|
+
|
|
5
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
6
|
+
|
|
7
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React$1);
|
|
8
|
+
|
|
9
|
+
const React = React__default["default"];
|
|
10
|
+
const BtIconAlert = props =>
|
|
11
|
+
/*#__PURE__*/ React.createElement(
|
|
12
|
+
"svg",
|
|
13
|
+
Object.assign(
|
|
14
|
+
{
|
|
15
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
16
|
+
viewBox: "0 0 32 32"
|
|
17
|
+
},
|
|
18
|
+
props
|
|
19
|
+
),
|
|
20
|
+
/*#__PURE__*/ React.createElement("defs", null),
|
|
21
|
+
/*#__PURE__*/ React.createElement("path", {
|
|
22
|
+
d:
|
|
23
|
+
"M16,2A14,14,0,1,0,30,16,14,14,0,0,0,16,2Zm0,27A13,13,0,1,1,29,16,13.01474,13.01474,0,0,1,16,29Z",
|
|
24
|
+
fill: "currentColor"
|
|
25
|
+
}),
|
|
26
|
+
/*#__PURE__*/ React.createElement("path", {
|
|
27
|
+
fill: "currentColor",
|
|
28
|
+
d: "M16 20.99335A1 1 0 1 0 16 22.99335 1 1 0 1 0 16 20.99335z"
|
|
29
|
+
}),
|
|
30
|
+
/*#__PURE__*/ React.createElement("path", {
|
|
31
|
+
d:
|
|
32
|
+
"M16.00488,19.00977a.49972.49972,0,0,0,.5-.5L16.50684,9.5a.5.5,0,0,0-1,0l-.002,9.00977A.5.5,0,0,0,16.00488,19.00977Z",
|
|
33
|
+
fill: "currentColor"
|
|
34
|
+
})
|
|
35
|
+
);
|
|
36
|
+
var BtIconAlert_2 = BtIconAlert;
|
|
37
|
+
|
|
38
|
+
exports.BtIconAlert_2 = BtIconAlert_2;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var React$1 = require('react');
|
|
4
|
+
|
|
5
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
6
|
+
|
|
7
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React$1);
|
|
8
|
+
|
|
9
|
+
const React = React__default["default"];
|
|
10
|
+
const BtIconChevronLeftMid = props =>
|
|
11
|
+
/*#__PURE__*/ React.createElement(
|
|
12
|
+
"svg",
|
|
13
|
+
Object.assign(
|
|
14
|
+
{
|
|
15
|
+
viewBox: "0 0 16 16",
|
|
16
|
+
fill: "none",
|
|
17
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
18
|
+
},
|
|
19
|
+
props
|
|
20
|
+
),
|
|
21
|
+
/*#__PURE__*/ React.createElement("path", {
|
|
22
|
+
fillRule: "evenodd",
|
|
23
|
+
clipRule: "evenodd",
|
|
24
|
+
d:
|
|
25
|
+
"M7.62107 8.00023L10.4697 10.8522C10.5957 10.9785 10.6665 11.1495 10.6665 11.3279C10.6665 11.5063 10.5957 11.6773 10.4697 11.8036C10.4074 11.866 10.3335 11.9155 10.252 11.9493C10.1706 11.983 10.0833 12.0004 9.99507 12.0004C9.9069 12.0004 9.81959 11.983 9.73814 11.9493C9.65669 11.9155 9.5827 11.866 9.52041 11.8036L6.19641 8.47556C6.07061 8.34935 5.99998 8.17842 5.99998 8.00023C5.99998 7.82203 6.07061 7.6511 6.19641 7.52489L9.52041 4.19689C9.5827 4.13449 9.65669 4.08498 9.73814 4.0512C9.81959 4.01741 9.9069 4.00003 9.99507 4.00003C10.0832 4.00003 10.1706 4.01741 10.252 4.0512C10.3335 4.08498 10.4074 4.13449 10.4697 4.19689C10.5957 4.32313 10.6665 4.4942 10.6665 4.67256C10.6665 4.85092 10.5957 5.02199 10.4697 5.14823L7.62107 8.00023Z",
|
|
26
|
+
fill: "currentColor"
|
|
27
|
+
})
|
|
28
|
+
);
|
|
29
|
+
var BtIconChevronLeftMid_2 = BtIconChevronLeftMid;
|
|
30
|
+
|
|
31
|
+
exports.BtIconChevronLeftMid_2 = BtIconChevronLeftMid_2;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var React$1 = require('react');
|
|
4
|
+
|
|
5
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
6
|
+
|
|
7
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React$1);
|
|
8
|
+
|
|
9
|
+
const React = React__default["default"];
|
|
10
|
+
const BtIconCrossAlt2Px = props =>
|
|
11
|
+
/*#__PURE__*/ React.createElement(
|
|
12
|
+
"svg",
|
|
13
|
+
Object.assign(
|
|
14
|
+
{
|
|
15
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
16
|
+
viewBox: "0 0 32 32"
|
|
17
|
+
},
|
|
18
|
+
props
|
|
19
|
+
),
|
|
20
|
+
/*#__PURE__*/ React.createElement("defs", null),
|
|
21
|
+
/*#__PURE__*/ React.createElement("path", {
|
|
22
|
+
d:
|
|
23
|
+
"M17.41406,16l3.793-3.793A.99989.99989,0,0,0,19.793,10.793L16,14.58594l-3.793-3.793A.99989.99989,0,0,0,10.793,12.207L14.58594,16l-3.793,3.793A.99989.99989,0,1,0,12.207,21.207L16,17.41406l3.793,3.793A.99989.99989,0,0,0,21.207,19.793Z",
|
|
24
|
+
fill: "currentColor"
|
|
25
|
+
})
|
|
26
|
+
);
|
|
27
|
+
var BtIconCrossAlt2Px_2 = BtIconCrossAlt2Px;
|
|
28
|
+
|
|
29
|
+
exports.BtIconCrossAlt2Px_2 = BtIconCrossAlt2Px_2;
|
|
@@ -1,47 +1,26 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var filterDataAttrs = require('./filter-data-attrs-a30dcf5f.js');
|
|
4
|
+
var BtIconChevronLeftMid = require('./BtIconChevronLeftMid-df952a3e.js');
|
|
5
5
|
var BtIconChevronRightMid = require('./BtIconChevronRightMid-5a38d855.js');
|
|
6
|
-
var index
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
6
|
+
var index = require('./index-45bfb67b.js');
|
|
7
|
+
var React = require('react');
|
|
8
|
+
var suffixModifier = require('./suffix-modifier-1ee2da04.js');
|
|
9
|
+
var Icon = require('./Icon-9ae8dbe1.js');
|
|
10
|
+
var Surface = require('./Surface-6da0a78e.js');
|
|
10
11
|
|
|
11
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
13
|
|
|
13
|
-
var React__default = /*#__PURE__*/_interopDefaultLegacy(React
|
|
14
|
-
|
|
15
|
-
const React = React__default["default"];
|
|
16
|
-
const BtIconChevronLeftMid = props =>
|
|
17
|
-
/*#__PURE__*/ React.createElement(
|
|
18
|
-
"svg",
|
|
19
|
-
Object.assign(
|
|
20
|
-
{
|
|
21
|
-
viewBox: "0 0 16 16",
|
|
22
|
-
fill: "none",
|
|
23
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
24
|
-
},
|
|
25
|
-
props
|
|
26
|
-
),
|
|
27
|
-
/*#__PURE__*/ React.createElement("path", {
|
|
28
|
-
fillRule: "evenodd",
|
|
29
|
-
clipRule: "evenodd",
|
|
30
|
-
d:
|
|
31
|
-
"M7.62107 8.00023L10.4697 10.8522C10.5957 10.9785 10.6665 11.1495 10.6665 11.3279C10.6665 11.5063 10.5957 11.6773 10.4697 11.8036C10.4074 11.866 10.3335 11.9155 10.252 11.9493C10.1706 11.983 10.0833 12.0004 9.99507 12.0004C9.9069 12.0004 9.81959 11.983 9.73814 11.9493C9.65669 11.9155 9.5827 11.866 9.52041 11.8036L6.19641 8.47556C6.07061 8.34935 5.99998 8.17842 5.99998 8.00023C5.99998 7.82203 6.07061 7.6511 6.19641 7.52489L9.52041 4.19689C9.5827 4.13449 9.65669 4.08498 9.73814 4.0512C9.81959 4.01741 9.9069 4.00003 9.99507 4.00003C10.0832 4.00003 10.1706 4.01741 10.252 4.0512C10.3335 4.08498 10.4074 4.13449 10.4697 4.19689C10.5957 4.32313 10.6665 4.4942 10.6665 4.67256C10.6665 4.85092 10.5957 5.02199 10.4697 5.14823L7.62107 8.00023Z",
|
|
32
|
-
fill: "currentColor"
|
|
33
|
-
})
|
|
34
|
-
);
|
|
35
|
-
var BtIconChevronLeftMid_2 = BtIconChevronLeftMid;
|
|
14
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
36
15
|
|
|
37
16
|
/**
|
|
38
17
|
* Use `Button` to allow users to take actions with clicks and taps.
|
|
39
18
|
*/
|
|
40
|
-
var Button = React
|
|
19
|
+
var Button = React.forwardRef(function (_a, ref) {
|
|
41
20
|
var _b;
|
|
42
|
-
var ariaLabel = _a.ariaLabel, _c = _a.fill, fill = _c === void 0 ? "solid" : _c, href = _a.href, icon = _a.icon, _d = _a.iconPosition, iconPosition = _d === void 0 ? "afterText" : _d, id = _a.id, _e = _a.isDisabled, isDisabled = _e === void 0 ? false : _e, _f = _a.isDisplayBlock, isDisplayBlock = _f === void 0 ? false : _f, _g = _a.isFullWidth, isFullWidth = _g === void 0 ? false : _g, label = _a.label, onClick = _a.onClick, rel = _a.rel, supportingText = _a.supportingText, target = _a.target, type = _a.type, props =
|
|
43
|
-
var surface = React
|
|
44
|
-
var buttonClasses = index
|
|
21
|
+
var ariaLabel = _a.ariaLabel, _c = _a.fill, fill = _c === void 0 ? "solid" : _c, href = _a.href, icon = _a.icon, _d = _a.iconPosition, iconPosition = _d === void 0 ? "afterText" : _d, id = _a.id, _e = _a.isDisabled, isDisabled = _e === void 0 ? false : _e, _f = _a.isDisplayBlock, isDisplayBlock = _f === void 0 ? false : _f, _g = _a.isFullWidth, isFullWidth = _g === void 0 ? false : _g, label = _a.label, onClick = _a.onClick, rel = _a.rel, supportingText = _a.supportingText, target = _a.target, type = _a.type, props = filterDataAttrs.__rest(_a, ["ariaLabel", "fill", "href", "icon", "iconPosition", "id", "isDisabled", "isDisplayBlock", "isFullWidth", "label", "onClick", "rel", "supportingText", "target", "type"]);
|
|
22
|
+
var surface = React.useContext(Surface.Context).surface;
|
|
23
|
+
var buttonClasses = index.classNames((_b = {
|
|
45
24
|
"arc-Button": true,
|
|
46
25
|
"arc-Button--displayBlock": isDisplayBlock
|
|
47
26
|
},
|
|
@@ -53,25 +32,25 @@ var Button = React$1.forwardRef(function (_a, ref) {
|
|
|
53
32
|
_b["arc-Button--hasSupportingText"] = supportingText,
|
|
54
33
|
_b["arc-Button--onDarkSurface"] = surface === "dark",
|
|
55
34
|
_b));
|
|
56
|
-
var commonProps =
|
|
35
|
+
var commonProps = filterDataAttrs.__assign({ id: id, onClick: onClick, ref: ref }, filterDataAttrs.filterDataAttrs(props));
|
|
57
36
|
var buttonText = supportingText ? (React__default["default"].createElement("span", null,
|
|
58
37
|
React__default["default"].createElement("span", { className: "arc-Button-text" }, label),
|
|
59
38
|
React__default["default"].createElement("span", { className: "arc-Button-supportingText" }, supportingText))) : (React__default["default"].createElement("span", { className: "arc-Button-text" }, label));
|
|
60
39
|
var buttonIcon = icon || fill === "flat" ? (React__default["default"].createElement(ButtonIcon, { icon: icon, isChevron: !icon && fill === "flat", isBeforeText: iconPosition === "beforeText" })) : null;
|
|
61
40
|
if (href && !isDisabled) {
|
|
62
|
-
return (React__default["default"].createElement("a",
|
|
41
|
+
return (React__default["default"].createElement("a", filterDataAttrs.__assign({}, commonProps, { "aria-label": ariaLabel, className: buttonClasses, href: href, rel: rel, target: target }),
|
|
63
42
|
React__default["default"].createElement("span", { className: "arc-Button-inner" },
|
|
64
43
|
buttonText,
|
|
65
44
|
buttonIcon)));
|
|
66
45
|
}
|
|
67
|
-
return (React__default["default"].createElement("button",
|
|
46
|
+
return (React__default["default"].createElement("button", filterDataAttrs.__assign({}, commonProps, { "aria-label": ariaLabel, className: buttonClasses, disabled: isDisabled, type: type }),
|
|
68
47
|
React__default["default"].createElement("span", { className: "arc-Button-inner" },
|
|
69
48
|
buttonText,
|
|
70
49
|
buttonIcon)));
|
|
71
50
|
});
|
|
72
51
|
var ButtonIcon = function (_a) {
|
|
73
52
|
var icon = _a.icon, isChevron = _a.isChevron, isBeforeText = _a.isBeforeText;
|
|
74
|
-
return (React__default["default"].createElement("span", { className: "arc-Button-icon" }, isChevron ? (React__default["default"].createElement(Icon.Icon, { icon: isBeforeText ? BtIconChevronLeftMid_2 : BtIconChevronRightMid.BtIconChevronRightMid_2 })) : (React__default["default"].createElement(Icon.Icon, { icon: icon }))));
|
|
53
|
+
return (React__default["default"].createElement("span", { className: "arc-Button-icon" }, isChevron ? (React__default["default"].createElement(Icon.Icon, { icon: isBeforeText ? BtIconChevronLeftMid.BtIconChevronLeftMid_2 : BtIconChevronRightMid.BtIconChevronRightMid_2 })) : (React__default["default"].createElement(Icon.Icon, { icon: icon }))));
|
|
75
54
|
};
|
|
76
55
|
|
|
77
56
|
exports.Button = Button;
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { FC, HTMLAttributes } from "react";
|
|
4
|
+
/**
|
|
5
|
+
* Detect interaction mode
|
|
6
|
+
*/
|
|
7
|
+
declare const useInteractionMode: () => {
|
|
8
|
+
interactionMode: string;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Use `Card` to contain content and actions about a single subject.
|
|
12
|
+
*/
|
|
13
|
+
declare const Card: FC<CardProps> & {
|
|
14
|
+
Block: typeof CardBlock;
|
|
15
|
+
Image: typeof CardImage;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Internal `Card.Block` component to section blocks of content within a Card.
|
|
19
|
+
*/
|
|
20
|
+
declare const CardBlock: FC<{
|
|
21
|
+
/**
|
|
22
|
+
* Contents of the CardBlock.
|
|
23
|
+
*/
|
|
24
|
+
children: React.ReactNode;
|
|
25
|
+
/**
|
|
26
|
+
* How should the content of the block be aligned?
|
|
27
|
+
*/
|
|
28
|
+
align?: "left" | "center" | "right";
|
|
29
|
+
/**
|
|
30
|
+
* Should the block stretch to the width of the Card?
|
|
31
|
+
*/
|
|
32
|
+
isFullWidth?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* Should the block grow to the fill the available vertical space? Used when the Card appears in a column.
|
|
35
|
+
*/
|
|
36
|
+
grow?: boolean;
|
|
37
|
+
}>;
|
|
38
|
+
/**
|
|
39
|
+
* Internal `Card.Image` component to show an image within a Card.
|
|
40
|
+
*/
|
|
41
|
+
declare const CardImage: FC<{
|
|
42
|
+
/**
|
|
43
|
+
* Alternative text for the Card.Image, shown if the image cannot be displayed.
|
|
44
|
+
*/
|
|
45
|
+
alt?: string;
|
|
46
|
+
/**
|
|
47
|
+
* Height of the Card.Image.
|
|
48
|
+
*/
|
|
49
|
+
height?: number;
|
|
50
|
+
/**
|
|
51
|
+
* Loading behaviour of the Card.Image.
|
|
52
|
+
*/
|
|
53
|
+
loading?: "eager" | "lazy";
|
|
54
|
+
/**
|
|
55
|
+
* The HTML [sizes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#Example_4_Using_the_srcset_and_sizes_attributes) attribute. Required if srcSet is defined.
|
|
56
|
+
*/
|
|
57
|
+
sizes?: string;
|
|
58
|
+
/**
|
|
59
|
+
* HTML src for the Card.Image.
|
|
60
|
+
*/
|
|
61
|
+
src: string;
|
|
62
|
+
/**
|
|
63
|
+
* A comma-separated list indicating a set of possible image sources for the user agent to use for different screen sizes. Same format as [srcSet](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#Example_4_Using_the_srcset_and_sizes_attributes), i.e. `my-image-200.png 200w, my-image-200.png 200w`.
|
|
64
|
+
*/
|
|
65
|
+
srcSet?: string;
|
|
66
|
+
}>;
|
|
67
|
+
type TitleSize = "xs" | "s" | "m" | "l" | "xl";
|
|
68
|
+
interface CardProps extends HTMLAttributes<HTMLElement> {
|
|
69
|
+
/**
|
|
70
|
+
* The HTML ID passed to the Card Button for aria- attributes.
|
|
71
|
+
*/
|
|
72
|
+
actionId?: string;
|
|
73
|
+
/**
|
|
74
|
+
* Label for the Card's Button. You should specify this if defining an href.
|
|
75
|
+
*/
|
|
76
|
+
actionLabel?: string;
|
|
77
|
+
/**
|
|
78
|
+
* A `Card.Image` to use for the cover image.
|
|
79
|
+
*/
|
|
80
|
+
coverImage?: React.ReactNode;
|
|
81
|
+
/**
|
|
82
|
+
* Card fill.
|
|
83
|
+
*/
|
|
84
|
+
fill?: "solid" | "outlined" | "neutral";
|
|
85
|
+
/**
|
|
86
|
+
* A URL to link to when the Card is clicked or touched.
|
|
87
|
+
*/
|
|
88
|
+
href: string;
|
|
89
|
+
/**
|
|
90
|
+
* Alternative text for the Card cover image, shown if the image cannot be displayed.
|
|
91
|
+
*/
|
|
92
|
+
imageAlt?: string;
|
|
93
|
+
/**
|
|
94
|
+
* Height of the Card cover image.
|
|
95
|
+
*/
|
|
96
|
+
imageHeight?: number;
|
|
97
|
+
/**
|
|
98
|
+
* Loading behaviour of the Card cover image.
|
|
99
|
+
*/
|
|
100
|
+
imageLoading?: "eager" | "lazy";
|
|
101
|
+
/**
|
|
102
|
+
* HTML src for the Card cover image.
|
|
103
|
+
*/
|
|
104
|
+
imageSrc?: string;
|
|
105
|
+
/**
|
|
106
|
+
* A comma-separated list indicating a set of possible image sources for the user agent to use for different screen sizes in the Card cover image. Same format as [srcSet](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#Example_4_Using_the_srcset_and_sizes_attributes), i.e. `my-image-200.png 200w, my-image-200.png 200w`.
|
|
107
|
+
*/
|
|
108
|
+
imageSrcSet?: string;
|
|
109
|
+
/**
|
|
110
|
+
* Object of `data-` attributes to render on internal anchor element, e.g.
|
|
111
|
+
* `{ data-analytics-link: "My link"}` => `<a data-analytics-link="My link">`.
|
|
112
|
+
*/
|
|
113
|
+
linkData?: {};
|
|
114
|
+
/**
|
|
115
|
+
* The minimum height of the card. Cards in a series of columns will match the
|
|
116
|
+
* height of the tallest Card.
|
|
117
|
+
*/
|
|
118
|
+
minHeight?: number;
|
|
119
|
+
/**
|
|
120
|
+
* Link target attribute for the Card link.
|
|
121
|
+
*/
|
|
122
|
+
target?: "_blank" | "_parent" | "_self" | "_top";
|
|
123
|
+
/**
|
|
124
|
+
* The title for the Card, describing the content. This is required to provide good accessibility to screen readers.
|
|
125
|
+
*/
|
|
126
|
+
title: string;
|
|
127
|
+
/**
|
|
128
|
+
* The size for the Card title.
|
|
129
|
+
*/
|
|
130
|
+
titleSize?: TitleSize;
|
|
131
|
+
/**
|
|
132
|
+
* On click handler.
|
|
133
|
+
*/
|
|
134
|
+
onClick?: () => void;
|
|
135
|
+
}
|
|
136
|
+
export { useInteractionMode, Card, TitleSize, CardProps };
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var filterDataAttrs = require('./filter-data-attrs-a30dcf5f.js');
|
|
4
|
+
var index = require('./index-45bfb67b.js');
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var BtIconChevronRightMid = require('./BtIconChevronRightMid-5a38d855.js');
|
|
7
|
+
var Icon = require('./Icon-9ae8dbe1.js');
|
|
8
|
+
var Image = require('./Image-3bf4b4f3.js');
|
|
9
|
+
var Heading = require('./Heading-d45f6a7f.js');
|
|
10
|
+
var suffixModifier = require('./suffix-modifier-1ee2da04.js');
|
|
11
|
+
var Surface = require('./Surface-6da0a78e.js');
|
|
12
|
+
var handleLinkClick = require('./handle-link-click-17a44cf4.js');
|
|
13
|
+
|
|
14
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
15
|
+
|
|
16
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Detect interaction mode
|
|
20
|
+
*/
|
|
21
|
+
var useInteractionMode = function () {
|
|
22
|
+
var _a = React.useState("pointer"), interactionMode = _a[0], setInteractionMode = _a[1];
|
|
23
|
+
React.useEffect(function () {
|
|
24
|
+
var onKeyDown = function (event) {
|
|
25
|
+
if (event.altKey || event.ctrlKey || event.metaKey) {
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
setInteractionMode("keyboard");
|
|
29
|
+
};
|
|
30
|
+
var onPointerDown = function () {
|
|
31
|
+
setInteractionMode("pointer");
|
|
32
|
+
};
|
|
33
|
+
if (typeof window !== "undefined") {
|
|
34
|
+
document.addEventListener("keydown", onKeyDown, true);
|
|
35
|
+
document.addEventListener("click", onPointerDown, true);
|
|
36
|
+
}
|
|
37
|
+
return function () {
|
|
38
|
+
if (typeof window !== "undefined") {
|
|
39
|
+
document.removeEventListener("keydown", onKeyDown);
|
|
40
|
+
document.removeEventListener("click", onPointerDown);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
}, []);
|
|
44
|
+
return { interactionMode: interactionMode };
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Use `Card` to contain content and actions about a single subject.
|
|
49
|
+
*/
|
|
50
|
+
var Card = function (_a) {
|
|
51
|
+
var _b;
|
|
52
|
+
var actionId = _a.actionId, _c = _a.actionLabel, actionLabel = _c === void 0 ? "Read more" : _c, children = _a.children, _d = _a.fill, fill = _d === void 0 ? "solid" : _d, href = _a.href, imageAlt = _a.imageAlt, imageHeight = _a.imageHeight, imageLoading = _a.imageLoading, imageSrc = _a.imageSrc, imageSrcSet = _a.imageSrcSet, linkData = _a.linkData, minHeight = _a.minHeight, onClick = _a.onClick, target = _a.target, title = _a.title, _e = _a.titleSize, titleSize = _e === void 0 ? "s" : _e, props = filterDataAttrs.__rest(_a, ["actionId", "actionLabel", "children", "fill", "href", "imageAlt", "imageHeight", "imageLoading", "imageSrc", "imageSrcSet", "linkData", "minHeight", "onClick", "target", "title", "titleSize"]);
|
|
53
|
+
var surface = React.useContext(Surface.Context).surface;
|
|
54
|
+
var interactionMode = useInteractionMode().interactionMode;
|
|
55
|
+
var Wrapper = function (_a) {
|
|
56
|
+
var children = _a.children;
|
|
57
|
+
return fill === "outlined" || fill === "neutral" ? (React__default["default"].createElement("div", null, children)) : (React__default["default"].createElement(Surface.Surface, { background: surface === "dark" ? "white" : "darker" }, children));
|
|
58
|
+
};
|
|
59
|
+
var coverImage = imageSrc && (React__default["default"].createElement(CardImage, { alt: imageAlt, height: imageHeight, loading: imageLoading, src: imageSrc, srcSet: imageSrcSet }));
|
|
60
|
+
return (React__default["default"].createElement("div", filterDataAttrs.__assign({ className: index.classNames((_b = {
|
|
61
|
+
"arc-Card": true,
|
|
62
|
+
"arc-Card--onDarkSurface": surface === "dark"
|
|
63
|
+
},
|
|
64
|
+
_b[suffixModifier.suffixModifier("arc-Card--fill", fill)] = fill !== "solid",
|
|
65
|
+
_b["arc-is-".concat(interactionMode, "InteractionMode")] = interactionMode,
|
|
66
|
+
_b)) }, filterDataAttrs.filterDataAttrs(props)),
|
|
67
|
+
React__default["default"].createElement(Wrapper, null,
|
|
68
|
+
React__default["default"].createElement("div", { className: "arc-Card-inner", style: { minHeight: minHeight } },
|
|
69
|
+
React__default["default"].createElement("div", { className: "arc-Card-header" },
|
|
70
|
+
React__default["default"].createElement("div", { className: "arc-Card-title" },
|
|
71
|
+
React__default["default"].createElement(Heading.Heading, { size: titleSize },
|
|
72
|
+
React__default["default"].createElement(CardLink, { stretch: true, onClick: onClick, actionId: actionId, fill: fill, href: href, linkData: linkData, target: target }, title))),
|
|
73
|
+
coverImage),
|
|
74
|
+
React__default["default"].createElement("div", { className: "arc-Card-children" },
|
|
75
|
+
React__default["default"].createElement(Card.Block, null, children)),
|
|
76
|
+
href && (React__default["default"].createElement(CardBlock, null,
|
|
77
|
+
React__default["default"].createElement(CardLink, { href: href, fill: fill, actionId: actionId, onClick: onClick, isButton: true }, actionLabel)))))));
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Internal `Card.Block` component to section blocks of content within a Card.
|
|
81
|
+
*/
|
|
82
|
+
var CardBlock = function (_a) {
|
|
83
|
+
var _b = _a.align, align = _b === void 0 ? "left" : _b, children = _a.children, _c = _a.isFullWidth, isFullWidth = _c === void 0 ? false : _c, _d = _a.grow, grow = _d === void 0 ? false : _d;
|
|
84
|
+
return (React__default["default"].createElement("div", { className: index.classNames({
|
|
85
|
+
"arc-Card-block": true,
|
|
86
|
+
"arc-Card-block--alignCenter": align === "center",
|
|
87
|
+
"arc-Card-block--alignRight": align === "right",
|
|
88
|
+
"arc-Card-block--fullWidth": isFullWidth,
|
|
89
|
+
"arc-Card-block--grow": grow
|
|
90
|
+
}) },
|
|
91
|
+
React__default["default"].createElement("div", { className: "arc-Card-blockInner" }, children)));
|
|
92
|
+
};
|
|
93
|
+
CardBlock.displayName = "Card.Block";
|
|
94
|
+
Card.Block = CardBlock;
|
|
95
|
+
/**
|
|
96
|
+
* Internal `Card.Image` component to show an image within a Card.
|
|
97
|
+
*/
|
|
98
|
+
var CardImage = function (_a) {
|
|
99
|
+
var _b = _a.alt, alt = _b === void 0 ? "" : _b, _c = _a.height, height = _c === void 0 ? 176 : _c, loading = _a.loading, sizes = _a.sizes, src = _a.src, srcSet = _a.srcSet;
|
|
100
|
+
return (React__default["default"].createElement("div", { className: index.classNames({
|
|
101
|
+
"arc-Card-image": true
|
|
102
|
+
}) },
|
|
103
|
+
React__default["default"].createElement(Image.Image, { alt: alt, fit: "cover", height: height, loading: loading, sizes: sizes, src: src, srcSet: srcSet })));
|
|
104
|
+
};
|
|
105
|
+
CardImage.displayName = "Card.Image";
|
|
106
|
+
Card.Image = CardImage;
|
|
107
|
+
/**
|
|
108
|
+
* Internal `CardLink` component.
|
|
109
|
+
*/
|
|
110
|
+
var CardLink = function (_a) {
|
|
111
|
+
var actionId = _a.actionId, isButton = _a.isButton, children = _a.children, fill = _a.fill, href = _a.href, _b = _a.linkData, linkData = _b === void 0 ? {} : _b, onClick = _a.onClick, stretch = _a.stretch, target = _a.target;
|
|
112
|
+
var surface = React.useContext(Surface.Context).surface;
|
|
113
|
+
return (React__default["default"].createElement("a", filterDataAttrs.__assign({ onClick: handleLinkClick.handleLinkClick({ handler: onClick }), "aria-describedby": actionId, className: index.classNames({
|
|
114
|
+
"arc-Card-link": true,
|
|
115
|
+
"arc-Card-link--button": isButton,
|
|
116
|
+
"arc-Card-link--onDarkSurface": surface === "dark" && fill !== "neutral",
|
|
117
|
+
"arc-Card-link--stretch": stretch
|
|
118
|
+
}), href: href, rel: target === "_blank" ? "noopener noreferrer" : undefined, tabIndex: isButton ? -1 : undefined, target: target }, filterDataAttrs.filterDataAttrs(linkData)),
|
|
119
|
+
React__default["default"].createElement("span", { className: "arc-Card-linkText" }, children),
|
|
120
|
+
isButton && (React__default["default"].createElement("span", { className: "arc-Card-linkIcon" },
|
|
121
|
+
React__default["default"].createElement(Icon.Icon, { testId: "cardIcon", icon: BtIconChevronRightMid.BtIconChevronRightMid_2, size: 24 })))));
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
exports.Card = Card;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import React from "react";
|
|
3
|
+
type EventType = React.ChangeEvent<HTMLInputElement>;
|
|
4
|
+
/**
|
|
5
|
+
* Use `Checkbox` to allow users to select individual options.
|
|
6
|
+
*/
|
|
7
|
+
declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<HTMLInputElement>>;
|
|
8
|
+
interface CheckboxProps {
|
|
9
|
+
/**
|
|
10
|
+
* Error message for the Checkbox.
|
|
11
|
+
*/
|
|
12
|
+
errorMessage?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Helper text for the Checkbox, shown below the label.
|
|
15
|
+
*/
|
|
16
|
+
helper?: React.ReactNode;
|
|
17
|
+
/**
|
|
18
|
+
* Determine the alignment the Checkbox.
|
|
19
|
+
*
|
|
20
|
+
*/
|
|
21
|
+
checkboxAlignment?: "top" | "center";
|
|
22
|
+
/**
|
|
23
|
+
* ID for the Checkbox.
|
|
24
|
+
*/
|
|
25
|
+
id: string;
|
|
26
|
+
/**
|
|
27
|
+
* Is the input checked?
|
|
28
|
+
*/
|
|
29
|
+
checked?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* `isDisabled` is a legacy property and not recommended from a UX usability best practice perspective.
|
|
32
|
+
*/
|
|
33
|
+
isDisabled?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Is the Checkbox required?
|
|
36
|
+
*/
|
|
37
|
+
isRequired?: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* Label for the Checkbox.
|
|
40
|
+
*/
|
|
41
|
+
label: React.ReactNode;
|
|
42
|
+
/**
|
|
43
|
+
* Name for the Checkbox.
|
|
44
|
+
*/
|
|
45
|
+
name?: string;
|
|
46
|
+
/**
|
|
47
|
+
* Function to call when the Checkbox loses focus.
|
|
48
|
+
*/
|
|
49
|
+
onBlur?: (e: EventType) => void;
|
|
50
|
+
/**
|
|
51
|
+
* Callback function to update the Checkbox's controlled `checked` prop, for
|
|
52
|
+
* example `e => setChecked(e.target.checked)`.
|
|
53
|
+
*/
|
|
54
|
+
onChange?: (event: EventType) => void;
|
|
55
|
+
/**
|
|
56
|
+
* Size of the Checkbox.
|
|
57
|
+
*/
|
|
58
|
+
size?: "s" | "l";
|
|
59
|
+
/**
|
|
60
|
+
* Value for the Checkbox.
|
|
61
|
+
*/
|
|
62
|
+
value?: string;
|
|
63
|
+
}
|
|
64
|
+
export { Checkbox, CheckboxProps };
|