@cloudgrid-io/ui 0.66.0 → 0.68.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/badge/owner.js +1 -1
  2. package/dist/badge/owner.js.map +1 -1
  3. package/dist/blocks/add-tile.d.ts +34 -1
  4. package/dist/blocks/add-tile.d.ts.map +1 -1
  5. package/dist/blocks/add-tile.js +34 -1
  6. package/dist/blocks/add-tile.js.map +1 -1
  7. package/dist/blocks/creation-search.d.ts +10 -1
  8. package/dist/blocks/creation-search.d.ts.map +1 -1
  9. package/dist/blocks/creation-search.js +5 -1
  10. package/dist/blocks/creation-search.js.map +1 -1
  11. package/dist/blocks/entity-card.d.ts.map +1 -1
  12. package/dist/blocks/entity-card.js +2 -2
  13. package/dist/blocks/entity-card.js.map +1 -1
  14. package/dist/blocks/entity-identity.d.ts +24 -1
  15. package/dist/blocks/entity-identity.d.ts.map +1 -1
  16. package/dist/blocks/entity-identity.js +19 -0
  17. package/dist/blocks/entity-identity.js.map +1 -1
  18. package/dist/blocks/header-menu.d.ts +6 -3
  19. package/dist/blocks/header-menu.d.ts.map +1 -1
  20. package/dist/blocks/header-menu.js +18 -11
  21. package/dist/blocks/header-menu.js.map +1 -1
  22. package/dist/blocks/home-bento.d.ts +1 -1
  23. package/dist/blocks/home-bento.js +1 -1
  24. package/dist/blocks/home-pinned.d.ts +144 -42
  25. package/dist/blocks/home-pinned.d.ts.map +1 -1
  26. package/dist/blocks/home-pinned.js +149 -28
  27. package/dist/blocks/home-pinned.js.map +1 -1
  28. package/dist/blocks/image-adjust-dialog.d.ts.map +1 -1
  29. package/dist/blocks/image-adjust-dialog.js +1 -1
  30. package/dist/blocks/image-adjust-dialog.js.map +1 -1
  31. package/dist/blocks/inspiration-cards.d.ts +98 -36
  32. package/dist/blocks/inspiration-cards.d.ts.map +1 -1
  33. package/dist/blocks/inspiration-cards.js +146 -27
  34. package/dist/blocks/inspiration-cards.js.map +1 -1
  35. package/dist/blocks/recent-plugs.d.ts +12 -0
  36. package/dist/blocks/recent-plugs.d.ts.map +1 -1
  37. package/dist/blocks/recent-plugs.js +4 -1
  38. package/dist/blocks/recent-plugs.js.map +1 -1
  39. package/dist/blocks/top-creations.d.ts +10 -0
  40. package/dist/blocks/top-creations.d.ts.map +1 -1
  41. package/dist/blocks/top-creations.js +6 -1
  42. package/dist/blocks/top-creations.js.map +1 -1
  43. package/dist/lib/thumbnail-identity.d.ts +47 -0
  44. package/dist/lib/thumbnail-identity.d.ts.map +1 -0
  45. package/dist/lib/thumbnail-identity.js +59 -0
  46. package/dist/lib/thumbnail-identity.js.map +1 -0
  47. package/package.json +2 -2
@@ -1 +1 @@
1
- {"version":3,"file":"header-menu.d.ts","sourceRoot":"","sources":["../../src/blocks/header-menu.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,IAAI,IAAI,aAAa,EAAE,MAAM,qBAAqB,CAAA;AAG3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAA;AA0BjE,iBAAS,iBAAiB,CAAC,EACzB,KAAmB,EACnB,SAAS,EACT,KAAK,EACL,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,mBAAmB,CAAC,GAAG;IACpD,gFAAgF;IAChF,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,qBAaA;AAED,iBAAS,iBAAiB,CAAC,EACzB,KAAK,EACL,MAAM,EACN,MAAc,EACd,SAAS,EACT,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,KAAK,EAAE,UAAU,CAAC,GAAG;IAC/C,yEAAyE;IACzE,KAAK,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB,8EAA8E;IAC9E,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACxB,uDAAuD;IACvD,MAAM,CAAC,EAAE,OAA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IAAI,EACJ,IAAI,EACJ,MAAM,EACN,OAAO,EACP,QAAgB,GACjB,EAAE;IACD,iDAAiD;IACjD,KAAK,EAAE,MAAM,CAAA;IACb,6CAA6C;IAC7C,IAAI,EAAE,KAAK,CAAC,SAAS,CAAA;IACrB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,aAAa,CAAC,QAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAA;IAC/C,OAAO,CAAC,EAAE,KAAK,CAAC,iBAAiB,CAAC,WAAW,CAAC,CAAA;IAC9C;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,qBAwCA;AAED,iBAAS,mBAAmB,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,aAAa,CAAC,SAAS,CAAC,KAAK,qBAWlF;AAED,iBAAS,kBAAkB,CAAC,EAC1B,MAAM,EACN,IAAI,EACJ,MAAM,EACN,SAAS,GACV,EAAE;IACD,gCAAgC;IAChC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAA;IACvB,IAAI,EAAE,KAAK,CAAC,SAAS,CAAA;IACrB,mDAAmD;IACnD,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,qBAUA;AAED,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,mBAAmB,GACpB,CAAA"}
@@ -16,13 +16,17 @@ import { DropdownMenuContent } from "../ui/dropdown-menu.js";
16
16
  * shadow, 12/8 padding, 2px between rows; 252 wide (account 258)
17
17
  * section an eyebrow label in slate-500 with an optional action ("+ New" in
18
18
  * `--cg-tertiary-dark`); 24 above it when `spaced` (SHARED WITH YOU)
19
- * row 40 tall (44 for the account menu), 8/20 padding, radius 12,
20
- * Medium 15 Ink; selected on the page colour with a trailing action
21
- * (the gear) whose right edge is 20 from the row's
22
- * band a 24px band with a 1px page-colour line, before Sign out
19
+ * row 36 tall in every header menu (ui#588; it was 40, and 44 in the
20
+ * account menu), 6/20 padding, radius 12, Medium 15 Ink, the hand
21
+ * cursor; selected (the current grid or space) on the brand tint,
22
+ * which a hover leaves as it is (ui#588; it was the page colour,
23
+ * almost the hover's grey), with a trailing action (the gear) whose
24
+ * right edge is 20 from the row's
25
+ * band a 16px band with a 1px page-colour line, before Sign out (ui#588;
26
+ * it was 24, with the 44px rows)
23
27
  *
24
28
  * Two calls the frames left open (spec §8.3, §8.4): row text is Ink (#222), not
25
- * the frames' #000; Sign out is the same 44px row as Profile. Hover and keyboard
29
+ * the frames' #000; Sign out is the same row as Profile. Hover and keyboard
26
30
  * highlight are not drawn in the frames and use `--cg-hover`.
27
31
  */
28
32
  const PANEL_WIDTH = 252;
@@ -35,10 +39,10 @@ function HeaderMenuSection({ label, action, spaced = false, className, children,
35
39
  return (_jsxs(MenuPrimitive.Group, { "data-slot": "header-menu-section", className: cn("flex flex-col gap-0.5", className), ...props, children: [_jsxs("div", { "data-slot": "header-menu-section-header", className: cn("flex items-center justify-between px-5 pb-2", spaced && "pt-6"), children: [_jsx(MenuPrimitive.GroupLabel, { "data-slot": "header-menu-section-label", className: "text-eyebrow text-steel uppercase", children: label }), action] }), children] }));
36
40
  }
37
41
  function HeaderMenuAction({ className, ...props }) {
38
- return (_jsx(MenuPrimitive.LinkItem, { "data-slot": "header-menu-action", className: cn("rounded-xs text-body-sm font-semibold text-cyan-dark no-underline outline-none", "data-highlighted:bg-(--cg-hover) focus-line", className), ...props }));
42
+ return (_jsx(MenuPrimitive.LinkItem, { "data-slot": "header-menu-action", className: cn("cursor-pointer rounded-xs text-body-sm font-semibold text-cyan-dark no-underline outline-none", "data-highlighted:bg-(--cg-hover) focus-line", className), ...props }));
39
43
  }
40
- function HeaderMenuRow({ children, leading, trailing, selected = false, size = "default", href, render, onClick, disabled, closeOnClick, className, }) {
41
- const itemClass = cn("flex min-w-0 flex-1 items-center gap-3 self-stretch rounded-md px-5 text-body-sm leading-none font-medium text-ink no-underline outline-none", "focus-line", "data-disabled:cursor-default data-disabled:opacity-50", size === "lg" ? "py-3" : "py-2", trailing && "pr-3");
44
+ function HeaderMenuRow({ children, leading, trailing, selected = false, href, render, onClick, disabled, closeOnClick, className, }) {
45
+ const itemClass = cn("flex min-w-0 flex-1 cursor-pointer items-center gap-3 self-stretch rounded-md px-5 py-1.5 text-body-sm leading-none font-medium text-ink no-underline outline-none", "focus-line", "data-disabled:cursor-default data-disabled:opacity-50", trailing && "pr-3");
42
46
  const content = (_jsxs(_Fragment, { children: [leading ? (_jsx("span", { "data-slot": "header-menu-row-leading", className: "inline-flex shrink-0 text-steel", children: leading })) : null, _jsx("span", { "data-slot": "header-menu-row-label", className: "-my-1 truncate leading-normal", children: children }), selected ? _jsx("span", { className: "sr-only", children: " (current)" }) : null] }));
43
47
  const shared = {
44
48
  "data-slot": "header-menu-item",
@@ -47,10 +51,13 @@ function HeaderMenuRow({ children, leading, trailing, selected = false, size = "
47
51
  onClick,
48
52
  closeOnClick,
49
53
  };
50
- return (_jsxs("div", { "data-slot": "header-menu-row", "data-selected": selected ? "" : undefined, className: cn("flex items-center self-stretch rounded-md", size === "lg" ? "min-h-11" : "min-h-10", selected ? "bg-page" : "has-[[data-highlighted]]:bg-(--cg-hover)", trailing && "pr-4", className), children: [href || render ? (_jsx(MenuPrimitive.LinkItem, { ...shared, href: href, render: render, children: content })) : (_jsx(MenuPrimitive.Item, { ...shared, disabled: disabled, children: content })), trailing] }));
54
+ return (_jsxs("div", { "data-slot": "header-menu-row", "data-selected": selected ? "" : undefined, className: cn("flex min-h-9 items-center self-stretch rounded-md",
55
+ // ui#588: the current row is the brand tint and keeps it under the
56
+ // pointer; the hover grey is for every other row, so the two never meet.
57
+ selected ? "bg-brand-tint" : "has-[[data-highlighted]]:bg-(--cg-hover)", trailing && "pr-4", className), children: [href || render ? (_jsx(MenuPrimitive.LinkItem, { ...shared, href: href, render: render, children: content })) : (_jsx(MenuPrimitive.Item, { ...shared, disabled: disabled, children: content })), trailing] }));
51
58
  }
52
59
  function HeaderMenuRowAction({ label, icon, href, render, onClick, disabled = false, }) {
53
- const className = cn("inline-flex size-7 shrink-0 items-center justify-center rounded-xs text-steel no-underline outline-none", "data-highlighted:bg-(--cg-hover) focus-line [&_svg]:size-5",
60
+ const className = cn("inline-flex size-7 shrink-0 cursor-pointer items-center justify-center rounded-xs text-steel no-underline outline-none", "data-highlighted:bg-(--cg-hover) focus-line [&_svg]:size-5",
54
61
  // The library's disabled look for a menu item (dropdown-menu.tsx), only
55
62
  // when disabled, so an enabled action's markup is what it was.
56
63
  disabled && "data-disabled:pointer-events-none data-disabled:opacity-50");
@@ -64,7 +71,7 @@ function HeaderMenuRowAction({ label, icon, href, render, onClick, disabled = fa
64
71
  return href || render ? (_jsx(MenuPrimitive.LinkItem, { "data-slot": "header-menu-row-action", "aria-label": label, href: href, render: render, onClick: onClick, className: className, children: icon })) : (_jsx(MenuPrimitive.Item, { "data-slot": "header-menu-row-action", "aria-label": label, onClick: onClick, className: className, children: icon }));
65
72
  }
66
73
  function HeaderMenuSeparator({ className, ...props }) {
67
- return (_jsx(MenuPrimitive.Separator, { "data-slot": "header-menu-separator", className: cn("relative h-6 shrink-0 after:absolute after:inset-x-0 after:top-1/2 after:h-px after:bg-page", className), ...props }));
74
+ return (_jsx(MenuPrimitive.Separator, { "data-slot": "header-menu-separator", className: cn("relative h-4 shrink-0 after:absolute after:inset-x-0 after:top-1/2 after:h-px after:bg-page", className), ...props }));
68
75
  }
69
76
  function HeaderMenuIdentity({ avatar, name, detail, className, }) {
70
77
  return (_jsxs("div", { "data-slot": "header-menu-identity", className: cn("flex items-center gap-4 pb-1.5", className), children: [avatar, _jsxs("div", { className: "flex min-w-0 flex-col", children: [_jsx("span", { className: "truncate text-body-sm font-medium text-ink", children: name }), detail ? _jsx("span", { className: "truncate text-body-sm text-steel", children: detail }) : null] })] }));
@@ -1 +1 @@
1
- {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M,GAAQ,CAAC,CAAC,CAAC,IAAI,IAC/E,IACF,CACP,CAAA;AACH,CAAC;AAED,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,mBAAmB,GACpB,CAAA"}
@@ -14,7 +14,7 @@ import * as React from "react";
14
14
  * 24 apart, and as that ratio at any other width; the cards in each column
15
15
  * 24 apart, in the caller's order. (The ratio is the design's own, not 5 and
16
16
  * 7 of 12: at 7 of 12 the right column is 737 and an idea card 219, too narrow
17
- * for Copy prompt and Paste in to share their line; at 776 it is 232.) Each card is as tall as
17
+ * for Pick it up and Paste in to share their line; at 776 it is 232.) Each card is as tall as
18
18
  * its content, and the next card in the column moves up to meet it: a column
19
19
  * is its own stack, not rows shared with the other column.
20
20
  *
@@ -17,7 +17,7 @@ import { PlugIcon } from "./icons.js";
17
17
  * 24 apart, and as that ratio at any other width; the cards in each column
18
18
  * 24 apart, in the caller's order. (The ratio is the design's own, not 5 and
19
19
  * 7 of 12: at 7 of 12 the right column is 737 and an idea card 219, too narrow
20
- * for Copy prompt and Paste in to share their line; at 776 it is 232.) Each card is as tall as
20
+ * for Pick it up and Paste in to share their line; at 776 it is 232.) Each card is as tall as
21
21
  * its content, and the next card in the column moves up to meet it: a column
22
22
  * is its own stack, not rows shared with the other column.
23
23
  *
@@ -11,14 +11,25 @@ import { type EntityKind } from "./entity-card.js";
11
11
  *
12
12
  * ## Pinned
13
13
  *
14
- * Three a page, each a thumbnail with the name under it and the filled pin, in
15
- * the brand purple, before the name. With more than three, an arrow at the
16
- * right pages through them, and after the last page it comes back to the first.
17
- * With fewer than three the rest of the row is the empty state's soft slots, so
18
- * a pinned creation is the same width whether it has company or not.
14
+ * Four a page, each a small My creations card (ui#591, Asaf's pick for
15
+ * console#1170, 2026-11-24): the Home card (`EntityCard look="home"`), smaller.
16
+ * The picture, with the views count at its top right (`views`: the Home card's
17
+ * views, in the Home card's materials, on one line: the eye, then the number);
18
+ * under it the filled pin, in the brand purple, before
19
+ * the name, which truncates; the type at the right of the name line; and the
20
+ * caller's `byline` ("By you · 2 days ago", or the owner's name and the time)
21
+ * under that. The whole card is the item's link. With more than four, an arrow
22
+ * at the right pages forward and, once the row has moved, its mirror at the left
23
+ * pages back (ui#587, Tamir's review in console#1170): the previous arrow is
24
+ * not there on the first page and the next arrow is not there on the last, so
25
+ * neither wraps around. When a press takes its own arrow away, keyboard focus
26
+ * goes to the other arrow rather than to the page. With fewer than four the
27
+ * rest of the row is the empty state's soft slots, each the size of a card, so
28
+ * a pinned creation is the same size whether it has company or not.
19
29
  *
20
30
  * Hover an item and its picture dims a little while an "Unpin" chip eases in
21
- * at the picture's top right. The chip is its own button, beside the item's
31
+ * at the picture's top right, where the views count was: the count gives way
32
+ * as the chip arrives (ui#591). The chip is its own button, beside the item's
22
33
  * link rather than in it (no nested interactive), laid over the picture: a
23
34
  * click on the chip calls `onUnpin`, a click anywhere else on the item opens
24
35
  * the creation. The chip is out of reach of the pointer until it shows, so a
@@ -45,39 +56,76 @@ import { type EntityKind } from "./entity-card.js";
45
56
  * top corners are the arrow's and the chip's. The name truncates before the
46
57
  * mark, which keeps its place. No `kind`, no mark.
47
58
  *
48
- * ## Two a page on a phone (Asaf, 2026-11-22, ui#559)
59
+ * ## Fewer where the box is narrower, two on a phone (ui#559, ui#591)
49
60
  *
50
- * Three a page need room for the arrow, a 12 gap and the whole chip on each
51
- * picture: 6 + 24 + 12 + 70 + 6 = 118 a picture, so 402 for the row with its
52
- * two gaps and the pager (`PINNED_THREE_MIN`, in rem at 16). Narrower than that,
53
- * Pinned shows two a page and the pager steps by two; the empty state's slots
54
- * follow, so a pinned creation is the same width with company or without. The
55
- * width is Pinned's own, never the screen's or the user agent's, and the
56
- * columns are CSS, as the inspiration card's rows are (#549): Pinned is a
57
- * container (`@container/pinned`), and under 25.125rem of it (402 at a 16
58
- * root) the row is two columns and the third of a server's page of three is
59
- * hidden, so the first paint is right and nothing re-lays out when the script
61
+ * A page needs room for the arrow, a 12 gap and the whole chip on each
62
+ * picture: 6 + 24 + 12 + 70 + 6 = 118 a picture, in its card's 2 a side (the
63
+ * hairline and the pad), 122 a card. Four with their three 12 gaps and the
64
+ * pager are 556 (`PINNED_FOUR_MIN`, in rem at 16), three 422
65
+ * (`PINNED_THREE_MIN`). Narrower than four's, Pinned shows three a page;
66
+ * narrower than three's (a phone), two; the pager steps by what shows, and the
67
+ * empty state's slots follow. The width is Pinned's own, never the screen's or
68
+ * the user agent's, and the columns are CSS, as the inspiration card's rows
69
+ * are (#549): Pinned is a container (`@container/pinned`); under 34.75rem of
70
+ * it (556 at a 16 root) the row is three columns and the fourth of a server's
71
+ * page of four is hidden, under 26.375rem (422) two and the third hidden too,
72
+ * so the first paint is right and nothing re-lays out when the script
60
73
  * arrives. The script only pages: it reads the width once in the commit that
61
- * mounts Pinned, then with one ResizeObserver (`useBand`), and steps two at a
62
- * time under the line. With exactly three pinned the server renders the pager
63
- * the phone needs, hidden from 25.125rem, where three fit without it.
74
+ * mounts Pinned, then with one ResizeObserver (`useBand`). With exactly four
75
+ * pinned the server renders the pager three and two a page need, hidden from
76
+ * 34.75rem, where four fit without it; with three, the pager two a page
77
+ * needs, hidden from 26.375rem.
64
78
  *
65
- * Empty: three soft slots, an outline pin in each, "Pin a creation" under.
79
+ * Empty: four soft slots, an outline pin in each, "Pin a creation" under. A
80
+ * slot is a card's size (ui#591): the card's frame with its line clear, the
81
+ * picture's box, and the card's text block, of a fixed height.
82
+ * With `onAddPin` (ui#587) each slot, the art and the label, is one button
83
+ * that calls it (the Console opens its search window, where every result has
84
+ * a pin): the hand cursor, the library's hover wash over the art's own
85
+ * ground, the keyboard line, and the label as its name. Without it the slot is
86
+ * a picture and a label, as it always was.
87
+ *
88
+ * ## No picture: the identity (ui#573)
89
+ *
90
+ * A creation with a `seed` (its stable id, the one its card passes as `seed`)
91
+ * shows its identity tile in the thumbnail when it has no picture, from that id
92
+ * and its name, exactly as its card in My creations does: the same look, the
93
+ * same monogram. With a picture the identity is laid under it, and a picture
94
+ * that fails to load is taken out, so it shows the identity rather than a
95
+ * blank or the browser's broken-picture mark; the picture element is drawn as
96
+ * before. Pinned's identity is the card's; the rows'
97
+ * 48-wide thumbnails take the small one (`size="thumb"`). Without a `seed`
98
+ * the thumbnail is exactly what it was: the picture, or the blank.
66
99
  *
67
100
  * ## The values
68
101
  *
69
- * thumbnail 216 by 98 at radius 8 (`rounded-xs`), on `bg-raised` until
70
- * the picture paints; the row's three are 8 apart, the empty
71
- * state's slots 24
72
- * label 9 under the picture: the 15 filled pin in the accent role
102
+ * card the Home card's frame: a hairline at 12 (`rounded-md`), a 1
103
+ * pad inside it, on `bg-card`; the row's four are 12 apart, the
104
+ * empty state's slots too
105
+ * thumbnail the Home card's 159/92, its top corners at 11 (the card's 12
106
+ * less the pad), on `bg-raised` until the picture paints
107
+ * views 6 in from the picture's top right, where the chip arrives: 20
108
+ * tall at radius 8, 6 aside, the 12 eye in `text-steel`, 4, the
109
+ * number in Small; the Home card's pill's white at 85% with its
110
+ * blur and the mark's lift, so it does not flip with the surface
111
+ * phone at two a page, the name line alone: no byline, no type mark,
112
+ * the text 42 tall; the Unpin chip the glyph alone in a 24
113
+ * circle, as the live arrow is (Asaf, 2026-11-24)
114
+ * text 62 tall, whatever it holds: 10 above, 12 aside and under. The
115
+ * name line, 20: the 15 filled pin in the accent role
73
116
  * (`--cg-text-accent`: the brand purple on the page, white on the
74
- * panel, lime on ink), 6, then the name in Small Medium
75
- * (`text-caption font-medium`)
76
- * arrow 24, the caret in the action colour (`text-cyan-dark`), 8 after
77
- * the row, centred on it
78
- * slot `bg-page` (the page grey; the hover wash on the panel and ink,
79
- * where the page grey would be a light slab), a 30 outline pin
80
- * in the middle, and
117
+ * panel, lime on ink), 6, the name in Small Medium (`text-caption
118
+ * font-medium`), and the 16 type mark at the right. 4 under it
119
+ * the byline in Small, the Home card's muted line
120
+ * on hover the chip and the live arrow 6 in from the picture's corners
121
+ * (8 from the card's), the count fading as they arrive
122
+ * arrows 24, the caret in the action colour (`text-cyan-dark`), 8 after
123
+ * the row (next) or 8 before it (previous), centred on it; the
124
+ * two are one class list, mirrored
125
+ * slot the card's box, its line clear: the picture's box in `bg-page`
126
+ * at radius 8 (the page grey; the hover wash on the panel and
127
+ * ink, where the page grey would be a light slab), a 30 outline
128
+ * pin in the middle, and the card's text block with
81
129
  * "Pin a creation" in Small, `text-faint-strong`
82
130
  * continue rows 40 tall, 6 apart: a 48 by 30 thumbnail at radius 8, 12,
83
131
  * the name in Small Medium, and the time at the right in Small
@@ -99,7 +147,7 @@ export type HomeCreation = {
99
147
  thumbnailSrc?: string;
100
148
  /** Where it opens. Without it, `onOpen` makes the item a button. */
101
149
  href?: string;
102
- /** What it is: draws the kind badge on a pinned creation's picture. */
150
+ /** What it is: draws its mark at the right of a pinned card's name line. */
103
151
  kind?: EntityKind;
104
152
  /**
105
153
  * The live creation. On a pinned item it draws the open live arrow, a new-tab
@@ -107,6 +155,26 @@ export type HomeCreation = {
107
155
  * Without it, no arrow.
108
156
  */
109
157
  liveHref?: string;
158
+ /**
159
+ * The creation's stable id, the one its card passes as `seed` (ui#573). With
160
+ * it, no picture (or one that fails to load) shows its identity tile, from
161
+ * this and `name`, rather than a blank. The look comes from this, never the
162
+ * name, so pass the id: a rename then keeps the look.
163
+ */
164
+ seed?: string;
165
+ /**
166
+ * How many have viewed it. On a pinned card, the views count at the
167
+ * picture's top right (ui#591): drawn short (1.2K), announced whole ("1,204
168
+ * views"), shown only above zero. It gives way to the Unpin chip on hover.
169
+ */
170
+ views?: number;
171
+ /**
172
+ * The line under a pinned card's name (ui#591): "By you · 2 days ago" for the
173
+ * reader's own creation, the owner's name and the time for another's
174
+ * ("Dana · 4 days ago"). The caller's words, as the Home card's `byline`
175
+ * is. Without it, no line; the card keeps its height.
176
+ */
177
+ byline?: React.ReactNode;
110
178
  };
111
179
  /** A creation the reader opened lately, and when, in the caller's words. */
112
180
  export type RecentlyOpenedCreation = HomeCreation & {
@@ -114,15 +182,40 @@ export type RecentlyOpenedCreation = HomeCreation & {
114
182
  opened: React.ReactNode;
115
183
  };
116
184
  /**
117
- * The least width of Pinned (its row and the pager) that shows three a page
118
- * (ui#559), in px at a 16px root: three pictures of 118 (6, the 24 arrow, 12,
119
- * the 70 chip, 6), two 8 gaps, and the 24 pager with its 8. It is measured with
120
- * the pager in, whether or not it shows, so showing it never changes the count.
185
+ * The least width of Pinned (its row and the pager) that shows four a page
186
+ * (ui#591), in px at a 16px root: four cards of 122 (a picture of 118: 6, the
187
+ * 24 arrow, 12, the 70 chip, 6; in its 2 of frame a side), three 12 gaps, and
188
+ * the 24 pager with its 8. It is measured with the pager in, whether or not it
189
+ * shows, so showing it never changes the count.
121
190
  */
122
- export declare const PINNED_THREE_MIN = 402;
191
+ export declare const PINNED_FOUR_MIN = 556;
192
+ /**
193
+ * The least width of Pinned that shows three a page (ui#559): three cards of
194
+ * 122, two 12 gaps and the pager, measured as `PINNED_FOUR_MIN` is. Narrower,
195
+ * two (a phone).
196
+ */
197
+ export declare const PINNED_THREE_MIN = 422;
198
+ /**
199
+ * Where Pinned's arrows are, `count` pinned on `page` (from 0) at `perPage` a
200
+ * page (ui#587): the previous arrow once the row has moved, the next arrow
201
+ * while a later page has something. No wrap around: `page` past the last is
202
+ * the last (a list that shrank shows its last page), before the first the
203
+ * first. Before the script has measured, the CSS shows fewer of a page than
204
+ * `perPage` where Pinned is narrower (three or two of the server's four;
205
+ * ui#559, ui#591), so one those columns leave behind needs the next arrow
206
+ * there and only there: `nextNarrowOnly` is the most a page shows where it is
207
+ * needed (3: under the four line; 2: under the three line), or false.
208
+ */
209
+ export declare function pinnedPager(count: number, page: number, perPage: 2 | 3 | 4): {
210
+ page: number;
211
+ pages: number;
212
+ prev: boolean;
213
+ next: boolean;
214
+ nextNarrowOnly: false | 2 | 3;
215
+ };
123
216
  /** How many pinned creations a page shows at `width` px of Pinned, the root font at `rem` px. */
124
- export declare function pinnedPerPage(width: number, rem: number): 2 | 3;
125
- declare function PinnedCreations({ items, onUnpin, onOpen, linkComponent, emptyLabel, unpinLabel, liveLabel, nextLabel, className, ...props }: Omit<React.ComponentProps<"div">, "children"> & {
217
+ export declare function pinnedPerPage(width: number, rem: number): 2 | 3 | 4;
218
+ declare function PinnedCreations({ items, onUnpin, onOpen, linkComponent, emptyLabel, unpinLabel, liveLabel, nextLabel, prevLabel, onAddPin, className, ...props }: Omit<React.ComponentProps<"div">, "children"> & {
126
219
  /** The pinned creations, in the caller's order. */
127
220
  items: readonly HomeCreation[];
128
221
  /** The reader pressed Unpin on one. No chip without it. */
@@ -137,8 +230,15 @@ declare function PinnedCreations({ items, onUnpin, onOpen, linkComponent, emptyL
137
230
  unpinLabel?: string;
138
231
  /** The open live arrow's name and tooltip. A screen reader hears the creation's name after it. */
139
232
  liveLabel?: string;
140
- /** The arrow's accessible name. */
233
+ /** The next arrow's accessible name. */
141
234
  nextLabel?: string;
235
+ /** The previous arrow's accessible name (ui#587). */
236
+ prevLabel?: string;
237
+ /**
238
+ * The reader pressed an empty slot, "Pin a creation" (ui#587): each slot is
239
+ * a button that calls this. Without it the slots are pictures, as before.
240
+ */
241
+ onAddPin?: () => void;
142
242
  }): React.JSX.Element;
143
243
  declare function RecentlyOpened({ items, onOpen, linkComponent, emptyLabel, className, ...props }: Omit<React.ComponentProps<"ul">, "children"> & {
144
244
  /** The creations, most recent first, as the caller orders them. */
@@ -155,11 +255,13 @@ declare function RecentlyOpened({ items, onOpen, linkComponent, emptyLabel, clas
155
255
  * The card shell is #533's `BentoCard`, its children 14 apart as the design
156
256
  * draws this card.
157
257
  */
158
- declare function PinnedCard({ pinned, recent, onUnpin, onOpen, linkComponent, title, continueTitle, className, ...props }: Omit<React.ComponentProps<"section">, "title" | "children"> & {
258
+ declare function PinnedCard({ pinned, recent, onUnpin, onOpen, onAddPin, linkComponent, title, continueTitle, className, ...props }: Omit<React.ComponentProps<"section">, "title" | "children"> & {
159
259
  pinned: readonly HomeCreation[];
160
260
  recent: readonly RecentlyOpenedCreation[];
161
261
  onUnpin?: (item: HomeCreation) => void;
162
262
  onOpen?: (item: HomeCreation) => void;
263
+ /** Makes each empty Pinned slot a button that calls it (ui#587). */
264
+ onAddPin?: () => void;
163
265
  linkComponent?: React.ElementType;
164
266
  title?: React.ReactNode;
165
267
  continueTitle?: React.ReactNode;
@@ -1 +1 @@
1
- {"version":3,"file":"home-pinned.d.ts","sourceRoot":"","sources":["../../src/blocks/home-pinned.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,EAAmB,KAAK,UAAU,EAAE,MAAM,2BAA2B,CAAA;AAM5E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwFG;AAEH,sCAAsC;AACtC,MAAM,MAAM,YAAY,GAAG;IACzB,wEAAwE;IACxE,EAAE,EAAE,MAAM,CAAA;IACV,gBAAgB;IAChB,IAAI,EAAE,MAAM,CAAA;IACZ,sDAAsD;IACtD,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,oEAAoE;IACpE,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,uEAAuE;IACvE,IAAI,CAAC,EAAE,UAAU,CAAA;IACjB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,4EAA4E;AAC5E,MAAM,MAAM,sBAAsB,GAAG,YAAY,GAAG;IAClD,wBAAwB;IACxB,MAAM,EAAE,KAAK,CAAC,SAAS,CAAA;CACxB,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,MAAM,CAAA;AAanC,iGAAiG;AACjG,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,CAAC,GAAG,CAAC,CAE/D;AAmLD,iBAAS,eAAe,CAAC,EACvB,KAAK,EACL,OAAO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