@deriv-com/dds-marketing 0.1.0 → 0.2.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/.llm/components/accordion.md +193 -0
- package/.llm/components/accordionitem.md +236 -0
- package/.llm/components/aspectratio.md +212 -0
- package/.llm/components/badge.md +231 -0
- package/.llm/components/bottomsheet.md +404 -0
- package/.llm/components/breadcrumb.md +197 -0
- package/.llm/components/breadcrumbitem.md +178 -0
- package/.llm/components/button.md +271 -0
- package/.llm/components/buttonicon.md +313 -0
- package/.llm/components/card.md +313 -0
- package/.llm/components/cardbody.md +409 -0
- package/.llm/components/cardbutton.md +259 -0
- package/.llm/components/checkbox.md +285 -0
- package/.llm/components/divider.md +230 -0
- package/.llm/components/dropdownmenu.md +453 -0
- package/.llm/components/filterchip.md +314 -0
- package/.llm/components/footer.md +408 -0
- package/.llm/components/footergroup.md +241 -0
- package/.llm/components/grid.md +659 -0
- package/.llm/components/icon.md +194 -0
- package/.llm/components/link.md +354 -0
- package/.llm/components/menuitem.md +218 -0
- package/.llm/components/navbar.md +458 -0
- package/.llm/components/navbaritem.md +238 -0
- package/.llm/components/navbarmenu.md +319 -0
- package/.llm/components/navbarmenugroup.md +184 -0
- package/.llm/components/navbarpanel.md +255 -0
- package/.llm/components/navbarswitcher.md +343 -0
- package/.llm/components/navbarswitcheroption.md +156 -0
- package/.llm/components/option.md +268 -0
- package/.llm/components/pagination.md +361 -0
- package/.llm/components/removablechip.md +247 -0
- package/.llm/components/row.md +381 -0
- package/.llm/components/scroller.md +470 -0
- package/.llm/components/searchinput.md +279 -0
- package/.llm/components/segmentedcontrol.md +358 -0
- package/.llm/components/segmentedcontrolitem.md +272 -0
- package/.llm/components/select.md +509 -0
- package/.llm/components/selectchip.md +334 -0
- package/.llm/components/spinner.md +222 -0
- package/.llm/components/stack.md +334 -0
- package/.llm/components/statusdot.md +205 -0
- package/.llm/components/subdomainnavbar.md +327 -0
- package/.llm/components/tab.md +291 -0
- package/.llm/components/table.md +660 -0
- package/.llm/components/tablebody.md +258 -0
- package/.llm/components/tablecell.md +248 -0
- package/.llm/components/tablehead.md +248 -0
- package/.llm/components/tableheadercell.md +298 -0
- package/.llm/components/tablerow.md +285 -0
- package/.llm/components/tablist.md +210 -0
- package/.llm/components/textarea.md +362 -0
- package/.llm/components/textinput.md +467 -0
- package/.llm/components/tooltip.md +267 -0
- package/.llm/components/typography.md +245 -0
- package/.llm/digest/accordion.md +43 -0
- package/.llm/digest/accordionitem.md +47 -0
- package/.llm/digest/aspectratio.md +47 -0
- package/.llm/digest/badge.md +45 -0
- package/.llm/digest/bottomsheet.md +69 -0
- package/.llm/digest/breadcrumb.md +38 -0
- package/.llm/digest/breadcrumbitem.md +43 -0
- package/.llm/digest/button.md +48 -0
- package/.llm/digest/buttonicon.md +61 -0
- package/.llm/digest/card.md +50 -0
- package/.llm/digest/cardbody.md +68 -0
- package/.llm/digest/cardbutton.md +49 -0
- package/.llm/digest/checkbox.md +63 -0
- package/.llm/digest/divider.md +52 -0
- package/.llm/digest/dropdownmenu.md +67 -0
- package/.llm/digest/filterchip.md +68 -0
- package/.llm/digest/footer.md +57 -0
- package/.llm/digest/footergroup.md +42 -0
- package/.llm/digest/grid.md +62 -0
- package/.llm/digest/icon.md +45 -0
- package/.llm/digest/link.md +59 -0
- package/.llm/digest/menuitem.md +46 -0
- package/.llm/digest/navbar.md +60 -0
- package/.llm/digest/navbaritem.md +54 -0
- package/.llm/digest/navbarmenu.md +54 -0
- package/.llm/digest/navbarmenugroup.md +40 -0
- package/.llm/digest/navbarpanel.md +53 -0
- package/.llm/digest/navbarswitcher.md +51 -0
- package/.llm/digest/navbarswitcheroption.md +37 -0
- package/.llm/digest/option.md +54 -0
- package/.llm/digest/pagination.md +71 -0
- package/.llm/digest/removablechip.md +51 -0
- package/.llm/digest/row.md +60 -0
- package/.llm/digest/scroller.md +59 -0
- package/.llm/digest/searchinput.md +56 -0
- package/.llm/digest/segmentedcontrol.md +59 -0
- package/.llm/digest/segmentedcontrolitem.md +59 -0
- package/.llm/digest/select.md +92 -0
- package/.llm/digest/selectchip.md +68 -0
- package/.llm/digest/spinner.md +52 -0
- package/.llm/digest/stack.md +56 -0
- package/.llm/digest/statusdot.md +46 -0
- package/.llm/digest/subdomainnavbar.md +54 -0
- package/.llm/digest/tab.md +60 -0
- package/.llm/digest/table.md +71 -0
- package/.llm/digest/tablebody.md +49 -0
- package/.llm/digest/tablecell.md +55 -0
- package/.llm/digest/tablehead.md +50 -0
- package/.llm/digest/tableheadercell.md +65 -0
- package/.llm/digest/tablerow.md +56 -0
- package/.llm/digest/tablist.md +46 -0
- package/.llm/digest/textarea.md +78 -0
- package/.llm/digest/textinput.md +95 -0
- package/.llm/digest/tooltip.md +58 -0
- package/.llm/digest/typography.md +59 -0
- package/.llm/index.md +86 -0
- package/.llm/rules.md +122 -0
- package/.llm/tokens.md +341 -0
- package/AGENTS.md +164 -0
- package/LICENSE +21 -0
- package/README.md +63 -15
- package/dist/components/core/accordion/Accordion.css +10 -0
- package/dist/components/core/accordion/Accordion.d.ts +20 -0
- package/dist/components/core/accordion/Accordion.js +69 -0
- package/dist/components/core/accordion/Accordion.types.d.ts +20 -0
- package/dist/components/core/accordion/Accordion.types.js +7 -0
- package/dist/components/core/accordion-item/AccordionItem.css +98 -0
- package/dist/components/core/accordion-item/AccordionItem.d.ts +44 -0
- package/dist/components/core/accordion-item/AccordionItem.js +63 -0
- package/dist/components/core/accordion-item/AccordionItem.types.d.ts +32 -0
- package/dist/components/core/accordion-item/AccordionItem.types.js +13 -0
- package/dist/components/core/accordion-item/accordion-item-impl.css +107 -0
- package/dist/components/core/badge/Badge.css +37 -0
- package/dist/components/core/badge/Badge.d.ts +37 -0
- package/dist/components/core/badge/Badge.js +40 -0
- package/dist/components/core/badge/Badge.types.d.ts +24 -0
- package/dist/components/core/badge/Badge.types.js +8 -0
- package/dist/components/core/badge/badge-impl.css +32 -0
- package/dist/components/core/bottom-sheet/BottomSheet.css +178 -0
- package/dist/components/core/bottom-sheet/BottomSheet.d.ts +22 -0
- package/dist/components/core/bottom-sheet/BottomSheet.js +359 -0
- package/dist/components/core/bottom-sheet/BottomSheet.types.d.ts +67 -0
- package/dist/components/core/bottom-sheet/BottomSheet.types.js +18 -0
- package/dist/components/core/bottom-sheet/bottom-sheet-impl.css +57 -0
- package/dist/components/core/breadcrumb/Breadcrumb.css +19 -0
- package/dist/components/core/breadcrumb/Breadcrumb.d.ts +16 -0
- package/dist/components/core/breadcrumb/Breadcrumb.js +22 -0
- package/dist/components/core/breadcrumb/Breadcrumb.types.d.ts +18 -0
- package/dist/components/core/breadcrumb/Breadcrumb.types.js +9 -0
- package/dist/components/core/breadcrumb-item/BreadcrumbItem.css +34 -0
- package/dist/components/core/breadcrumb-item/BreadcrumbItem.d.ts +12 -0
- package/dist/components/core/breadcrumb-item/BreadcrumbItem.js +15 -0
- package/dist/components/core/breadcrumb-item/BreadcrumbItem.types.d.ts +22 -0
- package/dist/components/core/breadcrumb-item/BreadcrumbItem.types.js +9 -0
- package/dist/components/core/button/Button.css +141 -0
- package/dist/components/core/button/Button.d.ts +25 -0
- package/dist/components/core/button/Button.js +28 -0
- package/dist/components/core/button/Button.types.d.ts +40 -0
- package/dist/components/core/button/Button.types.js +9 -0
- package/dist/components/core/button/button-impl.css +46 -0
- package/dist/components/core/button-icon/ButtonIcon.css +135 -0
- package/dist/components/core/button-icon/ButtonIcon.d.ts +34 -0
- package/dist/components/core/button-icon/ButtonIcon.js +117 -0
- package/dist/components/core/button-icon/ButtonIcon.types.d.ts +41 -0
- package/dist/components/core/button-icon/ButtonIcon.types.js +8 -0
- package/dist/components/core/card/Card.css +65 -0
- package/dist/components/core/card/Card.d.ts +24 -0
- package/dist/components/core/card/Card.js +26 -0
- package/dist/components/core/card/Card.types.d.ts +33 -0
- package/dist/components/core/card/Card.types.js +7 -0
- package/dist/components/core/card-body/CardBody.css +139 -0
- package/dist/components/core/card-body/CardBody.d.ts +62 -0
- package/dist/components/core/card-body/CardBody.js +97 -0
- package/dist/components/core/card-body/CardBody.types.d.ts +61 -0
- package/dist/components/core/card-body/CardBody.types.js +15 -0
- package/dist/components/core/card-body/card-body-impl.css +87 -0
- package/dist/components/core/card-button/CardButton.css +73 -0
- package/dist/components/core/card-button/CardButton.d.ts +27 -0
- package/dist/components/core/card-button/CardButton.js +37 -0
- package/dist/components/core/card-button/CardButton.types.d.ts +24 -0
- package/dist/components/core/card-button/CardButton.types.js +7 -0
- package/dist/components/core/card-button/card-button-impl.css +39 -0
- package/dist/components/core/checkbox/Checkbox.css +149 -0
- package/dist/components/core/checkbox/Checkbox.d.ts +21 -0
- package/dist/components/core/checkbox/Checkbox.js +97 -0
- package/dist/components/core/checkbox/Checkbox.types.d.ts +46 -0
- package/dist/components/core/checkbox/Checkbox.types.js +15 -0
- package/dist/components/core/checkbox/checkbox-impl.css +90 -0
- package/dist/components/core/divider/Divider.css +41 -0
- package/dist/components/core/divider/Divider.d.ts +46 -0
- package/dist/components/core/divider/Divider.js +51 -0
- package/dist/components/core/divider/Divider.types.d.ts +25 -0
- package/dist/components/core/divider/Divider.types.js +9 -0
- package/dist/components/core/dropdown-menu/DropdownMenu.css +146 -0
- package/dist/components/core/dropdown-menu/DropdownMenu.d.ts +22 -0
- package/dist/components/core/dropdown-menu/DropdownMenu.js +309 -0
- package/dist/components/core/dropdown-menu/DropdownMenu.types.d.ts +62 -0
- package/dist/components/core/dropdown-menu/DropdownMenu.types.js +12 -0
- package/dist/components/core/dropdown-menu/dropdown-menu-impl.css +70 -0
- package/dist/components/core/filter-chip/FilterChip.css +149 -0
- package/dist/components/core/filter-chip/FilterChip.d.ts +23 -0
- package/dist/components/core/filter-chip/FilterChip.js +37 -0
- package/dist/components/core/filter-chip/FilterChip.types.d.ts +53 -0
- package/dist/components/core/filter-chip/FilterChip.types.js +12 -0
- package/dist/components/core/footer/Footer.css +104 -0
- package/dist/components/core/footer/Footer.d.ts +43 -0
- package/dist/components/core/footer/Footer.js +53 -0
- package/dist/components/core/footer/Footer.types.d.ts +47 -0
- package/dist/components/core/footer/Footer.types.js +18 -0
- package/dist/components/core/footer/footer-impl.css +218 -0
- package/dist/components/core/footer-group/FooterGroup.css +90 -0
- package/dist/components/core/footer-group/FooterGroup.d.ts +32 -0
- package/dist/components/core/footer-group/FooterGroup.js +64 -0
- package/dist/components/core/footer-group/FooterGroup.types.d.ts +25 -0
- package/dist/components/core/footer-group/FooterGroup.types.js +12 -0
- package/dist/components/core/footer-group/footer-group-impl.css +78 -0
- package/dist/components/core/icon/Icon.css +40 -0
- package/dist/components/core/icon/Icon.d.ts +23 -0
- package/dist/components/core/icon/Icon.js +79 -0
- package/dist/components/core/icon/Icon.types.d.ts +24 -0
- package/dist/components/core/icon/Icon.types.js +7 -0
- package/dist/components/core/link/Link.css +89 -0
- package/dist/components/core/link/Link.d.ts +37 -0
- package/dist/components/core/link/Link.js +141 -0
- package/dist/components/core/link/Link.types.d.ts +41 -0
- package/dist/components/core/link/Link.types.js +9 -0
- package/dist/components/core/link/link-impl.css +168 -0
- package/dist/components/core/menu-item/MenuItem.css +70 -0
- package/dist/components/core/menu-item/MenuItem.d.ts +11 -0
- package/dist/components/core/menu-item/MenuItem.js +26 -0
- package/dist/components/core/menu-item/MenuItem.types.d.ts +28 -0
- package/dist/components/core/menu-item/MenuItem.types.js +9 -0
- package/dist/components/core/navbar/Navbar.css +135 -0
- package/dist/components/core/navbar/Navbar.d.ts +36 -0
- package/dist/components/core/navbar/Navbar.js +371 -0
- package/dist/components/core/navbar/Navbar.types.d.ts +49 -0
- package/dist/components/core/navbar/Navbar.types.js +17 -0
- package/dist/components/core/navbar/navbar-impl.css +590 -0
- package/dist/components/core/navbar-item/NavbarItem.css +75 -0
- package/dist/components/core/navbar-item/NavbarItem.d.ts +22 -0
- package/dist/components/core/navbar-item/NavbarItem.js +40 -0
- package/dist/components/core/navbar-item/NavbarItem.types.d.ts +34 -0
- package/dist/components/core/navbar-item/NavbarItem.types.js +10 -0
- package/dist/components/core/navbar-menu/NavbarMenu.css +128 -0
- package/dist/components/core/navbar-menu/NavbarMenu.d.ts +5 -0
- package/dist/components/core/navbar-menu/NavbarMenu.js +186 -0
- package/dist/components/core/navbar-menu/NavbarMenu.types.d.ts +45 -0
- package/dist/components/core/navbar-menu/NavbarMenu.types.js +12 -0
- package/dist/components/core/navbar-menu/navbar-menu-impl.css +186 -0
- package/dist/components/core/navbar-menu-group/NavbarMenuGroup.css +26 -0
- package/dist/components/core/navbar-menu-group/NavbarMenuGroup.d.ts +17 -0
- package/dist/components/core/navbar-menu-group/NavbarMenuGroup.js +22 -0
- package/dist/components/core/navbar-menu-group/NavbarMenuGroup.types.d.ts +14 -0
- package/dist/components/core/navbar-menu-group/NavbarMenuGroup.types.js +7 -0
- package/dist/components/core/navbar-panel/NavbarPanel.css +87 -0
- package/dist/components/core/navbar-panel/NavbarPanel.d.ts +34 -0
- package/dist/components/core/navbar-panel/NavbarPanel.js +46 -0
- package/dist/components/core/navbar-panel/NavbarPanel.types.d.ts +29 -0
- package/dist/components/core/navbar-panel/NavbarPanel.types.js +12 -0
- package/dist/components/core/navbar-panel/navbar-panel-impl.css +104 -0
- package/dist/components/core/navbar-panel/use-navbar-panel.d.ts +26 -0
- package/dist/components/core/navbar-panel/use-navbar-panel.js +135 -0
- package/dist/components/core/navbar-switcher/NavbarSwitcher.css +117 -0
- package/dist/components/core/navbar-switcher/NavbarSwitcher.d.ts +20 -0
- package/dist/components/core/navbar-switcher/NavbarSwitcher.js +90 -0
- package/dist/components/core/navbar-switcher/NavbarSwitcher.types.d.ts +46 -0
- package/dist/components/core/navbar-switcher/NavbarSwitcher.types.js +13 -0
- package/dist/components/core/navbar-switcher/navbar-switcher-impl.css +179 -0
- package/dist/components/core/navbar-switcher-option/NavbarSwitcherOption.css +39 -0
- package/dist/components/core/navbar-switcher-option/NavbarSwitcherOption.d.ts +16 -0
- package/dist/components/core/navbar-switcher-option/NavbarSwitcherOption.js +19 -0
- package/dist/components/core/navbar-switcher-option/NavbarSwitcherOption.types.d.ts +18 -0
- package/dist/components/core/navbar-switcher-option/NavbarSwitcherOption.types.js +7 -0
- package/dist/components/core/option/Option.css +133 -0
- package/dist/components/core/option/Option.d.ts +25 -0
- package/dist/components/core/option/Option.js +31 -0
- package/dist/components/core/option/Option.types.d.ts +44 -0
- package/dist/components/core/option/Option.types.js +14 -0
- package/dist/components/core/pagination/Pagination.css +237 -0
- package/dist/components/core/pagination/Pagination.d.ts +30 -0
- package/dist/components/core/pagination/Pagination.js +406 -0
- package/dist/components/core/pagination/Pagination.types.d.ts +59 -0
- package/dist/components/core/pagination/Pagination.types.js +14 -0
- package/dist/components/core/pagination/pagination-impl.css +17 -0
- package/dist/components/core/removable-chip/RemovableChip.css +125 -0
- package/dist/components/core/removable-chip/RemovableChip.d.ts +25 -0
- package/dist/components/core/removable-chip/RemovableChip.js +36 -0
- package/dist/components/core/removable-chip/RemovableChip.types.d.ts +38 -0
- package/dist/components/core/removable-chip/RemovableChip.types.js +13 -0
- package/dist/components/core/search-input/SearchInput.css +205 -0
- package/dist/components/core/search-input/SearchInput.d.ts +5 -0
- package/dist/components/core/search-input/SearchInput.js +81 -0
- package/dist/components/core/search-input/SearchInput.types.d.ts +43 -0
- package/dist/components/core/search-input/SearchInput.types.js +13 -0
- package/dist/components/core/search-input/search-input-impl.css +20 -0
- package/dist/components/core/segmented-control/SegmentedControl.css +57 -0
- package/dist/components/core/segmented-control/SegmentedControl.d.ts +37 -0
- package/dist/components/core/segmented-control/SegmentedControl.js +269 -0
- package/dist/components/core/segmented-control/SegmentedControl.types.d.ts +38 -0
- package/dist/components/core/segmented-control/SegmentedControl.types.js +8 -0
- package/dist/components/core/segmented-control/segmented-control-impl.css +57 -0
- package/dist/components/core/segmented-control-item/SegmentedControlItem.css +151 -0
- package/dist/components/core/segmented-control-item/SegmentedControlItem.d.ts +50 -0
- package/dist/components/core/segmented-control-item/SegmentedControlItem.js +101 -0
- package/dist/components/core/segmented-control-item/SegmentedControlItem.types.d.ts +37 -0
- package/dist/components/core/segmented-control-item/SegmentedControlItem.types.js +10 -0
- package/dist/components/core/segmented-control-item/segmented-control-item-impl.css +69 -0
- package/dist/components/core/select/Select.css +400 -0
- package/dist/components/core/select/Select.d.ts +29 -0
- package/dist/components/core/select/Select.js +524 -0
- package/dist/components/core/select/Select.types.d.ts +96 -0
- package/dist/components/core/select/Select.types.js +26 -0
- package/dist/components/core/select/select-impl.css +114 -0
- package/dist/components/core/select-chip/SelectChip.css +155 -0
- package/dist/components/core/select-chip/SelectChip.d.ts +20 -0
- package/dist/components/core/select-chip/SelectChip.js +273 -0
- package/dist/components/core/select-chip/SelectChip.types.d.ts +56 -0
- package/dist/components/core/select-chip/SelectChip.types.js +14 -0
- package/dist/components/core/select-chip/select-chip-impl.css +38 -0
- package/dist/components/core/spinner/Spinner.css +76 -0
- package/dist/components/core/spinner/Spinner.d.ts +5 -0
- package/dist/components/core/spinner/Spinner.js +29 -0
- package/dist/components/core/spinner/Spinner.types.d.ts +37 -0
- package/dist/components/core/spinner/Spinner.types.js +10 -0
- package/dist/components/core/spinner/spinner-impl.css +27 -0
- package/dist/components/core/status-dot/StatusDot.css +43 -0
- package/dist/components/core/status-dot/StatusDot.d.ts +35 -0
- package/dist/components/core/status-dot/StatusDot.js +46 -0
- package/dist/components/core/status-dot/StatusDot.types.d.ts +29 -0
- package/dist/components/core/status-dot/StatusDot.types.js +7 -0
- package/dist/components/core/status-dot/status-dot-impl.css +42 -0
- package/dist/components/core/subdomain-navbar/SubdomainNavbar.css +89 -0
- package/dist/components/core/subdomain-navbar/SubdomainNavbar.d.ts +21 -0
- package/dist/components/core/subdomain-navbar/SubdomainNavbar.js +127 -0
- package/dist/components/core/subdomain-navbar/SubdomainNavbar.types.d.ts +43 -0
- package/dist/components/core/subdomain-navbar/SubdomainNavbar.types.js +13 -0
- package/dist/components/core/subdomain-navbar/subdomain-navbar-impl.css +147 -0
- package/dist/components/core/tab/Tab.css +113 -0
- package/dist/components/core/tab/Tab.d.ts +36 -0
- package/dist/components/core/tab/Tab.js +53 -0
- package/dist/components/core/tab/Tab.types.d.ts +42 -0
- package/dist/components/core/tab/Tab.types.js +13 -0
- package/dist/components/core/tab/tab-impl.css +49 -0
- package/dist/components/core/tab-list/TabList.css +40 -0
- package/dist/components/core/tab-list/TabList.d.ts +26 -0
- package/dist/components/core/tab-list/TabList.js +124 -0
- package/dist/components/core/tab-list/TabList.types.d.ts +20 -0
- package/dist/components/core/tab-list/TabList.types.js +7 -0
- package/dist/components/core/tab-list/tab-list-impl.css +56 -0
- package/dist/components/core/table/Table.css +40 -0
- package/dist/components/core/table/Table.d.ts +19 -0
- package/dist/components/core/table/Table.js +55 -0
- package/dist/components/core/table/Table.types.d.ts +59 -0
- package/dist/components/core/table/Table.types.js +9 -0
- package/dist/components/core/table/table-impl.css +75 -0
- package/dist/components/core/table/use-table-sort.d.ts +43 -0
- package/dist/components/core/table/use-table-sort.js +51 -0
- package/dist/components/core/table-body/TableBody.css +6 -0
- package/dist/components/core/table-body/TableBody.d.ts +12 -0
- package/dist/components/core/table-body/TableBody.js +26 -0
- package/dist/components/core/table-body/TableBody.types.d.ts +36 -0
- package/dist/components/core/table-body/TableBody.types.js +7 -0
- package/dist/components/core/table-cell/TableCell.css +76 -0
- package/dist/components/core/table-cell/TableCell.d.ts +21 -0
- package/dist/components/core/table-cell/TableCell.js +31 -0
- package/dist/components/core/table-cell/TableCell.types.d.ts +43 -0
- package/dist/components/core/table-cell/TableCell.types.js +7 -0
- package/dist/components/core/table-head/TableHead.css +6 -0
- package/dist/components/core/table-head/TableHead.d.ts +22 -0
- package/dist/components/core/table-head/TableHead.js +52 -0
- package/dist/components/core/table-head/TableHead.types.d.ts +39 -0
- package/dist/components/core/table-head/TableHead.types.js +7 -0
- package/dist/components/core/table-head/table-head-impl.css +51 -0
- package/dist/components/core/table-header-cell/TableHeaderCell.css +126 -0
- package/dist/components/core/table-header-cell/TableHeaderCell.d.ts +21 -0
- package/dist/components/core/table-header-cell/TableHeaderCell.js +34 -0
- package/dist/components/core/table-header-cell/TableHeaderCell.types.d.ts +56 -0
- package/dist/components/core/table-header-cell/TableHeaderCell.types.js +9 -0
- package/dist/components/core/table-header-cell/table-header-cell-impl.css +74 -0
- package/dist/components/core/table-row/TableRow.css +18 -0
- package/dist/components/core/table-row/TableRow.d.ts +17 -0
- package/dist/components/core/table-row/TableRow.js +32 -0
- package/dist/components/core/table-row/TableRow.types.d.ts +45 -0
- package/dist/components/core/table-row/TableRow.types.js +7 -0
- package/dist/components/core/table-row/table-row-impl.css +31 -0
- package/dist/components/core/text-area/TextArea.css +325 -0
- package/dist/components/core/text-area/TextArea.d.ts +13 -0
- package/dist/components/core/text-area/TextArea.js +133 -0
- package/dist/components/core/text-area/TextArea.types.d.ts +67 -0
- package/dist/components/core/text-area/TextArea.types.js +19 -0
- package/dist/components/core/text-area/text-area-impl.css +36 -0
- package/dist/components/core/text-input/TextInput.css +400 -0
- package/dist/components/core/text-input/TextInput.d.ts +5 -0
- package/dist/components/core/text-input/TextInput.js +130 -0
- package/dist/components/core/text-input/TextInput.types.d.ts +96 -0
- package/dist/components/core/text-input/TextInput.types.js +24 -0
- package/dist/components/core/text-input/text-input-impl.css +36 -0
- package/dist/components/core/tooltip/Tooltip.css +101 -0
- package/dist/components/core/tooltip/Tooltip.d.ts +51 -0
- package/dist/components/core/tooltip/Tooltip.js +87 -0
- package/dist/components/core/tooltip/Tooltip.types.d.ts +38 -0
- package/dist/components/core/tooltip/Tooltip.types.js +9 -0
- package/dist/components/core/tooltip/TooltipAnchor.d.ts +52 -0
- package/dist/components/core/tooltip/TooltipAnchor.js +69 -0
- package/dist/components/core/tooltip/tooltip-anchor.css +145 -0
- package/dist/components/core/tooltip/tooltip-impl.css +54 -0
- package/dist/components/core/tooltip/use-tooltip.d.ts +111 -0
- package/dist/components/core/tooltip/use-tooltip.js +189 -0
- package/dist/components/core/typography/Typography.css +96 -0
- package/dist/components/core/typography/Typography.d.ts +297 -0
- package/dist/components/core/typography/Typography.js +28 -0
- package/dist/components/core/typography/Typography.types.d.ts +40 -0
- package/dist/components/core/typography/Typography.types.js +7 -0
- package/dist/components/css-time.d.ts +20 -0
- package/dist/components/css-time.js +30 -0
- package/dist/components/given.d.ts +7 -0
- package/dist/components/given.js +9 -0
- package/dist/components/hover-open.d.ts +34 -0
- package/dist/components/hover-open.js +90 -0
- package/dist/components/index.d.ts +114 -1
- package/dist/components/index.js +115 -2
- package/dist/components/layout/aspect-ratio/AspectRatio.css +29 -0
- package/dist/components/layout/aspect-ratio/AspectRatio.d.ts +24 -0
- package/dist/components/layout/aspect-ratio/AspectRatio.js +26 -0
- package/dist/components/layout/aspect-ratio/AspectRatio.types.d.ts +22 -0
- package/dist/components/layout/aspect-ratio/AspectRatio.types.js +7 -0
- package/dist/components/layout/aspect-ratio/aspect-ratio-impl.css +44 -0
- package/dist/components/layout/grid/Grid.css +76 -0
- package/dist/components/layout/grid/Grid.d.ts +31 -0
- package/dist/components/layout/grid/Grid.js +33 -0
- package/dist/components/layout/grid/Grid.types.d.ts +48 -0
- package/dist/components/layout/grid/Grid.types.js +7 -0
- package/dist/components/layout/grid/grid-impl.css +62 -0
- package/dist/components/layout/row/Row.css +85 -0
- package/dist/components/layout/row/Row.d.ts +32 -0
- package/dist/components/layout/row/Row.js +34 -0
- package/dist/components/layout/row/Row.types.d.ts +45 -0
- package/dist/components/layout/row/Row.types.js +7 -0
- package/dist/components/layout/scroller/Scroller.css +59 -0
- package/dist/components/layout/scroller/Scroller.d.ts +34 -0
- package/dist/components/layout/scroller/Scroller.js +36 -0
- package/dist/components/layout/scroller/Scroller.types.d.ts +38 -0
- package/dist/components/layout/scroller/Scroller.types.js +7 -0
- package/dist/components/layout/scroller/scroller-impl.css +45 -0
- package/dist/components/layout/stack/Stack.css +73 -0
- package/dist/components/layout/stack/Stack.d.ts +28 -0
- package/dist/components/layout/stack/Stack.js +30 -0
- package/dist/components/layout/stack/Stack.types.d.ts +41 -0
- package/dist/components/layout/stack/Stack.types.js +7 -0
- package/dist/components/visually-hidden.d.ts +22 -0
- package/dist/components/visually-hidden.js +31 -0
- package/dist/fonts/LICENSE-inter.txt +93 -0
- package/dist/fonts/LICENSE-red-hat-mono.txt +93 -0
- package/dist/fonts/fonts.css +111 -0
- package/dist/fonts/inter-cyrillic-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-cyrillic-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-greek-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-greek-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-vietnamese-wght-normal.woff2 +0 -0
- package/dist/fonts/red-hat-mono-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/red-hat-mono-latin-wght-normal.woff2 +0 -0
- package/dist/marketing.css +289 -241
- package/package.json +18 -4
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* GENERATED from footergroup.contract.json. Do not edit. */
|
|
2
|
+
|
|
3
|
+
:where([data-dds-context="marketing"]) .dds-footergroup {
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
gap: var(--space-gap-lg);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__heading {
|
|
10
|
+
display: none;
|
|
11
|
+
color: var(--color-fg-muted-inverse);
|
|
12
|
+
font-family: var(--font-label-md-family);
|
|
13
|
+
font-size: var(--font-label-md-size);
|
|
14
|
+
font-weight: var(--font-label-md-weight);
|
|
15
|
+
letter-spacing: var(--font-label-md-letter-spacing);
|
|
16
|
+
line-height: var(--font-label-md-line-height);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__trigger {
|
|
20
|
+
transition-property: outline-color, outline-width;
|
|
21
|
+
align-items: center;
|
|
22
|
+
appearance: none;
|
|
23
|
+
background-color: transparent;
|
|
24
|
+
border-style: none;
|
|
25
|
+
color: inherit;
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
display: flex;
|
|
28
|
+
inline-size: 100%;
|
|
29
|
+
justify-content: space-between;
|
|
30
|
+
outline-style: solid;
|
|
31
|
+
padding: unset;
|
|
32
|
+
text-align: start;
|
|
33
|
+
border-radius: var(--radius-control-sm);
|
|
34
|
+
gap: var(--space-gap-sm);
|
|
35
|
+
min-block-size: var(--size-target-min);
|
|
36
|
+
min-inline-size: var(--size-target-min);
|
|
37
|
+
outline-width: var(--border-width-none);
|
|
38
|
+
padding-block: var(--space-gap-sm);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__list {
|
|
42
|
+
display: flex;
|
|
43
|
+
flex-direction: column;
|
|
44
|
+
list-style: none;
|
|
45
|
+
margin: 0;
|
|
46
|
+
padding: 0;
|
|
47
|
+
gap: var(--space-gap-md);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded="false"] .dds-footergroup__list {
|
|
51
|
+
display: none;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded="true"] .dds-footergroup__list {
|
|
55
|
+
display: flex;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__label {
|
|
59
|
+
font-family: var(--font-label-md-family);
|
|
60
|
+
font-size: var(--font-label-md-size);
|
|
61
|
+
font-weight: var(--font-label-md-weight);
|
|
62
|
+
letter-spacing: var(--font-label-md-letter-spacing);
|
|
63
|
+
line-height: var(--font-label-md-line-height);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__marker {
|
|
67
|
+
block-size: var(--icon-size-xs);
|
|
68
|
+
inline-size: var(--icon-size-xs);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
:where([data-dds-context="marketing"]) .dds-footergroup .dds-footergroup__trigger:focus-visible {
|
|
72
|
+
outline-color: var(--color-border-focus-inverse);
|
|
73
|
+
outline-width: var(--border-width-focus);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded="false"] .dds-footergroup__marker {
|
|
77
|
+
transition-duration: var(--motion-duration-normal);
|
|
78
|
+
transition-timing-function: var(--motion-easing-exit);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded="true"] .dds-footergroup__marker {
|
|
82
|
+
transition-duration: var(--motion-duration-slow);
|
|
83
|
+
transition-timing-function: var(--motion-easing-enter);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
@media (prefers-reduced-motion: reduce) {
|
|
87
|
+
:where([data-dds-context="marketing"]) .dds-footergroup,
|
|
88
|
+
:where([data-dds-context="marketing"]) .dds-footergroup * { transition: none; }
|
|
89
|
+
}
|
|
90
|
+
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import './FooterGroup.css';
|
|
2
|
+
import './footer-group-impl.css';
|
|
3
|
+
import { type FooterGroupProps } from './FooterGroup.types.js';
|
|
4
|
+
export type { FooterGroupProps };
|
|
5
|
+
/**
|
|
6
|
+
* A named handful of destinations in the footer.
|
|
7
|
+
*
|
|
8
|
+
* The word appears twice in the markup and once on the screen. Above the footer's own width the
|
|
9
|
+
* trigger is not drawn and a plain `heading` carries the label; below it the trigger carries the
|
|
10
|
+
* label and the heading is not drawn. Both are always mounted and the stylesheet picks one, which
|
|
11
|
+
* is what lets the element change without React remounting anything — and `display: none` takes the
|
|
12
|
+
* unused one out of the accessibility tree, so a screen reader is never given the word twice.
|
|
13
|
+
*
|
|
14
|
+
* The first build put the label inside the trigger alone, and hiding the trigger on a desktop took
|
|
15
|
+
* the word with it: six sets of links with no names over them.
|
|
16
|
+
*
|
|
17
|
+
* The trigger is a `<button>` at every width it is drawn at, and above the footer's own width it is
|
|
18
|
+
* not drawn at all. That is the arrangement Navbar already uses for the control it keeps only while collapsed,
|
|
19
|
+
* and it is the one that avoids every alternative's problem: the element never changes, so React
|
|
20
|
+
* never remounts it; the list is simply open on a wide page; and there is no control left to
|
|
21
|
+
* announce, so `aria-expanded` cannot end up disagreeing with what a reader is looking at.
|
|
22
|
+
*
|
|
23
|
+
* A button that stayed and did nothing would be worse than it sounds. It would be a tab stop
|
|
24
|
+
* before every set of links, announced as collapsible, toggling a state the stylesheet overrules —
|
|
25
|
+
* which is a promise broken for exactly the readers who cannot see that the list was already open.
|
|
26
|
+
*
|
|
27
|
+
* The state is still held here at every width, because the width is not this component's to know:
|
|
28
|
+
* a container query decides it, and a container query cannot be read from JavaScript. Nothing goes
|
|
29
|
+
* wrong when a wide page holds `expanded: false` — there is no trigger to press and no rule
|
|
30
|
+
* reading the value.
|
|
31
|
+
*/
|
|
32
|
+
export declare function FooterGroup({ expanded: controlled, label, onExpandedChange, children, ...rest }: FooterGroupProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { Children, cloneElement, isValidElement, useId, useState } from 'react';
|
|
4
|
+
import { ChevronDownRegularIcon } from '@deriv-com/quill-icons-web';
|
|
5
|
+
import './FooterGroup.css';
|
|
6
|
+
import './footer-group-impl.css';
|
|
7
|
+
import { Link } from '../link/Link.js';
|
|
8
|
+
import { footerGroupDefaults, footerGroupParts } from './FooterGroup.types.js';
|
|
9
|
+
/**
|
|
10
|
+
* A named handful of destinations in the footer.
|
|
11
|
+
*
|
|
12
|
+
* The word appears twice in the markup and once on the screen. Above the footer's own width the
|
|
13
|
+
* trigger is not drawn and a plain `heading` carries the label; below it the trigger carries the
|
|
14
|
+
* label and the heading is not drawn. Both are always mounted and the stylesheet picks one, which
|
|
15
|
+
* is what lets the element change without React remounting anything — and `display: none` takes the
|
|
16
|
+
* unused one out of the accessibility tree, so a screen reader is never given the word twice.
|
|
17
|
+
*
|
|
18
|
+
* The first build put the label inside the trigger alone, and hiding the trigger on a desktop took
|
|
19
|
+
* the word with it: six sets of links with no names over them.
|
|
20
|
+
*
|
|
21
|
+
* The trigger is a `<button>` at every width it is drawn at, and above the footer's own width it is
|
|
22
|
+
* not drawn at all. That is the arrangement Navbar already uses for the control it keeps only while collapsed,
|
|
23
|
+
* and it is the one that avoids every alternative's problem: the element never changes, so React
|
|
24
|
+
* never remounts it; the list is simply open on a wide page; and there is no control left to
|
|
25
|
+
* announce, so `aria-expanded` cannot end up disagreeing with what a reader is looking at.
|
|
26
|
+
*
|
|
27
|
+
* A button that stayed and did nothing would be worse than it sounds. It would be a tab stop
|
|
28
|
+
* before every set of links, announced as collapsible, toggling a state the stylesheet overrules —
|
|
29
|
+
* which is a promise broken for exactly the readers who cannot see that the list was already open.
|
|
30
|
+
*
|
|
31
|
+
* The state is still held here at every width, because the width is not this component's to know:
|
|
32
|
+
* a container query decides it, and a container query cannot be read from JavaScript. Nothing goes
|
|
33
|
+
* wrong when a wide page holds `expanded: false` — there is no trigger to press and no rule
|
|
34
|
+
* reading the value.
|
|
35
|
+
*/
|
|
36
|
+
export function FooterGroup({ expanded: controlled, label, onExpandedChange, children, ...rest }) {
|
|
37
|
+
const base = useId();
|
|
38
|
+
const listId = `${base}-list`;
|
|
39
|
+
const headingId = `${base}-heading`;
|
|
40
|
+
/**
|
|
41
|
+
* Held here unless the page holds it.
|
|
42
|
+
*
|
|
43
|
+
* A footer of eleven groups has no reason to tell its page which ones a reader opened, so the
|
|
44
|
+
* uncontrolled form is the one nearly every site wants. Controlled when the prop is supplied at all, which
|
|
45
|
+
* here means not `undefined` — `false` is a page driving this shut, and reading that as "not
|
|
46
|
+
* supplied" would make a controlled group uncontrollable the moment somebody closed it.
|
|
47
|
+
*/
|
|
48
|
+
const driven = controlled !== undefined;
|
|
49
|
+
const [held, setHeld] = useState(footerGroupDefaults.expanded);
|
|
50
|
+
const open = driven ? controlled : held;
|
|
51
|
+
const toggle = () => {
|
|
52
|
+
if (!driven)
|
|
53
|
+
setHeld(!open);
|
|
54
|
+
onExpandedChange?.(!open);
|
|
55
|
+
};
|
|
56
|
+
return (_jsxs("div", { className: footerGroupParts.root, "data-expanded": String(open), ...rest, children: [_jsx("div", { className: footerGroupParts.heading, id: headingId, children: label }), _jsxs("button", { type: "button", className: footerGroupParts.trigger, "aria-expanded": open, "aria-controls": listId, onClick: toggle, children: [_jsx("span", { className: footerGroupParts.label, children: label }), _jsx(ChevronDownRegularIcon, { className: footerGroupParts.marker, "aria-hidden": "true", style: open ? { rotate: '180deg' } : undefined })] }), _jsx("ul", { className: footerGroupParts.list, id: listId, "aria-labelledby": headingId, children: Children.toArray(children).map((child) => {
|
|
57
|
+
const link = isValidElement(child) && child.type === Link;
|
|
58
|
+
return (_jsx("li", { children: link
|
|
59
|
+
? cloneElement(child, {
|
|
60
|
+
variant: child.props.variant ?? 'list',
|
|
61
|
+
})
|
|
62
|
+
: child }, child.key));
|
|
63
|
+
}) })] }));
|
|
64
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
export interface FooterGroupOwnProps {
|
|
3
|
+
/** Whether the set is open, on a page narrow enough for it to close. Left alone the group holds this itself, which is what a footer of eleven groups wants — the page has no reason to know which ones a reader has opened */
|
|
4
|
+
expanded?: boolean;
|
|
5
|
+
/** Always — it is the word the set is under, and the control that opens it on a narrow page. One or two words naming a kind: 'Markets', 'Partner with us' */
|
|
6
|
+
label: string;
|
|
7
|
+
/** Told when a set opens or shuts, for a page that drives them from outside — one open at a time, or a set opened by a link somebody followed */
|
|
8
|
+
onExpandedChange?: (expanded: boolean) => void;
|
|
9
|
+
/** Allowed: Link */
|
|
10
|
+
children: ReactNode;
|
|
11
|
+
}
|
|
12
|
+
export type FooterGroupProps = FooterGroupOwnProps & Omit<HTMLAttributes<HTMLDivElement>, 'className' | 'expanded' | 'label' | 'onExpandedChange'>;
|
|
13
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
14
|
+
export declare const footerGroupParts: {
|
|
15
|
+
readonly root: "dds-footergroup";
|
|
16
|
+
readonly heading: "dds-footergroup__heading";
|
|
17
|
+
readonly trigger: "dds-footergroup__trigger";
|
|
18
|
+
readonly label: "dds-footergroup__label";
|
|
19
|
+
readonly marker: "dds-footergroup__marker";
|
|
20
|
+
readonly list: "dds-footergroup__list";
|
|
21
|
+
};
|
|
22
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
23
|
+
export declare const footerGroupDefaults: {
|
|
24
|
+
readonly expanded: false;
|
|
25
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// GENERATED from footer-group.contract.json. Do not edit.
|
|
2
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
3
|
+
export const footerGroupParts = {
|
|
4
|
+
root: 'dds-footergroup',
|
|
5
|
+
heading: 'dds-footergroup__heading',
|
|
6
|
+
trigger: 'dds-footergroup__trigger',
|
|
7
|
+
label: 'dds-footergroup__label',
|
|
8
|
+
marker: 'dds-footergroup__marker',
|
|
9
|
+
list: 'dds-footergroup__list',
|
|
10
|
+
};
|
|
11
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
12
|
+
export const footerGroupDefaults = { expanded: false };
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Scoped to this package, like the generated sheet beside it.
|
|
3
|
+
*
|
|
4
|
+
* `:where([data-dds-context="marketing"])` confines these rules without contributing specificity,
|
|
5
|
+
* so each still ties or beats exactly what it did before.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
@container (min-width: 48rem) {
|
|
9
|
+
/*
|
|
10
|
+
* Wide enough, and there is nothing to open.
|
|
11
|
+
*
|
|
12
|
+
* The footer's band is the container, not the window — a footer in a narrow region of a wide page
|
|
13
|
+
* is a narrow footer, and asking the viewport would collapse the wrong one.
|
|
14
|
+
*
|
|
15
|
+
* `48rem` and not the `64rem` the navbar bends at, because the two are answering different
|
|
16
|
+
* questions. A bar needs room for a row of destinations across the whole width; a column of
|
|
17
|
+
* links needs far less, and four tracks of `min="sm"` with their gutters come to a little over
|
|
18
|
+
* seven hundred pixels. Forty-eight rem is `size.breakpoint.md` — the width at which this
|
|
19
|
+
* package's own token layer stops calling the page a phone — so the footer folds where
|
|
20
|
+
* everything else in the package folds.
|
|
21
|
+
*
|
|
22
|
+
* Written longhand because `var()` is not allowed in a container query condition; that role is
|
|
23
|
+
* the value to read, never the condition to write, and Navbar's sheet writes its number out for
|
|
24
|
+
* the same reason.
|
|
25
|
+
*
|
|
26
|
+
* The trigger goes rather than being disabled or hidden from the pointer alone. A control that
|
|
27
|
+
* stayed would be a tab stop before every set of links, announced as collapsible, toggling a
|
|
28
|
+
* state this rule overrules — so it leaves the accessibility tree with `display: none`, and the
|
|
29
|
+
* label it carried is not lost, because the label is what the list is titled by either way.
|
|
30
|
+
*/
|
|
31
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded] .dds-footergroup__trigger {
|
|
32
|
+
display: none;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/*
|
|
36
|
+
* And the word it was carrying is drawn by the heading instead.
|
|
37
|
+
*
|
|
38
|
+
* Two classes and an attribute against the generated rule's two classes, so it wins on weight
|
|
39
|
+
* rather than on which stylesheet the bundler wrote last. `data-expanded` is on the root at
|
|
40
|
+
* every width, so the attribute selects without narrowing anything — it is there to outrank the
|
|
41
|
+
* `display: none` the part carries by default, not to ask a question.
|
|
42
|
+
*/
|
|
43
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded] .dds-footergroup__heading {
|
|
44
|
+
display: block;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/*
|
|
48
|
+
* And the list is open whatever the group thinks.
|
|
49
|
+
*
|
|
50
|
+
* It outranks the generated `[data-expanded="false"]` rule on weight rather than on order: that
|
|
51
|
+
* selector is two classes and an attribute, this is two classes inside a container query, so the
|
|
52
|
+
* `display: none` it overrules is the one the collapsed state sets. Written as `flex` and not
|
|
53
|
+
* `revert`, because the part's own layout is a column of rows and reverting would hand it back
|
|
54
|
+
* to the browser's `<ul>`.
|
|
55
|
+
*/
|
|
56
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded='false'] .dds-footergroup__list {
|
|
57
|
+
display: flex;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
@container (max-width: 47.9375rem) {
|
|
62
|
+
/*
|
|
63
|
+
* Below the fold the set is a disclosure, and a disclosure closes up.
|
|
64
|
+
*
|
|
65
|
+
* The root's `space.gap.lg` is the step between a heading and the list it names on a desktop,
|
|
66
|
+
* where the label is a signpost standing over an open column and wants the air. Here the label is
|
|
67
|
+
* the row a reader just pressed and the list is what appeared underneath it: twenty-four between
|
|
68
|
+
* them, on top of the trigger's own padding, put the first destination thirty-two pixels from the
|
|
69
|
+
* word that revealed it, which reads as two things rather than one opening.
|
|
70
|
+
*
|
|
71
|
+
* The same width the band folds at, written as its complement so there is no gap between the two
|
|
72
|
+
* — `47.9375rem` is one sixteenth below `48rem`, which is the smallest step that cannot leave a
|
|
73
|
+
* width answering to neither.
|
|
74
|
+
*/
|
|
75
|
+
:where([data-dds-context="marketing"]) .dds-footergroup[data-expanded] {
|
|
76
|
+
gap: var(--space-gap-sm);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/* GENERATED from icon.contract.json. Do not edit. */
|
|
2
|
+
|
|
3
|
+
:where([data-dds-context="marketing"]) .dds-icon {
|
|
4
|
+
display: inline-block;
|
|
5
|
+
flex: none;
|
|
6
|
+
transition-property: rotate;
|
|
7
|
+
vertical-align: middle;
|
|
8
|
+
transition-duration: var(--motion-duration-fast);
|
|
9
|
+
transition-timing-function: var(--motion-easing-standard);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
:where([data-dds-context="marketing"]) .dds-icon[data-size="lg"] {
|
|
13
|
+
height: var(--icon-size-lg);
|
|
14
|
+
width: var(--icon-size-lg);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
:where([data-dds-context="marketing"]) .dds-icon[data-size="md"] {
|
|
18
|
+
height: var(--icon-size-md);
|
|
19
|
+
width: var(--icon-size-md);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
:where([data-dds-context="marketing"]) .dds-icon[data-size="sm"] {
|
|
23
|
+
height: var(--icon-size-sm);
|
|
24
|
+
width: var(--icon-size-sm);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
:where([data-dds-context="marketing"]) .dds-icon[data-size="xl"] {
|
|
28
|
+
height: var(--icon-size-xl);
|
|
29
|
+
width: var(--icon-size-xl);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
:where([data-dds-context="marketing"]) .dds-icon[data-size="xs"] {
|
|
33
|
+
height: var(--icon-size-xs);
|
|
34
|
+
width: var(--icon-size-xs);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@media (prefers-reduced-motion: reduce) {
|
|
38
|
+
:where([data-dds-context="marketing"]) .dds-icon { transition: none; }
|
|
39
|
+
}
|
|
40
|
+
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import './Icon.css';
|
|
2
|
+
import { type IconProps } from './Icon.types.js';
|
|
3
|
+
export type { IconProps };
|
|
4
|
+
/**
|
|
5
|
+
* Icon clones the glyph it is given rather than wrapping it.
|
|
6
|
+
*
|
|
7
|
+
* A wrapper would leave the size on the wrong element: every Quill glyph ships
|
|
8
|
+
* `width` and `height` attributes defaulting to 24, and sizing a parent does
|
|
9
|
+
* nothing to them. Cloning puts the part's class on the `<svg>` itself, where a
|
|
10
|
+
* CSS width beats a presentation attribute and `icon.size.*` decides the measure.
|
|
11
|
+
*
|
|
12
|
+
* This is not a hypothetical here. Marketing had three components drawing glyphs
|
|
13
|
+
* by hand before this existed — Breadcrumb's separator, AccordionItem's chevron
|
|
14
|
+
* and CardBody's mark — and the third had to answer the same problem with an
|
|
15
|
+
* impl sheet reaching into a child, because it wraps rather than clones and a box
|
|
16
|
+
* with a measure has no effect on the SVG inside it.
|
|
17
|
+
*
|
|
18
|
+
* Nothing here sets a colour. The glyph paints with `fill="currentColor"`, so it
|
|
19
|
+
* inherits whatever the surrounding text uses — which is what makes an Icon on a
|
|
20
|
+
* brand card pick up `color.fg.on-solid` without being told, the same way
|
|
21
|
+
* CardBody's regions do.
|
|
22
|
+
*/
|
|
23
|
+
export declare function Icon({ size, label, children }: IconProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { cloneElement, isValidElement } from 'react';
|
|
3
|
+
import { given } from '../../given.js';
|
|
4
|
+
import './Icon.css';
|
|
5
|
+
import { iconDefaults, iconParts } from './Icon.types.js';
|
|
6
|
+
/**
|
|
7
|
+
* Icon clones the glyph it is given rather than wrapping it.
|
|
8
|
+
*
|
|
9
|
+
* A wrapper would leave the size on the wrong element: every Quill glyph ships
|
|
10
|
+
* `width` and `height` attributes defaulting to 24, and sizing a parent does
|
|
11
|
+
* nothing to them. Cloning puts the part's class on the `<svg>` itself, where a
|
|
12
|
+
* CSS width beats a presentation attribute and `icon.size.*` decides the measure.
|
|
13
|
+
*
|
|
14
|
+
* This is not a hypothetical here. Marketing had three components drawing glyphs
|
|
15
|
+
* by hand before this existed — Breadcrumb's separator, AccordionItem's chevron
|
|
16
|
+
* and CardBody's mark — and the third had to answer the same problem with an
|
|
17
|
+
* impl sheet reaching into a child, because it wraps rather than clones and a box
|
|
18
|
+
* with a measure has no effect on the SVG inside it.
|
|
19
|
+
*
|
|
20
|
+
* Nothing here sets a colour. The glyph paints with `fill="currentColor"`, so it
|
|
21
|
+
* inherits whatever the surrounding text uses — which is what makes an Icon on a
|
|
22
|
+
* brand card pick up `color.fg.on-solid` without being told, the same way
|
|
23
|
+
* CardBody's regions do.
|
|
24
|
+
*/
|
|
25
|
+
export function Icon({ size = iconDefaults.size, label, children }) {
|
|
26
|
+
/**
|
|
27
|
+
* An Icon handed an Icon is unwrapped, and this one's size is the one that survives.
|
|
28
|
+
*
|
|
29
|
+
* A glyph slot takes the glyph and its component draws it, so the step is the
|
|
30
|
+
* component's and a page has no way to set another — except by passing an Icon it
|
|
31
|
+
* sized itself. Left alone the outcome is the worst available: React clones the inner
|
|
32
|
+
* `Icon` element and hands it `className` and `data-size`, which `Icon` does not read,
|
|
33
|
+
* so the props are dropped in silence and the glyph draws at the page's measure inside
|
|
34
|
+
* a component that had decided otherwise. Nothing reports it.
|
|
35
|
+
*
|
|
36
|
+
* So the outer one absorbs the inner and keeps going with what was inside it. Nesting
|
|
37
|
+
* has no other reading — Icon clones a glyph, and an Icon is not one.
|
|
38
|
+
*
|
|
39
|
+
* A loop rather than a single unwrap, because two is no more meaningful than one and a
|
|
40
|
+
* component that handled one level would fail on the level after it.
|
|
41
|
+
*
|
|
42
|
+
* The name is carried out, and that is the one thing here not merely about size: these
|
|
43
|
+
* slots are decorative and pass no label, but Icon is shared, and an accessible name
|
|
44
|
+
* dropped on the way through would be a convenience paid for with real harm. An outer
|
|
45
|
+
* label still wins — it is the nearer decision.
|
|
46
|
+
*/
|
|
47
|
+
let glyph = children;
|
|
48
|
+
let named = label;
|
|
49
|
+
while (isValidElement(glyph) && glyph.type === Icon) {
|
|
50
|
+
named = named ?? glyph.props.label;
|
|
51
|
+
glyph = glyph.props.children;
|
|
52
|
+
}
|
|
53
|
+
/*
|
|
54
|
+
* Decorative unless it is named. An icon-only control passes `label`; a glyph beside
|
|
55
|
+
* words that already say the same thing must not, or it is announced twice.
|
|
56
|
+
*
|
|
57
|
+
* Read through `given`, which is where this parts company with Product's. There the
|
|
58
|
+
* name is passed straight through, so `label=""` leaves `aria-label=""` on an element
|
|
59
|
+
* already marked presentational — a name of no characters rather than no name, which
|
|
60
|
+
* is a thing an audit flags and nothing wants. A label of spaces is the same case: it
|
|
61
|
+
* is not a name, and the switch here is presence rather than truthiness.
|
|
62
|
+
*/
|
|
63
|
+
const names = given(named);
|
|
64
|
+
const applied = {
|
|
65
|
+
'data-size': size,
|
|
66
|
+
role: names ? 'img' : 'presentation',
|
|
67
|
+
'aria-label': names ? named : undefined,
|
|
68
|
+
};
|
|
69
|
+
// Anything that is not a single element cannot be cloned. Wrapping it keeps the
|
|
70
|
+
// size and the colour on something rather than throwing: the preview hands every
|
|
71
|
+
// component the string "Sample content" and cannot know this one wants an element.
|
|
72
|
+
if (!isValidElement(glyph)) {
|
|
73
|
+
return (_jsx("span", { className: iconParts.root, ...applied, children: glyph }));
|
|
74
|
+
}
|
|
75
|
+
return cloneElement(glyph, {
|
|
76
|
+
className: [iconParts.root, glyph.props.className].filter(Boolean).join(' '),
|
|
77
|
+
...applied,
|
|
78
|
+
});
|
|
79
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
export interface IconOwnProps {
|
|
3
|
+
/**
|
|
4
|
+
* `xs` — Inline and supporting content — a separator in a trail, a mark against small text
|
|
5
|
+
* `sm` — A mark beside text that must not outweigh it: the chevron on a list row, an affordance next to a label
|
|
6
|
+
* `md` — The default. Body content and lists, where the glyph sits with the words rather than above them
|
|
7
|
+
* `lg` — Cards and content sections — the mark a feature card leads with, read before its title is
|
|
8
|
+
* `xl` — The largest step, for a callout or a highlighted block where the glyph does as much work as the copy
|
|
9
|
+
*/
|
|
10
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
11
|
+
/** The glyph is the only thing naming its control — an icon-only button, a mark with no words beside it */
|
|
12
|
+
label?: string;
|
|
13
|
+
/** Allowed: QuillSystemIcon */
|
|
14
|
+
children: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
export type IconProps = IconOwnProps;
|
|
17
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
18
|
+
export declare const iconParts: {
|
|
19
|
+
readonly root: "dds-icon";
|
|
20
|
+
};
|
|
21
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
22
|
+
export declare const iconDefaults: {
|
|
23
|
+
readonly size: "md";
|
|
24
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
// GENERATED from icon.contract.json. Do not edit.
|
|
2
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
3
|
+
export const iconParts = {
|
|
4
|
+
root: 'dds-icon',
|
|
5
|
+
};
|
|
6
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
7
|
+
export const iconDefaults = { size: 'md' };
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/* GENERATED from link.contract.json. Do not edit. */
|
|
2
|
+
|
|
3
|
+
:where([data-dds-context="marketing"]) .dds-link {
|
|
4
|
+
transition-property: color, outline-color, outline-width, text-decoration-thickness;
|
|
5
|
+
align-items: center;
|
|
6
|
+
appearance: none;
|
|
7
|
+
background-color: transparent;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
cursor: pointer;
|
|
10
|
+
display: inline;
|
|
11
|
+
font-family: inherit;
|
|
12
|
+
font-size: inherit;
|
|
13
|
+
line-height: inherit;
|
|
14
|
+
outline-style: solid;
|
|
15
|
+
border-radius: var(--radius-subtle);
|
|
16
|
+
outline-width: var(--border-width-none);
|
|
17
|
+
text-decoration-thickness: var(--border-width-default);
|
|
18
|
+
transition-duration: var(--motion-duration-fast);
|
|
19
|
+
transition-timing-function: var(--motion-easing-standard);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
:where([data-dds-context="marketing"]) .dds-link .dds-link__icon-leading {
|
|
23
|
+
align-items: center;
|
|
24
|
+
display: inline-flex;
|
|
25
|
+
vertical-align: middle;
|
|
26
|
+
padding-inline-end: var(--space-gap-xs);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
:where([data-dds-context="marketing"]) .dds-link .dds-link__icon-trailing {
|
|
30
|
+
align-items: center;
|
|
31
|
+
display: inline-flex;
|
|
32
|
+
vertical-align: middle;
|
|
33
|
+
padding-inline-start: var(--space-gap-xs);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="inline"] {
|
|
37
|
+
color: inherit;
|
|
38
|
+
text-decoration-line: underline;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="list"] {
|
|
42
|
+
color: inherit;
|
|
43
|
+
display: inline-flex;
|
|
44
|
+
text-decoration-line: none;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="standalone"] {
|
|
48
|
+
display: inline-flex;
|
|
49
|
+
text-decoration-line: none;
|
|
50
|
+
font-family: var(--font-label-md-family);
|
|
51
|
+
font-size: var(--font-label-md-size);
|
|
52
|
+
font-weight: var(--font-label-md-weight);
|
|
53
|
+
line-height: var(--font-label-md-line-height);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="standalone"][data-tone="inherit"] {
|
|
57
|
+
color: inherit;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
:where([data-dds-context="marketing"]) .dds-link:hover {
|
|
61
|
+
text-decoration-thickness: var(--border-width-emphasis);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
:where([data-dds-context="marketing"]) .dds-link:active {
|
|
65
|
+
text-decoration-thickness: var(--border-width-emphasis);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
:where([data-dds-context="marketing"]) .dds-link:focus-visible {
|
|
69
|
+
outline-color: var(--color-border-focus);
|
|
70
|
+
outline-width: var(--border-width-focus);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="standalone"][data-tone="brand"] {
|
|
74
|
+
color: var(--color-bg-brand);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="standalone"][data-tone="brand"]:hover {
|
|
78
|
+
color: var(--color-bg-brand-hover);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
:where([data-dds-context="marketing"]) .dds-link[data-variant="standalone"][data-tone="brand"]:active {
|
|
82
|
+
color: var(--color-bg-brand-active);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
@media (prefers-reduced-motion: reduce) {
|
|
86
|
+
:where([data-dds-context="marketing"]) .dds-link,
|
|
87
|
+
:where([data-dds-context="marketing"]) .dds-link * { transition: none; }
|
|
88
|
+
}
|
|
89
|
+
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import './Link.css';
|
|
2
|
+
import './link-impl.css';
|
|
3
|
+
import { type LinkProps } from './Link.types.js';
|
|
4
|
+
export type { LinkProps };
|
|
5
|
+
/**
|
|
6
|
+
* Words in a sentence that go somewhere.
|
|
7
|
+
*
|
|
8
|
+
* An anchor with a real href, which is the whole component: cmd-click opens a
|
|
9
|
+
* tab, the status bar shows the destination before the press, the address can be
|
|
10
|
+
* copied, and a screen reader announces a link. `href` is required in the
|
|
11
|
+
* generated type for that reason — an anchor without one takes no focus and is
|
|
12
|
+
* announced as plain text, so the destination disappears for anyone not using a
|
|
13
|
+
* mouse.
|
|
14
|
+
*
|
|
15
|
+
* `display: inline`, unlike everything else pressable in this package. A link is
|
|
16
|
+
* part of a line and has to wrap with it; Button is `inline-flex` because it is
|
|
17
|
+
* a box the copy flows around, and a link behaving that way would leave a hole
|
|
18
|
+
* at the end of a line rather than breaking across two.
|
|
19
|
+
*
|
|
20
|
+
* The type is inherited rather than set, in the inline variant. A link in a body
|
|
21
|
+
* paragraph is body copy and a link in a caption is caption, which is the whole
|
|
22
|
+
* idea — only `standalone` binds a step, because a link on its own line has no
|
|
23
|
+
* sentence to take one from.
|
|
24
|
+
*
|
|
25
|
+
* `external` carries three things that belong together: the target, the rel, and
|
|
26
|
+
* the mark. The rel is not optional and not the consumer's job — leaving it to
|
|
27
|
+
* the call site is how a page hands `window.opener` to a site it does not
|
|
28
|
+
* control — and putting the glyph here is what makes every external link on the
|
|
29
|
+
* site carry the same one.
|
|
30
|
+
*
|
|
31
|
+
* There is no `loading` and no `disabled`, which is where this parts company
|
|
32
|
+
* with Product's Link and follows Marketing's Button instead. The browser owns a
|
|
33
|
+
* navigation in flight and shows it in the chrome; and an anchor cannot be
|
|
34
|
+
* honestly disabled, since dropping the href is the only thing that truly stops
|
|
35
|
+
* it and that costs the link role and the focus with it.
|
|
36
|
+
*/
|
|
37
|
+
export declare function Link({ variant, tone, href, external, showIcon, iconLeading, children, ...rest }: LinkProps): import("react").JSX.Element;
|