@fiestaboard/ui 5.4.0 → 5.4.1
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/dist/components/board/board-teaser.d.ts +9 -1
- package/dist/components/board/board-teaser.js +56 -52
- package/dist/components/board/board-teaser.js.map +1 -1
- package/dist/components/plugin/board-showcase.d.ts +8 -1
- package/dist/components/plugin/board-showcase.js +17 -16
- package/dist/components/plugin/board-showcase.js.map +1 -1
- package/dist/components/plugin/plugin-card.d.ts +8 -1
- package/dist/components/plugin/plugin-card.js +8 -7
- package/dist/components/plugin/plugin-card.js.map +1 -1
- package/dist/components/plugin/scaled-board-teaser.d.ts +4 -1
- package/dist/components/plugin/scaled-board-teaser.js +12 -11
- package/dist/components/plugin/scaled-board-teaser.js.map +1 -1
- package/dist/index.js +44 -44
- package/dist/lib/board-characters.d.ts +13 -0
- package/dist/lib/board-characters.js +1 -1
- package/dist/lib/board-characters.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type Code62Glyph } from "../../lib/board-characters";
|
|
1
2
|
export interface BoardTeaserProps {
|
|
2
3
|
/** Literal board line, e.g. `"{66}AAPL +1.88%"`. */
|
|
3
4
|
teaser: string;
|
|
@@ -5,6 +6,13 @@ export interface BoardTeaserProps {
|
|
|
5
6
|
tiles?: number;
|
|
6
7
|
size?: "sm" | "md" | "lg";
|
|
7
8
|
boardType?: "black" | "white";
|
|
9
|
+
/**
|
|
10
|
+
* Which glyph the board this strip stands for draws for code 62. Already
|
|
11
|
+
* resolved by the consumer — a strip is one row with no shape of its own, so
|
|
12
|
+
* it has no `deviceType` to resolve from; a Note consumer passes `"heart"`.
|
|
13
|
+
* Defaults to `"degree"`, the glyph every Flagship carried before 2026.
|
|
14
|
+
*/
|
|
15
|
+
code62Glyph?: Code62Glyph;
|
|
8
16
|
className?: string;
|
|
9
17
|
}
|
|
10
|
-
export declare const BoardTeaser: import("react").MemoExoticComponent<({ teaser, tiles, size, boardType, className, }: BoardTeaserProps) => import("react").JSX.Element>;
|
|
18
|
+
export declare const BoardTeaser: import("react").MemoExoticComponent<({ teaser, tiles, size, boardType, code62Glyph, className, }: BoardTeaserProps) => import("react").JSX.Element>;
|
|
@@ -1,49 +1,53 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { resolveColorCode as e } from "../../lib/board-colors.js";
|
|
3
|
-
import {
|
|
4
|
-
import { gapClasses as
|
|
5
|
-
import { SEAM_CLASS as
|
|
6
|
-
import { memo as
|
|
7
|
-
import { jsx as
|
|
3
|
+
import { applyCode62Glyph as t, messageToText as n, parseLine as r } from "../../lib/board-characters.js";
|
|
4
|
+
import { gapClasses as i, radiusClasses as a, sizeClasses as o, textSizeClasses as s } from "../../lib/board-metrics.js";
|
|
5
|
+
import { SEAM_CLASS as c, charLeafBoxShadow as l, seamStyle as u } from "./board-surfaces.js";
|
|
6
|
+
import { memo as d, useMemo as f } from "react";
|
|
7
|
+
import { jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
8
8
|
//#region src/components/board/board-teaser.tsx
|
|
9
|
-
var
|
|
10
|
-
let
|
|
11
|
-
let e =
|
|
12
|
-
for (; e.length <
|
|
9
|
+
var h = d(function({ teaser: d, tiles: h = 15, size: g = "sm", boardType: _ = "black", code62Glyph: v = "degree", className: y = "" }) {
|
|
10
|
+
let b = _ === "white", x = b ? "var(--color-board-surface-light)" : "var(--color-board-surface-dark)", S = b ? "var(--color-board-text-on-light)" : "var(--color-board-text-on-dark)", C = f(() => {
|
|
11
|
+
let e = r(d).slice(0, h).map((e) => t(e, v));
|
|
12
|
+
for (; e.length < h;) e.push({
|
|
13
13
|
type: "char",
|
|
14
14
|
value: " "
|
|
15
15
|
});
|
|
16
16
|
return e;
|
|
17
|
-
}, [
|
|
18
|
-
|
|
17
|
+
}, [
|
|
18
|
+
d,
|
|
19
|
+
h,
|
|
20
|
+
v
|
|
21
|
+
]), w = f(() => n(d, "flagship", v) || "Board teaser", [d, v]), T = g === "sm" ? b ? "0 1px 2px rgba(0,0,0,0.15)" : "0 1px 2px rgba(0,0,0,0.4)" : b ? "0 2px 4px rgba(0,0,0,0.2), inset 0 1px 2px rgba(0,0,0,0.1), inset 0 -1px 2px rgba(255,255,255,0.5), inset 1px 0 1px rgba(0,0,0,0.08), inset -1px 0 1px rgba(255,255,255,0.4)" : "0 2px 4px rgba(0,0,0,0.5), inset 0 1px 2px rgba(0,0,0,0.8), inset 0 -1px 1px rgba(255,255,255,0.08), inset 1px 0 1px rgba(0,0,0,0.5), inset -1px 0 1px rgba(255,255,255,0.05)";
|
|
22
|
+
return /* @__PURE__ */ p("div", {
|
|
19
23
|
role: "img",
|
|
20
|
-
"aria-label":
|
|
24
|
+
"aria-label": w,
|
|
21
25
|
"data-slot": "board-teaser",
|
|
22
|
-
className: `inline-flex max-w-full ${
|
|
23
|
-
children: /* @__PURE__ */
|
|
26
|
+
className: `inline-flex max-w-full ${y}`,
|
|
27
|
+
children: /* @__PURE__ */ p("div", {
|
|
24
28
|
"aria-hidden": "true",
|
|
25
|
-
className: `flex ${
|
|
26
|
-
children:
|
|
29
|
+
className: `flex ${i[g]}`,
|
|
30
|
+
children: C.map((t, n) => {
|
|
27
31
|
if (t.type === "color") {
|
|
28
|
-
let r = e(t.code,
|
|
29
|
-
return
|
|
32
|
+
let r = e(t.code, b);
|
|
33
|
+
return g === "sm" ? /* @__PURE__ */ p("div", {
|
|
30
34
|
"data-teaser-tile": "",
|
|
31
|
-
className: `${
|
|
35
|
+
className: `${o[g]} ${a[g]}`,
|
|
32
36
|
style: {
|
|
33
37
|
backgroundColor: r,
|
|
34
|
-
boxShadow:
|
|
38
|
+
boxShadow: T,
|
|
35
39
|
contain: "layout style paint"
|
|
36
40
|
}
|
|
37
|
-
}, n) : /* @__PURE__ */
|
|
41
|
+
}, n) : /* @__PURE__ */ p("div", {
|
|
38
42
|
"data-teaser-tile": "",
|
|
39
|
-
className: `relative ${
|
|
43
|
+
className: `relative ${o[g]} ${a[g]} overflow-hidden`,
|
|
40
44
|
style: {
|
|
41
|
-
backgroundColor:
|
|
42
|
-
boxShadow:
|
|
45
|
+
backgroundColor: x,
|
|
46
|
+
boxShadow: T,
|
|
43
47
|
contain: "layout style paint"
|
|
44
48
|
},
|
|
45
|
-
children: /* @__PURE__ */
|
|
46
|
-
className: `absolute ${
|
|
49
|
+
children: /* @__PURE__ */ p("div", {
|
|
50
|
+
className: `absolute ${a[g]} overflow-hidden`,
|
|
47
51
|
style: {
|
|
48
52
|
top: "3px",
|
|
49
53
|
bottom: "4px",
|
|
@@ -52,57 +56,57 @@ var m = u(function({ teaser: u, tiles: m = 15, size: h = "sm", boardType: g = "b
|
|
|
52
56
|
backgroundColor: r,
|
|
53
57
|
boxShadow: "0 2px 4px rgba(0,0,0,0.3), inset 0 1px 1px rgba(255,255,255,0.15), inset 0 -1px 1px rgba(0,0,0,0.25)"
|
|
54
58
|
},
|
|
55
|
-
children: /* @__PURE__ */
|
|
56
|
-
className:
|
|
57
|
-
style:
|
|
59
|
+
children: /* @__PURE__ */ p("div", {
|
|
60
|
+
className: c,
|
|
61
|
+
style: u[_]
|
|
58
62
|
})
|
|
59
63
|
})
|
|
60
64
|
}, n);
|
|
61
65
|
}
|
|
62
|
-
let r = t.value,
|
|
63
|
-
return
|
|
66
|
+
let r = t.value, i = r === "♥";
|
|
67
|
+
return g === "sm" ? /* @__PURE__ */ p("div", {
|
|
64
68
|
"data-teaser-tile": "",
|
|
65
|
-
className: `${
|
|
69
|
+
className: `${o[g]} ${a[g]} flex items-center justify-center`,
|
|
66
70
|
style: {
|
|
67
|
-
backgroundColor:
|
|
68
|
-
boxShadow:
|
|
71
|
+
backgroundColor: x,
|
|
72
|
+
boxShadow: T,
|
|
69
73
|
contain: "layout style paint"
|
|
70
74
|
},
|
|
71
|
-
children: r !== " " && /* @__PURE__ */
|
|
72
|
-
className: `${
|
|
73
|
-
style: { color:
|
|
75
|
+
children: r !== " " && /* @__PURE__ */ p("span", {
|
|
76
|
+
className: `${s[g]} font-mono font-semibold select-none leading-none`,
|
|
77
|
+
style: { color: i ? "#eb4034" : S },
|
|
74
78
|
children: r
|
|
75
79
|
})
|
|
76
|
-
}, n) : /* @__PURE__ */
|
|
80
|
+
}, n) : /* @__PURE__ */ m("div", {
|
|
77
81
|
"data-teaser-tile": "",
|
|
78
|
-
className: `relative ${
|
|
82
|
+
className: `relative ${o[g]} ${a[g]} overflow-hidden`,
|
|
79
83
|
style: {
|
|
80
|
-
backgroundColor:
|
|
81
|
-
boxShadow:
|
|
84
|
+
backgroundColor: x,
|
|
85
|
+
boxShadow: T,
|
|
82
86
|
contain: "layout style paint"
|
|
83
87
|
},
|
|
84
88
|
children: [
|
|
85
|
-
/* @__PURE__ */
|
|
89
|
+
/* @__PURE__ */ p("div", {
|
|
86
90
|
className: "absolute inset-0 flex items-center justify-center",
|
|
87
91
|
style: {
|
|
88
92
|
zIndex: 2,
|
|
89
|
-
boxShadow:
|
|
93
|
+
boxShadow: l[_]
|
|
90
94
|
},
|
|
91
|
-
children: r !== " " && /* @__PURE__ */
|
|
92
|
-
className: `${
|
|
93
|
-
style: { color:
|
|
95
|
+
children: r !== " " && /* @__PURE__ */ p("span", {
|
|
96
|
+
className: `${s[g]} font-mono font-semibold select-none leading-none`,
|
|
97
|
+
style: { color: i ? "#eb4034" : S },
|
|
94
98
|
children: r
|
|
95
99
|
})
|
|
96
100
|
}),
|
|
97
|
-
/* @__PURE__ */
|
|
98
|
-
className:
|
|
99
|
-
style:
|
|
101
|
+
/* @__PURE__ */ p("div", {
|
|
102
|
+
className: c,
|
|
103
|
+
style: u[_]
|
|
100
104
|
}),
|
|
101
|
-
/* @__PURE__ */
|
|
105
|
+
/* @__PURE__ */ p("div", {
|
|
102
106
|
className: "absolute inset-0 pointer-events-none",
|
|
103
107
|
style: {
|
|
104
108
|
zIndex: 1,
|
|
105
|
-
background:
|
|
109
|
+
background: b ? "linear-gradient(180deg, rgba(255,255,255,0.3) 0%, transparent 50%, rgba(0,0,0,0.05) 100%)" : "linear-gradient(180deg, rgba(255,255,255,0.05) 0%, transparent 50%, rgba(0,0,0,0.2) 100%)"
|
|
106
110
|
}
|
|
107
111
|
})
|
|
108
112
|
]
|
|
@@ -112,6 +116,6 @@ var m = u(function({ teaser: u, tiles: m = 15, size: h = "sm", boardType: g = "b
|
|
|
112
116
|
});
|
|
113
117
|
});
|
|
114
118
|
//#endregion
|
|
115
|
-
export {
|
|
119
|
+
export { h as BoardTeaser };
|
|
116
120
|
|
|
117
121
|
//# sourceMappingURL=board-teaser.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"board-teaser.js","names":[],"sources":["../../../src/components/board/board-teaser.tsx"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"board-teaser.js","names":[],"sources":["../../../src/components/board/board-teaser.tsx"],"mappings":";;;;;;;;AA4CA,IAAa,IAAc,EAAK,SAAqB,EACnD,WACA,WAAQ,IACR,UAAO,MACP,eAAY,SACZ,iBAAc,UACd,eAAY,MACO;CACnB,IAAM,IAAe,MAAc,SAC7B,IAAS,IAAe,qCAAqC,mCAC7D,IAAY,IAAe,qCAAqC,mCAEhE,IAAM,QAA4B;EACtC,IAAM,IAAS,EAAU,CAAM,CAAC,CAC7B,MAAM,GAAG,CAAK,CAAC,CACf,KAAK,MAAU,EAAiB,GAAO,CAAW,CAAC;EACtD,OAAO,EAAO,SAAS,IACrB,EAAO,KAAK;GAAE,MAAM;GAAQ,OAAO;EAAI,CAAC;EAE1C,OAAO;CACT,GAAG;EAAC;EAAQ;EAAO;CAAW,CAAC,GASzB,IAAQ,QAAc,EAAc,GAAQ,YAAY,CAAW,KAAK,gBAAgB,CAAC,GAAQ,CAAW,CAAC,GAM7G,IACJ,MAAS,OACL,IACE,+BACA,8BACF,IACE,iLACA;CAER,OACE,kBAAC,OAAD;EAAK,MAAK;EAAM,cAAY;EAAO,aAAU;EAAe,WAAW,0BAA0B;EAC/F,UAAA,kBAAC,OAAD;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E,QAAQ;QAAG,WAAW,EAAkB;OAAW;OAE3D,UAAA,MAAS,OACR,kBAAC,QAAD;QACE,WAAW,GAAG,EAAgB,GAAM;QACpC,OAAO,EAAE,OAAO,IAAU,YAAY,EAAU;QAE/C,UAAA;OACG,CAAA;MAEL,CAAA;MACL,kBAAC,OAAD;OAAK,WAAW;OAAY,OAAO,EAAU;MAAa,CAAA;MAC1D,kBAAC,OAAD;OACE,WAAU;OACV,OAAO;QACL,QAAQ;QACR,YAAY,IACR,8FACA;OACN;MACD,CAAA;KACE;IAjCE,GAAA,CAiCF;GAET,CAAC;EACE,CAAA;CACF,CAAA;AAET,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Code62Glyph } from "../../lib/board-characters";
|
|
1
2
|
import { type BoardPreviewEntry, type PreviewShapeLabels } from "../../lib/board-previews";
|
|
2
3
|
export interface BoardShowcaseLabels extends PreviewShapeLabels {
|
|
3
4
|
/** Accessible name for the shape tab list. */
|
|
@@ -16,9 +17,15 @@ export interface BoardShowcaseProps {
|
|
|
16
17
|
size?: "sm" | "md" | "lg";
|
|
17
18
|
/** Controlled board colour. Leave unset to let the showcase own it. */
|
|
18
19
|
boardType?: "black" | "white";
|
|
20
|
+
/**
|
|
21
|
+
* Which glyph the viewer's board draws for code 62 (FiestaBoard#1666).
|
|
22
|
+
* Flagship previews only — a `note` or `note_array` preview always draws the
|
|
23
|
+
* heart its hardware carries, whatever this says. Defaults to `"degree"`.
|
|
24
|
+
*/
|
|
25
|
+
code62Glyph?: Code62Glyph;
|
|
19
26
|
defaultBoardType?: "black" | "white";
|
|
20
27
|
onBoardTypeChange?: (boardType: "black" | "white") => void;
|
|
21
28
|
labels?: Partial<BoardShowcaseLabels>;
|
|
22
29
|
className?: string;
|
|
23
30
|
}
|
|
24
|
-
export declare function BoardShowcase({ previews, previewLabel, size, boardType, defaultBoardType, onBoardTypeChange, labels, className, }: BoardShowcaseProps): import("react").JSX.Element | null;
|
|
31
|
+
export declare function BoardShowcase({ previews, previewLabel, size, boardType, code62Glyph, defaultBoardType, onBoardTypeChange, labels, className, }: BoardShowcaseProps): import("react").JSX.Element | null;
|
|
@@ -13,26 +13,26 @@ var f = {
|
|
|
13
13
|
blackBoard: "Black Board",
|
|
14
14
|
whiteBoard: "White Board"
|
|
15
15
|
}, p = "rounded-full border px-4 py-1.5 text-xs font-medium transition-colors data-[active]:border-primary data-[active]:bg-primary data-[active]:text-primary-foreground data-[active]:font-semibold hover:border-brand hover:text-brand data-[active]:hover:text-primary-foreground";
|
|
16
|
-
function m({ previews: o, previewLabel: m, size: h = "md", boardType: g,
|
|
17
|
-
let
|
|
16
|
+
function m({ previews: o, previewLabel: m, size: h = "md", boardType: g, code62Glyph: _, defaultBoardType: v = "black", onBoardTypeChange: y, labels: b, className: x }) {
|
|
17
|
+
let S = {
|
|
18
18
|
...f,
|
|
19
|
-
...
|
|
20
|
-
}, [
|
|
21
|
-
function
|
|
22
|
-
g === void 0 &&
|
|
19
|
+
...b
|
|
20
|
+
}, [C, w] = l(v), T = g ?? C;
|
|
21
|
+
function E(e) {
|
|
22
|
+
g === void 0 && w(e), y?.(e);
|
|
23
23
|
}
|
|
24
24
|
if (o.length === 0) return null;
|
|
25
|
-
let
|
|
25
|
+
let D = s(o, S);
|
|
26
26
|
return /* @__PURE__ */ d("div", {
|
|
27
27
|
"data-slot": "board-showcase",
|
|
28
|
-
className: e("flex flex-col items-center gap-4",
|
|
28
|
+
className: e("flex flex-col items-center gap-4", x),
|
|
29
29
|
children: [/* @__PURE__ */ d(t, {
|
|
30
30
|
defaultValue: 0,
|
|
31
31
|
className: "flex w-full flex-col items-center gap-4",
|
|
32
32
|
children: [o.length > 1 && /* @__PURE__ */ u(r, {
|
|
33
|
-
"aria-label":
|
|
33
|
+
"aria-label": S.boardShape,
|
|
34
34
|
className: "h-auto gap-2 rounded-full bg-transparent p-0",
|
|
35
|
-
children:
|
|
35
|
+
children: D.map((e, t) => /* @__PURE__ */ u(i, {
|
|
36
36
|
value: t,
|
|
37
37
|
className: p,
|
|
38
38
|
children: e
|
|
@@ -43,25 +43,26 @@ function m({ previews: o, previewLabel: m, size: h = "md", boardType: g, default
|
|
|
43
43
|
children: /* @__PURE__ */ u(a, {
|
|
44
44
|
message: c(e),
|
|
45
45
|
size: h,
|
|
46
|
-
boardType:
|
|
46
|
+
boardType: T,
|
|
47
47
|
deviceType: e.device_type ?? "flagship",
|
|
48
|
+
code62Glyph: _,
|
|
48
49
|
notesWide: e.notes_wide ?? 1,
|
|
49
50
|
notesTall: e.notes_tall ?? 1,
|
|
50
51
|
previewLabel: m
|
|
51
52
|
})
|
|
52
|
-
},
|
|
53
|
+
}, D[t]))]
|
|
53
54
|
}), /* @__PURE__ */ u("div", {
|
|
54
55
|
role: "group",
|
|
55
|
-
"aria-label":
|
|
56
|
+
"aria-label": S.boardColor,
|
|
56
57
|
className: "flex",
|
|
57
58
|
children: ["black", "white"].map((t) => {
|
|
58
|
-
let n =
|
|
59
|
+
let n = T === t;
|
|
59
60
|
return /* @__PURE__ */ u("button", {
|
|
60
61
|
type: "button",
|
|
61
62
|
"aria-pressed": n,
|
|
62
|
-
onClick: () =>
|
|
63
|
+
onClick: () => E(t),
|
|
63
64
|
className: e("border px-4 py-1.5 text-xs font-medium transition-colors", "first:rounded-l-full last:rounded-r-full [&:not(:last-child)]:border-r-0", "focus-ring", n ? "border-primary bg-primary font-semibold text-primary-foreground" : "text-muted-foreground hover:border-brand hover:text-brand"),
|
|
64
|
-
children: t === "black" ?
|
|
65
|
+
children: t === "black" ? S.blackBoard : S.whiteBoard
|
|
65
66
|
}, t);
|
|
66
67
|
})
|
|
67
68
|
})]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"board-showcase.js","names":[],"sources":["../../../src/components/plugin/board-showcase.tsx"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"board-showcase.js","names":[],"sources":["../../../src/components/plugin/board-showcase.tsx"],"mappings":";;;;;;;;AAkCA,IA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E,MAAK;KACL,gBAAc;KACd,eAAe,EAAgB,CAAK;KACpC,WAAW,EACT,4DACA,4EACA,cACA,IACI,oEACA,2DACN;KAEC,UAAA,MAAU,UAAU,EAAE,aAAa,EAAE;IAChC,GAdD,CAcC;GAEZ,CAAC;EACE,CAAA,CACF;;AAET"}
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* without nesting one interactive element inside another.
|
|
10
10
|
*/
|
|
11
11
|
import type { CSSProperties, ReactNode } from "react";
|
|
12
|
+
import type { Code62Glyph } from "../../lib/board-characters";
|
|
12
13
|
export interface PluginCardProps {
|
|
13
14
|
name: string;
|
|
14
15
|
description?: ReactNode;
|
|
@@ -24,6 +25,12 @@ export interface PluginCardProps {
|
|
|
24
25
|
/** Literal board line, at most 15 tiles. Omit to hide the teaser footer. */
|
|
25
26
|
teaser?: string;
|
|
26
27
|
boardType?: "black" | "white";
|
|
28
|
+
/**
|
|
29
|
+
* Which glyph the viewer's board draws for code 62 — a teaser carrying a
|
|
30
|
+
* temperature is `°` on an older Flagship and `♥` on one built from 2026
|
|
31
|
+
* (FiestaBoard#1666). Defaults to `"degree"`.
|
|
32
|
+
*/
|
|
33
|
+
code62Glyph?: Code62Glyph;
|
|
27
34
|
/**
|
|
28
35
|
* Renders the card's primary link. Receives the class that stretches it over
|
|
29
36
|
* the card, and the card title as children.
|
|
@@ -37,4 +44,4 @@ export interface PluginCardProps {
|
|
|
37
44
|
className?: string;
|
|
38
45
|
style?: CSSProperties;
|
|
39
46
|
}
|
|
40
|
-
export declare function PluginCard({ name, description, authorLabel, category, categoryLabel, teaser, boardType, renderLink, action, className, style, }: PluginCardProps): import("react").JSX.Element;
|
|
47
|
+
export declare function PluginCard({ name, description, authorLabel, category, categoryLabel, teaser, boardType, code62Glyph, renderLink, action, className, style, }: PluginCardProps): import("react").JSX.Element;
|
|
@@ -7,11 +7,11 @@ import { ScaledBoardTeaser as i } from "./scaled-board-teaser.js";
|
|
|
7
7
|
import { jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
8
8
|
//#region src/components/plugin/plugin-card.tsx
|
|
9
9
|
var s = "after:absolute after:inset-0 after:rounded-xl after:content-[''] outline-none focus-visible:after:ring-[3px] focus-visible:after:ring-ring/50 text-foreground no-underline hover:no-underline hover:text-foreground";
|
|
10
|
-
function c({ name: c, description: l, authorLabel: u, category: d, categoryLabel: f, teaser: p, boardType: m = "black",
|
|
10
|
+
function c({ name: c, description: l, authorLabel: u, category: d, categoryLabel: f, teaser: p, boardType: m = "black", code62Glyph: h, renderLink: g, action: _, className: v, style: y }) {
|
|
11
11
|
return /* @__PURE__ */ o("div", {
|
|
12
12
|
"data-slot": "plugin-card",
|
|
13
|
-
style:
|
|
14
|
-
className: e("group relative flex h-full flex-col overflow-hidden rounded-xl border bg-card text-card-foreground", "shadow-card transition-[transform,box-shadow] duration-base hover:-translate-y-1 hover:shadow-lg", "motion-reduce:transition-none motion-reduce:hover:translate-y-0",
|
|
13
|
+
style: y,
|
|
14
|
+
className: e("group relative flex h-full flex-col overflow-hidden rounded-xl border bg-card text-card-foreground", "shadow-card transition-[transform,box-shadow] duration-base hover:-translate-y-1 hover:shadow-lg", "motion-reduce:transition-none motion-reduce:hover:translate-y-0", v),
|
|
15
15
|
children: [/* @__PURE__ */ o("div", {
|
|
16
16
|
className: "flex flex-1 flex-col gap-2 p-4",
|
|
17
17
|
children: [
|
|
@@ -20,7 +20,7 @@ function c({ name: c, description: l, authorLabel: u, category: d, categoryLabel
|
|
|
20
20
|
children: [/* @__PURE__ */ a(t, {
|
|
21
21
|
level: 3,
|
|
22
22
|
className: "min-w-0 text-base",
|
|
23
|
-
children:
|
|
23
|
+
children: g({
|
|
24
24
|
className: s,
|
|
25
25
|
children: c
|
|
26
26
|
})
|
|
@@ -44,9 +44,9 @@ function c({ name: c, description: l, authorLabel: u, category: d, categoryLabel
|
|
|
44
44
|
size: "xs",
|
|
45
45
|
className: "truncate",
|
|
46
46
|
children: u
|
|
47
|
-
}) : /* @__PURE__ */ a("span", {}),
|
|
47
|
+
}) : /* @__PURE__ */ a("span", {}), _ && /* @__PURE__ */ a("div", {
|
|
48
48
|
className: "relative z-10 shrink-0",
|
|
49
|
-
children:
|
|
49
|
+
children: _
|
|
50
50
|
})]
|
|
51
51
|
})
|
|
52
52
|
]
|
|
@@ -54,7 +54,8 @@ function c({ name: c, description: l, authorLabel: u, category: d, categoryLabel
|
|
|
54
54
|
className: "border-t bg-muted/30 px-3 py-4",
|
|
55
55
|
children: /* @__PURE__ */ a(i, {
|
|
56
56
|
teaser: p,
|
|
57
|
-
boardType: m
|
|
57
|
+
boardType: m,
|
|
58
|
+
code62Glyph: h
|
|
58
59
|
})
|
|
59
60
|
})]
|
|
60
61
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin-card.js","names":[],"sources":["../../../src/components/plugin/plugin-card.tsx"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"plugin-card.js","names":[],"sources":["../../../src/components/plugin/plugin-card.tsx"],"mappings":";;;;;;;;AAuBA,IAAM,IACJ;AAoCF,SAAgB,EAAW,EACzB,SACA,gBACA,gBACA,aACA,kBACA,WACA,eAAY,SACZ,gBACA,eACA,WACA,cACA,YACkB;CAClB,OACE,kBAAC,OAAD;EACE,aAAU;EACH;EACP,WAAW,EACT,sGACA,oGACA,mEACA,CACF;EARF,UAAA,CAUE,kBAAC,OAAD;GAAK,WAAU;GAAf,UAAA;IACE,kBAAC,OAAD;KAAK,WAAU;KAAf,UAAA,CACE,kBAAC,GAAD;MAAS,OAAO;MAAG,WAAU;MAC1B,UAAA,EAAW;OAAE,WAAW;OAAsB,UAAU;MAAK,CAAC;KACxD,CAAA,GACR,KAAY,kBAAC,GAAD;MAA+B;MAAU,OAAO;MAAe,WAAU;KAAW,CAAA,CAC9F;;IAEJ,KACC,kBAAC,GAAD;KAAM,MAAK;KAAQ,MAAK;KAAK,WAAU;KACpC,UAAA;IACG,CAAA;IAGR,kBAAC,OAAD;KAAK,WAAU;KAAf,UAAA,CACG,IACC,kBAAC,GAAD;MAAM,IAAG;MAAO,MAAK;MAAQ,MAAK;MAAK,WAAU;MAC9C,UAAA;KACG,CAAA,IAEN,kBAAC,QAAD,CAAO,CAAA,GAER,KAAU,kBAAC,OAAD;MAAK,WAAU;MAA0B,UAAA;KAAY,CAAA,CAC7D;;GACF;EAEJ,CAAA,GAAA,KACC,kBAAC,OAAD;GAAK,WAAU;GACb,UAAA,kBAAC,GAAD;IAA2B;IAAmB;IAAwB;GAAc,CAAA;EACjF,CAAA,CAEJ;;AAET"}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
+
import type { Code62Glyph } from "../../lib/board-characters";
|
|
1
2
|
export interface ScaledBoardTeaserProps {
|
|
2
3
|
/** Literal board line, e.g. `"{66}AQI 45 CLEAR"`. */
|
|
3
4
|
teaser: string;
|
|
4
5
|
boardType?: "black" | "white";
|
|
6
|
+
/** Which glyph the board draws for code 62; see `BoardTeaser`. */
|
|
7
|
+
code62Glyph?: Code62Glyph;
|
|
5
8
|
/** Strip width in tiles. */
|
|
6
9
|
tiles?: number;
|
|
7
10
|
minScale?: number;
|
|
8
11
|
maxScale?: number;
|
|
9
12
|
className?: string;
|
|
10
13
|
}
|
|
11
|
-
export declare function ScaledBoardTeaser({ teaser, boardType, tiles, minScale, maxScale, className, }: ScaledBoardTeaserProps): import("react").JSX.Element;
|
|
14
|
+
export declare function ScaledBoardTeaser({ teaser, boardType, code62Glyph, tiles, minScale, maxScale, className, }: ScaledBoardTeaserProps): import("react").JSX.Element;
|
|
@@ -5,31 +5,32 @@ import { useEffect as n, useRef as r, useState as i } from "react";
|
|
|
5
5
|
import { jsx as a } from "react/jsx-runtime";
|
|
6
6
|
//#region src/components/plugin/scaled-board-teaser.tsx
|
|
7
7
|
var o = 18;
|
|
8
|
-
function s({ teaser: s, boardType: c = "black",
|
|
9
|
-
let
|
|
8
|
+
function s({ teaser: s, boardType: c = "black", code62Glyph: l, tiles: u = 15, minScale: d = .85, maxScale: f = 1.5, className: p }) {
|
|
9
|
+
let m = r(null), [h, g] = i(1);
|
|
10
10
|
return n(() => {
|
|
11
|
-
let e =
|
|
11
|
+
let e = m.current, t = e?.firstElementChild;
|
|
12
12
|
if (!e || !t) return;
|
|
13
13
|
let n = () => {
|
|
14
|
-
t.offsetWidth > 0 &&
|
|
14
|
+
t.offsetWidth > 0 && g(Math.min(f, Math.max(d, e.clientWidth / t.offsetWidth)));
|
|
15
15
|
};
|
|
16
16
|
n();
|
|
17
17
|
let r = new ResizeObserver(n);
|
|
18
18
|
return r.observe(e), () => r.disconnect();
|
|
19
|
-
}, [
|
|
20
|
-
ref:
|
|
19
|
+
}, [d, f]), /* @__PURE__ */ a("div", {
|
|
20
|
+
ref: m,
|
|
21
21
|
"data-slot": "scaled-board-teaser",
|
|
22
|
-
className: e("flex justify-center overflow-hidden",
|
|
23
|
-
style: { height: `${o *
|
|
22
|
+
className: e("flex justify-center overflow-hidden", p),
|
|
23
|
+
style: { height: `${o * h}px` },
|
|
24
24
|
children: /* @__PURE__ */ a("div", {
|
|
25
25
|
style: {
|
|
26
|
-
transform: `scale(${
|
|
26
|
+
transform: `scale(${h})`,
|
|
27
27
|
transformOrigin: "top center"
|
|
28
28
|
},
|
|
29
29
|
children: /* @__PURE__ */ a(t, {
|
|
30
30
|
teaser: s,
|
|
31
|
-
tiles:
|
|
32
|
-
boardType: c
|
|
31
|
+
tiles: u,
|
|
32
|
+
boardType: c,
|
|
33
|
+
code62Glyph: l
|
|
33
34
|
})
|
|
34
35
|
})
|
|
35
36
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scaled-board-teaser.js","names":[],"sources":["../../../src/components/plugin/scaled-board-teaser.tsx"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"scaled-board-teaser.js","names":[],"sources":["../../../src/components/plugin/scaled-board-teaser.tsx"],"mappings":";;;;;;AAiBA,IAAM,IAAe;AAerB,SAAgB,EAAkB,EAChC,WACA,eAAY,SACZ,gBACA,WAAQ,IACR,cAAW,KACX,cAAW,KACX,gBACyB;CACzB,IAAM,IAAe,EAAuB,IAAI,GAC1C,CAAC,GAAO,KAAY,EAAS,CAAC;CAkBpC,OAhBA,QAAgB;EACd,IAAM,IAAY,EAAa,SACzB,IAAQ,GAAW;EACzB,IAAI,CAAC,KAAa,CAAC,GAAO;EAC1B,IAAM,UAAgB;GAEpB,AAAI,EAAM,cAAc,KACtB,EAAS,KAAK,IAAI,GAAU,KAAK,IAAI,GAAU,EAAU,cAAc,EAAM,WAAW,CAAC,CAAC;EAE9F;EACA,EAAQ;EACR,IAAM,IAAW,IAAI,eAAe,CAAO;EAE3C,OADA,EAAS,QAAQ,CAAS,SACb,EAAS,WAAW;CACnC,GAAG,CAAC,GAAU,CAAQ,CAAC,GAGrB,kBAAC,OAAD;EACE,KAAK;EACL,aAAU;EACV,WAAW,EAAG,uCAAuC,CAAS;EAC9D,OAAO,EAAE,QAAQ,GAAG,IAAe,EAAM,IAAI;EAE7C,UAAA,kBAAC,OAAD;GAAK,OAAO;IAAE,WAAW,SAAS,EAAM;IAAI,iBAAiB;GAAa;GACxE,UAAA,kBAAC,GAAD;IAAqB;IAAe;IAAkB;IAAwB;GAAc,CAAA;EACzF,CAAA;CACF,CAAA;AAET"}
|
package/dist/index.js
CHANGED
|
@@ -62,47 +62,47 @@ import { SkipToContent as In } from "./components/chrome/skip-to-content.js";
|
|
|
62
62
|
import { ThemeToggle as Ln } from "./components/chrome/theme-toggle.js";
|
|
63
63
|
import { WizardProgress as Rn } from "./components/wizard/wizard-progress.js";
|
|
64
64
|
import { ALL_COLOR_CODES as zn, AVAILABLE_COLORS as Bn, BOARD_COLORS as Vn, COLOR_CODE_MAP as Hn, COLOR_DISPLAY as Un, FIESTABOARD_COLORS as Wn, getBoardColor as Gn, isValidBoardColor as Kn, resolveColorCode as qn } from "./lib/board-colors.js";
|
|
65
|
-
import { BOARD_CHARS as Jn, EXTRA_CHARS as Yn,
|
|
66
|
-
import { BoardTeaser as
|
|
67
|
-
import { BoardBackdrop as
|
|
68
|
-
import { WizardShell as
|
|
69
|
-
import { DEVICE_DIMENSIONS as
|
|
70
|
-
import { BoardDisplay as
|
|
71
|
-
import { ScaledBoardDisplay as
|
|
72
|
-
import { StaticBoardDisplay as
|
|
73
|
-
import { DEFAULT_SHAPE_LABELS as
|
|
74
|
-
import { BarList as
|
|
75
|
-
import { StatStrip as
|
|
76
|
-
import { BoardShowcase as
|
|
77
|
-
import { PLUGIN_CATEGORIES as
|
|
78
|
-
import { ScaledBoardTeaser as
|
|
79
|
-
import { PluginCard as
|
|
80
|
-
import { BOARD_CODE_TO_COLOR as
|
|
81
|
-
import { NodeViewInjectionProvider as
|
|
82
|
-
import { ColorTileNodeView as
|
|
83
|
-
import { ColorTileNode as
|
|
84
|
-
import { DEFAULT_FILL_SPACE_NODE_VIEW_LABELS as
|
|
85
|
-
import { FillSpaceNode as
|
|
86
|
-
import { DEFAULT_FORMULA_NODE_VIEW_LABELS as
|
|
87
|
-
import { FormulaNode as
|
|
88
|
-
import { LineNavigation as
|
|
89
|
-
import { SingleParagraphDoc as
|
|
90
|
-
import { TrailingNewline as
|
|
91
|
-
import { DEFAULT_VARIABLE_NODE_VIEW_LABELS as
|
|
92
|
-
import { VariableNode as
|
|
93
|
-
import { DEFAULT_WRAPPED_TEXT_VIEW_LABELS as
|
|
94
|
-
import { WrappedTextNode as
|
|
95
|
-
import { ColorPickerContent as
|
|
96
|
-
import { DRAW_CHARS as
|
|
97
|
-
import { DEFAULT_DRAW_CHAR_PICKER_LABELS as
|
|
98
|
-
import { DEFAULT_FORMATTING_PICKER_LABELS as
|
|
99
|
-
import { DEFAULT_TOOLBAR_DROPDOWN_LABELS as
|
|
100
|
-
import { parseLineContent as
|
|
101
|
-
import { insertTemplateContent as
|
|
102
|
-
import { DEFAULT_TEMPLATE_EDITOR_TOOLBAR_LABELS as
|
|
103
|
-
import { buildStrokeTransaction as
|
|
104
|
-
import { DEFAULT_TEMPLATE_EDITOR_LABELS as
|
|
105
|
-
import { DEFAULT_FILTER_PICKER_LABELS as
|
|
106
|
-
import { DEFAULT_VARIABLE_PICKER_LABELS as
|
|
107
|
-
import { calculateLineLength as
|
|
108
|
-
export { zn as ALL_COLOR_CODES, Bn as AVAILABLE_COLORS, t as Accordion, n as AccordionContent, r as AccordionItem, i as AccordionTrigger, x as Alert, S as AlertDescription, U as AlertDialog, W as AlertDialogAction, G as AlertDialogCancel, K as AlertDialogContent, q as AlertDialogDescription, J as AlertDialogFooter, Y as AlertDialogHeader, X as AlertDialogOverlay, Z as AlertDialogPortal, Q as AlertDialogTitle, $ as AlertDialogTrigger, C as AlertTitle, Jn as BOARD_CHARS,
|
|
65
|
+
import { BOARD_CHARS as Jn, EXTRA_CHARS as Yn, applyCode62Glyph as Xn, getCharFromToken as Zn, getCharIndex as Qn, isColorTile as $n, messageToGrid as er, messageToText as tr, parseLine as nr, resolveCode62Glyph as rr, tokensEqual as ir } from "./lib/board-characters.js";
|
|
66
|
+
import { BoardTeaser as ar } from "./components/board/board-teaser.js";
|
|
67
|
+
import { BoardBackdrop as or } from "./components/board/board-backdrop.js";
|
|
68
|
+
import { WizardShell as sr } from "./components/wizard/wizard-shell.js";
|
|
69
|
+
import { DEVICE_DIMENSIONS as cr, MAX_NOTES_PER_AXIS as lr, NOTE_COLS as ur, NOTE_ROWS as dr, isNoteArray as fr, noteArrayDimensions as pr, resolveDimensions as mr } from "./lib/board-dimensions.js";
|
|
70
|
+
import { BoardDisplay as hr, FLAP_SPEED_PRESETS as gr, deriveFlapTiming as _r, resolveFlapSpeed as vr } from "./components/board/board-display.js";
|
|
71
|
+
import { ScaledBoardDisplay as yr } from "./components/board/scaled-board-display.js";
|
|
72
|
+
import { StaticBoardDisplay as br } from "./components/board/static-board-display.js";
|
|
73
|
+
import { DEFAULT_SHAPE_LABELS as xr, previewLabel as Sr, previewLabels as Cr, previewMessage as wr } from "./lib/board-previews.js";
|
|
74
|
+
import { BarList as Tr } from "./components/data/bar-list.js";
|
|
75
|
+
import { StatStrip as Er, StatStripItem as Dr } from "./components/data/stat-strip.js";
|
|
76
|
+
import { BoardShowcase as Or, DEFAULT_SHOWCASE_LABELS as kr } from "./components/plugin/board-showcase.js";
|
|
77
|
+
import { PLUGIN_CATEGORIES as Ar, PluginCategoryBadge as jr } from "./components/plugin/plugin-category-badge.js";
|
|
78
|
+
import { ScaledBoardTeaser as Mr } from "./components/plugin/scaled-board-teaser.js";
|
|
79
|
+
import { PluginCard as Nr } from "./components/plugin/plugin-card.js";
|
|
80
|
+
import { BOARD_CODE_TO_COLOR as Pr, BOARD_COLOR_CODES as Fr, CURSOR_ANCHOR as Ir, DEFAULT_BOARD_LINES as Lr, DEFAULT_BOARD_WIDTH as Rr, FILL_SPACE_REPEAT_VAR as zr, FILL_SPACE_VAR as Br } from "./components/editor/constants.js";
|
|
81
|
+
import { NodeViewInjectionProvider as Vr, useNodeViewInjection as Hr } from "./components/editor/node-views/node-view-context.js";
|
|
82
|
+
import { ColorTileNodeView as Ur, DEFAULT_COLOR_TILE_NODE_VIEW_LABELS as Wr } from "./components/editor/node-views/color-tile-node-view.js";
|
|
83
|
+
import { ColorTileNode as Gr } from "./components/editor/extensions/color-tile-node.js";
|
|
84
|
+
import { DEFAULT_FILL_SPACE_NODE_VIEW_LABELS as Kr, FillSpaceNodeView as qr } from "./components/editor/node-views/fill-space-node-view.js";
|
|
85
|
+
import { FillSpaceNode as Jr } from "./components/editor/extensions/fill-space-node.js";
|
|
86
|
+
import { DEFAULT_FORMULA_NODE_VIEW_LABELS as Yr, FormulaNodeView as Xr } from "./components/editor/node-views/formula-node-view.js";
|
|
87
|
+
import { FormulaNode as Zr } from "./components/editor/extensions/formula-node.js";
|
|
88
|
+
import { LineNavigation as Qr } from "./components/editor/extensions/line-navigation.js";
|
|
89
|
+
import { SingleParagraphDoc as $r } from "./components/editor/extensions/single-paragraph-doc.js";
|
|
90
|
+
import { TrailingNewline as ei } from "./components/editor/extensions/trailing-newline.js";
|
|
91
|
+
import { DEFAULT_VARIABLE_NODE_VIEW_LABELS as ti, VariableNodeView as ni } from "./components/editor/node-views/variable-node-view.js";
|
|
92
|
+
import { VariableNode as ri } from "./components/editor/extensions/variable-node.js";
|
|
93
|
+
import { DEFAULT_WRAPPED_TEXT_VIEW_LABELS as ii, WrappedTextView as ai } from "./components/editor/node-views/wrapped-text-view.js";
|
|
94
|
+
import { WrappedTextNode as oi } from "./components/editor/extensions/wrapped-text-node.js";
|
|
95
|
+
import { ColorPickerContent as si, DEFAULT_COLOR_PICKER_LABELS as ci } from "./components/editor/color-picker-content.js";
|
|
96
|
+
import { DRAW_CHARS as li, brushToCell as ui, cellsToLine as di, isPositionalLine as fi, lineToCells as pi, paintLine as mi, renderPositionalLine as hi } from "./components/editor/utils/draw-mode.js";
|
|
97
|
+
import { DEFAULT_DRAW_CHAR_PICKER_LABELS as gi, DrawCharPickerContent as _i } from "./components/editor/draw-char-picker-content.js";
|
|
98
|
+
import { DEFAULT_FORMATTING_PICKER_LABELS as vi, FormattingPickerContent as yi } from "./components/editor/formatting-picker-content.js";
|
|
99
|
+
import { DEFAULT_TOOLBAR_DROPDOWN_LABELS as bi, ToolbarDropdown as xi } from "./components/editor/toolbar-dropdown.js";
|
|
100
|
+
import { parseLineContent as Si, parseTemplateSimple as Ci, serializeTemplateSimple as wi } from "./components/editor/utils/serialization.js";
|
|
101
|
+
import { insertTemplateContent as Ti } from "./components/editor/utils/insertion.js";
|
|
102
|
+
import { DEFAULT_TEMPLATE_EDITOR_TOOLBAR_LABELS as Ei, TemplateEditorToolbar as Di } from "./components/editor/template-editor-toolbar.js";
|
|
103
|
+
import { buildStrokeTransaction as Oi, lineRanges as ki } from "./components/editor/utils/stroke-transaction.js";
|
|
104
|
+
import { DEFAULT_TEMPLATE_EDITOR_LABELS as Ai, TemplateEditor as ji } from "./components/editor/template-editor.js";
|
|
105
|
+
import { DEFAULT_FILTER_PICKER_LABELS as Mi, FilterPickerContent as Ni } from "./components/editor/filter-picker-content.js";
|
|
106
|
+
import { DEFAULT_VARIABLE_PICKER_LABELS as Pi, VariablePickerContent as Fi, createLucideIconResolver as Ii, getPluginsWithNestedArrays as Li } from "./components/editor/variable-picker-content.js";
|
|
107
|
+
import { calculateLineLength as Ri, getOverflowAmount as zi, willOverflow as Bi } from "./components/editor/utils/length-calculator.js";
|
|
108
|
+
export { zn as ALL_COLOR_CODES, Bn as AVAILABLE_COLORS, t as Accordion, n as AccordionContent, r as AccordionItem, i as AccordionTrigger, x as Alert, S as AlertDescription, U as AlertDialog, W as AlertDialogAction, G as AlertDialogCancel, K as AlertDialogContent, q as AlertDialogDescription, J as AlertDialogFooter, Y as AlertDialogHeader, X as AlertDialogOverlay, Z as AlertDialogPortal, Q as AlertDialogTitle, $ as AlertDialogTrigger, C as AlertTitle, Jn as BOARD_CHARS, Pr as BOARD_CODE_TO_COLOR, Vn as BOARD_COLORS, Fr as BOARD_COLOR_CODES, T as Badge, Tr as BarList, or as BoardBackdrop, hr as BoardDisplay, sn as BoardIcon, cn as BoardSelector, Or as BoardShowcase, ar as BoardTeaser, R as Box, ln as Breadcrumb, un as BreadcrumbEllipsis, dn as BreadcrumbItem, fn as BreadcrumbLink, pn as BreadcrumbList, mn as BreadcrumbPage, hn as BreadcrumbSeparator, M as Button, Hn as COLOR_CODE_MAP, Un as COLOR_DISPLAY, Ir as CURSOR_ANCHOR, a as Card, o as CardAction, s as CardContent, c as CardDescription, l as CardFooter, u as CardHeader, d as CardTitle, P as Checkbox, D as Chip, ze as Code, f as Collapsible, p as CollapsibleContent, m as CollapsibleTrigger, si as ColorPickerContent, Gr as ColorTileNode, Ur as ColorTileNodeView, Lr as DEFAULT_BOARD_LINES, Rr as DEFAULT_BOARD_WIDTH, ci as DEFAULT_COLOR_PICKER_LABELS, Wr as DEFAULT_COLOR_TILE_NODE_VIEW_LABELS, gi as DEFAULT_DRAW_CHAR_PICKER_LABELS, Kr as DEFAULT_FILL_SPACE_NODE_VIEW_LABELS, Mi as DEFAULT_FILTER_PICKER_LABELS, vi as DEFAULT_FORMATTING_PICKER_LABELS, Yr as DEFAULT_FORMULA_NODE_VIEW_LABELS, xr as DEFAULT_SHAPE_LABELS, kr as DEFAULT_SHOWCASE_LABELS, Ai as DEFAULT_TEMPLATE_EDITOR_LABELS, Ei as DEFAULT_TEMPLATE_EDITOR_TOOLBAR_LABELS, bi as DEFAULT_TOOLBAR_DROPDOWN_LABELS, ti as DEFAULT_VARIABLE_NODE_VIEW_LABELS, Pi as DEFAULT_VARIABLE_PICKER_LABELS, ii as DEFAULT_WRAPPED_TEXT_VIEW_LABELS, cr as DEVICE_DIMENSIONS, li as DRAW_CHARS, ee as Dialog, te as DialogClose, ne as DialogContent, re as DialogDescription, ie as DialogFooter, ae as DialogHeader, oe as DialogOverlay, se as DialogPortal, ce as DialogTitle, le as DialogTrigger, _i as DrawCharPickerContent, ue as DropdownMenu, de as DropdownMenuCheckboxItem, fe as DropdownMenuContent, pe as DropdownMenuGroup, me as DropdownMenuItem, he as DropdownMenuLabel, ge as DropdownMenuPortal, _e as DropdownMenuRadioGroup, ve as DropdownMenuRadioItem, ye as DropdownMenuSeparator, be as DropdownMenuShortcut, xe as DropdownMenuSub, Se as DropdownMenuSubContent, Ce as DropdownMenuSubTrigger, we as DropdownMenuTrigger, Yn as EXTRA_CHARS, k as EmptyState, Wn as FIESTABOARD_COLORS, gn as FIESTA_ICON_DATA_URI, _n as FIESTA_ICON_PALETTE, vn as FIESTA_ICON_SVG, zr as FILL_SPACE_REPEAT_VAR, Br as FILL_SPACE_VAR, gr as FLAP_SPEED_PRESETS, rt as FadeContent, yn as FiestaIcon, bn as FiestaLogo, Jr as FillSpaceNode, qr as FillSpaceNodeView, Ni as FilterPickerContent, z as Flex, yi as FormattingPickerContent, Zr as FormulaNode, Xr as FormulaNodeView, V as Grid, Be as Heading, h as IconTile, F as Input, _ as JsonTree, I as Label, xn as LanguageSelector, Te as Lightbox, Ee as LightboxClose, De as LightboxContent, Oe as LightboxFooter, ke as LightboxOverlay, Ae as LightboxPortal, je as LightboxTrigger, Qr as LineNavigation, He as List, Ue as ListItem, lr as MAX_NOTES_PER_AXIS, Sn as MainContent, v as MediaFrame, y as MediaFrameBar, b as MediaFrameMedia, ur as NOTE_COLS, dr as NOTE_ROWS, Cn as NavList, wn as NavListItem, Tn as NavListLink, En as NavListSection, Dn as NavListSectionContent, On as NavListSectionTrigger, Vr as NodeViewInjectionProvider, kn as PAGE_HUES, Ar as PLUGIN_CATEGORIES, An as PageHeader, jn as PageIconGradientDefs, Nn as PageLayout, Pn as PageToolbar, Nr as PluginCard, jr as PluginCategoryBadge, Me as Popover, Ne as PopoverClose, Pe as PopoverContent, Fe as PopoverDescription, Ie as PopoverTitle, Le as PopoverTrigger, yr as ScaledBoardDisplay, Mr as ScaledBoardTeaser, Ge as ScrollArea, Ke as ScrollBar, L as SecretInput, Ft as SegmentedControl, It as SegmentedControlItem, st as Select, ct as SelectContent, lt as SelectGroup, ut as SelectItem, dt as SelectLabel, ft as SelectScrollDownButton, pt as SelectScrollUpButton, mt as SelectSeparator, ht as SelectTrigger, gt as SelectValue, Gt as Sheet, Kt as SheetClose, qt as SheetContent, Jt as SheetDescription, Yt as SheetFooter, Xt as SheetHeader, Zt as SheetOverlay, Qt as SheetPortal, $t as SheetTitle, en as SheetTrigger, Fn as Sidebar, $r as SingleParagraphDoc, it as Skeleton, In as SkipToContent, _t as Slider, A as Spinner, Ut as Stack, Er as StatStrip, Dr as StatStripItem, br as StaticBoardDisplay, at as StatusDot, vt as Swatch, yt as SwatchGroup, wt as Switch, qe as Table, Je as TableBody, Ye as TableCell, Xe as TableHead, Ze as TableHeader, Qe as TableRow, $e as Tabs, et as TabsContent, tt as TabsList, nt as TabsTrigger, ji as TemplateEditor, Di as TemplateEditorToolbar, Et as Text, on as TextLink, Tt as Textarea, Ln as ThemeToggle, Ot as TimePicker, kt as TimezonePicker, jt as Toggle, Lt as ToggleCard, Rt as ToggleCardGroup, Mt as ToggleGroup, xi as ToolbarDropdown, tn as Tooltip, nn as TooltipContent, rn as TooltipProvider, an as TooltipTrigger, ei as TrailingNewline, ri as VariableNode, ni as VariableNodeView, Fi as VariablePickerContent, Rn as WizardProgress, sr as WizardShell, oi as WrappedTextNode, ai as WrappedTextView, w as alertVariants, Xn as applyCode62Glyph, E as badgeVariants, ui as brushToCell, Oi as buildStrokeTransaction, N as buttonVariants, Ri as calculateLineLength, di as cellsToLine, O as chipVariants, e as cn, Ii as createLucideIconResolver, _r as deriveFlapTiming, B as flexVariants, Gn as getBoardColor, Zn as getCharFromToken, Qn as getCharIndex, zi as getOverflowAmount, Li as getPluginsWithNestedArrays, H as gridVariants, Ve as headingVariants, g as iconTileVariants, Ti as insertTemplateContent, $n as isColorTile, fr as isNoteArray, fi as isPositionalLine, Kn as isValidBoardColor, ki as lineRanges, pi as lineToCells, At as listTimezones, We as listVariants, er as messageToGrid, tr as messageToText, pr as noteArrayDimensions, Mn as pageHue, mi as paintLine, nr as parseLine, Si as parseLineContent, Ci as parseTemplateSimple, Sr as previewLabel, Cr as previewLabels, wr as previewMessage, hi as renderPositionalLine, rr as resolveCode62Glyph, qn as resolveColorCode, mr as resolveDimensions, vr as resolveFlapSpeed, zt as segmentedControlItemVariants, Bt as segmentedControlVariants, wi as serializeTemplateSimple, j as spinnerVariants, Wt as stackVariants, ot as statusDotVariants, bt as swatchFillVariants, xt as swatchGroupVariants, St as swatchIndicatorVariants, Ct as swatchVariants, Dt as textVariants, Vt as toggleCardGroupVariants, Ht as toggleCardVariants, Nt as toggleGroupVariants, Pt as toggleVariants, ir as tokensEqual, Hr as useNodeViewInjection, Re as usePopoverClose, Bi as willOverflow };
|
|
@@ -72,6 +72,19 @@ export type Code62Glyph = "degree" | "heart";
|
|
|
72
72
|
* not been taught about the new flap keeps rendering exactly as it did.
|
|
73
73
|
*/
|
|
74
74
|
export declare function resolveCode62Glyph(deviceType: string, code62Glyph?: Code62Glyph): Code62Glyph;
|
|
75
|
+
/**
|
|
76
|
+
* Draw code 62 as the glyph this board's flap actually carries.
|
|
77
|
+
*
|
|
78
|
+
* Shared by {@link messageToGrid} and {@link messageToText} rather than written
|
|
79
|
+
* out twice: the tiles and the accessible name have to agree about what the
|
|
80
|
+
* board draws, or a board shows ♥ while announcing "degree" (WCAG 1.1.1).
|
|
81
|
+
*
|
|
82
|
+
* Exported for `BoardTeaser`, which tokenizes with {@link parseLine} directly
|
|
83
|
+
* rather than through {@link messageToGrid} — a one-row strip pads to a tile
|
|
84
|
+
* count instead of filling a grid — and would otherwise need its own copy of
|
|
85
|
+
* this substitution (FiestaBoard#1666).
|
|
86
|
+
*/
|
|
87
|
+
export declare function applyCode62Glyph(token: BoardToken, glyph: Code62Glyph): BoardToken;
|
|
75
88
|
/**
|
|
76
89
|
* Convert a message string to a rows×cols grid of tokens.
|
|
77
90
|
* Lines are split on `\n`, truncated/padded to the grid, and code 62 draws as
|
|
@@ -156,6 +156,6 @@ function m(e, t = "flagship", n) {
|
|
|
156
156
|
}).join("")).join(" ").replace(/\s+/g, " ").trim();
|
|
157
157
|
}
|
|
158
158
|
//#endregion
|
|
159
|
-
export { t as BOARD_CHARS, n as EXTRA_CHARS, l as getCharFromToken, c as getCharIndex, o as isColorTile, p as messageToGrid, m as messageToText, u as parseLine, d as resolveCode62Glyph, i as tokensEqual };
|
|
159
|
+
export { t as BOARD_CHARS, n as EXTRA_CHARS, f as applyCode62Glyph, l as getCharFromToken, c as getCharIndex, o as isColorTile, p as messageToGrid, m as messageToText, u as parseLine, d as resolveCode62Glyph, i as tokensEqual };
|
|
160
160
|
|
|
161
161
|
//# sourceMappingURL=board-characters.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"board-characters.js","names":[],"sources":["../../src/lib/board-characters.ts"],"mappings":";;AAuBA,IAAa,IAAc;CACzB;CAEA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA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GACnB,IAAM,IAAe,EAAK,QAAQ,KAAK,CAAC;GACxC,IAAI,MAAiB,IAAI;IACvB,IAAM,IAAU,EAAK,UAAU,IAAI,GAAG,CAAY;IAGlD,IAAI,EAAQ,WAAW,GAAG,GAAG;KAE3B,IAAI,IAAe;KACnB;IACF;IAGA,IAAM,IAAe,EAAQ,YAAY,GAErC,IAA2B;IAO/B,IANI,EAAgB,KAClB,IAAY,IACH,EAAgB,OACzB,IAAY,IAGV,GAAW;KAEb,AADA,EAAO,KAAK;MAAE,MAAM;MAAS,MAAM;KAAU,CAAC,GAC9C,IAAI,IAAe;KACnB;IACF;GAEF;EACF;EAIA,AADA,EAAO,KAAK;GAAE,MAAM;GAAQ,OAAO,EAAK,EAAE,CAAC,YAAY;EAAE,CAAC,GAC1D;CACF;CAEA,OAAO;AACT;AA2BA,SAAgB,EAAmB,GAAoB,GAAwC;CAE7F,OADI,MAAe,UAAU,MAAe,eAAqB,UAC1D,KAAe;AACxB;
|
|
1
|
+
{"version":3,"file":"board-characters.js","names":[],"sources":["../../src/lib/board-characters.ts"],"mappings":";;AAuBA,IAAa,IAAc;CACzB;CAEA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CAEA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CAEA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CAEA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF,GAKa,IAAuC,OAAO,OAAO,OAAO,OAAO,IAAI,GAAG,EACrF,KAAK,GACP,CAAC,GAQK,IAA0B,OAAO,OAAO;CAAE,MAAM;CAAQ,OAAO;AAAI,CAAC;AAG1E,SAAgB,EAAY,GAAe,GAAwB;CAIjE,OAHI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