@evinvest/uikit 0.17.1 → 0.18.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/README.md +12 -6
- package/dist/index.d.ts +1 -1
- package/dist/index.js +12 -12
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/styles/tokens.css +23 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@evinvest/uikit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0",
|
|
4
4
|
"description": "Dep-light React UI kit: shadcn-semantics components with zero @radix-ui / cva, mirroring the ev_lib::uikit Rust feature. Ships the shared design tokens.",
|
|
5
5
|
"license": "BlueOak-1.0.0",
|
|
6
6
|
"publishConfig": {
|
package/styles/tokens.css
CHANGED
|
@@ -15,6 +15,8 @@
|
|
|
15
15
|
* ROLES {role} and on-{role} for the ones that get filled:
|
|
16
16
|
* brand · primary · secondary · positive ·
|
|
17
17
|
* accent-trace · accent-debug · accent-info · accent-warn · accent-error
|
|
18
|
+
* primary-ink — the primary role as ink on a surface, where the
|
|
19
|
+
* fill and the readable value are different colours
|
|
18
20
|
* SCALARS radius · control-* · display-scale · page-* · shadows · fonts
|
|
19
21
|
* CHARTS chart-1 … chart-5
|
|
20
22
|
* MARK brand-mark · brand-aspect — supplied, never defined here
|
|
@@ -33,7 +35,9 @@
|
|
|
33
35
|
* value, so the steps below are deliberate and measured; keep them apart if you
|
|
34
36
|
* retune. background #070d18 → secondary #0d1526 (1.07:1) → card #16233c (1.24:1
|
|
35
37
|
* vs background) → popover #1d2c49 (1.13:1 vs card) → muted #26375c. Elevation
|
|
36
|
-
* rides the same ladder via --shadow-card / -elevated / -overlay.
|
|
38
|
+
* rides the same ladder via --shadow-card / -elevated / -overlay. Card is also
|
|
39
|
+
* pinned from above by a second floor: --primary has to clear 3:1 against it
|
|
40
|
+
* (3.39:1 today), so lifting card one step breaks the tokens test.
|
|
37
41
|
*/
|
|
38
42
|
|
|
39
43
|
/*
|
|
@@ -390,6 +394,7 @@
|
|
|
390
394
|
--color-brand: var(--brand);
|
|
391
395
|
--color-primary: var(--primary);
|
|
392
396
|
--color-on-primary: var(--on-primary);
|
|
397
|
+
--color-primary-ink: var(--primary-ink);
|
|
393
398
|
--color-secondary: var(--secondary);
|
|
394
399
|
--color-on-secondary: var(--on-secondary);
|
|
395
400
|
--color-positive: var(--positive);
|
|
@@ -432,15 +437,28 @@
|
|
|
432
437
|
/* ── lines ───────────────────────────────────────────────────── */
|
|
433
438
|
--border: color-mix(in srgb, var(--ink) 14%, transparent);
|
|
434
439
|
--input: color-mix(in srgb, var(--ink) 20%, transparent);
|
|
435
|
-
--ring:
|
|
440
|
+
--ring: var(--primary-ink);
|
|
436
441
|
|
|
437
442
|
/* ── roles ───────────────────────────────────────────────────── */
|
|
438
443
|
--brand: #001e4e;
|
|
439
444
|
/* teal, not the brand navy: navy filled a Button/Switch at ~1.1:1 against
|
|
440
445
|
* these surfaces, i.e. an invisible control, and consumers hardcoded teal to
|
|
441
|
-
* get around it. The brand navy still lives in --brand.
|
|
442
|
-
|
|
443
|
-
|
|
446
|
+
* get around it. The brand navy still lives in --brand.
|
|
447
|
+
*
|
|
448
|
+
* A fill and an ink are different jobs, so the primary role carries two
|
|
449
|
+
* values (docs/spec/accents.md). --primary-ink is the teal that reads on the
|
|
450
|
+
* surfaces: 5.85:1 on background, 4.72:1 on card. --primary is the same hue
|
|
451
|
+
* and chroma one step down in lightness — OKLCH L 0.550 C 0.094 H 183°
|
|
452
|
+
* against the ink's L 0.630 C 0.101 H 183° — so the CTA carries white:
|
|
453
|
+
* --on-primary reads on it at 4.63:1, and the fill clears the 3:1 non-text
|
|
454
|
+
* floor against background (4.20:1), secondary (3.94:1), card (3.39:1) and
|
|
455
|
+
* popover (3.01:1), so a checked Switch on a Card still reads as one. Muted
|
|
456
|
+
* is the one surface under the floor (2.54:1); the controls that fill there
|
|
457
|
+
* carry an on-primary mark, see the spec. Darkening the single value instead
|
|
458
|
+
* would have dropped every teal label below AA. */
|
|
459
|
+
--primary: #128377;
|
|
460
|
+
--on-primary: #ffffff;
|
|
461
|
+
--primary-ink: #2a9d8f;
|
|
444
462
|
--secondary: #0d1526;
|
|
445
463
|
--on-secondary: var(--ink);
|
|
446
464
|
/* valence, not significance: a success reads as good while staying quiet */
|