@ids-group-ltd/ids-design-system 1.1.1 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (234) hide show
  1. package/CHANGELOG.md +869 -0
  2. package/agent/INDEX.md +8 -7
  3. package/agent/charts/ds-scatter-chart.md +1 -1
  4. package/agent/feedback/ds-badge.md +2 -2
  5. package/agent/feedback/ds-chat-message.md +1 -1
  6. package/agent/feedback/ds-chat-step.md +2 -2
  7. package/agent/feedback/ds-chat-thread.md +1 -1
  8. package/agent/feedback/ds-empty-state.md +2 -1
  9. package/agent/feedback/ds-stat.md +1 -1
  10. package/agent/feedback/ds-toast.md +2 -2
  11. package/agent/feedback/ds-tree.md +4 -2
  12. package/agent/forms/ds-button.md +3 -3
  13. package/agent/forms/ds-chat-input.md +3 -3
  14. package/agent/forms/ds-dropzone.md +1 -1
  15. package/agent/forms/ds-icon-button.md +3 -3
  16. package/agent/forms/ds-number-stepper.md +3 -3
  17. package/agent/forms/ds-search.md +1 -1
  18. package/agent/forms/ds-split-button.md +1 -1
  19. package/agent/foundations/tokens.md +4 -3
  20. package/agent/navigation/ds-app-layout.md +1 -1
  21. package/agent/navigation/ds-nav-divider.md +6 -0
  22. package/agent/navigation/{ds-sidenav-footer.md → ds-nav-footer.md} +3 -3
  23. package/agent/navigation/{ds-sidenav-group.md → ds-nav-group.md} +2 -2
  24. package/agent/navigation/{ds-sidenav-item.md → ds-nav-item.md} +6 -6
  25. package/agent/navigation/ds-nav.md +15 -0
  26. package/agent/navigation/ds-splitter.md +1 -1
  27. package/agent/overlays/ds-drawer.md +1 -1
  28. package/agent/platform/toast-service.md +1 -1
  29. package/components/README.md +24 -24
  30. package/components.md +60 -51
  31. package/design-system.md +8 -7
  32. package/eslint/deprecated-api.json +108 -7
  33. package/fesm2022/ids-group-ltd-ids-design-system-components-accordion.mjs +2 -2
  34. package/fesm2022/ids-group-ltd-ids-design-system-components-accordion.mjs.map +1 -1
  35. package/fesm2022/ids-group-ltd-ids-design-system-components-alert.mjs +2 -2
  36. package/fesm2022/ids-group-ltd-ids-design-system-components-alert.mjs.map +1 -1
  37. package/fesm2022/ids-group-ltd-ids-design-system-components-app-layout.mjs +4 -4
  38. package/fesm2022/ids-group-ltd-ids-design-system-components-app-layout.mjs.map +1 -1
  39. package/fesm2022/ids-group-ltd-ids-design-system-components-auth-layout.mjs +4 -4
  40. package/fesm2022/ids-group-ltd-ids-design-system-components-auth-layout.mjs.map +1 -1
  41. package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs +2 -2
  42. package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs.map +1 -1
  43. package/fesm2022/ids-group-ltd-ids-design-system-components-avatar.mjs +2 -2
  44. package/fesm2022/ids-group-ltd-ids-design-system-components-avatar.mjs.map +1 -1
  45. package/fesm2022/ids-group-ltd-ids-design-system-components-badge-badge-count-roll.component-BDNXADJZ.mjs +182 -0
  46. package/fesm2022/ids-group-ltd-ids-design-system-components-badge-badge-count-roll.component-BDNXADJZ.mjs.map +1 -0
  47. package/fesm2022/ids-group-ltd-ids-design-system-components-badge.mjs +37 -8
  48. package/fesm2022/ids-group-ltd-ids-design-system-components-badge.mjs.map +1 -1
  49. package/fesm2022/ids-group-ltd-ids-design-system-components-banner.mjs +2 -2
  50. package/fesm2022/ids-group-ltd-ids-design-system-components-banner.mjs.map +1 -1
  51. package/fesm2022/ids-group-ltd-ids-design-system-components-breadcrumbs.mjs +5 -2
  52. package/fesm2022/ids-group-ltd-ids-design-system-components-breadcrumbs.mjs.map +1 -1
  53. package/fesm2022/ids-group-ltd-ids-design-system-components-button-group.mjs +2 -2
  54. package/fesm2022/ids-group-ltd-ids-design-system-components-button-group.mjs.map +1 -1
  55. package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs +76 -5
  56. package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs.map +1 -1
  57. package/fesm2022/ids-group-ltd-ids-design-system-components-calendar-day.mjs +2 -2
  58. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs +2 -2
  59. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs.map +1 -1
  60. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs +2 -2
  61. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs.map +1 -1
  62. package/fesm2022/ids-group-ltd-ids-design-system-components-chat.mjs +122 -21
  63. package/fesm2022/ids-group-ltd-ids-design-system-components-chat.mjs.map +1 -1
  64. package/fesm2022/ids-group-ltd-ids-design-system-components-checkbox.mjs +2 -2
  65. package/fesm2022/ids-group-ltd-ids-design-system-components-checkbox.mjs.map +1 -1
  66. package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs +2 -2
  67. package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs.map +1 -1
  68. package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs +2 -2
  69. package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs.map +1 -1
  70. package/fesm2022/ids-group-ltd-ids-design-system-components-definition-term.mjs +2 -2
  71. package/fesm2022/ids-group-ltd-ids-design-system-components-definition-term.mjs.map +1 -1
  72. package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs +2 -2
  73. package/fesm2022/ids-group-ltd-ids-design-system-components-description-list.mjs.map +1 -1
  74. package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs +65 -4
  75. package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs.map +1 -1
  76. package/fesm2022/ids-group-ltd-ids-design-system-components-dropzone.mjs +76 -9
  77. package/fesm2022/ids-group-ltd-ids-design-system-components-dropzone.mjs.map +1 -1
  78. package/fesm2022/ids-group-ltd-ids-design-system-components-empty-state.mjs +14 -7
  79. package/fesm2022/ids-group-ltd-ids-design-system-components-empty-state.mjs.map +1 -1
  80. package/fesm2022/ids-group-ltd-ids-design-system-components-field-group.mjs +2 -2
  81. package/fesm2022/ids-group-ltd-ids-design-system-components-field-group.mjs.map +1 -1
  82. package/fesm2022/ids-group-ltd-ids-design-system-components-funnel-chart.mjs +2 -2
  83. package/fesm2022/ids-group-ltd-ids-design-system-components-heatmap-chart.mjs +2 -2
  84. package/fesm2022/ids-group-ltd-ids-design-system-components-heatmap-chart.mjs.map +1 -1
  85. package/fesm2022/ids-group-ltd-ids-design-system-components-icon-button.mjs +6 -4
  86. package/fesm2022/ids-group-ltd-ids-design-system-components-icon-button.mjs.map +1 -1
  87. package/fesm2022/ids-group-ltd-ids-design-system-components-info-hint.mjs +2 -2
  88. package/fesm2022/ids-group-ltd-ids-design-system-components-info-hint.mjs.map +1 -1
  89. package/fesm2022/ids-group-ltd-ids-design-system-components-inline-edit.mjs +2 -2
  90. package/fesm2022/ids-group-ltd-ids-design-system-components-inline-edit.mjs.map +1 -1
  91. package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs +2 -2
  92. package/fesm2022/ids-group-ltd-ids-design-system-components-input.mjs.map +1 -1
  93. package/fesm2022/ids-group-ltd-ids-design-system-components-list.mjs +2 -2
  94. package/fesm2022/ids-group-ltd-ids-design-system-components-menu.mjs +4 -4
  95. package/fesm2022/ids-group-ltd-ids-design-system-components-menu.mjs.map +1 -1
  96. package/fesm2022/ids-group-ltd-ids-design-system-components-modal.mjs +2 -2
  97. package/fesm2022/ids-group-ltd-ids-design-system-components-modal.mjs.map +1 -1
  98. package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs +2 -2
  99. package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs.map +1 -1
  100. package/fesm2022/ids-group-ltd-ids-design-system-components-nav-footer.mjs +113 -0
  101. package/fesm2022/ids-group-ltd-ids-design-system-components-nav-footer.mjs.map +1 -0
  102. package/fesm2022/ids-group-ltd-ids-design-system-components-nav.mjs +228 -0
  103. package/fesm2022/ids-group-ltd-ids-design-system-components-nav.mjs.map +1 -0
  104. package/fesm2022/ids-group-ltd-ids-design-system-components-number-stepper.mjs +61 -10
  105. package/fesm2022/ids-group-ltd-ids-design-system-components-number-stepper.mjs.map +1 -1
  106. package/fesm2022/ids-group-ltd-ids-design-system-components-otp-input.mjs +2 -2
  107. package/fesm2022/ids-group-ltd-ids-design-system-components-otp-input.mjs.map +1 -1
  108. package/fesm2022/ids-group-ltd-ids-design-system-components-pagination.mjs +36 -4
  109. package/fesm2022/ids-group-ltd-ids-design-system-components-pagination.mjs.map +1 -1
  110. package/fesm2022/ids-group-ltd-ids-design-system-components-pie-chart.mjs +2 -2
  111. package/fesm2022/ids-group-ltd-ids-design-system-components-popover.mjs +9 -2
  112. package/fesm2022/ids-group-ltd-ids-design-system-components-popover.mjs.map +1 -1
  113. package/fesm2022/ids-group-ltd-ids-design-system-components-radio-group.mjs +2 -2
  114. package/fesm2022/ids-group-ltd-ids-design-system-components-radio-group.mjs.map +1 -1
  115. package/fesm2022/ids-group-ltd-ids-design-system-components-reveal.mjs +56 -0
  116. package/fesm2022/ids-group-ltd-ids-design-system-components-reveal.mjs.map +1 -0
  117. package/fesm2022/ids-group-ltd-ids-design-system-components-scatter-chart.mjs +10 -39
  118. package/fesm2022/ids-group-ltd-ids-design-system-components-scatter-chart.mjs.map +1 -1
  119. package/fesm2022/ids-group-ltd-ids-design-system-components-search.mjs +7 -4
  120. package/fesm2022/ids-group-ltd-ids-design-system-components-search.mjs.map +1 -1
  121. package/fesm2022/ids-group-ltd-ids-design-system-components-segmented.mjs +33 -6
  122. package/fesm2022/ids-group-ltd-ids-design-system-components-segmented.mjs.map +1 -1
  123. package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs +2 -2
  124. package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs.map +1 -1
  125. package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav-footer.mjs +4 -98
  126. package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav-footer.mjs.map +1 -1
  127. package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs +11 -179
  128. package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs.map +1 -1
  129. package/fesm2022/ids-group-ltd-ids-design-system-components-skeleton.mjs +2 -2
  130. package/fesm2022/ids-group-ltd-ids-design-system-components-skeleton.mjs.map +1 -1
  131. package/fesm2022/ids-group-ltd-ids-design-system-components-slider.mjs +2 -2
  132. package/fesm2022/ids-group-ltd-ids-design-system-components-slider.mjs.map +1 -1
  133. package/fesm2022/ids-group-ltd-ids-design-system-components-split-button.mjs +3 -2
  134. package/fesm2022/ids-group-ltd-ids-design-system-components-split-button.mjs.map +1 -1
  135. package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs +68 -5
  136. package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs.map +1 -1
  137. package/fesm2022/ids-group-ltd-ids-design-system-components-stepper.mjs +2 -2
  138. package/fesm2022/ids-group-ltd-ids-design-system-components-stepper.mjs.map +1 -1
  139. package/fesm2022/ids-group-ltd-ids-design-system-components-switch.mjs +2 -2
  140. package/fesm2022/ids-group-ltd-ids-design-system-components-switch.mjs.map +1 -1
  141. package/fesm2022/ids-group-ltd-ids-design-system-components-table-columns.mjs +2 -2
  142. package/fesm2022/ids-group-ltd-ids-design-system-components-table-columns.mjs.map +1 -1
  143. package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs +2 -2
  144. package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs.map +1 -1
  145. package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs +41 -3
  146. package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs.map +1 -1
  147. package/fesm2022/ids-group-ltd-ids-design-system-components-tag.mjs +2 -2
  148. package/fesm2022/ids-group-ltd-ids-design-system-components-tag.mjs.map +1 -1
  149. package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs +6 -4
  150. package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs.map +1 -1
  151. package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs +4 -4
  152. package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs.map +1 -1
  153. package/fesm2022/ids-group-ltd-ids-design-system-components-timeline.mjs +27 -7
  154. package/fesm2022/ids-group-ltd-ids-design-system-components-timeline.mjs.map +1 -1
  155. package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs +54 -19
  156. package/fesm2022/ids-group-ltd-ids-design-system-components-toast.mjs.map +1 -1
  157. package/fesm2022/ids-group-ltd-ids-design-system-components-toggle-button.mjs +2 -2
  158. package/fesm2022/ids-group-ltd-ids-design-system-components-toggle-button.mjs.map +1 -1
  159. package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs +8 -7
  160. package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs.map +1 -1
  161. package/fesm2022/ids-group-ltd-ids-design-system-components-tree.mjs +58 -9
  162. package/fesm2022/ids-group-ltd-ids-design-system-components-tree.mjs.map +1 -1
  163. package/fesm2022/ids-group-ltd-ids-design-system-components-w3w.mjs +2 -2
  164. package/fesm2022/ids-group-ltd-ids-design-system-components-w3w.mjs.map +1 -1
  165. package/fesm2022/ids-group-ltd-ids-design-system-components.mjs +153 -1
  166. package/fesm2022/ids-group-ltd-ids-design-system-components.mjs.map +1 -1
  167. package/fesm2022/ids-group-ltd-ids-design-system-core.mjs +25 -1
  168. package/fesm2022/ids-group-ltd-ids-design-system-core.mjs.map +1 -1
  169. package/fesm2022/ids-group-ltd-ids-design-system.mjs +4 -1
  170. package/fesm2022/ids-group-ltd-ids-design-system.mjs.map +1 -1
  171. package/migrations/1.1.1.json +14 -4
  172. package/migrations/1.1.2.json +143 -0
  173. package/migrations/1.2.0.json +1433 -0
  174. package/migrations/README.md +11 -2
  175. package/package.json +28 -1
  176. package/schematics/check-overrides/index.cjs +28 -3
  177. package/schematics/check-overrides/scan.cjs +151 -2
  178. package/schematics/check-overrides/schema.json +4 -0
  179. package/schematics/check-overrides/surface.json +397 -73
  180. package/schematics/collection.json +1 -1
  181. package/stylelint/deprecated-tokens.json +7 -0
  182. package/stylelint/index.mjs +17 -3
  183. package/stylelint/known-tokens.mjs +139 -0
  184. package/stylelint/report.mjs +185 -0
  185. package/stylelint/tokens.mjs +160 -0
  186. package/stylelint/use-tokens.mjs +397 -0
  187. package/styles/_check-box.scss +6 -5
  188. package/styles/_dropdown-overlay.scss +6 -8
  189. package/styles/_ds-color.scss +7 -2
  190. package/styles/_field-state.scss +4 -2
  191. package/styles/_focus.scss +12 -5
  192. package/styles/_link.scss +4 -4
  193. package/styles/_optical-center.scss +29 -0
  194. package/styles/_reveal.scss +8 -0
  195. package/styles/_status.scss +17 -7
  196. package/styles/_step-marker.scss +192 -6
  197. package/styles/_surface-level.scss +16 -0
  198. package/styles/_text-shimmer.scss +21 -0
  199. package/styles/_theme-activation.scss +17 -4
  200. package/styles/_tokens.scss +34 -7
  201. package/styles/ds.scss +1 -0
  202. package/themes/README.md +16 -21
  203. package/themes/_semantic.scss +134 -61
  204. package/themes/dark/_theme.scss +20 -24
  205. package/types/ids-group-ltd-ids-design-system-components-app-layout.d.ts +3 -3
  206. package/types/ids-group-ltd-ids-design-system-components-auth-layout.d.ts +2 -2
  207. package/types/ids-group-ltd-ids-design-system-components-badge.d.ts +20 -1
  208. package/types/ids-group-ltd-ids-design-system-components-button.d.ts +14 -3
  209. package/types/ids-group-ltd-ids-design-system-components-chat.d.ts +67 -6
  210. package/types/ids-group-ltd-ids-design-system-components-drawer.d.ts +9 -1
  211. package/types/ids-group-ltd-ids-design-system-components-dropzone.d.ts +28 -2
  212. package/types/ids-group-ltd-ids-design-system-components-empty-state.d.ts +7 -2
  213. package/types/ids-group-ltd-ids-design-system-components-icon-button.d.ts +8 -5
  214. package/types/ids-group-ltd-ids-design-system-components-nav-footer.d.ts +88 -0
  215. package/types/ids-group-ltd-ids-design-system-components-nav.d.ts +152 -0
  216. package/types/ids-group-ltd-ids-design-system-components-number-stepper.d.ts +21 -3
  217. package/types/ids-group-ltd-ids-design-system-components-pagination.d.ts +1 -0
  218. package/types/ids-group-ltd-ids-design-system-components-reveal.d.ts +31 -0
  219. package/types/ids-group-ltd-ids-design-system-components-scatter-chart.d.ts +2 -8
  220. package/types/ids-group-ltd-ids-design-system-components-search.d.ts +4 -1
  221. package/types/ids-group-ltd-ids-design-system-components-segmented.d.ts +3 -0
  222. package/types/ids-group-ltd-ids-design-system-components-sidenav-footer.d.ts +12 -83
  223. package/types/ids-group-ltd-ids-design-system-components-sidenav.d.ts +21 -131
  224. package/types/ids-group-ltd-ids-design-system-components-split-button.d.ts +1 -1
  225. package/types/ids-group-ltd-ids-design-system-components-stat.d.ts +10 -1
  226. package/types/ids-group-ltd-ids-design-system-components-tabs.d.ts +1 -0
  227. package/types/ids-group-ltd-ids-design-system-components-textarea.d.ts +1 -1
  228. package/types/ids-group-ltd-ids-design-system-components-timeline.d.ts +3 -1
  229. package/types/ids-group-ltd-ids-design-system-components-toast.d.ts +27 -6
  230. package/types/ids-group-ltd-ids-design-system-components-tree.d.ts +26 -4
  231. package/types/ids-group-ltd-ids-design-system-components.d.ts +26 -1
  232. package/types/ids-group-ltd-ids-design-system-core.d.ts +38 -2
  233. package/types/ids-group-ltd-ids-design-system.d.ts +10 -7
  234. package/agent/navigation/ds-sidenav.md +0 -13
@@ -8,8 +8,9 @@
8
8
  // shipped: (bg: #E1EFFF, text: #0A6DB3),
9
9
  // ));
10
10
  //
11
- // Map entry: (bg:, text?:, dot?:). `bg` is the badge fill, `text` the badge label (unset:
12
- // --text-secondary), `dot` the ds-status-dot colour (unset: `text`).
11
+ // Map entry: (bg:, text?:, dot?:, border?:). `bg` is the badge fill, `text` the badge label (unset:
12
+ // --text-secondary), `dot` the ds-status-dot colour and the badge icon colour (unset: `text`),
13
+ // `border` the border of a `lozenge` badge (unset: --border-default).
13
14
 
14
15
  @use 'sass:map';
15
16
 
@@ -18,6 +19,7 @@
18
19
  $bg: map.get($spec, bg);
19
20
  $text: map.get($spec, text);
20
21
  $dot: map.get($spec, dot);
22
+ $border: map.get($spec, border);
21
23
 
22
24
  ds-badge[data-status='#{$name}'] {
23
25
  --ds-badge-bg-color: #{$bg};
@@ -25,6 +27,14 @@
25
27
  @if $text {
26
28
  --ds-badge-label-color: #{$text};
27
29
  }
30
+
31
+ @if $dot {
32
+ --ds-badge-icon-color: #{$dot};
33
+ }
34
+
35
+ @if $border {
36
+ --ds-badge-border-color: #{$border};
37
+ }
28
38
  }
29
39
 
30
40
  ds-status-dot[data-status='#{$name}'] {
@@ -40,10 +50,10 @@
40
50
  // Opt-in: emitted only when called.
41
51
  @mixin semantic-preset {
42
52
  @include define((
43
- info: (bg: var(--info-subtitle), text: var(--info-text), dot: var(--info)),
44
- success: (bg: var(--success-subtitle), text: var(--success-text), dot: var(--success)),
45
- warning: (bg: var(--warning-subtitle), text: var(--warning-text), dot: var(--warning)),
46
- error: (bg: var(--error-subtitle), text: var(--error-text), dot: var(--error)),
47
- neutral: (bg: var(--surface-secondary), text: var(--text-secondary),dot: var(--icon-muted)),
53
+ info: (bg: var(--info-subtitle), text: var(--info-text), dot: var(--info), border: var(--info-border)),
54
+ success: (bg: var(--success-subtitle), text: var(--success-text), dot: var(--success), border: var(--success-border)),
55
+ warning: (bg: var(--warning-subtitle), text: var(--warning-text), dot: var(--warning), border: var(--warning-border)),
56
+ error: (bg: var(--error-subtitle), text: var(--error-text), dot: var(--error), border: var(--error-border)),
57
+ neutral: (bg: var(--surface-secondary), text: var(--text-secondary),dot: var(--icon-muted), border: var(--border-default)),
48
58
  ));
49
59
  }
@@ -1,10 +1,20 @@
1
1
  // The step marker shared by ds-timeline-item and ds-chat-step, read from the host's `--_<prefix>-node-*`
2
- // properties: the ring, its fill and the centred glyph.
3
- @mixin node($prefix, $border-width) {
2
+ // properties: the ring, its fill and the centred glyph. A status change fades the colours and
3
+ // cross-fades the dashed ring of a planned step. The spinner arrives as an arc growing to its length;
4
+ // a glyph arriving closes the arc into a ring, grows the fill out of it and draws the glyph stroke by
5
+ // stroke (`prepareMarkerStrokes` splits the strokes). Every one-shot duration is zero under
6
+ // `prefers-reduced-motion: reduce`.
7
+ @property --_step-arc-sweep {
8
+ syntax: '<angle>';
9
+ inherits: true;
10
+ initial-value: 90deg;
11
+ }
12
+
13
+ @mixin node($prefix, $border-width, $spinner-size) {
4
14
  .node {
5
- display: inline-flex;
6
- align-items: center;
7
- justify-content: center;
15
+ position: relative;
16
+ display: inline-grid;
17
+ place-items: center;
8
18
  flex: none;
9
19
  width: var(--_#{$prefix}-node-size);
10
20
  height: var(--_#{$prefix}-node-size);
@@ -12,6 +22,178 @@
12
22
  background-color: var(--_#{$prefix}-node-bg-color);
13
23
  color: var(--_#{$prefix}-node-color);
14
24
  border: $border-width solid var(--_#{$prefix}-node-border-color);
25
+ transition-property: background-color, border-color, color;
26
+ transition-duration: var(--duration-base);
27
+ transition-timing-function: var(--ease-standard);
28
+
29
+ // A dashed border cannot fade into a solid one, so the dashes are a layer of their own.
30
+ &::before {
31
+ content: '';
32
+ position: absolute;
33
+ inset: calc(-1 * #{$border-width});
34
+ box-sizing: border-box;
35
+ border: $border-width dashed var(--_#{$prefix}-node-border-color);
36
+ border-radius: inherit;
37
+ opacity: 0;
38
+ transition: opacity var(--duration-base) var(--ease-standard);
39
+ }
40
+ }
41
+
42
+ .mark {
43
+ grid-area: 1 / 1;
44
+ display: inline-flex;
45
+ }
46
+
47
+ :host(.is-settled) {
48
+ --_step-arc-close: var(--duration-slow);
49
+ --_step-fill-delay: calc(var(--duration-slow) * 0.75);
50
+ --_step-draw-delay: calc(var(--_step-fill-delay) + var(--duration-base) * 0.6);
51
+ --_step-draw-stagger: calc(var(--duration-fast) * 0.6);
52
+
53
+ .mark-in:has(> ds-spinner) {
54
+ animation: ds-step-arc-grow var(--duration-slow) var(--ease-standard) both;
55
+
56
+ ds-spinner {
57
+ mask: conic-gradient(
58
+ from -45deg,
59
+ var(--surface-default) var(--_step-arc-sweep),
60
+ transparent 0 90deg,
61
+ var(--surface-default) 0
62
+ );
63
+ }
64
+ }
65
+
66
+ .mark-out {
67
+ animation: ds-step-mark-out var(--ds-motion-check-exit-duration)
68
+ var(--ds-motion-check-exit-easing) both;
69
+ }
70
+
71
+ // A glyph arriving takes the spinner's arc over where it stands, so the spinner goes at once.
72
+ .node:has(> .mark > ds-icon) > .mark-out:has(> ds-spinner) {
73
+ display: none;
74
+ }
75
+
76
+ // Angular keeps the enter class while the element's own animation runs, so the glyph's mark holds
77
+ // one as long as the fill and the strokes it carries.
78
+ .mark-in:has(> ds-icon) {
79
+ animation: ds-step-mark-hold
80
+ calc(var(--_step-draw-delay) + var(--duration-base) + var(--_step-draw-stagger)) linear both;
81
+
82
+ &::before {
83
+ content: '';
84
+ position: absolute;
85
+ inset: calc(-1 * #{$border-width});
86
+ border-radius: var(--radius-pill);
87
+ background-color: var(--_#{$prefix}-node-bg-color);
88
+ animation: ds-step-fill var(--duration-base) var(--ease-decelerate) var(--_step-fill-delay) both;
89
+ --_step-fill-from: calc((var(--_#{$prefix}-node-size) - #{$spinner-size}) / 2 - #{$border-width});
90
+ }
91
+
92
+ // The spinner's arc in the new colour, from the angle and length `holdMarkerArc` read off the
93
+ // spinner: its tail keeps the spinner's turn while its head runs on round to a full ring.
94
+ &::after {
95
+ content: '';
96
+ position: absolute;
97
+ top: 50%;
98
+ left: 50%;
99
+ width: #{$spinner-size};
100
+ height: #{$spinner-size};
101
+ box-sizing: border-box;
102
+ translate: -50% -50%;
103
+ border: #{$border-width} solid var(--_#{$prefix}-node-border-color);
104
+ border-radius: var(--radius-pill);
105
+ mask: conic-gradient(
106
+ from -45deg,
107
+ var(--surface-default) var(--_step-arc-sweep),
108
+ transparent 0
109
+ );
110
+ animation:
111
+ ds-step-arc-close var(--_step-arc-close) var(--ease-standard) both,
112
+ ds-step-arc-turn var(--duration-loop-fast) linear both;
113
+ }
114
+
115
+ ds-icon {
116
+ position: relative;
117
+ }
118
+
119
+ ::ng-deep svg > * {
120
+ stroke-dasharray: 1 2;
121
+ animation: ds-step-stroke var(--duration-base) var(--ease-standard) var(--_step-draw-delay) both;
122
+ }
123
+
124
+ ::ng-deep svg > * + * {
125
+ animation-delay: calc(var(--_step-draw-delay) + var(--_step-draw-stagger));
126
+ }
127
+ }
128
+
129
+ // The ring stays unfilled until the growing fill reaches its edge. Keyed on the glyph, not on the
130
+ // enter class, which Angular adds a task after the status changes.
131
+ .node:has(> .mark > ds-icon) {
132
+ transition-delay: calc(var(--_step-fill-delay) + var(--duration-base)), 0s, 0s;
133
+ }
134
+ }
135
+
136
+ @at-root {
137
+ @keyframes ds-step-arc-grow {
138
+ from {
139
+ opacity: 0;
140
+ --_step-arc-sweep: 0deg;
141
+ }
142
+ }
143
+
144
+ @keyframes ds-step-mark-out {
145
+ to {
146
+ opacity: 0;
147
+ scale: 0.4;
148
+ }
149
+ }
150
+
151
+ @keyframes ds-step-mark-hold {
152
+ to {
153
+ opacity: 1;
154
+ }
155
+ }
156
+
157
+ @keyframes ds-step-arc-close {
158
+ from {
159
+ --_step-arc-sweep: var(--_step-arc-length, 90deg);
160
+ }
161
+ to {
162
+ --_step-arc-sweep: 360deg;
163
+ }
164
+ }
165
+
166
+ @keyframes ds-step-arc-turn {
167
+ from {
168
+ rotate: var(--_step-arc-from, 0deg);
169
+ }
170
+ to {
171
+ rotate: calc(var(--_step-arc-from, 0deg) + 1turn);
172
+ }
173
+ }
174
+
175
+ @keyframes ds-step-fill {
176
+ 0% {
177
+ opacity: 0;
178
+ inset: var(--_step-fill-from);
179
+ }
180
+ 0.1% {
181
+ opacity: 1;
182
+ }
183
+ }
184
+
185
+ @keyframes ds-step-stroke {
186
+ 0% {
187
+ opacity: 0;
188
+ stroke-dashoffset: 1;
189
+ }
190
+ 0.1% {
191
+ opacity: 1;
192
+ }
193
+ 100% {
194
+ stroke-dashoffset: 0;
195
+ }
196
+ }
15
197
  }
16
198
  }
17
199
 
@@ -40,7 +222,11 @@
40
222
 
41
223
  :host([data-status='pending']) {
42
224
  .node {
43
- border-style: dashed;
225
+ border-color: transparent;
226
+
227
+ &::before {
228
+ opacity: 1;
229
+ }
44
230
  }
45
231
 
46
232
  .heading {
@@ -0,0 +1,16 @@
1
+ // The one list of roles an overlay rebinds to its level, so a row inside it keeps its hover, muted
2
+ // and selected fills one step off the overlay's own fill. Every overlay includes it; a role added here
3
+ // reaches all of them.
4
+ @mixin overlay($level: 'overlay') {
5
+ --surface-secondary: var(--surface-#{$level}-secondary);
6
+ --surface-muted: var(--surface-#{$level}-muted);
7
+ --surface-tint: var(--surface-#{$level}-tint);
8
+ --accent-surface-tint: var(--surface-#{$level}-tint);
9
+ --accent-strong: var(--accent-strong-overlay);
10
+ }
11
+
12
+ // A coloured surface (an alert, a banner) turns the ghost and outline state overlay from the control's
13
+ // own colour to the theme's neutral one, so hover shades the surface instead of mixing two hues.
14
+ @mixin tinted {
15
+ --state-overlay: var(--state-overlay-tinted);
16
+ }
@@ -0,0 +1,21 @@
1
+ // A highlight that sweeps across a line of text in a loop, for the line that says work is under way.
2
+ // The keyframes are emitted where the mixin is included: emulated encapsulation renames an animation
3
+ // and its keyframes together only inside one component stylesheet. Under
4
+ // `prefers-reduced-motion: reduce` nothing is drawn and the text keeps its own colour.
5
+ @mixin sweep($base, $highlight) {
6
+ @media (prefers-reduced-motion: no-preference) {
7
+ background: linear-gradient(90deg, $base 40%, $highlight 50%, $base 60%) 100% 0 / 300% 100%
8
+ no-repeat;
9
+ background-clip: text;
10
+ color: transparent;
11
+ animation: ds-text-shimmer var(--duration-loop-slow) linear infinite;
12
+ }
13
+
14
+ @at-root {
15
+ @keyframes ds-text-shimmer {
16
+ to {
17
+ background-position: 0 0;
18
+ }
19
+ }
20
+ }
21
+ }
@@ -1,14 +1,17 @@
1
- // Light applies at bare :root. Dark is opt-in via <html data-theme="dark">; its block declares the complete
2
- // token set, so it replaces light rather than patching it. No automatic prefers-color-scheme switch:
3
- // opt in with provideDsTheme({ followSystem: true }). The dark block comes last so it wins over the
4
- // light-context overrides (brand-gray neutrals) at equal specificity.
1
+ // The input colours (--primary, the channels, the -on colours) and light apply at bare :root. Dark is
2
+ // opt-in via <html data-theme="dark">; its block declares every formula again, so it replaces light
3
+ // rather than patching it, and never an input, so a brand that sets --primary once is read by both. No
4
+ // automatic prefers-color-scheme switch: opt in with provideDsTheme({ followSystem: true }). The dark
5
+ // block comes last so it wins over the light-context overrides (brand-gray neutrals) at equal specificity.
5
6
 
7
+ @use '../themes/semantic';
6
8
  @use '../themes/light/theme' as light;
7
9
  @use '../themes/dark/theme' as dark;
8
10
 
9
11
  :root {
10
12
  color-scheme: light; // opts out of UA force-dark
11
13
 
14
+ @include semantic.inputs;
12
15
  @include light.theme;
13
16
  }
14
17
 
@@ -34,3 +37,13 @@
34
37
 
35
38
  @include dark.theme;
36
39
  }
40
+
41
+ // Forced colours paint every field border CanvasText, so a disabled field would read as an enabled
42
+ // one; a system colour is kept by the browser where an author colour is not.
43
+ @media (forced-colors: active) {
44
+ :root,
45
+ :root[data-theme='dark'] {
46
+ --border-disabled: GrayText;
47
+ --text-disabled: GrayText;
48
+ }
49
+ }
@@ -27,6 +27,7 @@
27
27
 
28
28
  --radius-0: 0;
29
29
  --radius-sm: 4px;
30
+ --radius-sm-md: 6px;
30
31
  --radius-md: 8px;
31
32
  --radius-lg: 12px;
32
33
  --radius-xl: 16px;
@@ -40,7 +41,7 @@
40
41
  /* Radius roles: components resolve --ds-<comp>-radius -> role -> value. No `field` role; scope
41
42
  the control role instead: `ds-input { --ds-radius-control: 4px; }`. */
42
43
  --ds-radius-inner: var(--radius-sm);
43
- --ds-radius-control: var(--radius-md);
44
+ --ds-radius-control: var(--radius-sm-md);
44
45
  --ds-radius-panel: var(--radius-lg);
45
46
  --ds-radius-pill: var(--radius-pill);
46
47
 
@@ -110,6 +111,11 @@
110
111
  --duration-loop-fast: 700ms;
111
112
  --duration-loop-slow: 1400ms;
112
113
 
114
+ /* Items entering one after another (`dsReveal`): each waits one step more than the one before,
115
+ and items past `--stagger-max` wait no longer, so a long list finishes within max x step. */
116
+ --stagger-step: 40ms;
117
+ --stagger-max: 7;
118
+
113
119
  /* Easing: `settle` is a critically damped spring, so a growing mark never overshoots and never shows a value the data does not hold. */
114
120
  --ease-standard: cubic-bezier(.2, 0, 0, 1);
115
121
  --ease-emphasized: cubic-bezier(.3, 0, .1, 1.4);
@@ -239,13 +245,17 @@
239
245
 
240
246
  --ds-surface-padding: var(--space-6);
241
247
 
242
- /* Fields get the soft halo, controls and nav the crisp ring. Use the flat tokens, not the
248
+ /* A field's focus is one more border width outside its border, in the border's own colour, so the two
249
+ read as one crisp ring; a warning field draws its border, and its ring when focused, in the
250
+ opaque warning hue. `data-focus="halo"` draws the soft halo instead. Use the flat tokens, not the
243
251
  --accent-focus-* aliases: a `var()` inside a custom property is substituted where it is
244
252
  declared, so a ds-color zone could never reach it. */
245
- --ds-field-focus-shadow: var(--focus-field);
246
- --ds-field-focus-shadow-error: var(--focus-field-error);
247
- --ds-field-focus-shadow-warning: var(--focus-field-warning);
248
- --ds-field-focus-shadow-success: var(--focus-field-success);
253
+ --ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);
254
+ --ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error);
255
+ --ds-field-focus-shadow-warning: 0 0 0 var(--border-width-default) hsl(var(--warning-h) var(--warning-s) var(--warning-l));
256
+ --ds-field-focus-border-warning: hsl(var(--warning-h) var(--warning-s) var(--warning-l));
257
+ --ds-field-border-warning: hsl(var(--warning-h) var(--warning-s) var(--warning-l));
258
+ --ds-field-focus-shadow-success: 0 0 0 var(--border-width-default) var(--success);
249
259
  --ds-control-focus-shadow: var(--focus-ring);
250
260
  --ds-control-focus-shadow-error: var(--focus-ring-error);
251
261
 
@@ -307,7 +317,7 @@
307
317
  --stepper-bar-h: 2px;
308
318
 
309
319
  --segmented-btn-h: var(--hit-sm);
310
- --segmented-r-inner: var(--radius-md);
320
+ --segmented-r-inner: var(--ds-radius-control);
311
321
  --segmented-pad: 2px;
312
322
 
313
323
  --sidenav-w: 240px;
@@ -398,6 +408,7 @@
398
408
  --tooltip-border-color: var(--border-overlay);
399
409
 
400
410
  --popover-maxw: 320px;
411
+ --popover-pad: var(--space-3);
401
412
 
402
413
  --toast-minw: 320px;
403
414
  --toast-maxw: 480px;
@@ -494,6 +505,7 @@
494
505
  --duration-slow: 0ms;
495
506
  --duration-slower: 0ms;
496
507
  --duration-slowest: 0ms;
508
+ --stagger-step: 0ms;
497
509
  --ds-motion-chart-tooltip-move-duration: 0ms;
498
510
 
499
511
  /* Loops are slowed, never frozen: a stopped spinner reads as "hung". The skeleton sweep is the
@@ -508,6 +520,14 @@
508
520
  }
509
521
  }
510
522
 
523
+ /* Tokens derived from --hit-* resolve where they are declared, so a [data-density] below :root
524
+ re-derives them or keeps the :root heights. */
525
+ [data-density] {
526
+ --field-h-sm: var(--hit-min);
527
+ --field-h-md: var(--hit-cozy);
528
+ --sidenav-collapsed-item: var(--hit-cozy);
529
+ --calendar-cell-min: var(--hit-cozy);
530
+ }
511
531
  [data-density="ultra-compact"] {
512
532
  /* 24px hits sit below WCAG 2.5.5 (44px enhanced) and at the WCAG 2.5.8 minimum. Only for
513
533
  keyboard-first, mouse-driven screens the user opted into; never mobile or touch-first. */
@@ -529,6 +549,10 @@
529
549
  --table-cell-pad-x: var(--space-2);
530
550
  --table-cell-pad-y: var(--space-1);
531
551
  --table-head-pad-y: var(--space-1);
552
+ --tree-row-pad-y: var(--space-1);
553
+ --tree-row-pad-x: var(--space-2);
554
+ --tree-indent: var(--space-4);
555
+ --popover-pad: var(--space-2);
532
556
 
533
557
  /* One rung only: a card's frame reads as lost padding before its cells do (24 to 16, cells 16 to 8). */
534
558
  --ds-surface-padding: var(--space-4);
@@ -545,6 +569,9 @@
545
569
  --status-dot-size: 6px;
546
570
  --sidenav-w: 220px;
547
571
  --segmented-btn-h: 24px;
572
+ --tree-row-pad-y: var(--space-1);
573
+ --tree-row-pad-x: var(--space-2);
574
+ --tree-indent: var(--space-4);
548
575
  }
549
576
  [data-density="cozy"] {
550
577
  --hit-cozy: 40px;
package/styles/ds.scss CHANGED
@@ -26,5 +26,6 @@
26
26
  @forward 'toast-overlay';
27
27
  @forward 'surface-motion';
28
28
  @forward 'overlay-motion';
29
+ @forward 'reveal';
29
30
  @include bp-emit.emit-vars;
30
31
  @include focus-emit.emit-rules;
package/themes/README.md CHANGED
@@ -15,14 +15,14 @@ Colour is layered in three concerns: a **base palette** (theme-independent primi
15
15
  ## Files
16
16
 
17
17
  - **`_base-palette.scss`** — theme-independent primitives at `:root`: hue ramps (`--blue/red/green/yellow/sky/orange-*`) + HSL channels, `--cool-gray-*` / `--brand-gray-*` ramps, `--static-ink` (never flips), `--shadow-tint-h/s`, font families. Shared by every theme.
18
- - **`_semantic.scss`** — `@mixin roles`: the semantic role map (surfaces, text, icons, borders, primary/secondary/tertiary families, status, status-pills, focus). Structure is identical across themes; values resolve through each theme's own `--neutral-*` ramp. Holds the **light-default** values.
18
+ - **`_semantic.scss`** — `@mixin inputs`: the input colours every formula reads (`--primary`, `--primary-on`, the `--primary/secondary/tertiary/error/success/warning-h/s/l` channels, `--secondary`, `--tertiary` and their `-on`), emitted once at `:root` for every theme. `@mixin roles`: the semantic role map (surfaces, text, icons, borders, primary/secondary/tertiary families, status, status-pills, focus). Structure is identical across themes; values resolve through each theme's own `--neutral-*` ramp. Holds the **light-default** values.
19
19
  - **`light/_palette.scss` + `light/_theme.scss`** — `@mixin palette` (the `--neutral-*` slot = cool-gray + `--shadow-tint-l: 7%`) and `@mixin theme` (`palette` + `semantic.roles`). Light is the **default** skin and needs no extra overrides.
20
- - **`dark/_palette.scss` + `dark/_theme.scss`** — `@mixin palette` (dark neutral ramp + `--shadow-tint-l: 3%`) and `@mixin theme` (`palette` + `semantic.roles` + the value overrides that genuinely differ on dark: tint surfaces, on-tint text, hover/pressed mixed toward white, the overlay surfaces and border, scrim, `--shadow-1..4` alphas, focus-halo alpha, chart tokens).
21
- - **`../styles/_theme-activation.scss`** — applies light at `:root` and dark at `:root[data-theme='dark']`, plus the light-context `data-neutrals='brand'` switch.
20
+ - **`dark/_palette.scss` + `dark/_theme.scss`** — `@mixin palette` (dark neutral ramp + `--shadow-tint-l: 3%`) and `@mixin theme` (`palette` + `semantic.roles` + the formula overrides that genuinely differ on dark: tint surfaces, on-tint text, hover/pressed mixed toward white, the overlay surfaces and border, scrim, `--shadow-1..4` alphas, focus-halo alpha, chart tokens).
21
+ - **`../styles/_theme-activation.scss`** — applies the inputs and light at `:root` and dark at `:root[data-theme='dark']`, plus the light-context `data-neutrals='brand'` switch.
22
22
 
23
23
  `styles/ds.scss` forwards `_base-palette` then `theme-activation` (before `tokens`), so `@use 'styles/ds';` renders light out of the box.
24
24
 
25
- **Why sibling themes (not a dark "patch"):** the dark block declares the COMPLETE token set (`@include palette` + `@include semantic.roles` + its own overrides), so `:root[data-theme='dark']` fully replaces light rather than delta-patching it. The `@mixin roles` in `_semantic.scss` is an authoring-DRY device (the light-default structure both themes share), not a runtime cross-theme dependency.
25
+ **One set of inputs, a formula layer per theme:** the inputs are declared once, at `:root`. Each theme block declares its whole formula layer over them (`@include palette` + `@include semantic.roles` + its own overrides), so `:root[data-theme='dark']` fully replaces light's formulas rather than delta-patching them, and declares no input. A brand that sets `--primary` once is read by both themes; a value a brand sets on a derived role overrides that role's formula. The `@mixin roles` in `_semantic.scss` is an authoring-DRY device (the light-default structure both themes share), not a runtime cross-theme dependency.
26
26
 
27
27
  ## Theme switching
28
28
 
@@ -120,11 +120,11 @@ the parts that are easy to leave out are the ones that fail silently:
120
120
  ## Brand vs theme
121
121
 
122
122
  - **Theme** swaps the whole role map (light ↔ dark). Light is the default; dark is opt-in and, when active, fully replaces light.
123
- - **Brand** is a thin overlay scoped via attribute (`[data-brand="X"]`), authored on a theme. A brand authored on **light** pairs with the default (light) theme. A brand that wants dark adds a separate `[data-theme='dark'][data-brand="X"]` layer.
123
+ - **Brand** is a thin overlay scoped via attribute (`[data-brand="X"]`). Its inputs (`--primary`, the channels, the `-on` colours) reach both themes. A derived role it sets (`--primary-strong`, a tint) is a light value: the dark block declares its own formula for it at higher specificity, so a brand that wants its own dark value adds a separate `[data-theme='dark'][data-brand="X"]` layer.
124
124
 
125
125
  ## Adding a new theme
126
126
 
127
- 1. Create `themes/<name>/_palette.scss` (`@mixin palette` — its `--neutral-*` ramp + `--shadow-tint-l`) and `themes/<name>/_theme.scss` (`@mixin theme` — `@include palette` + `@include semantic.roles` + only the role values that differ for this theme).
127
+ 1. Create `themes/<name>/_palette.scss` (`@mixin palette` — its `--neutral-*` ramp + `--shadow-tint-l`) and `themes/<name>/_theme.scss` (`@mixin theme` — `@include palette` + `@include semantic.roles` + only the role values that differ for this theme). Never declare an input there (`@mixin inputs`): a theme block outranks a brand's `:root` or `[data-brand]` and would take the brand away in that theme.
128
128
  2. Add a selector block in `styles/_theme-activation.scss` (`:root[data-theme='<name>'] { @include <name>.theme; }`), after the light default.
129
129
 
130
130
  Components never change — they consume semantic roles, which the active theme block defines.
@@ -149,7 +149,7 @@ theme role.
149
149
 
150
150
  | Token | Paints | Light default | Dark default | Must meet |
151
151
  | ------------------------ | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------- | ------------ | ---------------------------------------------------- |
152
- | `--primary-strong` | text and icons on a tint: tag, chip, tonal button, selected row, tab, sidenav item, through `--accent-strong` | `hsl(from var(--primary) h calc(s * 0.85) calc(l - 7))` | `h 90% 72%` | 4.5:1 on every tint below and on `--surface-default` |
152
+ | `--primary-strong` | text and icons on a tint: tag, chip, tonal button, selected row, tab, sidenav item, through `--accent-strong` | `hsl(from var(--primary) h calc(s * 0.85) calc(l - 7))` | `h 90% 80%` | 4.5:1 on every tint below and on `--surface-default` |
153
153
  | `--surface-tint` | active rows and items (list, tree, empty state), through `--accent-surface-tint` | `hsl(from var(--primary) h 100% 97%)` | `h 45% 16%` | `--text-primary` and `--text-link` 4.5:1 on it |
154
154
  | `--primary-subtitle` | dropdown selected option; tonal fills (button, tabs, table, calendar day, sidenav item) through `--accent-subtitle` | `hsl(from var(--primary) h 100% 97%)` | `h 45% 18%` | the text on it 4.5:1 |
155
155
  | `--primary-muted` | dropdown selected option on hover; button, tag, avatar, sidenav item through `--accent-muted` | `hsl(from var(--primary) h 95% 94%)` | `h 40% 26%` | the text on it 4.5:1 |
@@ -161,12 +161,13 @@ Dark defaults are `hsl(from var(--primary) …)` with the hue, saturation and li
161
161
  a darker step.
162
162
  - An achromatic brand (black, gray) has no hue: the tints fall to hue 0, pink in light and dark red
163
163
  in dark. Set the tints.
164
+ - The focus ring and the field halo (`--focus-ring`, `--focus-ring-inset`, `--focus-field`) take
165
+ `--primary` itself, at their own alpha.
164
166
  - Still read from the channels `--primary-h/s/l`, which follow `--blue-h/s/l` and not `--primary`:
165
- the focus ring and the field halo (`--focus-ring`, `--focus-field`) and the
166
- `data-neutrals="brand"` grays. Set the three channels to your brand's
167
- HSL, or they stay blue.
168
- - Dark: the dark block declares `--primary` itself and wins over a light-authored brand, so restate
169
- `--primary` (and the channels) under `[data-theme='dark'][data-brand="X"]`; every shade follows.
167
+ the `data-neutrals="brand"` grays. Set the three channels to your brand's HSL, or they stay
168
+ blue.
169
+ - Dark: the inputs are declared once at `:root`, so the `--primary` and channels a brand sets reach
170
+ the dark theme too, and every dark shade follows. A derived role set in light only stays light.
170
171
 
171
172
  Green brand, measured in Chrome 2026-10-12:
172
173
 
@@ -181,14 +182,8 @@ Green brand, measured in Chrome 2026-10-12:
181
182
  // (8.33:1 on white, 8.07:1 on the tint). Links stay blue.
182
183
  }
183
184
 
184
- [data-theme='dark'][data-brand='green'] {
185
- --primary: #1f7a4d;
186
- --primary-h: 150;
187
- --primary-s: 60%;
188
- --primary-l: 30%;
189
- // Derived: --surface-tint #163b29, --primary-subtitle #19432e, --primary-muted #285d43,
190
- // --primary-muted-strong #2f7452, --primary-strong #77f8b8 (9.37:1 on the tint).
191
- }
185
+ // The same block under data-theme="dark" derives: --primary-subtitle #19432e,
186
+ // --primary-muted #285d43, --primary-muted-strong #2f7452, --primary-strong #9efacc.
192
187
  ```
193
188
 
194
189
  ## Rules summary
@@ -198,4 +193,4 @@ Green brand, measured in Chrome 2026-10-12:
198
193
  - Themes are sibling and self-contained; `_semantic.scss`'s `@mixin roles` holds the light-default values, dark overrides the deltas.
199
194
  - Brands are theme-authored overlays, and a brand authored on light pairs with the default theme.
200
195
  - Overlays take one of two fixed levels: a container (modal, drawer) is painted with `--surface-overlay`, a popover-class overlay (popover, menu, dropdown panel, picker panel, tooltip, toast) with `--surface-overlay-raised`. Each sets `--surface-secondary`, `--surface-muted`, `--surface-tint` and `--accent-surface-tint` on itself to its level's `-secondary` / `-muted` / `-tint` token (`--surface-overlay-secondary`, `--surface-overlay-raised-tint`, ...), so the hovers, fills and selected rows inside it stay a step above it. On dark the levels are `--neutral-100` and `--neutral-150`; in light every overlay token equals the role it replaces. Secondary text inside a popover-class overlay reads `--text-tertiary-overlay`: `--text-tertiary` in light, `--neutral-700` on dark.
201
- - `--primary-hover`/`--primary-pressed` are auto-derived via `color-mix()` (toward black in light, toward white in dark).
196
+ - `--primary-hover`/`--primary-pressed` are auto-derived by `state-step()`: the OKLCH lightness of `--primary` moved 0.05 / 0.12 away from `--primary-on`, toward it when the pressed step would leave 0.3-0.95.