@usableapp/cardds 0.7.177 → 0.7.179

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.
Files changed (56) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/css/actions.css +11 -8
  3. package/css/base.css +13 -2
  4. package/css/card.css +39 -7
  5. package/css/layover.css +87 -10
  6. package/css/lists.css +69 -3
  7. package/css/media.css +33 -0
  8. package/css/palette.css +7 -0
  9. package/css/parts.css +27 -1
  10. package/css/tokens.css +9 -2
  11. package/dist/actions/Btn.d.ts +6 -2
  12. package/dist/actions/Btn.js +5 -2
  13. package/dist/cardds.css +295 -33
  14. package/dist/cards/CardParts.d.ts +12 -5
  15. package/dist/cards/CardParts.js +8 -7
  16. package/dist/cards/FeedPost.d.ts +31 -0
  17. package/dist/cards/FeedPost.js +14 -0
  18. package/dist/cards/inkGrounds.js +1 -1
  19. package/dist/catalog.json +1 -1
  20. package/dist/index.d.ts +5 -0
  21. package/dist/index.js +5 -0
  22. package/dist/layover/Popup.d.ts +23 -0
  23. package/dist/layover/Popup.js +15 -0
  24. package/dist/lists/Bubble.d.ts +25 -6
  25. package/dist/lists/Bubble.js +17 -8
  26. package/dist/lists/Row.d.ts +19 -4
  27. package/dist/lists/Row.js +8 -6
  28. package/dist/media/Mosaic.d.ts +4 -3
  29. package/dist/media/Mosaic.js +8 -4
  30. package/dist/media/Thumb.d.ts +14 -0
  31. package/dist/media/Thumb.js +12 -0
  32. package/dist/parts/Foot.d.ts +7 -2
  33. package/dist/parts/Foot.js +4 -3
  34. package/dist/parts/Lead.d.ts +7 -1
  35. package/dist/parts/Lead.js +3 -2
  36. package/dist/scaffold/Centre.d.ts +1 -1
  37. package/dist/scaffold/Centre.js +1 -1
  38. package/dist/scaffold/Panes.d.ts +1 -0
  39. package/dist/scaffold/Panes.js +1 -0
  40. package/dist/sheets/Modal.d.ts +1 -1
  41. package/dist/sheets/Modal.js +1 -1
  42. package/dist/templates/Splash.d.ts +1 -1
  43. package/dist/templates/Splash.js +1 -1
  44. package/dist/type/Phrase.d.ts +9 -0
  45. package/dist/type/Phrase.js +11 -0
  46. package/dist/type/Strong.d.ts +7 -0
  47. package/dist/type/Strong.js +9 -0
  48. package/dist/type/Text.d.ts +5 -1
  49. package/dist/type/Text.js +7 -3
  50. package/dist/type/icons.d.ts +1 -1
  51. package/dist/type/icons.js +2 -2
  52. package/docs/reference.md +101 -4
  53. package/icons.svg +1 -0
  54. package/lib/catalog.mjs +1 -1
  55. package/lint/rules.mjs +2 -2
  56. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -6,6 +6,51 @@
6
6
 
7
7
  ## ยังไม่ปล่อย
8
8
 
9
+ ## 0.7.179 — 2026-11-19
10
+
11
+ A notification can be one line of words, a `Bubble` can quote the message it answers, a `Mosaic` takes 2 to 10 photos, a centred box stands by its own 40% point, and `Thumb` is new.
12
+
13
+ Components: all
14
+
15
+ ### Added
16
+ - **`Mosaic` of 2 to 10 photos, `CardMedia full`, `Panes` as a photo slide show** (cardds#226): before, `Mosaic` took exactly three photos (one big left, two small right), a rounded full-width picture stood only inside a card (on a full screen an app put a bare `Placeholder` or `img`), and `Panes` was written for "a few panes" of a card or a sheet. After: `<Mosaic>` takes 2 photos (side by side, equally tall), 3 (as before, unchanged) or 4 to 10 (the first three as before, the small lower one darkened with `+n`, n the photos not shown; the others are not drawn; the scrim twice so the number holds AA over any photo; knobs `--mosaic-more-bg`, `--mosaic-more-ink`, `--mosaic-more-font`); `<CardMedia full>` is the rounded full-width picture outside a card, in a `Page`: corner `--r-media`, the picture's own ratio, one taller than `--card-media-max-ratio` (height ÷ width, default 1.25, 4:5) cut at its middle; `<Panes>` in a `Page` with a `<Pane><CardMedia full>…</CardMedia></Pane>` per photo is a slide show of up to 10, the dots on one line at 375px (no code change in `Panes`; its JSDoc and the reference say so). Stories `Mosaic · Two` · `Three` · `Seven`, `CardMedia · FullInAPage`, `Panes · PhotoSlides`; `Mosaic · Alone` and the other existing stories unchanged.
17
+ - **A notification of one line of words: `Row leadLines`, `Strong`, `Text corner`** (cardds#229): before, a notification made of one `Text caption` could not be built from cardds: a `Row` lead had one size (`--stamp-sm-size` / `--lead-size`, one tap), so a stamp could not stand as tall as three lines of words; words could not be made heavy inside a text (an app cannot write its own `<strong>`); a time put as the `End` of a `Row` took a whole column from the words. After: `<Row leadLines={3} leadText="caption" unread><AvatarStack><Stamp bare … /></AvatarStack><Text level="caption" lines={3} corner="5 min" grow><Strong>Auntie Sri</Strong> • thank you for…</Text></Row>`. `Row leadLines` (1 to 3; `leadText` `body` (default) or `caption`): the lead is as tall as that many lines of the level's line height, a `Stamp` at its 4:5 shape, a `Lead` a square as wide as that stamp, in the middle; no px. `Strong`: weight `--strong-weight` (default `--fw-bold`), size, ink and line the text's. `Text corner`: one short word at the top end in the muted ink (`--text-corner-ink`) at the text's size, `--text-corner-gap` (`--sp-2`) from the words; the first line runs round it, the rest is full width, and with `lines` the cut counts the visible lines only. Stories `Row · Notifications`, `Row · LeadLines`, `Strong`, `Text · CornerWord`, `Text · CornerOneLine`.
18
+ - **`Thumb` and `ThumbGrid`** (cardds#232): before, a post desk showing the photos a member had added used a `Lead` holding an image icon with `--lead-size` set by the app (`Lead` is a box for an icon, `Avatar` is round, `Placeholder` a tall box), and had no way to lay them five to a row. After: `<ThumbGrid><Thumb src={url} label="Photo 1, tap to remove" onClick={ask} />…</ThumbGrid>`. A `Thumb` is one small square photo that is a button: only the photo (`object-fit: cover`), corner `--thumb-radius` (default `--r-control`), no words, the whole square pressed (`label` = its accessible name, `onClick` the app's), the tile's give and the focus ring; without `src` it holds a `Placeholder`'s crossed box. A `ThumbGrid` is `--thumb-grid-cols` (default 5) squares to a row, as wide as the box it stands in, `--thumb-grid-gap` (default `--sp-2`) apart: ten photos are two rows, and in a `Modal` at 375px each is over `--tap-sm`. Stories `Thumb · Default`, `ThreeInAModal`, `TenInAModal`; no existing story changes.
19
+ - **`Bubble quote`** (cardds#227): before, a bubble answering another message had nowhere for the line of the message answered; the app put a `Text caption muted lines={1}` inside it, with no rule at its start. After: `<Bubble quote="Noi: Could I have a cutting?">Yes, I am home all day</Bubble>` puts that line at the top inside the bubble, over the words: one line cut with "…", a rule at its start like a `MessageBar`'s `quote`, `caption` size, in the muted ink of the bubble's ground (a theirs and a mine bubble alike). `onClick`, `href` and `highlighted` work as before and take the line with them. Knobs `--bubble-quote-ink`, `--bubble-quote-rule-ink` (default `var(--card-muted)`). A mine bubble now declares its fill's side (`--dark: var(--accent-dark)`), so what reads the ground's side inside it (`--card-muted`, `--card-ink`, `--accent-ink`, the signals) follows the accent's side, as it did not before; its words keep `--on-accent`. Story `Bubble · Quote`; existing stories unchanged.
20
+ - **`FeedPost`, `CardList thin`, a done `Btn` (`aria-disabled`)** (cardds#213): before, a post in a feed was built by hand from `Card` + `Head` + `MediaBeside` + `Foot` and three `Btn`s: a post stood about 255px tall on a 390 × 844 phone (padding 20, corner 41.6, gap 20 — the card knobs live on `:root`, so a feed could not be thinner alone), the photo was a 72px square beside the words, and the like / comment / pass-on row was three framed buttons across the card. After, all three are opt-in and every existing screen is unchanged:
21
+ - `<CardList thin>`: every `Card` in the list — posts and plain cards alike — has padding `--sp-4`, corner `--r-base`, its parts `--sp-5` apart; the cards stay `--card-list-gap` (`--sp-3`) apart. A card outside the list, and a `Thread` between its cards, do not change. Knobs `--card-list-thin-pad`, `--card-list-thin-gap`, `--card-list-thin-radius`.
22
+ - `<FeedPost lead={<Avatar>…</Avatar>} author="Somsri" time="40 min" via="Ton passed it on" end={<Btn shape="round" size="sm" icon="flag" label="Report" />} media={<img …/>} actions={<BtnGroup …/>} onPress={open} pressLabel="Open the post"><Text level="body" expand>…</Text></FeedPost>`: one post, a card of its own — the author bold and ` · time` small on one line, `via` under them (head lines `--sp-1` apart), the words, the picture FULL WIDTH at its own shape (no taller than `--feed-post-media-ratio`, default `4 / 3`, a taller one cut in its middle; `4 / 5` on a sheet), the moves; parts `--sp-5` apart (`--feed-post-gap`); `end` is the `Head`'s end (the member's own post has none); pressed whole with `onPress` while its buttons keep their own press.
23
+ - The moves are the existing `BtnGroup` frame: a round `Btn` per share, an icon and the number as its child word (none at 0), `select="many"` + `value` for the liked share (filled), no `value` for a plain command. New: `<Btn aria-disabled>` is a move done already — it fades (`--off`), takes no give and no dim, never calls `onClick` and never switches a `BtnGroup`'s `value`, but stays focusable and read (before, `aria-disabled` on a `Btn` faded it and blocked the give, yet `onClick` still ran and a frame's share still dimmed under the finger). A move done STAYS in `value` with `aria-disabled` (Lh 2026-11-18): the share is the pressed fill, faded.
24
+ - A `flag` icon joins the stock set (Lucide's): the report flag at a post's head, `<Btn shape="round" size="sm" icon="flag" label="Report" />` — before, a project registered its own with `registerIcons`.
25
+ Stories `FeedPost · Feed`, `Words`, `Photo`, `TallPhoto`, `PassedOn`, `BtnGroup · PostRow`, `PostRowControlled`; existing stories unchanged.
26
+ - **`Row todo` and `Row done fullInk`** (cardds#223): before, a checklist built from `Row`s showed the finished lines with a tick and faded words, and the lines still to do with nothing where the tick goes, so they looked like plain rows: nobody saw they could be pressed, and the weight was upside down (done faded, open dark). After, `<Row todo as="a" href="…">` draws an empty dashed circle where the tick would be (the same size, `--row-done-size`) and fades its title and second line (`--row-todo-ink`, default 40% of the card's ink; the ring `--row-todo-ring`); the whole row is the press target, and the app's words name it for a screen reader. `<Row done fullInk>` keeps the card's ink beside the tick, so the finished lines stand out against the faded ones; a `done` row without `fullInk` is as before. Stories `Row · Todo`, `Row · Controlled`.
27
+ - **`Phrase`** (cardds#224): before, Thai words after a `Chip` in a sentence were cut wherever the line ran out (a `ModalAsk` caption read "…ของเพื่อนบ้านทุก" then "คน" alone on the next line), and a project wrote its own `white-space: nowrap`. After, `<Phrase>ของเพื่อนบ้านทุกคน</Phrase>` keeps its words on one line: the line breaks before it or after it, never inside. Inline, in any `Text` level, a `ModalAsk` `caption` and beside a `Chip`; a phrase longer than the room it has breaks inside itself, never out of its box. Story `Modal · PhraseAfterChip`.
28
+ - **`Bubble metaAbove` / `lead` / `action`, `Thread` room in a feed, `Foot layer`** (cardds#214): before, a `Bubble` could only put its caption (`author`, `day`, `meta`) UNDER the message, so a list of comments from several people was read message first and writer after; a right-hand (own) bubble had no place for its time over it or for a button beside it; a `Thread` standing alone between cards in a feed had only the cards' gap (the bubble crowded its neighbour card, the room piled up under it); and a sheet's foot (a `MessageBar` under comments) was the sheet's own colour, the same as the comments scrolling behind it, with no knob for another. After, all three are opt-in and every existing screen is unchanged:
29
+ - `<Bubble metaAbove author lead={<AvatarStack><Stamp bare … /></AvatarStack>} meta="35 min">`: the caption line stands over the message on one line — `lead` (the picture, at its own size) · `author` in bold · "·" · the time small; the bubble under it from the start edge, as wide as its words up to `--bubble-max-w`, `--sp-2` below the line. The name is cut with "…" before the line wraps. `lead` and `author` show where the Thread's `authors` says (`authors="every"` for a comment list). Mine (`side="right"`): the time alone, over the bubble at the right. Knobs `--bubble-meta-above-gap`, `--bubble-lead-gap`, `--bubble-author-font`, `--bubble-author-ink`. Without `metaAbove` nothing moves.
30
+ - `<Bubble side="right" metaAbove meta="12 min" action={<Btn shape="round" size="sm" icon="trash" label="Delete" />}>`: one round `Btn` of the app beside the message, centred on its height — after a left bubble, before a right one — inside the same 75% cap; knob `--bubble-action-gap` (`--sp-2`). Not with `href` or `onClick` (a button in a link): ignored, with a warning; use a `Row` there.
31
+ - A `Thread` that is a direct child of a `CardList` has the same room over it and under it, `--thread-room-size` (default `--sp-4`); before it had only the list's gap over it and `--thread-end-size` under it. A `Thread` anywhere else is as before; pass `jumpLabel={false}` in a feed.
32
+ - `<Foot layer>` in a `Sheet`: the foot's strip gets a ground of its own, edge to edge, a rule over it — the sheet's colour a little darker (`--foot-layer-bg`, default 8% of the dark ink over `--card-bg`; `--foot-layer-rule-ink`, default `--hairline`). The strip is the same size, so the body still stops above it, and a `MessageBar`'s box on it is still the paper. A `Foot` without `layer` is as before.
33
+ Stories `Bubble · Comments`, `Bubble · InFeed`; existing stories unchanged.
34
+
35
+ ### Changed
36
+ - **The line under a `Rows joined` row is thinner and fainter** (cardds#229, Lh 2026-11-18: "the dark line is too strong"): before, a border of `--border-w` (1.5) at `--hairline` (18% of the ink); after, `--rows-joined-border-w` (new knob, default `--px`, 1) at `--rows-joined-border` (default the new token `--hairline-soft`, 10% of the ink), about half as strong. A project that set `--rows-joined-border` keeps its colour; `--rows-joined-border-w: var(--border-w)` and `--rows-joined-border: var(--hairline)` are the old look. Every `Popup` and every `Rows joined` story shifts.
37
+ - **A centred box stands by its own 40% point** (cardds#231, Lh 2026-11-18): before, `Modal` stood with its MIDDLE at 50% of the stage, and `Card centre`, `Centre` on a `Screen fill` and the `Splash` group had their middle (50% of the box) on `--screen-centre` (40% of the screen): all four sat lower than the rule "the point 40% down the card is on the point 40% down the screen". After: the box's own 40% point is on `--screen-centre` in all four (`top: var(--screen-centre)` and `translate: 0 var(--centre-lift)`), so a `Card centre`, a `Centre` and a `Splash` group sit a tenth of their height LOWER than before (a box of 300: 30 lower) and a `Modal` sits higher (its middle goes from 50% of the stage to 40% plus a tenth of its height). New tokens `--centre-at` (0.4, the one number: `--screen-centre` is `calc(var(--centre-at) * 100%)`) and `--centre-lift` (`calc(-1 * var(--screen-centre))`). The `Modal` keeps that point while it drops in and while its drawer comes out (the box grows about it). The cap of each is now the room above the line / 0.4 or the room below it (`--bar-reserve`) / 0.6, whichever is less (the `Modal`'s was the stage less `--sp-5` on each side; it now also stays under a top bar, `--_top`): a taller box scrolls its `Body` (a `Modal`) or itself (the others); a `Modal`'s drawer keeps its height. A project's `--screen-centre: 45%` becomes `--centre-at: 0.45`. Story `Modal · TallUnderTopBar`; every `Modal`, `Card centre`, `Centre` and `Splash` story shifts.
38
+ - **`Popup` stands narrower than the cards under it** (cardds#222): before, a popup stood `--popup-margin` (`--sp-3`, 12) in from the screen's edge on both sides, wider than the cards of the page (16 in), so it read as one sheet with the card under it. After, it stands `--sp-2` in from the card's edge on the button's side and `--sp-6` in on the far side, so the card's edge shows on both (375 wide, `end`: popup x 40–351 over cards at 16–359; without `end` the mirror), anchored to the button or hung under the top bar (iOS before 26) alike; it is still at most `--popup-w` wide on a wider screen. A project that sets `--popup-margin` gets that one value for both distances (anchored, it now also moves the near edge that many in from the button's edge, where before it only limited the width); the margin under the popup is unchanged. Only the `Popup` stories change.
39
+
40
+ ## 0.7.178 — 2026-11-17
41
+
42
+ `Popup` (a panel under a button) is new, a `Row` can be `unread`, `Rows` can be `joined`, and a `Lead` takes a `tone`.
43
+
44
+ Components: all
45
+
46
+ ### Added
47
+ - **`Popup`, `Row unread`, `Rows joined`, `Lead tone`** (cardds#219): before, a list read from a bell (notifications) could not be built from cardds: a `Menu popover` takes only `MenuItem`s (no head, no `Rows`, no scrolling head), a `Row` had no unread fill, `Rows` drew a gap and a hairline only BETWEEN rows, and a `Lead` was an outline in one colour. After, all four are opt-in and every existing screen is unchanged:
48
+ - `<Popup id="inbox" end title meta action={<Btn size="sm">…</Btn>}>` is a native popover panel under the button carrying `popoverTarget="inbox"` (tap outside or Esc closes): a head (title, a second line, ONE Btn at the right, sticky) over its children, flush to its left and right edges (`Rows joined`). `end` (a button at the screen's right) makes its right edge the button's and it grows leftwards; it is never wider than the room it has less `--popup-margin` each side, at most `--popup-w`, and scrolls inside itself when the room under the button is short (`--popup-max-h`). Knobs `--popup-margin`, `--popup-w`, `--popup-max-h`, `--popup-bg`, `--popup-border`, `--popup-radius`, `--popup-shadow`, `--popup-pad-x`, `--popup-pad-y`, `--popup-head-gap`.
49
+ - `<Row unread>`: a very light grey fill over the whole row, the new token `--unread-bg` (4% of the ink over any ground; knob `--row-unread-bg`); a screen reader hears "unread" (`unreadLabel`).
50
+ - `<Rows joined>`: no gap, every row a band edge to edge with its own padding and a border under it, so rows with a fill join. Knobs `--rows-joined-pad-x`, `--rows-joined-pad-y`, `--rows-joined-border`.
51
+ - `<Lead icon tone="blue|green|amber|red|pink|violet">`: a filled box, a white icon on a colour of cardds's set (new tokens `--tone-blue` … `--tone-violet`; in the wireframe six greys). The icon holds 4.5:1 or more in every shipped palette (lowest 4.74, blue on clay). Knobs `--lead-bg`, `--lead-ink`.
52
+ Stories `Popup · UnderABell`, `Popup · AtTheStart`, `Popup · LongList`, `Lead · Tones`, `Row · Unread`; the Palette page lists the tones and `--unread-bg`.
53
+
9
54
  ## 0.7.177 — 2026-11-17
10
55
 
11
56
  `AppBar` holds two buttons and a round `Btn` shows a count, `Chip` takes a signal `tone`, `Head variant="date"` takes two chip rows, `NoteRows` and `Was` (a struck-through old value) are new, and a `Modal` mounted closed draws nothing.
package/css/actions.css CHANGED
@@ -135,7 +135,9 @@
135
135
  .icon-btn-line__words { font: var(--type-label); text-align: center; min-width: 0; }
136
136
  .icon-btn-line > .icon-btn-group--form { margin-inline: 0; }
137
137
  .icon-btn-group > .icon-btn[aria-pressed="true"] { background: var(--icon-btn-group-on-bg, var(--accent)); color: var(--icon-btn-group-on-ink, var(--on-accent)); } /* `select`: a pressed button STAYS filled (Lh 2026-09-29) */
138
- .icon-btn-group > .icon-btn:active:not(:disabled) { scale: 1; opacity: var(--press-dim); } /* a part of one frame DIMS, it never shrinks inside it */
138
+ .icon-btn-group > .icon-btn:active:not(:disabled, [aria-disabled="true"]) { scale: 1; opacity: var(--press-dim); } /* a part of one frame DIMS, it never shrinks inside it */
139
+ /* a share DONE ALREADY (`Btn aria-disabled`, cardds#213: a post passed on) fades with the press list's `--off` and takes no dim; pressed and done (its
140
+ value still on) it is the pressed fill, faded */
139
141
 
140
142
  /* fab: the square floating action, bottom-right of a stage or screen */
141
143
  .fab { width: var(--fab); height: var(--fab); border-radius: var(--r-card); position: absolute; right: var(--sp-4); bottom: calc(var(--sp-5) + var(--bar-h) + var(--sp-3) + var(--safe-bottom)); box-shadow: var(--shadow-float); z-index: var(--z-fab); }
@@ -500,18 +502,19 @@
500
502
  dims only when the finger is on the card itself, never while it is on one of those.
501
503
  .t-expand--more (Lh 2026-10-25) = a `Text expand` that does not fit: the whole box opens or folds. It is WORDS, so it neither
502
504
  dims nor gives: its ink never changes under the finger (Lh 2026-10-25), the opening is the answer. Pointer only (below).
505
+ .thumb (cardds#232) = a `Thumb`, a small square photo that is a button: it GIVES (scale) like a tile, and has the focus ring.
503
506
  .bubble--press (Lh 2026-10-28) = a chat `Bubble` that is a link (`href`) or pressed (`onClick`): a message is as wide as a row, so it DIMS.
504
507
  .link-block (Lh 2026-10-28) = a `LinkBlock`, a few pieces of a card's content as one link: as wide as the card, it DIMS.
505
508
  .card--folds > .head (Lh 2026-10-29) = the head of a `Card folds`: a tap opens or folds the card, so it DIMS (pointer and :active only —
506
509
  the focus ring is the card's, from its unseen open button, card.css). A control in the head keeps its own press. */
507
510
  :where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day, .calendar__pick,
508
511
  .float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
509
- a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .map-pick, .count-in__cancel) {
512
+ a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .map-pick, .count-in__cancel, .thumb) {
510
513
  cursor: pointer;
511
514
  touch-action: manipulation;
512
515
  transition: scale var(--motion-press) var(--ease-out);
513
516
  }
514
- :where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .card--press, .feed-card--small, .card--folds > .head, .toggle-field, .post-box__edge, .bubble--press, .link-block) {
517
+ :where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .card--press, .feed-card--small, .card--folds > .head, .toggle-field, .post-box__edge, .bubble--press, .link-block, .row--todo) {
515
518
  cursor: pointer;
516
519
  touch-action: manipulation;
517
520
  transition: opacity var(--motion-press) var(--ease-out);
@@ -526,8 +529,8 @@
526
529
  }
527
530
  :where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day, .calendar__pick,
528
531
  .float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
529
- a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .map-pick):active:not(:disabled, [aria-disabled="true"], :has(:disabled)) { scale: var(--press-scale); }
530
- :where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .card--press, .feed-card--small, .card--folds > .head, .toggle-field, .post-box__edge, .bubble--press, .link-block):active:not([aria-disabled="true"], :has(:disabled)) { opacity: var(--press-dim); }
532
+ a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .map-pick, .thumb):active:not(:disabled, [aria-disabled="true"], :has(:disabled)) { scale: var(--press-scale); }
533
+ :where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .card--press, .feed-card--small, .card--folds > .head, .toggle-field, .post-box__edge, .bubble--press, .link-block, .row--todo):active:not([aria-disabled="true"], :has(:disabled)) { opacity: var(--press-dim); }
531
534
  .card--press:active:has(:is(a[href], button, [role=button], input, select, textarea, summary):active) { opacity: 1; } /* the finger is on a link or a button inside: that one answers, the card stays */
532
535
  .card--folds > .head:active:has(:is(a[href], button, [role=button], input, select, textarea, summary):active) { opacity: 1; } /* a button in a folding card's head answers itself, the head stays */
533
536
  /* SHADE — what has something BEHIND it (a peeked sheet over the pile, a postcard's face over its back, a post letter's sheet over the other) must not turn see-through:
@@ -537,17 +540,17 @@
537
540
  /* the focus ring: on the control, or on the label that wraps a hidden input (chip, tile, file button, a row that is a label, a card that is a label round its radio) */
538
541
  :where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day, .calendar__pick,
539
542
  .float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
540
- a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove):focus-visible,
543
+ a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .thumb):focus-visible,
541
544
  :where(.chip--pick, .tile--pick, label.btn, label.row, .toggle-field):has(:focus-visible), :where(label.card:has(> input[type="radio"]:focus-visible)) { outline: var(--focus); outline-offset: var(--sp-1); }
542
545
  :where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .feed-card--small, .toggle-field, .post-box__edge, .t-expand--more, .bubble--press, .link-block):not(label, .toggle-field):focus-visible { outline: var(--focus); outline-offset: var(--sp-1); }
543
546
  /* disabled: no pointer anywhere; a control fades (a link and a row keep their own muted look) */
544
547
  :where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day, .calendar__pick,
545
548
  .float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
546
- a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .toggle-field, .post-box__edge):is(:disabled, [aria-disabled="true"]),
549
+ a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .thumb, a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .toggle-field, .post-box__edge):is(:disabled, [aria-disabled="true"]),
547
550
  :where(.chip--pick, .tile--pick, .mood__opt, .toggle-field, label.btn, label.row):has(:disabled) { cursor: default; }
548
551
  :where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day, .calendar__pick,
549
552
  .float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
550
- a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove):not(.link):is(:disabled, [aria-disabled="true"]),
553
+ a.avatar, button.avatar, .menu__item, button.snackbar__body, .stamp--tap, button.stamp-cell, button.stamp-place, .post-letter__turn, .post-desk__slot, .post-desk__pick, .post-desk__reach, .stamp-on__remove, .thumb):not(.link):is(:disabled, [aria-disabled="true"]),
551
554
  :where(.chip--pick, .tile--pick, .mood__opt, .toggle-field, label.btn):has(:disabled) { opacity: var(--off); }
552
555
  .sheet-stack--tap > .card > .head > :is(h1, h2, h3):focus-visible { outline: var(--focus); outline-offset: var(--sp-1); } /* the keyboard's way into a stack sheet */
553
556
  @media (prefers-reduced-motion: reduce) { :root { --press-scale: 1; } } /* the give goes; the dim, the shade and the focus ring stay */
package/css/base.css CHANGED
@@ -188,6 +188,14 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
188
188
 
189
189
  .t-muted { color: var(--card-muted); } /* the muted words of whatever it stands on: the screen, a card of any tone, a drawer */
190
190
  .t-caps { text-transform: uppercase; }
191
+ /* ---- strong: some words heavier INSIDE running text (cardds#229) ----
192
+ <p class="t-caption"><strong class="strong">Noi</strong> • asked for a ride</p> Weight only: the size, ink and line are the text's. */
193
+ .strong { font-weight: var(--strong-weight, var(--fw-bold)); }
194
+ /* ---- the corner word of a Text (cardds#229): one short word at the top end, the first line runs round it, the rest is full width ----
195
+ <span class="t-caption t-lines t-lines--3"><span class="t-corner-flow"><span class="t-corner">5 min</span>words…</span></span>
196
+ The flow is a block of its own: the cut (`-webkit-box`) turns its direct children into flex items, which ignore a float. */
197
+ .t-corner-flow { display: block; }
198
+ .t-corner { float: inline-end; margin-inline-start: var(--text-corner-gap, var(--sp-2)); color: var(--text-corner-ink, var(--card-muted)); }
191
199
  /* ---- mark: a highlighter stroke over a word INSIDE running text (a sender's name in a greeting) ----
192
200
  <p class="t-body"><mark class="mark">ธนาคารเวลา</mark> ส่งแสตมป์ดวงแรกให้คุณ</p>
193
201
  The words keep their ink and their size; the stroke is the signal washed thin, drawn as a pen would: unlike corners, the ink
@@ -210,6 +218,9 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
210
218
  .mark--warn { --_bg: color-mix(in srgb, var(--signal-warn) 30%, transparent); }
211
219
  .mark--error { --_bg: color-mix(in srgb, var(--signal-error) 30%, transparent); }
212
220
  .mark--info { --_bg: color-mix(in srgb, var(--signal-info) 30%, transparent); }
221
+ /* a phrase that is not split (Phrase, cardds#224): an inline-block is one unit, so the line breaks before it or after it, never inside it; sized to its own words,
222
+ and never wider than the box it stands in (a phrase longer than that breaks inside itself rather than run out of the box). Nothing is clipped or hidden */
223
+ .phrase { display: inline-block; max-width: 100%; overflow-wrap: anywhere; }
213
224
  .grow { flex: 1; min-width: 0; } /* the child that takes the remaining row space */
214
225
  /* read, not shown (Lh 2026-09-23): words a screen reader needs — a page's h1 the design leaves out — kept in the page, taking no room.
215
226
  The 1px is the one the platform needs to keep it in the accessibility tree, not a length of the design. */
@@ -285,10 +296,10 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
285
296
  .screen--fill > .screen__centre {
286
297
  position: absolute;
287
298
  top: var(--screen-centre);
288
- translate: 0 -50%;
299
+ translate: 0 var(--centre-lift); /* its own 40% point on --screen-centre, as a .card--centre (card.css) */
289
300
  /* the cap: as a .card--centre's (card.css, which says why) */
290
301
  --_lead: 0rem;
291
- max-height: calc(2 * min(var(--screen-centre) - var(--_lead) - var(--screen-gap), 100% - var(--screen-centre) - var(--bar-reserve)));
302
+ max-height: min((var(--screen-centre) - var(--_lead) - var(--screen-gap)) / var(--centre-at), (100% - var(--screen-centre) - var(--bar-reserve)) / (1 - var(--centre-at)));
292
303
  overflow-y: auto;
293
304
  overscroll-behavior: contain;
294
305
  }
package/css/card.css CHANGED
@@ -45,6 +45,11 @@
45
45
 
46
46
  .card__media { border-radius: var(--card-media-radius, var(--r-media)); overflow: hidden; position: relative; } /* relative: corner badges */
47
47
  .card__media > img { width: 100%; height: auto; object-fit: cover; }
48
+ /* a full-width picture outside a card (CardMedia full, cardds#226): the holder's width, the corner --r-media, the picture's own ratio — one taller than --card-media-max-ratio
49
+ (height ÷ width, default 1.25 = 4:5) is cut at its middle. The wrapper is the container the cap is measured in (cqw = its width) */
50
+ .card__media--full { container-type: inline-size; width: 100%; }
51
+ .card__media--full > img { display: block; max-height: calc(100cqw * var(--card-media-max-ratio, 1.25)); object-position: center; }
52
+ .card__media--full > .ph { min-height: 0; aspect-ratio: 4 / 3; border-radius: 0; }
48
53
  /* media beside (MediaBeside, Lh 2026-10-28): the words, and at their end a small square picture, the media's corner, cropped to fill it */
49
54
  .media-beside { display: grid; grid-template-columns: minmax(0, 1fr) var(--media-beside-size, calc(var(--tap) * 3 / 2)); gap: var(--media-beside-gap, var(--sp-3)); align-items: start; }
50
55
  .media-beside__words { display: grid; gap: var(--sp-1); min-width: 0; }
@@ -160,8 +165,10 @@
160
165
  Where the centre of a phone IS, to the person holding it: the bottom fifth is
161
166
  the thumb's — the bar, the controls — so what is meant to be read sits at the
162
167
  middle of the four fifths above it, --screen-centre (40%) down the screen, not
163
- at 50%. (Lh, 2026-09-10.) Any screen with one
164
- card and nothing else to read may.
168
+ at 50%. (Lh, 2026-09-10.) The card stands on that line by ITS OWN 40% point,
169
+ not its middle (Lh, 2026-11-18): the point 40% down the card is the point 40%
170
+ down the screen, so the card's middle is a tenth of its height under the
171
+ line, still over the screen's own middle (--centre-lift). Any screen with one card and nothing else to read may.
165
172
  <div class="screen screen--fill"><header class="topbar">…</header><article class="card card--centre">…</article></div>
166
173
  <div class="action-bar">…</div>
167
174
  The card hugs its words and keeps the screen's inset. It is capped so that it
@@ -170,14 +177,15 @@
170
177
  .card--centre {
171
178
  position: absolute;
172
179
  top: var(--screen-centre);
173
- translate: 0 -50%;
174
- /* the cap: twice the room above the centre (the title bar's height, when
175
- one is there, and the screen's gap), or twice the room below it (the
176
- bar's reserve) — whichever is less. --_lead is the title bar's height
180
+ translate: 0 var(--centre-lift);
181
+ /* the cap: the room above the centre (the title bar's height, when one is
182
+ there, and the screen's gap) is the card's 40% above its point, so the card
183
+ may be that room / 0.4 tall; the room below it (the bar's reserve) is its 60%,
184
+ so that room / 0.6 — whichever is less. --_lead is the title bar's height
177
185
  only on a screen that HAS one: without a .topbar/.appbar before it the
178
186
  block keeps that room (a card and its pager under it needs it on a short phone; Lh, 2026-09-11). */
179
187
  --_lead: 0rem;
180
- max-height: calc(2 * min(var(--screen-centre) - var(--_lead) - var(--screen-gap), 100% - var(--screen-centre) - var(--bar-reserve)));
188
+ max-height: min((var(--screen-centre) - var(--_lead) - var(--screen-gap)) / var(--centre-at), (100% - var(--screen-centre) - var(--bar-reserve)) / (1 - var(--centre-at)));
181
189
  overflow-y: auto;
182
190
  overscroll-behavior: contain;
183
191
  }
@@ -251,6 +259,14 @@
251
259
 
252
260
  /* ---- card list: rows, each row its own boundary ---- */
253
261
  .card-list { display: grid; gap: var(--card-list-gap, var(--sp-3)); }
262
+ /* thin (`CardList thin`, cardds#213, a feed — Lh 2026-11-17 "ก การ์ดบาง"): every card in the list thinner by its three rest values, set for the
263
+ list's cards alone (a card reads them as `--card-pad` / `--card-gap` / its corner, so its variants and parts follow); a card outside, and a
264
+ `Thread` standing between the cards, do not change */
265
+ .card-list--thin > .card {
266
+ --card-pad-rest: var(--card-list-thin-pad, var(--sp-4));
267
+ --card-gap-rest: var(--card-list-thin-gap, var(--sp-5));
268
+ --r-card: var(--card-list-thin-radius, var(--r-base));
269
+ }
254
270
 
255
271
  .card--row {
256
272
  border-radius: var(--card-row-radius, var(--r-card-row)); /* small: the big card's corner in proportion, not its size */
@@ -319,6 +335,22 @@
319
335
  .feed-card { row-gap: 0; }
320
336
  .feed-card > .head:has(> .t-caption) > .feed-card__lead { grid-row: span 2; }
321
337
  .feed-card__lead { display: grid; } /* placed by the head's align-items: top with a caption, middle without (parts.css) */ /* a Stamp here is the small one, 48 × 60 (stamp.css) */
338
+ /* FeedPost (cardds#213, Lh 2026-11-17 "ก การ์ดบาง"): ONE post in a feed — head · words · a picture full width · the moves (a BtnGroup frame).
339
+ GROUPS: the head's lines --sp-1 apart, the post's parts --sp-5 (the card's gap, so a thin CardList's cards and its posts read alike).
340
+ The head: the author bold in the label's size, ` · time` small and muted on the same line, how it came under them (the Head's meta).
341
+ The picture: full width at its own shape, cut in its middle past the tallest shape the post allows (width / height, 4 / 3; on a sheet
342
+ an app sets 4 / 5) — the box is a size container, so the cap is a share of its own width (cqi, iOS 16).
343
+ <article class="card feed-post"><div class="head"><span class="avatar">…</span><h2 class="words__title">Somsri<span class="feed-post__time"> · 40 min</span></h2>…</div>
344
+ <p class="t-body">…</p><div class="feed-post__media"><img …></div><div class="icon-btn-group" role="group">…</div></article> */
345
+ .feed-post { --card-gap: var(--feed-post-gap, var(--sp-5)); }
346
+ .feed-post > .head {
347
+ --head-row-gap: var(--sp-1);
348
+ --words-title-font: var(--fw-bold) var(--fs-label) / round(down, calc(var(--lh-label) * 1em), 1px) var(--face-label);
349
+ }
350
+ .feed-post__time { font: var(--type-caption); color: var(--card-muted); }
351
+ .feed-post__media { container-type: inline-size; border-radius: var(--r-media); overflow: hidden; }
352
+ .feed-post__media > * { display: block; width: 100%; max-height: calc(100cqi / (var(--feed-post-media-ratio, 4 / 3))); object-fit: cover; object-position: center; border-radius: inherit; }
353
+ .feed-post__media > img { height: auto; }
322
354
  /* FeedEnd (Lh 2026-10-29): the end of a feed — a drawn cat, its tail wagging, and a caption. Quiet: the ground's muted ink. */
323
355
  .feed-end { display: grid; justify-items: center; gap: var(--sp-2); padding-block: var(--sp-4); color: var(--feed-end-ink, var(--on-surface-muted)); text-align: center; }
324
356
  .feed-end__cat { width: var(--feed-end-size, var(--stamp)); height: auto; }
package/css/layover.css CHANGED
@@ -22,8 +22,8 @@
22
22
  1. the card drops in from above the stage to the screen's centre — its
23
23
  drawer still inside it, height 0: nothing of the ask shows yet
24
24
  2. the drawer comes out of the card's bottom edge while the lift moves
25
- up, both at once: the card grows from its centre, which never moves
26
- (the modal centres itself — absolute, margin auto; a growing card keeps its middle where it is)
25
+ up, both at once: the card grows about its 40% point, which never moves
26
+ (the modal stands itself on --screen-centre — absolute, margin auto; a growing card keeps that point where it is)
27
27
  Closing: <Modal open onClosed> — set open={false} and the Modal component plays the
28
28
  same animations in reverse (Animation.reverse() on each — nothing duplicated), then
29
29
  calls onClosed for the app to unmount the stage. Modal no longer knows its own
@@ -31,14 +31,16 @@
31
31
  sets open={false}).
32
32
  Reduced motion: the finished state, no beats; closing fires at once. */
33
33
  .modal {
34
- position: absolute; /* at the stage's centre, and kept there as it grows: its middle is pinned at 50% and */
35
- top: 50%; /* translate -50% of its OWN height re-centres it on every height. NOT inset 0 + margin auto + */
34
+ position: absolute; /* at the stage's centre, and kept there as it grows: its 40% point is pinned at --screen-centre and */
35
+ top: var(--screen-centre); /* translate -40% of its OWN height (--centre-lift) re-seats it on every height. NOT inset 0 + margin auto + */
36
36
  inset-inline: 0; /* align-self: center — Safari 18 ignores align-self on an absolute box in a block container, */
37
37
  margin-inline: auto; /* so the card stretched to the whole stage (iOS 18.6, Lh 2026-09-24); nor height: fit-content */
38
- translate: 0 -50%;
38
+ translate: 0 var(--centre-lift);
39
39
  width: calc(100% - 2 * var(--screen-pad));
40
40
  z-index: var(--z-over-2); /* over the dim stage's scrim (z 1) */
41
- max-height: calc(100cqh - 2 * var(--sp-5)); /* cqh: the stage (a size container) */
41
+ /* the cap, as a .card--centre's (card.css): its 40% above the point must clear the top bar's line (--_top) and the screen's gap, its 60% below
42
+ must stay out of the bar's room (--bar-reserve); past that the body scrolls (the drawer keeps its height). % of the stage: it is the box it stands in */
43
+ max-height: min((var(--screen-centre) - var(--_top, 0rem) - var(--screen-gap, var(--sp-5))) / var(--centre-at), (100% - var(--screen-centre) - var(--bar-reserve)) / (1 - var(--centre-at)));
42
44
  padding: 0; /* the parts pad themselves */
43
45
  border: 0; /* no frame on the modal (Lh 2026-09-16) — its edge is the shadow */
44
46
  display: flex; /* a column: the lift shrinks (and scrolls) under max-height, the drawer keeps its height. NOT a grid */
@@ -84,8 +86,8 @@
84
86
  .modal { animation: modal-drop calc(2 * var(--motion-sheet)) var(--ease) both; }
85
87
  .modal__drawer { animation: modal-open calc(2 * var(--motion-sheet)) var(--ease) both; }
86
88
  @keyframes modal-drop {
87
- 0% { translate: 0 calc(-50% - 100cqh); } /* above the stage */
88
- 50%, 100% { translate: 0 -50%; } /* 1. at the centre — and it stays: beat 2 is the drawer's */
89
+ 0% { translate: 0 calc(var(--centre-lift) - 100cqh); } /* above the stage */
90
+ 50%, 100% { translate: 0 var(--centre-lift); } /* 1. at the centre — and it stays: beat 2 is the drawer's */
89
91
  }
90
92
  @keyframes modal-open {
91
93
  0%, 50% { height: 0; padding-block: 0; } /* inside the card */
@@ -163,6 +165,81 @@
163
165
  @starting-style { .menu:popover-open { opacity: 0; translate: 0 calc(-1 * var(--sp-2)); } }
164
166
  }
165
167
 
168
+ /* ---- popup: a panel hung under the button that opens it — a head and `Rows joined` flush to its edges (cardds#219) ----
169
+ <button class="btn" popovertarget="inbox">…</button>
170
+ <div class="popup popup--end" id="inbox" popover role="group"><div class="popup__head"><span class="words">…</span><button class="btn">Read all</button></div>
171
+ <div class="rows rows--joined"><a class="row">…</a>…</div></div>
172
+ Native popover, as .menu: light dismiss, Esc, top layer, anchored to its invoker where anchor positioning exists. It is a paper of its own (the card-1 ground, so
173
+ the words on it follow that side), never wider than the room it has less its two margins, and scrolls inside itself when the room under the button is short: the head
174
+ is sticky, opaque, so a row's fill passes under it. Without anchor positioning (iOS before 26) it hangs under the top bar: the margin from the screen's start edge,
175
+ or from its end edge (a margin in) with .popup--end. .popup--end = the button is at the screen's right: the popup's right edge is --sp-2 in from the button's, it grows leftwards (as .menu--end), its far margin kept by max-width.
176
+ Narrower than the cards under it (cardds#222, Lh 2026-11-17: "ซ้อนกันเกินไป"): a card stands --screen-pad in from the screen, so the popup stands --sp-2 in from the card's edge on the button's side and --sp-6 in on the far side — the card's edge shows on both. */
177
+ .popup {
178
+ --card-bg: var(--card-1-bg); /* the paper's own slot (a ring, a fold reads it); its side, the inks follow (tokens.css) */
179
+ --dark: var(--card-1-dark);
180
+ --_popup-w: calc(var(--tap-base) * 8); /* 384: the widest it grows */
181
+ --_popup-max-h: calc(var(--tap-base) * 12); /* 576: the tallest it grows, short screens aside */
182
+ --_popup-room: calc(100dvh - var(--safe-top) - var(--header-h) - var(--sp-2) - var(--popup-margin, var(--sp-3))); /* the room under the top bar; anchored, what is under the button (below) */
183
+ --_popup-near: calc(var(--screen-pad) + var(--sp-2)); /* from the screen's edge, the button's side: --sp-2 inside the card's edge */
184
+ --_popup-far: calc(var(--screen-pad) + var(--sp-6)); /* from the screen's edge, the far side: --sp-6 inside the card's edge */
185
+ --_popup-m-near: var(--popup-margin, var(--_popup-near));
186
+ --_popup-m-far: var(--popup-margin, var(--_popup-far));
187
+ display: none; /* explicit closed state — never display on the base rule */
188
+ margin: 0;
189
+ padding: 0;
190
+ inset: auto;
191
+ inset-block-start: calc(var(--safe-top) + var(--header-h) + var(--sp-2));
192
+ inset-inline-start: var(--_popup-m-near);
193
+ width: var(--popup-w, var(--_popup-w));
194
+ max-width: calc(100% - var(--_popup-m-near) - var(--_popup-m-far));
195
+ max-height: min(var(--popup-max-h, var(--_popup-max-h)), var(--_popup-room));
196
+ overflow-y: auto;
197
+ overscroll-behavior: contain;
198
+ background: var(--popup-bg, var(--card-bg));
199
+ color: var(--card-ink);
200
+ border: var(--border-w) solid var(--popup-border, var(--card-border));
201
+ border-radius: var(--popup-radius, var(--r-card));
202
+ box-shadow: var(--popup-shadow, var(--shadow-float));
203
+ }
204
+ .popup:popover-open { display: block; }
205
+ .popup.\:popover-open { display: block; } /* the polyfill's open (iOS 16.4), its own rule as .menu's */
206
+ .popup--end { inset-inline-start: auto; inset-inline-end: var(--_popup-m-near); }
207
+ .popup__head {
208
+ position: sticky;
209
+ inset-block-start: 0;
210
+ z-index: var(--z-over);
211
+ display: flex;
212
+ align-items: center;
213
+ gap: var(--popup-head-gap, var(--sp-3));
214
+ padding: var(--popup-pad-y, var(--sp-3)) var(--popup-pad-x, var(--sp-4));
215
+ background: var(--popup-bg, var(--card-bg)); /* opaque: what scrolls under it is hidden, a row's fill too */
216
+ border-bottom: var(--border-w) solid var(--hairline);
217
+ }
218
+ .popup__head > .words { flex: 1; min-width: 0; }
219
+ .popup__head > :not(.words) { flex: none; }
220
+ @supports (anchor-name: --a) {
221
+ .popup[popover] {
222
+ position-area: block-end span-inline-end; /* from the button's start edge, rightwards */
223
+ inset: auto;
224
+ margin-block: var(--sp-2) var(--popup-margin, var(--sp-3));
225
+ --_popup-near: var(--sp-2); /* the area starts at the button, whose edge is the card's: the margin is measured from it */
226
+ margin-inline: var(--_popup-m-near) var(--_popup-m-far);
227
+ --_popup-room: calc(100% - var(--sp-2) - var(--popup-margin, var(--sp-3))); /* % of the area under the button */
228
+ position-try-fallbacks: flip-block;
229
+ }
230
+ .popup--end[popover] { position-area: block-end span-inline-start; margin-inline: var(--_popup-m-far) var(--_popup-m-near); } /* the button's right edge, leftwards (as .menu--end): the area starts at the screen's left, so the far margin is from the screen */
231
+ }
232
+ @media (prefers-reduced-motion: no-preference) {
233
+ .popup[popover] {
234
+ opacity: 0;
235
+ translate: 0 calc(-1 * var(--sp-2));
236
+ transition: display var(--motion-quick) allow-discrete, overlay var(--motion-quick) allow-discrete, opacity var(--motion-quick), translate var(--motion-quick);
237
+ }
238
+ .popup:popover-open { opacity: 1; translate: 0 0; }
239
+ .popup.\:popover-open { opacity: 1; translate: 0 0; }
240
+ @starting-style { .popup:popover-open { opacity: 0; translate: 0 calc(-1 * var(--sp-2)); } }
241
+ }
242
+
166
243
  /* ---- banner: ONE band — the line that opens it and the body share one ground (Lh 2026-09-24: "ปุ่มกับเนื้อหาใช้พื้นที่เดียวกัน") ----
167
244
  <details class="banner"><summary class="banner__summary">Save 2 h… <svg class="icon icon--xs"/></summary>
168
245
  <div class="banner__body">…</div></details>
@@ -291,12 +368,12 @@
291
368
  /* ---- splash: the app's mark at the human centre while it boots (Lh 2026-09-24) ----
292
369
  <section class="screen screen--fill splash"><div class="splash__group"><div class="splash__mark">{the app's lottie/img}</div>
293
370
  <p class="splash__text">…</p></div></section>
294
- The group's MIDDLE is on --screen-centre (40% down), the same line a centred card uses. The mark is the app's own content —
371
+ The group's own 40% point is on --screen-centre (40% down), the same line a centred card uses. The mark is the app's own content —
295
372
  a lottie box often carries empty room around its drawing — the app sets the knobs below, cardds does not guess it. */
296
373
  .splash { position: relative; background: var(--splash-bg, var(--surface)); transition: opacity var(--motion-sheet) var(--ease); }
297
374
  .splash--leaving { opacity: 0; }
298
375
  .splash__group {
299
- position: absolute; inset-inline: var(--screen-pad); top: var(--splash-at, var(--screen-centre)); translate: 0 -50%;
376
+ position: absolute; inset-inline: var(--screen-pad); top: var(--splash-at, var(--screen-centre)); translate: 0 var(--centre-lift);
300
377
  display: grid; justify-items: center; gap: var(--splash-gap, var(--sp-4)); text-align: center;
301
378
  }
302
379
  .splash__mark { width: var(--splash-mark-w, 60%); max-width: 100%; translate: var(--splash-mark-x, 0) var(--splash-mark-y, 0); }
package/css/lists.css CHANGED
@@ -21,6 +21,15 @@
21
21
  Space BETWEEN rows is .rows' gap; a lone row as card content takes the card's
22
22
  gap. (.row--flush, which zeroed the old padding, is gone — every row is flush.) */
23
23
  .row--lg { min-height: var(--row-lg-min-h, var(--fab)); } /* menu rows: a taller target, round arrow at the end; .rows gives them more air */
24
+ /* a lead as tall as N lines of the words beside it (Row leadLines, cardds#229): the stamp N lines tall at its 4:5 shape, a Lead a square as wide as that stamp, the row's
25
+ centring puts it in the middle of the height. The line is the level's own (body, or caption with `leadText="caption"`), so it follows the text size */
26
+ .row--lead-1 { --_lead-n: 1; }
27
+ .row--lead-2 { --_lead-n: 2; }
28
+ .row--lead-3 { --_lead-n: 3; }
29
+ .row--lead-lines { --_lead-line: round(down, calc(var(--lh-body) * var(--fs-body)), 1px); --_lead-w: calc(var(--_lead-n) * var(--_lead-line) * 4 / 5); }
30
+ .row--lead-caption { --_lead-line: round(down, calc(var(--lh-caption) * var(--fs-caption)), 1px); }
31
+ .row--lead-lines > .avatar-stack { --stamp-sm-size: var(--_lead-w); }
32
+ .row--lead-lines > .lead { --lead-size: var(--_lead-w); }
24
33
  /* a row that EXPANDS (Lh 2026-09-22): the row is a <details>' summary, what it shows comes out under it —
25
34
  who liked a postcard, the rest of a list. An end chevron turns when open. The app owns the list.
26
35
  <details class="row-expand"><summary class="row">…lead · body · end…</summary><div class="row-expand__more">…</div></details> */
@@ -46,6 +55,17 @@
46
55
  display: grid;
47
56
  place-items: center;
48
57
  }
58
+ /* a checklist item still to do (`Row todo`, cardds#223): the tick's place and size, empty and dashed; the words fade (the ring too, the one ink): not done yet, not active.
59
+ The row is a link or a button (the press list in actions.css): the whole row is the target. The circle is drawn, never a control. */
60
+ .row--todo { --_todo-fade: color-mix(in srgb, var(--card-ink) 40%, transparent); --_todo-ink: var(--row-todo-ink, var(--_todo-fade)); }
61
+ .row__todo {
62
+ width: var(--row-done-size, var(--tap-sm));
63
+ height: var(--row-done-size, var(--tap-sm));
64
+ flex: none;
65
+ margin-left: auto;
66
+ border-radius: 50%;
67
+ border: var(--border-w) dashed var(--row-todo-ring, var(--_todo-ink));
68
+ }
49
69
 
50
70
  /* rows: a list of rows separated by hairlines */
51
71
  .rows { display: grid; --rows-gap: var(--sp-4); row-gap: var(--rows-gap); }
@@ -63,6 +83,18 @@
63
83
  border-top: var(--border-w) solid var(--hairline);
64
84
  }
65
85
 
86
+ /* a row not yet seen (`Row unread`, cardds#219): the whole row takes a very light grey fill, the token --unread-bg (4% of the ink over any ground) */
87
+ .row--unread { background: var(--row-unread-bg, var(--unread-bg)); }
88
+
89
+ /* joined rows (`Rows joined`, cardds#219): no gap, every row a band edge to edge with its padding and a border under it (the last too), so a row with a fill
90
+ touches the next and reads as a band. The between-rows hairline is not drawn (the border is the line); a list for a holder that fills its width (a Popup) */
91
+ .rows.rows--joined { --rows-gap: 0rem; }
92
+ .rows--joined > .row + .row::before { display: none; }
93
+ .rows--joined > :is(.row, .row-expand) { border-bottom: var(--rows-joined-border-w, var(--px)) solid var(--rows-joined-border, var(--hairline-soft)); } /* thin and faint (Lh 2026-11-18: the dark line was too strong): was --border-w at --hairline */
94
+ .rows--joined > .row, .rows--joined > .row-expand > summary { padding: var(--rows-joined-pad-y, var(--sp-3)) var(--rows-joined-pad-x, var(--sp-4)); }
95
+ .rows--joined > .row-expand > .row-expand__more { padding: 0 var(--rows-joined-pad-x, var(--sp-4)) var(--rows-joined-pad-y, var(--sp-3)); }
96
+ .rows--joined > .rows__head { padding: var(--rows-joined-pad-y, var(--sp-3)) var(--rows-joined-pad-x, var(--sp-4)) 0; }
97
+
66
98
  /* ---- kv: label left, value right ----
67
99
  <dl class="kv"><div class="kv__row"><dt class="kv__key">Pay with</dt><dd class="kv__val">GHO</dd></div>…</dl> */
68
100
  .kv { margin: 0; display: grid; }
@@ -96,6 +128,9 @@
96
128
  the round Btn hangs up from it at the end corner while the reader is away from the end */
97
129
  .thread__end { position: sticky; bottom: 0; height: 0; margin-top: calc(-1 * var(--thread-gap, var(--sp-4))); display: grid; justify-items: end; z-index: 1; }
98
130
  .thread__jump { translate: 0 calc(-100% - var(--thread-jump-at, var(--sp-3))); }
131
+ /* a Thread standing in a CardList between its cards (a feed, cardds#214): a bubble is no card, so it needs more room than the gap between two
132
+ cards, the same over it and under it (the end room above is a chat's, for the bar under it) */
133
+ .card-list > .thread { padding-block: var(--thread-room-size, var(--sp-4)); }
99
134
  .bubble__author + *::before { content: "·"; margin-inline-end: var(--bubble-meta-gap, var(--sp-1)); }
100
135
  .bubble__author:has(+ *) { margin-inline-end: var(--bubble-meta-gap, var(--sp-1)); }
101
136
  .bubble__day:has(+ *) { margin-inline-end: var(--bubble-meta-gap, var(--sp-1)); } /* the day, then the time: "Dec 4 8:15" */
@@ -122,20 +157,51 @@
122
157
  font: var(--bubble-body-font, var(--type-body));
123
158
  overflow-wrap: anywhere;
124
159
  }
125
- .bubble--right > .bubble__body {
160
+ .bubble--right .bubble__body {
126
161
  border-bottom-left-radius: var(--r-card);
127
162
  border-bottom-right-radius: var(--bubble-tail-radius, var(--r-tail));
128
163
  background: var(--accent);
164
+ --dark: var(--accent-dark); /* the accent fill's side: the muted ink of its quote follows it */
129
165
  color: var(--on-accent);
130
166
  text-align: right;
131
167
  }
168
+ /* the line of the message this one answers (Bubble quote, cardds#227): first inside the body, over the words, one line cut with "…", a rule at its start as the
169
+ MessageBar's quote has; its words and rule are the muted ink of the body's ground, so fainter than the words on a theirs and a mine bubble alike */
170
+ .bubble__quote {
171
+ display: block;
172
+ margin-bottom: var(--sp-1);
173
+ padding-inline-start: var(--sp-3);
174
+ border-inline-start: var(--sp-1) solid var(--bubble-quote-rule-ink, var(--card-muted));
175
+ font: var(--type-caption);
176
+ color: var(--bubble-quote-ink, var(--card-muted));
177
+ white-space: nowrap;
178
+ overflow: hidden;
179
+ text-overflow: ellipsis;
180
+ text-align: start;
181
+ }
132
182
  .bubble__meta { display: flex; align-items: center; gap: var(--bubble-meta-gap, var(--sp-1)); font: var(--bubble-meta-font, var(--type-caption)); color: var(--bubble-meta-ink, var(--card-muted)); }
133
183
  .bubble--right > .bubble__meta { justify-self: end; }
134
- .bubble__meta > .icon { --icon-ink: var(--bubble-meta-icon-ink, var(--accent-ink)); }
184
+ .bubble__meta > .icon, .bubble__time > .icon { --icon-ink: var(--bubble-meta-icon-ink, var(--accent-ink)); }
185
+ /* the line ABOVE the message (Bubble metaAbove, cardds#214): who sent it, read before the words — lead · name · time on one line, the bubble
186
+ under it from the start edge (not led in beside the lead: that left a few words a line). The line comes first in the markup (the reader hears
187
+ who, then what), the same meta line as below the message and its separators. The bubble hugs its words however long the line is
188
+ (justify-items), and the line never wraps: the name gives way with "…", the lead and the time keep their size. Under the line --sp-2. */
189
+ .bubble--meta-above { row-gap: var(--bubble-meta-above-gap, var(--sp-2)); justify-items: start; }
190
+ .bubble--meta-above.bubble--right { justify-items: end; }
191
+ .bubble--meta-above > .bubble__meta { min-width: 0; max-width: 100%; }
192
+ .bubble__lead { flex: none; display: flex; margin-inline-end: var(--bubble-lead-gap, var(--sp-1)); } /* on top of the line's gap */
193
+ .bubble--meta-above .bubble__author { flex: 0 1 auto; min-width: 0; overflow-x: clip; overflow-y: visible; text-overflow: ellipsis; white-space: nowrap; font: var(--bubble-author-font, var(--type-label)); color: var(--bubble-author-ink, var(--card-ink)); } /* clip SIDEWAYS only: hidden cut the Thai tone marks over the line */
194
+ .bubble__time { flex: none; display: flex; align-items: center; gap: var(--bubble-meta-gap, var(--sp-1)); white-space: nowrap; }
195
+ /* the message with one round button of the app beside it (Bubble action, cardds#214): a row of the message and the button, the button on the
196
+ side the thread's middle is (after theirs, before mine), centred on the message's height. The bubble's 75% cap holds both */
197
+ .bubble__row { display: flex; align-items: center; gap: var(--bubble-action-gap, var(--sp-2)); min-width: 0; max-width: 100%; }
198
+ .bubble--right .bubble__row { flex-direction: row-reverse; }
199
+ .bubble__row > .bubble__body { flex: 0 1 auto; }
200
+ .bubble__action { flex: none; display: grid; }
135
201
  /* a bubble that is a link or is pressed (Bubble href / onClick, Lh 2026-10-28): the press answer is the DIM (actions.css), no underline */
136
202
  a.bubble { color: inherit; text-decoration: none; }
137
203
  /* highlighted (Bubble highlighted): the message the member is looking at, a ring a hair outside its body */
138
- .bubble--highlighted > .bubble__body { outline: var(--sp-0) solid var(--bubble-highlighted-ink, var(--accent)); outline-offset: var(--sp-0); }
204
+ .bubble--highlighted .bubble__body { outline: var(--sp-0) solid var(--bubble-highlighted-ink, var(--accent)); outline-offset: var(--sp-0); }
139
205
 
140
206
  /* ---- timeline: a hairline with date chips, entries to the right ----
141
207
  <ol class="timeline"><li class="timeline__item"><span class="timeline__mark">Wed 14</span><p class="t-body">…</p></li>…</ol> */
package/css/media.css CHANGED
@@ -124,6 +124,39 @@
124
124
  .mosaic > :first-child { grid-row: span 2; }
125
125
  .mosaic > * { min-height: 0; border-radius: 0; } /* opacity/border-width here were no-ops: .ph restates its own below, and nothing else in a mosaic carries either by default */
126
126
  .mosaic > img { width: 100%; height: 100%; object-fit: cover; }
127
+ /* two photos (cardds#226): side by side, one row, equally tall */
128
+ .mosaic--2 { grid-template-columns: 1fr 1fr; }
129
+ .mosaic--2 > :first-child { grid-row: auto; }
130
+ /* four or more: the small lower photo is darkened with "+n", n the photos not shown. The darkening is the scrim twice (75% black): one scrim is 3.9:1 under white words over a white photo, two are 10.4:1 */
131
+ .mosaic__more-cell { position: relative; display: grid; }
132
+ .mosaic__more-cell > :first-child { width: 100%; height: 100%; min-height: 0; border-radius: 0; object-fit: cover; }
133
+ .mosaic__more {
134
+ position: absolute; inset: 0; display: grid; place-items: center;
135
+ background: linear-gradient(var(--mosaic-more-bg, var(--scrim)), var(--mosaic-more-bg, var(--scrim))), var(--mosaic-more-bg, var(--scrim));
136
+ color: var(--mosaic-more-ink, var(--ink-ondark));
137
+ font: var(--mosaic-more-font, var(--type-title));
138
+ }
139
+
140
+ /* ---- thumb: one small square photo that can be pressed, and the grid it stands in (cardds#232) ----
141
+ <div class="thumb-grid"><button class="thumb" aria-label="Photo 1"><img src="…" alt=""></button>…</div>
142
+ The photo only — no words over or under it. The whole square is the control (its press is the shared list at the end of actions.css). */
143
+ .thumb-grid {
144
+ display: grid;
145
+ grid-template-columns: repeat(var(--thumb-grid-cols, 5), minmax(0, 1fr)); /* five to a row; the squares grow with the width they stand in */
146
+ gap: var(--thumb-grid-gap, var(--sp-2));
147
+ }
148
+ .thumb {
149
+ display: block;
150
+ aspect-ratio: 1;
151
+ min-width: 0;
152
+ padding: 0;
153
+ border: 0;
154
+ background: none;
155
+ color: inherit;
156
+ border-radius: var(--thumb-radius, var(--r-control));
157
+ overflow: hidden;
158
+ }
159
+ .thumb > img, .thumb > .ph { display: block; width: 100%; height: 100%; min-height: 0; object-fit: cover; border-radius: 0; }
127
160
 
128
161
  /* ---- postcard: a member's introduction in the shape of a cover card — the photo fills it,
129
162
  the band at the bottom names it; tap the photo to turn it over (Lh 2026-09-12; reshaped 2026-09-22) ----
package/css/palette.css CHANGED
@@ -123,6 +123,13 @@
123
123
  --dot-a: #dd9787; --dot-b: #b08a5a;
124
124
  }
125
125
 
126
+ /* TONES (cardds#219): the six fills of a `Lead tone`, a white icon on a colour to tell kinds of thing apart — in coloured mode, whatever the palette (a project's own
127
+ `data-palette` too). Each holds the ondark ink at 4.5:1 or more on every palette cardds ships, the dimmest ink (clay's #f4efe4) included; the lowest is blue on clay, 4.74.
128
+ A project whose own ondark ink is dimmer than that retunes the tone it fails (inkGrounds() names it), or sets it in its theme.css. The wireframe's are greys (tokens.css) */
129
+ [data-palette] {
130
+ --tone-blue: #2a6f9e; --tone-green: #52613d; --tone-amber: #8a5a12; --tone-red: #c22d12; --tone-pink: #b8285e; --tone-violet: #5b4a8a;
131
+ }
132
+
126
133
  /* Colored palettes trade wireframe outlines for soft elevation. */
127
134
  [data-palette] :is(.card, .band-stack) { box-shadow: var(--shadow-card); }
128
135
  /* COLOURED MODE is the attribute, whatever its value: a project with colours of its own (the five