@canonical/design-system 0.43.0 → 0.46.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/data/apps/component/file_tree.ttl +1 -1
- package/data/apps/component/inline_panel.ttl +17 -0
- package/data/apps/component/key_value_pair.ttl +1 -1
- package/data/apps/{subcomponent → component}/log.ttl +1 -1
- package/data/apps/component/navigation.ttl +1 -1
- package/data/apps/component/notification.ttl +1 -1
- package/data/apps/component/side_navigation.ttl +50 -6
- package/data/apps/group/key_value_pairs.ttl +1 -1
- package/data/apps/group/notifications.ttl +1 -1
- package/data/apps/layout/application_layout.ttl +1 -1
- package/data/apps/layout/content_layout.ttl +2 -3
- package/data/apps/layout/empty_layout.ttl +1 -1
- package/data/apps/layout/empty_state.ttl +1 -1
- package/data/{apps_workplaceengineering/pattern/group_card.ttl → apps/layout/login_layout.ttl} +4 -5
- package/data/apps/layout/side_panel_form_layout.ttl +13 -0
- package/data/apps/pattern/action_bar.ttl +2 -2
- package/data/apps/pattern/code_diff.ttl +1 -1
- package/data/apps/pattern/datatable.ttl +30 -31
- package/data/apps/pattern/destructive_modal.ttl +1 -1
- package/data/apps/pattern/drawer.ttl +1 -1
- package/data/apps/pattern/notification_center.ttl +2 -2
- package/data/apps/pattern/page_header.ttl +13 -0
- package/data/apps/pattern/side_panel.ttl +258 -10
- package/data/apps/subcomponent/data_table-action_bar.ttl +6 -6
- package/data/apps/subcomponent/data_table-body_cell.ttl +26 -26
- package/data/apps/subcomponent/data_table-group_header_row.ttl +8 -8
- package/data/apps/subcomponent/data_table-header_cell.ttl +13 -13
- package/data/apps/subcomponent/data_table-pagination_bar.ttl +9 -9
- package/data/apps/subcomponent/data_table-persistent_selection.ttl +10 -10
- package/data/apps/subcomponent/data_table-settings_menu.ttl +15 -15
- package/data/apps/subcomponent/drawer-content.ttl +1 -1
- package/data/apps/subcomponent/drawer-footer.ttl +1 -1
- package/data/apps/subcomponent/drawer-header.ttl +1 -1
- package/data/apps/subcomponent/side_navigation-content.ttl +13 -0
- package/data/apps/subcomponent/side_navigation-context_switcher.ttl +53 -0
- package/data/apps/subcomponent/side_navigation-item.ttl +80 -0
- package/data/apps/subcomponent/side_navigation-item_group.ttl +13 -0
- package/data/apps/subcomponent/side_panel-content.ttl +2 -2
- package/data/apps/subcomponent/side_panel-footer.ttl +196 -3
- package/data/apps/subcomponent/side_panel-header.ttl +212 -3
- package/data/apps_anbox/component/theme_switcher.ttl +1 -1
- package/data/apps_anbox/pattern/side_menu.ttl +0 -1
- package/data/{tagcategory/lpupstream.ttl → apps_identity.ttl} +2 -2
- package/data/apps_landscape/component/checkbox_group.ttl +24 -24
- package/data/apps_landscape/component/code_editor.ttl +35 -35
- package/data/apps_landscape/component/cron_schedule.ttl +4 -4
- package/data/apps_landscape/component/expandable_radio_group.ttl +47 -47
- package/data/apps_landscape/component/expandable_truncation.ttl +20 -20
- package/data/apps_landscape/component/form_section.ttl +4 -4
- package/data/apps_landscape/component/gpg_key_field.ttl +27 -27
- package/data/apps_landscape/component/grouped_select.ttl +25 -25
- package/data/apps_landscape/component/loading_state.ttl +8 -8
- package/data/apps_landscape/component/managed_file_input.ttl +18 -18
- package/data/apps_landscape/component/multi_select_field.ttl +50 -50
- package/data/apps_landscape/component/password_constraints.ttl +1 -1
- package/data/apps_landscape/component/progress_bar.ttl +20 -20
- package/data/apps_landscape/component/read_only_field.ttl +15 -15
- package/data/apps_landscape/component/search_help_popup.ttl +10 -10
- package/data/apps_landscape/component/search_query_editor.ttl +33 -33
- package/data/apps_landscape/component/tag_multi_select.ttl +9 -9
- package/data/apps_landscape/pattern/content_blocks.ttl +20 -20
- package/data/apps_landscape/pattern/dashboard_page_composition.ttl +37 -37
- package/data/apps_landscape/pattern/delivery_scheduling.ttl +6 -6
- package/data/apps_landscape/pattern/form_field_help.ttl +28 -28
- package/data/apps_landscape/pattern/header_search_controls.ttl +41 -41
- package/data/apps_landscape/pattern/ignorable_notification.ttl +16 -16
- package/data/apps_landscape/pattern/information_grid.ttl +14 -14
- package/data/apps_landscape/pattern/instance_association.ttl +5 -5
- package/data/apps_landscape/pattern/process_flow.ttl +11 -11
- package/data/apps_landscape/pattern/progressively_expandable_table.ttl +32 -32
- package/data/apps_landscape/pattern/recurring_schedule.ttl +3 -3
- package/data/apps_landscape/pattern/responsive_action_group.ttl +12 -12
- package/data/apps_landscape/pattern/responsive_header_actions.ttl +14 -14
- package/data/apps_landscape/pattern/responsive_table_filters.ttl +11 -11
- package/data/apps_landscape/pattern/side_panel_form_actions.ttl +40 -40
- package/data/apps_landscape/pattern/sortable_list.ttl +14 -14
- package/data/apps_landscape/pattern/table_filter.ttl +57 -57
- package/data/apps_landscape/pattern/table_filter_chips.ttl +67 -67
- package/data/apps_landscape/pattern/table_pagination.ttl +63 -63
- package/data/apps_landscape/pattern/typed_confirmation_modal.ttl +22 -22
- package/data/apps_landscape/subcomponent/bold_substring.ttl +4 -4
- package/data/apps_landscape/subcomponent/inline_cell_input.ttl +8 -8
- package/data/apps_landscape/subcomponent/label_with_description.ttl +14 -14
- package/data/apps_landscape/subcomponent/nested_dropdown_item.ttl +8 -8
- package/data/apps_landscape/subcomponent/pluralized_bold_count.ttl +7 -7
- package/data/apps_landscape/subcomponent/select_all_results_prompt.ttl +12 -12
- package/data/apps_launchpad/component/avatar.ttl +2 -2
- package/data/apps_launchpad/component/badge.ttl +2 -2
- package/data/apps_launchpad/component/breadcrumbs.ttl +1 -1
- package/data/apps_launchpad/component/button.ttl +2 -2
- package/data/apps_launchpad/component/checkbox_input.ttl +4 -4
- package/data/apps_launchpad/component/combobox.ttl +2 -2
- package/data/apps_launchpad/component/drawer.ttl +4 -4
- package/data/apps_launchpad/component/modal.ttl +6 -14
- package/data/apps_launchpad/component/radio_input.ttl +5 -5
- package/data/apps_launchpad/component/select_input.ttl +1 -1
- package/data/apps_launchpad/component/switch.ttl +5 -5
- package/data/apps_launchpad/component/text_input.ttl +8 -8
- package/data/apps_launchpad/component/textarea_input.ttl +10 -10
- package/data/apps_launchpad/component/tooltip.ttl +3 -3
- package/data/apps_launchpad/subcomponent/combobox-loading.ttl +2 -2
- package/data/apps_launchpad/subcomponent/combobox-search.ttl +4 -4
- package/data/apps_launchpad/subcomponent/description_list-item.ttl +1 -1
- package/data/apps_launchpad/subcomponent/modal-content.ttl +2 -2
- package/data/apps_lxd/component/back_link.ttl +1 -1
- package/data/apps_lxd/component/code_snippet_with_copy_button.ttl +1 -1
- package/data/apps_lxd/component/doc_link.ttl +2 -2
- package/data/apps_lxd/component/meter.ttl +5 -5
- package/data/apps_lxd/component/output_field.ttl +2 -3
- package/data/apps_lxd/component/rename_header.ttl +15 -15
- package/data/apps_lxd/component/tab_links.ttl +4 -4
- package/data/apps_lxd/subcomponent/copy_to_clipboard.ttl +2 -2
- package/data/apps_lxd/view/network_topology.ttl +3 -4
- package/data/apps_portal/layout/details_view.ttl +0 -1
- package/data/apps_workplaceengineering/component/label-highlight.ttl +2 -3
- package/data/apps_workplaceengineering/component/org_chart.ttl +12 -0
- package/data/apps_workplaceengineering/component/theme_switcher.ttl +1 -1
- package/data/apps_workplaceengineering/pattern/callout_numbers_card.ttl +2 -2
- package/data/apps_workplaceengineering/pattern/{event_timeline.ttl → org_event_card.ttl} +3 -4
- package/data/apps_workplaceengineering/subcomponent/multi_select_input.ttl +1 -1
- package/data/concept/Filtering-patterns.ttl +11 -0
- package/data/concept/Foundations-Grid--Layout.ttl +2 -2
- package/data/concept/Foundations-Surfaces.ttl +1 -1
- package/data/concept/How-to-differentiate-types-of-UI-blocks-.ttl +3 -3
- package/data/concept/How-to-indicate-required-fields-in-forms.ttl +1 -1
- package/data/concept/Overflow.ttl +11 -0
- package/data/concept/Question-mark-vs-information-icon.ttl +1 -1
- package/data/documentation/layout/content_page_layout.ttl +13 -0
- package/data/documentation/layout/documentation_layout.ttl +2 -1
- package/data/documentation/layout/library_layout.ttl +13 -0
- package/data/documentation/layout/search_page_layout.ttl +13 -0
- package/data/documentation/pattern/library_side_navigation.ttl +3 -3
- package/data/global/component/accordion.ttl +6 -185
- package/data/global/component/announcement.ttl +2 -3
- package/data/global/component/avatar.ttl +1 -1
- package/data/global/component/badge.ttl +5 -7
- package/data/global/component/breadcrumbs.ttl +7 -6
- package/data/global/component/button.ttl +5 -23
- package/data/global/component/card.ttl +3 -8
- package/data/global/component/checkbox_field.ttl +1 -1
- package/data/global/component/chip.ttl +4 -6
- package/data/global/component/choices_field.ttl +11 -3
- package/data/global/component/code_snippet.ttl +2 -3
- package/data/global/component/color_field.ttl +1 -1
- package/data/global/component/combobox_field.ttl +2 -18
- package/data/global/component/contextual_menu.ttl +4 -6
- package/data/global/component/data_tooltip.ttl +4 -4
- package/data/global/component/date_field.ttl +1 -1
- package/data/global/component/date_time_field.ttl +1 -1
- package/data/global/component/drag_and_drop_list.ttl +2 -2
- package/data/global/component/dropdown_button.ttl +4 -5
- package/data/global/component/file_upload_field.ttl +1 -1
- package/data/global/component/heading.ttl +4 -4
- package/data/global/component/hidden_field.ttl +1 -1
- package/data/global/component/icon.ttl +2 -2
- package/data/global/component/icon_button.ttl +13 -0
- package/data/global/component/icon_in_container.ttl +7 -2
- package/data/global/component/inline_code.ttl +1 -1
- package/data/global/component/keyboard_key.ttl +1 -1
- package/data/global/{layout/form_layout.ttl → component/link.ttl} +3 -3
- package/data/global/component/links.ttl +12 -0
- package/data/global/component/mode_switcher.ttl +1 -1
- package/data/global/component/notification_toast.ttl +1 -1
- package/data/global/component/pagination.ttl +2 -2
- package/data/global/component/password_field.ttl +1 -1
- package/data/global/component/phone_field.ttl +1 -1
- package/data/global/component/popover.ttl +1 -1
- package/data/global/component/query_builder.ttl +12 -0
- package/data/global/component/range_field.ttl +1 -1
- package/data/global/component/rating_field.ttl +1 -1
- package/data/global/component/relative_timestamp.ttl +2 -1
- package/data/global/component/rich_choices_field.ttl +1 -1
- package/data/global/component/rich_text_editor.ttl +12 -0
- package/data/global/component/rich_text_field.ttl +1 -1
- package/data/global/component/search_field.ttl +1 -1
- package/data/global/component/segmented_control.ttl +13 -0
- package/data/global/component/segmented_control_field.ttl +1 -1
- package/data/global/component/select_field.ttl +1 -1
- package/data/global/component/switch_field.ttl +1 -1
- package/data/global/component/table.ttl +2 -2
- package/data/global/component/tabs.ttl +1 -1
- package/data/global/component/tag.ttl +2 -2
- package/data/global/component/text_field.ttl +1 -1
- package/data/global/component/textarea_field.ttl +1 -1
- package/data/global/component/tile.ttl +3 -6
- package/data/global/component/time_field.ttl +1 -1
- package/data/global/component/timestamp.ttl +2 -1
- package/data/global/component/tooltip.ttl +43 -45
- package/data/global/component/tooltip_wrapper.ttl +2 -2
- package/data/global/group/buttons.ttl +1 -8
- package/data/global/group/cards.ttl +1 -5
- package/data/global/group/code_snippets.ttl +1 -1
- package/data/global/group/keyboard_keys.ttl +1 -1
- package/data/global/group/tiles.ttl +1 -1
- package/data/global/modifier/information.ttl +1 -1
- package/data/global/pattern/field.ttl +1 -1
- package/data/global/pattern/filter.ttl +13 -0
- package/data/global/pattern/form_login.ttl +1 -1
- package/data/global/pattern/modal.ttl +5 -21
- package/data/global/pattern/navigation.ttl +1 -1
- package/data/global/pattern/stepper.ttl +1 -1
- package/data/global/pattern/table_of_contents.ttl +1 -1
- package/data/global/pattern/timeline.ttl +15 -20
- package/data/global/subcomponent/accordion-item.ttl +3 -156
- package/data/global/subcomponent/card-content.ttl +1 -1
- package/data/global/subcomponent/card-footer.ttl +1 -1
- package/data/global/subcomponent/card-header.ttl +1 -1
- package/data/global/subcomponent/card-image.ttl +2 -2
- package/data/global/subcomponent/card-thumbnail.ttl +1 -1
- package/data/global/subcomponent/checkbox_input.ttl +1 -1
- package/data/global/subcomponent/color_input.ttl +1 -1
- package/data/global/subcomponent/combobox_input.ttl +2 -18
- package/data/global/subcomponent/date_input.ttl +1 -1
- package/data/global/subcomponent/date_time_input.ttl +1 -1
- package/data/global/subcomponent/field-description.ttl +1 -1
- package/data/global/subcomponent/field-label.ttl +1 -1
- package/data/global/subcomponent/file_upload_input.ttl +1 -1
- package/data/global/subcomponent/hidden_input.ttl +1 -1
- package/data/global/subcomponent/modal-content.ttl +1 -1
- package/data/global/subcomponent/modal-footer.ttl +2 -18
- package/data/global/subcomponent/modal-header.ttl +5 -21
- package/data/global/subcomponent/password_input.ttl +1 -1
- package/data/global/subcomponent/phone_input.ttl +1 -1
- package/data/global/subcomponent/radio_input.ttl +1 -1
- package/data/global/subcomponent/range_input.ttl +1 -1
- package/data/global/subcomponent/rating_input.ttl +1 -1
- package/data/global/subcomponent/rich_text_input.ttl +1 -1
- package/data/global/subcomponent/search_input.ttl +3 -4
- package/data/global/subcomponent/segmented_control_input.ttl +1 -1
- package/data/global/subcomponent/select_input.ttl +1 -1
- package/data/global/subcomponent/spinner.ttl +2 -2
- package/data/global/subcomponent/switch_input.ttl +1 -1
- package/data/global/subcomponent/text_input.ttl +1 -1
- package/data/global/subcomponent/textarea_input.ttl +1 -1
- package/data/global/subcomponent/tile-content.ttl +1 -1
- package/data/global/subcomponent/time_input.ttl +1 -1
- package/data/global/subcomponent/timeline-content.ttl +2 -2
- package/data/global/subcomponent/timeline-event.ttl +5 -5
- package/data/global/subcomponent/timeline-expansion_indicator.ttl +1 -1
- package/data/global/subcomponent/timeline-header.ttl +1 -1
- package/data/global/variant/tooltip_dense.ttl +1 -1
- package/data/sites/component/store_card.ttl +92 -0
- package/data/sites/pattern/hero.ttl +295 -4
- package/data/{stores.ttl → sites_stores.ttl} +2 -2
- package/data/tag/designin-progress.ttl +9 -0
- package/data/tag/devbatch1.ttl +1 -1
- package/data/tag/devbatch2.ttl +1 -1
- package/data/tag/devbatch3.ttl +1 -1
- package/data/tag/devdone.ttl +9 -0
- package/data/tag/devin-progress.ttl +9 -0
- package/data/tag/devin-review.ttl +9 -0
- package/data/tag/devpre-approved.ttl +9 -0
- package/data/tag/{stylesready.ttl → devreactdone.ttl} +3 -3
- package/data/tag/devreactpreapproved.ttl +1 -1
- package/data/tag/{devreactapproved.ttl → devsveltepreapproved.ttl} +3 -3
- package/data/tag/divergent.ttl +1 -1
- package/data/tag/docscomplete.ttl +1 -1
- package/data/tag/global-docs-missing.ttl +1 -1
- package/data/tag/has-no-global-entry.ttl +1 -1
- package/data/tag/implementationcomplete.ttl +9 -0
- package/data/tag/lpto-be-upstreamed.ttl +1 -1
- package/data/tag/lptriageblocked-reqs-design.ttl +1 -1
- package/data/tag/lptriageno-upstream.ttl +1 -1
- package/data/tag/lptriagereimplement-and-deprecate.ttl +1 -1
- package/data/tag/lptriagereimplement-and-keep.ttl +1 -1
- package/data/tag/lptriageupstream-and-deprecate.ttl +1 -1
- package/data/tag/{needsdefinition.ttl → needscoredocumentation.ttl} +3 -3
- package/data/tag/needsdesign.ttl +9 -0
- package/data/tag/{needsdocumentation.ttl → needsfulldocumentation.ttl} +3 -3
- package/data/tag/needsimplementation.ttl +9 -0
- package/data/tag/needstriage.ttl +1 -1
- package/data/tag/specialadoption-docs.ttl +1 -1
- package/data/tag/triagedbacklog.ttl +2 -2
- package/data/tag/triagedrejected.ttl +2 -2
- package/data/tag/upstream-candidate.ttl +1 -1
- package/data/tag/upstream-compliant.ttl +1 -1
- package/data/tag/waiting-for-delta-review.ttl +1 -1
- package/data/tag/wpeinital-implementation.ttl +1 -1
- package/data/tag/wpetriageupstream-and-deprecate.ttl +1 -0
- package/data/tagcategory/design--documentation-status.ttl +6 -0
- package/data/tagcategory/{documentation-stage.ttl → implementationnotes.ttl} +2 -2
- package/data/tagcategory/implementationstatus.ttl +6 -0
- package/data/tagcategory/implementationworkflow.ttl +6 -0
- package/package.json +10 -10
- package/skills/adoption-a1-styles/SKILL.md +38 -8
- package/skills/adoption-a2-components/SKILL.md +44 -4
- package/skills/adoption-a3-forms/SKILL.md +1 -1
- package/skills/anatomy-author/SKILL.md +26 -2
- package/skills/design-auditor/SKILL.md +1 -1
- package/skills/implement-component/SKILL.md +1 -1
- package/skills/specify-component/SKILL.md +1 -1
- package/skills/specify-pattern/SKILL.md +1 -1
- package/src/collect/types.ts +1 -1
- package/data/apps_workplaceengineering/pattern/travel_provider_card.ttl +0 -14
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.accordion a ds:Component;
|
|
6
6
|
ds:name "Accordion";
|
|
7
|
-
ds:summary "The accordion is a vertically stacked content area which can be collapsed and expanded to reveal or hide its contents. An can be opened or closed independently of its surrounding counterparts (i.e: multiple accordions can be open at the same time). \n\nAccordions can help browse different pieces of related content in a more efficient way. Be wary that they can also hide content from users and are not suitable when a user is meant to read all of the page content
|
|
8
|
-
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Accordion/styles.css on .ds.accordion\nnode:\n uri: global.component.accordion\n styles:\n layout.type: flex\n layout.direction: column\n # Inert outside a grid: the accordion is a full-width block, never a cell.\n layout.grid.column: \"1 / -1\"\n # Read on the element, not at :root, so the surface channel steps with\n # `.surface` nesting; outside any surface it falls back to the base.\n appearance.background: [surface.color.background, color.background]\n appearance.radius: dimension.radius.small\n # Clips the item corners to the accordion radius.\n layout.overflow: hidden\n # The retired `appearance.border: color-border-$root` is dropped: per the\n # Figma anatomy the accordion has no outer frame — only the per-item\n # dividers, which Accordion.Item carries.\n edges:\n - node:\n uri: global.subcomponent.accordion-item\n relation:\n cardinality: \"1..*\"\n slotName: default";
|
|
7
|
+
ds:summary "The accordion is a vertically stacked content area which can be collapsed and expanded to reveal or hide its contents. An can be opened or closed independently of its surrounding counterparts (i.e: multiple accordions can be open at the same time). \n\nAccordions can help browse different pieces of related content in a more efficient way. Be wary that they can also hide content from users and are not suitable when a user is meant to read all of the page content.";
|
|
8
|
+
ds:anatomyDsl "Initial\n\n```yaml\n---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Accordion/styles.css on .ds.accordion\nnode:\n uri: global.component.accordion\n styles:\n layout.type: flex\n layout.direction: column\n # Inert outside a grid: the accordion is a full-width block, never a cell.\n layout.grid.column: \"1 / -1\"\n # Read on the element, not at :root, so the surface channel steps with\n # `.surface` nesting; outside any surface it falls back to the base.\n appearance.background: [surface.color.background, color.background]\n appearance.radius: dimension.radius.small\n # Clips the item corners to the accordion radius.\n layout.overflow: hidden\n # The retired `appearance.border: color-border-$root` is dropped: per the\n # Figma anatomy the accordion has no outer frame — only the per-item\n # dividers, which Accordion.Item carries.\n edges:\n - node:\n uri: global.subcomponent.accordion-item\n relation:\n cardinality: \"1..*\"\n slotName: default\n```\n\n\n\nNew\n\n```yaml\n---\nnode:\n uri: global.component.accordion\n styles:\n layout.type: flex\n layout.direction: column\n edges:\n - node:\n uri: global.subcomponent.accordion-item\n relation:\n cardinality: \"1..*\"\n slotName: default\n```\n\n```yaml\n---\n# Source: Figma file \"Pragma - documentation visuals\" (WGHcOmGMEUF9hMAEoRafL8), node 6507:2040, instance of the Accordion component set, variant Surface=Root.\n# Omitted: the Surface=Layer 2 variant, which differs from Surface=Root only by the surface-specific fills of its items (see global.subcomponent.accordion-item).\n# Omitted: the hidden \"TRACKING PIXEL DO NOT DELETE\" frame, a Figma library-tracking artefact that renders nothing.\nnode:\n uri: global.component.accordion\n # Omitted: bottom padding, bound in Figma to the variable baseline-kick/accordion/bottom (0px by default); no token symbol declares that name.\n styles:\n layout.type: flex\n layout.direction: column\n layout.align: flex-start\n edges:\n - node:\n # The Figma \"Accordion items\" slot; it clips its content.\n role: items\n styles:\n layout.type: flex\n layout.direction: column\n layout.align: flex-start\n layout.overflow: hidden\n edges:\n # Open decision: the minimum of one item is not stated in Figma, which only shows five items.\n - node:\n uri: global.subcomponent.accordion-item\n relation:\n cardinality: \"1..*\"\n slotName: default\n relation:\n cardinality: \"1\"\n```";
|
|
9
9
|
ds:anatomyClassic "https://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=4457-2017&t=2fO23I8WsyT0YVJ1-4\n\n\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=4457-2163&t=P4vtZZbgRnYDuD33-1\n\n";
|
|
10
10
|
ds:usage "The accordion can be used to pack a lot of content into a constrained space by allowing to collapse and expand the to show or hide its contents. It also allows the user to consume the contents at their own pace and preference by not immediately showing but relying on progressive disclosure instead.\n\nTherefore when used right, accordions can help browse different pieces of related content in a more efficient way. Be wary that they can also hide content from users and are not suitable when a user is meant to read all of the page content.\n\n### Header\n\nThe header of the content contains the chevron, heading, and optional items such as a [Badge](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eHpgyzRyDl). The heading of the accordion should give the user a clear indication of what the contents of accordion item are going to be. The user should not have to open the to understand what is contained inside of it.\n\n### Panel\n\nThe accordion panel is what contains the content of an . Be mindful of what contents are put in the accordion item as an accordion does not lend itself well to containing overly complex components or patterns. The contents of an accordion will most often be just plain text or a simple component arrangement like filters (checkbox + label).\n\nIt is not allowed to nest .\n\n### When to use\n\n- In cases where there is a lot more content than the available screen estate allows for. E.g. when there is a lot of filters to show in a sidebar.\n- When you want to allow the user to scan large amounts of contents in a smaller amount of space and dive deeper at their own choosing. E.g. in an FAQ.\n- To shorten page lengths (and scroll time) if it is not important that the user reads everything.\n\n### When not to use\n\n- When the page content must be seen at a glance by a user. \n - Incorrect: Hiding mandatory legal terms or essential safety instructions inside collapsed Accordion panels.\n - Remediation: Instead you might consider restructuring your content or using anchor links in the beginning of the page which redirect the user to specific sections of the page. \n- When the data you want to show is inherently nested as accordion items do not allow to be nested.\n - Incorrect: Using an accordion to house a four-level deep directory of help articles or internal pages.\n - Remediation: Use a side [Navigation](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-nkDiZdUMkV) or [FileTree](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-DAHwqGVhxp) component, which is specifically designed to handle nested relationships and persistent state across navigation. \n";
|
|
11
11
|
ds:guidelines "# Animation\n\nThere is a fast (0.165s) animation of the accordion item when an accordion item is expanded / collapsed.\n\n- A fade from 0 - 100% opacity\n- The content slides upwards/downwards slightly (0.5rem)\n\n# Accessibility\n\n## Built-in\n\n### Semantic foundation: HTML and Aria labels\n\n- The accordion header is an HTML button.\n- The button which expands the accordion item has `aria-expanded=”true”` label if the accordion item is currently expanded, and `aria-expanded=\"false\"` when it is collapsed.\n- The button which expands the accordion item has a `aria-controls` with the ID set to the ID of the panel which is being expanded by it.\n- The accordion panel uses the `aria-labelledby` label with the ID set to the ID of the button which expands the accordion item.\n- Each accordion header button is automatically wrapped in a heading element at the level specified by the required `headingLevel` prop.\n\n### Visual and motion\n\n- Text color ensures 4.5:1 contrast with the background, chevrons color ensure 3:1 contrast with the background\n- Animations are disabled when `prefers-reduced-motion: reduce` is set\n- Color alone is not and should not be used to distinguish expanded vs. collapsed state. The chevron direction change indicates the difference.\n\n### **Keyboard navigation and focus order** \n\n- `Tab` and `Shift-Tab` are used to navigate forward and backward through each accordion header and all focusable elements in the accordion should be included in the tab order.\n- `Enter` or `Space` expand and collapse each accordion panel. \n- Expanding a panel does not move keyboard focus, it stays on the header button. The user presses `Tab` to move focus to the first focusable element inside the panel, if any, or to move to the next header. \n- `Home` / `End` move focus to the first / last accordion header\n\n### Screen reader & assistive technology support\n\n- When a collapsed accordion header receives focus, a screen reader announces the button label, its role (button), and its state (”collapsed” or “expanded”)\n- When the user activates the button, the state change is announced immediately via the updated `aria-expanded` value\n- The expanded panel content is not automatically read. Expanding a panel does not move keyboard focus, it stays on the header button. The user presses Tab to move focus to the first focusable element inside the panel. Screen reader users can additionally navigate panel content using their virtual cursor (browse mode) without pressing Tab.\n\n## Consumer responsibilities\n\n### Semantic foundation: HTML and Aria labels\n\n- The accordion item heading should have an appropriate `aria-level` label, depending on its position in the hierarchy of the page.\n- Each accordion heading must have a unique and descriptive content. Vague content like “Read more” is inaccessible: the heading is all a screen reader user has to orient by when navigating.\n\n### Visual and motion \n\n- Ensure all items placed inside the accordion panel respect color contrast requirements.\n\n### **Keyboard navigation and focus order** \n\n- Avoid keyboard traps when adding components to the accordion panel. For example, the user expands an accordion, but is unable to tab to the next focusable element. \n- You can add a `Down Arrow` / `Up Arrow` option to move focus between accordion headers for accordion-heavy pages.\n\n### Screen reader & assistive technology support\n\n- Avoid placing deeply nested interactive components (nested accordions, complex forms) inside accordion panels without testing the full tab flow with a screen reader.\n\n\n\n## **Accessibility resources**\n\n- [W3C WAI-ARIA Accordion (Sections With Show/Hide Functionality)](https://www.w3.org/WAI/ARIA/apg/patterns/accordion/)\n- [WAI-ARIA Examples: Accordion](https://www.w3.org/WAI/ARIA/apg/patterns/accordion/examples/accordion/)\n- [Carbon design systems - Accordion accessibility](https://carbondesignsystem.com/components/accordion/accessibility)\n- Guidelines:\n - [1.3.1: Info and Relationships](https://www.w3.org/TR/WCAG22/#info-and-relationships)\n - [2.1.1: Keyboard](https://www.w3.org/TR/WCAG22/#keyboard)\n - [2.1.2: No Keyboard Trap](https://www.w3.org/TR/WCAG22/#no-keyboard-trap)\n\n\n\n## **References**\n\n- [https://github.com/alphagov/govuk-design-system-backlog/issues/1#issuecomment-995675898](https://github.com/alphagov/govuk-design-system-backlog/issues/1#issuecomment-995675898)\n- [https://www.nngroup.com/articles/accordions-complex-content/](https://www.nngroup.com/articles/accordions-complex-content/)\n- [https://www.smashingmagazine.com/2017/06/designing-perfect-accordion-checklist/](https://www.smashingmagazine.com/2017/06/designing-perfect-accordion-checklist/)";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:name "children";
|
|
@@ -56,7 +56,6 @@ ds:global.component.accordion a ds:Component;
|
|
|
56
56
|
ds:propertyType "choice";
|
|
57
57
|
ds:optional "false"
|
|
58
58
|
];
|
|
59
|
-
ds:hasSubcomponent ds:global.subcomponent.accordion-item;
|
|
60
59
|
ds:changeLog [
|
|
61
60
|
a ds:ChangeLogEntry;
|
|
62
61
|
ds:timestamp "2026-01-21T14:13:23.000+01:00";
|
|
@@ -64,188 +63,10 @@ ds:global.component.accordion a ds:Component;
|
|
|
64
63
|
], [
|
|
65
64
|
a ds:ChangeLogEntry;
|
|
66
65
|
ds:timestamp "2026-06-10T00:00:00.000+02:00";
|
|
67
|
-
ds:changeType "change"
|
|
68
|
-
ds:change "Added properties"
|
|
66
|
+
ds:changeType "change"
|
|
69
67
|
], [
|
|
70
68
|
a ds:ChangeLogEntry;
|
|
71
69
|
ds:timestamp "2026-06-26T00:00:00.000+02:00";
|
|
72
|
-
ds:changeType "change"
|
|
73
|
-
ds:change "Added accessibility guidelines"
|
|
70
|
+
ds:changeType "change"
|
|
74
71
|
];
|
|
75
|
-
ds:
|
|
76
|
-
a ds:TokenBinding;
|
|
77
|
-
ds:viaBlock ds:global.component.accordion;
|
|
78
|
-
ds:node "$root";
|
|
79
|
-
anatomy:styleKey "appearance.background";
|
|
80
|
-
anatomy:styleState "default";
|
|
81
|
-
ds:rank 1;
|
|
82
|
-
ds:consumesSymbol dt:surface.color.background
|
|
83
|
-
], [
|
|
84
|
-
a ds:TokenBinding;
|
|
85
|
-
ds:viaBlock ds:global.component.accordion;
|
|
86
|
-
ds:node "$root";
|
|
87
|
-
anatomy:styleKey "appearance.background";
|
|
88
|
-
anatomy:styleState "default";
|
|
89
|
-
ds:rank 2;
|
|
90
|
-
ds:consumesSymbol dt:color.background
|
|
91
|
-
], [
|
|
92
|
-
a ds:TokenBinding;
|
|
93
|
-
ds:viaBlock ds:global.component.accordion;
|
|
94
|
-
ds:node "$root";
|
|
95
|
-
anatomy:styleKey "appearance.radius";
|
|
96
|
-
anatomy:styleState "default";
|
|
97
|
-
ds:rank 1;
|
|
98
|
-
ds:consumesSymbol dt:dimension.radius.small
|
|
99
|
-
], [
|
|
100
|
-
a ds:TokenBinding;
|
|
101
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
102
|
-
ds:node "$root";
|
|
103
|
-
anatomy:styleKey "appearance.border.bottom.color";
|
|
104
|
-
anatomy:styleState "default";
|
|
105
|
-
ds:rank 1;
|
|
106
|
-
ds:consumesSymbol dt:color.border.muted
|
|
107
|
-
], [
|
|
108
|
-
a ds:TokenBinding;
|
|
109
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
110
|
-
ds:node "$root/header tab";
|
|
111
|
-
anatomy:styleKey "spacing.gap";
|
|
112
|
-
anatomy:styleState "default";
|
|
113
|
-
ds:rank 1;
|
|
114
|
-
ds:consumesSymbol dt:dimension.200
|
|
115
|
-
], [
|
|
116
|
-
a ds:TokenBinding;
|
|
117
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
118
|
-
ds:node "$root/header tab";
|
|
119
|
-
anatomy:styleKey "spacing.internal.block.start";
|
|
120
|
-
anatomy:styleState "default";
|
|
121
|
-
ds:rank 1;
|
|
122
|
-
ds:consumesSymbol dt:dimension.100
|
|
123
|
-
], [
|
|
124
|
-
a ds:TokenBinding;
|
|
125
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
126
|
-
ds:node "$root/header tab";
|
|
127
|
-
anatomy:styleKey "spacing.internal.block.end";
|
|
128
|
-
anatomy:styleState "default";
|
|
129
|
-
ds:rank 1;
|
|
130
|
-
ds:consumesSymbol dt:dimension.100
|
|
131
|
-
], [
|
|
132
|
-
a ds:TokenBinding;
|
|
133
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
134
|
-
ds:node "$root/header tab";
|
|
135
|
-
anatomy:styleKey "spacing.internal.inline.start";
|
|
136
|
-
anatomy:styleState "default";
|
|
137
|
-
ds:rank 1;
|
|
138
|
-
ds:consumesSymbol dt:dimension.200
|
|
139
|
-
], [
|
|
140
|
-
a ds:TokenBinding;
|
|
141
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
142
|
-
ds:node "$root/header tab";
|
|
143
|
-
anatomy:styleKey "spacing.internal.inline.end";
|
|
144
|
-
anatomy:styleState "default";
|
|
145
|
-
ds:rank 1;
|
|
146
|
-
ds:consumesSymbol dt:dimension.200
|
|
147
|
-
], [
|
|
148
|
-
a ds:TokenBinding;
|
|
149
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
150
|
-
ds:node "$root/header tab";
|
|
151
|
-
anatomy:styleKey "typography.color";
|
|
152
|
-
anatomy:styleState "default";
|
|
153
|
-
ds:rank 1;
|
|
154
|
-
ds:consumesSymbol dt:color.text
|
|
155
|
-
], [
|
|
156
|
-
a ds:TokenBinding;
|
|
157
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
158
|
-
ds:node "$root/header tab";
|
|
159
|
-
anatomy:styleKey "appearance.background";
|
|
160
|
-
anatomy:styleState "default";
|
|
161
|
-
ds:rank 1;
|
|
162
|
-
ds:consumesSymbol dt:surface.color.foreground.ghost
|
|
163
|
-
], [
|
|
164
|
-
a ds:TokenBinding;
|
|
165
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
166
|
-
ds:node "$root/header tab";
|
|
167
|
-
anatomy:styleKey "appearance.background";
|
|
168
|
-
anatomy:styleState "default";
|
|
169
|
-
ds:rank 2;
|
|
170
|
-
ds:consumesSymbol dt:color.foreground.ghost
|
|
171
|
-
], [
|
|
172
|
-
a ds:TokenBinding;
|
|
173
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
174
|
-
ds:node "$root/header tab";
|
|
175
|
-
anatomy:styleKey "appearance.background";
|
|
176
|
-
anatomy:styleState "hover";
|
|
177
|
-
ds:rank 1;
|
|
178
|
-
ds:consumesSymbol dt:color.foreground.ghost.hover
|
|
179
|
-
], [
|
|
180
|
-
a ds:TokenBinding;
|
|
181
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
182
|
-
ds:node "$root/header tab";
|
|
183
|
-
anatomy:styleKey "appearance.background";
|
|
184
|
-
anatomy:styleState "active";
|
|
185
|
-
ds:rank 1;
|
|
186
|
-
ds:consumesSymbol dt:color.foreground.ghost.active
|
|
187
|
-
], [
|
|
188
|
-
a ds:TokenBinding;
|
|
189
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
190
|
-
ds:node "$root/header tab/chevron";
|
|
191
|
-
anatomy:styleKey "size.width";
|
|
192
|
-
anatomy:styleState "default";
|
|
193
|
-
ds:rank 1;
|
|
194
|
-
ds:consumesSymbol dt:dimension.200
|
|
195
|
-
], [
|
|
196
|
-
a ds:TokenBinding;
|
|
197
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
198
|
-
ds:node "$root/header tab/chevron";
|
|
199
|
-
anatomy:styleKey "size.height";
|
|
200
|
-
anatomy:styleState "default";
|
|
201
|
-
ds:rank 1;
|
|
202
|
-
ds:consumesSymbol dt:dimension.200
|
|
203
|
-
], [
|
|
204
|
-
a ds:TokenBinding;
|
|
205
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
206
|
-
ds:node "$root/header tab/chevron/chevron glyph";
|
|
207
|
-
anatomy:styleKey "appearance.background";
|
|
208
|
-
anatomy:styleState "default";
|
|
209
|
-
ds:rank 1;
|
|
210
|
-
ds:consumesSymbol dt:color.icon
|
|
211
|
-
], [
|
|
212
|
-
a ds:TokenBinding;
|
|
213
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
214
|
-
ds:node "$root/header tab/heading";
|
|
215
|
-
anatomy:styleKey "typography.font";
|
|
216
|
-
anatomy:styleState "default";
|
|
217
|
-
ds:rank 1;
|
|
218
|
-
ds:consumesSymbol dt:typography.text.primary
|
|
219
|
-
], [
|
|
220
|
-
a ds:TokenBinding;
|
|
221
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
222
|
-
ds:node "$root/content panel";
|
|
223
|
-
anatomy:styleKey "typography.color";
|
|
224
|
-
anatomy:styleState "default";
|
|
225
|
-
ds:rank 1;
|
|
226
|
-
ds:consumesSymbol dt:color.text
|
|
227
|
-
], [
|
|
228
|
-
a ds:TokenBinding;
|
|
229
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
230
|
-
ds:node "$root/content panel";
|
|
231
|
-
anatomy:styleKey "spacing.internal.block.start";
|
|
232
|
-
anatomy:styleState "default";
|
|
233
|
-
ds:rank 1;
|
|
234
|
-
ds:consumesSymbol dt:dimension.100
|
|
235
|
-
], [
|
|
236
|
-
a ds:TokenBinding;
|
|
237
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
238
|
-
ds:node "$root/content panel";
|
|
239
|
-
anatomy:styleKey "spacing.internal.block.end";
|
|
240
|
-
anatomy:styleState "default";
|
|
241
|
-
ds:rank 1;
|
|
242
|
-
ds:consumesSymbol dt:dimension.100
|
|
243
|
-
], [
|
|
244
|
-
a ds:TokenBinding;
|
|
245
|
-
ds:viaBlock ds:global.subcomponent.accordion-item;
|
|
246
|
-
ds:node "$root/content panel";
|
|
247
|
-
anatomy:styleKey "spacing.internal.inline.end";
|
|
248
|
-
anatomy:styleState "default";
|
|
249
|
-
ds:rank 1;
|
|
250
|
-
ds:consumesSymbol dt:dimension.200
|
|
251
|
-
].
|
|
72
|
+
ds:hasSubcomponent ds:global.subcomponent.accordion-item.
|
|
@@ -4,17 +4,16 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.announcement a ds:Component;
|
|
6
6
|
ds:name "Announcement";
|
|
7
|
-
ds:summary "An announcement is a persistent, high-visibility UI block used to communicate time-sensitive or critical contextual information directly within a page. These are not triggered by specific system or user events, instead they are non-transient call-outs used for broad organizational updates, compliance warnings, or upcoming deadlines
|
|
7
|
+
ds:summary "An announcement is a persistent, high-visibility UI block used to communicate time-sensitive or critical contextual information directly within a page. These are not triggered by specific system or user events, instead they are non-transient call-outs used for broad organizational updates, compliance warnings, or upcoming deadlines.";
|
|
8
8
|
ds:anatomyDsl "---\n# TODO implementation: no reference in @canonical/react-ds-global or react-ds-global-form\n# A notation migration of the previous DSL: structure and bindings kept, values\n# migrated.\nnode:\n uri: global.component.announcement\n styles:\n layout.type: flex # was flow\n layout.direction: row # was horizontal\n layout.align: center\n layout.justify: center\n size.width: fill\n # Was `spacing.internal: spacing/medium` — the key is not in the roster (a\n # padding is bound per side) and no declared spacing semantic corresponds\n # to spacing/medium, so the binding is dropped.\n # Was `color/surface/announcement`; no symbol declares\n # color.background.announcement, so this is the declared background the\n # surface correspondence lands on.\n appearance.background: color.background\n edges:\n - node:\n role: message\n styles:\n # Was `typography.size: font/size/small` — dropped, since\n # typography.size admits dimension.* only and no dimension symbol\n # corresponds to font/size/small.\n # Was `typography.color: color/text/on-announcement` — dropped, since\n # no symbol declares color.text.onAnnouncement.\n typography.align: center\n relation:\n cardinality: \"1\"\n slotName: default";
|
|
9
9
|
ds:anatomyClassic "https://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=6716-1731&t=SzJR7XNUj9T63OWi-1\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=4508-81683&t=2fO23I8WsyT0YVJ1-4\n\n";
|
|
10
10
|
ds:usage "### When to use\n\n- When high-priority systemic updates are required to be visible to all users visiting a specific page or dashboard (e.g., maintenance windows or version deprecations).\n- When actionable deadlines must be highlighted to ensure compliance or task completion within a specific timeframe.\n- When contextual information needs to be anchored to a page to provide persistent awareness of a change in state or policy.\n\n### When not to use\n\n- When a transient response is required following a specific user action or a background system trigger.\n - Incorrect: Using an Announcement to confirm that a file has been successfully uploaded.\n - Remediation: Use a [NotificationToast](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-j1ObcSRMxi) message or [Notification](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-KVe8I1_VnA) component to provide immediate, temporary feedback for a single event.\n- When the information is non-critical and does not require the user’s immediate attention or action.\n - Incorrect: Placing a permanent \"Welcome to the new dashboard\" banner that remains after the user's first visit.\n - Remediation: Use an [Notification](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-KVe8I1_VnA) or a [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) for static, non-urgent supplemental details.\n- The information is specific to a single data entry or a specific line item within a list.\n - Incorrect: An announcement at the top of a table stating that \"Row 4 has an error.\"\n - Remediation: Use an Inline status indicator or an error state within the specific component to maintain local context.\n\n";
|
|
11
11
|
ds:guidelines "";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:changeLog [
|
|
15
15
|
a ds:ChangeLogEntry;
|
|
16
16
|
ds:timestamp "2026-03-20T00:00:00.000+01:00";
|
|
17
|
-
ds:change "splitting announcement from notification";
|
|
18
17
|
ds:changeType "decision"
|
|
19
18
|
];
|
|
20
19
|
ds:hasTokenBinding [
|
|
@@ -4,20 +4,20 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.badge a ds:Component;
|
|
6
6
|
ds:name "Badge";
|
|
7
|
-
ds:summary "A badge is a read-only visual indicator for numeric values. Usually, it is used in other components to show a number of elements contained in that component
|
|
7
|
+
ds:summary "A badge is a read-only visual indicator for numeric values. Usually, it is used in other components to show a number of elements contained in that component.";
|
|
8
8
|
ds:anatomyDsl "";
|
|
9
9
|
ds:anatomyClassic "\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2877-2620&t=mrOkyDfhQY9JZwMz-1\n\nStyling \n\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=4320-90095&t=mrOkyDfhQY9JZwMz-1";
|
|
10
10
|
ds:usage "The badge is a read-only visual indicator for numeric values, so only numbers are allowed inside it. The exception is using non numeric characters to show larger numbers than can be shown in the width of the badge. Use a “+” to indicate a larger number such as “999+” or letters to indicate numbers such as “2M” or “25k”.\n\nIt is often used in other components to show a number of elements contained in that component. Such as in tabs to indicate the amount of elements contained inside of it, or in a chip to indicate the amount of items which fall under that filter.\n\n### When to use\n\n- If you need to indicate a specific numeric value and you want to give it visual prominence. For example for:\n - Unread messages\n - Amount of items requiring attention\n - Activity indicators (e.g. comments)\n - Inventory counts\n - Total items in collections (items in cart)\n - Performance metrics (e.g. amount of errors in a log)\n- As part of other components such as navigation items, chips, tabs etc. to show some of the above mentioned metrics\n\n### When not to use\n\n- When text labels, categories, or status descriptors are used to provide qualitative (non-numeric) information.\n - Incorrect: Using a badge to display a status such as \"In Progress\" or a category like \"Design.\"\n - Remediation: Use a [Tag](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-osLY8UcQUp) component to represent non-numeric labels or categories.\n- When complex information is presented that requires additional explanation or supporting text to be understood.\n - Incorrect: Placing a standalone number in a Badge without a clear parent element, leaving the user to guess what the count represents.\n - Remediation: Ensure the badge is anchored to a specific UI element (like an filter item in a [Combobox](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-x_PYG_O4qD) or a [Chip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-N-fnT7n4mU)).\n- When a numeric value is intended to function as a primary button or a standalone clickable action.\n - Incorrect: Expecting a user to click directly on a small badge to open a detailed list or perform a task.\n - Remediation: Place the badge within an interactive parent component, such as a [Navigation](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-nkDiZdUMkV) Item, which then directs the user to the relevant destination (e.g., a [NotificationCenter](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-D0oz4mX_sm)).\n- When you need to display long pieces of information\n - Incorrect: \n- When you want users to filter information by clicking on the badge.\n - Incorrect: Use a badge as a clickable quick filter.\n - Remediation: Use a [Chip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-N-fnT7n4mU) instead.";
|
|
11
|
-
ds:guidelines "# Accessibility\n\n## **Color**\n\n- Use a modifier if it makes sense semantically for your use case.\n- Avoid using semantic color modifiers on top of colored backgrounds.\n- Ensure you don’t use colour as the only visual means of conveying information or an action.\n\n## **Aria labels**\n\n- Use `aria-label` to provide full context for screen readers. For example “999+ notifications unread”.\n- If the badge is used to represent a live status of some value, using `role=\"status\"` should be considered.\n\n## **Accessibility resources**\n\nApplicable WCAG guidelines:\n\n- [1.3.3: Sensory Characteristics](https://www.w3.org/TR/WCAG22/#sensory-characteristics)\n- [1.4.1: Use of Color](https://www.w3.org/TR/WCAG22/#use-of-color)\n- [3.1.4: Abbreviations](https://www.w3.org/TR/WCAG22/#abbreviations)";
|
|
11
|
+
ds:guidelines "# Accessibility\n\n## **Color**\n\n- Use a modifier if it makes sense semantically for your use case.\n- Avoid using semantic color modifiers on top of colored backgrounds.\n- Ensure you don’t use colour as the only visual means of conveying information or an action.\n\n## **Aria labels**\n\n- Use `aria-label` to provide full context for screen readers. For example “999+ notifications unread”.\n- If the badge is used to represent a live status of some value, using `role=\"status\"` should be considered.\n\n## **Accessibility resources**\n\nApplicable WCAG guidelines:\n\n- [1.3.3: Sensory Characteristics](https://www.w3.org/TR/WCAG22/#sensory-characteristics)\n- [1.4.1: Use of Color](https://www.w3.org/TR/WCAG22/#use-of-color)\n- [3.1.4: Abbreviations](https://www.w3.org/TR/WCAG22/#abbreviations)\n\n";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needscoredocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:name "criticality";
|
|
17
17
|
ds:summary "The component can comnsume the[Criticality](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-2diO06C-8N/_rui-jOei2P6iqD) modifier family:";
|
|
18
18
|
ds:propertyType "choice";
|
|
19
|
-
ds:
|
|
20
|
-
ds:
|
|
19
|
+
ds:optional "true";
|
|
20
|
+
ds:defaultValue "Default"
|
|
21
21
|
], [
|
|
22
22
|
a ds:Property;
|
|
23
23
|
ds:name "value";
|
|
@@ -40,12 +40,10 @@ ds:global.component.badge a ds:Component;
|
|
|
40
40
|
ds:changeLog [
|
|
41
41
|
a ds:ChangeLogEntry;
|
|
42
42
|
ds:timestamp "2026-02-13T08:00:00.000+01:00";
|
|
43
|
-
ds:change "added content - based on vanillas, changed minimal wording";
|
|
44
43
|
ds:changeType "change"
|
|
45
44
|
], [
|
|
46
45
|
a ds:ChangeLogEntry;
|
|
47
46
|
ds:timestamp "2026-04-09T00:00:00.000+02:00";
|
|
48
|
-
ds:change "linked the anatomy and styling boards";
|
|
49
47
|
ds:changeType "change"
|
|
50
48
|
];
|
|
51
49
|
ds:hasModifierFamily ds:global.modifier_family.criticality, ds:global.modifier_family.release.
|
|
@@ -4,31 +4,32 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.breadcrumbs a ds:Component;
|
|
6
6
|
ds:name "Breadcrumbs";
|
|
7
|
-
ds:summary "Breadcrumbs are a navigational aid that shows users their current location within a product’s information hierarchy. They provide a clear path from the root of the information architecture (IA) to the current page, allowing users to quickly understand where they are and easily navigate back to previous levels in the IA. Breadcrumbs should reflect the IA, not the user's path they took to arrive at the current page. They work best in websites or applications with multiple levels of hierarchy and are particularly useful when users might arrive at deep pages through search or external links
|
|
8
|
-
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Breadcrumbs/styles.css on .ds.breadcrumbs\n# The root <nav> carries no declaration of its own; every style below sits on\n# the `.list` <ol> the component renders inside it.\nnode:\n uri: global.component.breadcrumbs\n edges:\n - node:\n role: list\n styles:\n layout.type: flex\n layout.direction: row\n layout.wrap: wrap\n layout.align: center\n # Reset of the <ol> defaults.\n spacing.external.block.start: 0\n spacing.external.block.end: 0\n spacing.external.inline.start: 0\n spacing.external.inline.end: 0\n spacing.internal.block.start: 0\n spacing.internal.block.end: 0\n spacing.internal.inline.start: 0\n spacing.internal.inline.end: 0\n layout.listStyle: none\n spacing.gap.block: dimension.050 # row-gap reads --dimension-050 direct: 4px between wrapped rows\n edges:\n # Each item may be replaced per item by a consumer-supplied component\n # (BreadcrumbItem.Component) — kept from the previous notation, and\n # the reference confirms it.\n - switch:\n on: override\n cases:\n - uri: global.subcomponent.breadcrumbs-item\n - uri: $custom\n relation:\n cardinality: \"1..*\"\n slotName: default\n relation:\n cardinality: \"1\"\n slotName: default";
|
|
7
|
+
ds:summary "Breadcrumbs are a navigational aid that shows users their current location within a product’s information hierarchy. They provide a clear path from the root of the information architecture (IA) to the current page, allowing users to quickly understand where they are and easily navigate back to previous levels in the IA. Breadcrumbs should reflect the IA, not the user's path they took to arrive at the current page. They work best in websites or applications with multiple levels of hierarchy and are particularly useful when users might arrive at deep pages through search or external links.";
|
|
8
|
+
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Breadcrumbs/styles.css on .ds.breadcrumbs\n# The root <nav> carries no declaration of its own; every style below sits on\n# the `.list` <ol> the component renders inside it.\nnode:\n uri: global.component.breadcrumbs\n edges:\n - node:\n role: list\n styles:\n layout.type: flex\n layout.direction: row\n layout.wrap: wrap\n layout.align: center\n # Reset of the <ol> defaults.\n spacing.external.block.start: 0\n spacing.external.block.end: 0\n spacing.external.inline.start: 0\n spacing.external.inline.end: 0\n spacing.internal.block.start: 0\n spacing.internal.block.end: 0\n spacing.internal.inline.start: 0\n spacing.internal.inline.end: 0\n layout.listStyle: none\n spacing.gap.block: dimension.050 # row-gap reads --dimension-050 direct: 4px between wrapped rows\n edges:\n # Each item may be replaced per item by a consumer-supplied component\n # (BreadcrumbItem.Component) — kept from the previous notation, and\n # the reference confirms it.\n - switch:\n on: override\n cases:\n - uri: global.subcomponent.breadcrumbs-item\n - uri: $custom\n relation:\n cardinality: \"1..*\"\n slotName: default\n relation:\n cardinality: \"1\"\n slotName: default\n";
|
|
9
9
|
ds:anatomyClassic "\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2121-7411&t=ZjF1qUMIhrKHbBRE-1\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2481-2182&t=ZjF1qUMIhrKHbBRE-1";
|
|
10
10
|
ds:usage "Breadcrumbs are used to represent the hierarchical structure of content within an application or website, helping users understand where they are in the information architecture (IA). They provide a visual trail of the user's current location and offer quick navigation to other levels in the IA. \n\nBreadcrumbs reflect the site's structure, not the path a user took to arrive at the current page. They show where you are in the hierarchy, not how you got there.\n\nThey are most effective in applications or websites with substantial content organized hierarchically across two or more levels. The more complex your information architecture, the more valuable breadcrumbs become for helping users maintain context and navigate efficiently.\n\n### When to use\n\n- In applications or websites with multiple levels of hierarchical content structure\n- To help users understand their current location within a deep information architecture\n- To provide quick navigation back to higher levels in the IA\n- When the relationship between pages follows a clear parent-child hierarchy\n- As a secondary navigation aid to complement your primary navigation\n\n### When not to use\n\n- On websites or applications with only a single level of hierarchy.\n - Incorrect: Displaying a breadcrumb that only shows \"Home\" on every page of a single-page application.\n - Remediation: Remove the component entirely, as the global navigation or page header is sufficient for navigation.\n- On the root of your site or app (as there are no higher levels to navigate to).\n - Incorrect: Placing a breadcrumb on the home screen where there are no parent levels to navigate back to.\n - Remediation: Omit the component entirely.\n- As a replacement for primary navigation. \n - Incorrect: Removing the [Navigation](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-_D-3DMJEui) (side navigation or top navigation) and forcing users to rely on breadcrumbs to find their way around the site.\n - Remediation: Use the right [Navigation](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-nkDiZdUMkV) pattern for primary orientation. Breadcrumbs are always secondary and should enrich, not replace, your main navigation.\n- To track a user's browsing history or the path they took through your application.\n - Incorrect: Showing a path like \"Home > Search > Profile > Search\" based on the user's back-and-forth browsing behavior.\n - Remediation: Use the browser's back button or a dedicated \"Back to results\" link to handle session-based movement.\n- As a progress indicator for multi-step processes.\n - Incorrect: Using Breadcrumbs to show steps 1, 2, and 3 of a checkout or registration form.\n - Remediation: Use a component able to represent progress to clearly communicate the sequence and status of a multi-step task.\n\n";
|
|
11
11
|
ds:guidelines "- use current page breadcrumb item as the last level of hierarchy, indicating the current location in the navigation structure\n- use parent page breadcrumb items for the higher levels of navigation from the current location in the navigation structure \n\n\nOverflow\n\n- Ideally breadcrumbs should be used in the design in a way where they do not overflow. But if they do for some reason overflow they should overflow in the following way: A 4px vertical distance. The slash should always be at the start of the second line (and not at the end of the first line). \n \n\n\n\n\n# Accessibility\n\n## **How it works**\n\nIt establishes a landmark on the page which assists the user in understanding where they currently are and which pages exist in the current page’s hierarchical order.\n\nIt comprises a set of links structured using an ordered list. A `nav` element using `aria-label=\"Breadcrumbs\"` identifies the structure as a breadcrumb trail and makes it a navigation landmark so that it is easy to locate. It can be navigated via keyboard using the `Tab` key.\n\nTo prevent screen reader announcement of the visual separators between links, they are added via CSS. The separators are part of the visual presentation that signifies the breadcrumb trail, which is already semantically represented by the `nav` element.\n\n## **Considerations**\n\nThis component strives to follow [WCAG 2.2 (level AA) guidelines](https://www.w3.org/TR/WCAG22/), and care must be taken to ensure this effort is maintained when the component is implemented across other projects. This section offers advice to that effect:\n\n- The breadcrumb text should reflect the page title accurately and concisely.\n- The breadcrumb should remain in the same relative order and location on each web page.\n- The breadcrumb indicating the current page should be visually distinct from the preceding breadcrumbs.\n- If the breadcrumb reflecting the current page is a link, it should have an `aria-current=\"page\"` attribute.\n\n## **Resources**\n\n- [WAI-ARIA practices: Breadcrumbs](https://www.w3.org/WAI/ARIA/apg/patterns/breadcrumb/)\n- [WAI-ARIA practices: Breadcrumb example](https://www.w3.org/WAI/ARIA/apg/patterns/breadcrumb/examples/breadcrumb/)\n- Guidelines:\n - [2.4.4: Link Purpose (in Context)](https://www.w3.org/TR/WCAG22/#link-purpose-in-context)\n - [3.2.3: Consistent Navigation](https://www.w3.org/TR/WCAG22/#consistent-navigation)";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:name "children";
|
|
17
17
|
ds:propertyType "node";
|
|
18
18
|
ds:optional "false"
|
|
19
19
|
];
|
|
20
|
-
ds:hasSubcomponent ds:global.subcomponent.breadcrumbs-item;
|
|
21
20
|
ds:changeLog [
|
|
22
21
|
a ds:ChangeLogEntry;
|
|
23
22
|
ds:timestamp "2026-01-19T00:00:00.000+01:00";
|
|
24
|
-
ds:change "We discussed whether the Breadcrumbs is a Component or a Pattern (etc...).\nWe decided for it being a Component because there is a usual way to do it (i.e. non-opinionated)";
|
|
25
23
|
ds:changeType "change"
|
|
26
24
|
], [
|
|
27
25
|
a ds:ChangeLogEntry;
|
|
28
26
|
ds:timestamp "2026-07-06T00:00:00.000+02:00";
|
|
29
|
-
ds:change "Overflow behaviour with ellipsis could be considered as a refinement for this component";
|
|
30
27
|
ds:changeType "decision"
|
|
28
|
+
], [
|
|
29
|
+
a ds:ChangeLogEntry;
|
|
30
|
+
ds:timestamp "2026-10-14T00:00:00.000+02:00"
|
|
31
31
|
];
|
|
32
|
+
ds:hasSubcomponent ds:global.subcomponent.breadcrumbs-item;
|
|
32
33
|
ds:hasTokenBinding [
|
|
33
34
|
a ds:TokenBinding;
|
|
34
35
|
ds:viaBlock ds:global.component.breadcrumbs;
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.button a ds:Component;
|
|
6
6
|
ds:name "Button";
|
|
7
|
-
ds:summary "Buttons trigger actions within an interface, typically involving data transformation or manipulation. They provide clear visual indicators of the primary actions users can perform on a page or section
|
|
8
|
-
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Button/styles.css on .ds.button\n# Every list is the reference's own var() chain, in order. The button reads the\n# modifier CHANNEL generically — it knows no particular importance class — so\n# the channel is consumed by name wherever the implementation reads it.\nnode:\n uri: global.component.button\n styles:\n layout.position: relative\n layout.type: inline-flex\n layout.align: center\n layout.justify: center\n interaction.cursor: pointer\n interaction.cursor@disabled: not-allowed\n appearance.border.style: solid\n appearance.border.width: dimension.stroke.thickness.medium\n # The primary foreground fills the background, through the channel that\n # importance provides it on.\n # reads --modifier-surface first; no symbol declares it.\n appearance.background: [modifier.color.foreground.primary, color.foreground.primary]\n # reads --modifier-surface-hover / -active / -disabled first; no symbol\n # declares any of the three.\n appearance.background@hover: color.foreground.primary.hover\n appearance.background@active: color.foreground.primary.active\n appearance.background@disabled: color.foreground.primary.disabled\n # The border is always present at the nominal width and colour-mixed to\n # transparent when the importance hides it; --modifier-outline is the 0/1\n # flag that does the mixing, and no symbol declares it.\n appearance.border.color: [modifier.color.border, color.border.highlighted, color.border]\n # reads --modifier-color-border-disabled first; no symbol declares it.\n appearance.border.color@disabled: color.border.highlighted.disabled\n typography.color: [modifier.color.text, color.text]\n # reads --modifier-color-text-disabled first; no symbol declares it.\n typography.color@disabled: color.text.disabled\n
|
|
7
|
+
ds:summary "Buttons trigger actions within an interface, typically involving data transformation or manipulation. They provide clear visual indicators of the primary actions users can perform on a page or section.";
|
|
8
|
+
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Button/styles.css on .ds.button\n# Every list is the reference's own var() chain, in order. The button reads the\n# modifier CHANNEL generically — it knows no particular importance class — so\n# the channel is consumed by name wherever the implementation reads it.\nnode:\n uri: global.component.button\n styles:\n layout.position: relative\n layout.type: inline-flex\n layout.align: center\n layout.justify: center\n interaction.cursor: pointer\n interaction.cursor@disabled: not-allowed\n appearance.border.style: solid\n appearance.border.width: dimension.stroke.thickness.medium\n # The primary foreground fills the background, through the channel that\n # importance provides it on.\n # reads --modifier-surface first; no symbol declares it.\n appearance.background: [modifier.color.foreground.primary, color.foreground.primary]\n # reads --modifier-surface-hover / -active / -disabled first; no symbol\n # declares any of the three.\n appearance.background@hover: color.foreground.primary.hover\n appearance.background@active: color.foreground.primary.active\n appearance.background@disabled: color.foreground.primary.disabled\n # The border is always present at the nominal width and colour-mixed to\n # transparent when the importance hides it; --modifier-outline is the 0/1\n # flag that does the mixing, and no symbol declares it.\n appearance.border.color: [modifier.color.border, color.border.highlighted, color.border]\n # reads --modifier-color-border-disabled first; no symbol declares it.\n appearance.border.color@disabled: color.border.highlighted.disabled\n typography.color: [modifier.color.text, color.text]\n # reads --modifier-color-text-disabled first; no symbol declares it.\n typography.color@disabled: color.text.disabled\n # The label is the typography.text.primary composite: family, size,\n # weight and letter-spacing all come from it.\n typography.font: typography.text.primary\n typography.align: center\n typography.decoration: none\n spacing.gap: dimension.100 # --button-gap, between the icon and the label\n # 16px each side, the action inset the button plays. A leading icon tightens\n # the start side to --dimension-100, which is a conditional the anatomy does\n # not carry.\n spacing.internal.inline.start: dimension.200 # --button-padding-inline-start\n spacing.internal.inline.end: dimension.200 # --button-padding-inline-end\n motion.property: \"background-color, color, border-color\"\n # The transition reads --motion-duration-fast and --motion-easing-standard;\n # both bindings are dropped because no symbol declares either name and\n # neither var() carries a literal fallback.\n # reads --focus-outline-width first; no symbol declares it, so the chain's\n # own literal is what is left.\n appearance.outline.width@focus: 2px\n appearance.outline.style@focus: solid\n appearance.outline.color@focus: [modifier.color.focusRing, color.focusRing, currentColor]\n # reads --focus-outline-offset first; no symbol declares it.\n appearance.outline.offset@focus: 2px\n # The `.link` variant (transparent chrome, underlined link text) is the\n # separate ButtonLink block (ds:global.component.button_link), not a case\n # of this tree.\n edges:\n - node:\n role: icon\n styles:\n layout.type: inline-flex\n layout.align: center\n layout.alignSelf: center\n layout.justify: center\n layout.flex.shrink: 0\n # reads --icon-size, a component-local size declared as 1em at :root.\n size.width: 1em\n size.height: 1em\n # The icon has its own colour channel, distinct from the label's, and\n # falls through to the colour it inherits.\n typography.color: [modifier.color.icon, modifier.color.text, currentColor]\n # reads --modifier-color-icon-disabled first; no symbol declares it.\n typography.color@disabled: color.icon.disabled\n relation:\n cardinality: \"0..1\"\n slotName: icon\n - node:\n role: label text\n relation:\n cardinality: \"1\"\n slotName: label\n - node:\n role: loading spinner\n styles:\n layout.position: absolute\n layout.type: inline-flex\n layout.align: center\n layout.justify: center\n layout.offset.top: 0\n layout.offset.right: 0\n layout.offset.bottom: 0\n layout.offset.left: 0\n relation:\n # Present only while loading, when the icon and the label stay in the\n # DOM at `visibility: hidden` so the button keeps its width.\n cardinality: \"0..1\"";
|
|
9
9
|
ds:anatomyClassic "https://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2093-5214&t=hZuG5NMGmwurwbXa-1\n\nStyling \nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2378-8459&t=hZuG5NMGmwurwbXa-1";
|
|
10
10
|
ds:usage "Use buttons for meaningful interactions that transform, submit, or manipulate data, such as: \n\n- Submitting forms\n- Deleting items\n- Processing payments\n- Updating settings\n\nActions represent state changes in the application rather than simple navigation.\n\nButtons help establish clear visual hierarchy by signaling the most important actions available to users at any given moment. This hierarchy is critical to effective interface design. Users should immediately understand what action they're expected to take. \n\nWhile buttons should primarily trigger actions, they can occasionally be used for navigation when the context demands it. This is most appropriate for high-priority conversion points, such as call-to-action buttons in hero sections that direct users to, for example, sign-up flows or landing pages. In these cases, the button represents a key user journey rather than standard navigation. \n\n### When to use\n\n- For actions that transform, submit, or manipulate data\n- To draw attention to the most important action on a page or section\n- For high-priority conversion points or key user journeys\n- When the interaction represents a meaningful state change in the application\n\n### When not to use\n\n- For simple navigation between pages (use links instead)\n- When you already have a primary button visible in the current viewport (consider using secondary or tertiary button styles instead)\n- For multiple competing actions of equal importance (reconsider your information architecture and prioritize one clear primary action)\n\n### Call to actions\n\nAlmost always, there is an action that the user needs to perform on a page. Guide users toward the main action within the user flow that you have designed. **This means being opinionated about what action the user should be performing and using that as the primary call to action.** Rather than presenting users with an overwhelming array of choices, you should clearly signal the intended path forward. As a result, the main action on any given page should, in most cases, be represented by a primary button.\n\nBe deliberate about the number of calls-to-action you present. Each additional CTA dilutes the user's focus and makes it harder for them to decide what to do. Ideally, limit pages to as few CTAs as possible so users clearly understand their intended path forward. **As a rule of thumb, there should almost never be more than one primary button visible in the user's viewport at a time.** \n\nWhen multiple primary buttons compete for attention simultaneously, the hierarchy collapses and users face decision paralysis. If you find yourself needing multiple primary actions in view, reconsider whether they're all truly primary and whether some could be deprioritized or removed entirely.";
|
|
11
|
-
ds:guidelines "# Button hierarchy\n\nEach button variant signals a different level of emphasis. Choose the variant that matches the role of the action on the page.\n\n\n\n**Primary**\n\nUse the primary variant for primary calls to action. Typical examples include the main action on an app’s table page, the hero call to action on a website. It also confirms non-destructive actions, such as submitting a form or proceeding to the next step.\n\n**Secondary**\n\nUse the secondary variant for secondary actions paired with a primary button. Apply it when no single action on the page should dominate. Use it when all actions share the same level of importance, or when the user may or may not choose to act.\n\n**Tertiary**\n\nUse the tertiary variant for tertiary actions paired with a more prominent button, such as “Back” or “Cancel”. It holds the lowest level of emphasis, so only use it when the element is clearly a button. In practice, this means pairing it with other buttons. Icon-only buttons are often base buttons.\n\n \n**Brand**\n\nUse the brand variant for actions and call to actions that live in an editorial setting, like sites or documentation tiers. All button levels are available as a brand version.\n\n**Anticipation modifier family**\n\n**Constructive**\n\nUse the constructive modifier for buttons whose actions create something new, such as a new instance, a new machine, or a new row, if you need to emphasize the constructive/additive nature of it. \n \n**Destructive**\n\nUse the the destructive modifier to warn the user that a destructive, irreversible action will be triggered.\n\n\n\n**Combinations**\n\nShow at most one primary button, whether default or using modifiers, in a given view. Supplement it with secondary or tertiary buttons as needed, and make sure the primary button reflects the main action you want the user to take. If all actions share the same level of importance and you do not want to direct the user to a specific one, use secondary buttons. Always pair tertiary buttons with other buttons. \n\n\n# Button order and alignment\n\
|
|
11
|
+
ds:guidelines "# Button hierarchy\n\nEach button variant signals a different level of emphasis. Choose the variant that matches the role of the action on the page.\n\n\n\n**Primary**\n\nUse the primary variant for primary calls to action. Typical examples include the main action on an app’s table page, the hero call to action on a website. It also confirms non-destructive actions, such as submitting a form or proceeding to the next step.\n\n**Secondary**\n\nUse the secondary variant for secondary actions paired with a primary button. Apply it when no single action on the page should dominate. Use it when all actions share the same level of importance, or when the user may or may not choose to act.\n\n**Tertiary**\n\nUse the tertiary variant for tertiary actions paired with a more prominent button, such as “Back” or “Cancel”. It holds the lowest level of emphasis, so only use it when the element is clearly a button. In practice, this means pairing it with other buttons. Icon-only buttons are often base buttons.\n\n \n**Brand**\n\nUse the brand variant for actions and call to actions that live in an editorial setting, like sites or documentation tiers. All button levels are available as a brand version.\n\n**Anticipation modifier family**\n\n**Constructive**\n\nUse the constructive modifier for buttons whose actions create something new, such as a new instance, a new machine, or a new row, if you need to emphasize the constructive/additive nature of it. \n \n**Destructive**\n\nUse the the destructive modifier to warn the user that a destructive, irreversible action will be triggered.\n\n\n\n**Combinations**\n\nShow at most one primary button, whether default or using modifiers, in a given view. Supplement it with secondary or tertiary buttons as needed, and make sure the primary button reflects the main action you want the user to take. If all actions share the same level of importance and you do not want to direct the user to a specific one, use secondary buttons. Always pair tertiary buttons with other buttons. \n\n\n# Button order and alignment\n\n~~Right-align buttons when:~~\n\n- ~~The action moves the user forward in a flow, such as forms, wizards, or checkout~~\n- ~~The button appears in a modal dialog or confirmation window~~\n- ~~The button appears in a settings or configuration panel~~\n- ~~The button completes or submits something~~\n- ~~The position follows the natural end of task after scanning content left to right~~\n\n~~Left-align buttons when:~~\n\n- ~~The button continues left-aligned content, such as a hero, card, or marketing block~~\n- ~~The action is a “Back” or “Cancel” that returns users to a previous state~~\n- ~~The button appears in an article page or a content-heavy context where buttons are secondary to the text~~\n\n# [IconButton](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-1G-7Wdwa2L) \n\nWhen space is limited and the actions have recognizable icons, buttons may use an icon without text. Reserve for very common actions such as delete, edit, or close. Always pair an icon-only button with a [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) that states the action clearly. Add a delay to the [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) so it does not interrupt the user.\n\n# When to disable buttons\n\nYou should keep buttons enabled by default so users always know how to proceed. Disable a button only when the action is clearly unavailable.\n\nYou may disable a button, but you must ensure users understand why it is disabled and how to move forward. Pair the disabled button with a [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ll01ZL3SIS) that explains why the action is unavailable.\n\nThis matters most for form submissions. Users may miss a required field in longer or more complex forms, so a disabled submit button can leave them stuck without a clear reason. If you disable the button, make the cause visible; otherwise, keep it enabled and let validation feedback guide users to the mistake.\n\nThe same applies to external constraints like permissions, plan limits, or missing prerequisites. Where you can, offer an alternative that unblocks the user. For example, if an empty state depends on a prerequisite, show the action that completes the prerequisite instead of a disabled button.\n\n# Dual buttons\n\nOpposing actions can sometimes be combined into a single button, such as play and pause in a video player. The icon or label should reflect the action that will occur when the user presses the button. If the media is playing, show the pause icon. If it is paused, show the play icon. This aligns with user intent, because users select an action, not a status.\n\n# Text in buttons\n\nWrite button labels as a verb plus noun in sentence case, with no punctuation. Use clear, action-oriented language that names the outcome, such as \"Get Ubuntu Pro\" rather than a generic \"Submit\". When a button relates to a nearby heading, match the language so the action reads as a direct answer. For example, on a card with the heading \"Would you like to save your changes?\", label the button \"Save changes\".\n\n# Accessibility\n\n## Built-in\n\n### Semantic foundation: HTML and Aria labels\n\n- cIn some contexts, it may be necessary to indicate to the user that a button is in a pressed state, such as when a button opens a contextual menu. This can be done by adding `aria-pressed=\"true\"` to the button with JavaScript when the button is clicked, and removed when necessary.\n- Loading buttons use `aria-busy=\"true\"` to indicate loading/pending state to screen readers. While loading, the interactions are blocked and the componet uses `aria-disabled=\"true\"` to indicate the element is not currently interactive. The buttons should not become `disabled` while loading, because this would drop focus for keyboard/screen reader users. \n\n### Visual and motion\n\n- Text color ensures 4.5:1 contrast with the foreground, and foreground color ensures3 :1 contrast with the background\n- Animations are disabled when `prefers-reduced-motion: reduce` is set\n\n### \n\n## Consumer responsibilities\n\n### **Keyboard navigation and focus order** \n\n- As the button is interactable it should be focused.\n- After the button is activated ensure the focus is set correctly based on the type of action the button performs. See [W3C WAI-ARIA Authoring Practices Button Design Pattern](https://www.w3.org/WAI/ARIA/apg/patterns/button/) for a list of examples.\n- Once focussed, the associated action should be executed if the `Enter` or `Space` key is pressed.\n\n\n\n## Accessibility references\n\nFor loading/disabled settings:\n\n- [MDN reference](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-busy)\n- [Example of another DS that does this](https://diceui.com/docs/utilities/radix/pending#accessibility)";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:name "content";
|
|
@@ -50,12 +50,10 @@ ds:global.component.button a ds:Component;
|
|
|
50
50
|
ds:changeLog [
|
|
51
51
|
a ds:ChangeLogEntry;
|
|
52
52
|
ds:timestamp "2026-02-20T00:00:00.000+01:00";
|
|
53
|
-
ds:change "Decided to split the button into multiple components: the select and the dropdown became their own components. This means there is no need to have a right side icon for the button";
|
|
54
53
|
ds:changeType "decision"
|
|
55
54
|
], [
|
|
56
55
|
a ds:ChangeLogEntry;
|
|
57
56
|
ds:timestamp "2026-03-06T11:00:00.000+01:00";
|
|
58
|
-
ds:change "In order to disambiguate the button and the button link components there was a decision made in the contribution process meeting to keep the components together, until the discussion of affordances (and potentially use cases) have been finalized. In the documentation review meeting we came to the same decision.";
|
|
59
57
|
ds:changeType "decision"
|
|
60
58
|
];
|
|
61
59
|
ds:hasModifierFamily ds:global.modifier_family.anticipation, ds:global.modifier_family.importance;
|
|
@@ -164,22 +162,6 @@ ds:global.component.button a ds:Component;
|
|
|
164
162
|
anatomy:styleState "disabled";
|
|
165
163
|
ds:rank 1;
|
|
166
164
|
ds:consumesSymbol dt:color.text.disabled
|
|
167
|
-
], [
|
|
168
|
-
a ds:TokenBinding;
|
|
169
|
-
ds:viaBlock ds:global.component.button;
|
|
170
|
-
ds:node "$root";
|
|
171
|
-
anatomy:styleKey "typography.weight";
|
|
172
|
-
anatomy:styleState "default";
|
|
173
|
-
ds:rank 1;
|
|
174
|
-
ds:consumesSymbol dt:typography.weight.medium
|
|
175
|
-
], [
|
|
176
|
-
a ds:TokenBinding;
|
|
177
|
-
ds:viaBlock ds:global.component.button;
|
|
178
|
-
ds:node "$root";
|
|
179
|
-
anatomy:styleKey "typography.size";
|
|
180
|
-
anatomy:styleState "default";
|
|
181
|
-
ds:rank 1;
|
|
182
|
-
ds:consumesSymbol dt:dimension.size.fontSize.300
|
|
183
165
|
], [
|
|
184
166
|
a ds:TokenBinding;
|
|
185
167
|
ds:viaBlock ds:global.component.button;
|
|
@@ -187,7 +169,7 @@ ds:global.component.button a ds:Component;
|
|
|
187
169
|
anatomy:styleKey "typography.font";
|
|
188
170
|
anatomy:styleState "default";
|
|
189
171
|
ds:rank 1;
|
|
190
|
-
ds:consumesSymbol dt:typography.text.
|
|
172
|
+
ds:consumesSymbol dt:typography.text.primary
|
|
191
173
|
], [
|
|
192
174
|
a ds:TokenBinding;
|
|
193
175
|
ds:viaBlock ds:global.component.button;
|
|
@@ -4,40 +4,35 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.card a ds:Component;
|
|
6
6
|
ds:name "Card";
|
|
7
|
-
ds:summary "The card is a container that is designed to represent data objects that share the same structure. Unlike the more flexible [Tile](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eThhoLZg3Y), a card is designed to have multiple units displayed beside one another. Because of this, the card has a predictable structure that allows the user to compare attributes across data objects
|
|
7
|
+
ds:summary "The card is a container that is designed to represent data objects that share the same structure. Unlike the more flexible [Tile](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eThhoLZg3Y), a card is designed to have multiple units displayed beside one another. Because of this, the card has a predictable structure that allows the user to compare attributes across data objects.";
|
|
8
8
|
ds:anatomyDsl "---\n# Authored 2026-09-13 from @canonical/react-ds-global src/lib/component/Card/styles.css on .ds.card\n# The Card is not a surface: it sets no background, so it reads flush on\n# whatever surface it sits on and stays delimited by its border, its radius and\n# the dividers between its sections. It is always a grid participant and a ROW\n# SUBGRID over four fixed section tracks — image, header, content, footer.\nnode:\n uri: global.component.card\n styles:\n layout.type: grid\n layout.grid.rows: subgrid\n layout.grid.columns: \"minmax(0, 1fr)\"\n # Spans --card-span parent columns (a component-local count, default 1) and\n # its own four section rows.\n layout.grid.column: \"span 1\"\n layout.grid.row: \"span 4\"\n appearance.border.width: dimension.stroke.thickness.medium\n appearance.border.style: solid\n appearance.border.color: color.border.muted\n appearance.radius: dimension.radius.medium\n # Clips section corners (a full-bleed image) to the card radius.\n layout.overflow: hidden\n edges:\n # Each section sits on its fixed row track and spans the card's single\n # column. An absent section leaves its track empty for this card only.\n # Image, content and footer draw a divider on their block-end edge when\n # they are not the last section; the header draws none, so title and\n # content read as one region.\n - node:\n uri: global.subcomponent.card-image\n styles:\n layout.grid.row: \"1\"\n layout.grid.column: \"1 / -1\"\n appearance.border.bottom.color: color.border.muted\n relation:\n cardinality: \"0..1\"\n slotName: media\n - node:\n uri: global.subcomponent.card-header\n styles:\n layout.grid.row: \"2\"\n layout.grid.column: \"1 / -1\"\n # Collapsed to raw 0 when a content section follows, to close the\n # header/content seam — unthemeable by design.\n spacing.internal.block.end: 0\n relation:\n cardinality: \"0..1\"\n slotName: header\n - node:\n uri: global.subcomponent.card-content\n styles:\n layout.grid.row: \"3\"\n layout.grid.column: \"1 / -1\"\n appearance.border.bottom.color: color.border.muted\n relation:\n cardinality: \"1\"\n slotName: default\n - node:\n uri: global.subcomponent.card-footer\n styles:\n layout.grid.row: \"4\"\n layout.grid.column: \"1 / -1\"\n appearance.border.bottom.color: color.border.muted\n relation:\n cardinality: \"0..1\"\n slotName: footer";
|
|
9
9
|
ds:anatomyClassic "https://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=3104-11741&t=ZeOhPBVqjN81UglM-1\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2124-397&t=2fO23I8WsyT0YVJ1-4";
|
|
10
10
|
ds:usage "Cards are intended for use in \"collection-based\" views. They are suitable for grids and galleries where multiple data objects of the same type are displayed next to each other. \n\n### When to use\n\n- When you have a repeating data structure with a uniform set of attributes that requires high legibility across many instances.\n- When the container itself acts as a toggle or a checkbox for selecting an item from a group. (radio card) // should be linking to forms\n- When the user behavior is focused on exploration of options, rather than searching for an already identified item of the group. Cards facilitate consuming the information of an individual data object, in contrast with a table where the emphasis is on comparison and ability to scan. \n- When building a responsive table, on small viewports, the designer can choose between horizontal scroll, or converting table rows into cards. \n\n### When not to use\n\n- When a single piece of information is being highlighted on a page without any \"peers\".\n - Incorrect: A single card floating in the middle of a dashboard to show \"Total users\".\n - Remediation: Use a [Tile](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eThhoLZg3Y) component designed for individual metric display.\n- When the user needs to perform deep data analysis or multi-column sorting on regular size pages.\n - Incorrect: Forcing 50 columns of data into a small card format.\n - Remediation: Use a [Table](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-Olq5LYSopF) to allow for better horizontal scanning and sorting of specific values.";
|
|
11
11
|
ds:guidelines "Styling\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2124-397&t=ch8BFFPUe9gCvMdg-1";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:optional "false"
|
|
17
17
|
];
|
|
18
|
-
ds:hasSubcomponent ds:global.subcomponent.card-footer, ds:global.subcomponent.card-thumbnail, ds:global.subcomponent.card-content, ds:global.subcomponent.card-image, ds:global.subcomponent.card-header;
|
|
19
18
|
ds:changeLog [
|
|
20
19
|
a ds:ChangeLogEntry;
|
|
21
20
|
ds:timestamp "2025-12-05T00:00:00.000+01:00";
|
|
22
|
-
ds:change "testing the structure";
|
|
23
21
|
ds:changeType "change"
|
|
24
22
|
], [
|
|
25
23
|
a ds:ChangeLogEntry;
|
|
26
24
|
ds:timestamp "2025-12-08T00:00:00.000+01:00";
|
|
27
|
-
ds:change "Another test";
|
|
28
25
|
ds:changeType "change"
|
|
29
26
|
], [
|
|
30
27
|
a ds:ChangeLogEntry;
|
|
31
28
|
ds:timestamp "2026-04-06T00:00:00.000+02:00";
|
|
32
|
-
ds:change "open question: in vanilla we had the responsive behavior of tables converting into cards when appropriate. we should have this behavior also for pragma. There should be a linkage between table and data table and cards. Adrian: Would recommend against it for now as it adds complexity (Which tables get turned into cards ? How should responsiveness be enforced ?)\n→ I would recommend adding to the decision log as defered; Diana: This was the design decision - it should be an opt-in responsive behaviour. we can link to “table” and “data table” for more info";
|
|
33
29
|
ds:changeType "decision"
|
|
34
30
|
], [
|
|
35
31
|
a ds:ChangeLogEntry;
|
|
36
32
|
ds:timestamp "2026-04-06T00:00:00.000+02:00";
|
|
37
|
-
ds:change "This usage guideline stays in the general card, until radio cards get separated into their own components: When the container itself acts as a toggle or a checkbox for selecting an item from a group. (radio card) // should be linking to form ";
|
|
38
33
|
ds:changeType "change"
|
|
39
34
|
];
|
|
40
|
-
ds:
|
|
35
|
+
ds:hasSubcomponent ds:global.subcomponent.card-footer, ds:global.subcomponent.card-thumbnail, ds:global.subcomponent.card-content, ds:global.subcomponent.card-image, ds:global.subcomponent.card-header;
|
|
41
36
|
ds:hasTokenBinding [
|
|
42
37
|
a ds:TokenBinding;
|
|
43
38
|
ds:viaBlock ds:global.component.card;
|
|
@@ -10,7 +10,7 @@ ds:global.component.checkbox_field a ds:Component;
|
|
|
10
10
|
ds:usage "A labelled binary choice within a form.\n\n\n\n### When to use\n\n- A single opt-in or acceptance (e.g. agree to terms).\n\n- Toggling one independent option whose value is committed with the form.\n\n\n\n### When not to use\n\n- Several related, mutually-exclusive options — use [RichChoicesField](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-OE7Ygmz_vT) or [ChoicesField](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-IFk-NNRL3C) .\n\n- A setting that takes effect immediately on toggle — use [SwitchField](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-vZovGhu5_P) .";
|
|
11
11
|
ds:guidelines "";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needscoredocumentation;
|
|
14
14
|
ds:hasTokenBinding [
|
|
15
15
|
a ds:TokenBinding;
|
|
16
16
|
ds:viaBlock ds:global.component.checkbox_field;
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.chip a ds:Component;
|
|
6
6
|
ds:name "Chip";
|
|
7
|
-
ds:summary "A chip is a compact, interactive component used to represent an attribute, entity, while facilitating secondary actions. Chips elevate specific information in the visual hierarchy, such as categories or selected tags, allowing users to trigger contextual behaviors like filtering, triggering a [Popover](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-i-62pvfoOF), selection, or dismissal. Unlike the [Tag](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-osLY8UcQUp), chips are always actionable. Chips should complement, rather than replace, the primary page actions
|
|
7
|
+
ds:summary "A chip is a compact, interactive component used to represent an attribute, entity, while facilitating secondary actions. Chips elevate specific information in the visual hierarchy, such as categories or selected tags, allowing users to trigger contextual behaviors like filtering, triggering a [Popover](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-i-62pvfoOF), selection, or dismissal. Unlike the [Tag](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-osLY8UcQUp), chips are always actionable. Chips should complement, rather than replace, the primary page actions.";
|
|
8
8
|
ds:anatomyDsl "";
|
|
9
9
|
ds:anatomyClassic "https://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2877-8032&t=ch8BFFPUe9gCvMdg-1\n\nStyling\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=2093-9647&t=ch8BFFPUe9gCvMdg-1\n\n";
|
|
10
10
|
ds:usage "### When to use\n\n- When displaying applied filters in a list, allowing users to see and dismiss active parameters. For example, the [ComboboxField](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-kfEQ25cX4a) displays selected items inside the input as a dismissible Chip.\n- When displaying a tag, category, or other attributes that a user can interact with. For example, use as a shortcut to filtering. There can be multiple instances of the chip, each representing a different attribute. It is common to find chips located inside of other components such as a table cell, a card, or next to the entity they belong to. \n- When displaying an entity (an object with its own parameters) that needs to trigger a popover for more information. For example, a computer name that would be rendered as a chip and display more details inside a popover when interacted with. \n- When users need to interact with tags, categories, or objects that can be added or removed from a collection.\n\n### When not to use\n\n- If the information is purely read-only (e.g., a \"Status\" indicator), use the [Tag](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-osLY8UcQUp) component instead.\n- Do not use chips for actions on a page, such as \"Submit,\" \"Save,\" or \"Delete All\"; use a [Button](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-8SdtbQUhTr) for these tasks.\n- Chips should not be used as navigation. They should not replace links, the primary navigation menu nor replace [Breadcrumbs](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-BXVe6mKJMd) for structural navigation.\n- If the user needs to input detailed text or data, use a [Field](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-y2LECO9EbF) or [SelectInput](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-xiMRYATXwr) component rather than a series of chips.\n- Avoid using too many chips in a single view if they compete for attention with the primary content of the page.";
|
|
11
11
|
ds:guidelines "Accessibility\n\n## **Color accessibility**\n\n- Chips border colors need to satisfy 3:1 contrast against the lightest/darkest background color state.\n- Use a modifier if it makes sense semantically for your use case.\n- Avoid using semantic color modifiers on top of colored backgrounds.\n- Ensure you don’t use colour as the only visual means of conveying information or an action.\n\n## Alternative text\n\n- There should be an alternative text specified when the value (text) doesn't provide enough contextual information E.g. \"status important\" instead of the default \"important\" as the value of the chip\n\n## Keyboard interactions and focus\n\n- When pressing `Enter` a default chip should perform the filtering action based on its value, the dismissible chip should revert the filtering behavior.\n- When tabulating through chips, the focus area should be the whole chip for the default chip, the dismissible area for the dismissible chip. ";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needscoredocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
15
15
|
a ds:Property;
|
|
16
16
|
ds:name "value";
|
|
@@ -32,14 +32,14 @@ ds:global.component.chip a ds:Component;
|
|
|
32
32
|
], [
|
|
33
33
|
a ds:Property;
|
|
34
34
|
ds:name "state";
|
|
35
|
-
ds:summary "The state the button is currently in.
|
|
35
|
+
ds:summary "The state the button is currently in.";
|
|
36
36
|
ds:propertyType "choice";
|
|
37
37
|
ds:optional "false";
|
|
38
38
|
ds:defaultValue "default"
|
|
39
39
|
], [
|
|
40
40
|
a ds:Property;
|
|
41
41
|
ds:name "color";
|
|
42
|
-
ds:summary "The color the chip should have. Be aware that some of the colors might be interpreted in a semantic way by users. The color token for chips allows input of a hue, and auto generates the correct lightness and chroma.
|
|
42
|
+
ds:summary "The color the chip should have. Be aware that some of the colors might be interpreted in a semantic way by users. The color token for chips allows input of a hue, and auto generates the correct lightness and chroma.";
|
|
43
43
|
ds:propertyType "choice";
|
|
44
44
|
ds:optional "false";
|
|
45
45
|
ds:defaultValue "color-foreground-secondary-root"
|
|
@@ -68,12 +68,10 @@ ds:global.component.chip a ds:Component;
|
|
|
68
68
|
ds:changeLog [
|
|
69
69
|
a ds:ChangeLogEntry;
|
|
70
70
|
ds:timestamp "2026-02-20T09:00:00.000+01:00";
|
|
71
|
-
ds:change "added initial documentation";
|
|
72
71
|
ds:changeType "change"
|
|
73
72
|
], [
|
|
74
73
|
a ds:ChangeLogEntry;
|
|
75
74
|
ds:timestamp "2026-05-01T00:00:00.000+02:00";
|
|
76
|
-
ds:change "we decided to not use chips as filters - in the sense as they are the only option to filtering, however, we want the chips to act as a shortcut to a filter: so when clicking on a chip triggers a filter selection ";
|
|
77
75
|
ds:changeType "decision"
|
|
78
76
|
], [
|
|
79
77
|
a ds:ChangeLogEntry;
|