Commit 480e5d1
committed
fix(gallery): define --destructive, and correct the @theme inline rule
Delta-review fixes.
--destructive and --destructive-foreground were mapped in public/input.css
and used at 20 call sites for validation errors, but nothing ever defined
them. An undefined var() is invalid at computed-value time, so every error
message in the auth, forms, file-storage, rate-limit and server-action demos
painted in the ordinary foreground colour, and the destructive button variant
had no fill. Measured in the browser before and after: text-destructive was
byte-identical to body text, and now resolves to the red. Pre-existing, but it
is the same dead-token class the previous commit audited, in the same block,
and it undercut this PR's claim that only token VALUES moved.
--color-success went the other way and is removed. Nothing in the app uses
success in any form, so defining it would have added exactly the kind of dead
token the last round removed three of.
The styling reference's new rule was wrong and is rewritten against a
measurement rather than an assumption. A component's static styles IS inside
the scanned source, so a raw var(--color-x) written there forces emission even
under @theme inline; and the emission rule is about HOW a token is referenced,
not about which block declares it. Both forms drop a token nothing references.
The cell that actually bites is inline plus utility-only usage. The gallery's
plain @theme is therefore a fine choice but not, as previously written, a
load-bearing one, and the shadow demo was never at risk.
Also corrects two comments this PR had made stale: the toggle's .dark mirror
runs only on click while the bootstrap writes data-theme alone, so the class
is absent on every page load and is not the kit-compatibility path the comment
claimed; and --primary-tint now derives from --ring, not --primary.1 parent 73f22c9 commit 480e5d1
4 files changed
Lines changed: 30 additions & 12 deletions
File tree
- .agents/skills/webjs/references
- gallery
- app
- components
- public
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
112 | | - | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
113 | 124 | | |
114 | 125 | | |
115 | 126 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
112 | 121 | | |
113 | 122 | | |
114 | 123 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
42 | 45 | | |
43 | 46 | | |
44 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
61 | | - | |
| 60 | + | |
| 61 | + | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | 64 | | |
70 | 65 | | |
71 | 66 | | |
| |||
0 commit comments