@hanzo/design 0.5.1 → 0.5.3

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.
@@ -239,6 +239,13 @@ export declare const elevation: {
239
239
  readonly 'shadow-lg': "0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)";
240
240
  readonly 'shadow-xl': "0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)";
241
241
  readonly 'shadow-2xl': "var(--shadow-floating)";
242
+ readonly 'sheet-0': "var(--surface-page)";
243
+ readonly 'sheet-1': "var(--surface-card)";
244
+ readonly 'sheet-2': "var(--surface-card-emphasis)";
245
+ readonly 'shadow-sheet-1': "var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)";
246
+ readonly 'shadow-sheet-2': "var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)";
247
+ readonly fold: "12px";
248
+ readonly 'fold-face': "linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))";
242
249
  readonly 'glow-hero': "radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)";
243
250
  readonly 'glow-hero-blur': "120px";
244
251
  readonly 'sheen-card': "radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)";
@@ -512,6 +519,13 @@ export declare const cssVars: {
512
519
  readonly '--shadow-lg': "0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)";
513
520
  readonly '--shadow-xl': "0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)";
514
521
  readonly '--shadow-2xl': "var(--shadow-floating)";
522
+ readonly '--sheet-0': "var(--surface-page)";
523
+ readonly '--sheet-1': "var(--surface-card)";
524
+ readonly '--sheet-2': "var(--surface-card-emphasis)";
525
+ readonly '--shadow-sheet-1': "var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)";
526
+ readonly '--shadow-sheet-2': "var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)";
527
+ readonly '--fold': "12px";
528
+ readonly '--fold-face': "linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))";
515
529
  readonly '--glow-hero': "radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)";
516
530
  readonly '--glow-hero-blur': "120px";
517
531
  readonly '--sheen-card': "radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)";
@@ -1 +1 @@
1
- {"version":3,"file":"tokens.gen.d.ts","sourceRoot":"","sources":["../src/tokens.gen.ts"],"names":[],"mappings":"AAIA,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyFT,CAAA;AAEV,0EAA0E;AAC1E,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgEb,CAAA;AAEV,oEAAoE;AACpE,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2CV,CAAA;AAEV,8DAA8D;AAC9D,eAAO,MAAM,IAAI;;;;;;;;;;;;CAYP,CAAA;AAEV,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;CAST,CAAA;AAEV,wEAAwE;AACxE,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;CAoBZ,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoQV,CAAA;AAEV,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,OAAO,CAAA"}
1
+ {"version":3,"file":"tokens.gen.d.ts","sourceRoot":"","sources":["../src/tokens.gen.ts"],"names":[],"mappings":"AAIA,kEAAkE;AAClE,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyFT,CAAA;AAEV,0EAA0E;AAC1E,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgEb,CAAA;AAEV,oEAAoE;AACpE,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2CV,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2QV,CAAA;AAEV,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,OAAO,CAAA"}
@@ -242,6 +242,13 @@ export const elevation = {
242
242
  'shadow-lg': '0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)',
243
243
  'shadow-xl': '0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)',
244
244
  'shadow-2xl': 'var(--shadow-floating)',
245
+ 'sheet-0': 'var(--surface-page)',
246
+ 'sheet-1': 'var(--surface-card)',
247
+ 'sheet-2': 'var(--surface-card-emphasis)',
248
+ 'shadow-sheet-1': 'var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)',
249
+ 'shadow-sheet-2': 'var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)',
250
+ 'fold': '12px',
251
+ 'fold-face': 'linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))',
245
252
  'glow-hero': 'radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)',
246
253
  'glow-hero-blur': '120px',
247
254
  'sheen-card': 'radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)',
@@ -515,6 +522,13 @@ export const cssVars = {
515
522
  '--shadow-lg': '0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)',
516
523
  '--shadow-xl': '0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)',
517
524
  '--shadow-2xl': 'var(--shadow-floating)',
525
+ '--sheet-0': 'var(--surface-page)',
526
+ '--sheet-1': 'var(--surface-card)',
527
+ '--sheet-2': 'var(--surface-card-emphasis)',
528
+ '--shadow-sheet-1': 'var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)',
529
+ '--shadow-sheet-2': 'var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)',
530
+ '--fold': '12px',
531
+ '--fold-face': 'linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))',
518
532
  '--glow-hero': 'radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)',
519
533
  '--glow-hero-blur': '120px',
520
534
  '--sheen-card': 'radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)',
@@ -0,0 +1,22 @@
1
+ <!-- @dsCard group="Brand" viewport="700x240" name="Paper" subtitle="Three sheets, one light, and a fold that means this opens" -->
2
+ <!doctype html><html class="dark"><head><meta charset="utf-8"><title>Paper</title><link rel="stylesheet" href="../styles.css">
3
+ <style>body{margin:0;padding:20px;background:var(--sheet-0);font-family:var(--font-sans);color:var(--foreground)}
4
+ .n{font-size:10px;font-weight:600;letter-spacing:.06em;color:var(--neutral-300);font-family:var(--font-mono)}
5
+ .v{font-size:9px;color:var(--neutral-600);font-family:var(--font-mono);margin-top:3px}
6
+ .sheet{padding:14px;border-radius:var(--radius-lg);font-size:12px;color:var(--neutral-400)}
7
+ .s1{background:var(--sheet-1);box-shadow:var(--shadow-sheet-1)}
8
+ .s2{background:var(--sheet-2);box-shadow:var(--shadow-sheet-2)}
9
+ .fold{background-image:var(--fold-face);border-bottom-right-radius:0}
10
+ </style></head><body>
11
+ <div style="display:flex;gap:16px;align-items:stretch">
12
+ <div class="sheet" style="flex:1">the workspace — no lift, no box<div class="n" style="margin-top:10px">--sheet-0</div><div class="v">the ground</div></div>
13
+ <div class="sheet s1" style="flex:1">an active tool<div class="n" style="margin-top:10px">--sheet-1</div><div class="v">+ --shadow-sheet-1</div></div>
14
+ <div class="sheet s2" style="flex:1">what opened<div class="n" style="margin-top:10px">--sheet-2</div><div class="v">+ --shadow-sheet-2</div></div>
15
+ <div class="sheet s1 fold" style="flex:1">this one expands<div class="n" style="margin-top:10px">--fold-face</div><div class="v">the only mark</div></div>
16
+ </div>
17
+ <div style="margin-top:18px;display:flex;gap:16px">
18
+ <div class="sheet s1" style="flex:1">a sheet on a sheet lands a step lighter
19
+ <div class="sheet s1" style="margin-top:10px">nested<div class="sheet s1" style="margin-top:10px">nested again</div></div>
20
+ </div>
21
+ </div>
22
+ </body></html>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hanzo/design",
3
- "version": "0.5.1",
3
+ "version": "0.5.3",
4
4
  "packageManager": "pnpm@11.17.0",
5
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.",
6
6
  "license": "MIT OR Apache-2.0",
package/prompts/rules.md CHANGED
@@ -33,7 +33,9 @@ token or pattern that makes the "do" trivial.
33
33
  |----|-------|
34
34
  | One primary (white) action per view; everything else outline or ghost. | Two competing primary buttons. |
35
35
  | Plain `<a>` / `<Link>` with className, or the shipped `<Button>`. | `<Button asChild>` — it breaks the build under React 18 strict children. |
36
- | Elevation as a hairline border + `--shadow-floating` only when floating. | Drop shadows on flat, in-flow cards. |
36
+ | Separate two surfaces by RAISING one `--sheet-1` + `--shadow-sheet-1`. | Outlining both, then raising one anyway. |
37
+ | A level because the surface means something: workspace, tool, opened. | A drop shadow for looks, or a second lamp — every shadow drops straight down. |
38
+ | A fold (`--fold-face`) only where the item expands. | A fold as ornament. |
37
39
 
38
40
  ## Motion
39
41
 
package/prompts/system.md CHANGED
@@ -73,8 +73,14 @@ That is not Hanzo. Make it white-on-black and let the content carry it.
73
73
 
74
74
  - `--radius-sm` on buttons/inputs, `--radius-lg` on cards, `--radius-full` on
75
75
  pills and avatars. `--radius-composer` (28px) only for the chat composer.
76
- - Hanzo barely uses shadow. On black, elevation is a hairline border plus, for
77
- truly floating surfaces, `--shadow-floating`. Heroes get one ambient
76
+ - Depth is the hierarchy. Three levels of paper: `--sheet-0` is the workspace,
77
+ `--sheet-1` an active tool, `--sheet-2` what opened each with the matching
78
+ `--shadow-sheet-*`, which carries the top edge-light and the drop together.
79
+ Raise a surface before you outline it, and never do both.
80
+ - One light, above: every shadow in the system is `0 <y> …`. A sideways offset
81
+ is a second lamp, and the screen stops reading as one space.
82
+ - `--fold-face` marks an item that expands, and nothing else. `--shadow-floating`
83
+ is for what actually floats — menus, dialogs. Heroes get one ambient
78
84
  `--glow-hero` radial, nothing more.
79
85
 
80
86
  ## Motion
@@ -302,5 +302,31 @@ const pass = (msg) => console.log(` ok ${msg}`)
302
302
  }
303
303
  }
304
304
 
305
+ // ── 5. one light, from one direction ─────────────────────────────────────
306
+ // The paper ramp reads as one space only while every edge and every drop in
307
+ // the system agrees where the light is. A single `2px 4px` — the spelling
308
+ // every other library ships — puts a second lamp in the room, and the failure
309
+ // is not visible on any one component: the panel with the offset shadow looks
310
+ // fine, and it is the SCREEN that stops making sense. So the rule is checked
311
+ // on the values instead of trusted to whoever writes the next one: the light
312
+ // is directly above, so a shadow moves down and never sideways.
313
+ //
314
+ // Structural, not by name — a layer counts as a shadow when its first two
315
+ // lengths are lengths, which is what a shadow is and what a size is not.
316
+ {
317
+ const css = strip(read(join(tokensDir, 'elevation.css')))
318
+ const LEN = /^-?[\d.]+(px|rem|em)?$/
319
+ const offenders = []
320
+ for (const [, name, value] of css.matchAll(/--([A-Za-z0-9-]+)\s*:\s*([^;]+);/g))
321
+ for (const layer of value.split(',')) {
322
+ const t = layer.trim().replace(/^inset\s+/, '').split(/\s+/)
323
+ if (LEN.test(t[0]) && LEN.test(t[1] ?? '') && parseFloat(t[0]) !== 0)
324
+ offenders.push(`--${name} (${layer.trim()})`)
325
+ }
326
+ offenders.length
327
+ ? offenders.forEach((o) => fail(`${o} is offset sideways — the light is above, so every shadow is \`0 <y> …\``))
328
+ : pass('one light direction — every shadow in elevation.css drops straight down')
329
+ }
330
+
305
331
  console.log(failures ? `\n${failures} check(s) failed` : '\nall token checks passed')
306
332
  process.exit(failures ? 1 : 0)
@@ -43,7 +43,9 @@ Then reach for a **name**, never a value:
43
43
  | You want | Use | Never |
44
44
  |---|---|---|
45
45
  | a page / text | `--background`, `--foreground`, `--text-secondary` | `#000`, `#fff`, `rgb(…)` |
46
- | a card, a panel | `--surface-card`, `--border-hairline` | a hand-mixed grey |
46
+ | a card, a panel | `--surface-card`, `--border` | a hand-mixed grey |
47
+ | depth — a tool over the workspace | `--sheet-1` + `--shadow-sheet-1` | a box round both, or your own `box-shadow` |
48
+ | "this expands" | `--fold-face` | a fold as ornament |
47
49
  | rank / emphasis | the ladder `--white-05 … --white-80` | an off-ladder 12% or 37% |
48
50
  | a size | `--type-body`, `--type-h2`, `--text-sm` | `font-size: 13px` |
49
51
  | space | `--space-*`, `--gutter*`, `--container-max` | `padding: 13px` |
package/src/tokens.gen.ts CHANGED
@@ -248,6 +248,13 @@ export const elevation = {
248
248
  'shadow-lg': '0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)',
249
249
  'shadow-xl': '0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)',
250
250
  'shadow-2xl': 'var(--shadow-floating)',
251
+ 'sheet-0': 'var(--surface-page)',
252
+ 'sheet-1': 'var(--surface-card)',
253
+ 'sheet-2': 'var(--surface-card-emphasis)',
254
+ 'shadow-sheet-1': 'var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)',
255
+ 'shadow-sheet-2': 'var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)',
256
+ 'fold': '12px',
257
+ 'fold-face': 'linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))',
251
258
  'glow-hero': 'radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)',
252
259
  'glow-hero-blur': '120px',
253
260
  'sheen-card': 'radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)',
@@ -528,6 +535,13 @@ export const cssVars = {
528
535
  '--shadow-lg': '0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55)',
529
536
  '--shadow-xl': '0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60)',
530
537
  '--shadow-2xl': 'var(--shadow-floating)',
538
+ '--sheet-0': 'var(--surface-page)',
539
+ '--sheet-1': 'var(--surface-card)',
540
+ '--sheet-2': 'var(--surface-card-emphasis)',
541
+ '--shadow-sheet-1': 'var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40)',
542
+ '--shadow-sheet-2': 'var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55)',
543
+ '--fold': '12px',
544
+ '--fold-face': 'linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold))',
531
545
  '--glow-hero': 'radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%)',
532
546
  '--glow-hero-blur': '120px',
533
547
  '--sheen-card': 'radial-gradient(120% 120% at 80% 0%,rgb(255 255 255 / .08) 0%,transparent 55%)',
package/styles.css CHANGED
@@ -588,6 +588,51 @@
588
588
  --shadow-lg:0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55);
589
589
  --shadow-xl:0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60);
590
590
  --shadow-2xl:var(--shadow-floating);
591
+
592
+ /* ——— the paper ——— */
593
+ /* Depth carries STATE, not decoration: which sheet is the workspace, which is
594
+ the tool in use, which one opened. Reach for a level before a border — if
595
+ two surfaces need separating, RAISE one rather than outline both, and a
596
+ surface that is already raised does not also need a box drawn round it.
597
+
598
+ A level is a tint AND the light on it, published as a pair, because the
599
+ alternative — every component composing its own `--edge-highlight,
600
+ --shadow-*` — is how two panels on one screen end up lit from two
601
+ directions. Every rung here is pure vertical: a 1px inset line along the
602
+ top edge, a drop straight down. One origin, above and slightly in front.
603
+
604
+ The tints are the surface recipes rather than new values, so sheets stack
605
+ the way paper does: each is an alpha-white wash, one laid on another lands
606
+ a step lighter, and the stack converges on #262626 instead of blowing out.
607
+
608
+ Nothing here is restated in `.light`, deliberately: every part defers to a
609
+ token that already flips, so the ramp inverts with the theme for free. */
610
+ --sheet-0:var(--surface-page); /* the workspace ground */
611
+ --sheet-1:var(--surface-card); /* an active tool */
612
+ --sheet-2:var(--surface-card-emphasis); /* what opened, or what is inside */
613
+ /* The drops are spelled out rather than read from the t-shirt ramp above, and
614
+ that is the whole reason this ladder can be shared. `--shadow-sm` is a name
615
+ this package does not own — @hanzo/brand declares the same names at :root
616
+ with white-canvas alphas, and load order decides who wins — so a rung built
617
+ on one is a rung somebody else can flatten. `--shadow-sheet-*` is ours
618
+ alone, which is what lets @hanzo/ui's `.elevation-*` read it instead of
619
+ keeping a private copy. The numbers ARE rung 1 and rung 2 of the ramp; if
620
+ one moves, move both. `--edge-highlight` stays deferred: it is role-named,
621
+ uncollided, and its `.light` zeroing is what makes one value work on both
622
+ canvases. */
623
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40);
624
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55);
625
+
626
+ /* The fold — a corner turned back, and the one mark that means THIS OPENS.
627
+ Ornament nowhere: a sheet that does not expand does not wear one.
628
+ It is a background-image, so it costs no element and no pseudo-element —
629
+ paint it on the sheet itself and square that corner
630
+ (`border-bottom-right-radius:0`), because a folded corner is not round.
631
+ The flap catches the light like every other surface; the crease is the
632
+ hairline; both defer, so both invert. */
633
+ --fold:12px;
634
+ --fold-face:linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold)); /* @kind color */
635
+
591
636
  /* Ambient hero glow — a single white radial, blurred 120px, low opacity. */
592
637
  --glow-hero:radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%); /* @kind color */
593
638
  --glow-hero-blur:120px;
@@ -620,6 +665,11 @@
620
665
  costs nothing. */
621
666
  .light{
622
667
  --shadow-floating:0 24px 60px -16px rgb(0 0 0 / .18);
668
+ /* On white the drop does all of it, so the paper rungs are restated here even
669
+ though check 4 does not demand it — their white is inside --edge-highlight,
670
+ which flips underneath. Rung 1 and rung 2 of the light ramp, same as dark. */
671
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .06);
672
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .09),0 4px 6px -4px rgb(0 0 0 / .07);
623
673
  --shadow-inset-hairline:inset 0 0 0 1px rgb(0 0 0 / .10);
624
674
  --edge-highlight:inset 0 0 0 0 transparent;
625
675
  --bloom:0 6px 20px -4px rgb(0 0 0 / .18);
package/tailwind.css CHANGED
@@ -611,6 +611,51 @@
611
611
  --shadow-lg:0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55);
612
612
  --shadow-xl:0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60);
613
613
  --shadow-2xl:var(--shadow-floating);
614
+
615
+ /* ——— the paper ——— */
616
+ /* Depth carries STATE, not decoration: which sheet is the workspace, which is
617
+ the tool in use, which one opened. Reach for a level before a border — if
618
+ two surfaces need separating, RAISE one rather than outline both, and a
619
+ surface that is already raised does not also need a box drawn round it.
620
+
621
+ A level is a tint AND the light on it, published as a pair, because the
622
+ alternative — every component composing its own `--edge-highlight,
623
+ --shadow-*` — is how two panels on one screen end up lit from two
624
+ directions. Every rung here is pure vertical: a 1px inset line along the
625
+ top edge, a drop straight down. One origin, above and slightly in front.
626
+
627
+ The tints are the surface recipes rather than new values, so sheets stack
628
+ the way paper does: each is an alpha-white wash, one laid on another lands
629
+ a step lighter, and the stack converges on #262626 instead of blowing out.
630
+
631
+ Nothing here is restated in `.light`, deliberately: every part defers to a
632
+ token that already flips, so the ramp inverts with the theme for free. */
633
+ --sheet-0:var(--surface-page); /* the workspace ground */
634
+ --sheet-1:var(--surface-card); /* an active tool */
635
+ --sheet-2:var(--surface-card-emphasis); /* what opened, or what is inside */
636
+ /* The drops are spelled out rather than read from the t-shirt ramp above, and
637
+ that is the whole reason this ladder can be shared. `--shadow-sm` is a name
638
+ this package does not own — @hanzo/brand declares the same names at :root
639
+ with white-canvas alphas, and load order decides who wins — so a rung built
640
+ on one is a rung somebody else can flatten. `--shadow-sheet-*` is ours
641
+ alone, which is what lets @hanzo/ui's `.elevation-*` read it instead of
642
+ keeping a private copy. The numbers ARE rung 1 and rung 2 of the ramp; if
643
+ one moves, move both. `--edge-highlight` stays deferred: it is role-named,
644
+ uncollided, and its `.light` zeroing is what makes one value work on both
645
+ canvases. */
646
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40);
647
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55);
648
+
649
+ /* The fold — a corner turned back, and the one mark that means THIS OPENS.
650
+ Ornament nowhere: a sheet that does not expand does not wear one.
651
+ It is a background-image, so it costs no element and no pseudo-element —
652
+ paint it on the sheet itself and square that corner
653
+ (`border-bottom-right-radius:0`), because a folded corner is not round.
654
+ The flap catches the light like every other surface; the crease is the
655
+ hairline; both defer, so both invert. */
656
+ --fold:12px;
657
+ --fold-face:linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold)); /* @kind color */
658
+
614
659
  /* Ambient hero glow — a single white radial, blurred 120px, low opacity. */
615
660
  --glow-hero:radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%); /* @kind color */
616
661
  --glow-hero-blur:120px;
@@ -643,6 +688,11 @@
643
688
  costs nothing. */
644
689
  .light{
645
690
  --shadow-floating:0 24px 60px -16px rgb(0 0 0 / .18);
691
+ /* On white the drop does all of it, so the paper rungs are restated here even
692
+ though check 4 does not demand it — their white is inside --edge-highlight,
693
+ which flips underneath. Rung 1 and rung 2 of the light ramp, same as dark. */
694
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .06);
695
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .09),0 4px 6px -4px rgb(0 0 0 / .07);
646
696
  --shadow-inset-hairline:inset 0 0 0 1px rgb(0 0 0 / .10);
647
697
  --edge-highlight:inset 0 0 0 0 transparent;
648
698
  --bloom:0 6px 20px -4px rgb(0 0 0 / .18);
@@ -53,6 +53,51 @@
53
53
  --shadow-lg:0 10px 15px -3px rgb(0 0 0 / .55), 0 4px 6px -4px rgb(0 0 0 / .55);
54
54
  --shadow-xl:0 20px 25px -5px rgb(0 0 0 / .60), 0 8px 10px -6px rgb(0 0 0 / .60);
55
55
  --shadow-2xl:var(--shadow-floating);
56
+
57
+ /* ——— the paper ——— */
58
+ /* Depth carries STATE, not decoration: which sheet is the workspace, which is
59
+ the tool in use, which one opened. Reach for a level before a border — if
60
+ two surfaces need separating, RAISE one rather than outline both, and a
61
+ surface that is already raised does not also need a box drawn round it.
62
+
63
+ A level is a tint AND the light on it, published as a pair, because the
64
+ alternative — every component composing its own `--edge-highlight,
65
+ --shadow-*` — is how two panels on one screen end up lit from two
66
+ directions. Every rung here is pure vertical: a 1px inset line along the
67
+ top edge, a drop straight down. One origin, above and slightly in front.
68
+
69
+ The tints are the surface recipes rather than new values, so sheets stack
70
+ the way paper does: each is an alpha-white wash, one laid on another lands
71
+ a step lighter, and the stack converges on #262626 instead of blowing out.
72
+
73
+ Nothing here is restated in `.light`, deliberately: every part defers to a
74
+ token that already flips, so the ramp inverts with the theme for free. */
75
+ --sheet-0:var(--surface-page); /* the workspace ground */
76
+ --sheet-1:var(--surface-card); /* an active tool */
77
+ --sheet-2:var(--surface-card-emphasis); /* what opened, or what is inside */
78
+ /* The drops are spelled out rather than read from the t-shirt ramp above, and
79
+ that is the whole reason this ladder can be shared. `--shadow-sm` is a name
80
+ this package does not own — @hanzo/brand declares the same names at :root
81
+ with white-canvas alphas, and load order decides who wins — so a rung built
82
+ on one is a rung somebody else can flatten. `--shadow-sheet-*` is ours
83
+ alone, which is what lets @hanzo/ui's `.elevation-*` read it instead of
84
+ keeping a private copy. The numbers ARE rung 1 and rung 2 of the ramp; if
85
+ one moves, move both. `--edge-highlight` stays deferred: it is role-named,
86
+ uncollided, and its `.light` zeroing is what makes one value work on both
87
+ canvases. */
88
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .40);
89
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .55),0 4px 6px -4px rgb(0 0 0 / .55);
90
+
91
+ /* The fold — a corner turned back, and the one mark that means THIS OPENS.
92
+ Ornament nowhere: a sheet that does not expand does not wear one.
93
+ It is a background-image, so it costs no element and no pseudo-element —
94
+ paint it on the sheet itself and square that corner
95
+ (`border-bottom-right-radius:0`), because a folded corner is not round.
96
+ The flap catches the light like every other surface; the crease is the
97
+ hairline; both defer, so both invert. */
98
+ --fold:12px;
99
+ --fold-face:linear-gradient(315deg,var(--glass-strong) 0,var(--glass-strong) calc(var(--fold) - 1px),var(--border-strong) calc(var(--fold) - 1px),var(--border-strong) var(--fold),transparent var(--fold)); /* @kind color */
100
+
56
101
  /* Ambient hero glow — a single white radial, blurred 120px, low opacity. */
57
102
  --glow-hero:radial-gradient(circle,rgb(255 255 255 / .12) 0%,transparent 68%); /* @kind color */
58
103
  --glow-hero-blur:120px;
@@ -85,6 +130,11 @@
85
130
  costs nothing. */
86
131
  .light{
87
132
  --shadow-floating:0 24px 60px -16px rgb(0 0 0 / .18);
133
+ /* On white the drop does all of it, so the paper rungs are restated here even
134
+ though check 4 does not demand it — their white is inside --edge-highlight,
135
+ which flips underneath. Rung 1 and rung 2 of the light ramp, same as dark. */
136
+ --shadow-sheet-1:var(--edge-highlight),0 1px 2px 0 rgb(0 0 0 / .06);
137
+ --shadow-sheet-2:var(--edge-highlight),0 10px 15px -3px rgb(0 0 0 / .09),0 4px 6px -4px rgb(0 0 0 / .07);
88
138
  --shadow-inset-hairline:inset 0 0 0 1px rgb(0 0 0 / .10);
89
139
  --edge-highlight:inset 0 0 0 0 transparent;
90
140
  --bloom:0 6px 20px -4px rgb(0 0 0 / .18);