@pnx-mixtape/mxds 0.0.21 → 0.0.23
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/build/accordion.entry.js +32 -43
- package/dist/build/accordion.entry.js.map +1 -1
- package/dist/build/base.css +19 -39
- package/dist/build/button.css +7 -8
- package/dist/build/chunks/{Accordion-O-huO4At.js → Accordion-D1HQ0FDq.js} +23 -21
- package/dist/build/chunks/{Accordion-O-huO4At.js.map → Accordion-D1HQ0FDq.js.map} +1 -1
- package/dist/build/chunks/disclosure-widget-CdjCdx7t.js +129 -0
- package/dist/build/chunks/disclosure-widget-CdjCdx7t.js.map +1 -0
- package/dist/build/chunks/drop-menu.entry-fzV-_VFl.js +70 -0
- package/dist/build/chunks/drop-menu.entry-fzV-_VFl.js.map +1 -0
- package/dist/build/chunks/{polyfills-C-B7iqDG.js → polyfills-DnrsypYs.js} +35 -26
- package/dist/build/chunks/polyfills-DnrsypYs.js.map +1 -0
- package/dist/build/chunks/popover.entry-BQvyR0d5.js +38 -0
- package/dist/build/chunks/popover.entry-BQvyR0d5.js.map +1 -0
- package/dist/build/chunks/{utilities-DXELy_An.js → utilities-Ci7wwNeg.js} +9 -106
- package/dist/build/chunks/utilities-Ci7wwNeg.js.map +1 -0
- package/dist/build/constants.css +10 -31
- package/dist/build/dialog.entry.js +23 -31
- package/dist/build/dialog.entry.js.map +1 -1
- package/dist/build/drop-menu.entry.js +1 -1
- package/dist/build/drupal.css +5 -9
- package/dist/build/filters.entry.js +54 -50
- package/dist/build/filters.entry.js.map +1 -1
- package/dist/build/form.css +12 -26
- package/dist/build/global-alert.entry.js +26 -19
- package/dist/build/global-alert.entry.js.map +1 -1
- package/dist/build/grid.css +3 -9
- package/dist/build/header.css +5 -3
- package/dist/build/header.entry.js +93 -88
- package/dist/build/header.entry.js.map +1 -1
- package/dist/build/icon.css +3 -3
- package/dist/build/in-page-navigation.entry.js +16 -12
- package/dist/build/in-page-navigation.entry.js.map +1 -1
- package/dist/build/navigation.css +21 -56
- package/dist/build/navigation.entry.js +148 -50
- package/dist/build/navigation.entry.js.map +1 -1
- package/dist/build/page.css +1 -1
- package/dist/build/popover.css +119 -0
- package/dist/build/popover.entry.js +2 -0
- package/dist/build/popover.entry.js.map +1 -0
- package/dist/build/section.css +1 -1
- package/dist/build/sticky.entry.js +11 -12
- package/dist/build/sticky.entry.js.map +1 -1
- package/dist/build/tabs.entry.js +108 -91
- package/dist/build/tabs.entry.js.map +1 -1
- package/dist/build/utility-list.css +43 -0
- package/dist/build/utility-list.entry.js +80 -0
- package/dist/build/utility-list.entry.js.map +1 -0
- package/package.json +9 -10
- package/src/Atom/{Base.mdx → Atom.mdx} +1 -1
- package/src/Atom/Background/Backgrounds.stories.ts +21 -4
- package/src/Atom/Background/__snapshots__/Backgrounds.stories.ts.snap +1 -1
- package/src/Atom/Background/_background.css +1 -2
- package/src/Atom/Blockquote/_blockquote.css +1 -2
- package/src/Atom/Button/Button.stories.ts +128 -19
- package/src/Atom/Button/__snapshots__/Button.stories.ts.snap +75 -11
- package/src/Atom/Button/__snapshots__/Button.stories.tsx.snap +1 -1
- package/src/Atom/Button/_buttons.css +5 -5
- package/src/Atom/DefinitionList/DefinitionList.stories.ts +20 -3
- package/src/Atom/DefinitionList/DefinitionList.stories.tsx +3 -9
- package/src/Atom/DefinitionList/DefinitionList.tsx +3 -4
- package/src/Atom/DefinitionList/__snapshots__/DefinitionList.stories.ts.snap +1 -1
- package/src/Atom/DefinitionList/__snapshots__/DefinitionList.stories.tsx.snap +1 -1
- package/src/Atom/Heading/Heading.stories.ts +49 -7
- package/src/Atom/Heading/Heading.tsx +1 -6
- package/src/Atom/Heading/__snapshots__/Heading.stories.ts.snap +9 -1
- package/src/Atom/Heading/__snapshots__/Heading.stories.tsx.snap +1 -1
- package/src/Atom/Heading/_headings.css +1 -2
- package/src/Atom/Icon/Icon.mdx +5 -1
- package/src/Atom/Icon/Icon.stories.ts +76 -6
- package/src/Atom/Icon/Icon.tsx +1 -8
- package/src/Atom/Icon/__snapshots__/Icon.stories.ts.snap +18 -4
- package/src/Atom/Icon/__snapshots__/Icon.stories.tsx.snap +1 -1
- package/src/Atom/Icon/_icon.css +1 -1
- package/src/Atom/Image/Image.stories.ts +4 -3
- package/src/Atom/Image/__snapshots__/Image.stories.ts.snap +1 -1
- package/src/Atom/Link/Link.stories.ts +74 -7
- package/src/Atom/Link/__snapshots__/Link.stories.ts.snap +4 -4
- package/src/Atom/Link/__snapshots__/Link.stories.tsx.snap +1 -1
- package/src/Atom/Media/Media.stories.ts +34 -5
- package/src/Atom/Media/Media.tsx +1 -6
- package/src/Atom/Media/__snapshots__/Media.stories.ts.snap +2 -2
- package/src/Atom/Media/__snapshots__/Media.stories.tsx.snap +1 -1
- package/src/Atom/Media/_media.css +2 -10
- package/src/Atom/Spacing/Spacing.stories.ts +45 -31
- package/src/Atom/Spacing/__snapshots__/Spacing.stories.ts.snap +5 -4
- package/src/Atom/Spacing/spacing.twig +5 -2
- package/src/Atom/Table/__snapshots__/Table.stories.ts.snap +1 -1
- package/src/Atom/Table/__snapshots__/TableResponsive.stories.ts.snap +1 -1
- package/src/Atom/Table/_table.css +1 -2
- package/src/Atom/Text/Text.stories.ts +62 -0
- package/src/Atom/Text/__snapshots__/{TextSizes.stories.ts.snap → Text.stories.ts.snap} +14 -27
- package/src/Atom/Text/__snapshots__/Text.stories.tsx.snap +1 -1
- package/src/Atom/Text/_text-sizes.css +2 -4
- package/src/Atom/Text/text-style.twig +11 -1
- package/src/Atom/Text/text-styles-example.twig +2 -16
- package/src/Atom/Video/Video.stories.ts +6 -4
- package/src/Atom/Video/Video.tsx +1 -5
- package/src/Atom/Video/__snapshots__/Video.stories.ts.snap +1 -1
- package/src/Atom/_generic.css +4 -4
- package/src/Atom/_hr.css +1 -2
- package/src/Component/Accordion/Accordion.stories.ts +26 -8
- package/src/Component/Accordion/Accordion.stories.tsx +8 -10
- package/src/Component/Accordion/Accordion.tsx +2 -13
- package/src/Component/Accordion/AccordionItem.stories.ts +90 -0
- package/src/Component/Accordion/Components/AccordionContent.tsx +1 -5
- package/src/Component/Accordion/Components/AccordionTitle.tsx +1 -4
- package/src/Component/Accordion/Elements/Accordion.ts +1 -1
- package/src/Component/Accordion/Elements/AccordionDiv.ts +4 -11
- package/src/Component/Accordion/Elements/AccordionGroup.ts +10 -24
- package/src/Component/Accordion/Elements/AccordionMobile.ts +4 -4
- package/src/Component/Accordion/__snapshots__/Accordion.stories.ts.snap +17 -6
- package/src/Component/Accordion/__snapshots__/Accordion.stories.tsx.snap +1 -1
- package/src/Component/Accordion/__snapshots__/AccordionItem.stories.ts.snap +90 -0
- package/src/Component/Accordion/accordion.css +7 -5
- package/src/Component/Accordion/twig/accordion-div.twig +13 -11
- package/src/Component/Accordion/twig/accordion-mobile.twig +13 -11
- package/src/Component/Breadcrumb/Breadcrumb.stories.ts +14 -0
- package/src/Component/Breadcrumb/Breadcrumb.tsx +2 -12
- package/src/Component/Breadcrumb/__snapshots__/Breadcrumb.stories.ts.snap +1 -1
- package/src/Component/Breadcrumb/__snapshots__/Breadcrumb.stories.tsx.snap +1 -1
- package/src/Component/Breadcrumb/breadcrumb.css +1 -4
- package/src/Component/Callout/Callout.stories.ts +20 -0
- package/src/Component/Callout/__snapshots__/Callout.stories.ts.snap +1 -1
- package/src/Component/Callout/callout.css +1 -2
- package/src/Component/Card/Card.stories.ts +129 -14
- package/src/Component/Card/Card.stories.tsx +2 -2
- package/src/Component/Card/Components/CardContent.tsx +1 -5
- package/src/Component/Card/__snapshots__/Card.stories.ts.snap +24 -24
- package/src/Component/Card/__snapshots__/Card.stories.tsx.snap +1 -1
- package/src/Component/Card/card.css +2 -6
- package/src/Component/Card/card.twig +1 -1
- package/src/Component/Carousel/Carousel.stories.ts +61 -8
- package/src/Component/Carousel/Elements/Carousel.ts +10 -19
- package/src/Component/Carousel/__snapshots__/Carousel.stories.ts.snap +321 -35
- package/src/Component/Carousel/carousel.css +1 -2
- package/src/Component/ContentBlock/Components/ContentBlockContent.tsx +1 -5
- package/src/Component/ContentBlock/Components/ContentBlockMedia.tsx +1 -4
- package/src/Component/ContentBlock/ContentBlock.stories.ts +63 -13
- package/src/Component/ContentBlock/ContentBlock.stories.tsx +2 -2
- package/src/Component/ContentBlock/ContentBlock.tsx +1 -5
- package/src/Component/ContentBlock/__snapshots__/ContentBlock.stories.ts.snap +11 -11
- package/src/Component/ContentBlock/__snapshots__/ContentBlock.stories.tsx.snap +1 -1
- package/src/Component/Dialog/Dialog.stories.ts +78 -21
- package/src/Component/Dialog/Dialog.stories.tsx +2 -3
- package/src/Component/Dialog/Elements/Dialog.ts +7 -16
- package/src/Component/Dialog/__snapshots__/Dialog.stories.ts.snap +8 -11
- package/src/Component/Dialog/__snapshots__/Dialog.stories.tsx.snap +1 -1
- package/src/Component/Dialog/dialog.css +1 -2
- package/src/Component/Dialog/dialog.twig +1 -1
- package/src/Component/DropMenu/Components/DropMenuContext.tsx +4 -12
- package/src/Component/DropMenu/DropMenu.stories.ts +60 -1
- package/src/Component/DropMenu/DropMenu.tsx +2 -7
- package/src/Component/DropMenu/Elements/DropMenu.ts +21 -91
- package/src/Component/DropMenu/__snapshots__/DropMenu.stories.ts.snap +53 -11
- package/src/Component/DropMenu/__snapshots__/DropMenu.stories.tsx.snap +1 -1
- package/src/Component/DropMenu/drop-menu.css +13 -41
- package/src/Component/DropMenu/drop-menu.twig +8 -6
- package/src/Component/Filters/Elements/Filters.ts +7 -11
- package/src/Component/Filters/FilterItem.stories.ts +180 -0
- package/src/Component/Filters/Filters.stories.ts +83 -8
- package/src/Component/Filters/__snapshots__/FilterItem.stories.ts.snap +135 -0
- package/src/Component/Filters/__snapshots__/Filters.stories.ts.snap +43 -41
- package/src/Component/Filters/filter-item.twig +1 -1
- package/src/Component/Filters/filters.css +33 -17
- package/src/Component/GlobalAlert/Elements/ClosableAlert.ts +8 -7
- package/src/Component/GlobalAlert/GlobalAlert.stories.ts +60 -12
- package/src/Component/GlobalAlert/GlobalAlert.stories.tsx +1 -2
- package/src/Component/GlobalAlert/__snapshots__/GlobalAlert.stories.ts.snap +8 -6
- package/src/Component/GlobalAlert/__snapshots__/GlobalAlert.stories.tsx.snap +3 -3
- package/src/Component/HeroBanner/HeroBanner.stories.ts +84 -7
- package/src/Component/HeroBanner/HeroBanner.stories.tsx +4 -4
- package/src/Component/HeroBanner/__snapshots__/HeroBanner.stories.ts.snap +91 -99
- package/src/Component/HeroBanner/__snapshots__/HeroBanner.stories.tsx.snap +1 -1
- package/src/Component/HeroSearch/HeroSearch.stories.ts +23 -4
- package/src/Component/HeroSearch/HeroSearch.stories.tsx +4 -4
- package/src/Component/HeroSearch/__snapshots__/HeroSearch.stories.ts.snap +10 -10
- package/src/Component/HeroSearch/__snapshots__/HeroSearch.stories.tsx.snap +1 -1
- package/src/Component/InPageAlert/InPageAlert.stories.ts +76 -8
- package/src/Component/InPageAlert/InPageAlert.stories.tsx +1 -2
- package/src/Component/InPageAlert/InPageAlert.tsx +1 -4
- package/src/Component/InPageAlert/__snapshots__/InPageAlert.stories.ts.snap +80 -2
- package/src/Component/InPageAlert/__snapshots__/InPageAlert.stories.tsx.snap +1 -1
- package/src/Component/InPageNavigation/Elements/InPageNavigation.ts +7 -9
- package/src/Component/InPageNavigation/Hooks/useInPageNavigation.ts +3 -5
- package/src/Component/InPageNavigation/InPageNavigation.stories.ts +44 -9
- package/src/Component/InPageNavigation/InPageNavigation.stories.tsx +32 -40
- package/src/Component/InPageNavigation/__snapshots__/InPageNavigation.stories.ts.snap +152 -5
- package/src/Component/InPageNavigation/__snapshots__/InPageNavigation.stories.tsx.snap +1 -1
- package/src/Component/LinkList/LinkList.stories.ts +23 -0
- package/src/Component/LinkList/__snapshots__/LinkList.stories.ts.snap +8 -8
- package/src/Component/LinkList/__snapshots__/LinkList.stories.tsx.snap +1 -1
- package/src/Component/LinkList/link-list.css +1 -2
- package/src/Component/ListItem/Components/ListItemContent.tsx +1 -5
- package/src/Component/ListItem/Components/ListItemMedia.tsx +1 -4
- package/src/Component/ListItem/ListItem.stories.ts +91 -11
- package/src/Component/ListItem/ListItem.stories.tsx +6 -7
- package/src/Component/ListItem/__snapshots__/ListItem.stories.ts.snap +1 -1
- package/src/Component/ListItem/__snapshots__/ListItem.stories.tsx.snap +1 -1
- package/src/Component/ListItem/list-item.css +1 -2
- package/src/Component/Navigation/Components/DropdownLevel.tsx +5 -13
- package/src/Component/Navigation/Elements/Navigation.ts +6 -13
- package/src/Component/Navigation/Navigation.stories.ts +48 -0
- package/src/Component/Navigation/__snapshots__/Dropdown.stories.tsx.snap +1 -1
- package/src/Component/Navigation/__snapshots__/Navigation.stories.ts.snap +1 -1
- package/src/Component/Navigation/__snapshots__/Navigation.stories.tsx.snap +1 -1
- package/src/Component/Navigation/_navigation-collapsible.css +2 -4
- package/src/Component/Navigation/_navigation-dropdown.css +10 -32
- package/src/Component/Navigation/_navigation-mega.css +1 -4
- package/src/Component/Navigation/_navigation.css +1 -4
- package/src/Component/Pagination/Components/PaginationContext.tsx +5 -19
- package/src/Component/Pagination/Components/PaginationItem.tsx +1 -5
- package/src/Component/Pagination/Pagination.stories.ts +28 -0
- package/src/Component/Pagination/Pagination.tsx +3 -11
- package/src/Component/Pagination/__snapshots__/Pagination.stories.ts.snap +3 -3
- package/src/Component/Pagination/__snapshots__/Pagination.stories.tsx.snap +1 -1
- package/src/Component/Pagination/pagination.css +1 -4
- package/src/Component/Popover/Elements/Popover.ts +55 -0
- package/src/Component/Popover/Popover.stories.ts +259 -0
- package/src/Component/Popover/__snapshots__/Popover.stories.ts.snap +508 -0
- package/src/Component/{DropMenu → Popover}/polyfills.js +6 -4
- package/src/Component/Popover/popover.css +113 -0
- package/src/Component/Popover/popover.entry.js +1 -0
- package/src/Component/Popover/popover.twig +27 -0
- package/src/Component/ResultsBar/Components/ResultsBarInfo.tsx +2 -7
- package/src/Component/ResultsBar/Components/ResultsBarSort.tsx +1 -6
- package/src/Component/ResultsBar/ResultsBar.stories.ts +34 -4
- package/src/Component/ResultsBar/__snapshots__/ResultsBar.stories.ts.snap +3 -3
- package/src/Component/ResultsBar/__snapshots__/ResultsBar.stories.tsx.snap +1 -1
- package/src/Component/SideNavigation/SideNavigation.stories.ts +40 -0
- package/src/Component/SideNavigation/__snapshots__/SideNavigation.stories.ts.snap +1 -1
- package/src/Component/SideNavigation/side-navigation.css +3 -6
- package/src/Component/SocialLinks/SocialLinks.stories.ts +20 -0
- package/src/Component/SocialLinks/__snapshots__/SocialLinks.stories.ts.snap +5 -5
- package/src/Component/SocialShare/SocialShare.stories.ts +37 -0
- package/src/Component/SocialShare/SocialShare.tsx +2 -4
- package/src/Component/SocialShare/__snapshots__/SocialShare.stories.ts.snap +40 -0
- package/src/Component/SocialShare/__snapshots__/SocialShare.stories.tsx.snap +1 -1
- package/src/Component/SocialShare/social-share.twig +34 -0
- package/src/Component/Steps/StepItem.stories.ts +48 -0
- package/src/Component/Steps/Steps.stories.ts +82 -13
- package/src/Component/Steps/__snapshots__/StepItem.stories.ts.snap +31 -0
- package/src/Component/Steps/__snapshots__/Steps.stories.ts.snap +109 -28
- package/src/Component/Steps/step-item.twig +1 -1
- package/src/Component/Steps/steps.css +4 -11
- package/src/Component/Sticky/Elements/Sticky.ts +3 -8
- package/src/Component/Sticky/Sticky.stories.ts +35 -3
- package/src/Component/Sticky/__snapshots__/Sticky.stories.ts.snap +1 -1
- package/src/Component/Sticky/__snapshots__/Sticky.stories.tsx.snap +1 -1
- package/src/Component/Sticky/sticky.twig +1 -1
- package/src/Component/Tabs/Components/Tab.tsx +2 -8
- package/src/Component/Tabs/Components/TabPanel.tsx +1 -5
- package/src/Component/Tabs/Elements/Tabs.ts +21 -31
- package/src/Component/Tabs/TabItem.stories.ts +52 -0
- package/src/Component/Tabs/Tabs.stories.ts +51 -8
- package/src/Component/Tabs/Tabs.tsx +6 -22
- package/src/Component/Tabs/__snapshots__/TabItem.stories.ts.snap +12 -0
- package/src/Component/Tabs/__snapshots__/Tabs.stories.ts.snap +127 -11
- package/src/Component/Tabs/__snapshots__/Tabs.stories.tsx.snap +1 -1
- package/src/Component/Tabs/tab-item.twig +1 -2
- package/src/Component/Tabs/tabs.css +56 -59
- package/src/Component/Tag/Tag.stories.ts +30 -0
- package/src/Component/Tag/Tag.tsx +1 -5
- package/src/Component/Tag/__snapshots__/Tag.stories.ts.snap +1 -1
- package/src/Component/Tag/__snapshots__/Tag.stories.tsx.snap +1 -1
- package/src/Component/Tag/tag.css +1 -4
- package/src/Component/UtilityList/Elements/UtilityList.ts +110 -0
- package/src/Component/UtilityList/UtilityList.stories.ts +72 -0
- package/src/Component/UtilityList/__snapshots__/UtilityList.stories.ts.snap +274 -0
- package/src/Component/UtilityList/utility-list.css +40 -0
- package/src/Component/UtilityList/utility-list.entry.js +1 -0
- package/src/Component/UtilityList/utility-list.twig +66 -0
- package/src/Form/Checkbox/FormCheckbox.stories.tsx +1 -3
- package/src/Form/Checkbox/FormCheckbox.tsx +4 -25
- package/src/Form/Checkbox/__snapshots__/Checkbox.stories.ts.snap +3 -3
- package/src/Form/Description/Description.stories.ts +1 -2
- package/src/Form/Description/FormStatus.stories.ts +1 -4
- package/src/Form/Description/__snapshots__/Description.stories.ts.snap +1 -1
- package/src/Form/Description/__snapshots__/FormDescription.stories.tsx.snap +1 -1
- package/src/Form/Description/__snapshots__/FormStatus.stories.ts.snap +3 -3
- package/src/Form/Form/Form.tsx +1 -3
- package/src/Form/Form/__snapshots__/Form.stories.tsx.snap +1 -1
- package/src/Form/Form/__snapshots__/FormTitle.stories.tsx.snap +1 -1
- package/src/Form/FormItem/FormItem.stories.ts +3 -9
- package/src/Form/FormItem/__snapshots__/FormItem.stories.ts.snap +18 -18
- package/src/Form/FormItem/__snapshots__/FormItem.stories.tsx.snap +1 -1
- package/src/Form/Label/FormLabel.tsx +1 -5
- package/src/Form/Label/__snapshots__/FormLabel.stories.tsx.snap +1 -1
- package/src/Form/Label/__snapshots__/Label.stories.ts.snap +3 -3
- package/src/Form/Radio/FormRadio.stories.tsx +1 -3
- package/src/Form/Radio/FormRadio.tsx +4 -25
- package/src/Form/Radio/__snapshots__/Radio.stories.ts.snap +9 -9
- package/src/Form/Search/__snapshots__/Search.stories.ts.snap +1 -1
- package/src/Form/Select/FormSelect.tsx +3 -9
- package/src/Form/Select/__snapshots__/FormSelect.stories.tsx.snap +1 -1
- package/src/Form/Select/__snapshots__/Select.stories.ts.snap +2 -2
- package/src/Form/TextInput/FormText.tsx +3 -9
- package/src/Form/TextInput/TextInput.stories.ts +1 -4
- package/src/Form/TextInput/__snapshots__/FormText.stories.tsx.snap +1 -1
- package/src/Form/TextInput/__snapshots__/InputDivider.stories.ts.snap +1 -1
- package/src/Form/TextInput/__snapshots__/TextInput.stories.ts.snap +3 -3
- package/src/Form/Textarea/FormTextarea.tsx +3 -9
- package/src/Form/Textarea/__snapshots__/FormTextarea.stories.tsx.snap +1 -1
- package/src/Form/Textarea/__snapshots__/Textarea.stories.ts.snap +2 -2
- package/src/Form/form.css +6 -14
- package/src/Introduction.mdx +1 -2
- package/src/Layout/Footer/Footer.stories.ts +1 -5
- package/src/Layout/Footer/Footer.stories.tsx +2 -3
- package/src/Layout/Footer/Footer.tsx +3 -12
- package/src/Layout/Footer/__snapshots__/Footer.stories.ts.snap +4 -4
- package/src/Layout/Footer/__snapshots__/Footer.stories.tsx.snap +1 -1
- package/src/Layout/Grid/Grid.stories.ts +40 -8
- package/src/Layout/Grid/Grid.tsx +1 -2
- package/src/Layout/Grid/GridItem.stories.ts +63 -0
- package/src/Layout/Grid/__snapshots__/Grid.stories.ts.snap +29 -4
- package/src/Layout/Grid/__snapshots__/Grid.stories.tsx.snap +1 -1
- package/src/Layout/Grid/__snapshots__/GridItem.stories.ts.snap +19 -0
- package/src/Layout/Grid/grid-item.twig +3 -9
- package/src/Layout/Grid/grid.css +1 -4
- package/src/Layout/Header/Elements/GlobalToggle.ts +9 -29
- package/src/Layout/Header/__snapshots__/Header.stories.ts.snap +25 -45
- package/src/Layout/Header/__snapshots__/Header.stories.tsx.snap +3 -3
- package/src/Layout/Header/_toggles.css +2 -2
- package/src/Layout/Header/header.twig +1 -1
- package/src/Layout/Masthead/Masthead.stories.ts +1 -4
- package/src/Layout/Masthead/__snapshots__/Masthead.stories.ts.snap +3 -3
- package/src/Layout/Page/Page.stories.tsx +2 -2
- package/src/Layout/Page/__snapshots__/Page.stories.tsx.snap +3 -3
- package/src/Layout/Page/page.css +2 -10
- package/src/Layout/Section/Background.stories.ts +14 -39
- package/src/Layout/Section/Breakouts.stories.ts +3 -0
- package/src/Layout/Section/Flow.stories.ts +3 -0
- package/src/Layout/Section/Section.stories.ts +93 -11
- package/src/Layout/Section/Section.tsx +3 -13
- package/src/Layout/Section/SectionGrid.tsx +2 -9
- package/src/Layout/Section/__snapshots__/Background.stories.ts.snap +4 -4
- package/src/Layout/Section/__snapshots__/Breakouts.stories.ts.snap +1 -1
- package/src/Layout/Section/__snapshots__/Flow.stories.ts.snap +1 -1
- package/src/Layout/Section/__snapshots__/Section.stories.ts.snap +93 -3
- package/src/Layout/Section/__snapshots__/Section.stories.tsx.snap +1 -1
- package/src/Layout/Section/__snapshots__/SectionGrid.stories.tsx.snap +1 -1
- package/src/Layout/Section/section.css +2 -5
- package/src/Layout/Section/section.twig +1 -3
- package/src/Layout/Sidebar/Sidebar.stories.ts +46 -4
- package/src/Layout/Sidebar/Sidebar.tsx +1 -3
- package/src/Layout/Sidebar/__snapshots__/Sidebar.stories.ts.snap +4 -4
- package/src/Layout/Sidebar/__snapshots__/Sidebar.stories.tsx.snap +1 -1
- package/src/Utility/Context/ImageComponent.tsx +4 -8
- package/src/Utility/Context/LinkComponent.tsx +1 -5
- package/src/Utility/Drupal/drupal.css +2 -4
- package/src/Utility/Elements/breakpoint-loader.ts +4 -10
- package/src/Utility/Elements/cookie-compliance.ts +2 -8
- package/src/Utility/Elements/disclosure-widget.ts +11 -18
- package/src/Utility/Elements/io-loader.ts +4 -6
- package/src/Utility/Elements/keyboard.ts +4 -14
- package/src/Utility/Hooks/useLocalStorage.ts +5 -18
- package/src/Utility/Hooks/useMediaQuery.ts +1 -4
- package/src/Utility/Hooks/useToggle.ts +1 -3
- package/src/Utility/global.d.ts +1 -5
- package/src/Utility/utilities.ts +20 -45
- package/src/constants.css +7 -28
- package/src/enums.ts +3 -1
- package/src/react.ts +5 -21
- package/src/tokens.js +2 -2
- package/dist/build/chunks/disclosure-widget-DVpnRsTI.js +0 -126
- package/dist/build/chunks/disclosure-widget-DVpnRsTI.js.map +0 -1
- package/dist/build/chunks/drop-menu.entry-B4TtnC50.js +0 -132
- package/dist/build/chunks/drop-menu.entry-B4TtnC50.js.map +0 -1
- package/dist/build/chunks/keyboard-rvZ4dfGF.js +0 -104
- package/dist/build/chunks/keyboard-rvZ4dfGF.js.map +0 -1
- package/dist/build/chunks/polyfills-C-B7iqDG.js.map +0 -1
- package/dist/build/chunks/utilities-DXELy_An.js.map +0 -1
- package/src/Atom/Text/TextSizes.stories.ts +0 -25
- package/src/Atom/Text/text-alignment.twig +0 -5
- package/src/Component/Accordion/twig/accordion-example.twig +0 -36
- package/src/Component/Tile/README.md +0 -3
- package/src/Component/Tile/Tile.stories.ts +0 -49
- package/src/Component/Tile/Tile.stories.tsx +0 -35
- package/src/Component/Tile/__snapshots__/Tile.stories.ts.snap +0 -57
- package/src/Component/Tile/__snapshots__/Tile.stories.tsx.snap +0 -23
|
@@ -5,6 +5,9 @@ import Image from "../Image/image.twig"
|
|
|
5
5
|
import "../_base.css"
|
|
6
6
|
import { Media as MediaType, MediaAlignmentTypes } from "@pnx-mixtape/ids-shape"
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Media atom with caption and alignment options.
|
|
10
|
+
*/
|
|
8
11
|
const meta: Meta<MediaType> = {
|
|
9
12
|
tags: ["autodocs", "ids-mvp"],
|
|
10
13
|
component: Component,
|
|
@@ -17,11 +20,37 @@ const meta: Meta<MediaType> = {
|
|
|
17
20
|
type: "image",
|
|
18
21
|
},
|
|
19
22
|
argTypes: {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
23
|
+
item: {
|
|
24
|
+
description:
|
|
25
|
+
"An [Image](/?path=/docs/atom-image--docs) or [Video](/?path=/docs/atom-video--docs) object.",
|
|
26
|
+
type: {
|
|
27
|
+
name: "string",
|
|
28
|
+
required: true,
|
|
29
|
+
},
|
|
30
|
+
table: {
|
|
31
|
+
type: { summary: "Image | Video" },
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
caption: {
|
|
35
|
+
description: "An optional caption to display underneath.",
|
|
36
|
+
},
|
|
37
|
+
type: {
|
|
38
|
+
description: "Clarify the item type",
|
|
39
|
+
options: ["image", "video"],
|
|
40
|
+
control: "check",
|
|
41
|
+
table: {
|
|
42
|
+
defaultValue: { summary: "image" },
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
align: {
|
|
46
|
+
description:
|
|
47
|
+
"Align the image (left/right will float the image so that text can wrap around it).",
|
|
48
|
+
options: Object.values(MediaAlignmentTypes),
|
|
49
|
+
control: "radio",
|
|
50
|
+
table: {
|
|
51
|
+
type: { summary: "enum" },
|
|
52
|
+
},
|
|
53
|
+
},
|
|
25
54
|
},
|
|
26
55
|
}
|
|
27
56
|
|
package/src/Atom/Media/Media.tsx
CHANGED
|
@@ -17,12 +17,7 @@ export type ImageProps = ComponentPropsWithoutRef<"img"> & {
|
|
|
17
17
|
align?: MediaAlignmentTypes
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
-
const Media = ({
|
|
21
|
-
align,
|
|
22
|
-
caption,
|
|
23
|
-
className,
|
|
24
|
-
...props
|
|
25
|
-
}: ImageProps): JSX.Element => {
|
|
20
|
+
const Media = ({ align, caption, className, ...props }: ImageProps): JSX.Element => {
|
|
26
21
|
const ImageComponent = useImageComponent()
|
|
27
22
|
|
|
28
23
|
return (
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://
|
|
1
|
+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
|
2
2
|
|
|
3
3
|
exports[`Atom/Media Media smoke-test 1`] = `
|
|
4
4
|
<div class="mx-page default">
|
|
5
|
-
<figure class="mx-media mx-media--image
|
|
5
|
+
<figure class="mx-media mx-media--image">
|
|
6
6
|
<picture>
|
|
7
7
|
<img src="https://picsum.photos/id/56/558/418?grayscale"
|
|
8
8
|
alt="Some blurry bubble image"
|
|
@@ -24,22 +24,14 @@
|
|
|
24
24
|
margin-inline: auto;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
:is(
|
|
28
|
-
.mx-media--left,
|
|
29
|
-
[dir="rtl"] .mx-media--right,
|
|
30
|
-
.translated-rtl .mx-media--right
|
|
31
|
-
) {
|
|
27
|
+
:is(.mx-media--left, [dir="rtl"] .mx-media--right, .translated-rtl .mx-media--right) {
|
|
32
28
|
@media (--small-up) {
|
|
33
29
|
float: left;
|
|
34
30
|
margin-inline: 0 var(--spacing-m);
|
|
35
31
|
}
|
|
36
32
|
}
|
|
37
33
|
|
|
38
|
-
:is(
|
|
39
|
-
.mx-media--right,
|
|
40
|
-
[dir="rtl"] .mx-media--left,
|
|
41
|
-
.translated-rtl .mx-media--left
|
|
42
|
-
) {
|
|
34
|
+
:is(.mx-media--right, [dir="rtl"] .mx-media--left, .translated-rtl .mx-media--left) {
|
|
43
35
|
@media (--small-up) {
|
|
44
36
|
float: right;
|
|
45
37
|
margin-inline: var(--spacing-m) 0;
|
|
@@ -1,48 +1,62 @@
|
|
|
1
1
|
import { Meta, StoryObj } from "@storybook/html-vite"
|
|
2
2
|
import Component from "./spacing.twig"
|
|
3
|
-
import "../_base.css"
|
|
4
3
|
|
|
5
4
|
const modifierOptions: string[] = [
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"
|
|
5
|
+
"xs",
|
|
6
|
+
"s",
|
|
7
|
+
"m",
|
|
8
|
+
"l",
|
|
9
|
+
"xl",
|
|
10
|
+
"top-xs",
|
|
11
|
+
"top-s",
|
|
12
|
+
"top-m",
|
|
13
|
+
"top-l",
|
|
14
|
+
"top-xl",
|
|
15
|
+
"bottom-xs",
|
|
16
|
+
"bottom-s",
|
|
17
|
+
"bottom-m",
|
|
18
|
+
"bottom-l",
|
|
19
|
+
"bottom-xl",
|
|
20
|
+
"left-xs",
|
|
21
|
+
"left-s",
|
|
22
|
+
"left-m",
|
|
23
|
+
"left-l",
|
|
24
|
+
"left-xl",
|
|
25
|
+
"right-xs",
|
|
26
|
+
"right-s",
|
|
27
|
+
"right-m",
|
|
28
|
+
"right-l",
|
|
29
|
+
"right-xl",
|
|
30
|
+
"reset",
|
|
31
|
+
"reset-top",
|
|
32
|
+
"reset-bottom",
|
|
33
|
+
"reset-left",
|
|
34
|
+
"reset-right",
|
|
31
35
|
]
|
|
32
36
|
|
|
33
37
|
type SpacingType = {
|
|
34
|
-
|
|
38
|
+
modifier?: (typeof modifierOptions)[number]
|
|
35
39
|
}
|
|
36
40
|
|
|
41
|
+
/**
|
|
42
|
+
* Demonstration of the spacing helper classes that are available to add padding to an element.
|
|
43
|
+
*/
|
|
37
44
|
const meta: Meta<SpacingType> = {
|
|
38
|
-
title: "Atom/Spacing",
|
|
39
45
|
tags: ["autodocs"],
|
|
40
46
|
component: Component,
|
|
47
|
+
args: {
|
|
48
|
+
modifier: modifierOptions[0],
|
|
49
|
+
},
|
|
50
|
+
argTypes: {
|
|
51
|
+
modifier: {
|
|
52
|
+
description: "The spacing option",
|
|
53
|
+
options: modifierOptions,
|
|
54
|
+
control: "select",
|
|
55
|
+
},
|
|
56
|
+
},
|
|
41
57
|
}
|
|
42
58
|
|
|
43
59
|
export default meta
|
|
44
60
|
type Story = StoryObj<SpacingType>
|
|
45
61
|
|
|
46
|
-
export const Spacing: Story = {
|
|
47
|
-
args: {},
|
|
48
|
-
}
|
|
62
|
+
export const Spacing: Story = {}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://
|
|
1
|
+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
|
2
2
|
|
|
3
3
|
exports[`Atom/Spacing Spacing smoke-test 1`] = `
|
|
4
4
|
<div class="mx-page default">
|
|
5
|
-
<div class="mx-spacing
|
|
6
|
-
<
|
|
7
|
-
|
|
5
|
+
<div class="mx-spacing--xs">
|
|
6
|
+
<div>
|
|
7
|
+
mx-spacing--xs
|
|
8
|
+
</div>
|
|
8
9
|
</div>
|
|
9
10
|
</div>
|
|
10
11
|
`;
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
{% set baseClass = "mx-spacing" %}
|
|
2
|
+
{% set class = baseClass ~ '--' ~ modifier %}
|
|
3
|
+
{% set attributes = (attributes ?? create_attribute()).addClass(class) %}
|
|
4
|
+
<div{{ attributes }}>
|
|
5
|
+
<div>{{ class }}</div>
|
|
3
6
|
</div>
|
|
@@ -11,8 +11,7 @@
|
|
|
11
11
|
|
|
12
12
|
& :is(td, th) {
|
|
13
13
|
padding: var(--spacing-xxs);
|
|
14
|
-
border-block-end: var(--line-width, 1px) solid
|
|
15
|
-
var(--line-colour, var(--colour-border));
|
|
14
|
+
border-block-end: var(--line-width, 1px) solid var(--line-colour, var(--colour-border));
|
|
16
15
|
vertical-align: top;
|
|
17
16
|
}
|
|
18
17
|
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { Meta, StoryObj } from "@storybook/html-vite"
|
|
2
|
+
import Component from "./text-style.twig"
|
|
3
|
+
import ExampleComponent from "./text-styles-example.twig"
|
|
4
|
+
import "../_base.css"
|
|
5
|
+
import { TextStyles } from "../../enums"
|
|
6
|
+
|
|
7
|
+
enum TextAlign {
|
|
8
|
+
LEFT = "mx-text--left",
|
|
9
|
+
RIGHT = "mx-text--right",
|
|
10
|
+
CENTER = "mx-text--center",
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
type TextProps = {
|
|
14
|
+
modifier?: TextStyles
|
|
15
|
+
alignment?: TextAlign
|
|
16
|
+
content: string
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Demonstration of the text helper classes that are available to control typographic sizes.
|
|
21
|
+
*/
|
|
22
|
+
const meta: Meta<TextProps> = {
|
|
23
|
+
tags: ["autodocs"],
|
|
24
|
+
component: Component,
|
|
25
|
+
args: {
|
|
26
|
+
content:
|
|
27
|
+
"In publishing and graphic design, lorem ipsum is a placeholder text commonly used to demonstrate the visual form of a document without relying on meaningful content (also called greeking). Replacing the actual content with placeholder text allows designers to design the form of the content before the content itself has been produced.",
|
|
28
|
+
},
|
|
29
|
+
argTypes: {
|
|
30
|
+
modifier: {
|
|
31
|
+
description: "Set the size of the text",
|
|
32
|
+
options: Object.values(TextStyles),
|
|
33
|
+
control: "select",
|
|
34
|
+
table: {
|
|
35
|
+
type: { summary: "enum" },
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
alignment: {
|
|
39
|
+
description: "Set the alignment of the text",
|
|
40
|
+
options: Object.values(TextAlign),
|
|
41
|
+
control: "select",
|
|
42
|
+
table: {
|
|
43
|
+
type: { summary: "enum" },
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export default meta
|
|
50
|
+
type Story = StoryObj<TextProps>
|
|
51
|
+
|
|
52
|
+
export const Text: Story = {}
|
|
53
|
+
|
|
54
|
+
export const Center: Story = {
|
|
55
|
+
args: {
|
|
56
|
+
alignment: TextAlign.CENTER,
|
|
57
|
+
},
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export const Example: Story = {
|
|
61
|
+
render: args => `<div class="mx-rich-text mx-vertical-flow">${ExampleComponent(args)}</div>`,
|
|
62
|
+
}
|
|
@@ -1,35 +1,22 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://
|
|
1
|
+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
|
2
2
|
|
|
3
|
-
exports[`Atom/
|
|
3
|
+
exports[`Atom/Text Center smoke-test 1`] = `
|
|
4
4
|
<div class="mx-page default">
|
|
5
|
-
<div class="vertical-flow">
|
|
5
|
+
<div class="mx-rich-text mx-vertical-flow mx-section--narrow mx-text--center">
|
|
6
|
+
In publishing and graphic design, lorem ipsum is a placeholder text commonly used to demonstrate the visual form of a document without relying on meaningful content (also called greeking). Replacing the actual content with placeholder text allows designers to design the form of the content before the content itself has been produced.
|
|
7
|
+
</div>
|
|
8
|
+
</div>
|
|
9
|
+
`;
|
|
10
|
+
|
|
11
|
+
exports[`Atom/Text Example smoke-test 1`] = `
|
|
12
|
+
<div class="mx-page default">
|
|
13
|
+
<div class="mx-rich-text mx-vertical-flow">
|
|
6
14
|
<p class="mx-text--embellished-headline">
|
|
7
15
|
Embelished headline: Lorem ipsum dolor sit amet consectetur
|
|
8
16
|
</p>
|
|
9
17
|
<p class="mx-text--section-headline">
|
|
10
18
|
Section headline: Lorem ipsum dolor sit amet consectetur
|
|
11
19
|
</p>
|
|
12
|
-
<h2 class="mx-headline">
|
|
13
|
-
Headline: Lorem ipsum dolor sit amet consectetur
|
|
14
|
-
</h2>
|
|
15
|
-
<p class="mx-heading--xxl">
|
|
16
|
-
Heading xxl: Lorem ipsum dolor sit amet consectetur
|
|
17
|
-
</p>
|
|
18
|
-
<p class="mx-heading--xl">
|
|
19
|
-
Heading xl: Lorem ipsum dolor sit amet consectetur
|
|
20
|
-
</p>
|
|
21
|
-
<p class="mx-heading--l">
|
|
22
|
-
Heading l: Lorem ipsum dolor sit amet consectetur
|
|
23
|
-
</p>
|
|
24
|
-
<p class="mx-heading--m">
|
|
25
|
-
Heading m: Lorem ipsum dolor sit amet consectetur
|
|
26
|
-
</p>
|
|
27
|
-
<p class="mx-heading--s">
|
|
28
|
-
Heading s: Lorem ipsum dolor sit amet consectetur
|
|
29
|
-
</p>
|
|
30
|
-
<p class="mx-heading--xs">
|
|
31
|
-
Heading xs: Lorem ipsum dolor sit amet consectetur
|
|
32
|
-
</p>
|
|
33
20
|
<p class="mx-text--xxxl">
|
|
34
21
|
Text xxxl: Lorem ipsum dolor sit amet consectetur
|
|
35
22
|
</p>
|
|
@@ -58,10 +45,10 @@ exports[`Atom/Typography/Text Sizes Example smoke-test 1`] = `
|
|
|
58
45
|
</div>
|
|
59
46
|
`;
|
|
60
47
|
|
|
61
|
-
exports[`Atom/
|
|
48
|
+
exports[`Atom/Text Text smoke-test 1`] = `
|
|
62
49
|
<div class="mx-page default">
|
|
63
|
-
<
|
|
50
|
+
<div class="mx-rich-text mx-vertical-flow mx-section--narrow">
|
|
64
51
|
In publishing and graphic design, lorem ipsum is a placeholder text commonly used to demonstrate the visual form of a document without relying on meaningful content (also called greeking). Replacing the actual content with placeholder text allows designers to design the form of the content before the content itself has been produced.
|
|
65
|
-
</
|
|
52
|
+
</div>
|
|
66
53
|
</div>
|
|
67
54
|
`;
|
|
@@ -26,9 +26,7 @@
|
|
|
26
26
|
.mx-text--xxxl,
|
|
27
27
|
.mx-text--fluid
|
|
28
28
|
) {
|
|
29
|
-
--font-min: calc(
|
|
30
|
-
var(--font-size) - var(--font-size) * var(--font-size-diff, 0.3)
|
|
31
|
-
);
|
|
29
|
+
--font-min: calc(var(--font-size) - var(--font-size) * var(--font-size-diff, 0.3));
|
|
32
30
|
|
|
33
31
|
font-size: clamp(
|
|
34
32
|
max(var(--base-font-size), var(--font-min)),
|
|
@@ -71,7 +69,7 @@
|
|
|
71
69
|
inline-size: var(--spacing-xxxl);
|
|
72
70
|
block-size: 3px;
|
|
73
71
|
background-color: var(--colour-primary);
|
|
74
|
-
inset-block-
|
|
72
|
+
inset-block-end: -8px;
|
|
75
73
|
}
|
|
76
74
|
}
|
|
77
75
|
|
|
@@ -1 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
{% set classes = [
|
|
2
|
+
"mx-rich-text",
|
|
3
|
+
"mx-vertical-flow",
|
|
4
|
+
"mx-section--narrow",
|
|
5
|
+
modifier,
|
|
6
|
+
alignment
|
|
7
|
+
] %}
|
|
8
|
+
{% set attributes = (attributes ?? create_attribute()).addClass(classes) %}
|
|
9
|
+
<div{{ attributes }}>
|
|
10
|
+
{{ content }}
|
|
11
|
+
</div>
|
|
@@ -1,22 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
2
|
<p class="mx-text--embellished-headline">Embelished headline: Lorem ipsum dolor sit amet consectetur</p>
|
|
3
3
|
|
|
4
4
|
<p class="mx-text--section-headline">Section headline: Lorem ipsum dolor sit amet consectetur</p>
|
|
5
5
|
|
|
6
|
-
<h2 class="mx-headline">Headline: Lorem ipsum dolor sit amet consectetur</h2>
|
|
7
|
-
|
|
8
|
-
<p class="mx-heading--xxl">Heading xxl: Lorem ipsum dolor sit amet consectetur</p>
|
|
9
|
-
|
|
10
|
-
<p class="mx-heading--xl">Heading xl: Lorem ipsum dolor sit amet consectetur</p>
|
|
11
|
-
|
|
12
|
-
<p class="mx-heading--l">Heading l: Lorem ipsum dolor sit amet consectetur</p>
|
|
13
|
-
|
|
14
|
-
<p class="mx-heading--m">Heading m: Lorem ipsum dolor sit amet consectetur</p>
|
|
15
|
-
|
|
16
|
-
<p class="mx-heading--s">Heading s: Lorem ipsum dolor sit amet consectetur</p>
|
|
17
|
-
|
|
18
|
-
<p class="mx-heading--xs">Heading xs: Lorem ipsum dolor sit amet consectetur</p>
|
|
19
|
-
|
|
20
6
|
<p class="mx-text--xxxl">Text xxxl: Lorem ipsum dolor sit amet consectetur</p>
|
|
21
7
|
|
|
22
8
|
<p class="mx-text--xxl">Text xxl: Lorem ipsum dolor sit amet consectetur</p>
|
|
@@ -32,4 +18,4 @@
|
|
|
32
18
|
<p class="mx-text--s">Text s: Lorem ipsum dolor sit amet consectetur</p>
|
|
33
19
|
|
|
34
20
|
<p class="mx-text--xs">Text xs: Lorem ipsum dolor sit amet consectetur</p>
|
|
35
|
-
|
|
21
|
+
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { Meta, StoryObj } from "@storybook/html-vite"
|
|
2
2
|
import Component from "./video.twig"
|
|
3
|
-
import "
|
|
3
|
+
import { Video as VideoType } from "@pnx-mixtape/ids-shape"
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
/**
|
|
6
|
+
* A simple video embed atom.
|
|
7
|
+
*/
|
|
8
|
+
const meta: Meta<VideoType> = {
|
|
7
9
|
tags: ["autodocs"],
|
|
8
10
|
component: Component,
|
|
9
11
|
args: {
|
|
@@ -13,6 +15,6 @@ const meta: Meta<typeof Component> = {
|
|
|
13
15
|
}
|
|
14
16
|
|
|
15
17
|
export default meta
|
|
16
|
-
type Story = StoryObj<
|
|
18
|
+
type Story = StoryObj<VideoType>
|
|
17
19
|
|
|
18
20
|
export const Video: Story = {}
|
package/src/Atom/Video/Video.tsx
CHANGED
|
@@ -4,11 +4,7 @@ import classNames from "classnames"
|
|
|
4
4
|
|
|
5
5
|
type VideoProps = ComponentPropsWithoutRef<"iframe">
|
|
6
6
|
|
|
7
|
-
const Video = ({
|
|
8
|
-
title,
|
|
9
|
-
className = null,
|
|
10
|
-
...props
|
|
11
|
-
}: VideoProps): JSX.Element => (
|
|
7
|
+
const Video = ({ title, className = null, ...props }: VideoProps): JSX.Element => (
|
|
12
8
|
<figure className={classNames("mx-video", className)}>
|
|
13
9
|
<iframe title={title} {...props} />
|
|
14
10
|
</figure>
|
package/src/Atom/_generic.css
CHANGED
|
@@ -11,8 +11,7 @@
|
|
|
11
11
|
margin: 0;
|
|
12
12
|
opacity: 1;
|
|
13
13
|
transition-property:
|
|
14
|
-
opacity, color, background-color, border-color, transform, rotate,
|
|
15
|
-
display, overlay;
|
|
14
|
+
opacity, color, background-color, border-color, transform, rotate, display, overlay;
|
|
16
15
|
transition-duration: 0.5s;
|
|
17
16
|
transition-timing-function: var(--ease);
|
|
18
17
|
transition-behavior: allow-discrete;
|
|
@@ -27,8 +26,7 @@
|
|
|
27
26
|
}
|
|
28
27
|
|
|
29
28
|
:focus-visible {
|
|
30
|
-
outline: var(--outline-size, 2px) var(--outline-style, solid)
|
|
31
|
-
var(--outline-color, currentcolor);
|
|
29
|
+
outline: var(--outline-size, 2px) var(--outline-style, solid) var(--outline-color, currentcolor);
|
|
32
30
|
outline-offset: var(--outline-offset, var(--outline-size, 2px));
|
|
33
31
|
}
|
|
34
32
|
|
|
@@ -50,6 +48,8 @@
|
|
|
50
48
|
accent-color: var(--colour-primary);
|
|
51
49
|
text-rendering: optimizespeed;
|
|
52
50
|
block-size: 100%;
|
|
51
|
+
padding-inline: unset;
|
|
52
|
+
padding-block: unset;
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
:target,
|
package/src/Atom/_hr.css
CHANGED
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
display: block;
|
|
4
4
|
block-size: 0;
|
|
5
5
|
border: 0;
|
|
6
|
-
border-block-start: var(--line-width, 1px) solid
|
|
7
|
-
var(--line-colour, var(--colour-border));
|
|
6
|
+
border-block-start: var(--line-width, 1px) solid var(--line-colour, var(--colour-border));
|
|
8
7
|
margin-block: var(--line-gap, var(--spacing-m));
|
|
9
8
|
}
|
|
10
9
|
}
|
|
@@ -2,12 +2,11 @@ import { Meta, StoryObj } from "@storybook/html-vite"
|
|
|
2
2
|
import Component from "./accordion.twig"
|
|
3
3
|
import AccordionItem from "./accordion-item.twig"
|
|
4
4
|
import Heading from "../../Atom/Heading/heading.twig"
|
|
5
|
+
import "./Elements/Accordion"
|
|
5
6
|
import "./Elements/AccordionGroup"
|
|
7
|
+
import "./Elements/AccordionMobile"
|
|
6
8
|
import "./accordion.css"
|
|
7
|
-
import {
|
|
8
|
-
Accordion as AccordionType,
|
|
9
|
-
HeadingTypes,
|
|
10
|
-
} from "@pnx-mixtape/ids-shape"
|
|
9
|
+
import { Accordion as AccordionType, HeadingTypes } from "@pnx-mixtape/ids-shape"
|
|
11
10
|
|
|
12
11
|
const meta: Meta<AccordionType> = {
|
|
13
12
|
tags: ["autodocs", "ids-mvp"],
|
|
@@ -31,10 +30,29 @@ const meta: Meta<AccordionType> = {
|
|
|
31
30
|
],
|
|
32
31
|
},
|
|
33
32
|
argTypes: {
|
|
34
|
-
toggleAll: {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
33
|
+
toggleAll: {
|
|
34
|
+
control: "boolean",
|
|
35
|
+
description: "Include the **Expand all / Collapse all** behaviour.",
|
|
36
|
+
table: { defaultValue: { summary: "false" } },
|
|
37
|
+
type: "boolean",
|
|
38
|
+
},
|
|
39
|
+
title: {
|
|
40
|
+
description:
|
|
41
|
+
"Optional [Heading](/?path=/docs/atom-heading--docs) component, displayed above the accordions.",
|
|
42
|
+
control: "text",
|
|
43
|
+
},
|
|
44
|
+
items: {
|
|
45
|
+
description:
|
|
46
|
+
"A list of [AccordionItem](/?path=/docs/component-accordion-accordionitem--docs) objects.",
|
|
47
|
+
type: {
|
|
48
|
+
name: "other",
|
|
49
|
+
required: true,
|
|
50
|
+
value: "array",
|
|
51
|
+
},
|
|
52
|
+
table: {
|
|
53
|
+
type: { summary: "AccordionItem[]" },
|
|
54
|
+
},
|
|
55
|
+
},
|
|
38
56
|
},
|
|
39
57
|
}
|
|
40
58
|
|
|
@@ -17,11 +17,10 @@ const meta: Meta<typeof Component> = {
|
|
|
17
17
|
<AccordionTitleIcon />
|
|
18
18
|
</AccordionTitle>
|
|
19
19
|
<AccordionContent>
|
|
20
|
-
I'm baby air plant hashtag letterpress blue bottle. Cloud bread
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
health goth.
|
|
20
|
+
I'm baby air plant hashtag letterpress blue bottle. Cloud bread dreamcatcher everyday
|
|
21
|
+
carry lumbersexual, iceland cardigan swag chicharrones lo-fi fanny pack affogato freegan
|
|
22
|
+
XOXO shaman. Shoreditch cloud bread waistcoat tbh XOXO. Chillwave pour-over umami pug
|
|
23
|
+
glossier health goth.
|
|
25
24
|
</AccordionContent>
|
|
26
25
|
</>
|
|
27
26
|
),
|
|
@@ -39,11 +38,10 @@ export const HeadingLevel: StoryObj<typeof meta> = {
|
|
|
39
38
|
<AccordionTitleIcon />
|
|
40
39
|
</AccordionTitle>
|
|
41
40
|
<AccordionContent>
|
|
42
|
-
I'm baby air plant hashtag letterpress blue bottle. Cloud bread
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
health goth.
|
|
41
|
+
I'm baby air plant hashtag letterpress blue bottle. Cloud bread dreamcatcher everyday
|
|
42
|
+
carry lumbersexual, iceland cardigan swag chicharrones lo-fi fanny pack affogato freegan
|
|
43
|
+
XOXO shaman. Shoreditch cloud bread waistcoat tbh XOXO. Chillwave pour-over umami pug
|
|
44
|
+
glossier health goth.
|
|
47
45
|
</AccordionContent>
|
|
48
46
|
</>
|
|
49
47
|
),
|
|
@@ -1,12 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
JSX,
|
|
3
|
-
PropsWithChildren,
|
|
4
|
-
useEffect,
|
|
5
|
-
useId,
|
|
6
|
-
createContext,
|
|
7
|
-
use,
|
|
8
|
-
useMemo,
|
|
9
|
-
} from "react"
|
|
1
|
+
import { JSX, PropsWithChildren, useEffect, useId, createContext, use, useMemo } from "react"
|
|
10
2
|
import classNames from "classnames"
|
|
11
3
|
import useToggle from "../../Utility/Hooks/useToggle"
|
|
12
4
|
|
|
@@ -40,10 +32,7 @@ const Accordion = ({
|
|
|
40
32
|
}
|
|
41
33
|
}, [accordionId])
|
|
42
34
|
|
|
43
|
-
const values = useMemo(
|
|
44
|
-
() => ({ on, toggle, id: accordionId }),
|
|
45
|
-
[on, toggle, accordionId],
|
|
46
|
-
)
|
|
35
|
+
const values = useMemo(() => ({ on, toggle, id: accordionId }), [on, toggle, accordionId])
|
|
47
36
|
|
|
48
37
|
return (
|
|
49
38
|
<AccordionContext value={values}>
|