@godxjp/ui 18.5.0 → 18.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/dist/components/charts/compact-bar-trend.d.ts +2 -1
  2. package/dist/components/charts/index.d.ts +4 -1
  3. package/dist/components/data-display/data-table.d.ts +25 -4
  4. package/dist/components/data-display/data-table.js +13 -2
  5. package/dist/components/data-display/empty-state.js +1 -1
  6. package/dist/components/data-display/index.d.ts +1 -1
  7. package/dist/components/data-display/list-row.d.ts +19 -0
  8. package/dist/components/data-display/list-row.js +2 -0
  9. package/dist/components/data-display/qr-code.d.ts +1 -1
  10. package/dist/components/data-display/table.d.ts +47 -2
  11. package/dist/components/data-display/table.js +29 -4
  12. package/dist/components/data-entry/command.d.ts +10 -10
  13. package/dist/components/data-entry/index.d.ts +1 -0
  14. package/dist/components/data-entry/input-otp.d.ts +1 -0
  15. package/dist/components/feedback/alert.d.ts +20 -2
  16. package/dist/components/feedback/alert.js +11 -1
  17. package/dist/components/feedback/dialog.d.ts +14 -1
  18. package/dist/components/feedback/dialog.js +4 -0
  19. package/dist/components/feedback/index.d.ts +3 -3
  20. package/dist/components/feedback/index.js +5 -1
  21. package/dist/components/general/logo.d.ts +7 -1
  22. package/dist/components/general/logo.js +1 -1
  23. package/dist/components/layout/app-shell.d.ts +1 -1
  24. package/dist/components/layout/app-shell.js +55 -46
  25. package/dist/components/layout/auth-account-summary.d.ts +5 -0
  26. package/dist/components/layout/auth-account-summary.js +31 -0
  27. package/dist/components/layout/auth-shell.d.ts +5 -2
  28. package/dist/components/layout/centered-shell.d.ts +1 -1
  29. package/dist/components/layout/centered-shell.js +28 -19
  30. package/dist/components/layout/error-surface.d.ts +35 -0
  31. package/dist/components/layout/error-surface.js +155 -0
  32. package/dist/components/layout/flex.d.ts +1 -1
  33. package/dist/components/layout/flex.js +4 -0
  34. package/dist/components/layout/index.d.ts +7 -0
  35. package/dist/components/layout/index.js +6 -0
  36. package/dist/components/layout/page-container.d.ts +1 -1
  37. package/dist/components/layout/page-container.js +23 -41
  38. package/dist/components/layout/page-header.d.ts +22 -0
  39. package/dist/components/layout/page-header.js +89 -0
  40. package/dist/components/navigation/filter-bar.d.ts +2 -2
  41. package/dist/components/navigation/filter-bar.js +44 -1
  42. package/dist/components/navigation/index.d.ts +1 -1
  43. package/dist/components/navigation/steps.js +38 -19
  44. package/dist/components/navigation/tabs.js +12 -3
  45. package/dist/components/ui/avatar.d.ts +2 -1
  46. package/dist/components/ui/avatar.js +2 -1
  47. package/dist/components/ui/input-otp.d.ts +4 -1
  48. package/dist/components/ui/input-otp.js +2 -1
  49. package/dist/components/ui/toggle-group.d.ts +7 -4
  50. package/dist/components/ui/toggle-group.js +32 -21
  51. package/dist/email/brand-mark.d.ts +21 -5
  52. package/dist/email/brand-mark.js +5 -0
  53. package/dist/email/color.d.ts +2 -1
  54. package/dist/email/geometry.d.ts +9 -1
  55. package/dist/email/geometry.js +1 -0
  56. package/dist/email/index.d.ts +6 -1
  57. package/dist/email/index.js +6 -0
  58. package/dist/email/inline-style.d.ts +7 -5
  59. package/dist/email/inline-style.js +5 -0
  60. package/dist/email/tokens.generated.d.ts +40 -20
  61. package/dist/email/tokens.generated.js +40 -20
  62. package/dist/email/urgency.d.ts +22 -0
  63. package/dist/email/urgency.js +14 -0
  64. package/dist/i18n/messages/en.json +26 -1
  65. package/dist/i18n/messages/ja.json +23 -1
  66. package/dist/i18n/messages/vi.json +23 -1
  67. package/dist/props/components/data-display.prop.d.ts +63 -1
  68. package/dist/props/components/data-entry.prop.d.ts +6 -0
  69. package/dist/props/components/feedback.prop.d.ts +6 -0
  70. package/dist/props/components/index.d.ts +1 -1
  71. package/dist/props/components/layout.prop.d.ts +244 -4
  72. package/dist/props/components/navigation.prop.d.ts +57 -1
  73. package/dist/props/registry.d.ts +205 -5
  74. package/dist/props/registry.js +270 -6
  75. package/dist/props/vocabulary/data.prop.d.ts +27 -0
  76. package/dist/props/vocabulary/index.d.ts +3 -3
  77. package/dist/props/vocabulary/interaction.prop.d.ts +19 -2
  78. package/dist/props/vocabulary/layout.prop.d.ts +41 -7
  79. package/dist/styles/alert-layout.css +36 -0
  80. package/dist/styles/control.css +28 -0
  81. package/dist/styles/data-display-layout.css +26 -0
  82. package/dist/styles/layout.css +212 -0
  83. package/dist/styles/logo-layout.css +42 -9
  84. package/dist/styles/navigation-layout.css +109 -0
  85. package/dist/styles/shell-layout.css +336 -0
  86. package/dist/styles/table-layout.css +164 -1
  87. package/dist/theme/dxs.canonical.css +5 -4
  88. package/dist/tokens/axes.css +4 -3
  89. package/dist/tokens/base.css +1 -0
  90. package/dist/tokens/components/data-display.css +13 -0
  91. package/dist/tokens/components/email.css +43 -16
  92. package/dist/tokens/components/error-surface.css +36 -0
  93. package/dist/tokens/components/feedback.css +20 -0
  94. package/dist/tokens/components/list-row.css +20 -0
  95. package/dist/tokens/components/logo.css +52 -10
  96. package/dist/tokens/components/navigation.css +41 -0
  97. package/dist/tokens/components/shell.css +109 -0
  98. package/dist/tokens/components/table.css +45 -0
  99. package/dist/tokens/foundation.css +26 -0
  100. package/dist/tokens/semantic/layout.css +38 -0
  101. package/package.json +8 -2
@@ -74,12 +74,17 @@
74
74
  gap: var(--space-inline-sm);
75
75
  }
76
76
 
77
+ /* The footer owns its own inset on BOTH axes (gh#236) — it is a self-contained slot that is
78
+ * usually dropped straight into a flush container, so relying on an ancestor for inline/block-end
79
+ * padding left the label and the page-size Select flush against the container edge and its
80
+ * closing border. Logical properties only (RTL-safe); both axes are tunable tokens (#45). */
77
81
  .ui-data-table-pagination {
78
82
  display: flex;
79
83
  align-items: center;
80
84
  justify-content: flex-end;
81
85
  gap: var(--space-inline-sm);
82
- padding-top: var(--space-stack-sm);
86
+ padding-block: var(--table-pagination-padding-y, var(--space-stack-sm));
87
+ padding-inline: var(--table-pagination-padding-x, var(--table-cell-space-x));
83
88
  }
84
89
 
85
90
  /* Numbered footer may wrap only between its two semantic groups. The supported JA/EN/VI locale
@@ -115,10 +120,22 @@
115
120
 
116
121
  .ui-data-table-surface {
117
122
  overflow: hidden;
123
+ /* Narrow-viewport legibility floor — a TOKEN, not the old `min-w-[640px]` literal (gh#253,
124
+ * rule #45). Cleared at the `sm` step below, and opted out of entirely by the collection
125
+ * preset, which owns its width through the column-priority measures. */
126
+ min-inline-size: var(--table-surface-min-inline-size);
118
127
  border: 1px solid hsl(var(--border));
119
128
  border-radius: var(--radius-md);
120
129
  }
121
130
 
131
+ /* `preset="action-collection"` (gh#253) — the priority measures fit the table to its container at
132
+ * every width, so the desktop floor would re-introduce exactly the horizontal scroll the preset
133
+ * removes. Attribute-scoped: `preset="default"` emits NO attribute, so an untouched DataTable
134
+ * never matches this rule (the inert-default contract, gh#231). */
135
+ .ui-data-table-surface[data-preset="action-collection"] {
136
+ min-inline-size: 0;
137
+ }
138
+
122
139
  /* Zebra striping (opt-in via the `striped` prop). Selected rows keep their
123
140
  * own emphasis, so they are excluded from the stripe. */
124
141
  .ui-data-table-surface[data-striped] tbody tr:nth-child(even):not([data-state="selected"]) {
@@ -187,6 +204,12 @@
187
204
  .ui-data-table-scroll::after {
188
205
  inset-inline-end: 0;
189
206
  }
207
+
208
+ /* From `sm` up the viewport is already wider than the floor, so it is released and the surface
209
+ * simply fills its container (this is the `sm:min-w-0` half of the old utility pair). */
210
+ .ui-data-table-surface {
211
+ min-inline-size: 0;
212
+ }
190
213
  }
191
214
 
192
215
  /* ── Pinned (sticky) inline-end column ────────────────────────────────
@@ -233,3 +256,143 @@
233
256
  );
234
257
  }
235
258
  }
259
+
260
+ @layer components {
261
+ /* ── Table · `preset="action-collection"` (gh#253) ───────────────────────────────────────────
262
+ * The canonical dense approval / action queue: requester · target · reason · requested date ·
263
+ * row actions, all five discoverable in the initial 390px frame, WITHOUT a consumer width, a
264
+ * hidden column or a page-local breakpoint.
265
+ *
266
+ * It keeps the REAL table: no `display` change, no role rewriting, no card transformation — so
267
+ * `<table>/<thead>/<tr>/<th>/<td>` semantics, header association, `aria-sort` and screen-reader
268
+ * table navigation survive exactly as they are at 1440. What the preset replaces is the SIZING
269
+ * model: the desktop INTRINSIC column widths (a `white-space: nowrap` reason column is what
270
+ * makes a five-column queue 1511px wide and forces the horizontal scroll gh#253 reports) give
271
+ * way to `table-layout: fixed` plus token-owned column-PRIORITY measures, and cells wrap.
272
+ *
273
+ * The collapse step is measured against the TABLE'S OWN container, not the viewport (a table in
274
+ * a master rail must collapse before the page does), so it is a container query. Below the step
275
+ * only the MEASURES and the type/padding tier change — the structure is identical. */
276
+ .ui-table-collection {
277
+ container: ui-table-collection / inline-size;
278
+ }
279
+
280
+ .ui-table-collection [data-slot="table"] {
281
+ table-layout: fixed;
282
+ inline-size: 100%;
283
+ }
284
+
285
+ .ui-table-collection :is([data-slot="table-head"], [data-slot="table-cell"]) {
286
+ /* The column measure comes from `priority`; an unmarked column takes what is left (`auto`),
287
+ * which is the free-text column. */
288
+ inline-size: var(--table-action-collection-column-width, auto);
289
+ overflow-wrap: anywhere;
290
+ white-space: normal;
291
+ vertical-align: top;
292
+ }
293
+
294
+ .ui-table-collection [data-priority="primary"] {
295
+ --table-action-collection-column-width: var(--table-action-collection-primary-width);
296
+ }
297
+
298
+ .ui-table-collection [data-priority="secondary"] {
299
+ --table-action-collection-column-width: var(--table-action-collection-secondary-width);
300
+ }
301
+
302
+ .ui-table-collection [data-priority="meta"] {
303
+ --table-action-collection-column-width: var(--table-action-collection-meta-width);
304
+ }
305
+
306
+ .ui-table-collection [data-priority="actions"] {
307
+ --table-action-collection-column-width: var(--table-action-collection-actions-width);
308
+ text-align: end;
309
+ }
310
+
311
+ /* Below the step the SOURCE measures are re-pointed to their compact tier (and the type / row
312
+ * density with them); nothing else moves. One block per canonical step — a media/container
313
+ * query cannot read a `var()`, so the tokenized scale is written out (sm 40rem · md 48rem ·
314
+ * lg 64rem · xl 80rem, the same steps as `--master-detail-collapse-below`). */
315
+ @container ui-table-collection (width < 40rem) {
316
+ [data-collapse-below="sm"] [data-slot="table"] {
317
+ --table-action-collection-primary-width: var(--table-action-collection-primary-width-compact);
318
+ --table-action-collection-secondary-width: var(
319
+ --table-action-collection-secondary-width-compact
320
+ );
321
+ --table-action-collection-meta-width: var(--table-action-collection-meta-width-compact);
322
+ --table-action-collection-actions-width: var(--table-action-collection-actions-width-compact);
323
+ --table-row-height: var(--table-action-collection-row-height-compact);
324
+ --table-cell-space-x: var(--table-action-collection-cell-space-x-compact);
325
+ --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
326
+ font-size: var(--table-action-collection-font-size-compact);
327
+ }
328
+
329
+ /* A nowrap child (a Badge pill, a chip) would otherwise bleed into the next column at the
330
+ * compact measure — inside a collapsed action cell everything wraps. */
331
+ [data-collapse-below="sm"] [data-slot="table-cell"] * {
332
+ white-space: normal;
333
+ }
334
+ }
335
+
336
+ @container ui-table-collection (width < 48rem) {
337
+ [data-collapse-below="md"] [data-slot="table"] {
338
+ --table-action-collection-primary-width: var(--table-action-collection-primary-width-compact);
339
+ --table-action-collection-secondary-width: var(
340
+ --table-action-collection-secondary-width-compact
341
+ );
342
+ --table-action-collection-meta-width: var(--table-action-collection-meta-width-compact);
343
+ --table-action-collection-actions-width: var(--table-action-collection-actions-width-compact);
344
+ --table-row-height: var(--table-action-collection-row-height-compact);
345
+ --table-cell-space-x: var(--table-action-collection-cell-space-x-compact);
346
+ --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
347
+ font-size: var(--table-action-collection-font-size-compact);
348
+ }
349
+
350
+ /* A nowrap child (a Badge pill, a chip) would otherwise bleed into the next column at the
351
+ * compact measure — inside a collapsed action cell everything wraps. */
352
+ [data-collapse-below="md"] [data-slot="table-cell"] * {
353
+ white-space: normal;
354
+ }
355
+ }
356
+
357
+ @container ui-table-collection (width < 64rem) {
358
+ [data-collapse-below="lg"] [data-slot="table"] {
359
+ --table-action-collection-primary-width: var(--table-action-collection-primary-width-compact);
360
+ --table-action-collection-secondary-width: var(
361
+ --table-action-collection-secondary-width-compact
362
+ );
363
+ --table-action-collection-meta-width: var(--table-action-collection-meta-width-compact);
364
+ --table-action-collection-actions-width: var(--table-action-collection-actions-width-compact);
365
+ --table-row-height: var(--table-action-collection-row-height-compact);
366
+ --table-cell-space-x: var(--table-action-collection-cell-space-x-compact);
367
+ --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
368
+ font-size: var(--table-action-collection-font-size-compact);
369
+ }
370
+
371
+ /* A nowrap child (a Badge pill, a chip) would otherwise bleed into the next column at the
372
+ * compact measure — inside a collapsed action cell everything wraps. */
373
+ [data-collapse-below="lg"] [data-slot="table-cell"] * {
374
+ white-space: normal;
375
+ }
376
+ }
377
+
378
+ @container ui-table-collection (width < 80rem) {
379
+ [data-collapse-below="xl"] [data-slot="table"] {
380
+ --table-action-collection-primary-width: var(--table-action-collection-primary-width-compact);
381
+ --table-action-collection-secondary-width: var(
382
+ --table-action-collection-secondary-width-compact
383
+ );
384
+ --table-action-collection-meta-width: var(--table-action-collection-meta-width-compact);
385
+ --table-action-collection-actions-width: var(--table-action-collection-actions-width-compact);
386
+ --table-row-height: var(--table-action-collection-row-height-compact);
387
+ --table-cell-space-x: var(--table-action-collection-cell-space-x-compact);
388
+ --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
389
+ font-size: var(--table-action-collection-font-size-compact);
390
+ }
391
+
392
+ /* A nowrap child (a Badge pill, a chip) would otherwise bleed into the next column at the
393
+ * compact measure — inside a collapsed action cell everything wraps. */
394
+ [data-collapse-below="xl"] [data-slot="table-cell"] * {
395
+ white-space: normal;
396
+ }
397
+ }
398
+ }
@@ -33,10 +33,11 @@
33
33
 
34
34
  :root {
35
35
  /* ── Brand palette — the shipped GodX Navy ramp (identical to the `brand`
36
- * axis preset). The brand-green IDENTITY mark is deliberately NOT here:
37
- * `--logo-godx-color` / `--logo-wordmark-color` default to the `--success`
38
- * identity role at their call sites and never read `--primary`, so a
39
- * re-themed action colour can never recolour the GoDX mark or wordmark. */
36
+ * axis preset). The emerald IDENTITY mark is deliberately NOT here:
37
+ * `--logo-godx-color` / `--logo-wordmark-color` default to the `--brand`
38
+ * IDENTITY role at their call sites and never read `--primary` (nor the
39
+ * `--success` status green gh#250), so a re-themed action colour can
40
+ * never recolour the GoDX mark or wordmark. */
40
41
  --primary: 211 73% 15%;
41
42
  --primary-foreground: 0 0% 100%;
42
43
  --ring: 24 99% 46%;
@@ -73,9 +73,10 @@
73
73
  * `src/theme/dxs.canonical.css` mirrors this block for stylesheet-only apps;
74
74
  * `src/tokens/__tests__/dxs-canonical-theme.test.ts` fails if the two drift.
75
75
  *
76
- * The brand-green GoDX identity mark needs no binding: `--logo-godx-color` /
77
- * `--logo-wordmark-color` already default to the `--success` identity role at
78
- * their call sites and never reference `--primary`. */
76
+ * The GoDX identity mark needs no binding: `--logo-godx-color` /
77
+ * `--logo-wordmark-color` already default to the `--brand` IDENTITY role (the
78
+ * canonical emerald) at their call sites, and never reference `--primary` — nor
79
+ * the `--success` status green they wrongly borrowed before gh#250. */
79
80
  :root[data-brand="dxs"] {
80
81
  --primary: 211 73% 15%;
81
82
  --primary-foreground: 0 0% 100%;
@@ -24,3 +24,4 @@
24
24
  @import "./components/shell.css";
25
25
  @import "./components/sidebar.css";
26
26
  @import "./components/legal-document.css";
27
+ @import "./components/error-surface.css";
@@ -15,6 +15,19 @@
15
15
  Painted as an overlay so a service sets --avatar-tint: hsl(var(--primary) / 0.08). */
16
16
  --avatar-tint: transparent;
17
17
 
18
+ /* Entity-header mark — `<Avatar shape="square">` (gh#249): the compact rounded SQUARE an
19
+ organization/service header uses, as opposed to the round person avatar. Every value is a knob
20
+ (rule #45) so a service matches the mark to its own grid without a className override.
21
+ --avatar-square-background / --avatar-square-foreground are role-mirror knobs: `initial` so the
22
+ --primary / --primary-foreground defaults re-resolve at the CALL SITE under a scoped
23
+ [data-tenant]/.dark theme (a :root binding to a role var would freeze at the :root value).
24
+ Defaults = --radius-lg corners · --control-height box (same as the circle avatar, so swapping
25
+ shape never reflows a header) · hsl(var(--primary)) fill · hsl(var(--primary-foreground)) glyph. */
26
+ --avatar-square-radius: var(--radius-lg);
27
+ --avatar-square-size: var(--control-height);
28
+ --avatar-square-background: initial;
29
+ --avatar-square-foreground: initial;
30
+
18
31
  /* Progress track + fill — `initial` so the role defaults re-resolve under a scoped theme.
19
32
  Track reads --secondary, fill reads --success; a service re-tones once.
20
33
  Defaults = hsl(var(--secondary)) track · hsl(var(--success)) fill. */
@@ -10,8 +10,10 @@
10
10
  * string. Where a value mirrors a web token the comment names it, so a retune stays traceable.
11
11
  *
12
12
  * Colours are deliberately NOT redeclared here — they derive from the semantic roles
13
- * (--card/--background/--foreground/--muted/--border/--primary/--ring/--success) and are converted
13
+ * (--card/--background/--foreground/--muted/--border/--primary/--ring/--brand) and are converted
14
14
  * HSL→hex at module load, so a re-themed role re-tints the email with zero copy-paste.
15
+ * The identity mark reads --brand, NOT --success: --success is the wakatake status green, and the
16
+ * two are deliberately distinct roles (gh#250).
15
17
  */
16
18
  :root {
17
19
  /* ── Shell — the 480px transactional-email geometry ─────────────────────────────────────── */
@@ -24,31 +26,53 @@
24
26
  --email-stack-gap: 24px; /* block rhythm — mirrors --space-stack-lg (1.5rem) */
25
27
  --email-stack-gap-sm: 12px; /* tight rhythm — mirrors --space-3 (0.75rem) */
26
28
 
27
- /* ── Brand mark — the canonical GoDX capsule (see EMAIL_BRAND_MARK) ─────────────────────── */
28
- --email-mark-width: 32px; /* mirrors --logo-godx-size (2rem) */
29
- --email-mark-height: 32px;
29
+ /* ── Brand-mark lockup — the canonical GoDX capsule + wordmark (see EMAIL_BRAND_MARK) ────── */
30
+ /* The mark ARTWORK is the same 32×32 capsule + glyph `<Logo mark="godx" />` paints; only the
31
+ * RENDERED BOX differs. The canonical SCR-302 header sets it at 22px next to a 13px/700 "GoDX"
32
+ * wordmark, which is smaller than the web --logo-godx-size (2rem) — an email header carries the
33
+ * identity, not the navigation, so the lockup sits quieter (gh#250). */
34
+ --email-mark-width: 22px; /* canonical SCR-302 header lockup mark box */
35
+ --email-mark-height: 22px;
36
+ --email-mark-gap: 8px; /* mark ↔ wordmark — mirrors --logo-wordmark-gap (--space-2) */
37
+ --email-wordmark-font-size: 13px; /* canonical wordmark size (≈ --font-size-xs 12.5px) */
38
+ --email-wordmark-font-weight: 700; /* mirrors --logo-wordmark-font-weight */
30
39
 
31
40
  /* ── Typography — literal px so no client has to resolve the rem scale ──────────────────── */
41
+ /* The DXS canonical face is M PLUS 2 (see src/styles/fonts.css). Email clients honour NO
42
+ * @font-face, so the stack ships the face NAME first and degrades through the platform JP faces
43
+ * to a generic — a client with M PLUS 2 installed (or a webmail that already loaded it) renders
44
+ * the canonical face, everything else lands on Hiragino (macOS/iOS) → Yu Gothic (Windows) →
45
+ * Noto Sans JP → Meiryo → the system UI face → Arial → sans-serif. Family names are SINGLE-quoted
46
+ * on export (the generator normalises) because an inline `style="…"` attribute is double-quoted;
47
+ * only ASCII aliases are listed, since a non-ASCII family name does not survive every transfer
48
+ * encoding. */
32
49
  --email-font-family-sans:
33
- -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, sans-serif;
50
+ "M PLUS 2", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", YuGothic,
51
+ "Noto Sans JP", Meiryo, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, Arial,
52
+ sans-serif;
53
+ /* Tabular/reference strings — invoice ids, masked card numbers, ISO dates, amounts — are set in
54
+ * the mono face in the canonical card. Mirrors --font-family-mono. */
55
+ --email-font-family-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
34
56
  --email-body-font-size: 14px; /* mirrors --font-size-base (0.875rem) */
35
- --email-body-line-height: 1.7; /* mirrors --line-height-body */
57
+ /* 1.9, NOT the web --line-height-body (1.7) — the canonical email card runs its JP body copy
58
+ * looser than a screen, because a mail client gives the reader no density control. */
59
+ --email-body-line-height: 1.9;
36
60
  --email-body-font-weight: 400; /* mirrors --font-weight-normal */
37
- --email-heading-font-size: 20px; /* mirrors --heading-h1 (base × φ^¼³19.8px) */
38
- --email-heading-line-height: 1.25; /* mirrors --line-height-tight */
39
- --email-heading-font-weight: 700; /* mirrors --font-weight-bold */
61
+ --email-heading-font-size: 17px; /* canonical card title (≈ --heading-h2, base × φ^¼²17.6px) */
62
+ --email-heading-line-height: 1.7; /* the title shares the card's body leading, not a tight ramp */
63
+ --email-heading-font-weight: 500; /* mirrors --font-weight-medium — an email title is calm, not bold */
40
64
 
41
65
  /* ── Primary CTA — the one action button ────────────────────────────────────────────────── */
42
- --email-cta-height: 44px; /* mirrors --control-height-comfortable (2.75rem coarse-pointer target) */
43
- --email-cta-line-height: 44px; /* equal to the height: bulletproof vertical centring in Outlook */
44
- --email-cta-padding-x: 24px; /* mirrors --space-6 */
66
+ --email-cta-height: 36px; /* mirrors --control-height-lg (2.25rem) the canonical CTA box */
67
+ --email-cta-line-height: 36px; /* equal to the height: bulletproof vertical centring in Outlook */
68
+ --email-cta-padding-x: 16px; /* mirrors --space-4 */
45
69
  --email-cta-radius: 6px; /* mirrors the --radius base (0.375rem) */
46
70
  --email-cta-font-size: 14px; /* mirrors --font-size-base */
47
- --email-cta-font-weight: 700; /* mirrors --font-weight-bold */
71
+ --email-cta-font-weight: 500; /* mirrors --font-weight-medium */
48
72
 
49
73
  /* ── Legal footer ───────────────────────────────────────────────────────────────────────── */
50
- --email-footer-font-size: 12px; /* mirrors --font-size-xs (base ÷ φ^¼12.5px) */
51
- --email-footer-line-height: 1.5; /* mirrors --line-height-normal */
74
+ --email-footer-font-size: 11px; /* mirrors --font-size-2xs (base ÷ φ^¼²11.1px) */
75
+ --email-footer-line-height: 1.8; /* the legal band runs looser than the web --line-height-normal */
52
76
  --email-footer-link-gap: 12px; /* horizontal separation between footer links (--space-3) */
53
77
  --email-footer-padding-top: 20px; /* space above the legal band */
54
78
  --email-footer-border-width: 1px; /* the hairline above the legal band */
@@ -61,6 +85,9 @@
61
85
  --email-mobile-width: 100%; /* the card goes fluid below the breakpoint */
62
86
  --email-mobile-padding: 20px; /* reduced card inset — mirrors --space-5 */
63
87
  --email-mobile-page-padding: 12px; /* reduced viewport gutter — mirrors --space-3 */
64
- --email-mobile-heading-font-size: 18px; /* mirrors --heading-h2 (base × φ^¼² 17.6px) */
88
+ /* One step below the 17px desktop title. The canonical 390px reference raster is unusable (it is
89
+ * 435px wide and already clips the card — dxs-platform/platform#496), so this is the library's
90
+ * documented contract rather than a measured canonical value. */
91
+ --email-mobile-heading-font-size: 16px;
65
92
  --email-mobile-cta-width: 100%; /* the CTA goes full-bleed so the tap target spans the card */
66
93
  }
@@ -0,0 +1,36 @@
1
+ /* ErrorSurface — the 403 / 404 / 500 / 503 exception surface (gh#221, gh#251).
2
+ *
3
+ * Package-owned geometry: a service retunes the surface here (or in its own theme.css) instead of
4
+ * forking `.ui-error-surface` or adding a `className` to the component. Chrome defaults are QUIET
5
+ * (cardinal rule #44): the metadata block ships with no divider — a service opts IN.
6
+ */
7
+ :root {
8
+ /* Measure of the surface block. Caps the status code + body + metadata column so a long ja/vi
9
+ * headline wraps at a readable width in BOTH shells, including the application shell where
10
+ * PageContainer is much wider than the copy wants to be. */
11
+ --error-surface-max-width: 32rem;
12
+
13
+ /* Rhythm between the status code, the EmptyState body, the metadata list and the progress meter. */
14
+ --error-surface-gap: var(--space-3);
15
+
16
+ /* Block padding of the surface inside the shell it is placed in. Desktop (1440/1024) default; the
17
+ * 390 step steps it down so a phone loses no vertical space (see styles/shell-layout.css). */
18
+ --error-surface-padding-block: var(--space-10);
19
+ --error-surface-padding-block-compact: var(--space-6);
20
+
21
+ /* Brand slot (a Logo) above the status code, system mode only. */
22
+ --error-surface-brand-gap: var(--space-2);
23
+
24
+ /* Metadata description list: row rhythm and the label↔value gap inside one row. */
25
+ --error-surface-meta-gap: var(--space-1);
26
+ --error-surface-meta-row-gap: var(--space-2);
27
+
28
+ /* Chrome, default quiet (#44). A service opts in with
29
+ * `--error-surface-meta-border: 1px solid hsl(var(--border));`. */
30
+ --error-surface-meta-border: none;
31
+ --error-surface-meta-padding-block: 0;
32
+
33
+ /* Width of the maintenance progress meter — narrower than the measure, so it reads as metadata
34
+ * rather than as the primary content of the page. */
35
+ --error-surface-progress-max-width: 18rem;
36
+ }
@@ -29,6 +29,26 @@
29
29
  * (a brand's success-bg/-border are often more present than the faint 5%/30% default). */
30
30
  --alert-bg-alpha: 0.05;
31
31
  --alert-border-alpha: 0.3;
32
+ /* BANNER — the page-level Alert treatment (gh#255). Every constant a service would want to
33
+ * match to its page grid is a knob (rule #45): a banner that must keep the app's rounded card
34
+ * language sets --banner-radius, one that rules its top edge too sets --banner-border-width.
35
+ * The inline inset tracks the live page gutter, so a banner mounted above a PageContainer lines
36
+ * its text up with the page title instead of sitting at a second, unrelated margin. */
37
+ --banner-radius: 0;
38
+ --banner-border-width: 0;
39
+ --banner-border-block-end-width: 1px;
40
+ --banner-space-block: var(--space-3);
41
+ /* Inline inset tracks the page gutter so a banner's text lines up with the page title.
42
+ * `--space-page-active-x` steps down to the compact gutter on `.ui-page-container` only, and
43
+ * custom properties inherit — so a banner rendered INSIDE the container picks the compact value
44
+ * up for free, while the normal case (a banner mounted ABOVE the container, or in AppShell) would
45
+ * keep the desktop gutter and sit 8px out at 390px. The compact step below is what actually keeps
46
+ * the two aligned; retune it rather than hard-coding a mobile inset at the call site. */
47
+ --banner-space-inline: var(--space-page-active-x);
48
+ --banner-space-inline-compact: var(--space-page-compact-x);
49
+ /* Dismiss offset is measured from the banner's own (shorter) block inset, so the ✕ stays
50
+ * optically centred on a one-line strip instead of floating at the inline-alert offset. */
51
+ --banner-dismiss-space-offset: var(--space-2);
32
52
  /* Brand glow layer for the raised dialog/sheet panel — invisible no-op at rest (rule #44).
33
53
  * Paired AFTER --shadow-lg in the surface box-shadow so a service can wash the overlay with the
34
54
  * global glow, e.g. --dialog-content-glow: var(--shadow-glow), with no markup change. */
@@ -15,6 +15,26 @@
15
15
  --list-row-body-min-width: 12rem;
16
16
  /* Gap BETWEEN trailing actions — they also wrap among themselves at narrow widths (#224). */
17
17
  --list-row-trailing-gap: var(--space-2);
18
+ /* ── Compact inline-actions geometry (`density="compact"`, #246) ──────────────────────────
19
+ * The canonical invitation / history row: a 36px leading avatar, a shrinkable title +
20
+ * description body and one or two small trailing Buttons, all on ONE line inside the canonical
21
+ * 358px card (326px content after the row's own inline inset) at a 390px viewport. These knobs
22
+ * only LOWER the geometry — the #224 wrap contract (row + trailing cluster wrap, body clamped
23
+ * with min(…, 100%)) is untouched, so a cluster that genuinely cannot fit still wraps instead of
24
+ * widening the page root.
25
+ * Declared `initial` so the spacing defaults re-resolve at the CALL SITE — --space-2 is
26
+ * density-scaled and re-declared inside a `.ui-density-*` subtree, so a :root binding would
27
+ * freeze compact rows at the :root density (docs/TOKENS.md — the :root freeze rule).
28
+ * Defaults = var(--space-2) block padding · var(--list-row-padding-x) inline padding ·
29
+ * var(--space-2) gap. */
30
+ --list-row-compact-padding-y: initial;
31
+ /* Inline inset defaults to the default row axis so compact and default rows in the same Card keep
32
+ * one optical axis; a service retunes it to its own grid (#45). */
33
+ --list-row-compact-padding-x: initial;
34
+ --list-row-compact-gap: initial;
35
+ /* Compact body threshold — small enough that avatar + body + two compact Buttons fit the
36
+ * canonical column (36 + 8 + 96 + 8 + 146 = 294 ≤ 326), and still a readable measure. */
37
+ --list-row-compact-body-min-width: 6rem;
18
38
  /* Read (default) row surface — `initial`, documented default = transparent, i.e. the Card
19
39
  * surface shows through untouched (#44 — chrome defaults to the quietest state). */
20
40
  --list-row-read-background: initial;
@@ -12,28 +12,70 @@
12
12
  --logo-font-size-sm: var(--font-size-xs);
13
13
  --logo-font-size-md: var(--font-size-sm);
14
14
  --logo-font-size-lg: var(--font-size-base);
15
- /* Semantic identity fill is deliberately independent from --primary so a green brand mark never
16
- * recolours primary buttons or links. Services can retune the role once for every Logo.
15
+ /* Semantic identity fill reads the --brand IDENTITY role: independent of --primary (a re-themed
16
+ * action colour never recolours the mark) AND of --success (the 若竹 STATUS green stays on
17
+ * badges/progress/"saved" text — the mark used to borrow it and rendered ΔE76 ≈ 17.5 off the
18
+ * canonical emerald, gh#250). Services retune the role once for every Logo.
17
19
  * ROLE-MIRROR KNOBS — declared `initial` here with the role default at the CALL SITE
18
- * (logo-layout.css), so a scoped `.dark` / `[data-tenant]` override of --success actually
20
+ * (logo-layout.css), so a scoped `.dark` / `[data-tenant]` override of --brand actually
19
21
  * reaches the mark instead of freezing at the :root value (docs/TOKENS.md ·
20
22
  * "Role-mirror knobs MUST be `initial`"). Documented defaults:
21
- * --logo-success-background = hsl(var(--success))
22
- * --logo-success-foreground = hsl(var(--success-foreground))
23
- * --logo-godx-color = hsl(var(--success)) */
23
+ * --logo-success-background = hsl(var(--brand))
24
+ * --logo-success-foreground = hsl(var(--logo-identity-foreground))
25
+ * --logo-godx-color = hsl(var(--brand)) */
24
26
  --logo-success-background: initial;
25
27
  --logo-success-foreground: initial;
26
- --logo-godx-size: 2rem;
27
28
  --logo-godx-color: initial;
28
29
 
30
+ /* Identity-fill INK — the ink `mark="glyph"` sets its (caller-supplied) TEXT in when it sits on
31
+ * the --brand identity fill. This is deliberately NOT --brand-foreground.
32
+ *
33
+ * --brand-foreground is the identity artwork's KNOCKOUT colour, not an ink: it tracks
34
+ * --background in both themes (light 60 33% 99% = --background; dark 48 9% 9% = --background)
35
+ * because `<Logo mark="godx">` punches its inner bar as an evenodd HOLE and the email mark has to
36
+ * paint that hole as a solid fill to match. Negative space only has to clear WCAG 2.2 SC 1.4.11
37
+ * (3:1, non-text) — and at 3.67:1 on the emerald it does.
38
+ *
39
+ * The boxed glyph is a different thing: it renders real TEXT, so SC 1.4.3 applies at 4.5:1 (14px
40
+ * bold is NOT "large text" — that needs 18.66px bold / 24px), and the knockout white measured
41
+ * 3.67:1 → a genuine AA failure. This ink is 48 9% 9% (#191815), the same near-black spine the
42
+ * DARK theme already inked the glyph with, so it is theme-INVARIANT: dark renders byte-identically
43
+ * (6.89:1, unchanged) and light rises 3.67 → 4.74:1. A service that re-themes --brand to a dark
44
+ * fill overrides --logo-success-foreground (the public knob) to re-invert the ink.
45
+ *
46
+ * NOT a role-mirror knob: its default is a real value, not a role token, so there is no role to
47
+ * freeze at :root and the `initial` + call-site rule (docs/TOKENS.md) does not apply to it. */
48
+ --logo-identity-foreground: 48 9% 9%;
49
+
50
+ /* ── Identity-mark box (`<Logo mark="godx" />`) ──────────────────────────────────────────────
51
+ * The `size` prop drives the identity mark exactly like it drives the boxed glyph — a public
52
+ * prop that renders identically at every tier is a silent no-op, and the godx LOCKUP already
53
+ * scaled its wordmark per tier, so a fixed mark broke the mark↔wordmark proportion at
54
+ * `size="lg"` (gh#163 follow-up). The godx artwork is a horizontal capsule inside a square
55
+ * viewBox, so it carries less optical weight than the fully-filled glyph box: each tier sits
56
+ * +0.25rem above its --logo-size-* sibling. `md` is 2rem — the historical fixed value — so
57
+ * every existing default-size identity surface renders byte-identically.
58
+ *
59
+ * --logo-godx-size is the PIN: declared `initial` (guaranteed-invalid) here with the per-tier
60
+ * default at the CALL SITE (logo-layout.css), so it is inert by default and a service that
61
+ * sets it once freezes the mark at that box on EVERY tier — the same call-site pattern the
62
+ * role-mirror colour knobs use (docs/TOKENS.md). Retune a single tier via --logo-godx-size-*.
63
+ * Documented default: --logo-godx-size = unset (tiers apply). */
64
+ --logo-godx-size-xs: 1.5rem;
65
+ --logo-godx-size-sm: 1.75rem;
66
+ --logo-godx-size-md: 2rem;
67
+ --logo-godx-size-lg: 2.5rem;
68
+ --logo-godx-size: initial;
69
+
29
70
  /* ── Wordmark / lockup (`<Logo wordmark="GoDX" />`) ─────────────────────────────────────────
30
71
  * The readable product name set beside the mark. The package ships NO wordmark artwork: the
31
72
  * wordmark is typeset in the design-system display face, so a service retunes face, weight,
32
73
  * tracking, size and the mark↔wordmark gap here instead of writing page CSS. The colour is a
33
- * role-mirror knob whose default is the IDENTITY role (never --primary): the GoDX/`success`
34
- * lockup is brand-green out of the box, and every other lockup reads --foreground.
74
+ * role-mirror knob whose default is the IDENTITY role --brand (never --primary, never the
75
+ * --success status green): the GoDX/`success` lockup is canonical emerald out of the box, and
76
+ * every other lockup reads --foreground.
35
77
  * Documented defaults: --logo-wordmark-font-family = var(--font-family-display);
36
- * --logo-wordmark-color = hsl(var(--foreground)), or hsl(var(--success)) on the
78
+ * --logo-wordmark-color = hsl(var(--foreground)), or hsl(var(--brand)) on the
37
79
  * godx / tone="success" lockup. */
38
80
  --logo-wordmark-gap: var(--space-2);
39
81
  --logo-wordmark-font-size-xs: var(--font-size-xs);
@@ -10,6 +10,10 @@
10
10
  --filter-label-font-size: var(--font-size-xs);
11
11
  --filter-picker-width-sm: 11rem;
12
12
  --filter-picker-width-md: 14rem;
13
+ --steps-inline-gap: var(--space-2);
14
+ --steps-inline-item-gap: var(--space-1);
15
+ --steps-inline-font-size: var(--font-size-xs);
16
+ --steps-inline-separator-size: var(--control-icon-size-sm);
13
17
 
14
18
  /* AppSettingPicker `compact` (gh#217) — the small, content-hugging labelled trigger used in an
15
19
  * auth/legal footer, where the square icon-only default reads as a stray button and the full
@@ -24,6 +28,17 @@
24
28
  --tabs-list-max-inline-size: 100%;
25
29
  --tabs-list-overflow: auto;
26
30
 
31
+ /* Tabs `line` active indicator (gh#248) — the ONLY selected-state decoration the line variant
32
+ * paints. The surrounding active ring belongs to the default/card lists, so `:focus-visible`
33
+ * keeps its own distinct keyboard ring here (WCAG 2.4.7). `--tabs-indicator-background` is a
34
+ * role-mirror knob: `initial` so hsl(var(--primary)) re-resolves at the CALL SITE under a scoped
35
+ * [data-tenant]/.dark theme (a :root binding to a role var would freeze at :root).
36
+ * Default = hsl(var(--primary)) · 2px thick · flush with the trigger edge (offset 0 = quietest,
37
+ * rule #44); a service raises the offset to park the bar on a thicker strip hairline. */
38
+ --tabs-indicator-background: initial;
39
+ --tabs-indicator-size: 2px;
40
+ --tabs-indicator-offset: 0px;
41
+
27
42
  /* Menu item hover/highlight tint — `initial` so the --accent default re-resolves at the call site
28
43
  * under a scoped theme (a :root binding to a role var freezes at :root).
29
44
  * Defaults = hsl(var(--accent)) fill · hsl(var(--accent-foreground)) text. */
@@ -40,4 +55,30 @@
40
55
  * scrollbar never overlaps the controls. Rule #45 — a service theme retunes it to its grid
41
56
  * (0 on an overlay-scrollbar platform). */
42
57
  --filter-bar-scroll-padding-y: var(--space-1);
58
+
59
+ /* FilterBar typed model (#258) — the search / chip / result-count regions the bar now OWNS, so a
60
+ * list page never re-decides them. Every constant is a knob (rule #45): a service matches its own
61
+ * grid by retuning these once instead of per page.
62
+ *
63
+ * Search MEASURE — the whole point of the `search` slot. Below the 640px step the control is
64
+ * full-width (a bounded search box on a 390px screen wastes the row), so this binds only at and
65
+ * above it. 18rem = 288px: comfortable for a JA/VI query without crowding the filter groups. */
66
+ --filter-bar-search-width: 18rem;
67
+
68
+ /* Applied-filter chips. */
69
+ --filter-bar-chip-gap: var(--space-inline-xs);
70
+ --filter-bar-chip-row-gap: var(--space-inline-xs);
71
+ --filter-bar-chip-padding-inline: var(--space-2);
72
+ --filter-bar-chip-padding-block: var(--space-1);
73
+ --filter-bar-chip-radius: var(--radius-sm);
74
+ --filter-bar-chip-font-size: var(--font-size-xs);
75
+ /* Role-mirror knobs (docs/TOKENS.md) — `initial` at :root so --muted / --muted-foreground
76
+ * re-resolve at the CALL SITE under a scoped [data-tenant]/.dark theme. Binding a role var here
77
+ * would freeze the chip at the :root palette and a tenant override would never reach it. */
78
+ --filter-bar-chip-background: initial;
79
+ --filter-bar-chip-foreground: initial;
80
+
81
+ /* Result-count live region. */
82
+ --filter-bar-count-font-size: var(--font-size-xs);
83
+ --filter-bar-count-foreground: initial;
43
84
  }