@ethlete/components 1.0.0-next.89 → 1.0.0-next.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +29 -0
- package/design/sdk/components/accent-on-light/accent-on-light.ts +1 -0
- package/design/sdk/components/action-sheet/action-sheet.ts +25 -1
- package/design/sdk/components/anchored-dialog/anchored-dialog.css +2 -5
- package/design/sdk/components/anchored-dialog/anchored-dialog.ts +13 -8
- package/design/sdk/components/badge/badge.css +18 -0
- package/design/sdk/components/badge/badge.ts +27 -3
- package/design/sdk/components/banner/banner.ts +32 -1
- package/design/sdk/components/bracket/bracket.ts +1 -0
- package/design/sdk/components/breadcrumb/breadcrumb.ts +1 -1
- package/design/sdk/components/button/button.ts +1 -0
- package/design/sdk/components/calendar/calendar.ts +31 -4
- package/design/sdk/components/card/card.ts +41 -1
- package/design/sdk/components/carousel/carousel.ts +35 -5
- package/design/sdk/components/chart/chart.ts +8 -2
- package/design/sdk/components/checkbox/checkbox.ts +11 -2
- package/design/sdk/components/chip/chip.ts +2 -9
- package/design/sdk/components/copy-button/copy-button.ts +4 -1
- package/design/sdk/components/dialog/dialog.ts +58 -1
- package/design/sdk/components/empty-state/empty-state.ts +1 -0
- package/design/sdk/components/floating-action/floating-action.ts +1 -0
- package/design/sdk/components/form-field/form-field.ts +9 -16
- package/design/sdk/components/grid/grid.ts +4 -1
- package/design/sdk/components/match/match.ts +1 -0
- package/design/sdk/components/menu/menu.ts +1 -0
- package/design/sdk/components/notification/notification.ts +1 -0
- package/design/sdk/components/pagination/pagination.ts +1 -1
- package/design/sdk/components/progress-steps/progress-steps.ts +1 -0
- package/design/sdk/components/query-error/query-error.ts +4 -1
- package/design/sdk/components/radio-group/radio-group.ts +1 -0
- package/design/sdk/components/scheduler/scheduler.ts +22 -1
- package/design/sdk/components/scrollable/scrollable.ts +28 -2
- package/design/sdk/components/scrollbar/scrollbar.css +1 -1
- package/design/sdk/components/scrollbar/scrollbar.ts +13 -0
- package/design/sdk/components/select/select.ts +9 -0
- package/design/sdk/components/select/shared/select-part.ts +4 -12
- package/design/sdk/components/select-panel/select-panel.ts +1 -0
- package/design/sdk/components/standings/standings.ts +4 -1
- package/design/sdk/components/stream/stream.ts +12 -3
- package/design/sdk/components/switch/switch.ts +10 -4
- package/design/sdk/components/table/table.ts +94 -12
- package/design/sdk/components/tabs/tabs.ts +1 -1
- package/design/sdk/components/textarea/textarea.ts +31 -2
- package/design/sdk/components/toolbar/toolbar.ts +1 -0
- package/design/sdk/components/tree/tree.ts +8 -1
- package/design/sdk/foundations/elevation/elevation.ts +1 -0
- package/design/sdk/ready.json +334 -87
- package/design/sdk/rule-baseline.json +48 -0
- package/design/table.ts +11 -4
- package/design/tooltip.ts +7 -1
- package/fesm2022/ethlete-components.mjs +438 -73
- package/fesm2022/ethlete-components.mjs.map +1 -1
- package/package.json +1 -1
- package/src/lib/bracket/bracket.component.css +4 -1
- package/src/lib/forms/choice-field/choice-field.component.css +4 -2
- package/src/lib/forms/dropzone/dropzone-crop.component.css +21 -0
- package/src/lib/forms/select/select-option-styles.component.css +1 -0
- package/src/lib/match/match-card.component.css +8 -2
- package/src/lib/match/match-participant.component.css +21 -1
- package/src/lib/stream/consent/stream-consent.component.css +1 -0
- package/src/lib/stream/error/stream-player-error.component.css +1 -0
- package/src/lib/stream/stream-overlay-card-styles.component.css +9 -3
- package/src/lib/table/table.component.css +1 -0
- package/types/ethlete-components.d.ts +111 -11
- package/design/sdk/components/switch/switch.css +0 -37
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,34 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.0.0-next.90
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- Add the `--et-bracket-journey-endpoint-outline` token to `et-bracket`, so the dashed outline around the match a highlighted journey ends in can be restyled, or hidden with `none`.
|
|
8
|
+
- Add `--et-choice-field-label-font-weight`, `--et-choice-field-label-letter-spacing` and `--et-select-option-letter-spacing`, mirroring the form-field label tokens. Defaults are unchanged.
|
|
9
|
+
- Dropzone: free and round crop frames, a minimum image size that rejects small images as `imageTooSmall`, and the drop area hides while a crop is pending.
|
|
10
|
+
- A single `et-select` with an option whose value is `null` now shows that option's label in the trigger for a `null` value instead of the placeholder. Without such an option, a `null` value still shows the placeholder.
|
|
11
|
+
- `et-standings` takes optional `extraColumns` filled from each row's `extraStats`, form entries with a `label` shown as a tooltip, and a `participantLink` that renders each participant as an `href` or `routerLink`.
|
|
12
|
+
- `et-switch` takes its name from a native `<label>` that wraps it or points at its `id`, and keeps an `aria-label` or `aria-labelledby` bound on its host.
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- The table design mock takes `selectAllAttributes` and a row's `selectAttributes`, extra attributes on its selection checkboxes.
|
|
17
|
+
- `et-choice-field`: the control slot is a flex container, so a checkbox or switch no longer sits in a text line box that
|
|
18
|
+
made the row taller than the control (in both the inline and the subgrid layout).
|
|
19
|
+
- `et-match-card`: the participant country line keeps its flag beside the name and stays start-aligned on both rows, even
|
|
20
|
+
inside a centered container.
|
|
21
|
+
- `et-match-participant`: new tokens for the emblem frame - `--et-match-participant-emblem-radius`,
|
|
22
|
+
`--et-match-participant-emblem-border-width`, `--et-match-participant-emblem-border-color`, and for the empty frame of a
|
|
23
|
+
participant still to be decided `--et-match-participant-tbd-emblem-border-width` and
|
|
24
|
+
`--et-match-participant-tbd-emblem-border-style` (e.g. `dashed`). The defaults keep today's look.
|
|
25
|
+
- `et-select` and `et-cascader` handle panel keys such as Escape as soon as the panel reopens, also while the previous panel is still animating out. Before, keys pressed in that window were lost.
|
|
26
|
+
- `et-select` closes on Escape again when the panel was reopened while the previous panel was still animating out (for example ArrowDown right after picking an option in an inline search). Before, the Escape was swallowed and the list stayed expanded.
|
|
27
|
+
- `et-select` no longer keeps a static `aria-label` or `aria-labelledby` on its host element, so only the combobox (trigger or search input) carries the accessible name.
|
|
28
|
+
- The stream consent gate and error overlay now fit a player under 200px tall: tighter spacing, and the icon reliably hides.
|
|
29
|
+
- The table's empty and error message no longer widens a table without a global `box-sizing: border-box` reset past its viewport, so it no longer scrolls sideways.
|
|
30
|
+
- Add `anchor` to the `tooltip()` design mock; the design frame now places anchored mock panes and arrows on whole pixels like the overlay runtime.
|
|
31
|
+
|
|
3
32
|
## 1.0.0-next.89
|
|
4
33
|
|
|
5
34
|
### Minor Changes
|
|
@@ -4,6 +4,7 @@ import styles from './accent-on-light.css?inline';
|
|
|
4
4
|
|
|
5
5
|
export default definePart({
|
|
6
6
|
note: 'The brand mint on light controls: checkbox checked, mixed and off, switch on, a radio group, a segmented button group and a choice-field card, drawn by the real components under one accent rule.',
|
|
7
|
+
consumerAction: 'a showcase of form controls whose values the consumer binds',
|
|
7
8
|
madeBy: ['claude-opus-5-5'],
|
|
8
9
|
states: { default: {} },
|
|
9
10
|
describe: {
|
|
@@ -64,13 +64,17 @@ const sheet = ({ header: withHeader = true, action, cancel }: Props) =>
|
|
|
64
64
|
|
|
65
65
|
export default definePart({
|
|
66
66
|
note: 'Full-width sheet flush to the bottom edge, Cancel as the last row',
|
|
67
|
-
|
|
67
|
+
consumerAction: 'its actions are the items the consumer passes in',
|
|
68
|
+
madeBy: ['claude-opus-5-5', 'design check'],
|
|
68
69
|
states: {
|
|
69
70
|
default: {},
|
|
70
71
|
'without-header': { header: false },
|
|
72
|
+
cancel: {},
|
|
71
73
|
'action-hover': { action: 'hover' },
|
|
72
74
|
'action-active': { action: 'active' },
|
|
73
75
|
'action-focus-visible': { action: 'focus-visible' },
|
|
76
|
+
'cancel-hover': { cancel: 'hover' },
|
|
77
|
+
'cancel-active': { cancel: 'active' },
|
|
74
78
|
'cancel-focus-visible': { cancel: 'focus-visible' },
|
|
75
79
|
},
|
|
76
80
|
describe: {
|
|
@@ -78,13 +82,33 @@ export default definePart({
|
|
|
78
82
|
'The sheet over a dimmed page with title, message, four actions and Cancel; check that it sits flush at the bottom and Delete match is red.',
|
|
79
83
|
'without-header':
|
|
80
84
|
'The sheet with only its actions and Cancel; check that the list starts at the top edge without a gap.',
|
|
85
|
+
cancel: 'The sheet at rest as the Cancel row of the grid; check that Cancel reads as the last row.',
|
|
81
86
|
'action-hover': 'Edit match hovered; check that the row takes the hover tint across the full width.',
|
|
82
87
|
'action-active': 'Edit match pressed; check that the tint goes a step past hover.',
|
|
83
88
|
'action-focus-visible':
|
|
84
89
|
'Edit match with keyboard focus; check that the focus ring shows inside the sheet and is not cut.',
|
|
90
|
+
'cancel-hover': 'Cancel hovered; check that the last row takes the hover tint across the full width.',
|
|
91
|
+
'cancel-active': 'Cancel pressed; check that the tint goes a step past hover.',
|
|
85
92
|
'cancel-focus-visible':
|
|
86
93
|
'Cancel with keyboard focus; check that the focus ring shows around the last row and is not cut at the bottom.',
|
|
87
94
|
},
|
|
95
|
+
grid: {
|
|
96
|
+
columns: ['rest', 'hover', 'active', 'focus-visible'] as const,
|
|
97
|
+
rows: {
|
|
98
|
+
action: {
|
|
99
|
+
rest: 'default',
|
|
100
|
+
hover: 'action-hover',
|
|
101
|
+
active: 'action-active',
|
|
102
|
+
'focus-visible': 'action-focus-visible',
|
|
103
|
+
},
|
|
104
|
+
cancel: {
|
|
105
|
+
rest: 'cancel',
|
|
106
|
+
hover: 'cancel-hover',
|
|
107
|
+
active: 'cancel-active',
|
|
108
|
+
'focus-visible': 'cancel-focus-visible',
|
|
109
|
+
},
|
|
110
|
+
},
|
|
111
|
+
},
|
|
88
112
|
widths: [390],
|
|
89
113
|
instant:
|
|
90
114
|
'Rows take their hover and press tint at once; the sheet enters and leaves with the overlay strategy motion.',
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { anchoredDialog, anchoredDialogStyles } from '@ethlete/components/design/anchored-dialog';
|
|
2
|
+
import { checkboxGroup, checkboxGroupStyles } from '@ethlete/components/design/checkbox';
|
|
3
|
+
import { control } from '@ethlete/components/design/control';
|
|
2
4
|
import { definePart, drawing } from '@design-system';
|
|
3
5
|
import button from '@system/components/button';
|
|
4
6
|
import edge from './anchored-dialog.css?inline';
|
|
@@ -25,16 +27,19 @@ const FILTERS = [
|
|
|
25
27
|
{ label: 'Has comments', checked: true },
|
|
26
28
|
];
|
|
27
29
|
|
|
30
|
+
const options = () =>
|
|
31
|
+
checkboxGroup({ id: 'filter', options: FILTERS }).replace(/<et-checkbox-option(?=[\s>])/gu, (tag) =>
|
|
32
|
+
control(`${tag}>`, 'option').slice(0, -1),
|
|
33
|
+
);
|
|
34
|
+
|
|
28
35
|
const filter = (apply: string) => `<header class="anchored-dialog-header"><span>Filter</span></header>
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
`<li><label><input type="checkbox" data-et-control="option"${checked ? ' checked' : ''} />${label}</label></li>`,
|
|
32
|
-
).join('')}</ul>
|
|
33
|
-
<footer class="anchored-dialog-footer">${apply}</footer>`;
|
|
36
|
+
<div class="anchored-dialog-group">${options()}</div>
|
|
37
|
+
<footer class="anchored-dialog-footer">${control(apply, 'apply')}</footer>`;
|
|
34
38
|
|
|
35
39
|
export default definePart({
|
|
36
40
|
note: 'An open popover anchored to its trigger: surface pane, arrow, free content',
|
|
37
|
-
|
|
41
|
+
consumerAction: 'the field inside is content the consumer projects',
|
|
42
|
+
madeBy: ['claude-sonnet-5-5', 'claude-opus-5-5', 'design check'],
|
|
38
43
|
states: {
|
|
39
44
|
'open-points': { kind: 'open-points', modal: false },
|
|
40
45
|
filter: { kind: 'filter', placement: 'bottom-start' },
|
|
@@ -52,7 +57,7 @@ export default definePart({
|
|
|
52
57
|
},
|
|
53
58
|
widths: [480],
|
|
54
59
|
controls: {
|
|
55
|
-
option: { kind: '
|
|
60
|
+
option: { kind: 'button', part: 'components/checkbox' },
|
|
56
61
|
apply: { kind: 'button', part: 'components/button' },
|
|
57
62
|
},
|
|
58
63
|
frame: (body, { placement = 'bottom-end' }) =>
|
|
@@ -78,7 +83,7 @@ export default definePart({
|
|
|
78
83
|
modal,
|
|
79
84
|
content: pane,
|
|
80
85
|
}),
|
|
81
|
-
styles: [anchoredDialogStyles, apply.styles, edge].join('\n'),
|
|
86
|
+
styles: [anchoredDialogStyles, apply.styles, checkboxGroupStyles, edge].join('\n'),
|
|
82
87
|
});
|
|
83
88
|
},
|
|
84
89
|
});
|
|
@@ -11,3 +11,21 @@
|
|
|
11
11
|
--_et-badge-border-color: var(--et-theme-color-ink-solid);
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
|
+
|
|
15
|
+
.badge-frame-narrow {
|
|
16
|
+
inline-size: 16rem;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@layer components {
|
|
20
|
+
.et-badge[data-long-label] {
|
|
21
|
+
--et-badge-max-width: 12rem;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.et-badge[data-long-label] .et-badge-label {
|
|
25
|
+
min-inline-size: 0;
|
|
26
|
+
overflow: hidden;
|
|
27
|
+
text-overflow: ellipsis;
|
|
28
|
+
white-space: nowrap;
|
|
29
|
+
text-box: normal;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -7,7 +7,7 @@ const icon = (name: string) => SDK_ICONS.find((each) => each.name === name);
|
|
|
7
7
|
|
|
8
8
|
type Variant = NonNullable<BadgeMockOptions['variant']>;
|
|
9
9
|
|
|
10
|
-
type Props = { badges: BadgeMockOptions[] };
|
|
10
|
+
type Props = { badges: BadgeMockOptions[]; narrow?: boolean };
|
|
11
11
|
|
|
12
12
|
const themed = (variant: Variant, size?: BadgeMockOptions['size']): Props => ({
|
|
13
13
|
badges: [
|
|
@@ -29,9 +29,21 @@ const sizes = (variant: Variant): Props => ({
|
|
|
29
29
|
badges: (['sm', 'md', 'lg'] as const).map((size) => ({ label: size, variant, size })),
|
|
30
30
|
});
|
|
31
31
|
|
|
32
|
+
const longLabel = (variant: Variant): Props => ({
|
|
33
|
+
narrow: true,
|
|
34
|
+
badges: [
|
|
35
|
+
{
|
|
36
|
+
label: 'Awaiting confirmation from the tournament organiser',
|
|
37
|
+
variant,
|
|
38
|
+
color: 'warning',
|
|
39
|
+
attributes: 'data-long-label',
|
|
40
|
+
},
|
|
41
|
+
],
|
|
42
|
+
});
|
|
43
|
+
|
|
32
44
|
export default definePart({
|
|
33
45
|
note: 'Decided rules only',
|
|
34
|
-
madeBy: ['claude-opus-5-5'],
|
|
46
|
+
madeBy: ['claude-opus-5-5', 'claude-sonnet-5-5'],
|
|
35
47
|
states: {
|
|
36
48
|
filled: themed('filled'),
|
|
37
49
|
tonal: themed('tonal'),
|
|
@@ -42,6 +54,9 @@ export default definePart({
|
|
|
42
54
|
'filled-sizes': sizes('filled'),
|
|
43
55
|
'tonal-sizes': sizes('tonal'),
|
|
44
56
|
'outline-sizes': sizes('outline'),
|
|
57
|
+
'filled-long-label': longLabel('filled'),
|
|
58
|
+
'tonal-long-label': longLabel('tonal'),
|
|
59
|
+
'outline-long-label': longLabel('outline'),
|
|
45
60
|
},
|
|
46
61
|
describe: {
|
|
47
62
|
filled: 'Filled badges in the default, brand, warning and danger themes; check that each label reads on its fill.',
|
|
@@ -54,12 +69,21 @@ export default definePart({
|
|
|
54
69
|
'filled-sizes': 'Filled badges at sm, md and lg; check that height, padding and text scale per step.',
|
|
55
70
|
'tonal-sizes': 'Tonal badges at sm, md and lg; check that height, padding and text scale per step.',
|
|
56
71
|
'outline-sizes': 'Outlined badges at sm, md and lg; check that height, padding and text scale per step.',
|
|
72
|
+
'filled-long-label':
|
|
73
|
+
'A filled warning badge with a label longer than its 12rem cap; check that the label stays on one line and ends in an ellipsis.',
|
|
74
|
+
'tonal-long-label':
|
|
75
|
+
'A tonal warning badge with a label longer than its cap; check that the label stays on one line and ends in an ellipsis.',
|
|
76
|
+
'outline-long-label':
|
|
77
|
+
'An outlined warning badge with a label longer than its cap; check the one-line label with its ellipsis inside the border.',
|
|
57
78
|
},
|
|
58
79
|
widths: [480],
|
|
80
|
+
controls: {},
|
|
59
81
|
frame: (body) => `<div class="badge-frame">${body}</div>`,
|
|
60
82
|
render: (props: Props) =>
|
|
61
83
|
drawing({
|
|
62
|
-
body:
|
|
84
|
+
body: props.narrow
|
|
85
|
+
? `<div class="badge-frame-narrow">${badgeRow(props.badges.map((each) => badge(each)))}</div>`
|
|
86
|
+
: badgeRow(props.badges.map((each) => badge(each))),
|
|
63
87
|
styles: [badgeStyles, frame].join('\n'),
|
|
64
88
|
}),
|
|
65
89
|
});
|
|
@@ -59,16 +59,20 @@ const render = ({ type, ...rest }: Props) =>
|
|
|
59
59
|
|
|
60
60
|
export default definePart({
|
|
61
61
|
note: 'Decided rules only',
|
|
62
|
-
|
|
62
|
+
consumerAction: 'its buttons are actions the consumer projects',
|
|
63
|
+
madeBy: ['claude-opus-5-5', 'design check'],
|
|
63
64
|
states: {
|
|
64
65
|
info: { type: 'info' },
|
|
65
66
|
success: { type: 'success' },
|
|
66
67
|
warning: { type: 'warning' },
|
|
67
68
|
error: { type: 'error' },
|
|
68
69
|
'without-dismiss': { type: 'info', dismissible: false },
|
|
70
|
+
action: { type: 'info' },
|
|
69
71
|
'close-hover': { type: 'info', close: 'hover' },
|
|
72
|
+
'close-active': { type: 'info', close: 'active' },
|
|
70
73
|
'close-focus-visible': { type: 'info', close: 'focus-visible' },
|
|
71
74
|
'action-hover': { type: 'info', action: 'hover' },
|
|
75
|
+
'action-active': { type: 'info', action: 'active' },
|
|
72
76
|
'action-focus-visible': { type: 'info', action: 'focus-visible' },
|
|
73
77
|
'error-close-focus-visible': { type: 'error', close: 'focus-visible' },
|
|
74
78
|
'error-action-focus-visible': { type: 'error', action: 'focus-visible' },
|
|
@@ -80,9 +84,12 @@ export default definePart({
|
|
|
80
84
|
warning: 'The warning banner with Upgrade; check that the warning tint and the text keep their contrast.',
|
|
81
85
|
error: 'The error banner with Retry in the danger colour; check the icon and that Retry reads on the tint.',
|
|
82
86
|
'without-dismiss': 'The info banner without its close button; check that the text and action take the freed space.',
|
|
87
|
+
action: 'The info banner at rest as the action row of the grid; check View fixtures at rest.',
|
|
83
88
|
'close-hover': 'The info close button hovered; check the round hover tint behind the icon.',
|
|
89
|
+
'close-active': 'The info close button pressed; check that the round tint goes a step past hover.',
|
|
84
90
|
'close-focus-visible': 'The info close button with keyboard focus; check that the focus ring shows around it.',
|
|
85
91
|
'action-hover': 'View fixtures hovered; check that the action shows its hover look.',
|
|
92
|
+
'action-active': 'View fixtures pressed; check that the action goes a step past its hover look.',
|
|
86
93
|
'action-focus-visible': 'View fixtures with keyboard focus; check that the focus ring shows around it.',
|
|
87
94
|
'error-close-focus-visible':
|
|
88
95
|
'The error close button with keyboard focus; check that the ring stays visible on the danger tint.',
|
|
@@ -90,6 +97,30 @@ export default definePart({
|
|
|
90
97
|
'Retry with keyboard focus on the error banner; check that the ring stays visible on the danger tint.',
|
|
91
98
|
all: 'The four banner types stacked; check that info, success, warning and error each read as their own colour.',
|
|
92
99
|
},
|
|
100
|
+
motions: {
|
|
101
|
+
'close-hover-in': { from: 'info', to: 'close-hover' },
|
|
102
|
+
'close-hover-out': { from: 'close-hover', to: 'info' },
|
|
103
|
+
'close-press': { from: 'close-hover', to: 'close-active' },
|
|
104
|
+
'close-release': { from: 'close-active', to: 'close-hover' },
|
|
105
|
+
'action-hover-in': { from: 'action', to: 'action-hover' },
|
|
106
|
+
'action-hover-out': { from: 'action-hover', to: 'action' },
|
|
107
|
+
'action-press': { from: 'action-hover', to: 'action-active' },
|
|
108
|
+
'action-release': { from: 'action-active', to: 'action-hover' },
|
|
109
|
+
'action-tap': { from: 'action', to: 'action-active' },
|
|
110
|
+
'action-lift': { from: 'action-active', to: 'action' },
|
|
111
|
+
},
|
|
112
|
+
grid: {
|
|
113
|
+
columns: ['rest', 'hover', 'active', 'focus-visible'] as const,
|
|
114
|
+
rows: {
|
|
115
|
+
close: { rest: 'info', hover: 'close-hover', active: 'close-active', 'focus-visible': 'close-focus-visible' },
|
|
116
|
+
action: {
|
|
117
|
+
rest: 'action',
|
|
118
|
+
hover: 'action-hover',
|
|
119
|
+
active: 'action-active',
|
|
120
|
+
'focus-visible': 'action-focus-visible',
|
|
121
|
+
},
|
|
122
|
+
},
|
|
123
|
+
},
|
|
93
124
|
widths: [480],
|
|
94
125
|
controls: {
|
|
95
126
|
close: { kind: 'button', input: ['pointer', 'keyboard'] },
|
|
@@ -105,6 +105,7 @@ const render = (props: Props) => {
|
|
|
105
105
|
|
|
106
106
|
export default definePart({
|
|
107
107
|
note: "The SDK bracket (et-bracket) in flow, first drawing, drawn by the mock from @ethlete/components/design/bracket with the real markup and CSS: the bracket, its default round header, default match cell (et-match-card at compact), default final card (trophy, round name, champion line), continue cell and participants legend sheets, plus the match card, icon and button sheets; cell positions and connector paths come from @ethlete/bracket (createBracket, the single elimination grid, drawMan) as in the lib; default settings and labels, en-US kick-off. Emblems are the participant's letter fallback; the move transitions at rest. Fixtures are fictional: an eight-club single elimination knockout (Northbridge Rovers NBR 1, Harbor City HBC 2, Eastvale United EVU 3, Millbrook Athletic MBA 4, Riverside Wanderers RSW 5, Stonegate FC SGF 6, Westport Albion WPA 7, Lakeside Town LST 8) over Quarter-finals, Semi-finals and Final; the brand theme only. Framed as a page with 16px padding at 1040 and 1680 (the default bracket is 980px wide, the grid does not follow the frame width). States: in-progress (quarter-finals and one semi-final finished, the other semi-final live 1 : 1 with the LIVE badge, the final with Northbridge Rovers against TBD and the kick-off, champion not decided), decided (Westport Albion beat Northbridge Rovers 2 : 1, the champion line), journey-hover (the hover journey of Riverside Wanderers: the rest at half opacity, the semi-final where they went out dashed and their row struck through), journey-pinned (the pinned journey of the champion with the participants legend, its toggle pressed; the rest at a quarter opacity), legend-focus-visible (the Eastvale United toggle forced), compact (density compact, in-progress), continue (quarter-finals and semi-finals with the continue cell, 2 winners advance, dashed connectors) and mirrored (decided, folded in half, compact, so it fits 1040). Numbers (light / dark), from shot pixels at scale 2 at 1040, brand mint, a: winner bar (primary) vs card 1.33 / 13.50; live dot (primary) vs its badge tint 1.24 / 9.67, vs card 1.33 / 13.28; badge tint vs card 1.07 / 1.37; final frame edge (45 % mint) vs page 1.22 / 3.90, vs the glow beside it 1.15 / 2.98, vs its own tint 1.18 / 3.50; the final tint (6 %) vs page 1.03 / 1.11; pressed legend toggle (mint fill) vs page 1.33 / 13.50, its label 15.82 / 15.82; legend toggle focus ring (primary) vs page 1.37 / 13.06; outline toggle edge and label (ink) 7.68 light. Q98 numbers only: connectors, card edges, the continue cell's dashed edge and the journey endpoint's dashed outline vs page 1.26 / 1.73. The journey dimming lowers text under 4.5:1 by design: at half opacity the check reports a dimmed winner code at 3.41 / 2.68 and the dimmed Final label at 2.14 / 3.93, at a quarter opacity 1.73 / 2.21, the struck-through row that went out (0.55 opacity) 2.62 / 2.98; exempted with contrast exceptions, an open point, no decided rule. Decided rules that arise: Q88 (the legend toggle focus ring; the default cells are not links, so no card ring) and Q99a (the winner bar, the live dot and the final frame edge take ink in light; the pressed legend toggle is a mint fill, so it takes a 1px inset ink edge). The ink edge on a mint fill arises, so Q102 arises: b draws the edge in both schemes, c keeps dark as today (light-dark(ink, transparent)). The badge tint and the final tint are band tints, not fills, so they are kept, and the final glow is kept. Q101 does not arise: the only filled button is a pressed toggle, whose hover keeps the fill in the lib. Findings for later: (1) lib bug: the live meta row grows the bracket's compact card past matchHeight: the live semi-final is 87px tall in its 75px cell (65 in 52 at compact), so it hangs 12px (13px) below its cell, the incoming connector meets it 6px above its centre and the gap to the card below shrinks. Drawn as is in every variant. (2) In the mirrored compact layout the final card in its 200px column shows full names and cuts the loser ('Northbridge Rove…') next to the score, where every other compact cell shows codes. (3) The eliminated row's line-through also strikes the emblem letter and the score. (4) The lit journey path keeps the grey connector colour (1.26 / 1.73), so it reads only by the rest fading; the dimmed text is under 4.5:1 (numbers above). (5) In dark the final glow lightens the page beside the frame edge, so the edge drops from 3.90 against the bare page to 2.98 against the glow. Later rounds, left out here: double elimination, swiss and round robin layouts, the third-place match, the mirrored layout at default density, the rounds list and adaptive layout, the skeleton, the prediction pick card, a custom match component on a link (card hover and focus ring), emblems as images, scheduled cells with kick-off times, long names, RTL and the move transitions. Omitted option value (Q182): alignRoundHeaders center draws the same pixels as start, because the default round header fills its column and is already centred.",
|
|
108
|
+
consumerAction: 'a press on a team runs the handler the consumer binds',
|
|
108
109
|
madeBy: ['claude-opus-5-5'],
|
|
109
110
|
states: {
|
|
110
111
|
'in-progress': { stage: 'in-progress' },
|
|
@@ -49,7 +49,7 @@ const longMarkup = (props: Props) => {
|
|
|
49
49
|
return `<div class="breadcrumb-overflow-stage">${panel}${breadcrumb({
|
|
50
50
|
crumbs: trail,
|
|
51
51
|
collapsed: hiddenCrumbs,
|
|
52
|
-
overflowAttributes: mark('overflow', props.overflow)
|
|
52
|
+
overflowAttributes: `${mark('overflow', props.overflow)} data-et-action="${props.open ? 'long' : 'overflow-open'}"`,
|
|
53
53
|
})}</div>`;
|
|
54
54
|
};
|
|
55
55
|
|
|
@@ -82,6 +82,7 @@ export const grid = {
|
|
|
82
82
|
|
|
83
83
|
export default definePart({
|
|
84
84
|
note: 'scale of the decided shape, Q182, lead merge',
|
|
85
|
+
consumerAction: 'a button whose click the consumer binds',
|
|
85
86
|
madeBy: ['claude-opus-5-5', 'claude-sonnet-5-5', 'design check'],
|
|
86
87
|
states,
|
|
87
88
|
grid,
|
|
@@ -4,8 +4,10 @@ import frame from './calendar.css?inline';
|
|
|
4
4
|
|
|
5
5
|
type Interaction = 'hover' | 'focus-visible';
|
|
6
6
|
|
|
7
|
+
type View = NonNullable<CalendarMockOptions['view']>;
|
|
8
|
+
|
|
7
9
|
type Props = {
|
|
8
|
-
view?:
|
|
10
|
+
view?: View;
|
|
9
11
|
selected?: boolean;
|
|
10
12
|
range?: boolean;
|
|
11
13
|
day?: Interaction;
|
|
@@ -25,11 +27,33 @@ const TODAY = '2026-09-14';
|
|
|
25
27
|
const force = (interaction: Interaction | undefined, key: string) =>
|
|
26
28
|
interaction ? { [key]: `data-et-force="${interaction}"` } : {};
|
|
27
29
|
|
|
30
|
+
const ZOOM_OUT: Record<View, string> = { month: 'year-view', year: 'multi-year-view', multiYear: 'selected' };
|
|
31
|
+
|
|
32
|
+
const action = (key: string) => `data-et-action="${key}"`;
|
|
33
|
+
|
|
34
|
+
const cellAction = (view: View, range: boolean) =>
|
|
35
|
+
view === 'year'
|
|
36
|
+
? 'emit:monthSelect'
|
|
37
|
+
: view === 'multiYear'
|
|
38
|
+
? 'emit:yearSelect'
|
|
39
|
+
: range
|
|
40
|
+
? 'emit:rangeValueChange'
|
|
41
|
+
: 'emit:valueChange';
|
|
42
|
+
|
|
43
|
+
const declareCells = (html: string, key: string) =>
|
|
44
|
+
html.replace(/<button [^>]*class="et-calendar-cell[^>]*>/g, (cell) =>
|
|
45
|
+
cell.includes('aria-disabled') ? cell : cell.replace('<button ', `<button ${action(key)} `),
|
|
46
|
+
);
|
|
47
|
+
|
|
48
|
+
const withAction = (key: string | undefined, extra?: string) =>
|
|
49
|
+
[key && action(key), extra].filter(Boolean).join(' ') || undefined;
|
|
50
|
+
|
|
28
51
|
const render = (props: Props) => {
|
|
29
52
|
const view = props.view ?? 'month';
|
|
30
53
|
const coarseKey = view === 'year' ? '2026-03' : '2021';
|
|
54
|
+
const navigate = props.limits ? undefined : 'emit:activeMonthChange';
|
|
31
55
|
|
|
32
|
-
|
|
56
|
+
const html = calendar({
|
|
33
57
|
view,
|
|
34
58
|
month: '2026-09',
|
|
35
59
|
today: TODAY,
|
|
@@ -55,10 +79,13 @@ const render = (props: Props) => {
|
|
|
55
79
|
...force(props.selectedDay, '2026-09-17'),
|
|
56
80
|
...force(props.rangeDay, '2026-09-09'),
|
|
57
81
|
},
|
|
58
|
-
|
|
59
|
-
|
|
82
|
+
previousAttributes: withAction(navigate),
|
|
83
|
+
nextAttributes: withAction(navigate, props.nav ? `data-et-force="${props.nav}"` : undefined),
|
|
84
|
+
labelAttributes: withAction(ZOOM_OUT[view], props.label ? `data-et-force="${props.label}"` : undefined),
|
|
60
85
|
attributes: props.compact ? 'style="--et-calendar-cell-size: 32px"' : undefined,
|
|
61
86
|
});
|
|
87
|
+
|
|
88
|
+
return declareCells(html, cellAction(view, Boolean(props.range || props.comparison)));
|
|
62
89
|
};
|
|
63
90
|
|
|
64
91
|
export default definePart({
|
|
@@ -38,14 +38,20 @@ const content = (props: Props) => {
|
|
|
38
38
|
|
|
39
39
|
export default definePart({
|
|
40
40
|
note: 'Decided rules only',
|
|
41
|
-
|
|
41
|
+
consumerAction: 'its buttons are actions the consumer projects',
|
|
42
|
+
madeBy: ['claude-opus-5-5', 'design check'],
|
|
42
43
|
states: {
|
|
43
44
|
outlined: { variant: 'outlined' },
|
|
44
45
|
elevated: { variant: 'elevated' },
|
|
45
46
|
filled: { variant: 'filled' },
|
|
46
47
|
media: { variant: 'outlined', form: 'media' },
|
|
47
48
|
plain: { variant: 'outlined', form: 'plain' },
|
|
49
|
+
confirm: { variant: 'outlined' },
|
|
50
|
+
'confirm-hover': { variant: 'outlined', confirm: 'hover' },
|
|
51
|
+
'confirm-active': { variant: 'outlined', confirm: 'active' },
|
|
48
52
|
'confirm-focus-visible': { variant: 'outlined', confirm: 'focus-visible' },
|
|
53
|
+
'cancel-hover': { variant: 'outlined', cancel: 'hover' },
|
|
54
|
+
'cancel-active': { variant: 'outlined', cancel: 'active' },
|
|
49
55
|
'cancel-focus-visible': { variant: 'outlined', cancel: 'focus-visible' },
|
|
50
56
|
},
|
|
51
57
|
describe: {
|
|
@@ -54,9 +60,43 @@ export default definePart({
|
|
|
54
60
|
filled: 'The filled card; check that its fill differs from the page without a border.',
|
|
55
61
|
media: 'The outlined card with a media image on top; check that the image fills the top edge inside the radius.',
|
|
56
62
|
plain: 'A plain outlined card with Revenue and an amount only; check the padding without actions.',
|
|
63
|
+
confirm: 'The outlined card at rest as the Open row of the grid; check Open at rest.',
|
|
64
|
+
'confirm-hover': 'Open hovered; check that the filled button takes its hover fill inside the card.',
|
|
65
|
+
'confirm-active': 'Open pressed; check that the fill goes a step past hover.',
|
|
57
66
|
'confirm-focus-visible': 'Open with keyboard focus; check the focus ring around the button inside the card.',
|
|
67
|
+
'cancel-hover': 'Cancel hovered; check that the outline button takes its hover tint inside the card.',
|
|
68
|
+
'cancel-active': 'Cancel pressed; check that the tint goes a step past hover.',
|
|
58
69
|
'cancel-focus-visible': 'Cancel with keyboard focus; check the focus ring around the outline button.',
|
|
59
70
|
},
|
|
71
|
+
motions: {
|
|
72
|
+
'cancel-hover-in': { from: 'outlined', to: 'cancel-hover' },
|
|
73
|
+
'cancel-hover-out': { from: 'cancel-hover', to: 'outlined' },
|
|
74
|
+
'cancel-press': { from: 'cancel-hover', to: 'cancel-active' },
|
|
75
|
+
'cancel-release': { from: 'cancel-active', to: 'cancel-hover' },
|
|
76
|
+
'confirm-hover-in': { from: 'confirm', to: 'confirm-hover' },
|
|
77
|
+
'confirm-hover-out': { from: 'confirm-hover', to: 'confirm' },
|
|
78
|
+
'confirm-press': { from: 'confirm-hover', to: 'confirm-active' },
|
|
79
|
+
'confirm-release': { from: 'confirm-active', to: 'confirm-hover' },
|
|
80
|
+
'confirm-tap': { from: 'confirm', to: 'confirm-active' },
|
|
81
|
+
'confirm-lift': { from: 'confirm-active', to: 'confirm' },
|
|
82
|
+
},
|
|
83
|
+
grid: {
|
|
84
|
+
columns: ['rest', 'hover', 'active', 'focus-visible'] as const,
|
|
85
|
+
rows: {
|
|
86
|
+
cancel: {
|
|
87
|
+
rest: 'outlined',
|
|
88
|
+
hover: 'cancel-hover',
|
|
89
|
+
active: 'cancel-active',
|
|
90
|
+
'focus-visible': 'cancel-focus-visible',
|
|
91
|
+
},
|
|
92
|
+
confirm: {
|
|
93
|
+
rest: 'confirm',
|
|
94
|
+
hover: 'confirm-hover',
|
|
95
|
+
active: 'confirm-active',
|
|
96
|
+
'focus-visible': 'confirm-focus-visible',
|
|
97
|
+
},
|
|
98
|
+
},
|
|
99
|
+
},
|
|
60
100
|
widths: [480],
|
|
61
101
|
controls: {
|
|
62
102
|
cancel: { kind: 'button', input: ['pointer', 'keyboard'] },
|
|
@@ -17,7 +17,9 @@ const TITLES = ['Kick-off', 'First half', 'Half time', 'Second half', 'Full time
|
|
|
17
17
|
const LONG_CAPTION =
|
|
18
18
|
'A long caption that wraps over several lines inside the slide, the way a match report teaser runs on past a single line of text.';
|
|
19
19
|
|
|
20
|
-
const
|
|
20
|
+
const INDEX_CHANGE = 'data-et-action="emit:activeIndexChange"';
|
|
21
|
+
|
|
22
|
+
const force = (interaction: Interaction | undefined) => (interaction ? `data-et-force="${interaction}"` : '');
|
|
21
23
|
|
|
22
24
|
const slideContent = (index: number, count: number, longCaption: boolean) =>
|
|
23
25
|
`<div class="carousel-slide"><p class="carousel-slide-title">${index + 1}. ${TITLES[index % TITLES.length]}</p>` +
|
|
@@ -28,10 +30,15 @@ const render = ({ count = 5, longCaption = false, previous, next, playToggle, do
|
|
|
28
30
|
carousel({
|
|
29
31
|
...options,
|
|
30
32
|
slides: Array.from({ length: count }, (_, index) => ({ content: slideContent(index, count, longCaption) })),
|
|
31
|
-
previousAttributes: force(previous)
|
|
32
|
-
nextAttributes: force(next)
|
|
33
|
-
playToggleAttributes: force(playToggle)
|
|
34
|
-
dotAttributes:
|
|
33
|
+
previousAttributes: `${INDEX_CHANGE} ${force(previous)}`,
|
|
34
|
+
nextAttributes: `${INDEX_CHANGE} ${force(next)}`,
|
|
35
|
+
playToggleAttributes: `data-et-action="${options.playing === false ? 'autoplay-playing' : 'autoplay-paused'}" ${force(playToggle)}`,
|
|
36
|
+
dotAttributes: Object.fromEntries(
|
|
37
|
+
Array.from({ length: count }, (_, index) => [
|
|
38
|
+
index,
|
|
39
|
+
`${INDEX_CHANGE} ${dot?.index === index ? force(dot.interaction) : ''}`,
|
|
40
|
+
]),
|
|
41
|
+
),
|
|
35
42
|
trackAttributes: 'data-et-skip="CLIPPED"',
|
|
36
43
|
}).replaceAll(
|
|
37
44
|
'class="et-carousel-dot-progress-half"',
|
|
@@ -92,6 +99,29 @@ export default definePart({
|
|
|
92
99
|
},
|
|
93
100
|
widths: [480],
|
|
94
101
|
frame: (body) => `<div class="carousel-frame">${body}</div>`,
|
|
102
|
+
scrolls: [
|
|
103
|
+
'first-slide',
|
|
104
|
+
'middle-slide',
|
|
105
|
+
'last-slide',
|
|
106
|
+
'no-loop-first',
|
|
107
|
+
'no-loop-last',
|
|
108
|
+
'next-hover',
|
|
109
|
+
'next-active',
|
|
110
|
+
'next-focus-visible',
|
|
111
|
+
'dot-hover',
|
|
112
|
+
'active-dot-hover',
|
|
113
|
+
'dot-focus-visible',
|
|
114
|
+
'active-dot-focus-visible',
|
|
115
|
+
'autoplay-playing',
|
|
116
|
+
'autoplay-paused',
|
|
117
|
+
'play-toggle-hover',
|
|
118
|
+
'play-toggle-focus-visible',
|
|
119
|
+
'multiple-items',
|
|
120
|
+
'item-size-third',
|
|
121
|
+
'center-aligned',
|
|
122
|
+
'no-controls',
|
|
123
|
+
'long-caption',
|
|
124
|
+
],
|
|
95
125
|
render: (props: Props) =>
|
|
96
126
|
drawing({
|
|
97
127
|
body: render(props),
|
|
@@ -36,7 +36,13 @@ const LONG_SOURCES = [
|
|
|
36
36
|
|
|
37
37
|
const PLOT_WIDTH = 410;
|
|
38
38
|
|
|
39
|
-
const
|
|
39
|
+
const declareMarks = (html: string) =>
|
|
40
|
+
html.replace(
|
|
41
|
+
/<g class="et-(bar-chart-bar|line-chart-slice|pie-chart-slice)\b/g,
|
|
42
|
+
(mark) => `${mark.slice(0, 2)} data-et-action="emit:markActivate"${mark.slice(2)}`,
|
|
43
|
+
);
|
|
44
|
+
|
|
45
|
+
const marks = (props: Props) => {
|
|
40
46
|
if (props.kind === 'bar') {
|
|
41
47
|
return barChart({
|
|
42
48
|
plotWidth: PLOT_WIDTH,
|
|
@@ -116,7 +122,7 @@ export default definePart({
|
|
|
116
122
|
frame: (body) => `<div class="t-frame">${body}</div>`,
|
|
117
123
|
render: (props: Props) =>
|
|
118
124
|
drawing({
|
|
119
|
-
body:
|
|
125
|
+
body: declareMarks(marks(props)),
|
|
120
126
|
styles: [chartStyles, frame].join('\n'),
|
|
121
127
|
}),
|
|
122
128
|
});
|
|
@@ -57,11 +57,12 @@ const EVENTS = ['Kick-off', 'Goals', 'Half-time', 'Full-time'];
|
|
|
57
57
|
|
|
58
58
|
const eventsGroup = (
|
|
59
59
|
checked: number,
|
|
60
|
-
extra: { force?: CheckboxMockForce[]; selectAllForce?: CheckboxMockForce[] } = {},
|
|
60
|
+
extra: { force?: CheckboxMockForce[]; selectAllForce?: CheckboxMockForce[]; disabled?: boolean } = {},
|
|
61
61
|
): CheckboxGroupMockOptions => ({
|
|
62
62
|
id: 'events',
|
|
63
63
|
label: 'Notify me about',
|
|
64
64
|
selectAll: 'All events',
|
|
65
|
+
disabled: extra.disabled,
|
|
65
66
|
selectAllForce: extra.selectAllForce,
|
|
66
67
|
options: EVENTS.map((label, index): CheckboxGroupMockOption => ({
|
|
67
68
|
label,
|
|
@@ -97,7 +98,8 @@ const render = (props: Props) =>
|
|
|
97
98
|
|
|
98
99
|
export default definePart({
|
|
99
100
|
note: "The SDK checkbox (et-checkbox) in flow, first drawing, drawn by the mock from @ethlete/components/design/checkbox with the real markup and CSS: et-checkbox alone and inside et-choice-field (label, et-description, hint, error, required marker), the card variant (et-selection-card), and et-checkbox-group with et-checkbox-group-select-all and et-checkbox-option, plus the color-interactive and focus-ring sheets; the brand theme, danger as the error theme. Fixtures are fictional: a match-report preferences form (Send me the match report, One email per match, no ads., hint We send it after the final whistle.; I accept the terms of use, required, error Accept the terms to continue.; card Weekly digest, A summary of every match day, each Monday.; group Notify me about with All events over Kick-off, Goals, Half-time, Full-time; horizontal group Show matches: Home, Away, Neutral ground). Framed as a page with 16px padding at 360 and 640. States: a grid of unchecked, checked and indeterminate by rest, hover, focus-visible, active, disabled and readonly (all labelled); box-only (checked, no label); support (description and hint); invalid and invalid-focus-visible; card-rest, card-checked, card-hover, card-focus-visible, card-checked-focus-visible; group-unchecked, group-partial (2 of 4, select-all mixed), group-checked, group-option-hover, group-option-pressed (force hover and active), group-option-focus-visible, group-select-all-focus-visible and group-horizontal. Numbers (light / dark), from shot pixels at scale 2 at 360, brand mint, a: unchecked box border (surface border) vs page 1.26 / 1.73, the same for the option and select-all boxes and the card edge; hover border 10.37 / 13.07; checked and indeterminate fill (primary) vs page 1.33 / 13.50, check and dash on it 15.82; checked hover fill (-hover) 1.37 / 13.06, 1.03 from rest; active fill 2.24 / 8.01; focus-visible fill (-focus) 1.37 / 13.06; focus ring on a checked or indeterminate box (primary -focus) 1.37 / 13.06, on an unchecked box (surface text colour) 17.93 / 17.18; card checked edge and card ring (primary) 1.33 / 13.50; option and select-all ring 1.37 / 13.06; invalid box border (danger) 4.83 / 3.71, its focus ring (danger -focus) 6.47 / 2.77; disabled checked fill 2.20 / 1.70, disabled unchecked border 1.12 / 1.27 (exempt under 1.4.11). Decided rules that arise: Q88 (the checked and indeterminate ring, the invalid ring, the card ring, the option and select-all rings in ink; the unchecked ring is the surface text colour, not a primary ring, so it stays), Q99a (the card checked and focus edge and the focused option, select-all and card box borders take light-dark(ink, primary); the checked and indeterminate box, the checked option box and the checked or mixed select-all box are mint fills, so they take a 1px inset ink edge, an outline at -1px as in the table round; on the option and select-all the focus ring owns the outline, so the edge leaves while it shows) and Q101 (a filled checked or indeterminate box hovers to -active). The ink edge on a mint fill arises, so Q102 arises: b draws the edges in both schemes, c keeps dark as today (light-dark(ink, transparent)). The error border is the danger theme, not mint, and passes 3:1, so it is kept. Findings for later: (1) lib bug: .et-checkbox-box, .et-checkbox-option-box and .et-checkbox-group-select-all-box were content-box, so --et-checkbox-size 20px drew a 24px box (48 sheet px at scale 2) in an app without a global border-box reset, and the hint and error started 4px left of the label column. Fixed in the lib (box-sizing: border-box on the three boxes): every box draws 20px (40 sheet px), and the label, description and hint share one column (44 CSS px from the frame edge). (2) WCAG 1.4.11: the unchecked box border is 1.26 / 1.73 vs page, under 3:1; it is the only edge of an unchecked box (the same question as the switch off track, switch r1, open). Not drawn. (3) The required marker takes the error theme primary: 3.71:1 in dark, under 4.5:1; exempted here. (4) Focus-visible lightens the checked fill to -focus (1.37 vs page, light), so a focused checked box reads paler than at rest; the ink ring carries the state in b and c. (5) Readonly draws exactly like rest (no affordance by design); a checked readonly box cannot be told from an editable one. (6) Mock: et-description now has its own stylesheet (description.component.css, f5722a1f5), so the mock's inline copy can import it instead. Later rounds, left out here: the sizes sm and lg, the card with the control at start, a coloured (non-brand) checkbox, the group's bulk-edit mixed state (dashed option boxes, a primary mark that Q99a would reach), a disabled or readonly group, a group with error and the group card variant, long labels that wrap, RTL and the check and uncheck animation.",
|
|
100
|
-
|
|
101
|
+
consumerAction: 'a form control whose value the consumer binds',
|
|
102
|
+
madeBy: ['claude-opus-5-5', 'design check'],
|
|
101
103
|
states: {
|
|
102
104
|
...gridStates,
|
|
103
105
|
'box-only': { checkbox: { id: 'box-only', checked: true } },
|
|
@@ -139,7 +141,10 @@ export default definePart({
|
|
|
139
141
|
'group-option-hover': { group: eventsGroup(0, { force: ['hover'] }) },
|
|
140
142
|
'group-option-pressed': { group: eventsGroup(0, { force: ['hover', 'active'] }) },
|
|
141
143
|
'group-option-focus-visible': { group: eventsGroup(2, { force: ['focus-visible'] }) },
|
|
144
|
+
'group-select-all-hover': { group: eventsGroup(2, { selectAllForce: ['hover'] }) },
|
|
145
|
+
'group-select-all-pressed': { group: eventsGroup(2, { selectAllForce: ['hover', 'active'] }) },
|
|
142
146
|
'group-select-all-focus-visible': { group: eventsGroup(2, { selectAllForce: ['focus-visible'] }) },
|
|
147
|
+
'group-disabled': { group: eventsGroup(2, { disabled: true }) },
|
|
143
148
|
'group-horizontal': { group: venueGroup },
|
|
144
149
|
},
|
|
145
150
|
describe: {
|
|
@@ -179,8 +184,12 @@ export default definePart({
|
|
|
179
184
|
'group-option-hover': 'The Goals option hovered; check its hover tint.',
|
|
180
185
|
'group-option-pressed': 'The Goals option pressed; check that the press goes past hover.',
|
|
181
186
|
'group-option-focus-visible': 'The Goals option with keyboard focus; check the focus ring around its box.',
|
|
187
|
+
'group-select-all-hover': 'All events hovered over a partial group; check the hover tint around the mixed box.',
|
|
188
|
+
'group-select-all-pressed': 'All events pressed over a partial group; check that the press goes past hover.',
|
|
182
189
|
'group-select-all-focus-visible':
|
|
183
190
|
'All events with keyboard focus over a partial group; check the ring around the mixed box.',
|
|
191
|
+
'group-disabled':
|
|
192
|
+
'The partial group disabled; check that All events and every option fade together and show no pointer state.',
|
|
184
193
|
'group-horizontal': 'The Show matches group in one row; check the gaps between Home, Away and Neutral ground.',
|
|
185
194
|
},
|
|
186
195
|
grid: {
|