@usableapp/cardds 0.7.173 → 0.7.174
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/CHANGELOG.md +9 -0
- package/css/card.css +4 -0
- package/dist/cardds.css +4 -0
- package/dist/cards/Card.d.ts +1 -1
- package/dist/cards/Card.js +1 -1
- package/dist/catalog.json +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
> For: a project that consumes `@usableapp/cardds` and its AI — what changed between versions, written as before → after, so a screen can be brought up to date without reading the source. Newest first. A consumer never edits cardds; if something here leaves you without a way to do what you did before, report the gap. Each release section after 0.7.97 carries one `Components:` line, written by `node scripts/components-changed.mjs <previous tag>`: the components the release changed, or `all` when a file changed that any component can read (a token, the build), or `none`; check only the screens that import those.
|
|
4
4
|
|
|
5
|
+
## 0.7.174 — 2026-10-30
|
|
6
|
+
|
|
7
|
+
A foldable `Card`'s chevron stands on the middle of the whole head.
|
|
8
|
+
|
|
9
|
+
Components: Card
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
- **`Card fold` chevron** (Lh 2026-10-30): before, the chevron down was a head end like the others, so in a head of more than one line it stood on the title's first line, above the head's middle. After, it is centred on the vertical middle of the whole head, one line or many, with or without a circle around it; it turns up around the same centre while open. The other ends (pins, buttons) keep the title's first line. No new knob.
|
|
13
|
+
|
|
5
14
|
## 0.7.173 — 2026-10-29
|
|
6
15
|
|
|
7
16
|
A round button's icon is 15% smaller, and a StackSheet's tabs stand further in from the edge with more room between them.
|
package/css/card.css
CHANGED
|
@@ -334,6 +334,10 @@
|
|
|
334
334
|
<article class="card card--folds is-folded"><div class="head" id="…">…</div><button class="card__open" aria-expanded="false" aria-controls="…r"></button>
|
|
335
335
|
<div class="card__more" id="…r" inert><div class="card__rest">content · <div class="foot">…</div></div></div></article> */
|
|
336
336
|
.card--folds { row-gap: 0; }
|
|
337
|
+
.card--folds > .head { position: relative; }
|
|
338
|
+
.card--folds > .head.head:has(> .line-ends) > .line-ends { position: static; } /* (.head twice: to outrank parts.css's led-line rule) so the chevron below measures the head, not the ends' box */
|
|
339
|
+
.card__fold { display: block; flex: none; width: var(--icon-sm-size, var(--icon-sm)); height: var(--icon-sm-size, var(--icon-sm)); } /* the chevron's room in the ends (and in their unseen copy); the glyph itself stands on the head's middle, its box centred on the whole head's vertical centre, one line or many, with or without a circle (Lh 2026-10-30) */
|
|
340
|
+
.card__fold > .icon { position: absolute; inset-inline-end: 0; top: 50%; --icon-shift: 0 -50%; }
|
|
337
341
|
.card__chevron { --icon-motion: rotate var(--motion-quick) var(--ease); } /* the card's own chevron, the head's last end: down while folded, turned up while open (as a Banner's) */
|
|
338
342
|
.card--folds:not(.is-folded) .card__chevron { --icon-turn: 180deg; }
|
|
339
343
|
.card__open { position: absolute; inset: 0; width: var(--px); height: var(--px); padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); }
|
package/dist/cardds.css
CHANGED
|
@@ -1394,6 +1394,10 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
1394
1394
|
<article class="card card--folds is-folded"><div class="head" id="…">…</div><button class="card__open" aria-expanded="false" aria-controls="…r"></button>
|
|
1395
1395
|
<div class="card__more" id="…r" inert><div class="card__rest">content · <div class="foot">…</div></div></div></article> */
|
|
1396
1396
|
.card--folds { row-gap: 0; }
|
|
1397
|
+
.card--folds > .head { position: relative; }
|
|
1398
|
+
.card--folds > .head.head:has(> .line-ends) > .line-ends { position: static; } /* (.head twice: to outrank parts.css's led-line rule) so the chevron below measures the head, not the ends' box */
|
|
1399
|
+
.card__fold { display: block; flex: none; width: var(--icon-sm-size, var(--icon-sm)); height: var(--icon-sm-size, var(--icon-sm)); } /* the chevron's room in the ends (and in their unseen copy); the glyph itself stands on the head's middle, its box centred on the whole head's vertical centre, one line or many, with or without a circle (Lh 2026-10-30) */
|
|
1400
|
+
.card__fold > .icon { position: absolute; inset-inline-end: 0; top: 50%; --icon-shift: 0 -50%; }
|
|
1397
1401
|
.card__chevron { --icon-motion: rotate var(--motion-quick) var(--ease); } /* the card's own chevron, the head's last end: down while folded, turned up while open (as a Banner's) */
|
|
1398
1402
|
.card--folds:not(.is-folded) .card__chevron { --icon-turn: 180deg; }
|
|
1399
1403
|
.card__open { position: absolute; inset: 0; width: var(--px); height: var(--px); padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); }
|
package/dist/cards/Card.d.ts
CHANGED
|
@@ -82,7 +82,7 @@ export interface CardProps extends ComponentProps<'article'> {
|
|
|
82
82
|
removeLabel?: string;
|
|
83
83
|
/** THE FOLD — the card can fold to its head: folded, only its `Head` shows; a tap on the head (not on a control in it) opens the rest
|
|
84
84
|
* (the content and the `Foot`), another folds it again. The rest opens and folds as a grid row, nothing jumps; folded it is `inert`.
|
|
85
|
-
* The card draws its own chevron down as the head's last `end` (after the app's own ends), turned up while open, as a Banner's.
|
|
85
|
+
* The card draws its own chevron down as the head's last `end` (after the app's own ends), turned up while open, as a Banner's; it stands on the middle of the WHOLE head, not on the title's first line as the other ends do.
|
|
86
86
|
* The keyboard and a screen reader meet ONE unseen button after the head, named by the head (or `openLabel`), that says open or folded.
|
|
87
87
|
* The card finds its `Head` by type, as a two-faced card does. Not on a `row`, `sm`, `stack`, `paper="bands"` card, nor with `back` or `onPress`:
|
|
88
88
|
* there it is ignored. A folding card is never pressed whole (the head is its press). Knob: none — the motion is the sheet's (`--motion-sheet`) */
|
package/dist/cards/Card.js
CHANGED
|
@@ -153,7 +153,7 @@ export function Card({ tone, paper, sm, row, cover, fold, centre, wide, band, as
|
|
|
153
153
|
if (folding) {
|
|
154
154
|
const headId = headKid.props.id ?? `${foldId}h`;
|
|
155
155
|
const rest = kids.filter((c) => c !== headKid);
|
|
156
|
-
return createElement(as, props, inner(_jsxs(_Fragment, { children: [cloneElement(headKid, { id: headId, end: _jsxs(_Fragment, { children: [headKid.props.end, _jsx(Icon, { name: "chevron-down", size: "sm", className: "card__chevron" })] }) }), _jsx("button", { type: "button", className: "card__open", "aria-expanded": opened, "aria-controls": `${foldId}r`, ...(openLabel ? { 'aria-label': openLabel } : { 'aria-labelledby': headId }), onClick: () => askOpen(!opened) }), _jsx("div", { className: "card__more", id: `${foldId}r`, inert: folded, children: _jsx("div", { className: "card__rest", children: rest }) })] })));
|
|
156
|
+
return createElement(as, props, inner(_jsxs(_Fragment, { children: [cloneElement(headKid, { id: headId, end: _jsxs(_Fragment, { children: [headKid.props.end, _jsx("span", { className: "card__fold", children: _jsx(Icon, { name: "chevron-down", size: "sm", className: "card__chevron" }) })] }) }), _jsx("button", { type: "button", className: "card__open", "aria-expanded": opened, "aria-controls": `${foldId}r`, ...(openLabel ? { 'aria-label': openLabel } : { 'aria-labelledby': headId }), onClick: () => askOpen(!opened) }), _jsx("div", { className: "card__more", id: `${foldId}r`, inert: folded, children: _jsx("div", { className: "card__rest", children: rest }) })] })));
|
|
157
157
|
}
|
|
158
158
|
if (turns) {
|
|
159
159
|
const ownHeadKid = kids.find((c) => isValidElement(c) && c.type === Head);
|