@usableapp/cardds 0.7.156 → 0.7.158
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 +32 -0
- package/css/actions.css +33 -4
- package/css/base.css +8 -0
- package/css/card.css +5 -0
- package/css/forms.css +14 -1
- package/css/lists.css +4 -0
- package/css/parts.css +33 -1
- package/css/sheet.css +5 -2
- package/css/stamp.css +2 -0
- package/css/tokens.css +1 -0
- package/dist/actions/Btn.d.ts +12 -3
- package/dist/actions/Btn.js +6 -3
- package/dist/actions/BtnRow.d.ts +6 -2
- package/dist/actions/BtnRow.js +3 -3
- package/dist/actions/IconBtn.d.ts +8 -2
- package/dist/actions/IconBtn.js +4 -2
- package/dist/actions/LinkBlock.d.ts +9 -0
- package/dist/actions/LinkBlock.js +8 -0
- package/dist/actions/useSendOut.d.ts +4 -0
- package/dist/actions/useSendOut.js +15 -0
- package/dist/cardds.css +105 -8
- package/dist/cards/Card.d.ts +8 -1
- package/dist/cards/CardParts.d.ts +8 -0
- package/dist/cards/CardParts.js +5 -0
- package/dist/catalog.json +1 -1
- package/dist/forms/MessageBar.d.ts +9 -2
- package/dist/forms/MessageBar.js +6 -4
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/lists/Bubble.d.ts +859 -4
- package/dist/lists/Bubble.js +18 -4
- package/dist/lists/Row.d.ts +4 -0
- package/dist/media/MapArea.d.ts +7 -1
- package/dist/media/MapArea.js +5 -3
- package/dist/parts/Foot.d.ts +8 -2
- package/dist/parts/Foot.js +4 -3
- package/dist/parts/Head.d.ts +1 -0
- package/dist/parts/Head.js +1 -0
- package/dist/stamp/Stamp.d.ts +1 -0
- package/dist/stamp/Stamp.js +1 -0
- package/dist/state.d.ts +2 -2
- package/dist/state.js +4 -4
- package/dist/type/Text.d.ts +5 -1
- package/dist/type/Text.js +3 -2
- package/dist/type/icons.d.ts +1 -1
- package/dist/type/icons.js +2 -2
- package/docs/reference.md +56 -5
- package/icons.svg +1 -0
- package/package.json +1 -1
package/dist/cardds.css
CHANGED
|
@@ -183,6 +183,7 @@
|
|
|
183
183
|
--ease-linear: linear;
|
|
184
184
|
--ease-settle: cubic-bezier(0.2, 0.8, 0.2, 1);
|
|
185
185
|
--ease-step: steps(1); /* on or off with nothing between: a code cell's caret blinking, a secret digit before its dot */
|
|
186
|
+
--motion-send: 0.7s; /* something going OUT from a button (Btn / IconBtn sending, actions.css): the icon tips forward, two rings spread */
|
|
186
187
|
--motion-press: 0.12s; /* a control giving under the finger and springing back (actions.css PRESS) */
|
|
187
188
|
--press-scale: 0.96; /* how far a finger-sized control gives — a share of its size */
|
|
188
189
|
--scale-lift: 1.06; /* a stamp lifted off the paper while the finger holds it */
|
|
@@ -744,6 +745,14 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
744
745
|
.t-title { font: var(--type-title); margin: 0; --fs-self: var(--fs-title); }
|
|
745
746
|
.t-body { font: var(--type-body); margin: 0; }
|
|
746
747
|
.t-scroll { --_t-scroll-max: calc(var(--text-scroll-lines, 3.6) * 1lh); height: var(--text-scroll-size, auto); max-height: var(--text-scroll-size, var(--_t-scroll-max)); overflow: hidden; } /* the cut box of `Text expand`: plain, no border, no ground, no scroll; lh = the body's own line */
|
|
748
|
+
/* cut at N lines (Text lines, Lh 2026-10-28): no chevron, no tap, the words stop at the last line's end */
|
|
749
|
+
.t-lines { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
|
|
750
|
+
.t-lines--1 { -webkit-line-clamp: 1; line-clamp: 1; }
|
|
751
|
+
.t-lines--2 { -webkit-line-clamp: 2; line-clamp: 2; }
|
|
752
|
+
.t-lines--3 { -webkit-line-clamp: 3; line-clamp: 3; }
|
|
753
|
+
.t-lines--4 { -webkit-line-clamp: 4; line-clamp: 4; }
|
|
754
|
+
.t-lines--5 { -webkit-line-clamp: 5; line-clamp: 5; }
|
|
755
|
+
.t-lines--6 { -webkit-line-clamp: 6; line-clamp: 6; }
|
|
747
756
|
.t-expand { display: grid; } /* the box, and under it the chevron when the text does not fit */
|
|
748
757
|
.t-expand.is-open > .t-scroll { height: auto; max-height: none; } /* open: the whole text in place */
|
|
749
758
|
.t-expand__sign { justify-self: center; } /* the chevron: down = there is more, up = fold it */
|
|
@@ -1018,6 +1027,11 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
1018
1027
|
|
|
1019
1028
|
.card__media { border-radius: var(--card-media-radius, var(--r-media)); overflow: hidden; position: relative; } /* relative: corner badges */
|
|
1020
1029
|
.card__media > img { width: 100%; height: auto; object-fit: cover; }
|
|
1030
|
+
/* 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 */
|
|
1031
|
+
.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; }
|
|
1032
|
+
.media-beside__words { display: grid; gap: var(--sp-1); min-width: 0; }
|
|
1033
|
+
.media-beside__pic { aspect-ratio: 1; border-radius: var(--r-media); overflow: hidden; }
|
|
1034
|
+
.media-beside__pic > * { width: 100%; height: 100%; min-height: 0; object-fit: cover; }
|
|
1021
1035
|
|
|
1022
1036
|
/* a JourneyBadge at the edge of the card's own first head (the date box in the top-left or top-right corner) keeps its corner concentric
|
|
1023
1037
|
with the card's: the card's corner (--r-card) less the room the padding leaves round it. journey.css reads it behind the theme's --tile-badge-radius,
|
|
@@ -2271,14 +2285,17 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
2271
2285
|
--_band-centre: 50%;
|
|
2272
2286
|
position: relative;
|
|
2273
2287
|
min-height: var(--map-inline-h, calc(var(--map-ring) * 3 / 2));
|
|
2274
|
-
/* a thin grey frame, the joined BtnGroup look="choice"'s edge (actions.css .segment--choice): its width, its ink
|
|
2288
|
+
/* a thin grey frame, the joined BtnGroup look="choice"'s edge (actions.css .segment--choice): its width, its ink; the media's corner; the map clipped to it */
|
|
2275
2289
|
border: var(--border-w) solid var(--map-area-edge-ink, var(--outline));
|
|
2276
|
-
border-radius: var(--map-radius, var(--r-
|
|
2290
|
+
border-radius: var(--map-radius, var(--r-media)); /* the media corner, as a picture in a card (Lh 2026-10-28: was the pill's) */
|
|
2277
2291
|
overflow: clip;
|
|
2278
2292
|
}
|
|
2279
2293
|
.map--bleed { margin-inline: calc(-1 * var(--card-pad, 0rem)); border-radius: 0; border-inline: 0; } /* edge to edge is a band, and a band has no corner; --map-radius is for the box in the inset */
|
|
2280
2294
|
/* a map that is a body's only child fills it; the body turns to a column for it (parts.css) */
|
|
2281
2295
|
.body > .map--inline:only-child { flex: 1 0 auto; }
|
|
2296
|
+
/* a STILL map (`.map--still`): a preview of one point, not a place to choose — it owns no gesture (no data-gestures="own", so the page's
|
|
2297
|
+
own touch-action) and takes no touch: a finger on it scrolls the page, a tap is a tap on what holds it (a card that links out). The mark keeps its name */
|
|
2298
|
+
.map--still, .map--still * { pointer-events: none; }
|
|
2282
2299
|
|
|
2283
2300
|
/* ---- map pick: a place on the map the member taps to choose it (Lh 2026-10-17) ----
|
|
2284
2301
|
<label class="map-pick" style="top: 30%; left: 40%"><input type="radio" name="meet" value="library">
|
|
@@ -2705,7 +2722,20 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
2705
2722
|
it rides with the bar above the keyboard. A written name is one piece: .mention-under is a copy of the words in the textarea's
|
|
2706
2723
|
own cell and class (same font, padding, wrap), its ink clear, drawn BEHIND the transparent textarea; only the names' marks show. */
|
|
2707
2724
|
.mention-list { flex: 0 0 100%; order: -1; max-height: calc(var(--tap) * 4.5); /* the fifth name shows half: the list scrolls */ }
|
|
2708
|
-
.message-bar:has(> .mention-list) { flex-wrap: wrap; }
|
|
2725
|
+
.message-bar:has(> :is(.mention-list, .message-bar__quote)) { flex-wrap: wrap; }
|
|
2726
|
+
/* the reply-to quote (MessageBar quote, Lh 2026-10-28): a line of its own over the box, a rule at its start, cut at one line, its ✕ at the end */
|
|
2727
|
+
.message-bar__quote {
|
|
2728
|
+
flex: 0 0 100%;
|
|
2729
|
+
order: -1;
|
|
2730
|
+
display: flex;
|
|
2731
|
+
align-items: center;
|
|
2732
|
+
gap: var(--sp-2);
|
|
2733
|
+
padding-inline-start: var(--sp-3);
|
|
2734
|
+
border-inline-start: var(--sp-1) solid var(--message-bar-quote-rule-ink, var(--accent));
|
|
2735
|
+
font: var(--type-caption);
|
|
2736
|
+
color: var(--message-bar-quote-ink, var(--card-muted)); /* the muted words of whatever it stands on, as .t-muted */
|
|
2737
|
+
}
|
|
2738
|
+
.message-bar__quote-words { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
|
2709
2739
|
.mention-box { display: grid; }
|
|
2710
2740
|
.mention-box > * { grid-area: 1 / 1; }
|
|
2711
2741
|
.mention-under {
|
|
@@ -2979,17 +3009,44 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
2979
3009
|
.btn--warn { --dark: var(--action-dark); color: var(--btn-warn-ink, var(--signal-warn)); } /* a move to think twice about ("cancel the request"): the signal set's warning, on the button's own paper — its side, not the card's */
|
|
2980
3010
|
.btn--block { width: 100%; }
|
|
2981
3011
|
.btn--form { justify-self: center; align-self: center; margin-inline: auto; padding-inline: var(--btn-form-pad-x, calc(var(--sp-base) * 14.5)); /* 58px: "ส่งรหัส OTP" at 213px, 20% longer than at 40px sides (Lh 2026-09-25) */ } /* a form's button: its words + wide sides, centred in a grid (a step) or a block (Lh 2026-09-25) */
|
|
3012
|
+
/* sm (Btn sm, Lh 2026-10-28): one small tap tall (the touch floor, 44), the small words, closer sides — a worded move at a card head's end */
|
|
3013
|
+
.btn--sm { min-height: var(--btn-sm-size, var(--form-tap-sm)); padding-block: var(--sp-1); padding-inline: var(--btn-sm-pad-x, var(--sp-4)); font-size: var(--btn-sm-font-size, var(--fs-sm)); }
|
|
2982
3014
|
/* xl: the one giant call to action in a tinted card ("Taxi!") */
|
|
2983
3015
|
.btn--xl { min-height: var(--btn-xl-h); font: var(--fw-heavy) var(--fs-3xl) / var(--lh-solid) var(--font-display); letter-spacing: var(--track-h1); border-radius: var(--r-card); padding-inline: var(--sp-8); }
|
|
2984
3016
|
/* disabled keeps the slot — a control that vanishes moves everything else,
|
|
2985
3017
|
and a pager whose "previous" disappeared on page one would shift the bar
|
|
2986
3018
|
under the thumb on every page */
|
|
3019
|
+
/* SENDING (Btn / IconBtn sending, Lh 2026-10-28): something goes OUT from the button — for --motion-send its icon swells and tips forward,
|
|
3020
|
+
and two rings spread from its edge one after the other (--btn-sending-ink, the accent); then the app swaps the icon or puts the sent thing in.
|
|
3021
|
+
Under reduced motion nothing moves (the app is told at once) */
|
|
3022
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
3023
|
+
:is(.btn, .icon-btn).is-sending { animation: send-out var(--motion-send) var(--ease-out); }
|
|
3024
|
+
:is(.btn, .icon-btn).is-sending > .icon { animation: send-out-call var(--motion-send) ease-in-out; }
|
|
3025
|
+
}
|
|
3026
|
+
@keyframes send-out {
|
|
3027
|
+
from { box-shadow: 0 0 0 0 color-mix(in srgb, var(--btn-sending-ink, var(--accent)) 45%, transparent), 0 0 0 0 color-mix(in srgb, var(--btn-sending-ink, var(--accent)) 30%, transparent); }
|
|
3028
|
+
60% { box-shadow: 0 0 0 var(--sp-3) transparent, 0 0 0 var(--sp-1) color-mix(in srgb, var(--btn-sending-ink, var(--accent)) 30%, transparent); }
|
|
3029
|
+
to { box-shadow: 0 0 0 var(--sp-5) transparent, 0 0 0 var(--sp-4) transparent; }
|
|
3030
|
+
}
|
|
3031
|
+
@keyframes send-out-call {
|
|
3032
|
+
0% { transform: none; }
|
|
3033
|
+
30% { transform: scale(1.35) rotate(-14deg); }
|
|
3034
|
+
55% { transform: translateX(var(--sp-1)) scale(1.15) rotate(-8deg); opacity: 0.5; }
|
|
3035
|
+
100% { transform: none; opacity: 1; }
|
|
3036
|
+
}
|
|
3037
|
+
/* link block (LinkBlock, Lh 2026-10-28): a few pieces of a card's content as one link — stacked with the card's gap, the holder's ink, no underline,
|
|
3038
|
+
no frame, no padding; the DIM press answer (below) */
|
|
3039
|
+
.link-block { display: grid; gap: var(--link-block-gap, var(--card-gap)); color: inherit; text-decoration: none; }
|
|
2987
3040
|
/* a row of buttons sharing the width (twin CTAs inside a card) */
|
|
2988
3041
|
.btn-row { display: flex; gap: var(--btn-row-gap, var(--sp-2)); }
|
|
2989
3042
|
/* round (BtnRow round, Lh 2026-10-24): a few round IconBtns as one group in the middle of a card's content, a fixed gap apart — Foot round's look,
|
|
2990
3043
|
so a card's foot stays its status line */
|
|
2991
3044
|
.btn-row--round { justify-content: center; align-items: center; gap: var(--btn-row-gap, var(--sp-6)); }
|
|
2992
3045
|
.btn-row > .btn { flex: 1; min-width: 0; }
|
|
3046
|
+
/* wrap (BtnRow wrap): each Btn as wide as its words, wrapping; end: they stand at the row's end */
|
|
3047
|
+
.btn-row--wrap { flex-wrap: wrap; }
|
|
3048
|
+
.btn-row--wrap > .btn { flex: 0 0 auto; }
|
|
3049
|
+
.btn-row--end { justify-content: flex-end; }
|
|
2993
3050
|
/* joined (BtnRow round joined, Foot round joined — Lh 2026-10-24, was BtnTrio): a dotted link between each two round buttons, a closer gap */
|
|
2994
3051
|
.btn-row--joined { gap: var(--btn-trio-gap, var(--sp-3)); }
|
|
2995
3052
|
.btn-trio__dots {
|
|
@@ -3259,7 +3316,9 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
3259
3316
|
button (src/cards/cardGo.ts). It is in the DIM pointer and :active lists only — the focus ring and the disabled look stay the
|
|
3260
3317
|
button's, the card itself is never focused or disabled.
|
|
3261
3318
|
.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
|
|
3262
|
-
dims nor gives: its ink never changes under the finger (Lh 2026-10-25), the opening is the answer. Pointer only (below).
|
|
3319
|
+
dims nor gives: its ink never changes under the finger (Lh 2026-10-25), the opening is the answer. Pointer only (below).
|
|
3320
|
+
.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.
|
|
3321
|
+
.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. */
|
|
3263
3322
|
:where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day,
|
|
3264
3323
|
.float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
|
|
3265
3324
|
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) {
|
|
@@ -3267,7 +3326,7 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
3267
3326
|
touch-action: manipulation;
|
|
3268
3327
|
transition: scale var(--motion-press) var(--ease-out);
|
|
3269
3328
|
}
|
|
3270
|
-
:where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .feed-card--small, .toggle-field, .post-box__edge) {
|
|
3329
|
+
:where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .feed-card--small, .toggle-field, .post-box__edge, .bubble--press, .link-block) {
|
|
3271
3330
|
cursor: pointer;
|
|
3272
3331
|
touch-action: manipulation;
|
|
3273
3332
|
transition: opacity var(--motion-press) var(--ease-out);
|
|
@@ -3283,7 +3342,7 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
3283
3342
|
:where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day,
|
|
3284
3343
|
.float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
|
|
3285
3344
|
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); }
|
|
3286
|
-
:where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .feed-card--small, .toggle-field, .post-box__edge):active:not([aria-disabled="true"], :has(:disabled)) { opacity: var(--press-dim); }
|
|
3345
|
+
:where(a.row, button.row, label.row, .row-expand > summary, .banner__summary, a.card, label.card, .card--go, .feed-card--small, .toggle-field, .post-box__edge, .bubble--press, .link-block):active:not([aria-disabled="true"], :has(:disabled)) { opacity: var(--press-dim); }
|
|
3287
3346
|
/* 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:
|
|
3288
3347
|
it darkens a touch instead (--press-shade) */
|
|
3289
3348
|
:where(.sheet-stack--tap > .card:not(.is-open), .postcard__turn, .post-letter__sheet:not(:has(.icon-btn:active))) { cursor: pointer; touch-action: manipulation; transition: filter var(--motion-press) var(--ease-out); }
|
|
@@ -3293,7 +3352,7 @@ button:enabled { cursor: pointer; } /* a disabled one keeps the arrow */
|
|
|
3293
3352
|
.float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
|
|
3294
3353
|
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,
|
|
3295
3354
|
: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); }
|
|
3296
|
-
: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):not(label, .toggle-field):focus-visible { outline: var(--focus); outline-offset: var(--sp-1); }
|
|
3355
|
+
: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); }
|
|
3297
3356
|
/* disabled: no pointer anywhere; a control fades (a link and a row keep their own muted look) */
|
|
3298
3357
|
:where(.btn, .icon-btn, .link, a.chip, button.chip, .chip--pick, a.tile, button.tile, .tile--pick, .day, .segment__item, .calendar__day,
|
|
3299
3358
|
.float-bar__item, .avatar-pick__item, .add-row, .picker__item, .dropdown__btn, .appbar__who, .check, .toggle, .mood__opt, .sheet__handle,
|
|
@@ -4267,6 +4326,10 @@ button.calendar__label:focus-visible { outline: var(--focus); outline-offset: va
|
|
|
4267
4326
|
.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)); }
|
|
4268
4327
|
.bubble--right > .bubble__meta { justify-self: end; }
|
|
4269
4328
|
.bubble__meta > .icon { --icon-ink: var(--bubble-meta-icon-ink, var(--accent-ink)); }
|
|
4329
|
+
/* 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 */
|
|
4330
|
+
a.bubble { color: inherit; text-decoration: none; }
|
|
4331
|
+
/* highlighted (Bubble highlighted): the message the member is looking at, a ring a hair outside its body */
|
|
4332
|
+
.bubble--highlighted > .bubble__body { outline: var(--sp-0) solid var(--bubble-highlighted-ink, var(--accent)); outline-offset: var(--sp-0); }
|
|
4270
4333
|
|
|
4271
4334
|
/* ---- timeline: a hairline with date chips, entries to the right ----
|
|
4272
4335
|
<ol class="timeline"><li class="timeline__item"><span class="timeline__mark">Wed 14</span><p class="t-body">…</p></li>…</ol> */
|
|
@@ -4511,6 +4574,34 @@ button.calendar__label:focus-visible { outline: var(--focus); outline-offset: va
|
|
|
4511
4574
|
}
|
|
4512
4575
|
.head:has(> .tile-badge:first-child + .chip-row) > :nth-child(n + 3) { grid-column: 1 / -1; grid-row: auto; }
|
|
4513
4576
|
|
|
4577
|
+
/* a head that LEADS with a person or a thing (Lh 2026-10-28, timebank's welcome card): a `Head` whose first child is a `Lead`, an `Avatar` or an
|
|
4578
|
+
`AvatarStack` (a stamp in one) and whose second is the `Words` title. The lead stands at the left; beside it, left-aligned, ONE block — the title
|
|
4579
|
+
at the card heading's size over its meta — as a FeedCard's head draws it; whatever follows (an `End`, an `IconBtn`) stands at the right, centred to
|
|
4580
|
+
the block. A title without a meta is centred to the lead. The title is cut at --head-title-lines (above), the meta at --head-meta-lines (none).
|
|
4581
|
+
A head with no lead before its title is untouched.
|
|
4582
|
+
<div class="head"><span class="avatar-stack">…</span><h2 class="words__title t-h2">…</h2><span class="words__meta t-caption t-muted">…</span><span class="end">…</span></div> */
|
|
4583
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) {
|
|
4584
|
+
display: grid;
|
|
4585
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
4586
|
+
grid-auto-columns: auto;
|
|
4587
|
+
align-items: center;
|
|
4588
|
+
}
|
|
4589
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) > :first-child { grid-column: 1; grid-row: 1 / 3; }
|
|
4590
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) > :nth-child(2) { grid-column: 2; grid-row: 1; align-self: end; }
|
|
4591
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) > :nth-child(2):not(:has(+ .words__meta)) { grid-row: 1 / 3; align-self: center; }
|
|
4592
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) > .words__meta:nth-child(3) {
|
|
4593
|
+
grid-column: 2; grid-row: 2; align-self: start;
|
|
4594
|
+
overflow-wrap: anywhere;
|
|
4595
|
+
display: -webkit-box;
|
|
4596
|
+
-webkit-box-orient: vertical;
|
|
4597
|
+
-webkit-line-clamp: var(--head-meta-lines, none);
|
|
4598
|
+
line-clamp: var(--head-meta-lines, none);
|
|
4599
|
+
overflow: hidden;
|
|
4600
|
+
padding-block: 0.2em 0.15em; /* room for a Thai mark inside the clip, given back outside (as the title's, above) */
|
|
4601
|
+
margin-block: -0.2em -0.15em;
|
|
4602
|
+
}
|
|
4603
|
+
.head:not(.head--centre):has(> :is(.lead, .avatar, .avatar-stack):first-child + :is(.words__title, .words__over-title)) > :nth-child(n + 3):not(.words__meta) { grid-row: 1 / 3; }
|
|
4604
|
+
|
|
4514
4605
|
/* in a card with paper bands: the head and the foot are paper bands edge to edge, one look */
|
|
4515
4606
|
:is(.card--bands, .card--bands > .card__face) > :is(.head, .foot) {
|
|
4516
4607
|
--card-bg: var(--card-1-bg);
|
|
@@ -4752,7 +4843,11 @@ button.calendar__label:focus-visible { outline: var(--focus); outline-offset: va
|
|
|
4752
4843
|
Knobs --foot-gap, --foot-ink, --foot-link-gap. An outer governs a foot through those knobs or a selector naming both, written
|
|
4753
4844
|
below under the outer's name (Lh 2026-10-21). ---- */
|
|
4754
4845
|
.foot { display: flex; gap: var(--foot-gap, var(--sp-2)); align-items: center; color: var(--foot-ink, inherit); }
|
|
4755
|
-
.foot:has(> :nth-child(3)) > .btn { --btn-pad-x: var(--sp-2); }
|
|
4846
|
+
.foot:not(.foot--wrap):has(> :nth-child(3)) > .btn { --btn-pad-x: var(--foot-crowd-pad-x, var(--sp-2)); } /* knob: a theme that keeps one pill shape sets it to the Btn's own side padding */
|
|
4847
|
+
/* wrap (Foot wrap): each Btn as wide as its words, its own side padding, from the start, wrapping; end (Foot end): they stand at the foot's end */
|
|
4848
|
+
.foot--wrap { flex-wrap: wrap; justify-content: flex-start; row-gap: var(--foot-gap, var(--sp-2)); }
|
|
4849
|
+
.foot--wrap > .btn { flex: 0 0 auto; }
|
|
4850
|
+
.foot--end { justify-content: flex-end; }
|
|
4756
4851
|
/* a small link under the buttons (Foot link — Lh 2026-09-23, as the ActionBar's ctaLink): the row wraps, the link takes a
|
|
4757
4852
|
whole short row of its own, centred — it never shares the buttons' line */
|
|
4758
4853
|
.foot--link { flex-wrap: wrap; align-content: end; row-gap: var(--foot-link-gap, var(--sp-1)); }
|
|
@@ -5556,6 +5651,8 @@ button.calendar__label:focus-visible { outline: var(--focus); outline-offset: va
|
|
|
5556
5651
|
/* the SMALL stamp, 48 × 60 whatever its holder's size, in the three places that hold it: stuck on a surface (a note), lapped in an avatar stack,
|
|
5557
5652
|
leading a feed card's head. The stamp carries the size and the `.stamp-on` box is as wide as its stamp */
|
|
5558
5653
|
.stamp-on > .stamp, .avatar-stack > .stamp, .feed-card__lead > .stamp { width: var(--stamp-sm-size, var(--tap)); }
|
|
5654
|
+
/* the empty PLACE for a stamp at a lead's size (Lh 2026-10-28): in an avatar stack or a feed card's lead it is the small stamp's size too, an Icon inside */
|
|
5655
|
+
.avatar-stack > .stamp-place, .feed-card__lead > .stamp-place { width: var(--stamp-sm-size, var(--tap)); flex: none; margin-inline: 0; }
|
|
5559
5656
|
.stamp-on > .stamp { max-width: none; }
|
|
5560
5657
|
/* --main: the same stuck stamp at the stamp's MAIN size, 96 × 120 (--stamp-size), to cover what it lies on (the owner's call, 2026-10-11: the home's note).
|
|
5561
5658
|
After the rule above, at the same weight: `main` is the one place a stuck stamp reads --stamp-size. */
|
package/dist/cards/Card.d.ts
CHANGED
|
@@ -31,6 +31,10 @@ export interface CardProps extends ComponentProps<'article'> {
|
|
|
31
31
|
as?: 'article' | 'div' | 'a' | 'label' | 'section' | 'li';
|
|
32
32
|
/** the link's target, for `as="a"` */
|
|
33
33
|
href?: string;
|
|
34
|
+
/** where the link opens, for `as="a"` (`_blank`: a new tab, out of the app) */
|
|
35
|
+
target?: string;
|
|
36
|
+
/** the link's relation, for `as="a"` (`noopener` with `target="_blank"`) */
|
|
37
|
+
rel?: string;
|
|
34
38
|
/** set by `SheetStack` from the app's `open` and `refreshing`. The card renders its place, its grip and its pull. Leave it unset on any other card */
|
|
35
39
|
stack?: StackPlace;
|
|
36
40
|
/** THE CARD LEAVES — the card floats away: up and out with a small turn, as one piece with all it holds (a stamp that has just landed on it goes with it).
|
|
@@ -947,6 +951,10 @@ export declare function Card({ tone, paper, sm, row, cover, fold, centre, wide,
|
|
|
947
951
|
} | undefined;
|
|
948
952
|
/** the link's target, for `as="a"` */
|
|
949
953
|
href?: string;
|
|
954
|
+
/** where the link opens, for `as="a"` (`_blank`: a new tab, out of the app) */
|
|
955
|
+
target?: string;
|
|
956
|
+
/** the link's relation, for `as="a"` (`noopener` with `target="_blank"`) */
|
|
957
|
+
rel?: string;
|
|
950
958
|
key?: import("react").Key | null | undefined;
|
|
951
959
|
defaultChecked?: boolean | undefined;
|
|
952
960
|
defaultValue?: string | number | readonly string[] | undefined;
|
|
@@ -977,7 +985,6 @@ export declare function Card({ tone, paper, sm, row, cover, fold, centre, wide,
|
|
|
977
985
|
inlist?: any;
|
|
978
986
|
prefix?: string | undefined;
|
|
979
987
|
property?: string | undefined;
|
|
980
|
-
rel?: string | undefined;
|
|
981
988
|
resource?: string | undefined;
|
|
982
989
|
rev?: string | undefined;
|
|
983
990
|
typeof?: string | undefined;
|
|
@@ -4,6 +4,14 @@ export interface CardMediaProps extends ComponentProps<'div'> {
|
|
|
4
4
|
/** CardMedia — rounded media inside a card (a Placeholder or img); a corner JourneyBadge pins to it: the badge on the corner of a picture is the paper,
|
|
5
5
|
* its corner concentric with the media's; a theme's `--tile-badge-bg` / `--tile-badge-radius` still win. Ruled (Lh 2026-10-21). */
|
|
6
6
|
export declare function CardMedia({ className, ...rest }: CardMediaProps): import("react").JSX.Element;
|
|
7
|
+
export interface MediaBesideProps extends ComponentProps<'div'> {
|
|
8
|
+
/** the picture: a SMALL SQUARE at the side of the words (an `img` or a `Placeholder`), cropped to fill it, the media's corner. Knob `--media-beside-size`
|
|
9
|
+
* (default one and a half taps, 72) */
|
|
10
|
+
media: ReactNode;
|
|
11
|
+
}
|
|
12
|
+
/** MediaBeside — words with a small square picture at their END (a post's photo beside its words): the words take the room, the picture its own small square,
|
|
13
|
+
* both from the top. In a card's content; a full-width picture is `CardMedia`. Knobs `--media-beside-size`, `--media-beside-gap`. */
|
|
14
|
+
export declare function MediaBeside({ media, className, children, ...rest }: MediaBesideProps): import("react").JSX.Element;
|
|
7
15
|
export interface CardListProps extends ComponentProps<'div'> {
|
|
8
16
|
/** how many rows show before the list scrolls IN ITSELF, counted in rows, not a height: `2.5` = two whole rows and half of the third, the cut row
|
|
9
17
|
* saying there is more. The list measures its own rows (they wrap to any height) and keeps the window right when they change. Leave it out and the
|
package/dist/cards/CardParts.js
CHANGED
|
@@ -6,6 +6,11 @@ import { cx } from '../cx.js';
|
|
|
6
6
|
export function CardMedia({ className, ...rest }) {
|
|
7
7
|
return _jsx("div", { className: cx('card__media', className), ...rest });
|
|
8
8
|
}
|
|
9
|
+
/** MediaBeside — words with a small square picture at their END (a post's photo beside its words): the words take the room, the picture its own small square,
|
|
10
|
+
* both from the top. In a card's content; a full-width picture is `CardMedia`. Knobs `--media-beside-size`, `--media-beside-gap`. */
|
|
11
|
+
export function MediaBeside({ media, className, children, ...rest }) {
|
|
12
|
+
return (_jsxs("div", { className: cx('media-beside', className), ...rest, children: [_jsx("div", { className: "media-beside__words", children: children }), _jsx("div", { className: "media-beside__pic", children: media })] }));
|
|
13
|
+
}
|
|
9
14
|
/** CardList — a stack of `Card row`s, each its own boundary: a list of things to open or to pick (past requests to reuse). It stands on the base or straight in a sheet's
|
|
10
15
|
* body and scrolls with it; never inside a card (a card never wraps a card — `cardds check` rule `card-in-card`). Rows inside a card are `Rows`.
|
|
11
16
|
* A SHORT WINDOW of past entries under a form (`show={2.5}`): the list scrolls in itself, a few rows in sight; each row a `Card row as="label"` round a radio
|