@loidolt/theme-styles 0.11.1 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loidolt/theme-styles",
3
- "version": "0.11.1",
3
+ "version": "0.12.0",
4
4
  "description": "Base styles, fonts, accessibility helpers, and utilities for Loidolt applications",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -19,19 +19,24 @@
19
19
  "./components/*": "./src/components/*.css",
20
20
  "./fonts": "./src/fonts.css",
21
21
  "./fonts/*": "./src/fonts/*",
22
+ "./standalone.css": "./dist/standalone.css",
23
+ "./standalone-core.css": "./dist/standalone-core.css",
24
+ "./fonts-embedded.css": "./dist/fonts-embedded.css",
22
25
  "./package.json": "./package.json"
23
26
  },
24
27
  "files": [
25
- "src"
28
+ "src",
29
+ "dist"
26
30
  ],
27
31
  "sideEffects": [
28
32
  "**/*.css"
29
33
  ],
30
34
  "scripts": {
31
- "build": "node -e \"console.log('theme-styles: source CSS is publish-ready')\""
35
+ "build": "node scripts/build-standalone.mjs",
36
+ "prepack": "npm run build"
32
37
  },
33
38
  "dependencies": {
34
- "@loidolt/theme-tokens": "^0.11.1"
39
+ "@loidolt/theme-tokens": "^0.12.0"
35
40
  },
36
41
  "publishConfig": {
37
42
  "access": "public",
@@ -131,11 +131,13 @@
131
131
  }
132
132
  :where(
133
133
  .ldt-icon-button,
134
+ .ldt-select,
134
135
  .ldt-number-field__button,
135
136
  .ldt-combobox__trigger,
136
137
  .ldt-password-input__toggle,
137
138
  .ldt-chip__remove,
138
139
  .ldt-media-controls__button,
140
+ .ldt-media-controls__speed,
139
141
  .ldt-lightbox__control,
140
142
  .ldt-media-carousel__control,
141
143
  .ldt-map .maplibregl-ctrl-group button
@@ -169,6 +171,112 @@
169
171
  .ldt-number-field:not(.ldt-number-field--bare) {
170
172
  grid-template-columns: 44px minmax(0, 1fr) 44px;
171
173
  }
174
+ :where(.ldt-list-row) {
175
+ min-height: 44px;
176
+ }
177
+ .ldt-file-input::file-selector-button {
178
+ min-height: 44px;
179
+ padding-block: var(--loidolt-space-2);
180
+ }
181
+ /* The only way to pick on a phone, where there is nothing to drag. */
182
+ :where(.ldt-dropzone__browse) {
183
+ display: inline-flex;
184
+ align-items: center;
185
+ min-height: 44px;
186
+ }
187
+ :where(.ldt-swatch-group__swatch) {
188
+ width: 44px;
189
+ height: 44px;
190
+ }
191
+ :where(.ldt-swatch-group) {
192
+ gap: var(--loidolt-space-2);
193
+ }
194
+ /* Breadcrumbs keep their small label type; an invisible 44px band around each link takes the
195
+ press. */
196
+ /* The band hangs off the item, so the link can still clip a long label with an ellipsis. */
197
+ .ldt-breadcrumbs__item {
198
+ position: relative;
199
+ }
200
+ .ldt-breadcrumbs__link::after {
201
+ content: '';
202
+ position: absolute;
203
+ inset: 50% 0 auto;
204
+ height: 44px;
205
+ transform: translateY(-50%);
206
+ }
207
+ /* Small in-place controls that keep their drawn size and take a 44px press around it: a stage
208
+ label, the folded map attribution, the brand, a field's trigger or reveal button inside its
209
+ border, a chip's remove button. */
210
+ :where(.ldt-pagination__page) {
211
+ min-width: 44px;
212
+ }
213
+ :where(
214
+ .ldt-stage-stepper__action,
215
+ .ldt-footnote-back,
216
+ .ldt-heading-anchor,
217
+ .ldt-brand,
218
+ .ldt-combobox__trigger,
219
+ .ldt-password-input__toggle,
220
+ .ldt-chip__remove
221
+ ) {
222
+ position: relative;
223
+ }
224
+ .ldt-footnote-back::after,
225
+ .ldt-heading-anchor::after,
226
+ .ldt-stage-stepper__action::after,
227
+ .ldt-map .maplibregl-ctrl-attrib-button::after,
228
+ .ldt-brand::after,
229
+ .ldt-combobox__trigger::after,
230
+ .ldt-password-input__toggle::after,
231
+ .ldt-chip__remove::after {
232
+ content: '';
233
+ position: absolute;
234
+ inset: 50% auto auto 50%;
235
+ width: max(100%, 44px);
236
+ height: 44px;
237
+ transform: translate(-50%, -50%);
238
+ }
239
+ /* A row's checkbox takes the whole of its 44px column: a square hung off it would reach into the
240
+ next cell, or under the sort header beside it. */
241
+ .ldt-table :where(th, td).ldt-data-table__select {
242
+ padding-inline: 0;
243
+ }
244
+ :where(.ldt-data-table__select .ldt-choice) {
245
+ min-width: 44px;
246
+ justify-content: center;
247
+ }
248
+ /*
249
+ * A sort header's press is the whole header cell, which grows to 44px: a square hung off the
250
+ * button would reach past the cell into the first row, over a row link or checkbox. A sticky
251
+ * cell is already positioned, and must stay sticky.
252
+ */
253
+ :where(.ldt-table th:has(> .ldt-table__sort)) {
254
+ height: 44px;
255
+ }
256
+ :where(.ldt-table:not(.ldt-table--sticky) th:has(> .ldt-table__sort)) {
257
+ position: relative;
258
+ }
259
+ .ldt-table__sort::after {
260
+ content: '';
261
+ position: absolute;
262
+ inset: 0;
263
+ }
264
+ /* A disclosure's summary keeps its marker, so it grows by padding rather than by flex. */
265
+ :where(.ldt-mermaid__source summary, summary.ldt-map-legend__summary) {
266
+ padding-block: max(var(--loidolt-space-3), calc((44px - 1lh) / 2));
267
+ }
268
+ /* Inline radios sit far enough apart that a thumb takes one, not its neighbour. */
269
+ :where(.ldt-radio-group:not(.ldt-radio-group--vertical)) {
270
+ column-gap: var(--loidolt-space-5);
271
+ }
272
+ /* A chip inside a MultiSelect field keeps its size: at 44px it would fill the field. Its
273
+ remove button keeps a 44px target through the invisible square above instead. */
274
+ .ldt-multi-select :where(.ldt-chip) {
275
+ min-height: auto;
276
+ }
277
+ .ldt-multi-select :where(.ldt-chip__remove) {
278
+ min-width: auto;
279
+ }
172
280
  }
173
281
 
174
282
  /*
@@ -23,19 +23,24 @@
23
23
  text-transform: var(--loidolt-control-transform);
24
24
  white-space: normal;
25
25
  }
26
- .ldt-button:hover:not(:disabled, [aria-disabled='true']) {
27
- color: var(--loidolt-text-inverse);
28
- background: var(--loidolt-surface-inverse);
26
+ /* Hover styles apply only where the pointer can hover: a tap leaves `:hover` stuck on touch screens. */
27
+ @media (hover: hover) {
28
+ .ldt-button:hover:not(:disabled, [aria-disabled='true']) {
29
+ color: var(--loidolt-text-inverse);
30
+ background: var(--loidolt-surface-inverse);
31
+ }
29
32
  }
30
33
  .ldt-button--primary {
31
34
  color: var(--loidolt-on-accent);
32
35
  border-color: var(--loidolt-accent);
33
36
  background: var(--loidolt-accent);
34
37
  }
35
- .ldt-button--primary:hover:not(:disabled, [aria-disabled='true']) {
36
- color: var(--loidolt-on-accent);
37
- border-color: var(--loidolt-accent-hover);
38
- background: var(--loidolt-accent-hover);
38
+ @media (hover: hover) {
39
+ .ldt-button--primary:hover:not(:disabled, [aria-disabled='true']) {
40
+ color: var(--loidolt-on-accent);
41
+ border-color: var(--loidolt-accent-hover);
42
+ background: var(--loidolt-accent-hover);
43
+ }
39
44
  }
40
45
  .ldt-button--quiet {
41
46
  color: var(--loidolt-text-muted);
@@ -48,10 +53,12 @@
48
53
  }
49
54
  /* Without this, the base hover would flip a destructive button to the neutral inverse
50
55
  surface — the danger affordance must survive hover. */
51
- .ldt-button--danger:hover:not(:disabled, [aria-disabled='true']) {
52
- color: var(--loidolt-on-danger);
53
- border-color: var(--loidolt-danger-hover);
54
- background: var(--loidolt-danger-hover);
56
+ @media (hover: hover) {
57
+ .ldt-button--danger:hover:not(:disabled, [aria-disabled='true']) {
58
+ color: var(--loidolt-on-danger);
59
+ border-color: var(--loidolt-danger-hover);
60
+ background: var(--loidolt-danger-hover);
61
+ }
55
62
  }
56
63
  .ldt-button--ghost,
57
64
  .ldt-button--text {
@@ -64,9 +71,11 @@
64
71
  padding: var(--loidolt-space-1);
65
72
  color: var(--loidolt-text-muted);
66
73
  }
67
- .ldt-button--text:hover:not(:disabled, [aria-disabled='true']) {
68
- color: var(--loidolt-text-accent);
69
- background: transparent;
74
+ @media (hover: hover) {
75
+ .ldt-button--text:hover:not(:disabled, [aria-disabled='true']) {
76
+ color: var(--loidolt-text-accent);
77
+ background: transparent;
78
+ }
70
79
  }
71
80
  .ldt-button--sm {
72
81
  min-height: var(--loidolt-size-control-sm);
@@ -139,9 +148,11 @@
139
148
  text-decoration: none;
140
149
  cursor: pointer;
141
150
  }
142
- .ldt-list-row:hover {
143
- background: var(--loidolt-surface-sunken);
144
- text-decoration: none;
151
+ @media (hover: hover) {
152
+ .ldt-list-row:hover {
153
+ background: var(--loidolt-surface-sunken);
154
+ text-decoration: none;
155
+ }
145
156
  }
146
157
  .ldt-list-row--selected {
147
158
  box-shadow: inset var(--loidolt-stroke-indicator) 0 0 var(--loidolt-accent);
@@ -29,6 +29,12 @@
29
29
  min-height: var(--ldt-chart-height, 20rem);
30
30
  align-content: center;
31
31
  }
32
+ /* On a phone a two-line message does not need the chart's full height. */
33
+ @media (max-width: 30rem) {
34
+ .ldt-chart__state.ldt-empty-state {
35
+ min-height: min(var(--ldt-chart-height, 20rem), 12rem);
36
+ }
37
+ }
32
38
  .ldt-chart__alert :where(p) {
33
39
  margin: 0 0 0.5rem;
34
40
  }
@@ -5,11 +5,31 @@
5
5
  * to where the last row would have been.
6
6
  */
7
7
  .ldt-table-wrap {
8
+ --ldt-table-shadow: color-mix(in srgb, var(--loidolt-text) 22%, transparent);
8
9
  position: relative;
9
10
  width: 100%;
10
11
  overflow-x: auto;
11
12
  border: var(--loidolt-border-width) solid var(--loidolt-border);
12
13
  border-radius: var(--loidolt-radius-surface);
14
+ /*
15
+ * A shadow on whichever side has more columns to scroll to. The two covers scroll with the
16
+ * content (`local`) and hide the fixed shadows (`scroll`) only while that edge is in view, so
17
+ * a table cut off at the right of a phone says so. The table itself is see-through inside
18
+ * the wrapper for the shadows to show; the wrapper paints its surface.
19
+ */
20
+ background:
21
+ linear-gradient(to right, var(--loidolt-surface) 30%, transparent) left / 2.5rem 100% no-repeat
22
+ local,
23
+ linear-gradient(to left, var(--loidolt-surface) 30%, transparent) right / 2.5rem 100% no-repeat
24
+ local,
25
+ radial-gradient(farthest-side at 0 50%, var(--ldt-table-shadow), transparent) left / 0.75rem
26
+ 100% no-repeat scroll,
27
+ radial-gradient(farthest-side at 100% 50%, var(--ldt-table-shadow), transparent) right / 0.75rem
28
+ 100% no-repeat scroll,
29
+ var(--loidolt-surface);
30
+ }
31
+ .ldt-table-wrap > .ldt-table {
32
+ background: transparent;
13
33
  }
14
34
  .ldt-table {
15
35
  width: 100%;
@@ -22,6 +42,11 @@
22
42
  border-bottom: var(--loidolt-border-width) solid var(--loidolt-border-soft);
23
43
  text-align: left;
24
44
  }
45
+ /* A column header names its column in one line; a narrow table scrolls rather than stacking
46
+ "LIGHT" over "VALUE". A row header is content, and wraps like the cells beside it. */
47
+ .ldt-table thead th {
48
+ white-space: nowrap;
49
+ }
25
50
  .ldt-table th {
26
51
  color: var(--loidolt-text-muted);
27
52
  font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
@@ -74,8 +99,11 @@
74
99
  text-transform: inherit;
75
100
  cursor: pointer;
76
101
  }
77
- .ldt-table__sort:hover {
78
- color: var(--loidolt-text);
102
+ /* Hover styles apply only where the pointer can hover: a tap leaves `:hover` stuck on touch screens. */
103
+ @media (hover: hover) {
104
+ .ldt-table__sort:hover {
105
+ color: var(--loidolt-text);
106
+ }
79
107
  }
80
108
  /* A CSS triangle rather than a glyph: no icon dependency, and nothing that can fall back to
81
109
  tofu in a font that lacks the arrow. */
@@ -86,8 +114,10 @@
86
114
  border-bottom: 0.34rem solid currentColor; /* @literal CSS triangle geometry */
87
115
  opacity: 0;
88
116
  }
89
- .ldt-table__sort:hover .ldt-table__sort-indicator {
90
- opacity: 0.4;
117
+ @media (hover: hover) {
118
+ .ldt-table__sort:hover .ldt-table__sort-indicator {
119
+ opacity: 0.4;
120
+ }
91
121
  }
92
122
  .ldt-table__sort[data-sort='ascending'] .ldt-table__sort-indicator,
93
123
  .ldt-table__sort[data-sort='descending'] .ldt-table__sort-indicator {
@@ -170,6 +200,10 @@
170
200
  .ldt-comment__content {
171
201
  min-width: 0;
172
202
  }
203
+ /* In a thread with numbered comments, one without a number lines its text up with theirs. */
204
+ .ldt-comment-list:has(.ldt-marker) .ldt-comment > .ldt-comment__content:first-child {
205
+ margin-inline-start: calc(1.25rem + var(--loidolt-space-2)); /* @literal marker width */
206
+ }
173
207
  .ldt-comment__meta {
174
208
  color: var(--loidolt-text-muted);
175
209
  font-size: var(--loidolt-font-size-sm);
@@ -256,8 +290,10 @@
256
290
  text-align: inherit;
257
291
  cursor: text;
258
292
  }
259
- .ldt-data-table__edit:hover {
260
- border-bottom-color: var(--loidolt-border-control);
293
+ @media (hover: hover) {
294
+ .ldt-data-table__edit:hover {
295
+ border-bottom-color: var(--loidolt-border-control);
296
+ }
261
297
  }
262
298
  .ldt-data-table__edit-input {
263
299
  width: 100%;
@@ -64,8 +64,11 @@
64
64
  text-transform: var(--loidolt-label-transform);
65
65
  cursor: pointer;
66
66
  }
67
- .ldt-code__copy:hover {
68
- background: var(--loidolt-surface);
67
+ /* Hover styles apply only where the pointer can hover: a tap leaves `:hover` stuck on touch screens. */
68
+ @media (hover: hover) {
69
+ .ldt-code__copy:hover {
70
+ background: var(--loidolt-surface);
71
+ }
69
72
  }
70
73
  .ldt-code__pre {
71
74
  margin: 0;
@@ -113,7 +116,10 @@
113
116
  }
114
117
 
115
118
  /* --- Diagrams -------------------------------------------------------------------------------- */
119
+ /* A diagram too wide to shrink scrolls, with the scroll shadows `.ldt-table-wrap` draws (each
120
+ component file stands alone, so the stack is repeated rather than shared). */
116
121
  .ldt-mermaid {
122
+ --ldt-scroll-shadow: color-mix(in srgb, var(--loidolt-text) 22%, transparent);
117
123
  display: grid;
118
124
  gap: var(--loidolt-space-2);
119
125
  margin: 0 0 1.1em;
@@ -121,7 +127,16 @@
121
127
  overflow-x: auto;
122
128
  border: var(--loidolt-border-width) solid var(--loidolt-border);
123
129
  border-radius: var(--loidolt-radius-surface);
124
- background: var(--loidolt-background);
130
+ background:
131
+ linear-gradient(to right, var(--loidolt-background) 30%, transparent) left / 2.5rem 100%
132
+ no-repeat local,
133
+ linear-gradient(to left, var(--loidolt-background) 30%, transparent) right / 2.5rem 100%
134
+ no-repeat local,
135
+ radial-gradient(farthest-side at 0 50%, var(--ldt-scroll-shadow), transparent) left / 0.75rem
136
+ 100% no-repeat scroll,
137
+ radial-gradient(farthest-side at 100% 50%, var(--ldt-scroll-shadow), transparent) right /
138
+ 0.75rem 100% no-repeat scroll,
139
+ var(--loidolt-background);
125
140
  }
126
141
  .ldt-mermaid__diagram[hidden] {
127
142
  display: none;
@@ -180,8 +195,10 @@ pre.ldt-mermaid {
180
195
  color: var(--loidolt-text-muted);
181
196
  text-decoration: none;
182
197
  }
183
- .ldt-toc__link:hover {
184
- color: var(--loidolt-text);
198
+ @media (hover: hover) {
199
+ .ldt-toc__link:hover {
200
+ color: var(--loidolt-text);
201
+ }
185
202
  }
186
203
  .ldt-toc__link[aria-current='location'] {
187
204
  border-inline-start-color: var(--loidolt-accent);
@@ -249,13 +266,21 @@ pre.ldt-mermaid {
249
266
  color: var(--loidolt-text);
250
267
  text-decoration: none;
251
268
  }
252
- .ldt-markdown-page__pager a:hover {
253
- border-color: var(--loidolt-border-strong);
269
+ @media (hover: hover) {
270
+ .ldt-markdown-page__pager a:hover {
271
+ border-color: var(--loidolt-border-strong);
272
+ }
254
273
  }
255
274
  .ldt-markdown-page__next {
256
275
  margin-inline-start: auto;
257
276
  text-align: end;
258
277
  }
278
+ /* On a phone the two cards stack full width, rather than one left and one right on two rows. */
279
+ @media (max-width: 30rem) {
280
+ .ldt-markdown-page__pager a {
281
+ flex: 1 1 100%;
282
+ }
283
+ }
259
284
  .ldt-markdown-page__direction {
260
285
  color: var(--loidolt-text-muted);
261
286
  font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
@@ -79,6 +79,18 @@
79
79
  font-variant-numeric: tabular-nums;
80
80
  text-align: end;
81
81
  }
82
+ /* On a phone the readout sits above the bar, as Slider's does: bars keep the full width and line
83
+ up whatever their readouts say. */
84
+ @media (max-width: 30rem) {
85
+ .ldt-progress-field {
86
+ flex-wrap: wrap;
87
+ row-gap: var(--loidolt-space-1);
88
+ }
89
+ .ldt-progress-field__value {
90
+ order: -1;
91
+ flex-basis: 100%;
92
+ }
93
+ }
82
94
  .ldt-progress--indeterminate .ldt-progress__bar {
83
95
  width: 40%;
84
96
  transform: none;
@@ -297,3 +309,196 @@
297
309
  .ldt-marker--active {
298
310
  outline: 2px solid var(--loidolt-surface); /* @literal halo that lifts the pin off a canvas */
299
311
  }
312
+ /*
313
+ * An ordered run of named steps. The root is a size container so a horizontal stepper can fall
314
+ * back to a column when the space it is given — not the viewport — is too narrow for a row.
315
+ * Each step is a two-column grid: the indicator, and beside it either the connector to the next
316
+ * step (horizontal, with the text below) or the text (vertical, with the connector below).
317
+ */
318
+ .ldt-stage-stepper {
319
+ container: ldt-stage-stepper / inline-size;
320
+ }
321
+ .ldt-stage-stepper__list {
322
+ display: flex;
323
+ margin: 0;
324
+ padding: 0;
325
+ list-style: none;
326
+ }
327
+ .ldt-stage-stepper__step {
328
+ --ldt-stage-stepper-tone: var(--loidolt-border-strong);
329
+ display: grid;
330
+ grid-template-columns: auto minmax(0, 1fr);
331
+ align-items: center;
332
+ gap: var(--loidolt-space-1) var(--loidolt-space-2);
333
+ min-width: 0;
334
+ }
335
+ .ldt-stage-stepper__indicator {
336
+ position: relative;
337
+ grid-area: 1 / 1;
338
+ display: inline-flex;
339
+ align-items: center;
340
+ justify-content: center;
341
+ width: 1.5rem;
342
+ height: 1.5rem;
343
+ border: var(--loidolt-stroke-indicator) solid var(--ldt-stage-stepper-tone);
344
+ border-radius: var(--loidolt-border-radius-pill);
345
+ color: var(--loidolt-text-muted);
346
+ background: var(--loidolt-surface);
347
+ font: var(--loidolt-font-size-xs) var(--loidolt-font-utility);
348
+ font-variant-numeric: tabular-nums;
349
+ }
350
+ /* The line to the next step. The last step has none. */
351
+ .ldt-stage-stepper__step:not(:last-child)::after {
352
+ content: '';
353
+ grid-area: 1 / 2;
354
+ height: var(--loidolt-stroke-indicator);
355
+ margin-inline-end: var(--loidolt-space-2);
356
+ background: var(--loidolt-border);
357
+ }
358
+ .ldt-stage-stepper__step--done:not(:last-child)::after {
359
+ background: var(--loidolt-success);
360
+ }
361
+ .ldt-stage-stepper__body {
362
+ grid-area: 2 / 1 / auto / -1;
363
+ display: grid;
364
+ gap: var(--loidolt-space-1);
365
+ min-width: 0;
366
+ padding-inline-end: var(--loidolt-space-3);
367
+ }
368
+ .ldt-stage-stepper__label {
369
+ color: var(--loidolt-text);
370
+ font: var(--loidolt-font-size-sm) var(--loidolt-font-utility);
371
+ font-weight: var(--loidolt-label-weight);
372
+ overflow-wrap: anywhere;
373
+ }
374
+ .ldt-stage-stepper__action {
375
+ justify-self: start;
376
+ margin: 0;
377
+ padding: 0;
378
+ border: 0;
379
+ background: none;
380
+ text-align: start;
381
+ cursor: pointer;
382
+ }
383
+ /* Hover styles apply only where the pointer can hover: a tap leaves `:hover` stuck on touch screens. */
384
+ @media (hover: hover) {
385
+ .ldt-stage-stepper__action:hover {
386
+ color: var(--loidolt-text-accent);
387
+ text-decoration: underline;
388
+ }
389
+ }
390
+ .ldt-stage-stepper__description {
391
+ margin: 0;
392
+ color: var(--loidolt-text-muted);
393
+ font-size: var(--loidolt-font-size-sm);
394
+ overflow-wrap: anywhere;
395
+ }
396
+ .ldt-stage-stepper__progress {
397
+ min-width: 0;
398
+ }
399
+ /* A bar the width of a wide column reads as a page divider; keep it to a line's length. */
400
+ .ldt-stage-stepper__body > .ldt-progress-field {
401
+ max-width: 24rem;
402
+ }
403
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__step {
404
+ flex: 1 1 0;
405
+ align-content: start;
406
+ }
407
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__step:last-child {
408
+ flex-grow: 0.6;
409
+ }
410
+ /* A column: the text sits beside its indicator and the connector runs down beneath it. */
411
+ .ldt-stage-stepper--vertical .ldt-stage-stepper__list {
412
+ flex-direction: column;
413
+ }
414
+ .ldt-stage-stepper--vertical .ldt-stage-stepper__step {
415
+ align-items: start;
416
+ }
417
+ .ldt-stage-stepper--vertical .ldt-stage-stepper__body {
418
+ grid-area: 1 / 2 / span 2 / auto;
419
+ align-self: center;
420
+ padding-block-end: var(--loidolt-space-4);
421
+ }
422
+ .ldt-stage-stepper--vertical .ldt-stage-stepper__step:last-child .ldt-stage-stepper__body {
423
+ padding-block-end: 0;
424
+ }
425
+ .ldt-stage-stepper--vertical .ldt-stage-stepper__step:not(:last-child)::after {
426
+ grid-area: 2 / 1;
427
+ justify-self: center;
428
+ width: var(--loidolt-stroke-indicator);
429
+ height: auto;
430
+ min-height: var(--loidolt-space-4);
431
+ align-self: stretch;
432
+ margin: 0;
433
+ }
434
+ /* A row of steps too narrow to read: the same column the vertical stepper draws. */
435
+ @container ldt-stage-stepper (max-width: 36rem) {
436
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__list {
437
+ flex-direction: column;
438
+ }
439
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__step {
440
+ align-items: start;
441
+ }
442
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__body {
443
+ grid-area: 1 / 2 / span 2 / auto;
444
+ align-self: center;
445
+ padding-block-end: var(--loidolt-space-4);
446
+ }
447
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__step:last-child .ldt-stage-stepper__body {
448
+ padding-block-end: 0;
449
+ }
450
+ .ldt-stage-stepper--horizontal .ldt-stage-stepper__step:not(:last-child)::after {
451
+ grid-area: 2 / 1;
452
+ justify-self: center;
453
+ width: var(--loidolt-stroke-indicator);
454
+ height: auto;
455
+ min-height: var(--loidolt-space-4);
456
+ align-self: stretch;
457
+ margin: 0;
458
+ }
459
+ }
460
+ .ldt-stage-stepper__step--running {
461
+ --ldt-stage-stepper-tone: var(--loidolt-border);
462
+ }
463
+ .ldt-stage-stepper__step--running .ldt-stage-stepper__indicator {
464
+ color: var(--loidolt-text-accent);
465
+ }
466
+ /* Activity: an accent arc turning around the ring. Under reduced motion it holds still. */
467
+ .ldt-stage-stepper__activity {
468
+ position: absolute;
469
+ inset: calc(var(--loidolt-stroke-indicator) * -1);
470
+ border: var(--loidolt-stroke-indicator) solid transparent;
471
+ border-top-color: var(--loidolt-accent);
472
+ border-right-color: var(--loidolt-accent);
473
+ border-radius: var(--loidolt-border-radius-pill);
474
+ animation: ldt-spin 1s linear infinite;
475
+ }
476
+ @media (prefers-reduced-motion: reduce) {
477
+ .ldt-stage-stepper__activity {
478
+ animation: none;
479
+ }
480
+ }
481
+ .ldt-stage-stepper__step--done {
482
+ --ldt-stage-stepper-tone: var(--loidolt-success);
483
+ }
484
+ .ldt-stage-stepper__step--done .ldt-stage-stepper__indicator {
485
+ color: var(--loidolt-on-success);
486
+ background: var(--loidolt-success);
487
+ }
488
+ .ldt-stage-stepper__step--failed {
489
+ --ldt-stage-stepper-tone: var(--loidolt-danger);
490
+ }
491
+ .ldt-stage-stepper__step--failed .ldt-stage-stepper__indicator {
492
+ color: var(--loidolt-on-danger);
493
+ background: var(--loidolt-danger);
494
+ }
495
+ .ldt-stage-stepper__step--failed .ldt-stage-stepper__description {
496
+ color: var(--loidolt-text-danger);
497
+ }
498
+ .ldt-stage-stepper__step--skipped .ldt-stage-stepper__indicator {
499
+ border-style: dashed;
500
+ }
501
+ .ldt-stage-stepper__step--skipped .ldt-stage-stepper__label,
502
+ .ldt-stage-stepper__step--pending .ldt-stage-stepper__label {
503
+ color: var(--loidolt-text-muted);
504
+ }