@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,56 @@
|
|
|
1
|
+
import type { ReactNode, ThHTMLAttributes } from 'react';
|
|
2
|
+
export interface TableHeaderCellOwnProps {
|
|
3
|
+
/**
|
|
4
|
+
* `sm` — Compact. Dense data a reader scans rather than reads — a ledger, a positions table, anything where fitting more rows on screen is worth more than air around each one
|
|
5
|
+
* `md` — Balanced, and the default: rows a reader moves through at reading pace, with enough room that the eye does not slip between them
|
|
6
|
+
* `lg` — Spacious. Few rows, each carrying something substantial — a plan comparison, a summary of three accounts. Reach for it when the table is the page rather than a part of it
|
|
7
|
+
*/
|
|
8
|
+
size?: 'sm' | 'md' | 'lg';
|
|
9
|
+
/**
|
|
10
|
+
* `start` — Words. Names, descriptions, statuses — anything read left to right starts where the reading does, and a column of them shares one edge the eye can run down
|
|
11
|
+
* `center` — Rare, and worth arguing for: a single glyph or a very short state where neither edge means anything. A centred column of words has two ragged edges instead of one
|
|
12
|
+
* `end` — Numbers that line up under each other — amounts, counts, percentages. The decimal point is what a reader compares down a column, and ranging to the end is what puts it in one place
|
|
13
|
+
*/
|
|
14
|
+
align?: 'start' | 'center' | 'end';
|
|
15
|
+
/**
|
|
16
|
+
* `none` — The column can be sorted and the table is not currently ordered by it. The mark is drawn quietly, which is what tells a reader the column is available rather than active
|
|
17
|
+
* `ascending` — The table is ordered by this column, smallest first — A to Z, earliest date, lowest amount
|
|
18
|
+
* `descending` — The table is ordered by this column, largest first. The commoner opening state for money and dates, where the newest or the biggest is what a reader came for
|
|
19
|
+
*/
|
|
20
|
+
sortDirection?: 'none' | 'ascending' | 'descending';
|
|
21
|
+
/**
|
|
22
|
+
* `rows` — The default. A line between rows and none between columns, which is what stops the eye slipping from one row's start to another's end — the mistake a wide table invites and the one a reader never notices making
|
|
23
|
+
* `grid` — Lines both ways, for a table read as a matrix rather than as a list of records: a rate card, a comparison where the reader traces a column as often as a row. It is more lines than most tables need, so it should be asked for
|
|
24
|
+
* `none` — No lines at all. Right for two or three rows, where the rules are more structure than data, and for a table whose columns are already separated by their alignment
|
|
25
|
+
*/
|
|
26
|
+
dividers?: 'rows' | 'grid' | 'none';
|
|
27
|
+
/**
|
|
28
|
+
* `upper` — The house setting. Column names in capitals at font.overline — eleven pixels with wide tracking — which reads as a different texture from the values rather than a louder version of them. A header is read once where the data under it is read many times, and capitals are what stop it competing
|
|
29
|
+
* `title` — Names drawn as they were written, at font.label.sm — twelve pixels, medium, ordinary tracking. Right where the names are long, are proper nouns whose own capitals capitals would flatten, or are in a script that has no case at all, and right wherever a product has decided its tables read as sentences rather than as labels
|
|
30
|
+
*/
|
|
31
|
+
headerCase?: 'upper' | 'title';
|
|
32
|
+
/** Allowed: any content */
|
|
33
|
+
children: ReactNode;
|
|
34
|
+
}
|
|
35
|
+
export type TableHeaderCellProps = TableHeaderCellOwnProps & Omit<ThHTMLAttributes<HTMLTableCellElement>, 'className' | 'size' | 'align' | 'sortDirection' | 'dividers' | 'headerCase' | 'sortable' | 'onSort'> & ({
|
|
36
|
+
sortable?: boolean;
|
|
37
|
+
onSort: () => void;
|
|
38
|
+
} | {
|
|
39
|
+
sortable?: false;
|
|
40
|
+
onSort?: () => void;
|
|
41
|
+
});
|
|
42
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
43
|
+
export declare const tableHeaderCellParts: {
|
|
44
|
+
readonly root: "dds-tableheadercell";
|
|
45
|
+
readonly trigger: "dds-tableheadercell__trigger";
|
|
46
|
+
readonly indicator: "dds-tableheadercell__indicator";
|
|
47
|
+
};
|
|
48
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
49
|
+
export declare const tableHeaderCellDefaults: {
|
|
50
|
+
readonly size: "md";
|
|
51
|
+
readonly align: "start";
|
|
52
|
+
readonly sortDirection: "none";
|
|
53
|
+
readonly dividers: "rows";
|
|
54
|
+
readonly headerCase: "upper";
|
|
55
|
+
readonly sortable: false;
|
|
56
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// GENERATED from table-header-cell.contract.json. Do not edit.
|
|
2
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
3
|
+
export const tableHeaderCellParts = {
|
|
4
|
+
root: 'dds-tableheadercell',
|
|
5
|
+
trigger: 'dds-tableheadercell__trigger',
|
|
6
|
+
indicator: 'dds-tableheadercell__indicator',
|
|
7
|
+
};
|
|
8
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
9
|
+
export const tableHeaderCellDefaults = { size: 'md', align: 'start', sortDirection: 'none', dividers: 'rows', headerCase: 'upper', sortable: false };
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Scoped to this package, like the generated sheet beside it.
|
|
3
|
+
*
|
|
4
|
+
* `:where([data-dds-context="marketing"])` confines these rules without contributing
|
|
5
|
+
* specificity, so every override below still ties or beats exactly what it did
|
|
6
|
+
* before — several here are written a class deeper than they look in order to
|
|
7
|
+
* match generated CSS, and a scope that carried weight would break all of them.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/*
|
|
11
|
+
* The sort mark answering the pointer, where the whole header is the target.
|
|
12
|
+
*
|
|
13
|
+
* The header used to take a wash across the whole button, which is the gesture a row already uses
|
|
14
|
+
* to say a press would land there. At the top of a table it reads as a selected column instead: a
|
|
15
|
+
* block of grey behind a name, in the one row that holds no values.
|
|
16
|
+
*
|
|
17
|
+
* So the feedback moved to the mark and the target did not. The button still fills the cell and
|
|
18
|
+
* still takes the press anywhere in it — only what the reader sees change is smaller.
|
|
19
|
+
*
|
|
20
|
+
* The ink is the contract's: the indicator binds color.fg.default in the hover state, so the value
|
|
21
|
+
* is decided in the one place every other value here is. What a binding cannot say is *whose* hover
|
|
22
|
+
* — it names a part and a state, and generates `__indicator:hover`, which is the sixteen pixels of
|
|
23
|
+
* the glyph rather than the header around it. So the selector is here and the colour is not, the
|
|
24
|
+
* same division the row's pointer gate makes.
|
|
25
|
+
*
|
|
26
|
+
* No pointer-device gate here, unlike the row. A stale hover on a touch screen leaves a mark in the
|
|
27
|
+
* ink it would take anyway once that column were sorted, on a control the reader can still see —
|
|
28
|
+
* where a stale row wash points at the wrong record. The cost is not the same, so the departure is
|
|
29
|
+
* not worth repeating.
|
|
30
|
+
*/
|
|
31
|
+
:where([data-dds-context="marketing"]) .dds-tableheadercell .dds-tableheadercell__trigger:hover:where(:not(:disabled)) .dds-tableheadercell__indicator {
|
|
32
|
+
color: var(--color-fg-default);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/*
|
|
36
|
+
* The capitals reaching the column's name and nothing else placed beside it.
|
|
37
|
+
*
|
|
38
|
+
* `text-transform` inherits, and a header cell is a slot: a page may put a control or a mark in
|
|
39
|
+
* it, and "Select all" arrived as SELECT ALL — a control shouting at a reader in a row of quiet
|
|
40
|
+
* column names. Anything else a page composes in there would have gone the same way: a link, a
|
|
41
|
+
* tooltip's trigger, a count beside a name.
|
|
42
|
+
*
|
|
43
|
+
* The case belongs to the header's own words. Those are either the cell's text or, where the column
|
|
44
|
+
* can be sorted, the text inside its trigger — both of which carry this component's own class, and
|
|
45
|
+
* both of which the exclusion keeps. Everything else in there is a component with typography of its
|
|
46
|
+
* own, and its case is that component's business rather than the column's.
|
|
47
|
+
*/
|
|
48
|
+
:where([data-dds-context="marketing"]) .dds-tableheadercell [class*='dds-']:not([class*='dds-tableheadercell']) {
|
|
49
|
+
text-transform: none;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/*
|
|
53
|
+
* The sort mark, centred on the name's capitals rather than on its line box.
|
|
54
|
+
*
|
|
55
|
+
* `align-items: center` centres each flex item's box, and the two boxes here are not the same kind
|
|
56
|
+
* of thing. The glyph's ink fills its box symmetrically. The name's box is a line box, which
|
|
57
|
+
* reserves room under the baseline for descenders — and the header is uppercase, so it never has
|
|
58
|
+
* any. Its visible mass therefore sits above the centre of its own box while the glyph's sits on
|
|
59
|
+
* the centre of the glyph's, and the two are aligned by the browser and misaligned to the eye: the
|
|
60
|
+
* mark reads low by about half a descender.
|
|
61
|
+
*
|
|
62
|
+
* Product never has to correct this. It draws the mark a step smaller than anything in this
|
|
63
|
+
* package's icon ramp, and at that size the error is under a pixel. Here it is a sixteen-pixel mark
|
|
64
|
+
* against a twelve-pixel name, and it shows.
|
|
65
|
+
*
|
|
66
|
+
* The correction is bottom margin rather than a translate, because `align-items` centres the margin
|
|
67
|
+
* box: extending the box downward lifts the ink inside it by half of what was added, and it stays
|
|
68
|
+
* in the flow so nothing overlaps the row above. Stated in `em` so it tracks the type — this is the
|
|
69
|
+
* one measure in these sheets that is not a token, and it cannot be: it is a fraction of a font's
|
|
70
|
+
* descender, which is a fact about the typeface rather than a decision anybody made.
|
|
71
|
+
*/
|
|
72
|
+
:where([data-dds-context="marketing"]) .dds-tableheadercell .dds-tableheadercell__indicator {
|
|
73
|
+
margin-block-end: 0.2em;
|
|
74
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/* GENERATED from tablerow.contract.json. Do not edit. */
|
|
2
|
+
|
|
3
|
+
:where([data-dds-context="marketing"]) .dds-tablerow[data-selected="false"] {
|
|
4
|
+
background-color: var(--color-bg-transparent);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
:where([data-dds-context="marketing"]) .dds-tablerow[data-selected="true"] {
|
|
8
|
+
background-color: var(--color-bg-selected);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
:where([data-dds-context="marketing"]) .dds-tablerow[data-hoverable="false"]:hover {
|
|
12
|
+
background-color: var(--color-bg-transparent);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
:where([data-dds-context="marketing"]) .dds-tablerow[data-hoverable="true"]:hover {
|
|
16
|
+
background-color: var(--color-bg-hover);
|
|
17
|
+
}
|
|
18
|
+
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import './TableRow.css';
|
|
2
|
+
import './table-row-impl.css';
|
|
3
|
+
import { type TableRowProps } from './TableRow.types.js';
|
|
4
|
+
export type { TableRowProps };
|
|
5
|
+
/**
|
|
6
|
+
* One row of a table: the cells that answer the same questions in the same order as every other.
|
|
7
|
+
*
|
|
8
|
+
* It owns the rule above it and whether it reads as picked, and nothing about what any cell holds.
|
|
9
|
+
* Being picked is drawn here rather than on the checkbox that sets it, because selection is a fact
|
|
10
|
+
* about the row — a reader scanning needs to see which rows are in the set without checking every
|
|
11
|
+
* box in the first column.
|
|
12
|
+
*
|
|
13
|
+
* `aria-selected` is set only where the row is picked. A row that is not part of a selectable set
|
|
14
|
+
* should not announce itself as unselected: that tells a reader there is a selection to join when
|
|
15
|
+
* there may be none, and the attribute is absent rather than false on that account.
|
|
16
|
+
*/
|
|
17
|
+
export declare function TableRow({ selected, hoverable, dividers, overflow, size, headerCase, children, ...rest }: TableRowProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { Children, cloneElement, isValidElement } from 'react';
|
|
4
|
+
import './TableRow.css';
|
|
5
|
+
import './table-row-impl.css';
|
|
6
|
+
import { tableRowDefaults, tableRowParts } from './TableRow.types.js';
|
|
7
|
+
/**
|
|
8
|
+
* One row of a table: the cells that answer the same questions in the same order as every other.
|
|
9
|
+
*
|
|
10
|
+
* It owns the rule above it and whether it reads as picked, and nothing about what any cell holds.
|
|
11
|
+
* Being picked is drawn here rather than on the checkbox that sets it, because selection is a fact
|
|
12
|
+
* about the row — a reader scanning needs to see which rows are in the set without checking every
|
|
13
|
+
* box in the first column.
|
|
14
|
+
*
|
|
15
|
+
* `aria-selected` is set only where the row is picked. A row that is not part of a selectable set
|
|
16
|
+
* should not announce itself as unselected: that tells a reader there is a selection to join when
|
|
17
|
+
* there may be none, and the attribute is absent rather than false on that account.
|
|
18
|
+
*/
|
|
19
|
+
export function TableRow({ selected = tableRowDefaults.selected, hoverable = tableRowDefaults.hoverable, dividers = tableRowDefaults.dividers, overflow = tableRowDefaults.overflow, size = tableRowDefaults.size, headerCase = tableRowDefaults.headerCase, children, ...rest }) {
|
|
20
|
+
return (_jsx("tr", { ...rest, className: tableRowParts.root, "data-selected": String(selected), "data-hoverable": String(hoverable), "aria-selected": selected ? true : undefined, children: Children.toArray(children)
|
|
21
|
+
.filter(isValidElement)
|
|
22
|
+
.map((cell, at) => cloneElement(cell, {
|
|
23
|
+
key: cell.key ?? at,
|
|
24
|
+
size,
|
|
25
|
+
// The rule travels with the size: a cell draws the line above it, so a run of cells
|
|
26
|
+
// across one row draws one rule. The row itself cannot — a `<tr>` border is painted
|
|
27
|
+
// only while a table collapses its borders, and this one separates them for its corner.
|
|
28
|
+
dividers,
|
|
29
|
+
overflow,
|
|
30
|
+
headerCase,
|
|
31
|
+
})) }));
|
|
32
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import type { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
export interface TableRowOwnProps {
|
|
3
|
+
/** The page is holding this row in a set the reader has picked — for an export, a bulk action, a comparison. It draws the state and reports nothing: the checkbox in the row is what a reader presses, and what it reports belongs to the page */
|
|
4
|
+
selected?: boolean;
|
|
5
|
+
/** Handed down by the table. It draws a wash under the pointer so a reader knows which row a press would land on — and only on a device that has a pointer, which the row's own stylesheet gates */
|
|
6
|
+
hoverable?: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* `rows` — The default. A line between rows and none between columns, which is what stops the eye slipping from one row's start to another's end — the mistake a wide table invites and the one a reader never notices making
|
|
9
|
+
* `grid` — Lines both ways, for a table read as a matrix rather than as a list of records: a rate card, a comparison where the reader traces a column as often as a row. It is more lines than most tables need, so it should be asked for
|
|
10
|
+
* `none` — No lines at all. Right for two or three rows, where the rules are more structure than data, and for a table whose columns are already separated by their alignment
|
|
11
|
+
*/
|
|
12
|
+
dividers?: 'rows' | 'grid' | 'none';
|
|
13
|
+
/**
|
|
14
|
+
* `upper` — The house setting: column names in capitals, at the role that suits them. A header is read once where the data under it is read many times, and capitals are what stop it competing
|
|
15
|
+
* `title` — Names drawn as they were written, at twelve pixels. Right where the names are long, are proper nouns whose own capitals would be flattened, or are in a script with no case at all
|
|
16
|
+
*/
|
|
17
|
+
headerCase?: 'upper' | 'title';
|
|
18
|
+
/**
|
|
19
|
+
* `wrap` — The default. Text too long for its column wraps and the row grows taller, so nothing is hidden — right whenever the value is the point and a reader has to read all of it
|
|
20
|
+
* `truncate` — Rows must stay one line high — a dense table a reader scans down, where a row that grew would break the rhythm they are scanning by. The value is clipped with an ellipsis and the whole of it is still reachable, so this trades seeing for scanning rather than losing anything
|
|
21
|
+
*/
|
|
22
|
+
overflow?: 'wrap' | 'truncate';
|
|
23
|
+
/**
|
|
24
|
+
* `sm` — Compact. Dense data a reader scans rather than reads — a ledger, a positions table, anything where fitting more rows on screen is worth more than air around each one
|
|
25
|
+
* `md` — Balanced, and the default: rows a reader moves through at reading pace, with enough room that the eye does not slip between them
|
|
26
|
+
* `lg` — Spacious. Few rows, each carrying something substantial — a plan comparison, a summary of three accounts. Reach for it when the table is the page rather than a part of it
|
|
27
|
+
*/
|
|
28
|
+
size?: 'sm' | 'md' | 'lg';
|
|
29
|
+
/** Allowed: TableCell, TableHeaderCell */
|
|
30
|
+
children: ReactNode;
|
|
31
|
+
}
|
|
32
|
+
export type TableRowProps = TableRowOwnProps & Omit<HTMLAttributes<HTMLTableRowElement>, 'className' | 'selected' | 'hoverable' | 'dividers' | 'headerCase' | 'overflow' | 'size'>;
|
|
33
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
34
|
+
export declare const tableRowParts: {
|
|
35
|
+
readonly root: "dds-tablerow";
|
|
36
|
+
};
|
|
37
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
38
|
+
export declare const tableRowDefaults: {
|
|
39
|
+
readonly selected: false;
|
|
40
|
+
readonly hoverable: true;
|
|
41
|
+
readonly dividers: "rows";
|
|
42
|
+
readonly headerCase: "upper";
|
|
43
|
+
readonly overflow: "wrap";
|
|
44
|
+
readonly size: "md";
|
|
45
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
// GENERATED from table-row.contract.json. Do not edit.
|
|
2
|
+
/** The class each part carries. Apply these — do not retype them. */
|
|
3
|
+
export const tableRowParts = {
|
|
4
|
+
root: 'dds-tablerow',
|
|
5
|
+
};
|
|
6
|
+
/** Generated so defaults cannot drift from the contract. */
|
|
7
|
+
export const tableRowDefaults = { selected: false, hoverable: true, dividers: 'rows', headerCase: 'upper', overflow: 'wrap', size: 'md' };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Scoped to this package, like the generated sheet beside it.
|
|
3
|
+
*
|
|
4
|
+
* `:where([data-dds-context="marketing"])` confines these rules without contributing
|
|
5
|
+
* specificity, so every override below still ties or beats exactly what it did
|
|
6
|
+
* before — several here are written a class deeper than they look in order to
|
|
7
|
+
* match generated CSS, and a scope that carried weight would break all of them.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/*
|
|
11
|
+
* The pointer-device gate on the row highlight.
|
|
12
|
+
*
|
|
13
|
+
* A touch screen reports a hover that never ends: the last row tapped keeps the wash until
|
|
14
|
+
* something else is tapped, so a highlight meant to say "a press would land here" ends up saying it
|
|
15
|
+
* about a row the reader has already left. `@media (hover: hover)` is the question that separates a
|
|
16
|
+
* device with a pointer from one without, and it cannot be asked from a contract — a binding names
|
|
17
|
+
* a token and a state, and this is neither.
|
|
18
|
+
*
|
|
19
|
+
* Written as an undo rather than as the rule itself, so the generated stylesheet stays the one place
|
|
20
|
+
* the highlight's colour is decided. What is here is the condition, not the value.
|
|
21
|
+
*
|
|
22
|
+
* No other component in this package gates its hover, which makes this a departure worth naming
|
|
23
|
+
* rather than a convention being followed: a row is the largest hover target the system draws, and
|
|
24
|
+
* the only one wide enough that a stale highlight points at the wrong record rather than at a
|
|
25
|
+
* control the reader can still see.
|
|
26
|
+
*/
|
|
27
|
+
@media (hover: none) {
|
|
28
|
+
:where([data-dds-context="marketing"]) .dds-tablerow[data-hoverable='true']:hover {
|
|
29
|
+
background-color: transparent;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,325 @@
|
|
|
1
|
+
/* GENERATED from textarea.contract.json. Do not edit. */
|
|
2
|
+
|
|
3
|
+
:where([data-dds-context="marketing"]) .dds-textarea {
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
gap: var(--space-gap-xs);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-row {
|
|
10
|
+
align-items: center;
|
|
11
|
+
display: flex;
|
|
12
|
+
gap: var(--space-gap-xs);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label {
|
|
16
|
+
transition-property: color;
|
|
17
|
+
align-items: center;
|
|
18
|
+
display: flex;
|
|
19
|
+
color: var(--color-fg-default);
|
|
20
|
+
gap: var(--space-gap-xs);
|
|
21
|
+
min-block-size: var(--size-target-min);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-tooltip {
|
|
25
|
+
transition-property: background-color, color, outline-color, outline-width;
|
|
26
|
+
align-items: center;
|
|
27
|
+
appearance: none;
|
|
28
|
+
background-color: transparent;
|
|
29
|
+
border-style: none;
|
|
30
|
+
cursor: pointer;
|
|
31
|
+
display: flex;
|
|
32
|
+
flex: none;
|
|
33
|
+
justify-content: center;
|
|
34
|
+
outline-style: solid;
|
|
35
|
+
padding: unset;
|
|
36
|
+
border-radius: var(--radius-pill);
|
|
37
|
+
color: var(--color-fg-muted);
|
|
38
|
+
min-block-size: var(--size-target-min);
|
|
39
|
+
min-inline-size: var(--size-target-min);
|
|
40
|
+
outline-width: var(--border-width-none);
|
|
41
|
+
transition-duration: var(--motion-duration-fast);
|
|
42
|
+
transition-timing-function: var(--motion-easing-standard);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__control {
|
|
46
|
+
transition-property: background-color, border-color, box-shadow, opacity, outline-color, outline-width;
|
|
47
|
+
align-items: flex-start;
|
|
48
|
+
border-style: solid;
|
|
49
|
+
box-sizing: border-box;
|
|
50
|
+
display: flex;
|
|
51
|
+
inline-size: 100%;
|
|
52
|
+
outline-style: solid;
|
|
53
|
+
background-color: var(--color-bg-field);
|
|
54
|
+
border-color: var(--color-border-default);
|
|
55
|
+
border-width: var(--border-width-default);
|
|
56
|
+
gap: var(--space-gap-sm);
|
|
57
|
+
outline-width: var(--border-width-none);
|
|
58
|
+
transition-duration: var(--motion-duration-fast);
|
|
59
|
+
transition-timing-function: var(--motion-easing-standard);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__field {
|
|
63
|
+
appearance: none;
|
|
64
|
+
background-color: transparent;
|
|
65
|
+
border-style: none;
|
|
66
|
+
box-sizing: border-box;
|
|
67
|
+
display: block;
|
|
68
|
+
flex: auto;
|
|
69
|
+
min-inline-size: 0;
|
|
70
|
+
outline-style: solid;
|
|
71
|
+
padding: unset;
|
|
72
|
+
resize: none;
|
|
73
|
+
color: var(--color-fg-default);
|
|
74
|
+
outline-width: var(--border-width-none);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__footer {
|
|
78
|
+
align-items: flex-start;
|
|
79
|
+
display: flex;
|
|
80
|
+
justify-content: space-between;
|
|
81
|
+
gap: var(--space-gap-md);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__message {
|
|
85
|
+
transition-property: color;
|
|
86
|
+
align-items: flex-start;
|
|
87
|
+
display: flex;
|
|
88
|
+
overflow-wrap: anywhere;
|
|
89
|
+
font-family: var(--font-body-sm-family);
|
|
90
|
+
font-size: var(--font-body-sm-size);
|
|
91
|
+
font-weight: var(--font-body-sm-weight);
|
|
92
|
+
gap: var(--space-gap-xs);
|
|
93
|
+
letter-spacing: var(--font-body-sm-letter-spacing);
|
|
94
|
+
line-height: var(--font-body-sm-line-height);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__message-icon {
|
|
98
|
+
align-items: center;
|
|
99
|
+
display: flex;
|
|
100
|
+
flex-shrink: 0;
|
|
101
|
+
font-size: var(--font-body-sm-size);
|
|
102
|
+
line-height: var(--font-body-sm-line-height);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__counter {
|
|
106
|
+
flex: none;
|
|
107
|
+
font-variant-numeric: tabular-nums;
|
|
108
|
+
color: var(--color-fg-muted);
|
|
109
|
+
font-family: var(--font-body-sm-family);
|
|
110
|
+
font-size: var(--font-body-sm-size);
|
|
111
|
+
letter-spacing: var(--font-body-sm-letter-spacing);
|
|
112
|
+
line-height: var(--font-body-sm-line-height);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__field::placeholder {
|
|
116
|
+
color: var(--color-fg-tertiary);
|
|
117
|
+
font-weight: var(--font-body-md-weight);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__helper {
|
|
121
|
+
transition-property: color;
|
|
122
|
+
color: var(--color-fg-muted);
|
|
123
|
+
font-family: var(--font-body-sm-family);
|
|
124
|
+
font-size: var(--font-body-sm-size);
|
|
125
|
+
font-weight: var(--font-body-sm-weight);
|
|
126
|
+
letter-spacing: var(--font-body-sm-letter-spacing);
|
|
127
|
+
line-height: var(--font-body-sm-line-height);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__optional-mark {
|
|
131
|
+
transition-property: color;
|
|
132
|
+
color: var(--color-fg-muted);
|
|
133
|
+
font-family: var(--font-body-sm-family);
|
|
134
|
+
font-size: var(--font-body-sm-size);
|
|
135
|
+
font-weight: var(--font-body-sm-weight);
|
|
136
|
+
line-height: var(--font-body-sm-line-height);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__required-mark {
|
|
140
|
+
transition-property: color;
|
|
141
|
+
color: var(--color-fg-required);
|
|
142
|
+
font-family: var(--font-body-sm-family);
|
|
143
|
+
font-size: var(--font-body-sm-size);
|
|
144
|
+
font-weight: var(--font-body-sm-weight);
|
|
145
|
+
line-height: var(--font-body-sm-line-height);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__control:hover:where(:not(:has(.dds-textarea__field:disabled), :has(.dds-textarea__field[readonly]))) {
|
|
149
|
+
box-shadow: var(--elevation-ring-hover);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-tooltip:hover:where(:not(:disabled)) {
|
|
153
|
+
background-color: var(--color-bg-hover);
|
|
154
|
+
color: var(--color-fg-default);
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-tooltip:active {
|
|
158
|
+
background-color: var(--color-bg-active);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-tooltip:focus-visible {
|
|
162
|
+
outline-color: var(--color-border-focus);
|
|
163
|
+
outline-width: var(--border-width-focus);
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:focus-visible) .dds-textarea__control {
|
|
167
|
+
border-color: var(--color-border-focus);
|
|
168
|
+
outline-color: var(--color-border-focus);
|
|
169
|
+
outline-width: var(--border-width-hairline);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field[readonly]) .dds-textarea__control {
|
|
173
|
+
background-color: var(--color-bg-readonly);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled:not(:where(:disabled *))) .dds-textarea__control {
|
|
177
|
+
opacity: var(--opacity-disabled);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled) .dds-textarea__helper {
|
|
181
|
+
color: var(--color-fg-disabled);
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled) .dds-textarea__label {
|
|
185
|
+
color: var(--color-fg-disabled);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled) .dds-textarea__message {
|
|
189
|
+
color: var(--color-fg-disabled);
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled) .dds-textarea__optional-mark {
|
|
193
|
+
color: var(--color-fg-disabled);
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
:where([data-dds-context="marketing"]) .dds-textarea:has(.dds-textarea__field:disabled) .dds-textarea__required-mark {
|
|
197
|
+
color: var(--color-fg-disabled);
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="lg"] .dds-textarea__control {
|
|
201
|
+
border-radius: var(--radius-control-lg);
|
|
202
|
+
padding-block: var(--space-inset-md);
|
|
203
|
+
padding-inline: var(--space-inset-md);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="lg"] .dds-textarea__field {
|
|
207
|
+
font-family: var(--font-body-lg-family);
|
|
208
|
+
font-size: var(--font-body-lg-size);
|
|
209
|
+
font-weight: var(--font-body-lg-weight);
|
|
210
|
+
letter-spacing: var(--font-body-lg-letter-spacing);
|
|
211
|
+
line-height: var(--font-body-lg-line-height);
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="lg"] .dds-textarea__label {
|
|
215
|
+
font-family: var(--font-field-label-lg-family);
|
|
216
|
+
font-size: var(--font-field-label-lg-size);
|
|
217
|
+
font-weight: var(--font-field-label-lg-weight);
|
|
218
|
+
letter-spacing: var(--font-field-label-lg-letter-spacing);
|
|
219
|
+
line-height: var(--font-field-label-lg-line-height);
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="md"] .dds-textarea__control {
|
|
223
|
+
border-radius: var(--radius-control-md);
|
|
224
|
+
padding-block: var(--space-inset-sm);
|
|
225
|
+
padding-inline: var(--space-inset-sm);
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="md"] .dds-textarea__field {
|
|
229
|
+
font-family: var(--font-body-md-family);
|
|
230
|
+
font-size: var(--font-body-md-size);
|
|
231
|
+
font-weight: var(--font-body-md-weight);
|
|
232
|
+
letter-spacing: var(--font-body-md-letter-spacing);
|
|
233
|
+
line-height: var(--font-body-md-line-height);
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="md"] .dds-textarea__label {
|
|
237
|
+
font-family: var(--font-field-label-md-family);
|
|
238
|
+
font-size: var(--font-field-label-md-size);
|
|
239
|
+
font-weight: var(--font-field-label-md-weight);
|
|
240
|
+
letter-spacing: var(--font-field-label-md-letter-spacing);
|
|
241
|
+
line-height: var(--font-field-label-md-line-height);
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="sm"] .dds-textarea__control {
|
|
245
|
+
border-radius: var(--radius-control-sm);
|
|
246
|
+
padding-block: var(--space-inset-sm);
|
|
247
|
+
padding-inline: var(--space-inset-sm);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="sm"] .dds-textarea__field {
|
|
251
|
+
font-family: var(--font-body-md-family);
|
|
252
|
+
font-size: var(--font-body-md-size);
|
|
253
|
+
font-weight: var(--font-body-md-weight);
|
|
254
|
+
letter-spacing: var(--font-body-md-letter-spacing);
|
|
255
|
+
line-height: var(--font-body-md-line-height);
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-size="sm"] .dds-textarea__label {
|
|
259
|
+
font-family: var(--font-field-label-md-family);
|
|
260
|
+
font-size: var(--font-field-label-md-size);
|
|
261
|
+
font-weight: var(--font-field-label-md-weight);
|
|
262
|
+
letter-spacing: var(--font-field-label-md-letter-spacing);
|
|
263
|
+
line-height: var(--font-field-label-md-line-height);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="error"] .dds-textarea__control {
|
|
267
|
+
border-color: var(--color-border-danger);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="error"] .dds-textarea__message {
|
|
271
|
+
color: var(--color-fg-danger);
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="pending"] .dds-textarea__message {
|
|
275
|
+
color: var(--color-fg-muted);
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="success"] .dds-textarea__control {
|
|
279
|
+
border-color: var(--color-border-success);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="success"] .dds-textarea__message {
|
|
283
|
+
color: var(--color-fg-success);
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="warning"] .dds-textarea__control {
|
|
287
|
+
border-color: var(--color-border-warning);
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="warning"] .dds-textarea__message {
|
|
291
|
+
color: var(--color-fg-warning);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="error"]:has(.dds-textarea__field:focus-visible) .dds-textarea__control {
|
|
295
|
+
border-color: var(--color-border-danger);
|
|
296
|
+
outline-color: var(--color-border-danger);
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="success"]:has(.dds-textarea__field:focus-visible) .dds-textarea__control {
|
|
300
|
+
border-color: var(--color-border-success);
|
|
301
|
+
outline-color: var(--color-border-success);
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
:where([data-dds-context="marketing"]) .dds-textarea[data-status="warning"]:has(.dds-textarea__field:focus-visible) .dds-textarea__control {
|
|
305
|
+
border-color: var(--color-border-warning);
|
|
306
|
+
outline-color: var(--color-border-warning);
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__label-tooltip:disabled {
|
|
310
|
+
cursor: not-allowed;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__field:disabled {
|
|
314
|
+
cursor: not-allowed;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
:where([data-dds-context="marketing"]) .dds-textarea .dds-textarea__field[readonly] {
|
|
318
|
+
cursor: default;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
@media (prefers-reduced-motion: reduce) {
|
|
322
|
+
:where([data-dds-context="marketing"]) .dds-textarea,
|
|
323
|
+
:where([data-dds-context="marketing"]) .dds-textarea * { transition: none; }
|
|
324
|
+
}
|
|
325
|
+
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import './TextArea.css';
|
|
2
|
+
import './text-area-impl.css';
|
|
3
|
+
import { type TextAreaProps } from './TextArea.types.js';
|
|
4
|
+
export type { TextAreaProps };
|
|
5
|
+
/**
|
|
6
|
+
* How many lines the box is, given how much text is in it.
|
|
7
|
+
*
|
|
8
|
+
* Exported because it is the whole of the growing rule and it is worth testing without a DOM:
|
|
9
|
+
* never fewer than `rows`, never more than `maxRows`, and `maxRows` below `rows` is read as
|
|
10
|
+
* `rows` rather than inverting the two.
|
|
11
|
+
*/
|
|
12
|
+
export declare function linesFor(content: number, line: number, rows: number, maxRows: number): number;
|
|
13
|
+
export declare function TextArea({ size, status, label, labelTooltip, placeholder, helperText, rows, maxRows, maxLength, statusMessage, required, requiredMark, optional, ...rest }: TextAreaProps): import("react").JSX.Element;
|