@justai/cuts 0.52.0 → 0.54.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/package.json +1 -1
- package/src/Posts.astro +53 -2
package/package.json
CHANGED
package/src/Posts.astro
CHANGED
|
@@ -95,8 +95,59 @@ const vars = [
|
|
|
95
95
|
/* the cut owns its own landing offset (was `#kernel, #posts { scroll-margin-top }` in each persona —
|
|
96
96
|
which orphaned once #posts moved here and carried this component's scope cid instead of the persona's). */
|
|
97
97
|
.posts { border-block-start: 1px solid var(--border); scroll-margin-top: 82px; }
|
|
98
|
-
|
|
99
|
-
|
|
98
|
+
/* A post is hoverable because it is a link to its own page, and the hover used to say so with a grey wash
|
|
99
|
+
— `--text` at 3.5% — which reads as dimming rather than as lifting. It now uses the card material, so
|
|
100
|
+
hovering a post looks like the same gesture as hovering a catalogue card.
|
|
101
|
+
|
|
102
|
+
`var(--card-bg, ...)` with the old wash as the fallback ON PURPOSE. Those tokens exist in app.zone only;
|
|
103
|
+
the other eleven personas have no catalogue and never defined them, and their column already uses
|
|
104
|
+
`--surface` as its own background, so falling back to that would have made the hover invisible. This way
|
|
105
|
+
app.zone gets the material and nobody else changes at all, which is the difference between an
|
|
106
|
+
improvement and a regression in eleven repos.
|
|
107
|
+
|
|
108
|
+
16px of horizontal padding with a matching negative margin, so the box grows outward and the text does
|
|
109
|
+
not move. 16 rather than the 18 above it because the column's own padding is 16px on a phone and 28px
|
|
110
|
+
from 768px up: at 18 the box would overflow the narrow case by 2px. Two pixels of asymmetry nobody can
|
|
111
|
+
see beats a horizontal scrollbar on a phone.
|
|
112
|
+
|
|
113
|
+
Square corners, stated rather than inherited — a radius here would make it a card, and it is not one:
|
|
114
|
+
it spans the column and sits directly against its neighbours. */
|
|
115
|
+
.post {
|
|
116
|
+
padding-block: 18px;
|
|
117
|
+
padding-inline: 16px;
|
|
118
|
+
margin-inline: -16px;
|
|
119
|
+
border-radius: 0;
|
|
120
|
+
cursor: pointer;
|
|
121
|
+
transition: background 0.15s var(--ease-out), transform 0.15s var(--ease-out),
|
|
122
|
+
border-radius 0.15s var(--ease-out);
|
|
123
|
+
}
|
|
124
|
+
/* THE FILL LIVES IN ITS OWN PROPERTY, and that is not tidiness — it is the difference between a hover and
|
|
125
|
+
no hover. A color-mix over a bare --card-bg (no fallback) written straight into `background` is an
|
|
126
|
+
INVALID declaration for a persona that never defined --card-bg, and an invalid declaration is dropped, so
|
|
127
|
+
those pages would answer the cursor with nothing at all. Here the fallback sits inside the mix, so the
|
|
128
|
+
value is always valid; the defaults mirror app.zone's own tokens per scheme.
|
|
129
|
+
(app.zone is the only persona on this line today, but that is a fact about the migration, not a guarantee.)
|
|
130
|
+
|
|
131
|
+
55% rather than the full card colour, and no hairline. The full-strength version was measured at 7
|
|
132
|
+
luminance steps of lift in light, and it read as a slab competing with the text — the inset hairline was
|
|
133
|
+
doing most of that. At 55% the lift is 4 in light and still 9 in dark, so it calms down where it was loud
|
|
134
|
+
without disappearing where it was already subtle. 35% was tried and rejected: 2 steps in dark, which on a
|
|
135
|
+
bright screen is nothing.
|
|
136
|
+
|
|
137
|
+
The radius and the scale are why it now invites rather than announces. They only exist on hover — at rest
|
|
138
|
+
the post has no box to round. */
|
|
139
|
+
.post:hover {
|
|
140
|
+
background: color-mix(in srgb, var(--card-bg, rgba(255, 255, 255, 0.06)) 55%, transparent);
|
|
141
|
+
backdrop-filter: var(--card-blur, none);
|
|
142
|
+
-webkit-backdrop-filter: var(--card-blur, none);
|
|
143
|
+
border-radius: 14px;
|
|
144
|
+
transform: scale(1.006);
|
|
145
|
+
}
|
|
146
|
+
/* The light default is white because that is what --card-bg is there; the dark default is a faint white
|
|
147
|
+
overlay because on dark --card-bg equals --surface, which is the column, so copying it would vanish. */
|
|
148
|
+
@media (prefers-color-scheme: light) {
|
|
149
|
+
.post:hover { background: color-mix(in srgb, var(--card-bg, #fff) 55%, transparent); }
|
|
150
|
+
}
|
|
100
151
|
.post + .post { border-block-start: 1px solid var(--border); }
|
|
101
152
|
|
|
102
153
|
.trow { display: flex; gap: 12px; }
|