@ids-group-ltd/ids-design-system 0.10.3 → 0.11.1
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 +1376 -904
- package/components.md +61 -30
- package/design-system.md +18 -18
- package/fesm2022/ids-group-ltd-ids-design-system.mjs +992 -486
- package/fesm2022/ids-group-ltd-ids-design-system.mjs.map +1 -1
- package/migrations/0.1.0.json +2 -1
- package/migrations/0.10.0.json +219 -42
- package/migrations/0.10.1.json +50 -13
- package/migrations/0.10.2.json +90 -24
- package/migrations/0.10.3.json +22 -5
- package/migrations/0.11.0.json +216 -0
- package/migrations/0.11.1.json +305 -0
- package/migrations/0.2.0.json +22 -9
- package/migrations/0.2.1.json +2 -1
- package/migrations/0.2.2.json +3 -2
- package/migrations/0.3.0.json +16 -10
- package/migrations/0.4.0.json +38 -14
- package/migrations/0.5.0.json +49 -25
- package/migrations/0.5.1/badge-statuses.md +1 -3
- package/migrations/0.5.1.json +75 -33
- package/migrations/0.6.0.json +6 -2
- package/migrations/0.6.1.json +19 -1
- package/migrations/0.6.2.json +3 -1
- package/migrations/0.6.3.json +13 -4
- package/migrations/0.7.0.json +45 -26
- package/migrations/0.7.1.json +58 -20
- package/migrations/0.8.0.json +53 -15
- package/migrations/0.9.0.json +147 -27
- package/migrations/0.9.1.json +4 -3
- package/migrations/README.md +34 -52
- package/package.json +2 -1
- package/styles/_dropdown-overlay.scss +35 -13
- package/styles/_ds-color.scss +3 -3
- package/styles/_field-box.scss +2 -6
- package/styles/_field-label.scss +5 -10
- package/styles/_field-state.scss +3 -2
- package/styles/_focus.scss +0 -2
- package/styles/_layout-utils.scss +2 -2
- package/styles/_link.scss +1 -2
- package/styles/_overlay-motion.scss +2 -4
- package/styles/_press.scss +3 -5
- package/styles/_reset.scss +0 -1
- package/styles/_scrollbar.scss +1 -3
- package/styles/_status.scss +1 -2
- package/styles/_surface-motion.scss +3 -4
- package/styles/_text-clip.scss +1 -1
- package/styles/_theme-activation.scss +1 -1
- package/styles/_tokens-charts.scss +1 -3
- package/styles/_tokens.scss +4 -3
- package/styles/_typography.scss +2 -2
- package/themes/README.md +3 -3
- package/themes/_base-palette.scss +2 -2
- package/themes/_semantic.scss +2 -2
- package/themes/dark/_palette.scss +1 -2
- package/themes/light/_palette.scss +1 -1
- package/themes/light/_theme.scss +1 -1
- package/types/ids-group-ltd-ids-design-system.d.ts +403 -108
- package/migrations/AUTHORING.md +0 -273
package/migrations/0.9.1.json
CHANGED
|
@@ -2,9 +2,10 @@
|
|
|
2
2
|
"version": "0.9.1",
|
|
3
3
|
"items": [],
|
|
4
4
|
"informational": [
|
|
5
|
-
"Nothing in this release changes the package's runtime.
|
|
5
|
+
"Nothing in this release changes the package's runtime. The entire change is documentation, feeding the token and component reference; every component behaves exactly as it did on 0.9.0.",
|
|
6
6
|
"THREE documented behaviours were guessable wrong, so check these if you use them - the code always worked this way, only the reference was silent. (1) ds-time-columns `value` is always HH:mm in 24h and `format` changes only the DISPLAY, so a picker showing 12h still emits 24h - code that parsed the emitted value as 12h was wrong. (2) ds-time-columns `minTime`/`maxTime` DISABLE the out-of-range rows rather than removing them, so the columns keep their height as a bound moves - a layout that assumed the list shortens was wrong. (3) ds-calendar-day `tabIndex` is a roving tabindex owned by the grid (exactly one cell at 0, the rest at -1), not a tab position to set per day - setting it per cell fights the grid's keyboard model.",
|
|
7
7
|
"41 public tokens and props gained descriptions in the reference: 10 --ds-* tokens (the whole --ds-password-rules-* set, --ds-multi-select-panel-bg-color and --ds-menu-item-radius among them) and 31 inputs and outputs across ds-calendar-day, ds-time-columns, ds-field-message, ds-divider, ds-sidenav-footer and the three layout primitives. Names, types and defaults are unchanged.",
|
|
8
|
-
"
|
|
9
|
-
]
|
|
8
|
+
"A release manifest carries a deleteList wherever that release made a workaround unnecessary, so an upgrade tool can act on what became redundant and not only on what broke. Each row is machine-readable: { id, surface, find, why, replaceWith }."
|
|
9
|
+
],
|
|
10
|
+
"deleteList": []
|
|
10
11
|
}
|
package/migrations/README.md
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
# Machine-readable migration manifests
|
|
2
2
|
|
|
3
3
|
One file per released version — `migrations/<version>.json` — mirroring that version's
|
|
4
|
-
`CHANGELOG.md` block as a structured **MigrationPlan
|
|
5
|
-
`/design-system:auto-update-package` plugin's planner produces from prose):
|
|
4
|
+
`CHANGELOG.md` block as a structured **MigrationPlan**:
|
|
6
5
|
|
|
7
6
|
```json
|
|
8
7
|
{ "version": "X.Y.Z",
|
|
@@ -41,77 +40,60 @@ One file per released version — `migrations/<version>.json` — mirroring that
|
|
|
41
40
|
- **`supersedes`** — `<version>#<id>`, declared on the item that REVERSES an earlier one. It points
|
|
42
41
|
BACKWARD only. An upgrade walks one version at a time and each manifest is frozen when the next is
|
|
43
42
|
written, so a file cannot name its own future: there is no `supersededBy`, and a note that says
|
|
44
|
-
"in the next release" is a defect
|
|
43
|
+
"in the next release" is a defect. The reversal is described in full by the later
|
|
45
44
|
item, which is the one an upgrade reaches second.
|
|
45
|
+
- **`action`** — the imperative: what to change, in the order to change it. The one field an
|
|
46
|
+
upgrade executes.
|
|
47
|
+
- **`appliesWhen`** — the boundary: which components, which bindings, and what is explicitly NOT
|
|
48
|
+
affected, so an item can be ruled out without searching.
|
|
49
|
+
- **`pitfall`** — the way to apply the item mechanically correctly and still ship a broken app.
|
|
50
|
+
Read it before deciding a clean build means done.
|
|
46
51
|
- **`deleteList`** — the structured form of "what you can now delete" (see below).
|
|
47
52
|
|
|
48
|
-
**Why:** the
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
them missing. A patch release is not exempt: 0.6.2 turned out to carry an actionable change (a sheet
|
|
53
|
+
**Why:** an upgrade tool can read the plan out of the prose changelog, but it re-derives it on
|
|
54
|
+
every run. A shipped manifest makes it deterministic: the tool validates and prefers the
|
|
55
|
+
manifest, falling back to prose only when a version has no manifest. **Every published version
|
|
56
|
+
has one**, so the fallback should never fire. A patch
|
|
57
|
+
release is not exempt: 0.6.2 carries an actionable change (a sheet
|
|
54
58
|
with nothing focusable in it stopped closing on Escape), which is exactly the kind a "just fixes"
|
|
55
59
|
release is assumed not to have.
|
|
56
60
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
`migrations/unreleased/README.md` restated the manifest in a form nothing reads: the auto-update
|
|
61
|
-
plugin loads `<version>.json`, and the only content the manifest did not already carry was the
|
|
62
|
-
delete-list. Worse, it went stale inside one release — three late changes never reached it — and a
|
|
63
|
-
stale duplicate misleads where no file would merely be silent. Its content now lives in the two
|
|
64
|
-
places that ARE read: the `deleteList` array in `<version>.json`, and a "What you can now DELETE"
|
|
65
|
-
table in that version's CHANGELOG block.
|
|
66
|
-
|
|
67
|
-
**A sibling folder `migrations/<version>/*.md` is still legal for the rare case a `note` genuinely
|
|
68
|
-
cannot hold** — a worked before/after with code on both sides, like `migrations/0.5.1/badge-statuses.md`.
|
|
69
|
-
The folder never matches the `*.json` glob, so tooling ignores it, and `tools/changelog-release.mjs`
|
|
70
|
-
promotes `migrations/unreleased/` alongside the manifest if one exists. The test before writing one:
|
|
71
|
-
**would a tool or an agent ever open it?** If the answer is "a human might", it belongs in the
|
|
72
|
-
CHANGELOG instead.
|
|
61
|
+
A version may also ship a sibling folder `migrations/<version>/*.md` holding a worked
|
|
62
|
+
before/after too long for a `note` — `migrations/0.5.1/badge-statuses.md` is the one that exists.
|
|
63
|
+
It never matches the `*.json` glob, so tooling ignores it.
|
|
73
64
|
|
|
74
65
|
**What the manifest must carry that a release note usually omits: what the consumer can now DELETE.**
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
hooks that ALREADY existed, because a release note says what broke and never says what became
|
|
78
|
-
unnecessary.
|
|
66
|
+
Most workarounds in an app are written against hooks that
|
|
67
|
+
ALREADY existed, because a release note says what broke and never says what became unnecessary.
|
|
79
68
|
|
|
80
|
-
**Those entries are the `deleteList` ARRAY, not prose.**
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
of the 45 waited for a human to read all 63 informational lines and recognise their own code in a
|
|
84
|
-
sentence. Twelve local classes and a duplicated `visually-hidden` recipe survived the upgrade that
|
|
85
|
-
way. Write each as `{ id, surface, find, why, replaceWith }` — `find` being the shape in the
|
|
69
|
+
**Those entries are the `deleteList` ARRAY, not prose.** A delete hint written as a sentence inside
|
|
70
|
+
`informational` has no `find` for a finder to run, so it waits for a human to recognise their own
|
|
71
|
+
code in it. Write each as `{ id, surface, find, why, replaceWith }` — `find` being the shape in the
|
|
86
72
|
CONSUMER's code, a string or an array of them — and keep the human copy in that version's CHANGELOG
|
|
87
73
|
"What you can now DELETE" table. Two copies, each read by someone; the third copy in `informational`
|
|
88
74
|
is the one that goes stale, so new manifests do not carry it.
|
|
89
75
|
|
|
90
76
|
**What made an item findable is now part of the schema, because a well-formed item can still be
|
|
91
|
-
undetectable.**
|
|
92
|
-
|
|
93
|
-
just impossible to locate from what they carried:
|
|
77
|
+
undetectable.** Two shapes slip past a find/apply/recheck loop — not malformed, not ambiguous, just
|
|
78
|
+
impossible to locate from what they carry:
|
|
94
79
|
|
|
95
80
|
- `0.7.1#table-sortkey-non-null-when-unsorted` named `ds-table[sortKey]` as `old`, and every
|
|
96
81
|
`searchHint` named the DS. What breaks is the host's own store code —
|
|
97
82
|
`sorting: store.sortKey() ? { path: sortKey()!, order: sortDir() ?? 'Asc' } : undefined` — which
|
|
98
|
-
mentions no DS symbol at all.
|
|
99
|
-
|
|
83
|
+
mentions no DS symbol at all. A DS-named search returns zero hits, the item is
|
|
84
|
+
recorded not-applicable, and a clean re-check grep agrees — while the table keeps ordering by a
|
|
85
|
+
column whose header shows no sort.
|
|
100
86
|
- `0.7.1#field-reserve-message-default-off` put "consumers that wrote `[reserveMessage]="false"` can
|
|
101
|
-
delete those bindings"
|
|
102
|
-
survived.
|
|
87
|
+
delete those bindings" deep inside a long note, with no delete entry, so the bindings survive.
|
|
103
88
|
|
|
104
89
|
Hence `surface`, `detect`, `verify` and `restore`: say WHERE the consumer's code changes, what that
|
|
105
90
|
code LOOKS like when it names nothing of ours, what proves the change landed, and how to get the old
|
|
106
|
-
behaviour back.
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
items across 19 releases, 32 prose delete lines into arrays), so there is no legacy tier and no
|
|
110
|
-
warning level: a gap is an error wherever it appears.
|
|
91
|
+
behaviour back. **Every published manifest meets this contract**, back to the earliest release, so there is no
|
|
92
|
+
legacy tier and no warning level: `surface`, `detect`, `verify` and `restore` are present wherever
|
|
93
|
+
they apply.
|
|
111
94
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
for humans — the manifest is its machine mirror; if they disagree, fix the manifest.
|
|
95
|
+
The prose CHANGELOG is the human copy of a release; the manifest is its machine mirror of the
|
|
96
|
+
same release. Where the two disagree, the CHANGELOG is the one to trust.
|
|
115
97
|
|
|
116
|
-
**Shipping:**
|
|
117
|
-
|
|
98
|
+
**Shipping:** the manifests are in
|
|
99
|
+
`node_modules/@ids-group-ltd/ids-design-system/migrations/`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ids-group-ltd/ids-design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"description": "IDS Group Angular design system: components, tokens, themes",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://ids-ds.proto.ids-group.co.uk/",
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
"exports": {
|
|
18
18
|
"./styles/*": "./styles/*",
|
|
19
19
|
"./themes/*": "./themes/*",
|
|
20
|
+
"./migrations/*": "./migrations/*",
|
|
20
21
|
"./package.json": {
|
|
21
22
|
"default": "./package.json"
|
|
22
23
|
},
|
|
@@ -22,22 +22,35 @@
|
|
|
22
22
|
picker's corner is not a thing a design system should encourage, but moving
|
|
23
23
|
every panel — modal, popover, date picker — to reach the dropdowns is too
|
|
24
24
|
blunt. This is the middle lever, and `--ds-radius-panel` stays its default so
|
|
25
|
-
an untouched theme is unchanged.
|
|
26
|
-
`--ds-select-panel-radius`, which never existed; this is what they meant. */
|
|
25
|
+
an untouched theme is unchanged. */
|
|
27
26
|
--_dropdown-panel-radius: var(--ds-dropdown-panel-radius, var(--ds-radius-panel));
|
|
28
27
|
|
|
28
|
+
/* Only bite in `content` width mode, where the pane is auto-sized: in `fill` the
|
|
29
|
+
component pins the pane to the trigger and there is nothing left to bound. */
|
|
30
|
+
--_dropdown-panel-bg-color: var(--ds-dropdown-panel-bg-color, var(--surface-overlay));
|
|
31
|
+
--_dropdown-panel-maxh: var(--ds-dropdown-panel-maxh, 320px);
|
|
32
|
+
--_dropdown-panel-minw: var(--ds-dropdown-panel-minw, 0);
|
|
33
|
+
--_dropdown-panel-maxw: var(--ds-dropdown-panel-maxw, none);
|
|
34
|
+
|
|
29
35
|
.dropdown-panel {
|
|
30
|
-
//
|
|
31
|
-
//
|
|
32
|
-
// child of the pane and shrinks to its own option content width.
|
|
36
|
+
// The pane is sized from the trigger, so without `width: 100%` the panel is a flex
|
|
37
|
+
// child of it and shrinks to its own option content width.
|
|
33
38
|
width: 100%;
|
|
34
|
-
background: var(--
|
|
39
|
+
background: var(--_dropdown-panel-bg-color);
|
|
35
40
|
border: var(--border-width-default) solid var(--border-default);
|
|
36
41
|
border-radius: var(--_dropdown-panel-radius);
|
|
37
42
|
box-shadow: var(--shadow-popover);
|
|
38
43
|
padding: var(--space-1);
|
|
39
|
-
|
|
40
|
-
|
|
44
|
+
min-width: var(--_dropdown-panel-minw);
|
|
45
|
+
max-width: var(--_dropdown-panel-maxw);
|
|
46
|
+
max-height: var(--_dropdown-panel-maxh);
|
|
47
|
+
|
|
48
|
+
// The panel clips and the LIST scrolls, so a filter row or a select-all row
|
|
49
|
+
// stays put while the options move under it. A panel that scrolled itself
|
|
50
|
+
// would carry those rows out of view.
|
|
51
|
+
display: flex;
|
|
52
|
+
flex-direction: column;
|
|
53
|
+
overflow: hidden;
|
|
41
54
|
z-index: var(--layer-popover);
|
|
42
55
|
}
|
|
43
56
|
|
|
@@ -47,6 +60,11 @@
|
|
|
47
60
|
padding: 0;
|
|
48
61
|
display: flex;
|
|
49
62
|
flex-direction: column;
|
|
63
|
+
|
|
64
|
+
// A flex child will not shrink below its content without this, so the list
|
|
65
|
+
// would push the panel past its own max-height instead of scrolling.
|
|
66
|
+
min-height: 0;
|
|
67
|
+
overflow-y: auto;
|
|
50
68
|
gap: 2px;
|
|
51
69
|
}
|
|
52
70
|
|
|
@@ -80,6 +98,12 @@
|
|
|
80
98
|
gap: 2px;
|
|
81
99
|
}
|
|
82
100
|
|
|
101
|
+
.empty {
|
|
102
|
+
padding: var(--space-3) var(--space-4);
|
|
103
|
+
color: var(--text-tertiary);
|
|
104
|
+
text-align: center;
|
|
105
|
+
}
|
|
106
|
+
|
|
83
107
|
.option {
|
|
84
108
|
display: flex;
|
|
85
109
|
align-items: center;
|
|
@@ -121,11 +145,9 @@
|
|
|
121
145
|
background: var(--surface-secondary);
|
|
122
146
|
}
|
|
123
147
|
|
|
124
|
-
//
|
|
125
|
-
//
|
|
126
|
-
//
|
|
127
|
-
// the row had been hit. One rule here covers select, autocomplete and
|
|
128
|
-
// multi-select, which all render their options through this partial.
|
|
148
|
+
// A tap on a phone has no hover, so a pressed state is the only feedback that the
|
|
149
|
+
// row was hit. One rule here covers select, autocomplete and multi-select, which
|
|
150
|
+
// all render their options through this partial.
|
|
129
151
|
&:active:not(.is-disabled) {
|
|
130
152
|
background: var(--surface-muted);
|
|
131
153
|
}
|
package/styles/_ds-color.scss
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// Scoped accent recolour. A `ds-color="<family>"` attribute — on a zone
|
|
2
2
|
// container, on a component host, or applied via the ds.color() mixin in
|
|
3
3
|
// consumer config — flips the --accent-* pointer family to another brand/status
|
|
4
|
-
// family for its subtree. Components read --accent-* for their accent
|
|
5
|
-
//
|
|
6
|
-
//
|
|
4
|
+
// family for its subtree. Components read --accent-* for their accent, so the whole
|
|
5
|
+
// subtree recolours from this one rule. Pairs with the button/icon-button `color`
|
|
6
|
+
// input, which flips the same pointers
|
|
7
7
|
// per instance. With no attribute, --accent-* stays the primary family (see
|
|
8
8
|
// themes/_semantic.scss), so the default theme is unchanged.
|
|
9
9
|
|
package/styles/_field-box.scss
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
// One control-box height for the field family.
|
|
2
2
|
//
|
|
3
|
-
// `--field-h-sm`/`-md`/`-lg`
|
|
4
|
-
//
|
|
5
|
-
// other two as the raw `var(--hit-min)` / `var(--hit-cozy)` instead. A consumer
|
|
6
|
-
// retuning `--field-h-md` — the obvious lever, and the one the token name
|
|
7
|
-
// advertises — therefore changed nothing. Same values, so routing through the
|
|
8
|
-
// scale is visually neutral; it just makes the knob real.
|
|
3
|
+
// `--field-h-sm`/`-md`/`-lg` is the height scale every field-shaped control resolves
|
|
4
|
+
// through, so retuning `--field-h-md` moves them together.
|
|
9
5
|
//
|
|
10
6
|
// `--ds-field-height` is the public override and beats the size class, because a
|
|
11
7
|
// consumer setting it has already decided. Per-instance is CSS-variable scoping:
|
package/styles/_field-label.scss
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
// One label contract for the field family.
|
|
2
2
|
//
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
6
|
-
// `.field.field .label.label
|
|
7
|
-
// component rule. One class (`.label`), one token set, resolved here.
|
|
3
|
+
// One class (`.label`), one token set, resolved here, so a form mixing a select with an
|
|
4
|
+
// input renders its labels at one size and colour. It lives in one place because
|
|
5
|
+
// out-ranking a shimmed component rule from an app needs doubled selectors
|
|
6
|
+
// (`.field.field .label.label`).
|
|
8
7
|
//
|
|
9
8
|
// A MIXIN, not a global rule: a global `.label` would match consumer markup that
|
|
10
|
-
// happens to use the same class name
|
|
11
|
-
// specimens caused in ds-docs. Each field pays ~6 declarations of its own CSS.
|
|
9
|
+
// happens to use the same class name. Each field pays ~6 declarations of its own CSS.
|
|
12
10
|
//
|
|
13
11
|
// Per-instance retune is CSS-variable scoping, so no per-component token set is
|
|
14
12
|
// needed: `ds-select { --ds-field-label-transform: uppercase; }` reaches exactly
|
|
@@ -23,9 +21,6 @@
|
|
|
23
21
|
|
|
24
22
|
display: flex;
|
|
25
23
|
align-items: center;
|
|
26
|
-
|
|
27
|
-
// --field-gap-req is the label↔asterisk token; the old rules all spelled its
|
|
28
|
-
// value out as var(--space-1) instead of naming it.
|
|
29
24
|
gap: var(--field-gap-req);
|
|
30
25
|
font: var(--_field-label-weight) var(--_field-label-font-size) / var(--line-height-base) var(--font-sans);
|
|
31
26
|
color: var(--_field-label-color);
|
package/styles/_field-state.scss
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// Keyed off `data-field-state` on the host, which each field binds from
|
|
2
|
-
// `resolveFieldMessage`'s `controlState`.
|
|
3
|
-
// success
|
|
2
|
+
// `resolveFieldMessage`'s `controlState`. Only error carries a fill: a warning or
|
|
3
|
+
// success tint measures 1.05:1 against a white field, too faint to do the
|
|
4
|
+
// findability job a fill exists for, so neither carries one.
|
|
4
5
|
//
|
|
5
6
|
// The colour arguments exist so a component can pass its own `--ds-<name>-*-error`
|
|
6
7
|
// resolver: hardcoding the family token here would silently drop overrides
|
package/styles/_focus.scss
CHANGED
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
// `$control` names ONE control and must never be a blanket: a box-wide reset also
|
|
20
20
|
// silences the tab stops living in the box — a clear button, a stepper arrow — and
|
|
21
21
|
// then tabbing from the field to that button changes nothing on screen.
|
|
22
|
-
// Enforced by tools/check-focus-rings.mjs.
|
|
23
22
|
@mixin owns-the-focus-ring($control) {
|
|
24
23
|
#{$control}:where(:focus-visible) {
|
|
25
24
|
box-shadow: none;
|
|
@@ -36,7 +35,6 @@
|
|
|
36
35
|
--ds-control-focus-shadow-error: var(--focus-field-error);
|
|
37
36
|
}
|
|
38
37
|
|
|
39
|
-
// A hairline flush against the element, no gap — from the pin-475 prototype.
|
|
40
38
|
:root[data-focus='edge'] {
|
|
41
39
|
--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);
|
|
42
40
|
--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// Layout utility classes — grid helpers
|
|
2
|
-
//
|
|
1
|
+
// Layout utility classes — grid helpers. A divider is the ds-divider component,
|
|
2
|
+
// which is the single canonical source for one.
|
|
3
3
|
|
|
4
4
|
@use 'breakpoints' as bp;
|
|
5
5
|
|
package/styles/_link.scss
CHANGED
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
flow. Modifiers: .quiet, .inline, .standalone, .xs, .sm, .lg. */
|
|
4
4
|
|
|
5
5
|
.link {
|
|
6
|
-
/*
|
|
7
|
-
overrides inherit in. Hover/active derive from the resolved color. */
|
|
6
|
+
/* Hover and active derive from the resolved color. */
|
|
8
7
|
--_link-color: var(--ds-link-color, var(--text-link));
|
|
9
8
|
--_link-color-hover: var(--ds-link-color-hover, color-mix(in srgb, var(--_link-color) 80%, black));
|
|
10
9
|
--_link-color-active: var(--ds-link-color-active, color-mix(in srgb, var(--_link-color) 65%, black));
|
|
@@ -2,9 +2,8 @@
|
|
|
2
2
|
// panelClass (select, autocomplete, multi-select, date-picker, time-picker,
|
|
3
3
|
// color-picker, popover, tooltip, menu submenu). Animates the panel's ROOT
|
|
4
4
|
// CHILD, not the pane itself, so CDK's positioning transforms on
|
|
5
|
-
// `.cdk-overlay-pane` are left untouched.
|
|
6
|
-
//
|
|
7
|
-
// to reinstate it.
|
|
5
|
+
// `.cdk-overlay-pane` are left untouched. A leave animation runs on an ambient
|
|
6
|
+
// dismiss only; picking an option closes instantly (see `.ds-leaving` below).
|
|
8
7
|
//
|
|
9
8
|
// `data-ds-placement` names WHERE the panel sits relative to its trigger and is
|
|
10
9
|
// stamped by `prepareOverlayEnter()` before the panel is attached, so the panel
|
|
@@ -17,7 +16,6 @@
|
|
|
17
16
|
// teardown working and outranks a consumer keyframe carrying its own timing.
|
|
18
17
|
|
|
19
18
|
.cdk-overlay-pane.ds-overlay-pane {
|
|
20
|
-
/* Public --ds-overlay-* are read with fallbacks, never declared — consumer overrides inherit in. */
|
|
21
19
|
--_overlay-enter-keyframes: var(--ds-overlay-enter-keyframes, ds-slide-in);
|
|
22
20
|
--_overlay-enter-duration: var(--ds-overlay-enter-duration, var(--ds-motion-enter-panel-duration));
|
|
23
21
|
--_overlay-enter-easing: var(--ds-overlay-enter-easing, var(--ds-motion-enter-panel-easing));
|
package/styles/_press.scss
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
//
|
|
4
|
-
// tap overlay was a rectangle that ignored border-radius; we removed it, and
|
|
5
|
-
// this gives each interactive control a press state that INHERITS its shape:
|
|
1
|
+
// Complements the global tap-highlight reset (_reset.scss), which drops the native
|
|
2
|
+
// mobile overlay — a rectangle that ignored border-radius. This replaces it with a
|
|
3
|
+
// press state that INHERITS the control shape:
|
|
6
4
|
// `filter` + `transform` apply to the rendered element, so any border-radius /
|
|
7
5
|
// clip is followed automatically, and neither conflicts with the box-shadow
|
|
8
6
|
// focus rings (different properties).
|
package/styles/_reset.scss
CHANGED
package/styles/_scrollbar.scss
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Brand-tinted neutral thumb applied globally.
|
|
1
|
+
// Applied globally, not per component: a consumer gets the thumb without opting in.
|
|
3
2
|
|
|
4
3
|
html { scrollbar-width: thin; scrollbar-color: var(--scrollbar-thumb) transparent; }
|
|
5
4
|
*::-webkit-scrollbar { width: var(--scrollbar-w); height: var(--scrollbar-w); }
|
|
@@ -14,5 +13,4 @@ html { scrollbar-width: thin; scrollbar-color: var(--scrollbar-thumb) transparen
|
|
|
14
13
|
*::-webkit-scrollbar-thumb:hover { background: var(--scrollbar-thumb-hover); background-clip: padding-box; }
|
|
15
14
|
*::-webkit-scrollbar-thumb:active { background: var(--scrollbar-thumb-active); background-clip: padding-box; }
|
|
16
15
|
|
|
17
|
-
// Global text-selection — sourced from components-extras.css line 910.
|
|
18
16
|
::selection { background-color: var(--select-bg-color, color-mix(in srgb, var(--primary) 22%, transparent)); color: var(--text-primary); }
|
package/styles/_status.scss
CHANGED
|
@@ -6,8 +6,7 @@
|
|
|
6
6
|
// component keys off [data-status]; these rules set the public --ds-badge-* /
|
|
7
7
|
// --ds-status-dot-* tokens the components already read.
|
|
8
8
|
//
|
|
9
|
-
// @use 'styles/status' as status;
|
|
10
|
-
// // @use '@ids-group-ltd/ids-design-system/styles/status' as status; // external consumer
|
|
9
|
+
// @use '@ids-group-ltd/ids-design-system/styles/status' as status;
|
|
11
10
|
// @include status.semantic-preset; // optional universal set
|
|
12
11
|
// @include status.define((
|
|
13
12
|
// confirmed: (bg: var(--primary-subtitle), text: var(--primary-strong), dot: var(--accent)),
|
|
@@ -14,10 +14,9 @@
|
|
|
14
14
|
// surface, and swapping presets never loses the surface's own geometry.
|
|
15
15
|
//
|
|
16
16
|
// Exit presets mirror the entrances and are swappable the same way, via
|
|
17
|
-
// `--ds-<surface>-leave-keyframes`.
|
|
18
|
-
//
|
|
19
|
-
//
|
|
20
|
-
// animated element rather than from something inside it, which frees the name.
|
|
17
|
+
// `--ds-<surface>-leave-keyframes`. Swapping one is only safe because teardown checks
|
|
18
|
+
// that the animationend came from the animated element rather than matching the
|
|
19
|
+
// animation NAME — a name match would break closing entirely on a renamed keyframe.
|
|
21
20
|
//
|
|
22
21
|
// An exit reads `--_ds-exit-*` and falls back to the matching `--_ds-enter-*`, so
|
|
23
22
|
// a surface that leaves the way it arrived declares nothing: one preset replaces
|
package/styles/_text-clip.scss
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
overflow, and where the line box is tighter than the glyph box that overflow
|
|
4
4
|
eats the glyph. Mulish measures 1.257em, so --line-height-flat (1) and -tight
|
|
5
5
|
(1.1) are both under it and shave EVERY label, not only the ones with
|
|
6
|
-
descenders
|
|
6
|
+
descenders. `text-overflow` reads any non-`visible` overflow, so the
|
|
7
7
|
ellipsis still applies under `clip`. */
|
|
8
8
|
overflow: clip;
|
|
9
9
|
overflow-clip-margin: var(--space-1);
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
@include light.theme;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
// Brand-gray neutral family — opt-in light-context switch
|
|
27
|
+
// Brand-gray neutral family — opt-in light-context switch via <html data-neutrals="brand">.
|
|
28
28
|
// A light-theme feature: dark ships its own neutral ramp and wins below.
|
|
29
29
|
:root[data-neutrals='brand'] {
|
|
30
30
|
--neutral-0: var(--brand-gray-0);
|
|
@@ -33,9 +33,7 @@
|
|
|
33
33
|
--chart-seq-6: var(--blue-900);
|
|
34
34
|
|
|
35
35
|
/* DIVERGENT — red ← neutral → green
|
|
36
|
-
|
|
37
|
-
(CLAUDE_DESIGN_DS/patterns.css) so the Excess/Shortage matrix
|
|
38
|
-
matches the reference one-for-one. Explicit HSL keeps the ramp
|
|
36
|
+
Explicit HSL keeps the ramp
|
|
39
37
|
independent of palette retunes — re-skinning brand/red/green
|
|
40
38
|
should not shift the dataviz colour story. */
|
|
41
39
|
--chart-div--3: hsl(0deg 70% 40%); /* large negative (worst) */
|
package/styles/_tokens.scss
CHANGED
|
@@ -108,7 +108,8 @@
|
|
|
108
108
|
hue/saturation/lightness become configurable.
|
|
109
109
|
============================================================ */
|
|
110
110
|
|
|
111
|
-
/* --shadow-tint-h/s
|
|
111
|
+
/* --shadow-tint-h/s live in themes/_base-palette.scss and -l in each theme's
|
|
112
|
+
_palette.scss — palette-level
|
|
112
113
|
so dark palettes can override --shadow-tint-l → ~95% for soft light glows. */
|
|
113
114
|
|
|
114
115
|
--shadow-1: 0 1px 2px hsl(var(--shadow-tint-h) var(--shadow-tint-s) var(--shadow-tint-l) / 6%),
|
|
@@ -654,7 +655,7 @@
|
|
|
654
655
|
}
|
|
655
656
|
|
|
656
657
|
/* ============================================================
|
|
657
|
-
Density tiers —
|
|
658
|
+
Density tiers — set [data-density] on <html> or any container
|
|
658
659
|
============================================================ */
|
|
659
660
|
[data-density="ultra-compact"] {
|
|
660
661
|
/* Power-user / tradesperson tier: financial dashboards, log viewers,
|
|
@@ -662,7 +663,7 @@
|
|
|
662
663
|
and WCAG 2.5.8 (24px minimum) margins — acceptable only when:
|
|
663
664
|
(a) the screen is keyboard-first, (b) input is mouse/keys not
|
|
664
665
|
touch, (c) accidental-tap risk is low, (d) the user opted in.
|
|
665
|
-
Do not enable for mobile
|
|
666
|
+
Do not enable for mobile or touch-first layouts. */
|
|
666
667
|
--hit-cozy: 24px;
|
|
667
668
|
--hit-min: 24px;
|
|
668
669
|
--check-size: 14px;
|
package/styles/_typography.scss
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
1
|
+
// GLOBAL by design — a consumer applies these by class, so the names are part of the
|
|
2
|
+
// published surface.
|
|
3
3
|
//
|
|
4
4
|
// Consumer-first token contract (same as components): every token-driven
|
|
5
5
|
// property is a longhand read through a public `--ds-t-<name>-*` custom
|
package/themes/README.md
CHANGED
|
@@ -83,13 +83,13 @@ On-fill text uses theme-stable `--static-white` / `--static-ink` so it doesn't f
|
|
|
83
83
|
|
|
84
84
|
```scss
|
|
85
85
|
@use 'styles/ds';
|
|
86
|
-
@use './app/styles/brand-
|
|
86
|
+
@use './app/styles/brand-acme'; // [data-brand="acme"] overrides (light-authored)
|
|
87
87
|
```
|
|
88
88
|
|
|
89
89
|
## Brand vs theme
|
|
90
90
|
|
|
91
91
|
- **Theme** swaps the whole role map (light ↔ dark). Light is the default; dark is opt-in and, when active, fully replaces light.
|
|
92
|
-
- **Brand** is a thin overlay scoped via attribute (`[data-brand="X"]`), authored on a theme.
|
|
92
|
+
- **Brand** is a thin overlay scoped via attribute (`[data-brand="X"]`), authored on a theme. A brand authored on **light** pairs with the default (light) theme. A brand that wants dark adds a separate `[data-theme='dark'][data-brand="X"]` layer.
|
|
93
93
|
|
|
94
94
|
## Adding a new theme
|
|
95
95
|
|
|
@@ -110,5 +110,5 @@ Components never change — they consume semantic roles, which the active theme
|
|
|
110
110
|
- Components never reference base-palette primitives (`--blue-600`, `--neutral-200`) directly — use a Tier-2 role.
|
|
111
111
|
- Light is the default; dark is opt-in (`data-theme="dark"`); OS-follow is a consumer opt-in. No `prefers-color-scheme` by default.
|
|
112
112
|
- Themes are sibling and self-contained; `_semantic.scss`'s `@mixin roles` holds the light-default values, dark overrides the deltas.
|
|
113
|
-
- Brands are theme-authored overlays
|
|
113
|
+
- Brands are theme-authored overlays, and a brand authored on light pairs with the default theme.
|
|
114
114
|
- `--primary-hover`/`--primary-pressed` are auto-derived via `color-mix()` (toward black in light, toward white in dark).
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
// -----------------------------------------------------------------------
|
|
57
57
|
// Blue — defined as HSL channels so we can compose hsla() halos and tints
|
|
58
58
|
// from the same source. #2F54FF ≈ hsl(229, 100%, 59%). This is the ramp the
|
|
59
|
-
// default theme maps --primary onto (see
|
|
59
|
+
// default theme maps --primary onto (see themes/_semantic.scss). Naming is
|
|
60
60
|
// concrete (the colour) — the semantic --primary mapping lives in the lib.
|
|
61
61
|
// -----------------------------------------------------------------------
|
|
62
62
|
--blue-h: 229;
|
|
@@ -122,7 +122,7 @@
|
|
|
122
122
|
|
|
123
123
|
// -----------------------------------------------------------------------
|
|
124
124
|
// Red — HSL-channel-split for halo derivation. #D81F1F ≈ hsl(0, 75%, 49%).
|
|
125
|
-
// The default theme maps --error onto this ramp (see
|
|
125
|
+
// The default theme maps --error onto this ramp (see themes/_semantic.scss).
|
|
126
126
|
// -----------------------------------------------------------------------
|
|
127
127
|
--red-h: 0;
|
|
128
128
|
--red-s: 75%;
|
package/themes/_semantic.scss
CHANGED
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
--icon-on-primary: white;
|
|
84
84
|
|
|
85
85
|
/* Semantic → palette bridge. The lib knows colours by PURPOSE; the theme
|
|
86
|
-
(themes/
|
|
86
|
+
(themes/_base-palette.scss) ships the concrete ramps + HSL channels. This
|
|
87
87
|
is the one place that maps semantic roles onto a concrete palette. A brand
|
|
88
88
|
re-skins by overriding either the palette (--blue-*, --red-*) or these
|
|
89
89
|
role tokens directly.
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
|
|
120
120
|
/* Accent / secondary role — maps onto the palette --orange family (Tier-1),
|
|
121
121
|
kept distinct from --primary so the brand slots read apart. Override
|
|
122
|
-
--secondary-h/s/l per-brand
|
|
122
|
+
--secondary-h/s/l per-brand to reskin it —
|
|
123
123
|
--secondary recomposes automatically. Hover/pressed derive from --secondary
|
|
124
124
|
so any hue change propagates. */
|
|
125
125
|
--secondary-h: var(--orange-h);
|
|
@@ -15,8 +15,7 @@
|
|
|
15
15
|
// --neutral-* directly, so when both `[data-neutrals='brand']` and
|
|
16
16
|
// `[data-theme='dark']` are set (equal specificity) dark wins by source order —
|
|
17
17
|
// the brand-gray hue-tint is dropped and these fixed dark neutrals apply. Benign
|
|
18
|
-
// (renders correctly dark, just not brand-hue-tinted)
|
|
19
|
-
// a future follow-up, not v1.
|
|
18
|
+
// (renders correctly dark, just not brand-hue-tinted).
|
|
20
19
|
// =========================================================================
|
|
21
20
|
|
|
22
21
|
@mixin palette {
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
@mixin palette {
|
|
13
13
|
/* Neutral family slot — semantic pointer at the active gray ramp from the
|
|
14
14
|
palette. Default: hand-drawn cool-gray. <html data-neutrals="brand">
|
|
15
|
-
|
|
15
|
+
repoints it at the brand-derived brand-gray ramp,
|
|
16
16
|
where --primary-h re-tints every gray. Roles below consume --neutral-*
|
|
17
17
|
so the family switch never touches them. */
|
|
18
18
|
--neutral-0: var(--cool-gray-0);
|
package/themes/light/_theme.scss
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Light theme — Tier 2 role assignments (light).
|
|
3
3
|
//
|
|
4
4
|
// Composes the light-specific palette (neutral slot + shadow-l) with the
|
|
5
|
-
// shared role structure. Light needs no extra role overrides —
|
|
5
|
+
// shared role structure. Light needs no extra role overrides — _semantic.scss
|
|
6
6
|
// already holds the light-default values.
|
|
7
7
|
// =========================================================================
|
|
8
8
|
|