@ids-group-ltd/ids-design-system 0.13.1 → 0.13.2

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 (52) hide show
  1. package/CHANGELOG.md +361 -0
  2. package/components.md +17 -5
  3. package/docs/agent/INDEX.md +1 -0
  4. package/docs/agent/charts/ds-line-chart.md +2 -1
  5. package/docs/agent/feedback/ds-meter.md +11 -0
  6. package/docs/agent/feedback/ds-progress.md +4 -1
  7. package/docs/agent/forms/ds-button.md +1 -1
  8. package/docs/agent/forms/ds-icon-button.md +1 -1
  9. package/docs/agent/surfaces/ds-card.md +1 -1
  10. package/fesm2022/ids-group-ltd-ids-design-system-components-bar-chart.mjs +77 -8
  11. package/fesm2022/ids-group-ltd-ids-design-system-components-bar-chart.mjs.map +1 -1
  12. package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs +3 -0
  13. package/fesm2022/ids-group-ltd-ids-design-system-components-button.mjs.map +1 -1
  14. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs +47 -5
  15. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-legend.mjs.map +1 -1
  16. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs +141 -22
  17. package/fesm2022/ids-group-ltd-ids-design-system-components-chart-tooltip.mjs.map +1 -1
  18. package/fesm2022/ids-group-ltd-ids-design-system-components-column-chart.mjs +49 -9
  19. package/fesm2022/ids-group-ltd-ids-design-system-components-column-chart.mjs.map +1 -1
  20. package/fesm2022/ids-group-ltd-ids-design-system-components-donut-chart.mjs +47 -7
  21. package/fesm2022/ids-group-ltd-ids-design-system-components-donut-chart.mjs.map +1 -1
  22. package/fesm2022/ids-group-ltd-ids-design-system-components-funnel-chart.mjs +74 -8
  23. package/fesm2022/ids-group-ltd-ids-design-system-components-funnel-chart.mjs.map +1 -1
  24. package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs +182 -18
  25. package/fesm2022/ids-group-ltd-ids-design-system-components-line-chart.mjs.map +1 -1
  26. package/fesm2022/ids-group-ltd-ids-design-system-components-meter.mjs +61 -0
  27. package/fesm2022/ids-group-ltd-ids-design-system-components-meter.mjs.map +1 -0
  28. package/fesm2022/ids-group-ltd-ids-design-system-components-progress.mjs +34 -10
  29. package/fesm2022/ids-group-ltd-ids-design-system-components-progress.mjs.map +1 -1
  30. package/fesm2022/ids-group-ltd-ids-design-system-components.mjs +71 -13
  31. package/fesm2022/ids-group-ltd-ids-design-system-components.mjs.map +1 -1
  32. package/fesm2022/ids-group-ltd-ids-design-system-core.mjs.map +1 -1
  33. package/fesm2022/ids-group-ltd-ids-design-system.mjs +1 -0
  34. package/fesm2022/ids-group-ltd-ids-design-system.mjs.map +1 -1
  35. package/migrations/0.13.2.json +269 -0
  36. package/package.json +9 -1
  37. package/styles/_chart-frame.scss +101 -4
  38. package/styles/_chart-interactive.scss +12 -3
  39. package/styles/_overlay-motion.scss +7 -6
  40. package/types/ids-group-ltd-ids-design-system-components-bar-chart.d.ts +66 -4
  41. package/types/ids-group-ltd-ids-design-system-components-button.d.ts +1 -0
  42. package/types/ids-group-ltd-ids-design-system-components-chart-legend.d.ts +25 -2
  43. package/types/ids-group-ltd-ids-design-system-components-chart-tooltip.d.ts +16 -2
  44. package/types/ids-group-ltd-ids-design-system-components-column-chart.d.ts +34 -3
  45. package/types/ids-group-ltd-ids-design-system-components-donut-chart.d.ts +29 -3
  46. package/types/ids-group-ltd-ids-design-system-components-funnel-chart.d.ts +46 -3
  47. package/types/ids-group-ltd-ids-design-system-components-line-chart.d.ts +83 -6
  48. package/types/ids-group-ltd-ids-design-system-components-meter.d.ts +36 -0
  49. package/types/ids-group-ltd-ids-design-system-components-progress.d.ts +21 -3
  50. package/types/ids-group-ltd-ids-design-system-components.d.ts +35 -9
  51. package/types/ids-group-ltd-ids-design-system-core.d.ts +19 -3
  52. package/types/ids-group-ltd-ids-design-system.d.ts +5 -4
package/CHANGELOG.md CHANGED
@@ -1,5 +1,366 @@
1
1
  ## Unreleased
2
2
 
3
+ ## 0.13.2 — 2026-09-15
4
+
5
+ ### Added
6
+
7
+ - **`ds-line-chart` takes `annotations`, so a reading can be labelled without a pointer.** The
8
+ chart had tooltips and nothing else, which leaves a peak unreadable in a screenshot, a printed
9
+ page or a slide. An annotation names a `categoryIndex`, a `label` and optionally the `seriesId`
10
+ it belongs to — left out, the first plotted series.
11
+
12
+ ```html
13
+ <ds-line-chart
14
+ [categories]="months"
15
+ [series]="series"
16
+ [annotations]="[{ categoryIndex: 5, label: 'Peak' }]" />
17
+ ```
18
+
19
+ It sits above the reading, below it where the plot has no room — a peak is at the top, which is
20
+ exactly where a label clamped upward lands on its own marker — and anchors to its own edge within
21
+ 48 view units of one rather than hanging outside the viewBox. A label whose series is hidden or
22
+ whose reading is `null` draws nothing, so a legend toggle takes its annotations with it.
23
+
24
+ It is drawn with a halo rather than a box (`paint-order: stroke`), so it survives crossing the
25
+ line and a gridline; `--ds-line-chart-annotation-color`, `-font-size`, `-weight`, `-halo-color`
26
+ and `-halo-width` set its look. The plot's own text is `aria-hidden`, so the labels are read out
27
+ of the chart's description instead — `Noted: Peak; Launch.` after the series sentences — rather
28
+ than twice from the plot and the annex table.
29
+
30
+ - **`ds-progress` takes a `target`, drawn as a hairline across the track.** A second point on the
31
+ same 0–100 scale, so a bar reads actual against a goal or a baseline in one glance instead of
32
+ standing alone. Clamped like `value`, ignored while `indeterminate`, and unset draws nothing —
33
+ every existing bar is unchanged.
34
+
35
+ ```html
36
+ <ds-progress
37
+ [value]="62"
38
+ [target]="75"
39
+ ariaLabel="Resolved 62% against a 75% target" />
40
+ ```
41
+
42
+ **Name the comparison in `ariaLabel`.** `role="progressbar"` announces one value and has no second
43
+ to carry, so the mark is visual only — a reader on a screen reader gets the target from the label
44
+ or not at all. `--ds-progress-target-color` and `--ds-progress-target-width` set its look.
45
+
46
+ - **`ds-progress` takes a `max`, so `value` can be the real count.** The bar read 0–100 only and
47
+ pinned `aria-valuemax="100"`, which made a caller convert their own numbers before us and put the
48
+ percentage into the accessible name in place of the measurement. `max` is the scale `value` and
49
+ `target` are read against; at its default of 100 they are percentages, so every existing bar is
50
+ unchanged, and `aria-valuemax` follows it.
51
+
52
+ ```html
53
+ <ds-progress [value]="37" [max]="80" [target]="64" ariaLabel="Requests handled" />
54
+ ```
55
+
56
+ That bar fills to 46.25% and reports `aria-valuenow="37"` of `aria-valuemax="80"` — "37 of 80"
57
+ rather than "46%". A `max` of zero or less falls back to 100, because a scale with no width has no
58
+ fraction to draw.
59
+
60
+ `ProgressComponent` grows by the `target` and `max` inputs; a subclass declaring either name stops
61
+ building until it renames the member or marks it `override`.
62
+
63
+ - **`ds-bar-chart` and `ds-column-chart` take `partOfWhole`, and it is what states each mark's share
64
+ of the total.** A share of a total is only a real quantity when the marks are parts of one whole.
65
+ Visitors per funnel stage, or response time per endpoint, sum to a number nobody can point at, and
66
+ a percentage of THAT is arithmetic dressed as a fact — so the charts no longer state one unless
67
+ you say the relationship holds:
68
+
69
+ ```html
70
+ <ds-bar-chart partOfWhole caption="Spend by department, share of the budget" [data]="rows" />
71
+ ```
72
+
73
+ With it set, the share appears in two places: the tooltip's second line, and a `Share of total`
74
+ column in the data table. The column is headed `Share of total` rather than `Share` because
75
+ `ds-bar-chart` already prints a percentage beside each row and that one is the share of the
76
+ LARGEST row — two different questions, each now labelled with the one it answers.
77
+
78
+ The cell is empty where there is no share to state: a lone mark, or a reading that is zero,
79
+ negative or non-finite. Negatives are left out of the total rather than subtracted from it.
80
+
81
+ - **Every chart takes `pinOnClick`, which holds a reading in place.** Clicking a mark keeps it, its
82
+ tooltip and — with `dimOthers` — the dimming of everything else, so the comparison survives the
83
+ pointer leaving the chart entirely. Hovering another mark does not move it; clicking another one
84
+ does. Clicking the pinned mark again, pressing outside it, or Escape releases it. Off by default:
85
+ a click is already the drill-down hook, and a mark left lit after the pointer has gone needs a
86
+ reader who knows why it is lit.
87
+
88
+ ```html
89
+ <ds-column-chart interactive pinOnClick dimOthers [data]="points" />
90
+ ```
91
+
92
+ A pinned mark carries a pushpin on an opaque disc — over the row's bar, the column, the middle of
93
+ the ring's arc, the middle of the funnel band — because the panel can sit anywhere on screen and
94
+ the reader needs to see WHICH mark is held. An `Unpin` button appears centred above the plot while
95
+ anything is pinned, so the way out is on screen rather than a key nobody was told about, and it is
96
+ centred because a corner competes with the donut's legend and the column chart's value labels.
97
+
98
+ The click output fires either way — pinning is a state, not a handler. On `ds-line-chart` the pin
99
+ hangs off the data markers rather than the plot, so Enter and Space pin from the keyboard too.
100
+
101
+ - **`ds-meter` — one track and one fill, for a measurement inside a table cell.** Every chart is a
102
+ block with a caption, a legend and an annex table; in a 60px cell that chrome is the whole cell,
103
+ so a micro-bar in a column had nothing to be built from. This is the mark on its own — no
104
+ caption, no legend, no tooltip, no table.
105
+
106
+ ```html
107
+ <ds-meter [value]="row.rate" [max]="highestRate" />
108
+ ```
109
+
110
+ `max` is the ceiling the column is read against, usually the column's own largest value, so the
111
+ longest bar fills its track and the rest are its share; at its default of 100, `value` is a
112
+ percentage. A value past `max` fills the track rather than overflowing, a negative one draws
113
+ nothing, and a `max` of zero or less falls back to 100.
114
+
115
+ **It is not `ds-progress`.** That reports how far a task has got and says so with
116
+ `role="progressbar"`, which a table of two hundred measurements would announce two hundred times.
117
+ A rate, a score or a count against a ceiling has no beginning and no completion. So the mark is
118
+ `aria-hidden` unless `ariaLabel` names it — leave it unset where the cell prints the figure
119
+ beside the bar, and set it where the bar is the only place the number appears.
120
+
121
+ The fill takes `--ds-meter-fill-color`, so a column is coloured once in a stylesheet rather than
122
+ once per row; the `color` input overrides it where the colour carries meaning.
123
+ `--ds-meter-height`, `--ds-meter-track-color` and `--ds-meter-radius` set the rest.
124
+
125
+ The bar is as wide as the box it sits in, so the column decides. A box sized to its content —
126
+ `width: 'content'` on `ds-table`, or a shrink-to-fit flex or grid item — is sized by what its
127
+ contents contribute intrinsically, and a bar that is 100% of its cell contributes nothing: one
128
+ alone in such a cell comes out 0px wide. The host carries a `min-inline-size` of `3rem` so it
129
+ cannot vanish, overridable through `--ds-meter-min-width`; give it a width of your own where the
130
+ bar should be a fixed size.
131
+
132
+ - **A `ds-bar-chart` row takes `segments`, which divide its bar without shortening it.** A row that
133
+ is a distribution had to become its own chart. The bar keeps its own length — the row's share of
134
+ the largest row — and the parts say what it is made of, so one plot answers both "which department
135
+ spends most" and "on what".
136
+
137
+ ```html
138
+ <ds-bar-chart [data]="[{ label: 'Engineering', value: 412000, segments: [
139
+ { label: 'Salaries', value: 291000 },
140
+ { label: 'Tooling', value: 74000 },
141
+ ] }]" />
142
+ ```
143
+
144
+ The parts are sized against their OWN sum and always fill the bar: a set that does not add up to
145
+ `value` is a data error, and a gap left where the difference is would read as an unlabelled
146
+ category. They are categories rather than one series, so they take the categorical palette in
147
+ order and the row's `color` goes unused; `color` on a segment overrides its slot. Each part gets
148
+ its own row in the annex table under the row it belongs to. Pair the chart with `ds-chart-legend`
149
+ to name them — the parts carry no text of their own.
150
+
151
+ - **A `ds-bar-chart` row takes `detail`, a second reading printed under the label.** A row often
152
+ encodes a ratio — 12,400 visitors against 456 requests — and the bar can draw only one of the two
153
+ numbers, so the other had nowhere to go. It is passed already formatted, because the row knows
154
+ what its second number means and the chart does not, and it reaches the annex table too.
155
+
156
+ ```html
157
+ <ds-bar-chart [data]="[{ label: 'Organic', value: 12400, detail: '456 requests · 3.7%' }]" />
158
+ ```
159
+
160
+ - **`ds-line-chart` takes `max` and `maxSecondary`, which pin the value axis.** A panel that opens
161
+ one subject at a time derived a different axis for each, so two plots with the same gentle wiggle
162
+ could be four times apart in value with nothing on screen saying so. A fixed maximum is what makes
163
+ two renders comparable.
164
+
165
+ ```html
166
+ <ds-line-chart [max]="5000" [categories]="months" [series]="series" />
167
+ ```
168
+
169
+ Null, the default, keeps the derived axis, so every existing chart is unchanged. A maximum below
170
+ the data does not clip it — the larger of the two wins, because hiding a reading is worse than
171
+ more headroom than you asked for. `maxSecondary` does the same for the axis a series reaches with
172
+ `axis: 'secondary'`.
173
+
174
+ - **`ds-funnel-chart` takes `drop`, which says what its Drop column reports.** `'relative'`, the
175
+ default, is the share that leaked at that stage and is what the column always showed;
176
+ `'absolute'` is the COUNT that leaked, and `'none'` takes the column out. Both figures answer a
177
+ real question and they are not the same question: on a settlement funnel the share is a talking
178
+ point and the count is a re-targeting job. The count was recoverable by subtracting two rows, and
179
+ a reader should not have to.
180
+
181
+ ```html
182
+ <ds-funnel-chart drop="absolute" [stages]="stages" />
183
+ ```
184
+
185
+ - **Every chart takes `tooltipLingerMs`, and `DS_CONFIG.chart.tooltipLingerMs` sets it app-wide.**
186
+ How long the panel stays after the pointer leaves the mark. See the tooltip entry under Changed
187
+ for what the default does and when to raise it.
188
+
189
+ - **A pinned mark offers an `Unpin` control, and says which mark it is.** `ds-bar-chart`,
190
+ `ds-column-chart`, `ds-donut-chart` and `ds-funnel-chart` render a pill button above the plot
191
+ while a mark is pinned — Escape already released one, and a control that says so is what a reader
192
+ finds without knowing the key. `ds-donut-chart` and `ds-funnel-chart` also draw a pin glyph at the
193
+ pinned slice's or band's centre, so the plot itself carries which one is held rather than leaving
194
+ it to the panel; the glyph takes no pointer events. `--ds-chart-pin-size` sizes it, and the button
195
+ is `.pin-reset`.
196
+
197
+ The internal mark-state interface behind it — not exported from the package root — gains a
198
+ `release()`, and its factory implements it. Only a hand-written implementation of that interface
199
+ has one more method to satisfy.
200
+
201
+ - **A toggleable legend in `isolate` mode offers `None`.** Beside `All` and the per-series controls,
202
+ which left no way to clear the plot in one action.
203
+
204
+ ### Changed
205
+
206
+ - **Turning a chart's frame off is an input now, not a stylesheet rule.** The frame still draws by
207
+ default. Switching it off took `ds-bar-chart { --ds-chart-frame-border-width: 0;
208
+ --ds-chart-frame-padding: 0 }` in a global sheet — a deep rule into a component's own chrome,
209
+ which is the shape of styling the rest of the library has been turning into inputs and tokens.
210
+
211
+ `frame` takes `'auto'` (the default, draws it) or `'none'`, and falls back to
212
+ `DS_CONFIG.chart.frame` when unset — whether charts live inside cards is one decision per app,
213
+ the same as `dataTable`:
214
+
215
+ ```ts
216
+ provideDsConfig({ chart: { frame: 'none' } });
217
+ ```
218
+
219
+ ```html
220
+ <ds-donut-chart frame="none" [data]="slices" />
221
+ ```
222
+
223
+ The two custom properties still size the frame and still work; a stylesheet zeroing them can drop
224
+ those declarations in favour of the config key. `ChartFrame` is exported from the package root.
225
+
226
+ - **The annex data table is off by default.** `dataTable` defaults to `'none'` rather than
227
+ `'toggle'`, on all five charts and in `DS_CONFIG.chart.dataTable`. A disclosure under every plot
228
+ is chrome the page did not ask for, and the page usually carries the numbers already.
229
+
230
+ It stays the non-visual route to the numbers where a page does NOT carry them, so turn it on
231
+ deliberately — per chart with `dataTable="toggle"`, or once for an app:
232
+
233
+ ```ts
234
+ provideDsConfig({ chart: { dataTable: 'toggle' } });
235
+ ```
236
+
237
+ - **A legend control isolates a series rather than hiding one, and `ds-chart-legend` says which.**
238
+ `mode` is `'isolate'` by default: choosing a series shows that one and hides the rest, which takes
239
+ one action instead of one per series on a crowded chart. `mode="toggle"` is the old behaviour —
240
+ hide one, leave the rest — for taking a dominant series out so the others can be read at a usable
241
+ scale. `ds-line-chart` forwards it as `legendMode`.
242
+
243
+ The two are different controls, not two looks: isolate is a single choice among many, so it
244
+ renders as a radio group running `All`, each series, `None`, and toggle renders as the checkboxes
245
+ it already did. That is what gives each the keyboard and screen-reader behaviour it should have.
246
+ One option is always chosen — `All` where the set is neither one series nor empty — because a
247
+ radio group with nothing selected cannot say whether it means "everything" or "not decided".
248
+
249
+ **If you set `legendFilters` on `ds-line-chart`, its legend changes shape.** Add
250
+ `legendMode="toggle"` to keep the checkboxes. `hiddenSeries` is unchanged in both modes, so a page
251
+ driving it from a URL parameter needs nothing.
252
+
253
+ - **A chart tooltip can be selected and dismissed with Escape, and reached with the pointer where
254
+ you ask for it.** The pane was inert and closed the instant the pointer left the mark, which left
255
+ it unreadable at high zoom, unselectable, and impossible to clear without moving the pointer away.
256
+
257
+ The pane takes the pointer now, and Escape closes the panel — it stays closed until the pointer
258
+ visits another mark, so a reader who clears the screen keeps it cleared. Reaching the panel is
259
+ `tooltipLingerMs`, which is `0`: the panel goes when the pointer does, because one left behind
260
+ sits over the plot the reader has moved on to. WCAG 1.4.13's hoverable clause only bites where the
261
+ panel holds something to reach — a link, a figure, a selectable string — so set
262
+ `[tooltipLingerMs]="140"` on those charts, or `DS_CONFIG.chart.tooltipLingerMs` for an app whose
263
+ tooltips all carry one. 140ms is what crossing the gap to a portaled panel takes at an ordinary
264
+ pointer speed.
265
+
266
+ If you styled `.ds-chart-tooltip-pane` with `pointer-events`, that rule now decides whether the
267
+ panel can be selected at all — the pane must stay `auto`.
268
+
269
+ - **A chart tooltip's second line is opt-in.** `0.13.1` gave every `ds-bar-chart` and
270
+ `ds-column-chart` tooltip a `18.6% of total` line whether or not the marks were parts of a whole.
271
+ It appears only under `partOfWhole` now. Set it on any chart whose categories genuinely divide one
272
+ total to keep the line; leave it off and the tooltip carries the label and the value, as before
273
+ `0.13.1`.
274
+
275
+ - **Exported class member surface grew — only matters if you SUBCLASS one of these.** `BarChartComponent`,
276
+ `ColumnChartComponent`, `DonutChartComponent`, `FunnelChartComponent` and `LineChartComponent` all
277
+ gain `pinOnClick` and the protected `onMarkClick`, which `LineChartComponent` spells
278
+ `onMarkerClick` beside its own `pinnedCategory` and `releaseCategoryPin`; `BarChartComponent` and
279
+ `ColumnChartComponent` also gain `partOfWhole` and the protected `valueClearance`; all five gain
280
+ `frame` and `frameResolved`; `LineChartComponent` gains `legendMode`; the
281
+ internal `ChartLegendComponent`, which the package root does not export, gains `mode`, `isolated`,
282
+ `isolate` and `showAll`; and the internal `ChartTooltipDirective`, also unexported there, gains
283
+ `dsChartTooltipExtraGap` and the private `detachEscape` and `closeOnEscape`.
284
+
285
+ All five also gain `tooltipLingerMs` and the private `tooltipLingerResolved`; `FunnelChartComponent`
286
+ gains `drop` and the protected `pinnedCenter`; `LineChartComponent` gains `max`, `maxSecondary`,
287
+ `annotations`, `placedAnnotations` and the protected `onPointerAnywhere`, `host`,
288
+ `cancelCategoryClear` and `pendingCategoryClear`; the internal legend also gains `groupName` and
289
+ `hideAll`.
290
+
291
+ Outside the charts: `ProgressComponent` gains `target`, `max` and the protected `scale`,
292
+ `clampedTarget`, `targetPercent` and `valuePercent`, and the internal message base the fields and
293
+ the button extend — unexported from the package root — gains a protected
294
+ `reserveFollowsFieldDefault`.
295
+
296
+ A subclass declaring any of those names collides. For a public or protected member the fix is
297
+ `override` or a rename; for a private one only a rename works, because TS2415 fires on the name
298
+ and `override` does not clear it.
299
+
300
+ ### Fixed
301
+
302
+ - **`ds-line-chart` draws from axis to axis.** Its readings sat at the centre of a slot each, which
303
+ left an empty strip of plot against the value axis and another against the far edge — a gap that
304
+ reads as data the chart is withholding. The first reading is on the value axis now and the last
305
+ at the far edge, with the rest dividing the run evenly. The crosshair band is centred on its
306
+ reading and clamped at both ends, so the first and last are half-width and neither hangs over an
307
+ axis label.
308
+
309
+ - **A drag across a chart no longer selects its chrome.** Axis ticks, legend labels and the caption
310
+ a screen reader needs — clipped to a thin strip for everyone else — all came out selected, and the
311
+ selection painted as bars across the card over content that is not visibly there. The plot is
312
+ `user-select: none` now; the annex table, the funnel's stage table and the visible caption stay
313
+ selectable, because those carry numbers people copy.
314
+
315
+ - **Clicking a slice or a band no longer draws a rectangle around it.** Chromium focuses an SVG
316
+ shape when it is clicked even with no `tabindex` on it, and reports that focus as NOT
317
+ `:focus-visible` — so a rule keyed on `:focus-visible` never fired and the browser painted its
318
+ own outline instead. On a ring arc or a funnel band an outline is the BOUNDING BOX, which stood
319
+ off the shape and read as a selection nobody asked for. `ds-donut-chart`, `ds-funnel-chart` and
320
+ `ds-line-chart` marks now suppress it on `:focus`. The keyboard indicator is untouched: it is a
321
+ stroke that follows the silhouette, and it still paints under `:focus-visible`.
322
+
323
+ - **`ds-column-chart`'s tooltip clears the value printed above the column.** The panel is anchored
324
+ to the column and opened 12px above it, which is exactly where `showValues` prints the figure,
325
+ so the two overlapped. It now clears the text as well as the mark; with `showValues` off the gap
326
+ is unchanged.
327
+
328
+ - **`ds-button` ignores the app-wide `DS_CONFIG.field.reserveMessage`.** The button takes the same
329
+ message line a field does, and with it took the field-wide default: an app calling
330
+ `provideDsConfig({ field: { reserveMessage: true } })` gave EVERY button an empty message row,
331
+ which turns the host from `inline-flex` into a column with a gap. One app found 125 buttons
332
+ across 45 files changed box that way, and nothing in the build, the types or the release notes
333
+ reported it. `reserveMessage` exists so a field row does not shift its neighbours as a message
334
+ appears, and a button is not in that column.
335
+
336
+ A button reserves only where you ask it to, with `[reserveMessage]="true"`. Fields are unchanged:
337
+ `DS_CONFIG.field.reserveMessage` still reaches every one of them, `ds-field-group` included.
338
+
339
+ The decision lives on the internal `DsMessageBase`, the shared message base the fields and the
340
+ button extend, as a protected `reserveFollowsFieldDefault`. The package root does not export it; a
341
+ subclass reaching it through the deep entry point and declaring that name stops building until it
342
+ renames the member or marks it `override`.
343
+
344
+ - **Two legends on one page no longer fight over the same selection.** A legend's isolate controls
345
+ are radios, and every legend named the same group — so a page with more than one chart formed a
346
+ single document-wide group: choosing a series in one legend cleared the selection in the others,
347
+ and only the last-rendered legend showed one at all. Each legend now names its own group.
348
+
349
+ A legend also always shows exactly one control chosen. A leftover partial state left the group
350
+ with nothing checked; it settles on `All`.
351
+
352
+ - **`ds-line-chart` holds its height when the last series is switched off.** The empty message
353
+ reserved the plot-height token alone, and the plot is an SVG sized by its ratio against the card
354
+ width — so on any card wider than that token the message box came up short and the card jumped.
355
+ It reserves the canvas ratio now, with the token as the floor for a very narrow card.
356
+
357
+ ### What you can now DELETE
358
+
359
+ | your workaround | why it is unnecessary | replace with |
360
+ | --- | --- | --- |
361
+ | `--ds-chart-frame-border-width: 0` with `--ds-chart-frame-padding: 0`, written to strip the frame off a chart inside a card | the frame is an input and an app-wide config key, so reaching into the component's chrome is no longer the route | `frame="none"`, or `provideDsConfig({ chart: { frame: 'none' } })` |
362
+ | `dataTable="none"` on a chart | the annex table is off by default, so the binding restates it | nothing — keep it only where the app-wide default is `'toggle'` and this one chart differs |
363
+
3
364
  ## 0.13.1 — 2026-09-14
4
365
 
5
366
  ### Added
package/components.md CHANGED
@@ -165,14 +165,14 @@ Content slots: default (label / leading or trailing icon), plus `[dsButtonSubtex
165
165
  - **Standing** (no permission, no integration — nothing here will change it): `disabledReason` beside `disabled`. The reason renders as a second line INSIDE the button, and setting it flips how the button is disabled — `aria-disabled="true"` instead of the native attribute, because a natively disabled button never takes focus and its description would never be announced (measured; Chrome's a11y tree reports name `"Approve invoice"`, description `"Needs the Finance role"`, state disabled). The click is swallowed in the handler instead, so `(pressed)` still never fires. Leave `disabledReason` unset and NOTHING changes: the native attribute stays, and so does every existing layout. Length is deliberately uncapped — the text wraps and the button grows.
166
166
  - **Temporary** (the form is not filled in yet): do NOT disable the button at all. Leave it live, judge validity in the submit handler, and carry the text UNDER the button with `hint` / `warning` / `error` — the same three inputs the fields take, resolved and rendered by the same `ds-field-message` row the fields use, with the same `messageIcon` and `reserveMessage` knobs and the same `DS_CONFIG.field.*` fallbacks. Those inputs live on an internal shared base class that `ButtonComponent` and every field extend, so the behaviour cannot drift apart. What it does NOT take is `errors` / `invalid` / `touched`: a button has no validation state of its own.
167
167
  Layout: a message-bearing button becomes a column (host class `with-message`), and because the host shrinks to fit, a message longer than the label widens the pair — button included, exactly as a field's control spans its own message. Without a message the host keeps the `inline-flex` box every existing layout was built against.
168
- Tokens: `--ds-button-bg-color`, `--ds-button-bg-color-hover`, `--ds-button-bg-color-active`, `--ds-button-bg-color-disabled`, `--ds-button-label-color`, `--ds-button-label-color-disabled`, `--ds-button-border-color`, `--ds-button-border-color-disabled`, `--ds-button-border-width`, `--ds-button-radius`, `--ds-button-focus-shadow`, `--ds-button-pressed-shadow`, `--ds-button-shadow`, `--ds-button-shadow-hover`. The last two are the REST and hover shadow, both `none` by default — before them the only way to give a button a resting shadow was a deep selector into its inner `<button>`. `-shadow-hover` falls back to `-shadow`, so setting the resting one alone keeps the button steady under the pointer; focus and pressed keep their own hooks and still win while those states are on. For `variant="solid"`, `-bg-color-hover` / `-bg-color-active` / `-pressed-shadow` default to a `color-mix()` derivation of the resolved fill (88 % / 76 % + black — the theme's hover/pressed recipe), so overriding the fill alone retints the whole state set; tonal, outline, ghost and text keep explicit ramp defaults, so a full retint there means setting the state tokens too.
168
+ Tokens: `--ds-button-bg-color`, `--ds-button-bg-color-hover`, `--ds-button-bg-color-active`, `--ds-button-bg-color-disabled`, `--ds-button-label-color`, `--ds-button-label-color-disabled`, `--ds-button-border-color`, `--ds-button-border-color-disabled`, `--ds-button-border-width`, `--ds-button-radius`, `--ds-button-pressed-shadow`, `--ds-button-shadow`, `--ds-button-shadow-hover`. The focus ring is not a button token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on the button's own scope. The last two are the REST and hover shadow, both `none` by default — before them the only way to give a button a resting shadow was a deep selector into its inner `<button>`. `-shadow-hover` falls back to `-shadow`, so setting the resting one alone keeps the button steady under the pointer; focus and pressed keep their own hooks and still win while those states are on. For `variant="solid"`, `-bg-color-hover` / `-bg-color-active` / `-pressed-shadow` default to a `color-mix()` derivation of the resolved fill (88 % / 76 % + black — the theme's hover/pressed recipe), so overriding the fill alone retints the whole state set; tonal, outline, ghost and text keep explicit ramp defaults, so a full retint there means setting the state tokens too.
169
169
 
170
170
  #### `<ds-icon-button>` — `IconButtonComponent`
171
171
  Icon-only action with its own taxonomy, distinct from `ds-button`. `ariaLabel` is required (icon-only must be labelled for a11y).
172
172
  Inputs: `icon: required IconName`, `ariaLabel: required string`, `ariaDescribedBy: string | null = null` (point at text the page already shows — e.g. why the action is refused; icon-only leaves no room for a second line, which is why there is deliberately no `disabledReason` here), `variant: IconButtonVariant = 'standard'` (`'standard' | 'filled' | 'tonal' | 'outlined'`), `size: IconButtonSize = 'md'` (`'sm' | 'md' | 'lg'` = 32/40/48), `type: 'button' | 'submit' | 'reset' = 'button'`, `disabled: boolean = false`, `selected: boolean = false` (toggle — sets `aria-pressed`)
173
173
  Output: `(pressed): MouseEvent` — fires when not disabled
174
174
  Variant emphasis: `standard` chromeless (hover-reveal) · `filled` `--primary` · `tonal` `--primary-muted` · `outlined` bordered. `selected` renders the pressed/active fill.
175
- Tokens: `--ds-icon-button-bg-color`, `--ds-icon-button-icon-color`, `--ds-icon-button-border`, `--ds-icon-button-bg-color-hover`, `--ds-icon-button-bg-color-active`, `--ds-icon-button-icon-color-hover`, `--ds-icon-button-radius`, `--ds-icon-button-focus-shadow`. `filled`/`selected` derive hover/active from the resolved bg, `standard`/`tonal`/`outlined` keep explicit ramp defaults.
175
+ Tokens: `--ds-icon-button-bg-color`, `--ds-icon-button-icon-color`, `--ds-icon-button-border`, `--ds-icon-button-bg-color-hover`, `--ds-icon-button-bg-color-active`, `--ds-icon-button-icon-color-hover`, `--ds-icon-button-radius`. The focus ring is not an icon-button token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on its own scope. `filled`/`selected` derive hover/active from the resolved bg, `standard`/`tonal`/`outlined` keep explicit ramp defaults.
176
176
 
177
177
  #### `<ds-input>` — `InputComponent`
178
178
  Inputs: `value: model<string>`, `type: InputType = 'text'` (`'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'search'`), `size: 'sm' | 'md' | 'lg' = 'md'`, `label: string = ''`, `hint: string = ''`, `placeholder: string = ''`, `disabled: boolean = false`, `invalid: boolean = false`, `required: boolean = false`, `optional: boolean = false`, `name: string | null = null`, `clearable: boolean | null = null` (inline clear (×) button; `null` resolves to `true` for `type="search"` and `false` otherwise)
@@ -286,7 +286,18 @@ Content: project `<ds-avatar>` children.
286
286
 
287
287
  #### `<ds-progress>` — `ProgressComponent`
288
288
  Linear progress bar (no circular variant).
289
- Inputs: `value: number = 0` (0–100, clamped), `variant: 'default' | 'success' | 'warn' | 'error' | 'indeterminate' = 'default'`
289
+ Inputs: `value: number = 0` (in units of `max`, clamped), `max: number = 100`, `variant: 'default' | 'success' | 'warning' | 'error' = 'default'`, `indeterminate: boolean = false`, `target: number | null = null`, `ariaLabel: string | null = null`.
290
+ `max` is the scale `value` and `target` are read against; left at 100 they are percentages. Set it to the real total — `[value]="37" [max]="80"` — and `aria-valuenow`/`aria-valuemax` carry "37 of 80" instead of a percentage the caller had to compute. Zero or less falls back to 100.
291
+ `target` is a second point on the same scale, drawn as a hairline across the track — a goal or baseline to read `value` against. Clamped like `value` and ignored while `indeterminate`. `role="progressbar"` announces one value, so name the comparison in `ariaLabel` ("Resolved 62% against a 75% target"); the mark alone reaches nobody using a screen reader.
292
+ Tokens: `--ds-progress-height`, `--ds-progress-track-color`, `--ds-progress-bar-color`, `--ds-progress-bar-color-success`, `--ds-progress-bar-color-warning`, `--ds-progress-bar-color-error`, `--ds-progress-target-color`, `--ds-progress-target-width`.
293
+
294
+ #### `<ds-meter>` — `MeterComponent`
295
+ One track and one fill, for a measurement inside a table cell — no caption, no legend, no annex table.
296
+ Inputs: `value: number = 0` (in units of `max`, clamped), `max: number = 100` (zero or less falls back to 100), `color: string | null = null`, `ariaLabel: string | null = null`.
297
+ Not `<ds-progress>`: that reports how far a task has got and says so with `role="progressbar"`, which a table of two hundred measurements would announce two hundred times. Here the mark is `aria-hidden` unless `ariaLabel` names it — leave it unset where the cell prints the figure beside the bar, set it where the bar is the only place the number appears.
298
+ `max` is usually the column's own largest value, so the longest bar fills its track and the rest are its share.
299
+ The meter fills whatever box it is in, so the column decides the bar's width. A box sized to its content — `width: 'content'` on `ds-table`, or a shrink-to-fit flex or grid item — is sized by what its contents contribute intrinsically, and a bar that is 100% of its cell contributes nothing, so the host carries a `min-inline-size` of `3rem`. Give it a width of your own where the bar should be a fixed size.
300
+ Tokens: `--ds-meter-height`, `--ds-meter-min-width`, `--ds-meter-track-color`, `--ds-meter-radius`, `--ds-meter-fill-color`.
290
301
 
291
302
  #### `<ds-spinner>` — `SpinnerComponent`
292
303
  Input: `size: 'sm' | 'md' | 'lg' = 'md'`. Pure-CSS spinner, `role="status"` with built-in `aria-label`.
@@ -399,7 +410,7 @@ Content: label text (when `variant="label"`).
399
410
  #### `<ds-card>` — `CardComponent`
400
411
  Inputs: `elevation: 'flat' | 'raised' | 'hover' | 'interactive' = 'flat'`, `padding: 'none' | 'sm' | 'md' | 'lg' | null = null` (when `null`, no `padding-*` class is applied and the consumer controls padding via own CSS or `--ds-card-pad`)
401
412
  Output: `(pressed): MouseEvent` — fires only when `elevation="interactive"`
402
- Tokens: `--ds-card-bg-color`, `--ds-card-border`, `--ds-card-radius`, `--ds-card-pad`, `--ds-card-shadow`, `--ds-card-shadow-hover`, `--ds-card-focus-shadow`, `--ds-card-hover-lift`, `--ds-card-overflow`
413
+ Tokens: `--ds-card-bg-color`, `--ds-card-border`, `--ds-card-radius`, `--ds-card-pad`, `--ds-card-shadow`, `--ds-card-shadow-hover`, `--ds-card-hover-lift`, `--ds-card-overflow`. The focus ring is not a card token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on the card's own scope
403
414
  Full-bleed child: a child whose background reaches the card edge paints square corners over the radius, and the host cannot fix it — the rounded box is the card's inner element. Set `--ds-card-overflow: clip` (`clip`, not `hidden`, so the card stays out of the scroll-container business). It is opt-in because a clipped card also cuts the focus ring off a child at its edge; where the clipped card holds focusable content, pair it with `data-focus="inset"`.
404
415
  Convention tokens (consumer-side `.title` projected into the card slot — declared at `:root`, not on the host): `--card-title-fs` (default `var(--font-size-h4)` = 22px; a brand can step it down to `var(--font-size-h5)`). Consumer markup: `<h3 class="title">…</h3>`; local `.title` class reads the token via `font:` shorthand together with `--font-weight-bold` / `--line-height-snug` / `--font-heading`.
405
416
 
@@ -519,7 +530,8 @@ Second channel: `patterns` gives every series a dash of its own, in palette-slot
519
530
  Series: `LineChartSeries = { id: string; label: string; data: readonly (number | null)[]; axis?: 'primary' | 'secondary'; area?: boolean; slot?: number }`. A `null` is a missing reading and `gaps` decides what it draws — `'break'` leaves a hole in the line, `'zero'` plants a point on the baseline. `area` fills the band between the line and its axis baseline. `slot` pins a palette slot, so hiding one series leaves every other series' colour alone.
520
531
  `yAxisMode` only matters once a series sets `axis: 'secondary'`: `'rounded'` shares one set of gridlines and rounds the secondary step up, so that series stops short of the top; `'exact'` shares the gridlines but ends the secondary axis on its largest reading, so it uses the full height and its labels are not round; `'independent'` scales and grids each axis on its own; `'stacked'` draws two plots one above the other, sharing the category axis.
521
532
  Colour: series ARE different things, so the categorical palette applies — `--ds-chart-series-1-color` onward, by position or by `slot`.
522
- Tokens: `--ds-line-chart-plot-height`, `--ds-line-chart-line-width`, `--ds-line-chart-dot-radius`, `--ds-line-chart-area-opacity`, `--ds-line-chart-swatch-size`, `--ds-line-chart-grid-line-color`, `--ds-line-chart-axis-line-color`, `--ds-line-chart-axis-label-color`, `--ds-line-chart-axis-font-size`.
533
+ `annotations: LineChartAnnotation[]` pins a label over one reading — `{ categoryIndex, label, seriesId? }`, the series defaulting to the first plotted one — so a peak reads in a screenshot with no pointer. Placed above the reading, below it where the plot has no room, and anchored to its own edge within 48 view units of one. An annotation whose series is hidden or whose reading is `null` draws nothing. Marked `aria-hidden`: the annex table already carries every reading, so announcing it again reads the number twice.
534
+ Tokens: `--ds-line-chart-plot-height`, `--ds-line-chart-line-width`, `--ds-line-chart-dot-radius`, `--ds-line-chart-area-opacity`, `--ds-line-chart-swatch-size`, `--ds-line-chart-grid-line-color`, `--ds-line-chart-axis-line-color`, `--ds-line-chart-axis-label-color`, `--ds-line-chart-axis-font-size`, `--ds-line-chart-annotation-color`, `--ds-line-chart-annotation-font-size`, `--ds-line-chart-annotation-weight`, `--ds-line-chart-annotation-halo-color`, `--ds-line-chart-annotation-halo-width`.
523
535
 
524
536
  #### Chart defaults — what `DS_CONFIG` decides once
525
537
  Four chart inputs resolve through `DS_CONFIG.chart` because they are one decision per APP, not per plot: `valueFormat` (a number reads one way in a product; a formatter passed per chart drifts as soon as there are two screens), `dataTable` (whether the numbers behind a plot have a non-visual route is an accessibility policy), `emptyText` and `errorText` (copy, and the place localisation lands). Precedence is the input, then the config, then the built-in — so binding one on a single chart still wins.
@@ -40,6 +40,7 @@ and token names.** These leaves are for orientation and usage.
40
40
  - [<ds-avatar> — AvatarComponent](feedback/ds-avatar.md) — Inputs: size: 'xs' | 'sm' | 'md' | 'lg' = 'md', initials: string = '', imageUrl: string | null = null, tint: {
41
41
  - [<ds-avatar-group> — AvatarGroupComponent](feedback/ds-avatar-group.md) — Content: project <ds-avatar> children.
42
42
  - [<ds-progress> — ProgressComponent](feedback/ds-progress.md) — Linear progress bar (no circular variant).
43
+ - [<ds-meter> — MeterComponent](feedback/ds-meter.md) — One track and one fill, for a measurement inside a table cell — no caption, no legend, no annex table.
43
44
  - [<ds-spinner> — SpinnerComponent](feedback/ds-spinner.md) — Input: size: 'sm' | 'md' | 'lg' = 'md'. Pure-CSS spinner, role="status" with built-in aria-label.
44
45
  - [<ds-skeleton> — SkeletonComponent](feedback/ds-skeleton.md) — Inputs: width?: string, height?: string, circle: boolean = false, inline: boolean = false. Shimmer animation r
45
46
  - [<ds-stat> — StatComponent](feedback/ds-stat.md) — Delta direction is derived from the sign of delta: positive → up (arrow + green), negative → down (arrow + red
@@ -12,4 +12,5 @@ Second channel: `patterns` gives every series a dash of its own, in palette-slot
12
12
  Series: `LineChartSeries = { id: string; label: string; data: readonly (number | null)[]; axis?: 'primary' | 'secondary'; area?: boolean; slot?: number }`. A `null` is a missing reading and `gaps` decides what it draws — `'break'` leaves a hole in the line, `'zero'` plants a point on the baseline. `area` fills the band between the line and its axis baseline. `slot` pins a palette slot, so hiding one series leaves every other series' colour alone.
13
13
  `yAxisMode` only matters once a series sets `axis: 'secondary'`: `'rounded'` shares one set of gridlines and rounds the secondary step up, so that series stops short of the top; `'exact'` shares the gridlines but ends the secondary axis on its largest reading, so it uses the full height and its labels are not round; `'independent'` scales and grids each axis on its own; `'stacked'` draws two plots one above the other, sharing the category axis.
14
14
  Colour: series ARE different things, so the categorical palette applies — `--ds-chart-series-1-color` onward, by position or by `slot`.
15
- Tokens: `--ds-line-chart-plot-height`, `--ds-line-chart-line-width`, `--ds-line-chart-dot-radius`, `--ds-line-chart-area-opacity`, `--ds-line-chart-swatch-size`, `--ds-line-chart-grid-line-color`, `--ds-line-chart-axis-line-color`, `--ds-line-chart-axis-label-color`, `--ds-line-chart-axis-font-size`.
15
+ `annotations: LineChartAnnotation[]` pins a label over one reading — `{ categoryIndex, label, seriesId? }`, the series defaulting to the first plotted one — so a peak reads in a screenshot with no pointer. Placed above the reading, below it where the plot has no room, and anchored to its own edge within 48 view units of one. An annotation whose series is hidden or whose reading is `null` draws nothing. Marked `aria-hidden`: the annex table already carries every reading, so announcing it again reads the number twice.
16
+ Tokens: `--ds-line-chart-plot-height`, `--ds-line-chart-line-width`, `--ds-line-chart-dot-radius`, `--ds-line-chart-area-opacity`, `--ds-line-chart-swatch-size`, `--ds-line-chart-grid-line-color`, `--ds-line-chart-axis-line-color`, `--ds-line-chart-axis-label-color`, `--ds-line-chart-axis-font-size`, `--ds-line-chart-annotation-color`, `--ds-line-chart-annotation-font-size`, `--ds-line-chart-annotation-weight`, `--ds-line-chart-annotation-halo-color`, `--ds-line-chart-annotation-halo-width`.
@@ -0,0 +1,11 @@
1
+ <!-- GENERATED by tools/split-agent-catalogue.mjs from components.md. Do not edit. -->
2
+ # `<ds-meter>` — `MeterComponent`
3
+
4
+ Group: Display & feedback
5
+
6
+ One track and one fill, for a measurement inside a table cell — no caption, no legend, no annex table.
7
+ Inputs: `value: number = 0` (in units of `max`, clamped), `max: number = 100` (zero or less falls back to 100), `color: string | null = null`, `ariaLabel: string | null = null`.
8
+ Not `<ds-progress>`: that reports how far a task has got and says so with `role="progressbar"`, which a table of two hundred measurements would announce two hundred times. Here the mark is `aria-hidden` unless `ariaLabel` names it — leave it unset where the cell prints the figure beside the bar, set it where the bar is the only place the number appears.
9
+ `max` is usually the column's own largest value, so the longest bar fills its track and the rest are its share.
10
+ The meter fills whatever box it is in, so the column decides the bar's width. A box sized to its content — `width: 'content'` on `ds-table`, or a shrink-to-fit flex or grid item — is sized by what its contents contribute intrinsically, and a bar that is 100% of its cell contributes nothing, so the host carries a `min-inline-size` of `3rem`. Give it a width of your own where the bar should be a fixed size.
11
+ Tokens: `--ds-meter-height`, `--ds-meter-min-width`, `--ds-meter-track-color`, `--ds-meter-radius`, `--ds-meter-fill-color`.
@@ -4,4 +4,7 @@
4
4
  Group: Display & feedback
5
5
 
6
6
  Linear progress bar (no circular variant).
7
- Inputs: `value: number = 0` (0–100, clamped), `variant: 'default' | 'success' | 'warn' | 'error' | 'indeterminate' = 'default'`
7
+ Inputs: `value: number = 0` (in units of `max`, clamped), `max: number = 100`, `variant: 'default' | 'success' | 'warning' | 'error' = 'default'`, `indeterminate: boolean = false`, `target: number | null = null`, `ariaLabel: string | null = null`.
8
+ `max` is the scale `value` and `target` are read against; left at 100 they are percentages. Set it to the real total — `[value]="37" [max]="80"` — and `aria-valuenow`/`aria-valuemax` carry "37 of 80" instead of a percentage the caller had to compute. Zero or less falls back to 100.
9
+ `target` is a second point on the same scale, drawn as a hairline across the track — a goal or baseline to read `value` against. Clamped like `value` and ignored while `indeterminate`. `role="progressbar"` announces one value, so name the comparison in `ariaLabel` ("Resolved 62% against a 75% target"); the mark alone reaches nobody using a screen reader.
10
+ Tokens: `--ds-progress-height`, `--ds-progress-track-color`, `--ds-progress-bar-color`, `--ds-progress-bar-color-success`, `--ds-progress-bar-color-warning`, `--ds-progress-bar-color-error`, `--ds-progress-target-color`, `--ds-progress-target-width`.
@@ -15,4 +15,4 @@ Content slots: default (label / leading or trailing icon), plus `[dsButtonSubtex
15
15
  - **Standing** (no permission, no integration — nothing here will change it): `disabledReason` beside `disabled`. The reason renders as a second line INSIDE the button, and setting it flips how the button is disabled — `aria-disabled="true"` instead of the native attribute, because a natively disabled button never takes focus and its description would never be announced (measured; Chrome's a11y tree reports name `"Approve invoice"`, description `"Needs the Finance role"`, state disabled). The click is swallowed in the handler instead, so `(pressed)` still never fires. Leave `disabledReason` unset and NOTHING changes: the native attribute stays, and so does every existing layout. Length is deliberately uncapped — the text wraps and the button grows.
16
16
  - **Temporary** (the form is not filled in yet): do NOT disable the button at all. Leave it live, judge validity in the submit handler, and carry the text UNDER the button with `hint` / `warning` / `error` — the same three inputs the fields take, resolved and rendered by the same `ds-field-message` row the fields use, with the same `messageIcon` and `reserveMessage` knobs and the same `DS_CONFIG.field.*` fallbacks. Those inputs live on an internal shared base class that `ButtonComponent` and every field extend, so the behaviour cannot drift apart. What it does NOT take is `errors` / `invalid` / `touched`: a button has no validation state of its own.
17
17
  Layout: a message-bearing button becomes a column (host class `with-message`), and because the host shrinks to fit, a message longer than the label widens the pair — button included, exactly as a field's control spans its own message. Without a message the host keeps the `inline-flex` box every existing layout was built against.
18
- Tokens: `--ds-button-bg-color`, `--ds-button-bg-color-hover`, `--ds-button-bg-color-active`, `--ds-button-bg-color-disabled`, `--ds-button-label-color`, `--ds-button-label-color-disabled`, `--ds-button-border-color`, `--ds-button-border-color-disabled`, `--ds-button-border-width`, `--ds-button-radius`, `--ds-button-focus-shadow`, `--ds-button-pressed-shadow`, `--ds-button-shadow`, `--ds-button-shadow-hover`. The last two are the REST and hover shadow, both `none` by default — before them the only way to give a button a resting shadow was a deep selector into its inner `<button>`. `-shadow-hover` falls back to `-shadow`, so setting the resting one alone keeps the button steady under the pointer; focus and pressed keep their own hooks and still win while those states are on. For `variant="solid"`, `-bg-color-hover` / `-bg-color-active` / `-pressed-shadow` default to a `color-mix()` derivation of the resolved fill (88 % / 76 % + black — the theme's hover/pressed recipe), so overriding the fill alone retints the whole state set; tonal, outline, ghost and text keep explicit ramp defaults, so a full retint there means setting the state tokens too.
18
+ Tokens: `--ds-button-bg-color`, `--ds-button-bg-color-hover`, `--ds-button-bg-color-active`, `--ds-button-bg-color-disabled`, `--ds-button-label-color`, `--ds-button-label-color-disabled`, `--ds-button-border-color`, `--ds-button-border-color-disabled`, `--ds-button-border-width`, `--ds-button-radius`, `--ds-button-pressed-shadow`, `--ds-button-shadow`, `--ds-button-shadow-hover`. The focus ring is not a button token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on the button's own scope. The last two are the REST and hover shadow, both `none` by default — before them the only way to give a button a resting shadow was a deep selector into its inner `<button>`. `-shadow-hover` falls back to `-shadow`, so setting the resting one alone keeps the button steady under the pointer; focus and pressed keep their own hooks and still win while those states are on. For `variant="solid"`, `-bg-color-hover` / `-bg-color-active` / `-pressed-shadow` default to a `color-mix()` derivation of the resolved fill (88 % / 76 % + black — the theme's hover/pressed recipe), so overriding the fill alone retints the whole state set; tonal, outline, ghost and text keep explicit ramp defaults, so a full retint there means setting the state tokens too.
@@ -7,4 +7,4 @@ Icon-only action with its own taxonomy, distinct from `ds-button`. `ariaLabel` i
7
7
  Inputs: `icon: required IconName`, `ariaLabel: required string`, `ariaDescribedBy: string | null = null` (point at text the page already shows — e.g. why the action is refused; icon-only leaves no room for a second line, which is why there is deliberately no `disabledReason` here), `variant: IconButtonVariant = 'standard'` (`'standard' | 'filled' | 'tonal' | 'outlined'`), `size: IconButtonSize = 'md'` (`'sm' | 'md' | 'lg'` = 32/40/48), `type: 'button' | 'submit' | 'reset' = 'button'`, `disabled: boolean = false`, `selected: boolean = false` (toggle — sets `aria-pressed`)
8
8
  Output: `(pressed): MouseEvent` — fires when not disabled
9
9
  Variant emphasis: `standard` chromeless (hover-reveal) · `filled` `--primary` · `tonal` `--primary-muted` · `outlined` bordered. `selected` renders the pressed/active fill.
10
- Tokens: `--ds-icon-button-bg-color`, `--ds-icon-button-icon-color`, `--ds-icon-button-border`, `--ds-icon-button-bg-color-hover`, `--ds-icon-button-bg-color-active`, `--ds-icon-button-icon-color-hover`, `--ds-icon-button-radius`, `--ds-icon-button-focus-shadow`. `filled`/`selected` derive hover/active from the resolved bg, `standard`/`tonal`/`outlined` keep explicit ramp defaults.
10
+ Tokens: `--ds-icon-button-bg-color`, `--ds-icon-button-icon-color`, `--ds-icon-button-border`, `--ds-icon-button-bg-color-hover`, `--ds-icon-button-bg-color-active`, `--ds-icon-button-icon-color-hover`, `--ds-icon-button-radius`. The focus ring is not an icon-button token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on its own scope. `filled`/`selected` derive hover/active from the resolved bg, `standard`/`tonal`/`outlined` keep explicit ramp defaults.
@@ -5,6 +5,6 @@ Group: Surfaces
5
5
 
6
6
  Inputs: `elevation: 'flat' | 'raised' | 'hover' | 'interactive' = 'flat'`, `padding: 'none' | 'sm' | 'md' | 'lg' | null = null` (when `null`, no `padding-*` class is applied and the consumer controls padding via own CSS or `--ds-card-pad`)
7
7
  Output: `(pressed): MouseEvent` — fires only when `elevation="interactive"`
8
- Tokens: `--ds-card-bg-color`, `--ds-card-border`, `--ds-card-radius`, `--ds-card-pad`, `--ds-card-shadow`, `--ds-card-shadow-hover`, `--ds-card-focus-shadow`, `--ds-card-hover-lift`, `--ds-card-overflow`
8
+ Tokens: `--ds-card-bg-color`, `--ds-card-border`, `--ds-card-radius`, `--ds-card-pad`, `--ds-card-shadow`, `--ds-card-shadow-hover`, `--ds-card-hover-lift`, `--ds-card-overflow`. The focus ring is not a card token — set `--focus-ring-color`, `--focus-ring-width` or `--focus-ring-offset` on the card's own scope
9
9
  Full-bleed child: a child whose background reaches the card edge paints square corners over the radius, and the host cannot fix it — the rounded box is the card's inner element. Set `--ds-card-overflow: clip` (`clip`, not `hidden`, so the card stays out of the scroll-container business). It is opt-in because a clipped card also cuts the focus ring off a child at its edge; where the clipped card holds focusable content, pair it with `data-focus="inset"`.
10
10
  Convention tokens (consumer-side `.title` projected into the card slot — declared at `:root`, not on the host): `--card-title-fs` (default `var(--font-size-h4)` = 22px; a brand can step it down to `var(--font-size-h5)`). Consumer markup: `<h3 class="title">…</h3>`; local `.title` class reads the token via `font:` shorthand together with `--font-weight-bold` / `--line-height-snug` / `--font-heading`.