@hanzo/design 0.5.13 → 0.5.15
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/dist/tokens.gen.d.ts +14 -6
- package/dist/tokens.gen.d.ts.map +1 -1
- package/dist/tokens.gen.js +14 -6
- package/package.json +11 -9
- package/src/tokens.gen.ts +14 -6
- package/styles.css +32 -3
- package/tailwind.css +32 -3
- package/tokens/colors.css +12 -3
- package/tokens/spacing.css +20 -0
package/dist/tokens.gen.d.ts
CHANGED
|
@@ -35,11 +35,11 @@ export declare const colors: {
|
|
|
35
35
|
readonly 'white-80': "rgb(255 255 255 / .80)";
|
|
36
36
|
readonly 'white-92': "rgb(255 255 255 / .92)";
|
|
37
37
|
readonly background: "#0a0a0a";
|
|
38
|
-
readonly foreground: "#
|
|
38
|
+
readonly foreground: "#e5e5e5";
|
|
39
39
|
readonly card: "#0f0f0f";
|
|
40
|
-
readonly 'card-foreground': "#
|
|
40
|
+
readonly 'card-foreground': "#e5e5e5";
|
|
41
41
|
readonly popover: "#0f0f0f";
|
|
42
|
-
readonly 'popover-foreground': "#
|
|
42
|
+
readonly 'popover-foreground': "#e5e5e5";
|
|
43
43
|
readonly primary: "#fafafa";
|
|
44
44
|
readonly 'primary-hover': "#e5e5e5";
|
|
45
45
|
readonly 'primary-foreground': "#0a0a0a";
|
|
@@ -203,6 +203,10 @@ export declare const spacing: {
|
|
|
203
203
|
readonly 'hero-y-lg': "4.5rem";
|
|
204
204
|
readonly 'header-height': "3.5rem";
|
|
205
205
|
readonly 'tap-target': "44px";
|
|
206
|
+
readonly 'control-height-sm': "32px";
|
|
207
|
+
readonly 'control-height': "36px";
|
|
208
|
+
readonly 'control-height-lg': "40px";
|
|
209
|
+
readonly 'control-height-xl': "52px";
|
|
206
210
|
readonly 'safe-top': "env(safe-area-inset-top,0px)";
|
|
207
211
|
readonly 'safe-right': "env(safe-area-inset-right,0px)";
|
|
208
212
|
readonly 'safe-bottom': "env(safe-area-inset-bottom,0px)";
|
|
@@ -338,11 +342,11 @@ export declare const cssVars: {
|
|
|
338
342
|
readonly '--white-80': "rgb(255 255 255 / .80)";
|
|
339
343
|
readonly '--white-92': "rgb(255 255 255 / .92)";
|
|
340
344
|
readonly '--background': "#0a0a0a";
|
|
341
|
-
readonly '--foreground': "#
|
|
345
|
+
readonly '--foreground': "#e5e5e5";
|
|
342
346
|
readonly '--card': "#0f0f0f";
|
|
343
|
-
readonly '--card-foreground': "#
|
|
347
|
+
readonly '--card-foreground': "#e5e5e5";
|
|
344
348
|
readonly '--popover': "#0f0f0f";
|
|
345
|
-
readonly '--popover-foreground': "#
|
|
349
|
+
readonly '--popover-foreground': "#e5e5e5";
|
|
346
350
|
readonly '--primary': "#fafafa";
|
|
347
351
|
readonly '--primary-hover': "#e5e5e5";
|
|
348
352
|
readonly '--primary-foreground': "#0a0a0a";
|
|
@@ -500,6 +504,10 @@ export declare const cssVars: {
|
|
|
500
504
|
readonly '--hero-y-lg': "4.5rem";
|
|
501
505
|
readonly '--header-height': "3.5rem";
|
|
502
506
|
readonly '--tap-target': "44px";
|
|
507
|
+
readonly '--control-height-sm': "32px";
|
|
508
|
+
readonly '--control-height': "36px";
|
|
509
|
+
readonly '--control-height-lg': "40px";
|
|
510
|
+
readonly '--control-height-xl': "52px";
|
|
503
511
|
readonly '--safe-top': "env(safe-area-inset-top,0px)";
|
|
504
512
|
readonly '--safe-right': "env(safe-area-inset-right,0px)";
|
|
505
513
|
readonly '--safe-bottom': "env(safe-area-inset-bottom,0px)";
|
package/dist/tokens.gen.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokens.gen.d.ts","sourceRoot":"","sources":["../src/tokens.gen.ts"],"names":[],"mappings":"AAIA,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8FT,CAAA;AAEV,0EAA0E;AAC1E,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmEb,CAAA;AAEV,oEAAoE;AACpE,eAAO,MAAM,OAAO
|
|
1
|
+
{"version":3,"file":"tokens.gen.d.ts","sourceRoot":"","sources":["../src/tokens.gen.ts"],"names":[],"mappings":"AAIA,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8FT,CAAA;AAEV,0EAA0E;AAC1E,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmEb,CAAA;AAEV,oEAAoE;AACpE,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+CV,CAAA;AAEV,8DAA8D;AAC9D,eAAO,MAAM,IAAI;;;;;;;;;;;;CAYP,CAAA;AAEV,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;CAST,CAAA;AAEV,wEAAwE;AACxE,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2BZ,CAAA;AAEV,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;;;;;CAaT,CAAA;AAEV,6DAA6D;AAC7D,eAAO,MAAM,MAAM;;;;;;;;;;;;CAYT,CAAA;AAEV,gEAAgE;AAChE,eAAO,MAAM,KAAK;;;;;;CAMR,CAAA;AAEV,8DAA8D;AAC9D,eAAO,MAAM,IAAI,IAEP,CAAA;AAEV,sFAAsF;AACtF,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuRV,CAAA;AAEV,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,OAAO,CAAA"}
|
package/dist/tokens.gen.js
CHANGED
|
@@ -38,11 +38,11 @@ export const colors = {
|
|
|
38
38
|
'white-80': 'rgb(255 255 255 / .80)',
|
|
39
39
|
'white-92': 'rgb(255 255 255 / .92)',
|
|
40
40
|
'background': '#0a0a0a',
|
|
41
|
-
'foreground': '#
|
|
41
|
+
'foreground': '#e5e5e5',
|
|
42
42
|
'card': '#0f0f0f',
|
|
43
|
-
'card-foreground': '#
|
|
43
|
+
'card-foreground': '#e5e5e5',
|
|
44
44
|
'popover': '#0f0f0f',
|
|
45
|
-
'popover-foreground': '#
|
|
45
|
+
'popover-foreground': '#e5e5e5',
|
|
46
46
|
'primary': '#fafafa',
|
|
47
47
|
'primary-hover': '#e5e5e5',
|
|
48
48
|
'primary-foreground': '#0a0a0a',
|
|
@@ -206,6 +206,10 @@ export const spacing = {
|
|
|
206
206
|
'hero-y-lg': '4.5rem',
|
|
207
207
|
'header-height': '3.5rem',
|
|
208
208
|
'tap-target': '44px',
|
|
209
|
+
'control-height-sm': '32px',
|
|
210
|
+
'control-height': '36px',
|
|
211
|
+
'control-height-lg': '40px',
|
|
212
|
+
'control-height-xl': '52px',
|
|
209
213
|
'safe-top': 'env(safe-area-inset-top,0px)',
|
|
210
214
|
'safe-right': 'env(safe-area-inset-right,0px)',
|
|
211
215
|
'safe-bottom': 'env(safe-area-inset-bottom,0px)',
|
|
@@ -341,11 +345,11 @@ export const cssVars = {
|
|
|
341
345
|
'--white-80': 'rgb(255 255 255 / .80)',
|
|
342
346
|
'--white-92': 'rgb(255 255 255 / .92)',
|
|
343
347
|
'--background': '#0a0a0a',
|
|
344
|
-
'--foreground': '#
|
|
348
|
+
'--foreground': '#e5e5e5',
|
|
345
349
|
'--card': '#0f0f0f',
|
|
346
|
-
'--card-foreground': '#
|
|
350
|
+
'--card-foreground': '#e5e5e5',
|
|
347
351
|
'--popover': '#0f0f0f',
|
|
348
|
-
'--popover-foreground': '#
|
|
352
|
+
'--popover-foreground': '#e5e5e5',
|
|
349
353
|
'--primary': '#fafafa',
|
|
350
354
|
'--primary-hover': '#e5e5e5',
|
|
351
355
|
'--primary-foreground': '#0a0a0a',
|
|
@@ -503,6 +507,10 @@ export const cssVars = {
|
|
|
503
507
|
'--hero-y-lg': '4.5rem',
|
|
504
508
|
'--header-height': '3.5rem',
|
|
505
509
|
'--tap-target': '44px',
|
|
510
|
+
'--control-height-sm': '32px',
|
|
511
|
+
'--control-height': '36px',
|
|
512
|
+
'--control-height-lg': '40px',
|
|
513
|
+
'--control-height-xl': '52px',
|
|
506
514
|
'--safe-top': 'env(safe-area-inset-top,0px)',
|
|
507
515
|
'--safe-right': 'env(safe-area-inset-right,0px)',
|
|
508
516
|
'--safe-bottom': 'env(safe-area-inset-bottom,0px)',
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hanzo/design",
|
|
3
|
-
"version": "0.5.
|
|
4
|
-
"
|
|
3
|
+
"version": "0.5.15",
|
|
4
|
+
"packageManager": "pnpm@11.17.0",
|
|
5
|
+
"description": "Hanzo Design System \u2014 monochrome, dark-default tokens + components + brand assets, the single source of truth for every Hanzo surface. CSS + typed programmatic tokens.",
|
|
5
6
|
"license": "MIT OR Apache-2.0",
|
|
6
7
|
"repository": {
|
|
7
8
|
"type": "git",
|
|
@@ -31,6 +32,13 @@
|
|
|
31
32
|
"./skills/*": "./skills/*",
|
|
32
33
|
"./tailwind.css": "./tailwind.css"
|
|
33
34
|
},
|
|
35
|
+
"scripts": {
|
|
36
|
+
"gen": "node scripts/gen-tokens.mjs",
|
|
37
|
+
"test": "node scripts/check-tokens.mjs && node scripts/check-preference.mjs && node scripts/lint.mjs .",
|
|
38
|
+
"build": "pnpm gen && pnpm test && tsc -p tsconfig.json && node scripts/check-dist.mjs",
|
|
39
|
+
"prepublishOnly": "pnpm build",
|
|
40
|
+
"lint": "node scripts/lint.mjs"
|
|
41
|
+
},
|
|
34
42
|
"devDependencies": {
|
|
35
43
|
"typescript": "^5.9.3"
|
|
36
44
|
},
|
|
@@ -63,11 +71,5 @@
|
|
|
63
71
|
},
|
|
64
72
|
"bin": {
|
|
65
73
|
"hanzo-design-lint": "./scripts/lint.mjs"
|
|
66
|
-
},
|
|
67
|
-
"scripts": {
|
|
68
|
-
"gen": "node scripts/gen-tokens.mjs",
|
|
69
|
-
"test": "node scripts/check-tokens.mjs && node scripts/check-preference.mjs && node scripts/lint.mjs .",
|
|
70
|
-
"build": "pnpm gen && pnpm test && tsc -p tsconfig.json && node scripts/check-dist.mjs",
|
|
71
|
-
"lint": "node scripts/lint.mjs"
|
|
72
74
|
}
|
|
73
|
-
}
|
|
75
|
+
}
|
package/src/tokens.gen.ts
CHANGED
|
@@ -39,11 +39,11 @@ export const colors = {
|
|
|
39
39
|
'white-80': 'rgb(255 255 255 / .80)',
|
|
40
40
|
'white-92': 'rgb(255 255 255 / .92)',
|
|
41
41
|
'background': '#0a0a0a',
|
|
42
|
-
'foreground': '#
|
|
42
|
+
'foreground': '#e5e5e5',
|
|
43
43
|
'card': '#0f0f0f',
|
|
44
|
-
'card-foreground': '#
|
|
44
|
+
'card-foreground': '#e5e5e5',
|
|
45
45
|
'popover': '#0f0f0f',
|
|
46
|
-
'popover-foreground': '#
|
|
46
|
+
'popover-foreground': '#e5e5e5',
|
|
47
47
|
'primary': '#fafafa',
|
|
48
48
|
'primary-hover': '#e5e5e5',
|
|
49
49
|
'primary-foreground': '#0a0a0a',
|
|
@@ -209,6 +209,10 @@ export const spacing = {
|
|
|
209
209
|
'hero-y-lg': '4.5rem',
|
|
210
210
|
'header-height': '3.5rem',
|
|
211
211
|
'tap-target': '44px',
|
|
212
|
+
'control-height-sm': '32px',
|
|
213
|
+
'control-height': '36px',
|
|
214
|
+
'control-height-lg': '40px',
|
|
215
|
+
'control-height-xl': '52px',
|
|
212
216
|
'safe-top': 'env(safe-area-inset-top,0px)',
|
|
213
217
|
'safe-right': 'env(safe-area-inset-right,0px)',
|
|
214
218
|
'safe-bottom': 'env(safe-area-inset-bottom,0px)',
|
|
@@ -354,11 +358,11 @@ export const cssVars = {
|
|
|
354
358
|
'--white-80': 'rgb(255 255 255 / .80)',
|
|
355
359
|
'--white-92': 'rgb(255 255 255 / .92)',
|
|
356
360
|
'--background': '#0a0a0a',
|
|
357
|
-
'--foreground': '#
|
|
361
|
+
'--foreground': '#e5e5e5',
|
|
358
362
|
'--card': '#0f0f0f',
|
|
359
|
-
'--card-foreground': '#
|
|
363
|
+
'--card-foreground': '#e5e5e5',
|
|
360
364
|
'--popover': '#0f0f0f',
|
|
361
|
-
'--popover-foreground': '#
|
|
365
|
+
'--popover-foreground': '#e5e5e5',
|
|
362
366
|
'--primary': '#fafafa',
|
|
363
367
|
'--primary-hover': '#e5e5e5',
|
|
364
368
|
'--primary-foreground': '#0a0a0a',
|
|
@@ -516,6 +520,10 @@ export const cssVars = {
|
|
|
516
520
|
'--hero-y-lg': '4.5rem',
|
|
517
521
|
'--header-height': '3.5rem',
|
|
518
522
|
'--tap-target': '44px',
|
|
523
|
+
'--control-height-sm': '32px',
|
|
524
|
+
'--control-height': '36px',
|
|
525
|
+
'--control-height-lg': '40px',
|
|
526
|
+
'--control-height-xl': '52px',
|
|
519
527
|
'--safe-top': 'env(safe-area-inset-top,0px)',
|
|
520
528
|
'--safe-right': 'env(safe-area-inset-right,0px)',
|
|
521
529
|
'--safe-bottom': 'env(safe-area-inset-bottom,0px)',
|
package/styles.css
CHANGED
|
@@ -92,11 +92,20 @@
|
|
|
92
92
|
|
|
93
93
|
/* ——— semantic aliases (dark, the default) ——— */
|
|
94
94
|
--background:#0a0a0a;
|
|
95
|
-
|
|
95
|
+
/* READING ink, one rung below the top of the ramp. The note at the head of this
|
|
96
|
+
file already made this argument once — #ffffff on #000000 halates, so #fafafa
|
|
97
|
+
— and the argument does not stop being true at 19.0:1. Every heading and
|
|
98
|
+
paragraph on every surface was set in the brightest ink the system has, while
|
|
99
|
+
the CHROME beside them draws body text at --white-92; a page read as glare
|
|
100
|
+
against its own header. #e5e5e5 is the neutral-200 rung this file already
|
|
101
|
+
spends on --primary-hover, so the ramp gains no new value: 15.7:1 on the page,
|
|
102
|
+
15.2:1 on a card, both more than twice the 7:1 AAA asks of body text.
|
|
103
|
+
Something that genuinely needs the brightest ink names --primary. */
|
|
104
|
+
--foreground:#e5e5e5;
|
|
96
105
|
--card:#0f0f0f;
|
|
97
|
-
--card-foreground:#
|
|
106
|
+
--card-foreground:#e5e5e5;
|
|
98
107
|
--popover:#0f0f0f;
|
|
99
|
-
--popover-foreground:#
|
|
108
|
+
--popover-foreground:#e5e5e5;
|
|
100
109
|
--primary:#fafafa;
|
|
101
110
|
/* A 5% step, not the 16% this used to be. A filled button's fill is already
|
|
102
111
|
the top of the ink ramp, so the only directions available on hover are
|
|
@@ -503,6 +512,26 @@
|
|
|
503
512
|
hanzoai/id's stylesheet — one app knowing something the system did not. */
|
|
504
513
|
--tap-target:44px;
|
|
505
514
|
|
|
515
|
+
/* ——— controls ——— */
|
|
516
|
+
/* A control's OWN height, which the floor above does not answer: 44px is the
|
|
517
|
+
smallest a finger may aim at, not the size a thing should be. Nothing named
|
|
518
|
+
the second question, so each surface answered it privately and they drifted
|
|
519
|
+
— @hanzo/ui keeps `CONTROL_H = 36` in TypeScript, hanzoai/app pins a 30px
|
|
520
|
+
`--control-h` over that same 36px library, and hanzoai/id spelled
|
|
521
|
+
`min-height:52px` into three separate rules.
|
|
522
|
+
The first three rungs ARE @hanzo/ui's size table (default/sm/lg), moved
|
|
523
|
+
down to the layer that holds values so a host can answer it once instead of
|
|
524
|
+
each library carrying a private copy. They sit under the tap floor on
|
|
525
|
+
purpose: base.css lifts whichever one is spent to 44px under
|
|
526
|
+
`pointer:coarse`, so one declaration serves a compact pointer control and a
|
|
527
|
+
hittable touch one. -xl is what a surface earns when the control IS the
|
|
528
|
+
content — one field, one button, nothing competing — where the default
|
|
529
|
+
reads as one of a stack rather than as the thing the screen is for. */
|
|
530
|
+
--control-height-sm:32px;
|
|
531
|
+
--control-height:36px;
|
|
532
|
+
--control-height-lg:40px;
|
|
533
|
+
--control-height-xl:52px;
|
|
534
|
+
|
|
506
535
|
/* ——— safe areas ——— */
|
|
507
536
|
/* The notch/home-indicator insets, named once. Anything pinned to a viewport
|
|
508
537
|
edge — a fixed header, a bottom bar, a sheet — adds the matching one. */
|
package/tailwind.css
CHANGED
|
@@ -115,11 +115,20 @@
|
|
|
115
115
|
|
|
116
116
|
/* ——— semantic aliases (dark, the default) ——— */
|
|
117
117
|
--background:#0a0a0a;
|
|
118
|
-
|
|
118
|
+
/* READING ink, one rung below the top of the ramp. The note at the head of this
|
|
119
|
+
file already made this argument once — #ffffff on #000000 halates, so #fafafa
|
|
120
|
+
— and the argument does not stop being true at 19.0:1. Every heading and
|
|
121
|
+
paragraph on every surface was set in the brightest ink the system has, while
|
|
122
|
+
the CHROME beside them draws body text at --white-92; a page read as glare
|
|
123
|
+
against its own header. #e5e5e5 is the neutral-200 rung this file already
|
|
124
|
+
spends on --primary-hover, so the ramp gains no new value: 15.7:1 on the page,
|
|
125
|
+
15.2:1 on a card, both more than twice the 7:1 AAA asks of body text.
|
|
126
|
+
Something that genuinely needs the brightest ink names --primary. */
|
|
127
|
+
--foreground:#e5e5e5;
|
|
119
128
|
--card:#0f0f0f;
|
|
120
|
-
--card-foreground:#
|
|
129
|
+
--card-foreground:#e5e5e5;
|
|
121
130
|
--popover:#0f0f0f;
|
|
122
|
-
--popover-foreground:#
|
|
131
|
+
--popover-foreground:#e5e5e5;
|
|
123
132
|
--primary:#fafafa;
|
|
124
133
|
/* A 5% step, not the 16% this used to be. A filled button's fill is already
|
|
125
134
|
the top of the ink ramp, so the only directions available on hover are
|
|
@@ -526,6 +535,26 @@
|
|
|
526
535
|
hanzoai/id's stylesheet — one app knowing something the system did not. */
|
|
527
536
|
--tap-target:44px;
|
|
528
537
|
|
|
538
|
+
/* ——— controls ——— */
|
|
539
|
+
/* A control's OWN height, which the floor above does not answer: 44px is the
|
|
540
|
+
smallest a finger may aim at, not the size a thing should be. Nothing named
|
|
541
|
+
the second question, so each surface answered it privately and they drifted
|
|
542
|
+
— @hanzo/ui keeps `CONTROL_H = 36` in TypeScript, hanzoai/app pins a 30px
|
|
543
|
+
`--control-h` over that same 36px library, and hanzoai/id spelled
|
|
544
|
+
`min-height:52px` into three separate rules.
|
|
545
|
+
The first three rungs ARE @hanzo/ui's size table (default/sm/lg), moved
|
|
546
|
+
down to the layer that holds values so a host can answer it once instead of
|
|
547
|
+
each library carrying a private copy. They sit under the tap floor on
|
|
548
|
+
purpose: base.css lifts whichever one is spent to 44px under
|
|
549
|
+
`pointer:coarse`, so one declaration serves a compact pointer control and a
|
|
550
|
+
hittable touch one. -xl is what a surface earns when the control IS the
|
|
551
|
+
content — one field, one button, nothing competing — where the default
|
|
552
|
+
reads as one of a stack rather than as the thing the screen is for. */
|
|
553
|
+
--control-height-sm:32px;
|
|
554
|
+
--control-height:36px;
|
|
555
|
+
--control-height-lg:40px;
|
|
556
|
+
--control-height-xl:52px;
|
|
557
|
+
|
|
529
558
|
/* ——— safe areas ——— */
|
|
530
559
|
/* The notch/home-indicator insets, named once. Anything pinned to a viewport
|
|
531
560
|
edge — a fixed header, a bottom bar, a sheet — adds the matching one. */
|
package/tokens/colors.css
CHANGED
|
@@ -77,11 +77,20 @@
|
|
|
77
77
|
|
|
78
78
|
/* ——— semantic aliases (dark, the default) ——— */
|
|
79
79
|
--background:#0a0a0a;
|
|
80
|
-
|
|
80
|
+
/* READING ink, one rung below the top of the ramp. The note at the head of this
|
|
81
|
+
file already made this argument once — #ffffff on #000000 halates, so #fafafa
|
|
82
|
+
— and the argument does not stop being true at 19.0:1. Every heading and
|
|
83
|
+
paragraph on every surface was set in the brightest ink the system has, while
|
|
84
|
+
the CHROME beside them draws body text at --white-92; a page read as glare
|
|
85
|
+
against its own header. #e5e5e5 is the neutral-200 rung this file already
|
|
86
|
+
spends on --primary-hover, so the ramp gains no new value: 15.7:1 on the page,
|
|
87
|
+
15.2:1 on a card, both more than twice the 7:1 AAA asks of body text.
|
|
88
|
+
Something that genuinely needs the brightest ink names --primary. */
|
|
89
|
+
--foreground:#e5e5e5;
|
|
81
90
|
--card:#0f0f0f;
|
|
82
|
-
--card-foreground:#
|
|
91
|
+
--card-foreground:#e5e5e5;
|
|
83
92
|
--popover:#0f0f0f;
|
|
84
|
-
--popover-foreground:#
|
|
93
|
+
--popover-foreground:#e5e5e5;
|
|
85
94
|
--primary:#fafafa;
|
|
86
95
|
/* A 5% step, not the 16% this used to be. A filled button's fill is already
|
|
87
96
|
the top of the ink ramp, so the only directions available on hover are
|
package/tokens/spacing.css
CHANGED
|
@@ -68,6 +68,26 @@
|
|
|
68
68
|
hanzoai/id's stylesheet — one app knowing something the system did not. */
|
|
69
69
|
--tap-target:44px;
|
|
70
70
|
|
|
71
|
+
/* ——— controls ——— */
|
|
72
|
+
/* A control's OWN height, which the floor above does not answer: 44px is the
|
|
73
|
+
smallest a finger may aim at, not the size a thing should be. Nothing named
|
|
74
|
+
the second question, so each surface answered it privately and they drifted
|
|
75
|
+
— @hanzo/ui keeps `CONTROL_H = 36` in TypeScript, hanzoai/app pins a 30px
|
|
76
|
+
`--control-h` over that same 36px library, and hanzoai/id spelled
|
|
77
|
+
`min-height:52px` into three separate rules.
|
|
78
|
+
The first three rungs ARE @hanzo/ui's size table (default/sm/lg), moved
|
|
79
|
+
down to the layer that holds values so a host can answer it once instead of
|
|
80
|
+
each library carrying a private copy. They sit under the tap floor on
|
|
81
|
+
purpose: base.css lifts whichever one is spent to 44px under
|
|
82
|
+
`pointer:coarse`, so one declaration serves a compact pointer control and a
|
|
83
|
+
hittable touch one. -xl is what a surface earns when the control IS the
|
|
84
|
+
content — one field, one button, nothing competing — where the default
|
|
85
|
+
reads as one of a stack rather than as the thing the screen is for. */
|
|
86
|
+
--control-height-sm:32px;
|
|
87
|
+
--control-height:36px;
|
|
88
|
+
--control-height-lg:40px;
|
|
89
|
+
--control-height-xl:52px;
|
|
90
|
+
|
|
71
91
|
/* ——— safe areas ——— */
|
|
72
92
|
/* The notch/home-indicator insets, named once. Anything pinned to a viewport
|
|
73
93
|
edge — a fixed header, a bottom bar, a sheet — adds the matching one. */
|