@adia-ai/web-components 0.6.47 → 0.6.48
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 +42 -0
- package/components/badge/badge.d.ts +14 -0
- package/components/button/button.a2ui.json +1 -4
- package/components/button/button.d.ts +1 -1
- package/components/button/button.yaml +0 -3
- package/components/calendar-grid/calendar-grid.css +20 -11
- package/components/calendar-picker/calendar-picker.css +19 -10
- package/components/card/card.a2ui.json +2 -5
- package/components/card/card.css +3 -1
- package/components/card/card.d.ts +2 -2
- package/components/card/card.yaml +2 -5
- package/components/date-range-picker/date-range-picker.css +10 -1
- package/components/heatmap/heatmap.a2ui.json +2 -0
- package/components/heatmap/heatmap.d.ts +1 -1
- package/components/heatmap/heatmap.yaml +2 -0
- package/components/index.js +1 -0
- package/components/preview/preview.a2ui.json +93 -0
- package/components/preview/preview.class.js +178 -0
- package/components/preview/preview.css +176 -0
- package/components/preview/preview.d.ts +24 -0
- package/components/preview/preview.js +22 -0
- package/components/preview/preview.yaml +100 -0
- package/components/progress/progress.a2ui.json +2 -7
- package/components/progress/progress.d.ts +2 -2
- package/components/progress/progress.yaml +3 -8
- package/components/progress-row/progress-row.a2ui.json +1 -3
- package/components/progress-row/progress-row.d.ts +1 -1
- package/components/progress-row/progress-row.yaml +0 -2
- package/components/select/select.a2ui.json +2 -4
- package/components/select/select.yaml +2 -2
- package/components/tabs/tabs.a2ui.json +1 -4
- package/components/tabs/tabs.d.ts +2 -2
- package/components/tabs/tabs.yaml +2 -2
- package/core/anchor.js +5 -1
- package/dist/web-components.min.css +1 -1
- package/dist/web-components.min.js +75 -73
- package/index.css +6 -6
- package/package.json +1 -1
- package/styles/README.md +71 -36
- package/styles/api/layout.css +19 -0
- package/styles/api/sizing.css +225 -0
- package/styles/api/text.css +106 -0
- package/styles/colors/semantics/aliases.css +32 -0
- package/styles/colors/semantics/buckets.css +64 -0
- package/styles/colors/semantics/core.css +317 -0
- package/styles/colors/semantics/data-viz.css +129 -0
- package/styles/colors/semantics/features.css +114 -0
- package/styles/colors/semantics.css +10 -619
- package/styles/components.css +1 -0
- package/styles/foundation/elevation.css +29 -0
- package/styles/foundation/index.css +11 -0
- package/styles/foundation/motion.css +10 -0
- package/styles/foundation/radius.css +27 -0
- package/styles/foundation/size.css +33 -0
- package/styles/foundation/space.css +47 -0
- package/styles/index.css +14 -0
- package/styles/resets.css +17 -25
- package/styles/tokens.css +16 -384
- package/styles/type/elements.css +225 -0
- package/styles/type/roles.css +419 -0
- package/styles/type/scale.css +89 -0
- package/styles/typography.css +11 -809
package/index.css
CHANGED
|
@@ -3,9 +3,11 @@
|
|
|
3
3
|
*
|
|
4
4
|
* <link rel="stylesheet" href="@adia-ai/web-components/css" />
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
6
|
+
* The real barrel now lives at `./styles/index.css`; this file re-exports
|
|
7
|
+
* it (v0.6.48 foundation reorg, ADR-0035) so this published entry point
|
|
8
|
+
* and the `dist/web-components.min.css` bundle are unchanged. It pulls, in
|
|
9
|
+
* cascade order: design tokens (foundation + type + color, via the colors
|
|
10
|
+
* tree) → component styles → global resets.
|
|
9
11
|
*
|
|
10
12
|
* Composite-element CSS (chat-shell, editor-shell, admin-shell, etc.)
|
|
11
13
|
* lives in the sibling `@adia-ai/web-modules` package as of 0.0.29
|
|
@@ -22,6 +24,4 @@
|
|
|
22
24
|
* @adia-ai/web-components/styles/typography.css (standalone)
|
|
23
25
|
*/
|
|
24
26
|
|
|
25
|
-
@import "./styles/
|
|
26
|
-
@import "./styles/components.css";
|
|
27
|
-
@import "./styles/resets.css";
|
|
27
|
+
@import "./styles/index.css";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adia-ai/web-components",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.48",
|
|
4
4
|
"description": "AdiaUI web components \u2014 vanilla custom elements. A2UI runtime (renderer, registry, streams, wiring) lives in @adia-ai/a2ui-runtime.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"types": "./index.d.ts",
|
package/styles/README.md
CHANGED
|
@@ -8,17 +8,24 @@ Consumable design-token reference for component authors.
|
|
|
8
8
|
|
|
9
9
|
## Token layers
|
|
10
10
|
|
|
11
|
+
Files are organized by **dimension × layer** (v0.6.48 reorg, [ADR-0035](../../../.brain/adrs/0035-foundation-by-dimension-and-layer.md)).
|
|
12
|
+
A file answers two questions: which dimension (color · type · space · size · radius · motion · elevation) and which layer (primitive → semantic → role → applied/element → attribute-API → context → reset).
|
|
13
|
+
|
|
11
14
|
| Layer | Files | When to use |
|
|
12
15
|
|-------|-------|-------------|
|
|
13
|
-
| **L1 —
|
|
14
|
-
| **L2 —
|
|
15
|
-
| **L3 —
|
|
16
|
+
| **L1 — Color primitives** | `colors/parameters.css`, `colors/primitives-*.css` | Token system authors only. OKLCH base values, hue ramps, neutral scales. |
|
|
17
|
+
| **L2 — Color families** | `colors/semantics/core.css` | Component authors building *new* semantic aliases not yet exposed. Maps primitives to meaning (`--a-canvas-text`, `--a-danger-muted`). |
|
|
18
|
+
| **L3 — Color aliases** | `colors/semantics/core.css` + `colors/semantics/{features,buckets,data-viz}.css` | **All component CSS.** The stable public API: `--a-fg`, `--a-bg`, `--a-accent`, `--a-focus-ring`, `--a-data-0`. |
|
|
16
19
|
| **Dynamic / Theme** | `themes.css`, `colors/surfaces.css` | Theme authors. Per-theme hue shifts, density, radius overrides. |
|
|
17
|
-
| **
|
|
18
|
-
| **
|
|
19
|
-
| **
|
|
20
|
-
| **
|
|
21
|
-
| **
|
|
20
|
+
| **Type primitives + roles** | `type/scale.css` (L1/L2), `type/roles.css` (L3) | Component authors for font-size, weight, leading, tracking. |
|
|
21
|
+
| **Element defaults** | `type/elements.css` | Native HTML element typographic baseline (table, code, h1–h6, links…). |
|
|
22
|
+
| **Spacing / Size** | `foundation/space.css`, `foundation/size.css` | Component authors for padding, margin, gap, component/chrome heights. |
|
|
23
|
+
| **Radius** | `foundation/radius.css` | `--a-radius-sm/md/lg`, the `--a-radius-k` knob. |
|
|
24
|
+
| **Shadows** | `foundation/elevation.css` | Elevation authors. `--a-shadow-sm/md/lg`. |
|
|
25
|
+
| **Timing** | `foundation/motion.css` | Motion authors. `--a-duration`, `--a-easing`. |
|
|
26
|
+
| **Attribute API** | `api/sizing.css`, `api/text.css`, `api/layout.css` | The consumer-facing `[size]`/`[gap]`/`[weight]`/`[color]`/`[grow]`… selectors. |
|
|
27
|
+
|
|
28
|
+
> `tokens.css`, `typography.css`, `colors/semantics.css` remain as **compat barrels** at their published paths — they `@import` the files above. Link them exactly as before; the reorg is behind the barrel.
|
|
22
29
|
|
|
23
30
|
---
|
|
24
31
|
|
|
@@ -236,13 +243,14 @@ Set `--a-density` and `--a-radius-k` on `:root` for global effect, or on `[densi
|
|
|
236
243
|
|
|
237
244
|
## How to add a new token
|
|
238
245
|
|
|
239
|
-
1. **Need a new semantic color?** Add it in `colors/semantics.css`
|
|
246
|
+
1. **Need a new semantic color?** Add it in `colors/semantics/core.css` (canvas/accent/brand/status), mapping to an L2 family — or the matching `colors/semantics/{features,buckets,data-viz}.css` for focus/field/highlight/chrome/bucket/data tokens. Example:
|
|
240
247
|
```css
|
|
241
248
|
--a-bg-ghost: var(--a-canvas-0); /* new variant */
|
|
242
249
|
```
|
|
243
250
|
2. **Need a new primitive hue?** Extend `colors/parameters.css` hue ramp.
|
|
244
|
-
3. **Need a new spacing step?** Add to `
|
|
245
|
-
4. **
|
|
251
|
+
3. **Need a new spacing step?** Add to `foundation/space.css`. (radius → `foundation/radius.css`, motion → `foundation/motion.css`, shadow → `foundation/elevation.css`, type role → `type/roles.css`.)
|
|
252
|
+
4. **Need a new global attribute?** Add the `[attr]` selector to the matching `api/{sizing,text,layout}.css` — never scatter attribute selectors into primitive files.
|
|
253
|
+
5. **Never** add tokens directly in component CSS. Always add to the token system first, then consume.
|
|
246
254
|
|
|
247
255
|
---
|
|
248
256
|
|
|
@@ -250,23 +258,50 @@ Set `--a-density` and `--a-radius-k` on `:root` for global effect, or on `[densi
|
|
|
250
258
|
|
|
251
259
|
```
|
|
252
260
|
styles/
|
|
253
|
-
├──
|
|
254
|
-
|
|
255
|
-
├──
|
|
256
|
-
├──
|
|
257
|
-
│
|
|
258
|
-
|
|
259
|
-
│ ├──
|
|
260
|
-
│ ├──
|
|
261
|
-
│ ├──
|
|
262
|
-
│
|
|
263
|
-
├──
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
├──
|
|
267
|
-
├──
|
|
268
|
-
├──
|
|
269
|
-
└──
|
|
261
|
+
├── index.css # Real barrel: tokens → components → resets (re-exported by ../index.css)
|
|
262
|
+
│
|
|
263
|
+
├── tokens.css # COMPAT BARREL → colors + typography + foundation + api/sizing
|
|
264
|
+
├── typography.css # COMPAT BARREL → type/{scale,roles,elements} + api/{text,layout}
|
|
265
|
+
│
|
|
266
|
+
├── foundation/ # non-color, non-type PRIMITIVES (L1), one file per dimension
|
|
267
|
+
│ ├── index.css # barrel
|
|
268
|
+
│ ├── space.css # --a-space-* · inset · gap (+ the --a-density knob)
|
|
269
|
+
│ ├── size.css # --a-size-* · chrome heights · toggle · icon/caret
|
|
270
|
+
│ ├── radius.css # --a-radius-* (+ the --a-radius-k knob)
|
|
271
|
+
│ ├── motion.css # --a-duration-* · --a-easing-*
|
|
272
|
+
│ └── elevation.css # --a-shadow-*
|
|
273
|
+
│
|
|
274
|
+
├── type/ # the TYPE system (content of the typography.css barrel)
|
|
275
|
+
│ ├── scale.css # L1/L2: families, weights, leading, tracking
|
|
276
|
+
│ ├── roles.css # L3: 13 roles + h1–h6 defaults + [variant]
|
|
277
|
+
│ └── elements.css # native element typographic defaults (table, code, h1–h6, links…)
|
|
278
|
+
│
|
|
279
|
+
├── colors/ # the COLOR system (L1 → L3)
|
|
280
|
+
│ ├── index.css # barrel: parameters → primitives → surfaces → scrims → semantics
|
|
281
|
+
│ ├── parameters.css # L1: hue definitions, OKLCH ramp parameters
|
|
282
|
+
│ ├── primitives.css # L1 barrel → primitives-{shared,neutral,brand,accent,info,success,warning,danger}.css
|
|
283
|
+
│ ├── primitives-*.css # L1: per-family OKLCH ramps (8 files)
|
|
284
|
+
│ ├── surfaces.css # L2: canvas ramps (--a-canvas-0 … 6)
|
|
285
|
+
│ ├── scrims.css # L2: overlay transparency values
|
|
286
|
+
│ ├── semantics.css # COMPAT BARREL → semantics/*
|
|
287
|
+
│ └── semantics/
|
|
288
|
+
│ ├── core.css # L2+L3 canvas/accent/brand/status aliases (the consumable API)
|
|
289
|
+
│ ├── buckets.css # sequential data-vis ramps
|
|
290
|
+
│ ├── features.css # focus ring · field · highlight · chrome
|
|
291
|
+
│ ├── data-viz.css # --a-data-0..9 categorical palette + tuning knobs
|
|
292
|
+
│ └── aliases.css # scrim role aliases + legacy status-compat (loads LAST — order-bearing)
|
|
293
|
+
│
|
|
294
|
+
├── api/ # the global ATTRIBUTE API (consumer-facing [attr] selectors)
|
|
295
|
+
│ ├── sizing.css # [density] [radius] [size] [gap] [padding] [margin]
|
|
296
|
+
│ ├── text.css # [text-align] [weight] [color] [transform] [truncate]
|
|
297
|
+
│ └── layout.css # [hidden] [nomargin] [grow]
|
|
298
|
+
│
|
|
299
|
+
├── themes.css # CONTEXT: 8 named themes + light/dark scheme overrides ([data-theme])
|
|
300
|
+
├── prose.css # CONTEXT: opt-in article typography ([prose])
|
|
301
|
+
├── resets.css # global RESET (box-sizing, scrollbar, focus, normalize)
|
|
302
|
+
├── fonts.css # @font-face declarations + font-family primitives
|
|
303
|
+
├── components.css # per-component @import barrel
|
|
304
|
+
└── design-tokens-export.js # tooling: Figma Variables Pro exporter (reads the live --a-* surface)
|
|
270
305
|
```
|
|
271
306
|
|
|
272
307
|
---
|
|
@@ -275,12 +310,12 @@ styles/
|
|
|
275
310
|
|
|
276
311
|
| Layer | File(s) | ~Tokens |
|
|
277
312
|
|-------|---------|---------|
|
|
278
|
-
| L1 Primitives | `colors/parameters.css`, `colors/primitives
|
|
279
|
-
| L2 Families | `colors/semantics.css` (family section) | ~60 |
|
|
280
|
-
| L3 Semantic aliases | `colors/semantics.css`
|
|
281
|
-
| Typography | `
|
|
282
|
-
| Spacing | `
|
|
283
|
-
| Chrome | `
|
|
284
|
-
| Shadows | `
|
|
285
|
-
| Timing | `
|
|
313
|
+
| L1 Primitives | `colors/parameters.css`, `colors/primitives-*.css` | ~80 |
|
|
314
|
+
| L2 Families | `colors/semantics/core.css` (family section) | ~60 |
|
|
315
|
+
| L3 Semantic aliases | `colors/semantics/{core,features,buckets,data-viz}.css` | ~150 |
|
|
316
|
+
| Typography | `type/{scale,roles}.css` | ~80 |
|
|
317
|
+
| Spacing / Size | `foundation/{space,size}.css` | ~25 |
|
|
318
|
+
| Chrome | `foundation/size.css` | ~10 |
|
|
319
|
+
| Shadows | `foundation/elevation.css` | ~4 |
|
|
320
|
+
| Timing | `foundation/motion.css` | ~5 |
|
|
286
321
|
| **Total** | | **~410** |
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/* adia:attribute-api/layout — global presentational LAYOUT attributes.
|
|
2
|
+
[hidden] [nomargin] [grow] — NOT typography; relocated out of
|
|
3
|
+
typography.css where they had drifted (v0.6.48 foundation reorg, ADR-0035). */
|
|
4
|
+
|
|
5
|
+
/* Visibility */
|
|
6
|
+
[hidden] {
|
|
7
|
+
display: none !important;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
[nomargin] {
|
|
11
|
+
margin: 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/* Flex grow — fills remaining space in a flex parent.
|
|
15
|
+
Works on any element (col-ui, row-ui, input-ui, etc.) */
|
|
16
|
+
[grow] {
|
|
17
|
+
flex: 1;
|
|
18
|
+
min-width: 0;
|
|
19
|
+
}
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
/* adia:attribute-api/sizing — global spatial attribute API.
|
|
2
|
+
[density] [radius] [size] [gap] [padding] [margin] — the consumer-facing
|
|
3
|
+
selectors that turn spatial primitives into behavior. Moved verbatim out
|
|
4
|
+
of tokens.css (v0.6.48 foundation reorg, ADR-0035); imported by the
|
|
5
|
+
tokens.css barrel AFTER foundation/ so cascade position is unchanged. */
|
|
6
|
+
|
|
7
|
+
/* ═══════════════════════════════════════════════════════════════
|
|
8
|
+
DENSITY PRESETS — scoped via [density] attribute.
|
|
9
|
+
--a-density controls spacing, padding, gaps, AND component heights.
|
|
10
|
+
--a-radius-k is coupled for visual consistency.
|
|
11
|
+
|
|
12
|
+
Usage:
|
|
13
|
+
<div density="compact">...tight layout...</div>
|
|
14
|
+
<div density="spacious">...generous layout...</div>
|
|
15
|
+
═══════════════════════════════════════════════════════════════ */
|
|
16
|
+
|
|
17
|
+
[density="compact"] {
|
|
18
|
+
--a-density: 0.85;
|
|
19
|
+
--a-radius-k: 0.75;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
[density="spacious"] {
|
|
23
|
+
--a-density: 1.15;
|
|
24
|
+
--a-radius-k: 1.25;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* ── Radius presets — scoped via [radius] attribute ── */
|
|
28
|
+
|
|
29
|
+
[radius="sharp"] {
|
|
30
|
+
--a-radius-k: 0;
|
|
31
|
+
--a-radius-min: 0rem;
|
|
32
|
+
--a-radius-max: 0rem;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
[radius="rounded"] {
|
|
36
|
+
--a-radius-k: 1.5;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
[radius="round"] {
|
|
40
|
+
--a-radius-k: 2;
|
|
41
|
+
--a-radius-max: 3rem;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* ═══════════════════════════════════════════════════════════════
|
|
45
|
+
SIZE PRESETS — universal [size="sm|md|lg"] attribute.
|
|
46
|
+
|
|
47
|
+
Sets BOTH component tokens AND container tokens.
|
|
48
|
+
Each tier shifts the entire typescale to its sm/md/lg variant.
|
|
49
|
+
|
|
50
|
+
Component: --a-size, --a-ui-px, --a-ui-size, --a-icon-size
|
|
51
|
+
Container: --a-inset, --a-gap
|
|
52
|
+
Typography: all 13 role sizes shift to the tier's variant
|
|
53
|
+
|
|
54
|
+
Usage:
|
|
55
|
+
<button-ui size="sm"> — compact button
|
|
56
|
+
<card-ui size="lg">...</card-ui> — spacious card + larger type inside
|
|
57
|
+
<div size="sm">...</div> — everything inside scales down
|
|
58
|
+
═══════════════════════════════════════════════════════════════ */
|
|
59
|
+
/* ── sm — dense data UIs, sidebars, inspectors ── */
|
|
60
|
+
[size] {
|
|
61
|
+
font-size: var(--a-body-size);
|
|
62
|
+
}
|
|
63
|
+
[size="sm"] {
|
|
64
|
+
/* Component */
|
|
65
|
+
--a-size: calc(var(--a-density) * 1.5rem);
|
|
66
|
+
--a-toggle-size: calc(var(--a-size-sm) - var(--a-space-2)); /* 16px at d=1 */
|
|
67
|
+
--a-ui-px: var(--a-space-1-5);
|
|
68
|
+
--a-ui-size: var(--a-ui-sm);
|
|
69
|
+
--a-icon-size: 0.875rem;
|
|
70
|
+
--a-caret-size: 0.75rem;
|
|
71
|
+
/* Container */
|
|
72
|
+
--a-inset: var(--a-inset-sm);
|
|
73
|
+
--a-gap: var(--a-gap-sm);
|
|
74
|
+
--a-radius: var(--a-radius-sm);
|
|
75
|
+
/* Typography — all roles shift to -sm */
|
|
76
|
+
--a-display-size: var(--a-display-sm);
|
|
77
|
+
--a-title-size: var(--a-title-sm);
|
|
78
|
+
--a-heading-size: var(--a-heading-sm);
|
|
79
|
+
--a-section-size: var(--a-section-sm);
|
|
80
|
+
--a-subsection-size: var(--a-subsection-sm);
|
|
81
|
+
--a-body-size: var(--a-body-sm);
|
|
82
|
+
--a-deck-size: var(--a-deck-sm);
|
|
83
|
+
--a-caption-size: var(--a-caption-sm);
|
|
84
|
+
--a-kicker-size: var(--a-kicker-sm);
|
|
85
|
+
--a-label-size: var(--a-label-sm);
|
|
86
|
+
--a-metric-size: var(--a-metric-sm);
|
|
87
|
+
--a-code-size: var(--a-code-sm);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/* [size="md"] is the default — no overrides needed */
|
|
91
|
+
|
|
92
|
+
/* ── lg — pages, hero sections, marketing ── */
|
|
93
|
+
[size="lg"] {
|
|
94
|
+
/* Component */
|
|
95
|
+
--a-size: calc(var(--a-density) * 2.25rem);
|
|
96
|
+
--a-toggle-size: var(--a-size-sm); /* 24px at d=1 */
|
|
97
|
+
--a-ui-px: var(--a-space-3);
|
|
98
|
+
--a-ui-size: var(--a-ui-lg);
|
|
99
|
+
--a-icon-size: 1.25rem;
|
|
100
|
+
--a-caret-size: 1rem;
|
|
101
|
+
/* Container */
|
|
102
|
+
--a-inset: var(--a-inset-lg);
|
|
103
|
+
--a-gap: var(--a-gap-lg);
|
|
104
|
+
--a-radius: var(--a-radius-lg);
|
|
105
|
+
/* Typography — all roles shift to -lg */
|
|
106
|
+
--a-display-size: var(--a-display-lg);
|
|
107
|
+
--a-title-size: var(--a-title-lg);
|
|
108
|
+
--a-heading-size: var(--a-heading-lg);
|
|
109
|
+
--a-section-size: var(--a-section-lg);
|
|
110
|
+
--a-subsection-size: var(--a-subsection-lg);
|
|
111
|
+
--a-body-size: var(--a-body-lg);
|
|
112
|
+
--a-deck-size: var(--a-deck-lg);
|
|
113
|
+
--a-caption-size: var(--a-caption-lg);
|
|
114
|
+
--a-kicker-size: var(--a-kicker-lg);
|
|
115
|
+
--a-label-size: var(--a-label-lg);
|
|
116
|
+
--a-metric-size: var(--a-metric-lg);
|
|
117
|
+
--a-code-size: var(--a-code-lg);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
[gap="0"] {
|
|
121
|
+
--a-gap: 0;
|
|
122
|
+
}
|
|
123
|
+
[gap="1"] {
|
|
124
|
+
--a-gap: var(--a-space-1);
|
|
125
|
+
}
|
|
126
|
+
[gap="2"] {
|
|
127
|
+
--a-gap: var(--a-space-2);
|
|
128
|
+
}
|
|
129
|
+
[gap="3"] {
|
|
130
|
+
--a-gap: var(--a-space-3);
|
|
131
|
+
}
|
|
132
|
+
[gap="4"] {
|
|
133
|
+
--a-gap: var(--a-space-4);
|
|
134
|
+
}
|
|
135
|
+
[gap="5"] {
|
|
136
|
+
--a-gap: var(--a-space-5);
|
|
137
|
+
}
|
|
138
|
+
[gap="6"] {
|
|
139
|
+
--a-gap: var(--a-space-6);
|
|
140
|
+
}
|
|
141
|
+
[gap="7"] {
|
|
142
|
+
--a-gap: var(--a-space-7);
|
|
143
|
+
}
|
|
144
|
+
[gap="8"] {
|
|
145
|
+
--a-gap: var(--a-space-8);
|
|
146
|
+
}
|
|
147
|
+
[gap="9"] {
|
|
148
|
+
--a-gap: var(--a-space-9);
|
|
149
|
+
}
|
|
150
|
+
[gap="10"] {
|
|
151
|
+
--a-gap: var(--a-space-10);
|
|
152
|
+
}
|
|
153
|
+
[gap="12"] {
|
|
154
|
+
--a-gap: var(--a-space-12);
|
|
155
|
+
}
|
|
156
|
+
[gap="16"] {
|
|
157
|
+
--a-gap: var(--a-space-16);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
[gap="sm"] {
|
|
161
|
+
--a-gap: var(--a-space-4);
|
|
162
|
+
}
|
|
163
|
+
[gap="md"] {
|
|
164
|
+
--a-gap: var(--a-space-6);
|
|
165
|
+
}
|
|
166
|
+
[gap="lg"] {
|
|
167
|
+
--a-gap: var(--a-space-8);
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
/* ── Universal [padding] / [margin] — same scale as [gap]. Layout
|
|
171
|
+
primitives (row-ui, col-ui, grid-ui, stack-ui) opt in by reading
|
|
172
|
+
var(--a-padding, 0) and var(--a-margin, 0). Components with their
|
|
173
|
+
own padding/margin contracts (block-ui, card-ui, drawer-ui) keep
|
|
174
|
+
their scoped declarations and aren't affected.
|
|
175
|
+
|
|
176
|
+
Registered as non-inheriting via @property so a parent's
|
|
177
|
+
[padding="6"] doesn't bleed into nested layout primitives —
|
|
178
|
+
children see the initial-value (0) unless they declare their own
|
|
179
|
+
[padding] / [margin]. */
|
|
180
|
+
@property --a-padding {
|
|
181
|
+
syntax: "<length>";
|
|
182
|
+
inherits: false;
|
|
183
|
+
initial-value: 0;
|
|
184
|
+
}
|
|
185
|
+
@property --a-margin {
|
|
186
|
+
syntax: "<length>";
|
|
187
|
+
inherits: false;
|
|
188
|
+
initial-value: 0;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
[padding="0"] { --a-padding: 0; }
|
|
192
|
+
[padding="1"] { --a-padding: var(--a-space-1); }
|
|
193
|
+
[padding="2"] { --a-padding: var(--a-space-2); }
|
|
194
|
+
[padding="3"] { --a-padding: var(--a-space-3); }
|
|
195
|
+
[padding="4"] { --a-padding: var(--a-space-4); }
|
|
196
|
+
[padding="5"] { --a-padding: var(--a-space-5); }
|
|
197
|
+
[padding="6"] { --a-padding: var(--a-space-6); }
|
|
198
|
+
[padding="7"] { --a-padding: var(--a-space-7); }
|
|
199
|
+
[padding="8"] { --a-padding: var(--a-space-8); }
|
|
200
|
+
[padding="9"] { --a-padding: var(--a-space-9); }
|
|
201
|
+
[padding="10"] { --a-padding: var(--a-space-10); }
|
|
202
|
+
[padding="12"] { --a-padding: var(--a-space-12); }
|
|
203
|
+
[padding="16"] { --a-padding: var(--a-space-16); }
|
|
204
|
+
|
|
205
|
+
[padding="sm"] { --a-padding: var(--a-space-4); }
|
|
206
|
+
[padding="md"] { --a-padding: var(--a-space-6); }
|
|
207
|
+
[padding="lg"] { --a-padding: var(--a-space-8); }
|
|
208
|
+
|
|
209
|
+
[margin="0"] { --a-margin: 0; }
|
|
210
|
+
[margin="1"] { --a-margin: var(--a-space-1); }
|
|
211
|
+
[margin="2"] { --a-margin: var(--a-space-2); }
|
|
212
|
+
[margin="3"] { --a-margin: var(--a-space-3); }
|
|
213
|
+
[margin="4"] { --a-margin: var(--a-space-4); }
|
|
214
|
+
[margin="5"] { --a-margin: var(--a-space-5); }
|
|
215
|
+
[margin="6"] { --a-margin: var(--a-space-6); }
|
|
216
|
+
[margin="7"] { --a-margin: var(--a-space-7); }
|
|
217
|
+
[margin="8"] { --a-margin: var(--a-space-8); }
|
|
218
|
+
[margin="9"] { --a-margin: var(--a-space-9); }
|
|
219
|
+
[margin="10"] { --a-margin: var(--a-space-10); }
|
|
220
|
+
[margin="12"] { --a-margin: var(--a-space-12); }
|
|
221
|
+
[margin="16"] { --a-margin: var(--a-space-16); }
|
|
222
|
+
|
|
223
|
+
[margin="sm"] { --a-margin: var(--a-space-4); }
|
|
224
|
+
[margin="md"] { --a-margin: var(--a-space-6); }
|
|
225
|
+
[margin="lg"] { --a-margin: var(--a-space-8); }
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/* adia:attribute-api/text — global presentational TEXT attributes.
|
|
2
|
+
[text-align] [weight] [color] [transform] [truncate]. Moved verbatim out
|
|
3
|
+
of typography.css (v0.6.48 foundation reorg, ADR-0035); imported by the
|
|
4
|
+
typography.css barrel at its original cascade position. */
|
|
5
|
+
|
|
6
|
+
/* ═══════════════════════════════════════════════════════════
|
|
7
|
+
GLOBAL PRESENTATIONAL ATTRIBUTES
|
|
8
|
+
Work on any element. Attribute-driven, not class-based.
|
|
9
|
+
|
|
10
|
+
NOTE: These have lower specificity than @scope component CSS.
|
|
11
|
+
Using [weight="bold"] on a component like <text-ui> will be
|
|
12
|
+
overridden by the component's own font-weight rule. Use these
|
|
13
|
+
on plain elements (<span>, <p>, <div>) or choose the right
|
|
14
|
+
[variant] instead.
|
|
15
|
+
═══════════════════════════════════════════════════════════ */
|
|
16
|
+
|
|
17
|
+
/* Text alignment */
|
|
18
|
+
[text-align="left"] {
|
|
19
|
+
text-align: left;
|
|
20
|
+
}
|
|
21
|
+
[text-align="center"] {
|
|
22
|
+
text-align: center;
|
|
23
|
+
}
|
|
24
|
+
[text-align="right"] {
|
|
25
|
+
text-align: right;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/* Font weight — six steps matching --a-weight-* tokens */
|
|
29
|
+
[weight="thin"] {
|
|
30
|
+
--a-weight: var(--a-weight-thin);
|
|
31
|
+
font-weight: var(--a-weight);
|
|
32
|
+
} /* 100 — hairline, display only */
|
|
33
|
+
[weight="light"] {
|
|
34
|
+
--a-weight: var(--a-weight-light);
|
|
35
|
+
font-weight: var(--a-weight);
|
|
36
|
+
} /* 300 — light UI emphasis */
|
|
37
|
+
[weight="normal"] {
|
|
38
|
+
--a-weight: var(--a-weight-normal);
|
|
39
|
+
font-weight: var(--a-weight);
|
|
40
|
+
} /* 400 */
|
|
41
|
+
[weight="medium"] {
|
|
42
|
+
--a-weight: var(--a-weight-medium);
|
|
43
|
+
font-weight: var(--a-weight);
|
|
44
|
+
} /* 500 */
|
|
45
|
+
[weight="semibold"] {
|
|
46
|
+
--a-weight: var(--a-weight-semibold);
|
|
47
|
+
font-weight: var(--a-weight);
|
|
48
|
+
} /* 600 */
|
|
49
|
+
[weight="bold"] {
|
|
50
|
+
--a-weight: var(--a-weight-bold);
|
|
51
|
+
font-weight: var(--a-weight);
|
|
52
|
+
} /* 700 */
|
|
53
|
+
|
|
54
|
+
/* Text color */
|
|
55
|
+
[color] {
|
|
56
|
+
color: var(--a-fg);
|
|
57
|
+
}
|
|
58
|
+
[color="text"] {
|
|
59
|
+
--a-fg: var(--a-canvas-text);
|
|
60
|
+
}
|
|
61
|
+
[color="text-strong"] {
|
|
62
|
+
--a-fg: var(--a-fg-strong);
|
|
63
|
+
}
|
|
64
|
+
[color="subtle"] {
|
|
65
|
+
--a-fg: var(--a-fg-subtle);
|
|
66
|
+
}
|
|
67
|
+
[color="muted"] {
|
|
68
|
+
--a-fg: var(--a-fg-muted);
|
|
69
|
+
}
|
|
70
|
+
[color="accent"] {
|
|
71
|
+
--a-fg: var(--a-accent);
|
|
72
|
+
}
|
|
73
|
+
[color="success"] {
|
|
74
|
+
--a-fg: var(--a-success);
|
|
75
|
+
}
|
|
76
|
+
[color="warning"] {
|
|
77
|
+
--a-fg: var(--a-warning);
|
|
78
|
+
}
|
|
79
|
+
[color="danger"] {
|
|
80
|
+
--a-fg: var(--a-danger);
|
|
81
|
+
}
|
|
82
|
+
[color="info"] {
|
|
83
|
+
--a-fg: var(--a-info);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/* Text transform */
|
|
87
|
+
[transform="uppercase"] {
|
|
88
|
+
text-transform: uppercase;
|
|
89
|
+
letter-spacing: 0.04em;
|
|
90
|
+
}
|
|
91
|
+
[transform="lowercase"] {
|
|
92
|
+
text-transform: lowercase;
|
|
93
|
+
}
|
|
94
|
+
[transform="capitalize"] {
|
|
95
|
+
text-transform: capitalize;
|
|
96
|
+
}
|
|
97
|
+
[transform="none"] {
|
|
98
|
+
text-transform: none;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/* Truncation */
|
|
102
|
+
[truncate] {
|
|
103
|
+
overflow: hidden;
|
|
104
|
+
text-overflow: ellipsis;
|
|
105
|
+
white-space: nowrap;
|
|
106
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/* adia:semantic/color — scrim role aliases + legacy status compat.
|
|
2
|
+
--a-scrim-* role names, and the STATUS COMPAT block that overrides
|
|
3
|
+
--a-danger / --a-success to -strong. Imported LAST by the semantics.css
|
|
4
|
+
barrel — this ordering is load-bearing: these re-declarations must win
|
|
5
|
+
over the core.css defaults (v0.6.48 reorg, ADR-0035). */
|
|
6
|
+
|
|
7
|
+
:root, theme-ui, [data-theme] {
|
|
8
|
+
/* ══════════════════════════════════════════════════════════════
|
|
9
|
+
SCRIMS — Role aliases. Map onto the 7-step adaptive scrim-0..6
|
|
10
|
+
scale in scrims.css. Per-family semantic tiers (weak / default /
|
|
11
|
+
strong / peak) live in surfaces.css.
|
|
12
|
+
══════════════════════════════════════════════════════════════ */
|
|
13
|
+
|
|
14
|
+
--a-scrim-weak: var(--a-neutral-1-shade-scrim); /* 20% — hover wash */
|
|
15
|
+
--a-scrim-toast: var(--a-neutral-2-shade-scrim); /* 30% — toast veil */
|
|
16
|
+
--a-scrim-default: var(--a-neutral-3-shade-scrim); /* 40% — generic overlay */
|
|
17
|
+
--a-scrim-dialog: var(--a-neutral-4-shade-scrim); /* 50% — modal backdrop */
|
|
18
|
+
--a-scrim-strong: var(--a-neutral-6-shade-scrim); /* 70% — heaviest veil */
|
|
19
|
+
|
|
20
|
+
/* ══════════════════════════════════════════════════════════════
|
|
21
|
+
STATUS COMPAT — Legacy status shortcuts used by existing
|
|
22
|
+
components (button, chart, pipeline-status, timeline). Override
|
|
23
|
+
the L2 "default" shade to match -strong so the pre-reorg visual
|
|
24
|
+
behavior is preserved. Components should migrate to the L3
|
|
25
|
+
matrix (--a-danger-bg, --a-success-fg, etc) over time.
|
|
26
|
+
══════════════════════════════════════════════════════════════ */
|
|
27
|
+
|
|
28
|
+
--a-danger: var(--a-danger-strong);
|
|
29
|
+
--a-danger-fg: var(--a-danger-text-strong);
|
|
30
|
+
--a-success: var(--a-success-strong);
|
|
31
|
+
--a-success-fg: var(--a-success-text-strong);
|
|
32
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/* adia:semantic/color — sequential data-vis buckets (5-step per family).
|
|
2
|
+
Distinct from --a-data-0..9 (categorical): buckets are 5 ordered steps
|
|
3
|
+
within ONE family for heatmap/choropleth/treemap intensity.
|
|
4
|
+
Split out of semantics.css (v0.6.48 reorg, ADR-0035). */
|
|
5
|
+
|
|
6
|
+
:root, theme-ui, [data-theme] {
|
|
7
|
+
/* ══════════════════════════════════════════════════════════════
|
|
8
|
+
BUCKETS — sequential 5-step ramp per family for data-vis consumers
|
|
9
|
+
|
|
10
|
+
Distinct from `--a-data-0..9` (categorical, distinct hues) — buckets
|
|
11
|
+
are 5 steps within ONE family, ordered low → high. Used by sequential
|
|
12
|
+
data-vis surfaces (heatmap-ui, choropleth, treemap intensity).
|
|
13
|
+
|
|
14
|
+
Anchor: bucket-2 = `--a-{family}-strong` (semantic step-50). Steps 0
|
|
15
|
+
and 1 sit lighter (toward muted); steps 3 and 4 sit deeper (toward
|
|
16
|
+
active). Light/dark scheme polarity is honored via `light-dark()` —
|
|
17
|
+
in light mode the lighter primitives are step-tints, in dark mode
|
|
18
|
+
the lighter primitives are step-shades, so "low intensity" reads
|
|
19
|
+
as low contrast against canvas-0 in either scheme.
|
|
20
|
+
|
|
21
|
+
Coordinate with chart palette: `--a-data-N` are categorical (10 hue
|
|
22
|
+
slots fanning out from accent-hue); buckets stay within one family
|
|
23
|
+
so a heatmap colored `[color="success"]` doesn't drift through the
|
|
24
|
+
accent → success → warning hue arc. Five steps were chosen so the
|
|
25
|
+
ramp fits within WCAG AA against `--a-canvas-0` at the high end and
|
|
26
|
+
remains visually distinguishable at the low end.
|
|
27
|
+
══════════════════════════════════════════════════════════════ */
|
|
28
|
+
|
|
29
|
+
/* Accent buckets */
|
|
30
|
+
--a-accent-bucket-0: light-dark(var(--a-accent-15-tint), var(--a-accent-85-shade));
|
|
31
|
+
--a-accent-bucket-1: light-dark(var(--a-accent-30-tint), var(--a-accent-70-shade));
|
|
32
|
+
--a-accent-bucket-2: var(--a-accent-strong);
|
|
33
|
+
--a-accent-bucket-3: light-dark(var(--a-accent-65-tint), var(--a-accent-35-shade));
|
|
34
|
+
--a-accent-bucket-4: light-dark(var(--a-accent-80-tint), var(--a-accent-20-shade));
|
|
35
|
+
|
|
36
|
+
/* Success buckets */
|
|
37
|
+
--a-success-bucket-0: light-dark(var(--a-success-15-tint), var(--a-success-85-shade));
|
|
38
|
+
--a-success-bucket-1: light-dark(var(--a-success-30-tint), var(--a-success-70-shade));
|
|
39
|
+
--a-success-bucket-2: var(--a-success-strong);
|
|
40
|
+
--a-success-bucket-3: light-dark(var(--a-success-65-tint), var(--a-success-35-shade));
|
|
41
|
+
--a-success-bucket-4: light-dark(var(--a-success-80-tint), var(--a-success-20-shade));
|
|
42
|
+
|
|
43
|
+
/* Warning buckets */
|
|
44
|
+
--a-warning-bucket-0: light-dark(var(--a-warning-15-tint), var(--a-warning-85-shade));
|
|
45
|
+
--a-warning-bucket-1: light-dark(var(--a-warning-30-tint), var(--a-warning-70-shade));
|
|
46
|
+
--a-warning-bucket-2: var(--a-warning-strong);
|
|
47
|
+
--a-warning-bucket-3: light-dark(var(--a-warning-65-tint), var(--a-warning-35-shade));
|
|
48
|
+
--a-warning-bucket-4: light-dark(var(--a-warning-80-tint), var(--a-warning-20-shade));
|
|
49
|
+
|
|
50
|
+
/* Danger buckets */
|
|
51
|
+
--a-danger-bucket-0: light-dark(var(--a-danger-15-tint), var(--a-danger-85-shade));
|
|
52
|
+
--a-danger-bucket-1: light-dark(var(--a-danger-30-tint), var(--a-danger-70-shade));
|
|
53
|
+
--a-danger-bucket-2: var(--a-danger-strong);
|
|
54
|
+
--a-danger-bucket-3: light-dark(var(--a-danger-65-tint), var(--a-danger-35-shade));
|
|
55
|
+
--a-danger-bucket-4: light-dark(var(--a-danger-80-tint), var(--a-danger-20-shade));
|
|
56
|
+
|
|
57
|
+
/* Info buckets */
|
|
58
|
+
--a-info-bucket-0: light-dark(var(--a-info-15-tint), var(--a-info-85-shade));
|
|
59
|
+
--a-info-bucket-1: light-dark(var(--a-info-30-tint), var(--a-info-70-shade));
|
|
60
|
+
--a-info-bucket-2: var(--a-info-strong);
|
|
61
|
+
--a-info-bucket-3: light-dark(var(--a-info-65-tint), var(--a-info-35-shade));
|
|
62
|
+
--a-info-bucket-4: light-dark(var(--a-info-80-tint), var(--a-info-20-shade));
|
|
63
|
+
|
|
64
|
+
}
|