@canonical/design-system 0.46.0 → 0.47.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/pattern/data_views.ttl +85 -0
- package/data/apps/pattern/datatable.ttl +3 -73
- package/data/apps/pattern/page_header.ttl +50 -5
- package/data/apps/subcomponent/data_table-action_bar.ttl +2 -2
- package/data/apps/subcomponent/data_table-pagination_bar.ttl +2 -2
- package/data/apps/subcomponent/data_table-persistent_selection.ttl +1 -1
- package/data/apps/subcomponent/data_views-filters.ttl +13 -0
- package/data/apps/subcomponent/data_views-saved_views.ttl +13 -0
- package/data/apps/subcomponent/data_views-sort_panel.ttl +13 -0
- package/data/apps/subcomponent/side_panel-footer.ttl +1 -1
- package/data/apps_launchpad/component/modal.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/component/complex_multi_select.ttl +3 -3
- package/data/{apps_workplaceengineering → apps_workplace}/component/label-highlight.ttl +4 -4
- package/data/{apps_workplaceengineering → apps_workplace}/component/org_chart.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/component/rule.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/component/skip_link.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/component/theme_switcher.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/pattern/callout_numbers_card.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/pattern/confirmation_modal.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/pattern/org_event_card.ttl +2 -2
- package/data/{apps_workplaceengineering → apps_workplace}/subcomponent/multi_select_input.ttl +2 -2
- package/data/{apps_workplaceengineering.ttl → apps_workplace.ttl} +2 -2
- package/data/concept/Accessibility.ttl +9 -0
- package/data/concept/Breakpoints.ttl +9 -0
- package/data/concept/Design-tokens-Overview.ttl +10 -0
- package/data/concept/Filtering-patterns.ttl +0 -1
- package/data/concept/Foundations-Baseline.ttl +0 -1
- package/data/concept/Foundations-Color.ttl +10 -0
- package/data/concept/Foundations-Density--the-form-channel.ttl +0 -1
- package/data/concept/Foundations-Grid--Layout.ttl +1 -2
- package/data/concept/Foundations-Spacing/-Element-vs-container-owned.ttl +0 -1
- package/data/concept/Foundations-Spacing.ttl +0 -1
- package/data/concept/Foundations-Surfaces.ttl +0 -1
- package/data/concept/Foundations-Typography.ttl +1 -2
- package/data/concept/How-to-choose-between-question-mark-and-information-icon.ttl +10 -0
- package/data/concept/How-to-differentiate-types-of-UI-blocks-.ttl +0 -1
- package/data/concept/How-to-indicate-required-fields-in-forms.ttl +0 -1
- package/data/concept/How-to-support-modifiers-in-a-component.ttl +0 -1
- package/data/concept/Intentional-friction.ttl +0 -1
- package/data/concept/Overflow.ttl +0 -1
- package/data/concept/Understanding-the-modifier-contract.ttl +0 -1
- package/data/documentation/pattern/library_side_navigation.ttl +2 -2
- package/data/global/component/accordion.ttl +2 -2
- package/data/global/component/announcement.ttl +2 -1
- package/data/global/component/avatar.ttl +1 -1
- package/data/global/component/badge.ttl +2 -2
- package/data/global/component/breadcrumbs.ttl +3 -3
- package/data/global/component/button.ttl +3 -3
- package/data/global/component/button_link.ttl +1 -1
- package/data/global/component/card.ttl +3 -7
- package/data/global/component/chip.ttl +1 -0
- package/data/global/component/code_snippet.ttl +1 -1
- package/data/global/component/drag_and_drop_list.ttl +1 -1
- package/data/global/component/dropdown_button.ttl +2 -2
- package/data/global/component/file_upload_field.ttl +509 -60
- package/data/global/component/icon.ttl +1 -1
- package/data/global/component/icon_button.ttl +26 -4
- package/data/{apps → global}/component/key_value_pair.ttl +2 -2
- package/data/global/{subcomponent/markdown_input.ttl → component/markdown_editor_field.ttl} +3 -3
- package/data/global/component/mode_switcher.ttl +1 -1
- package/data/global/component/number_field.ttl +1 -1
- package/data/global/component/range_field.ttl +0 -80
- package/data/global/component/table.ttl +2 -2
- package/data/global/component/tile.ttl +1 -1
- package/data/global/component/tooltip.ttl +51 -91
- package/data/global/component/{data_tooltip.ttl → tooltip_data.ttl} +31 -23
- package/data/global/component/tooltip_wrapper.ttl +70 -14
- package/data/global/group/cards.ttl +1 -1
- package/data/{apps → global}/group/key_value_pairs.ttl +2 -2
- package/data/global/modifier/constructive.ttl +1 -1
- package/data/global/modifier/elevated.ttl +1 -1
- package/data/global/modifier_family/_emphasis.ttl +1 -2
- package/data/global/modifier_family/_other.ttl +1 -2
- package/data/global/modifier_family/surface.ttl +1 -1
- package/data/global/pattern/description_list.ttl +1 -1
- package/data/global/pattern/modal.ttl +1 -1
- package/data/global/pattern/timeline.ttl +1 -1
- package/data/global/pattern/{navigation.ttl → top_navigation.ttl} +2 -2
- package/data/global/subcomponent/chart_legend.ttl +1 -1
- package/data/global/subcomponent/chart_legend_item.ttl +1 -1
- package/data/global/subcomponent/file_upload_input.ttl +503 -50
- package/data/global/subcomponent/markdown_editor_input.ttl +13 -0
- package/data/global/subcomponent/modal-footer.ttl +1 -1
- package/data/global/subcomponent/number_input.ttl +1 -1
- package/data/global/subcomponent/range_input.ttl +3 -84
- package/data/global/{component/markdown_field.ttl → subcomponent/text_editor_input.ttl} +3 -3
- package/data/global/variant/tooltip_dense.ttl +86 -5
- package/data/global_dataviews/component/filter_button.ttl +487 -0
- package/data/global_dataviews/component/query_bar.ttl +1639 -0
- package/data/global_dataviews/component/query_chip.ttl +605 -0
- package/data/global_dataviews/group/query_chips.ttl +565 -0
- package/data/global_dataviews/modifier/exclusion.ttl +8 -0
- package/data/global_dataviews/modifier/inclusion.ttl +8 -0
- package/data/global_dataviews/modifier/match.ttl +8 -0
- package/data/global_dataviews/modifier/presence.ttl +8 -0
- package/data/global_dataviews/modifier/range.ttl +8 -0
- package/data/global_dataviews/modifier_family/condition.ttl +9 -0
- package/data/global_dataviews/subcomponent/query_chip-entry.ttl +186 -0
- package/data/global_dataviews/subcomponent/query_chip-segment.ttl +241 -0
- package/data/global_dataviews/subcomponent/query_input.ttl +1287 -0
- package/data/global_dataviews.ttl +6 -0
- package/data/sites/component/store_card.ttl +1 -1
- package/data/tag/{wpeinital-implementation.ttl → workplaceinitial-implementation.ttl} +2 -2
- package/data/tag/{wpetriageupstream-and-deprecate.ttl → workplacetriageupstream-and-deprecate.ttl} +2 -2
- package/definitions/ontology.ttl +8 -2
- package/package.json +6 -6
- package/skills/adoption-a1-styles/SKILL.md +11 -0
- package/skills/adoption-a2-components/SKILL.md +82 -2
- package/skills/anatomy-author/SKILL.md +278 -95
- package/skills/anatomy-author/clarification-guidelines.md +150 -0
- package/skills/anatomy-author/completeness-checklist.md +224 -0
- package/skills/implement-component/SKILL.md +2 -2
- package/skills/map-journeys/SKILL.md +395 -0
- package/skills/map-journeys/journey-graph.example.html +298 -0
- package/skills/model-domains/SKILL.md +502 -0
- package/data/concept/Question-mark-vs-information-icon.ttl +0 -11
- package/data/global/modifier/editable.ttl +0 -8
- package/data/global/modifier/focused.ttl +0 -8
- package/data/global/modifier/highlighted.ttl +0 -8
- package/data/global/modifier/loading.ttl +0 -8
- package/data/global/modifier/muted.ttl +0 -8
- package/data/global/modifier/wireframe.ttl +0 -8
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
@prefix anatomy: <https://anatomy.canonical.com/>.
|
|
3
3
|
@prefix dt: <https://dt.canonical.com/>.
|
|
4
4
|
|
|
5
|
-
ds:global.component.
|
|
6
|
-
ds:name "
|
|
7
|
-
ds:summary "The data tooltip is a tooltip designed specifically for data visualisation.
|
|
8
|
-
ds:anatomyDsl "---\
|
|
9
|
-
ds:anatomyClassic "
|
|
10
|
-
ds:usage "When to use\n\n- When inspecting individual data points in charts or visualisations\n- When users move quickly between adjacent data points\n- When content is structured as short label–value pairs (e.g. “OS: Ubuntu 24.04”, “CPU usage: 72%”), optionally with colour indicators to match visual elements such as charts\n\n
|
|
11
|
-
ds:guidelines "### Animation\n\n- Show with a 400 ms delay after hover or focus\n- Hide with a 400 ms delay after the pointer leaves\n- Cancel display if the pointer exits before the show delay completes\n- If the pointer moves directly from one tooltip trigger to another, show the new tooltip immediately and skip the previous tooltip’s exit animation\n\n###
|
|
5
|
+
ds:global.component.tooltip_data a ds:Component;
|
|
6
|
+
ds:name "TooltipData";
|
|
7
|
+
ds:summary "The data tooltip is a tooltip designed specifically for data visualisation. Its primary purpose is to reveal values when users interact with charts, graphs, maps, or other data-driven elements. It is used for displaying metrics on hover, clarifying data points that cannot be fully shown in the visual itself. \n\nThis variant helps users interpret information accurately without cluttering the interface with labels that are always visible.\n\nRelated to [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) and [TooltipWrapper](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-69TNyYt7M9).";
|
|
8
|
+
ds:anatomyDsl "---\nnode:\n uri: global.component.data_tooltip\n edges:\n - node:\n role: surface\n styles:\n appearance.background: color.background\n appearance.border.color: color.border.muted\n appearance.border.style: solid\n appearance.border.width: dimension.stroke.thickness.medium\n layout.type: flex\n layout.direction: column\n layout.align: start\n spacing.internal.block.start: dimension.100\n spacing.internal.block.end: dimension.100\n spacing.internal.inline.start: dimension.100\n spacing.internal.inline.end: dimension.100\n edges:\n # No block names the heading, so it is an anonymous node.\n - node:\n role: heading\n styles:\n typography.font: typography.text.secondary.bold\n relation:\n cardinality: \"0..1\"\n slotName: heading\n - node:\n uri: global.subcomponent.chart_legend\n relation:\n cardinality: \"1\"\n slotName: default\n relation:\n cardinality: \"1\"\n slotName: default";
|
|
9
|
+
ds:anatomyClassic "## Anatomy\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=13993-2770&t=pA5l7Omuxa3ATwVS-1\n\n1. **Container**\n\nSurface that follows the pointer. No arrow.\n\n1. **Chart legend**\n\nDisplays the data label and value. One row per series: marker, label and value. Add or remove rows in the Items slot.\n\n1. **Heading (optional)**\n\nTitles the legend.\n\n## Styling\n\n";
|
|
10
|
+
ds:usage "## When to use\n\n- When inspecting individual data points in charts or visualisations\n- When users move quickly between adjacent data points\n- When content is structured as short label–value pairs (e.g. “OS: Ubuntu 24.04”, “CPU usage: 72%”), optionally with colour indicators to match visual elements such as charts\n\n## When not to use\n\n- When used outside of data visualisation contexts\n - Incorrect: A data tooltip is used to explain a form field\n - Remediation: Use a [Standard tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20chnVyhaz/_rui-Y9PpN4FiwA)\n- When explaining UI controls or icons\n - Incorrect: A data tooltip is attached to a settings icon\n - Remediation: Use a [Standard tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20chnVyhaz/_rui-Y9PpN4FiwA) \n- When information must persist beyond hover\n - Incorrect: A data tooltip contains important information users must reference continuously\n - Remediation: Use a persistent component such as [Popover](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-i-62pvfoOF) or inline content\n- When the element is already clearly labelled or self-explanatory.\n\n**In essence:**\n\nWhen in doubt, start with standard [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW). Move to its [Tooltip+Dense](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-PFE_wK_bWT) variant for space constraints; [TooltipWrapper](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-69TNyYt7M9) for structured content and complex hierarchies; [TooltipData](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-Y1ha3zI_b_) for data visualization.";
|
|
11
|
+
ds:guidelines "### Animation\n\n- Show with a 400 ms delay after hover or focus\n- Hide with a 400 ms delay after the pointer leaves\n- Cancel display if the pointer exits before the show delay completes\n- If the pointer moves directly from one tooltip trigger to another, show the new tooltip immediately and skip the previous tooltip’s exit animation\n\n### Transition\n\n- **Type**: spring\n- **Duration**: 0.4 s\n- **Bounce**: 0.2\n- **Delay**: 0 s\n\n### Specific for data tooltip:\n\n- Cursor-follow behaviour; follows the cursor while open.\n- Cursor-follow placement direction: **Right**\n- Horizontal offset from cursor: **16 px**\n- Vertical offset from cursor: **8 px**\n\n### Motion feel\n\n- Preset: **Snappy**\n- Bounce profile: **No-bounce**\n- Spring: stiffness **500**, damping **60**, mass **1**, no overshoot\n\n### Reduced motion\n\n- Snaps to the pointer position instead of easing. Same 400 ms open and close delays.\n\n### CSS fallback\n\n- Cursor-follow: 140 to 180 ms, cubic-bezier(0.16, 1, 0.3, 1), no overshoot.\n- Enter and exit: opacity 0 to 1 and scale 0.96 to 1 over 400 ms, cubic-bezier(0.22, 1, 0.36, 1).\n\n### Hovered series\n\n- The series under the pointer shows as highlighted in the legend (bold label and value), so it's clear which row the pointer refers to. Other rows stay in the default state.\n\n### Interactions and accessibility\n\n- Only one tooltip is open at a time. It contains no interactive content and never takes focus.\n- Escape closes it.\n- The tooltip element has role=\"tooltip\". Data shown only on hover should also be available another way, for example a data table, for keyboard, screen reader and touch users.\n- Values use tabular figures in code.";
|
|
12
12
|
ds:tier ds:global;
|
|
13
13
|
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
@@ -78,15 +78,15 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
78
78
|
ds:optional "false";
|
|
79
79
|
ds:propertyType "choice"
|
|
80
80
|
];
|
|
81
|
+
ds:hasSubcomponent ds:global.subcomponent.chart_legend, ds:global.subcomponent.chart_legend_item;
|
|
82
|
+
ds:inheritsFrom ds:global.component.tooltip;
|
|
81
83
|
ds:changeLog [
|
|
82
84
|
a ds:ChangeLogEntry;
|
|
83
85
|
ds:timestamp "2026-04-22T00:00:00.000+02:00"
|
|
84
86
|
];
|
|
85
|
-
ds:hasSubcomponent ds:global.subcomponent.chart_legend, ds:global.subcomponent.chart_legend_item;
|
|
86
|
-
ds:inheritsFrom ds:global.component.tooltip;
|
|
87
87
|
ds:hasTokenBinding [
|
|
88
88
|
a ds:TokenBinding;
|
|
89
|
-
ds:viaBlock ds:global.component.
|
|
89
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
90
90
|
ds:node "$root/surface";
|
|
91
91
|
anatomy:styleKey "appearance.background";
|
|
92
92
|
anatomy:styleState "default";
|
|
@@ -94,7 +94,23 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
94
94
|
ds:consumesSymbol dt:color.background
|
|
95
95
|
], [
|
|
96
96
|
a ds:TokenBinding;
|
|
97
|
-
ds:viaBlock ds:global.component.
|
|
97
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
98
|
+
ds:node "$root/surface";
|
|
99
|
+
anatomy:styleKey "appearance.border.color";
|
|
100
|
+
anatomy:styleState "default";
|
|
101
|
+
ds:rank 1;
|
|
102
|
+
ds:consumesSymbol dt:color.border.muted
|
|
103
|
+
], [
|
|
104
|
+
a ds:TokenBinding;
|
|
105
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
106
|
+
ds:node "$root/surface";
|
|
107
|
+
anatomy:styleKey "appearance.border.width";
|
|
108
|
+
anatomy:styleState "default";
|
|
109
|
+
ds:rank 1;
|
|
110
|
+
ds:consumesSymbol dt:dimension.stroke.thickness.medium
|
|
111
|
+
], [
|
|
112
|
+
a ds:TokenBinding;
|
|
113
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
98
114
|
ds:node "$root/surface";
|
|
99
115
|
anatomy:styleKey "spacing.internal.block.start";
|
|
100
116
|
anatomy:styleState "default";
|
|
@@ -102,7 +118,7 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
102
118
|
ds:consumesSymbol dt:dimension.100
|
|
103
119
|
], [
|
|
104
120
|
a ds:TokenBinding;
|
|
105
|
-
ds:viaBlock ds:global.component.
|
|
121
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
106
122
|
ds:node "$root/surface";
|
|
107
123
|
anatomy:styleKey "spacing.internal.block.end";
|
|
108
124
|
anatomy:styleState "default";
|
|
@@ -110,7 +126,7 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
110
126
|
ds:consumesSymbol dt:dimension.100
|
|
111
127
|
], [
|
|
112
128
|
a ds:TokenBinding;
|
|
113
|
-
ds:viaBlock ds:global.component.
|
|
129
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
114
130
|
ds:node "$root/surface";
|
|
115
131
|
anatomy:styleKey "spacing.internal.inline.start";
|
|
116
132
|
anatomy:styleState "default";
|
|
@@ -118,7 +134,7 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
118
134
|
ds:consumesSymbol dt:dimension.100
|
|
119
135
|
], [
|
|
120
136
|
a ds:TokenBinding;
|
|
121
|
-
ds:viaBlock ds:global.component.
|
|
137
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
122
138
|
ds:node "$root/surface";
|
|
123
139
|
anatomy:styleKey "spacing.internal.inline.end";
|
|
124
140
|
anatomy:styleState "default";
|
|
@@ -126,7 +142,7 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
126
142
|
ds:consumesSymbol dt:dimension.100
|
|
127
143
|
], [
|
|
128
144
|
a ds:TokenBinding;
|
|
129
|
-
ds:viaBlock ds:global.component.
|
|
145
|
+
ds:viaBlock ds:global.component.tooltip_data;
|
|
130
146
|
ds:node "$root/surface/heading";
|
|
131
147
|
anatomy:styleKey "typography.font";
|
|
132
148
|
anatomy:styleState "default";
|
|
@@ -220,12 +236,4 @@ ds:global.component.data_tooltip a ds:Component;
|
|
|
220
236
|
anatomy:styleState "default";
|
|
221
237
|
ds:rank 1;
|
|
222
238
|
ds:consumesSymbol dt:color.palette.gray.180
|
|
223
|
-
], [
|
|
224
|
-
a ds:TokenBinding;
|
|
225
|
-
ds:viaBlock ds:global.component.data_tooltip;
|
|
226
|
-
ds:node "$root/arrow";
|
|
227
|
-
anatomy:styleKey "appearance.background";
|
|
228
|
-
anatomy:styleState "default";
|
|
229
|
-
ds:rank 1;
|
|
230
|
-
ds:consumesSymbol dt:color.background
|
|
231
239
|
].
|
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.component.tooltip_wrapper a ds:Component;
|
|
6
6
|
ds:name "TooltipWrapper";
|
|
7
|
-
ds:summary "The wrapper tooltip is a flexible tooltip designed to support richer content beyond a single line of text. It is best suited for use cases where multiple content types must be supported, such as text, KVPs ([KVPItem (base)](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eUn6xQeQ6l)), or tables. This type of tooltip is ideal when standard tooltips are too limited, but a modal or larger surface would feel too disruptive. \n\nRelated to [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) and [
|
|
8
|
-
ds:anatomyDsl "---\n#
|
|
9
|
-
ds:anatomyClassic "\n\
|
|
10
|
-
ds:usage "When to use\n\n- When tooltip content requires internal structure such as tables, key–value pairs, legends, or media\n- When used in dashboards or data-heavy contexts requiring quick, glanceable detail\n- When flexibility is required without introducing multiple bespoke tooltip variants\n\n
|
|
11
|
-
ds:guidelines "- Show with a 400 ms delay after hover or focus\n- Hide with a 400 ms delay after the pointer leaves\n- Cancel display if the pointer exits before the show delay completes\n- If the pointer moves directly from one tooltip trigger to another, show the new tooltip immediately and skip the previous tooltip’s exit animation\n\n### **Transition**\n\n- **Type**: spring\n- **Duration**: 0.4 s\n- **Bounce**: 0.2\n- **Delay**: 0 s";
|
|
7
|
+
ds:summary "The wrapper tooltip is a flexible tooltip designed to support richer content beyond a single line of text. It is best suited for use cases where multiple content types must be supported, such as text, KVPs ([KVPItem (base)](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-eUn6xQeQ6l)), or tables. This type of tooltip is ideal when standard tooltips are too limited, but a modal or larger surface would feel too disruptive. \n\nRelated to [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW) and [TooltipData](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-Y1ha3zI_b_).";
|
|
8
|
+
ds:anatomyDsl "---\n# The tooltip for structured content: its body is a slot for any components.\n# Content colour is set by the slotted components, so none is bound here. An\n# inverted wrapper is made by switching the variable mode of the instance, so\n# the colours are bound directly and not through surface channels.\nnode:\n uri: global.component.tooltip_wrapper\n styles:\n layout.type: flex\n layout.direction: column\n layout.align: flex-start\n # Stays visible so the arrow, which sits outside the box, is not clipped.\n layout.overflow: visible\n appearance.background: color.background.container\n appearance.border.color: color.border.muted\n appearance.border.style: solid\n appearance.border.width: dimension.stroke.thickness.medium\n appearance.radius: dimension.radius.small\n spacing.gap: dimension.100\n spacing.internal.block.start: dimension.200\n spacing.internal.block.end: dimension.200\n spacing.internal.inline.start: dimension.200\n spacing.internal.inline.end: dimension.200\n edges:\n - switch:\n on: override\n cases:\n - uri: $custom\n relation:\n cardinality: \"0..*\"\n slotName: default\n - node:\n role: arrow\n styles:\n layout.position: absolute\n # Which side it points from follows the Arrow variant, so its offsets\n # are not bound, and the DSL has no triangle shape. The variant also\n # adds 8px of padding on the arrow side, which the tree cannot carry\n # per variant.\n size.width: dimension.175\n size.height: dimension.100\n appearance.background: color.background.container\n appearance.border.color: color.border.muted\n appearance.border.style: solid\n appearance.border.width: dimension.stroke.thickness.medium\n relation:\n # The component draws the arrow; no caller fills it, so it carries no\n # slot name.\n cardinality: \"1\"";
|
|
9
|
+
ds:anatomyClassic "## Anatomy\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=13993-2495&t=pA5l7Omuxa3ATwVS-1\n\n1. **Container**\n\nA content slot. No max width.\n\n1. **Slot content**\n\nAnything non-interactive: free text, a chart legend, a key-value list, a tooltip table or a Pragma component. Default is a placeholder.\n\n1. **Arrow** **(optional)**\n\nPoints from the tooltip to its trigger.\n\n**Helper components**\n\n- **Chart legend item**: one legend row with marker, label, optional value, and a rule below. State: Default or Highlighted (hovered series).\n- **Chart legend**: heading plus a slot of legend items. Turn Show rule off on the last item.\n- **Key-value pair**: Inline (value right-aligned) or Stacked. Strong is bold; use it as a group header.\n- **Key-value list**: a slot of key-value pairs. Width is set per instance.\n- **Tooltip table and row**: compact table with an exposed header row plus a slot of body rows. Two, three or four equal-width columns.\n- **Series marker**: 6 x 6 circle. Override the fill per series.\n- **Slot placeholder**: default content of the Wrapper slot. Replace it.\n\n## Styling\n\nhttps://www.figma.com/design/WGHcOmGMEUF9hMAEoRafL8/%F0%9F%93%95-Pragma---documentation-visuals?node-id=13993-3879&t=pA5l7Omuxa3ATwVS-1";
|
|
10
|
+
ds:usage "## When to use\n\n- When tooltip content requires internal structure such as tables, key–value pairs, legends, or media\n- When used in dashboards or data-heavy contexts requiring quick, glanceable detail\n- When flexibility is required without introducing multiple bespoke tooltip variants\n\n## When not to use\n\n- When only simple icon or control clarification is needed\n - Incorrect: A wrapper tooltip is used for a single short label explanation\n - Remediation: Use a [Standard tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20chnVyhaz/_rui-Y9PpN4FiwA) or [Dense tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20chnVyhaz/_rui-tES05lAnIw) \n- When content must persist or be interactive\n - Incorrect: A wrapper tooltip contains controls or actions\n - Remediation: Use a [Popover](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-i-62pvfoOF) or [Modal](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-XsokbPLmnc) \n- When only a single short sentence is required\n - Incorrect: A wrapper tooltip is used for minimal text\n - Remediation: Use a [Standard tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20chnVyhaz/_rui-Y9PpN4FiwA) \n- When the element is already clearly labelled or self-explanatory.\n\n**In essence:**\n\nWhen in doubt, start with standard [Tooltip](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-ONb9LwkGvW). Move to its [Tooltip+Dense](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-PFE_wK_bWT) variant for space constraints; [TooltipWrapper](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-69TNyYt7M9) for structured content and complex hierarchies; [TooltipData](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-Y1ha3zI_b_) for data visualization.";
|
|
11
|
+
ds:guidelines "- Show with a 400 ms delay after hover or focus\n- Hide with a 400 ms delay after the pointer leaves\n- Cancel display if the pointer exits before the show delay completes\n- If the pointer moves directly from one tooltip trigger to another, show the new tooltip immediately and skip the previous tooltip’s exit animation\n\n### **Transition**\n\n- **Type**: spring\n- **Duration**: 0.4 s\n- **Bounce**: 0.2\n- **Delay**: 0 s\n\n### Reduced motion\n\n- Fade in and out with no scale or movement, keeping the same delays.\n\n### CSS fallback\n\n- Opacity 0 to 1 and scale 0.96 to 1 over 400 ms, cubic-bezier(0.22, 1, 0.36, 1), transform origin at the arrow.\n\n### Interactions\n\n- Opens on hover and on keyboard focus, never on click.\n- Closes when the pointer or focus leaves, on Escape, and when another tooltip opens.\n- Only one tooltip is open at a time.\n- The pointer can move onto the tooltip without it closing.\n- Slot content stays non-interactive.\n\n### Positioning and responsive\n\n- Positioned relative to its trigger, centred with an 8 px offset. Flips to the opposite side when there isn't enough room and never overflows the viewport.\n- Collision padding is 24 px.\n- Tooltips don't appear on touch devices, so essential information must be available another way.\n\n### Typography\n\n- Helper headings and Strong key-value pairs: typography-text-secondary-$bold. Tooltip table headers: typography-text-tertiary-$bold.\n- Values use tabular figures in code.\n\n### Keyboard support\n\n- Tab or Shift+Tab to a trigger opens its tooltip.\n- Escape closes it without moving focus.\n\n### Focus\n\n- Tooltips aren't focusable and aren't part of the tab order.\n- A disabled control that needs an explanation should be wrapped in a focusable element.\n\n### ARIA\n\n- The tooltip element has role=\"tooltip\", and the trigger references it with aria-describedby.\n- Decorative icons inside the tooltip are hidden from assistive technology.";
|
|
12
12
|
ds:tier ds:global;
|
|
13
13
|
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasProperty [
|
|
@@ -84,15 +84,47 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
84
84
|
ds:hasTokenBinding [
|
|
85
85
|
a ds:TokenBinding;
|
|
86
86
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
87
|
-
ds:node "$root
|
|
87
|
+
ds:node "$root";
|
|
88
88
|
anatomy:styleKey "appearance.background";
|
|
89
89
|
anatomy:styleState "default";
|
|
90
90
|
ds:rank 1;
|
|
91
|
-
ds:consumesSymbol dt:color.background
|
|
91
|
+
ds:consumesSymbol dt:color.background.container
|
|
92
92
|
], [
|
|
93
93
|
a ds:TokenBinding;
|
|
94
94
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
95
|
-
ds:node "$root
|
|
95
|
+
ds:node "$root";
|
|
96
|
+
anatomy:styleKey "appearance.border.color";
|
|
97
|
+
anatomy:styleState "default";
|
|
98
|
+
ds:rank 1;
|
|
99
|
+
ds:consumesSymbol dt:color.border.muted
|
|
100
|
+
], [
|
|
101
|
+
a ds:TokenBinding;
|
|
102
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
103
|
+
ds:node "$root";
|
|
104
|
+
anatomy:styleKey "appearance.border.width";
|
|
105
|
+
anatomy:styleState "default";
|
|
106
|
+
ds:rank 1;
|
|
107
|
+
ds:consumesSymbol dt:dimension.stroke.thickness.medium
|
|
108
|
+
], [
|
|
109
|
+
a ds:TokenBinding;
|
|
110
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
111
|
+
ds:node "$root";
|
|
112
|
+
anatomy:styleKey "appearance.radius";
|
|
113
|
+
anatomy:styleState "default";
|
|
114
|
+
ds:rank 1;
|
|
115
|
+
ds:consumesSymbol dt:dimension.radius.small
|
|
116
|
+
], [
|
|
117
|
+
a ds:TokenBinding;
|
|
118
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
119
|
+
ds:node "$root";
|
|
120
|
+
anatomy:styleKey "spacing.gap";
|
|
121
|
+
anatomy:styleState "default";
|
|
122
|
+
ds:rank 1;
|
|
123
|
+
ds:consumesSymbol dt:dimension.100
|
|
124
|
+
], [
|
|
125
|
+
a ds:TokenBinding;
|
|
126
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
127
|
+
ds:node "$root";
|
|
96
128
|
anatomy:styleKey "spacing.internal.block.start";
|
|
97
129
|
anatomy:styleState "default";
|
|
98
130
|
ds:rank 1;
|
|
@@ -100,7 +132,7 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
100
132
|
], [
|
|
101
133
|
a ds:TokenBinding;
|
|
102
134
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
103
|
-
ds:node "$root
|
|
135
|
+
ds:node "$root";
|
|
104
136
|
anatomy:styleKey "spacing.internal.block.end";
|
|
105
137
|
anatomy:styleState "default";
|
|
106
138
|
ds:rank 1;
|
|
@@ -108,7 +140,7 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
108
140
|
], [
|
|
109
141
|
a ds:TokenBinding;
|
|
110
142
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
111
|
-
ds:node "$root
|
|
143
|
+
ds:node "$root";
|
|
112
144
|
anatomy:styleKey "spacing.internal.inline.start";
|
|
113
145
|
anatomy:styleState "default";
|
|
114
146
|
ds:rank 1;
|
|
@@ -116,7 +148,7 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
116
148
|
], [
|
|
117
149
|
a ds:TokenBinding;
|
|
118
150
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
119
|
-
ds:node "$root
|
|
151
|
+
ds:node "$root";
|
|
120
152
|
anatomy:styleKey "spacing.internal.inline.end";
|
|
121
153
|
anatomy:styleState "default";
|
|
122
154
|
ds:rank 1;
|
|
@@ -124,8 +156,16 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
124
156
|
], [
|
|
125
157
|
a ds:TokenBinding;
|
|
126
158
|
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
127
|
-
ds:node "$root/
|
|
128
|
-
anatomy:styleKey "
|
|
159
|
+
ds:node "$root/arrow";
|
|
160
|
+
anatomy:styleKey "size.width";
|
|
161
|
+
anatomy:styleState "default";
|
|
162
|
+
ds:rank 1;
|
|
163
|
+
ds:consumesSymbol dt:dimension.175
|
|
164
|
+
], [
|
|
165
|
+
a ds:TokenBinding;
|
|
166
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
167
|
+
ds:node "$root/arrow";
|
|
168
|
+
anatomy:styleKey "size.height";
|
|
129
169
|
anatomy:styleState "default";
|
|
130
170
|
ds:rank 1;
|
|
131
171
|
ds:consumesSymbol dt:dimension.100
|
|
@@ -136,5 +176,21 @@ ds:global.component.tooltip_wrapper a ds:Component;
|
|
|
136
176
|
anatomy:styleKey "appearance.background";
|
|
137
177
|
anatomy:styleState "default";
|
|
138
178
|
ds:rank 1;
|
|
139
|
-
ds:consumesSymbol dt:color.background
|
|
179
|
+
ds:consumesSymbol dt:color.background.container
|
|
180
|
+
], [
|
|
181
|
+
a ds:TokenBinding;
|
|
182
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
183
|
+
ds:node "$root/arrow";
|
|
184
|
+
anatomy:styleKey "appearance.border.color";
|
|
185
|
+
anatomy:styleState "default";
|
|
186
|
+
ds:rank 1;
|
|
187
|
+
ds:consumesSymbol dt:color.border.muted
|
|
188
|
+
], [
|
|
189
|
+
a ds:TokenBinding;
|
|
190
|
+
ds:viaBlock ds:global.component.tooltip_wrapper;
|
|
191
|
+
ds:node "$root/arrow";
|
|
192
|
+
anatomy:styleKey "appearance.border.width";
|
|
193
|
+
anatomy:styleState "default";
|
|
194
|
+
ds:rank 1;
|
|
195
|
+
ds:consumesSymbol dt:dimension.stroke.thickness.medium
|
|
140
196
|
].
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.group.cards a ds:Group;
|
|
6
6
|
ds:name "Cards";
|
|
7
|
-
ds:summary "";
|
|
7
|
+
ds:summary "Cards are a set of Card blocks shown side by side, each one data object in the same structure. Users scan and compare attributes across the set at a glance. Use them for machine inventories, image catalogues and plan comparisons.";
|
|
8
8
|
ds:anatomyDsl "";
|
|
9
9
|
ds:anatomyClassic "";
|
|
10
10
|
ds:usage "";
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
@prefix anatomy: <https://anatomy.canonical.com/>.
|
|
3
3
|
@prefix dt: <https://dt.canonical.com/>.
|
|
4
4
|
|
|
5
|
-
ds:
|
|
5
|
+
ds:global.group.key_value_pairs a ds:Group;
|
|
6
6
|
ds:name "KeyValuePairs";
|
|
7
7
|
ds:summary "";
|
|
8
8
|
ds:anatomyDsl "";
|
|
9
9
|
ds:anatomyClassic "";
|
|
10
10
|
ds:usage "";
|
|
11
11
|
ds:guidelines "";
|
|
12
|
-
ds:tier ds:
|
|
12
|
+
ds:tier ds:global;
|
|
13
13
|
ds:documentationStage ds:tag.designin-progress.
|
|
@@ -4,5 +4,5 @@
|
|
|
4
4
|
|
|
5
5
|
ds:global.modifier.constructive a ds:Modifier;
|
|
6
6
|
ds:name "Constructive";
|
|
7
|
-
ds:summary "";
|
|
7
|
+
ds:summary "The constructive modifier highlights the additive or positive nature of the consequences of an action. As opposed to [Destructive](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-aygAVqOfFj/_rui-VZYLmDJC1O) , Constructive should only be applied in tandem with [Destructive](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-aygAVqOfFj/_rui-VZYLmDJC1O) . When action UI blocks are used standalone, they should use their default, unmodified, appearance.";
|
|
8
8
|
ds:modifierFamily ds:global.modifier_family.anticipation.
|
|
@@ -5,5 +5,4 @@
|
|
|
5
5
|
ds:global.modifier_family._other a ds:ModifierFamily;
|
|
6
6
|
ds:name "(Other)";
|
|
7
7
|
ds:summary "";
|
|
8
|
-
ds:tier ds:global
|
|
9
|
-
ds:hasModifier ds:global.modifier.elevated, ds:global.modifier.editable, ds:global.modifier.focused, ds:global.modifier.wireframe, ds:global.modifier.loading.
|
|
8
|
+
ds:tier ds:global.
|
|
@@ -6,4 +6,4 @@ ds:global.modifier_family.surface a ds:ModifierFamily;
|
|
|
6
6
|
ds:name "Surface";
|
|
7
7
|
ds:summary "";
|
|
8
8
|
ds:tier ds:global;
|
|
9
|
-
ds:hasModifier ds:global.modifier.modal, ds:global.modifier.surface3, ds:global.modifier.surface2, ds:global.modifier.surface1.
|
|
9
|
+
ds:hasModifier ds:global.modifier.modal, ds:global.modifier.surface3, ds:global.modifier.surface2, ds:global.modifier.surface1, ds:global.modifier.elevated.
|
|
@@ -10,7 +10,7 @@ ds:global.pattern.modal a ds:Pattern;
|
|
|
10
10
|
ds:usage "Modals are intended for focused, interruptive interactions. They are suitable for moments where the user must complete an action or understand contextual information before returning to their current flow.\n\n**When to use**\n\n- When a confirmation is needed before completing or canceling an action, modals should be used. They are well suited for this because they capture full attention and require an explicit decision from the user. \n- When a form is displayed on a website rather than an app. On apps, forms should generally use side panels or full pages instead. If a form requires a nested step, layer side panels rather than escalating to a modal.\n- When providing extra context or instructions that are supplementary to the main task. For example, explaining search syntax rules or describing how to format a cron job expression.\n- When the system needs to interrupt the user with a warning, such as when unsaved changes are about to be lost or a critical condition requires acknowledgment.\n- When a side panel triggers a secondary step that involves a small, self-contained form that is not a fully independent entity in the software. For example, selecting an image for an LXD container. This is only appropriate when the nested step is minor. If the nested step is a complete form that already exists elsewhere in the UI, use a nested side panel for consistency.\n- When a side panel is displaying an item that has associated entities, and the main listing page cannot be filtered to show only the related ones. For example, when an instance is related to several profiles and there is no way to filter the profiles listing page down to only the associated ones. If the item is displayed on a full page instead of a side panel, open the associated list in a side panel rather than a modal.\n\n\n\n**When not to use**\n\n- When a modal would need to trigger a side panel as a secondary step. A side panel can trigger a modal, but a modal cannot trigger a side panel.\n - Incorrect: A modal form that opens a side panel when the user needs to complete a prerequisite step.\n - Remediation: Restructure the flow so that the initial container is a side panel, which can then trigger a modal for any smaller interruption if needed.\n- When a form is required to complete an app workflow. Use side panels or full pages instead, which keep the user oriented within the application structure. [This is also the case for forms with only one field.]\n - Incorrect: Opening a modal to fill out a multi-field entity creation form inside an app.\n - Remediation: Use a side panel or a dedicated page. If a nested step is required, layer a second side panel on top of the first.\n- When displaying static information about an entity, such as a read-only detail view. Static content does not require the level of interruption a modal creates.\n - Incorrect: A modal that opens to show the details of an entity with no actions available.\n - Remediation: Use a side panel to display entity details while keeping the background context visible.\n- When the goal is to guide a first-time user through the interface in a tour or onboarding flow.\n - Incorrect: A modal sequence that blocks the UI to walk the user through each feature step by step.\n - Remediation: Use popovers, which allow the user to interact with the UI and exit the flow at any point.\n- When a lighter, non-interruptive overlay could serve the same purpose. Modals block the entire view and force a decision, while popovers allow continued interaction with the page.\n - Incorrect: Using a modal to show a tooltip-style explanation of a field while the user is filling out a form.\n - Remediation: Use a popover, which surfaces the information without interrupting the user's flow.\n- When providing feedback on the outcome of an action, whether successful or not.\n - Incorrect: A modal that appears after completing an action to confirm it was done successfully.\n - Remediation: Use a toast notification, which communicates the result without requiring any interaction from the user.";
|
|
11
11
|
ds:guidelines "Web : It is recommended to use a backdrop for the modal if the browser allows for it\n\nConfirmation modals, constructive or destructive, should include a description of the consequences. The button used in the Modal footer should reflect the modifier context, for instance a modal that confirms a [Destructive](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-aygAVqOfFj/_rui-VZYLmDJC1O) action should use a [Destructive](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-aygAVqOfFj/_rui-VZYLmDJC1O) [Button](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-20dWwIHYhx/_rui-8SdtbQUhTr) .\n\nIf the action is destructive, a [Intentional friction](https://docs.superhuman.com/d/_dNyzE_TLZDh#_tugrid-GnfOU3MM-3/_rui-jBkiiurLeQ) should be considered.";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:documentationStage ds:tag.
|
|
13
|
+
ds:documentationStage ds:tag.needsfulldocumentation;
|
|
14
14
|
ds:hasSubcomponent ds:global.subcomponent.modal-content, ds:global.subcomponent.modal-header, ds:global.subcomponent.modal-footer;
|
|
15
15
|
ds:hasTokenBinding [
|
|
16
16
|
a ds:TokenBinding;
|
|
@@ -70,6 +70,7 @@ ds:global.pattern.timeline a ds:Pattern;
|
|
|
70
70
|
ds:optional "false";
|
|
71
71
|
ds:constraints "the user should contain the name, email, role, and profile picture"
|
|
72
72
|
];
|
|
73
|
+
ds:hasSubcomponent ds:global.subcomponent.timeline-event, ds:global.subcomponent.timeline-expansion_indicator, ds:global.subcomponent.timeline-content, ds:global.subcomponent.timeline-header;
|
|
73
74
|
ds:changeLog [
|
|
74
75
|
a ds:ChangeLogEntry;
|
|
75
76
|
ds:timestamp "2026-01-15T14:00:00.000+01:00";
|
|
@@ -91,7 +92,6 @@ ds:global.pattern.timeline a ds:Pattern;
|
|
|
91
92
|
ds:timestamp "2026-03-13T00:00:00.000+01:00";
|
|
92
93
|
ds:changeType "change"
|
|
93
94
|
];
|
|
94
|
-
ds:hasSubcomponent ds:global.subcomponent.timeline-event, ds:global.subcomponent.timeline-expansion_indicator, ds:global.subcomponent.timeline-content, ds:global.subcomponent.timeline-header;
|
|
95
95
|
ds:hasTokenBinding [
|
|
96
96
|
a ds:TokenBinding;
|
|
97
97
|
ds:viaBlock ds:global.subcomponent.timeline-event;
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
@prefix anatomy: <https://anatomy.canonical.com/>.
|
|
3
3
|
@prefix dt: <https://dt.canonical.com/>.
|
|
4
4
|
|
|
5
|
-
ds:global.pattern.
|
|
6
|
-
ds:name "
|
|
5
|
+
ds:global.pattern.top_navigation a ds:Pattern;
|
|
6
|
+
ds:name "TopNavigation";
|
|
7
7
|
ds:summary "";
|
|
8
8
|
ds:anatomyDsl "";
|
|
9
9
|
ds:anatomyClassic "";
|
|
@@ -10,7 +10,7 @@ ds:global.subcomponent.chart_legend a ds:Subcomponent;
|
|
|
10
10
|
ds:usage "";
|
|
11
11
|
ds:guidelines "**Accessibility**\n\n**Hover and focus triggers** \nTooltips must be accessible via both pointer (hover) and keyboard (focus). Any element that triggers a tooltip must be focusable and expose the same information on focus as on hover. The tooltip itself has no focus state.\n\n**Screen reader support** \nTooltip content should be programmatically associated with its trigger using appropriate ARIA attributes. Content must be announced without requiring additional interaction.\n\n**Content clarity and brevity** \nAs mentioned earlier, tooltip content should be concise and written in plain language. Avoid relying on tooltips to communicate critical or required information, as they may not be consistently discovered.\n\n**Non-hover environments** \nOn touch devices where hover is not available, tooltips should either appear on tap, or be replaced by an alternative pattern. Again, no essential info should be hidden behind a hover-only interaction. \n\n\n\n**Device and input considerations**\n\n**Pointer vs touch behavior** \nOn pointer devices, tooltips appear on hover and dismiss on pointer exit. On touch devices, tooltips should be triggered by tap and dismissible via a second tap (on itself), outside tap, or timeout.\n\n**Target size and spacing** \nInteractive elements that trigger tooltips must meet the minimum touch target size (24 px by 24 px on desktops). Avoid attaching tooltips to very small or densely packed targets without sufficient padding.\n\n**Responsive positioning** \nTooltip placement should adapt to viewport constraints. When insufficient space is available, the tooltip should flip or reposition to remain fully visible.\n\n\n\n**Content**\n\n**Purpose of tooltips** \nAgain, as mentioned earlier, use tooltips to provide supplementary, non-critical information that is used as clarification.\n\n**Appropriate use cases**\n\n- Explaining unfamiliar icons, abbreviations, or controls\n- Providing short contextual hints without adding visual clutter\n- Supporting data interpretation in charts and dashboards\n\n**Avoid misuse**\n\n- Do not include essential instructions or required actions\n- Do not include complex, multi-step, or interactive content\n- Do not duplicate clearly visible labels or text\n\n**Length and structure** \nKeep content short (ideally one line, maximum two lines for standard). Avoid paragraphs.\n\n\n\n**Animation**\n\n**Entrance and exit timing** \nTooltips should appear after a short delay on hover or focus (~400 ms) and dismiss after a similar delay when the pointer leaves.\n\n**Motion behaviour** \nThis element uses subtle, non-distracting motion. Cursor-follow behaviour (for data vis) should feel responsive and stable.\n\n**Interruptions and re-triggering** \nIf the pointer moves between adjacent triggers, skip exit/entry animations and display the new tooltip immediately to maintain continuity.\n\n\n\n**Keyboard navigation**\n\n**Focus order** \nTooltip triggers must be reachable via standard tab navigation. The tooltip itself should not receive focus unless it contains interactive content (which I realise can happen if we’re using links – could you help out here please [Elaine Liman](mailto:elaine.liman@canonical.com)?).\n\n**Dismissal** \nTooltips should dismiss when the focus moves away from the trigger\n\n\n\n**Interaction behavior**\n\n**Trigger types** \nTooltips may be triggered by icons, text, or UI controls. For data vis, tooltips may follow the cursor.\n\n**Positioning** \nDefault placement should be centred relative to the trigger with a consistent offset. Placement should adjust dynamically to avoid viewport overflow.\n\n**Collision handling** \nIn-built, but there is consistent collision padding to ensure tooltips do not touch screen edges (or overlap critical UI elements). \n\n\n\n**Layout and spacing**\n\n**Standard and dense variants**\n\n- Standard tooltips prioritise readability with balanced padding\n- Dense tooltips reduce spacing for compact environments\n\n\n\n**Wrapper variant** \nWrapper tooltips support more complex content structures and flexible layouts. Spacing should follow token-based guidance but remain adaptable to context (at the designer’s discretion)\n\n\n\n**Color and theming**\n\n**Contrast and readability** \nThe tooltip ensures sufficient contrast between its background and the text it houses, in all themes. \n\n**Contextual theming** \nFor data vis, tooltip styling may match the visualisation theme (light or dark) for consistency.\n\n\n\n**Overflow and constraints**\n\n**Viewport boundaries** \nTooltips must remain fully visible within the viewport. If necessary, reposition or constrain width.\n\n**Content overflow** \nAvoid scrolling within tooltips. If content exceeds reasonable limits, use a more appropriate pattern (e.g.modal – do we have this?)";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:parentComponent ds:global.component.
|
|
13
|
+
ds:parentComponent ds:global.component.tooltip_data;
|
|
14
14
|
ds:hasTokenBinding [
|
|
15
15
|
a ds:TokenBinding;
|
|
16
16
|
ds:viaBlock ds:global.subcomponent.chart_legend;
|
|
@@ -10,7 +10,7 @@ ds:global.subcomponent.chart_legend_item a ds:Subcomponent;
|
|
|
10
10
|
ds:usage "";
|
|
11
11
|
ds:guidelines "";
|
|
12
12
|
ds:tier ds:global;
|
|
13
|
-
ds:parentComponent ds:global.component.
|
|
13
|
+
ds:parentComponent ds:global.component.tooltip_data;
|
|
14
14
|
ds:hasTokenBinding [
|
|
15
15
|
a ds:TokenBinding;
|
|
16
16
|
ds:viaBlock ds:global.subcomponent.chart_legend_item;
|