@objectifthunes/whiteboard 0.2.6 → 0.3.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.
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
- import { jsx as n, jsxs as d, Fragment as re } from "react/jsx-runtime";
2
- import { useEffect as Y, useRef as S, useCallback as B, memo as Re, useId as We, useState as Se, useLayoutEffect as Xe, Component as Ye, useMemo as ye, forwardRef as me, createElement as T } from "react";
3
- import { create as De } from "zustand";
4
- import { createPortal as Ie } from "react-dom";
5
- const D = (e = 14) => ({
1
+ import { jsx as r, jsxs as m, Fragment as et } from "react/jsx-runtime";
2
+ import { useEffect as Y, useRef as M, useCallback as $, memo as Ct, useId as Tt, useState as vt, useLayoutEffect as Rt, Component as Wt, useMemo as bt, forwardRef as dt, createElement as W } from "react";
3
+ import { create as Xt } from "zustand";
4
+ import { createPortal as Yt } from "react-dom";
5
+ const D = (t = 14) => ({
6
6
  xmlns: "http://www.w3.org/2000/svg",
7
- width: e,
8
- height: e,
7
+ width: t,
8
+ height: t,
9
9
  viewBox: "0 0 24 24",
10
10
  fill: "none",
11
11
  stroke: "currentColor",
@@ -13,167 +13,166 @@ const D = (e = 14) => ({
13
13
  strokeLinecap: "round",
14
14
  strokeLinejoin: "round"
15
15
  });
16
- function Fe({ size: e, ...t }) {
17
- return /* @__PURE__ */ n("svg", { ...D(e), ...t, children: /* @__PURE__ */ n("path", { d: "M5 12h14" }) });
16
+ function Dt({ size: t, ...e }) {
17
+ return /* @__PURE__ */ r("svg", { ...D(t), ...e, children: /* @__PURE__ */ r("path", { d: "M5 12h14" }) });
18
18
  }
19
- function Ge({ size: e, ...t }) {
20
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
21
- /* @__PURE__ */ n("path", { d: "M5 12h14" }),
22
- /* @__PURE__ */ n("path", { d: "M12 5v14" })
19
+ function It({ size: t, ...e }) {
20
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
21
+ /* @__PURE__ */ r("path", { d: "M5 12h14" }),
22
+ /* @__PURE__ */ r("path", { d: "M12 5v14" })
23
23
  ] });
24
24
  }
25
- function Le({ size: e, ...t }) {
26
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
27
- /* @__PURE__ */ n("path", { d: "M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425z", fill: "none", stroke: "none" }),
28
- /* @__PURE__ */ n("path", { d: "M3 7V5a2 2 0 0 1 2-2h2" }),
29
- /* @__PURE__ */ n("path", { d: "M17 3h2a2 2 0 0 1 2 2v2" }),
30
- /* @__PURE__ */ n("path", { d: "M21 17v2a2 2 0 0 1-2 2h-2" }),
31
- /* @__PURE__ */ n("path", { d: "M7 21H5a2 2 0 0 1-2-2v-2" }),
32
- /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "3" }),
33
- /* @__PURE__ */ n("path", { d: "m16 16-1.9-1.9" })
25
+ function Ft({ size: t, ...e }) {
26
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
27
+ /* @__PURE__ */ r("path", { d: "M3 7V5a2 2 0 0 1 2-2h2" }),
28
+ /* @__PURE__ */ r("path", { d: "M17 3h2a2 2 0 0 1 2 2v2" }),
29
+ /* @__PURE__ */ r("path", { d: "M21 17v2a2 2 0 0 1-2 2h-2" }),
30
+ /* @__PURE__ */ r("path", { d: "M7 21H5a2 2 0 0 1-2-2v-2" }),
31
+ /* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "3" }),
32
+ /* @__PURE__ */ r("path", { d: "m16 16-1.9-1.9" })
34
33
  ] });
35
34
  }
36
- function Ee({ size: e, ...t }) {
37
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
38
- /* @__PURE__ */ n("path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" }),
39
- /* @__PURE__ */ n("path", { d: "M3 3v5h5" })
35
+ function Gt({ size: t, ...e }) {
36
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
37
+ /* @__PURE__ */ r("path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" }),
38
+ /* @__PURE__ */ r("path", { d: "M3 3v5h5" })
40
39
  ] });
41
40
  }
42
- function Ae({ size: e, ...t }) {
43
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
44
- /* @__PURE__ */ n("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
45
- /* @__PURE__ */ n("path", { d: "M3 9h18" }),
46
- /* @__PURE__ */ n("path", { d: "M3 15h18" }),
47
- /* @__PURE__ */ n("path", { d: "M9 3v18" }),
48
- /* @__PURE__ */ n("path", { d: "M15 3v18" })
41
+ function Et({ size: t, ...e }) {
42
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
43
+ /* @__PURE__ */ r("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
44
+ /* @__PURE__ */ r("path", { d: "M3 9h18" }),
45
+ /* @__PURE__ */ r("path", { d: "M3 15h18" }),
46
+ /* @__PURE__ */ r("path", { d: "M9 3v18" }),
47
+ /* @__PURE__ */ r("path", { d: "M15 3v18" })
49
48
  ] });
50
49
  }
51
- function Oe({ size: e, ...t }) {
52
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
53
- /* @__PURE__ */ n("polyline", { points: "15 3 21 3 21 9" }),
54
- /* @__PURE__ */ n("polyline", { points: "9 21 3 21 3 15" }),
55
- /* @__PURE__ */ n("line", { x1: "21", x2: "14", y1: "3", y2: "10" }),
56
- /* @__PURE__ */ n("line", { x1: "3", x2: "10", y1: "21", y2: "14" })
50
+ function Lt({ size: t, ...e }) {
51
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
52
+ /* @__PURE__ */ r("polyline", { points: "15 3 21 3 21 9" }),
53
+ /* @__PURE__ */ r("polyline", { points: "9 21 3 21 3 15" }),
54
+ /* @__PURE__ */ r("line", { x1: "21", x2: "14", y1: "3", y2: "10" }),
55
+ /* @__PURE__ */ r("line", { x1: "3", x2: "10", y1: "21", y2: "14" })
57
56
  ] });
58
57
  }
59
- function pe({ size: e, ...t }) {
60
- return /* @__PURE__ */ n("svg", { ...D(e), ...t, children: /* @__PURE__ */ n("path", { d: "M21 12a9 9 0 1 1-6.219-8.56" }) });
58
+ function ht({ size: t, ...e }) {
59
+ return /* @__PURE__ */ r("svg", { ...D(t), ...e, children: /* @__PURE__ */ r("path", { d: "M21 12a9 9 0 1 1-6.219-8.56" }) });
61
60
  }
62
- function Be({ size: e, ...t }) {
63
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
64
- /* @__PURE__ */ n("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
65
- /* @__PURE__ */ n("path", { d: "M12 9v4" }),
66
- /* @__PURE__ */ n("path", { d: "M12 17h.01" })
61
+ function Ot({ size: t, ...e }) {
62
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
63
+ /* @__PURE__ */ r("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
64
+ /* @__PURE__ */ r("path", { d: "M12 9v4" }),
65
+ /* @__PURE__ */ r("path", { d: "M12 17h.01" })
67
66
  ] });
68
67
  }
69
- function He({ size: e, ...t }) {
70
- return /* @__PURE__ */ n("svg", { ...D(e), ...t, children: /* @__PURE__ */ n("path", { d: "M20 6 9 17l-5-5" }) });
68
+ function At({ size: t, ...e }) {
69
+ return /* @__PURE__ */ r("svg", { ...D(t), ...e, children: /* @__PURE__ */ r("path", { d: "M20 6 9 17l-5-5" }) });
71
70
  }
72
- function ke({ size: e, ...t }) {
73
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
74
- /* @__PURE__ */ n("path", { d: "M18 6 6 18" }),
75
- /* @__PURE__ */ n("path", { d: "m6 6 12 12" })
71
+ function Nt({ size: t, ...e }) {
72
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
73
+ /* @__PURE__ */ r("path", { d: "M18 6 6 18" }),
74
+ /* @__PURE__ */ r("path", { d: "m6 6 12 12" })
76
75
  ] });
77
76
  }
78
- function $e({ size: e, ...t }) {
79
- return /* @__PURE__ */ n("svg", { ...D(e), ...t, children: /* @__PURE__ */ n("path", { d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z" }) });
80
- }
81
- function Ve({ size: e, ...t }) {
82
- return /* @__PURE__ */ d("svg", { ...D(e), ...t, children: [
83
- /* @__PURE__ */ n("circle", { cx: "12", cy: "12", r: "4" }),
84
- /* @__PURE__ */ n("path", { d: "M12 2v2" }),
85
- /* @__PURE__ */ n("path", { d: "M12 20v2" }),
86
- /* @__PURE__ */ n("path", { d: "m4.93 4.93 1.41 1.41" }),
87
- /* @__PURE__ */ n("path", { d: "m17.66 17.66 1.41 1.41" }),
88
- /* @__PURE__ */ n("path", { d: "M2 12h2" }),
89
- /* @__PURE__ */ n("path", { d: "M20 12h2" }),
90
- /* @__PURE__ */ n("path", { d: "m6.34 17.66-1.41 1.41" }),
91
- /* @__PURE__ */ n("path", { d: "m19.07 4.93-1.41 1.41" })
77
+ function $t({ size: t, ...e }) {
78
+ return /* @__PURE__ */ r("svg", { ...D(t), ...e, children: /* @__PURE__ */ r("path", { d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z" }) });
79
+ }
80
+ function Bt({ size: t, ...e }) {
81
+ return /* @__PURE__ */ m("svg", { ...D(t), ...e, children: [
82
+ /* @__PURE__ */ r("circle", { cx: "12", cy: "12", r: "4" }),
83
+ /* @__PURE__ */ r("path", { d: "M12 2v2" }),
84
+ /* @__PURE__ */ r("path", { d: "M12 20v2" }),
85
+ /* @__PURE__ */ r("path", { d: "m4.93 4.93 1.41 1.41" }),
86
+ /* @__PURE__ */ r("path", { d: "m17.66 17.66 1.41 1.41" }),
87
+ /* @__PURE__ */ r("path", { d: "M2 12h2" }),
88
+ /* @__PURE__ */ r("path", { d: "M20 12h2" }),
89
+ /* @__PURE__ */ r("path", { d: "m6.34 17.66-1.41 1.41" }),
90
+ /* @__PURE__ */ r("path", { d: "m19.07 4.93-1.41 1.41" })
92
91
  ] });
93
92
  }
94
- const he = 20;
95
- function ue(e) {
96
- return Math.round(e / he) * he;
93
+ const ut = 20;
94
+ function ct(t) {
95
+ return Math.round(t / ut) * ut;
97
96
  }
98
- function Ne(e, t, r = 60) {
99
- if (e.size === 0) return null;
100
- let s = 1 / 0, a = 1 / 0, u = -1 / 0, m = -1 / 0;
101
- for (const v of e.values())
102
- s = Math.min(s, v.x), a = Math.min(a, v.y), u = Math.max(u, v.x + v.width), m = Math.max(m, v.y + v.height);
103
- const f = u - s + r * 2, p = m - a + r * 2, b = t.width || window.innerWidth, h = t.height || window.innerHeight, k = Math.min(b / f, h / p, 1.5), M = (s + u) / 2, _ = (a + m) / 2;
97
+ function gt(t, e, n = 60) {
98
+ if (t.size === 0) return null;
99
+ let s = 1 / 0, a = 1 / 0, u = -1 / 0, h = -1 / 0;
100
+ for (const v of t.values())
101
+ s = Math.min(s, v.x), a = Math.min(a, v.y), u = Math.max(u, v.x + v.width), h = Math.max(h, v.y + v.height);
102
+ const f = u - s + n * 2, p = h - a + n * 2, w = e.width || window.innerWidth, d = e.height || window.innerHeight, N = Math.min(w / f, d / p, 1.5), k = (s + u) / 2, P = (a + h) / 2;
104
103
  return {
105
- scale: Math.min(3, Math.max(0.2, k)),
104
+ scale: Math.min(3, Math.max(0.2, N)),
106
105
  offset: {
107
- x: b / 2 - M * k,
108
- y: h / 2 - _ * k
106
+ x: w / 2 - k * N,
107
+ y: d / 2 - P * N
109
108
  }
110
109
  };
111
110
  }
112
- function je(e, t, r = 40, s = 1.5) {
113
- const a = t.width || window.innerWidth, u = t.height || window.innerHeight, m = Math.max(1, e.width), f = Math.max(1, e.height), p = Math.min(
114
- (a - r * 2) / m,
115
- (u - r * 2) / f,
111
+ function Ht(t, e, n = 40, s = 1.5) {
112
+ const a = e.width || window.innerWidth, u = e.height || window.innerHeight, h = Math.max(1, t.width), f = Math.max(1, t.height), p = Math.min(
113
+ (a - n * 2) / h,
114
+ (u - n * 2) / f,
116
115
  s
117
- ), b = Math.min(3, Math.max(0.2, p));
116
+ ), w = Math.min(3, Math.max(0.2, p));
118
117
  return {
119
- scale: b,
118
+ scale: w,
120
119
  offset: {
121
- x: a / 2 - (e.x + m / 2) * b,
122
- y: u / 2 - (e.y + f / 2) * b
120
+ x: a / 2 - (t.x + h / 2) * w,
121
+ y: u / 2 - (t.y + f / 2) * w
123
122
  }
124
123
  };
125
124
  }
126
- const g = De((e, t) => ({
125
+ const b = Xt((t, e) => ({
127
126
  offset: { x: 0, y: 0 },
128
127
  scale: 1,
129
128
  viewportSize: { width: 0, height: 0 },
130
129
  snapToGrid: !1,
131
- snapGridSize: he,
130
+ snapGridSize: ut,
132
131
  panels: /* @__PURE__ */ new Map(),
133
132
  resetFns: /* @__PURE__ */ new Map(),
134
133
  registryVersion: 0,
135
- setOffset: (r) => e((s) => ({ offset: typeof r == "function" ? r(s.offset) : r })),
136
- setScale: (r) => e((s) => ({ scale: typeof r == "function" ? r(s.scale) : r })),
137
- setViewportSize: (r) => e({ viewportSize: r }),
138
- setSnapToGrid: (r) => e((s) => ({ snapToGrid: typeof r == "function" ? r(s.snapToGrid) : r })),
139
- register: (r, s) => {
140
- t().panels.set(r, s), e((a) => ({ registryVersion: a.registryVersion + 1 }));
134
+ setOffset: (n) => t((s) => ({ offset: typeof n == "function" ? n(s.offset) : n })),
135
+ setScale: (n) => t((s) => ({ scale: typeof n == "function" ? n(s.scale) : n })),
136
+ setViewportSize: (n) => t({ viewportSize: n }),
137
+ setSnapToGrid: (n) => t((s) => ({ snapToGrid: typeof n == "function" ? n(s.snapToGrid) : n })),
138
+ register: (n, s) => {
139
+ e().panels.set(n, s), t((a) => ({ registryVersion: a.registryVersion + 1 }));
141
140
  },
142
- unregister: (r) => {
143
- t().panels.delete(r), e((s) => ({ registryVersion: s.registryVersion + 1 }));
141
+ unregister: (n) => {
142
+ e().panels.delete(n), t((s) => ({ registryVersion: s.registryVersion + 1 }));
144
143
  },
145
- registerReset: (r, s) => {
146
- t().resetFns.set(r, s);
144
+ registerReset: (n, s) => {
145
+ e().resetFns.set(n, s);
147
146
  },
148
- unregisterReset: (r) => {
149
- t().resetFns.delete(r);
147
+ unregisterReset: (n) => {
148
+ e().resetFns.delete(n);
150
149
  },
151
150
  fitToContent: () => {
152
- const { panels: r, viewportSize: s } = t(), a = Ne(r, s);
153
- a && e({ scale: a.scale, offset: a.offset });
151
+ const { panels: n, viewportSize: s } = e(), a = gt(n, s);
152
+ a && t({ scale: a.scale, offset: a.offset });
154
153
  },
155
- focusPanel: (r, s) => {
156
- const { viewportSize: a } = t(), u = je(
157
- r,
154
+ focusPanel: (n, s) => {
155
+ const { viewportSize: a } = e(), u = Ht(
156
+ n,
158
157
  a,
159
158
  (s == null ? void 0 : s.padding) ?? 40,
160
159
  (s == null ? void 0 : s.maxScale) ?? 1.5
161
160
  );
162
- e({ scale: u.scale, offset: u.offset });
161
+ t({ scale: u.scale, offset: u.offset });
163
162
  },
164
163
  resetWidgets: () => {
165
- for (const s of t().resetFns.values()) s();
166
- const r = (s = 0) => {
167
- const { panels: a, viewportSize: u } = t(), m = Ne(a, u);
168
- if (m) {
169
- e({ scale: m.scale, offset: m.offset });
164
+ for (const s of e().resetFns.values()) s();
165
+ const n = (s = 0) => {
166
+ const { panels: a, viewportSize: u } = e(), h = gt(a, u);
167
+ if (h) {
168
+ t({ scale: h.scale, offset: h.offset });
170
169
  return;
171
170
  }
172
- s < 6 && requestAnimationFrame(() => r(s + 1));
171
+ s < 6 && requestAnimationFrame(() => n(s + 1));
173
172
  };
174
- requestAnimationFrame(() => requestAnimationFrame(() => r()));
173
+ requestAnimationFrame(() => requestAnimationFrame(() => n()));
175
174
  },
176
- resetSession: () => e({
175
+ resetSession: () => t({
177
176
  offset: { x: 0, y: 0 },
178
177
  scale: 1,
179
178
  viewportSize: { width: 0, height: 0 },
@@ -183,119 +182,119 @@ const g = De((e, t) => ({
183
182
  resetFns: /* @__PURE__ */ new Map()
184
183
  })
185
184
  }));
186
- function Ue({ extraActions: e }) {
187
- const t = g((h) => h.scale), r = g((h) => h.viewportSize), s = g((h) => h.snapToGrid), a = g((h) => h.setScale), u = g((h) => h.setOffset), m = g((h) => h.setSnapToGrid), f = g((h) => h.fitToContent), p = g((h) => h.resetWidgets);
185
+ function Vt({ extraActions: t }) {
186
+ const e = b((d) => d.scale), n = b((d) => d.viewportSize), s = b((d) => d.snapToGrid), a = b((d) => d.setScale), u = b((d) => d.setOffset), h = b((d) => d.setSnapToGrid), f = b((d) => d.fitToContent), p = b((d) => d.resetWidgets);
188
187
  Y(() => {
189
188
  s && window.dispatchEvent(new Event("whiteboard-snap-now"));
190
189
  }, [s]);
191
- const b = (h) => {
192
- const k = Math.min(3, Math.max(0.2, h)), M = k / t, _ = (r.width || window.innerWidth) / 2, v = (r.height || window.innerHeight) / 2;
193
- u((P) => ({
194
- x: _ - (_ - P.x) * M,
195
- y: v - (v - P.y) * M
196
- })), a(k);
190
+ const w = (d) => {
191
+ const N = Math.min(3, Math.max(0.2, d)), k = N / e, P = (n.width || window.innerWidth) / 2, v = (n.height || window.innerHeight) / 2;
192
+ u((_) => ({
193
+ x: P - (P - _.x) * k,
194
+ y: v - (v - _.y) * k
195
+ })), a(N);
197
196
  };
198
- return /* @__PURE__ */ d(
197
+ return /* @__PURE__ */ m(
199
198
  "div",
200
199
  {
201
200
  className: "zoom-bar",
202
- onPointerDown: (h) => h.stopPropagation(),
203
- onWheel: (h) => h.stopPropagation(),
201
+ onPointerDown: (d) => d.stopPropagation(),
202
+ onWheel: (d) => d.stopPropagation(),
204
203
  children: [
205
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__icon", onClick: () => b(t * 0.8), title: "Zoom out", "aria-label": "Zoom out", children: /* @__PURE__ */ n(Fe, { size: 14 }) }),
206
- /* @__PURE__ */ d("span", { className: "zoom-bar__value", children: [
207
- Math.round(t * 100),
204
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__icon", onClick: () => w(e * 0.8), title: "Zoom out", "aria-label": "Zoom out", children: /* @__PURE__ */ r(Dt, { size: 14 }) }),
205
+ /* @__PURE__ */ m("span", { className: "zoom-bar__value", children: [
206
+ Math.round(e * 100),
208
207
  "%"
209
208
  ] }),
210
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__icon", onClick: () => b(t * 1.2), title: "Zoom in", "aria-label": "Zoom in", children: /* @__PURE__ */ n(Ge, { size: 14 }) }),
211
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__action", onClick: f, title: "Fit camera to all panels", "aria-label": "Fit camera to all panels", children: /* @__PURE__ */ n(Le, { size: 14 }) }),
212
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__action", onClick: p, title: "Reset panel positions", "aria-label": "Reset panel positions", children: /* @__PURE__ */ n(Ee, { size: 14 }) }),
213
- /* @__PURE__ */ n(
209
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__icon", onClick: () => w(e * 1.2), title: "Zoom in", "aria-label": "Zoom in", children: /* @__PURE__ */ r(It, { size: 14 }) }),
210
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__action", onClick: f, title: "Fit camera to all panels", "aria-label": "Fit camera to all panels", children: /* @__PURE__ */ r(Ft, { size: 14 }) }),
211
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__action", onClick: p, title: "Reset panel positions", "aria-label": "Reset panel positions", children: /* @__PURE__ */ r(Gt, { size: 14 }) }),
212
+ /* @__PURE__ */ r(
214
213
  "button",
215
214
  {
216
215
  type: "button",
217
216
  className: `wb-btn wb-btn--secondary wb-btn--icon-only zoom-bar__action${s ? " is-active" : ""}`,
218
- onClick: () => m((h) => !h),
217
+ onClick: () => h((d) => !d),
219
218
  title: s ? "Disable snap to grid" : "Enable snap to grid",
220
219
  "aria-label": s ? "Disable snap to grid" : "Enable snap to grid",
221
- children: /* @__PURE__ */ n(Ae, { size: 14 })
220
+ children: /* @__PURE__ */ r(Et, { size: 14 })
222
221
  }
223
222
  ),
224
- e
223
+ t
225
224
  ]
226
225
  }
227
226
  );
228
227
  }
229
- const ee = 200, te = 150, de = 40, xe = 1;
230
- function Ze({ loading: e = !1 }) {
231
- g((i) => i.registryVersion);
232
- const t = g((i) => i.offset), r = g((i) => i.scale), s = g((i) => i.viewportSize), a = g((i) => i.panels), u = g((i) => i.setOffset), m = g((i) => i.setScale), f = g((i) => i.focusPanel), p = S(null), b = S(!1), h = S(null), M = Array.from(a.entries()).filter(([, i]) => Number.isFinite(i.width) && Number.isFinite(i.height)), _ = M.map(([, i]) => i);
233
- if (e || _.length === 0)
234
- return /* @__PURE__ */ n("div", { className: "minimap minimap--loading", style: { width: ee, height: te }, children: /* @__PURE__ */ n("div", { className: "minimap__loading", children: /* @__PURE__ */ n(pe, { size: 14, className: "icon-spin" }) }) });
235
- const v = s.width || window.innerWidth, P = s.height || window.innerHeight, L = v / r, H = P / r, $ = -t.x / r, V = -t.y / r;
236
- let I = 1 / 0, c = 1 / 0, R = -1 / 0, W = -1 / 0;
237
- for (const i of _)
238
- I = Math.min(I, i.x), c = Math.min(c, i.y), R = Math.max(R, i.x + i.width), W = Math.max(W, i.y + i.height);
239
- I -= de, c -= de, R += de, W += de;
240
- const z = Math.max(xe, R - I), O = Math.max(xe, W - c), C = Math.min(ee / z, te / O), E = z * C, U = O * C, Z = (ee - E) / 2, X = (te - U) / 2, q = (i) => Z + (i - I) * C, j = (i) => X + (i - c) * C, Q = (i, y) => {
228
+ const Q = 200, tt = 150, lt = 40, yt = 1;
229
+ function jt({ loading: t = !1 }) {
230
+ b((i) => i.registryVersion);
231
+ const e = b((i) => i.offset), n = b((i) => i.scale), s = b((i) => i.viewportSize), a = b((i) => i.panels), u = b((i) => i.setOffset), h = b((i) => i.setScale), f = b((i) => i.focusPanel), p = M(null), w = M(!1), d = M(null), k = Array.from(a.entries()).filter(([, i]) => Number.isFinite(i.width) && Number.isFinite(i.height)), P = k.map(([, i]) => i);
232
+ if (t || P.length === 0)
233
+ return /* @__PURE__ */ r("div", { className: "minimap minimap--loading", style: { width: Q, height: tt }, children: /* @__PURE__ */ r("div", { className: "minimap__loading", children: /* @__PURE__ */ r(ht, { size: 14, className: "icon-spin" }) }) });
234
+ const v = s.width || window.innerWidth, _ = s.height || window.innerHeight, E = v / n, B = _ / n, H = -e.x / n, V = -e.y / n;
235
+ let I = 1 / 0, c = 1 / 0, T = -1 / 0, R = -1 / 0;
236
+ for (const i of P)
237
+ I = Math.min(I, i.x), c = Math.min(c, i.y), T = Math.max(T, i.x + i.width), R = Math.max(R, i.y + i.height);
238
+ I -= lt, c -= lt, T += lt, R += lt;
239
+ const z = Math.max(yt, T - I), A = Math.max(yt, R - c), C = Math.min(Q / z, tt / A), L = z * C, Z = A * C, U = (Q - L) / 2, X = (tt - Z) / 2, q = (i) => U + (i - I) * C, j = (i) => X + (i - c) * C, J = (i, y) => {
241
240
  if (!p.current) return;
242
- const x = p.current.getBoundingClientRect(), F = Math.min(ee, Math.max(0, i - x.left)), A = Math.min(te, Math.max(0, y - x.top)), ae = Math.min(E + Z, Math.max(Z, F)), ie = Math.min(U + X, Math.max(X, A)), oe = (ae - Z) / C + I, ce = (ie - X) / C + c;
243
- return { worldX: oe, worldY: ce };
244
- }, K = (i, y, x) => {
245
- const F = Math.min(3, Math.max(0.2, x));
246
- m(F), u({
241
+ const S = p.current.getBoundingClientRect(), F = Math.min(Q, Math.max(0, i - S.left)), O = Math.min(tt, Math.max(0, y - S.top)), rt = Math.min(L + U, Math.max(U, F)), st = Math.min(Z + X, Math.max(X, O)), at = (rt - U) / C + I, it = (st - X) / C + c;
242
+ return { worldX: at, worldY: it };
243
+ }, K = (i, y, S) => {
244
+ const F = Math.min(3, Math.max(0.2, S));
245
+ h(F), u({
247
246
  x: v / 2 - i * F,
248
- y: P / 2 - y * F
247
+ y: _ / 2 - y * F
249
248
  });
250
- }, se = (i, y) => {
251
- const x = Q(i, y);
252
- x && K(x.worldX, x.worldY, r);
253
- }, we = (i) => {
254
- i.stopPropagation(), i.preventDefault(), b.current = !0, i.currentTarget.setPointerCapture(i.pointerId), se(i.clientX, i.clientY);
249
+ }, nt = (i, y) => {
250
+ const S = J(i, y);
251
+ S && K(S.worldX, S.worldY, n);
252
+ }, ft = (i) => {
253
+ i.stopPropagation(), i.preventDefault(), w.current = !0, i.currentTarget.setPointerCapture(i.pointerId), nt(i.clientX, i.clientY);
255
254
  }, o = (i) => {
256
- b.current && se(i.clientX, i.clientY);
257
- }, w = () => {
258
- b.current = !1;
255
+ w.current && nt(i.clientX, i.clientY);
256
+ }, g = () => {
257
+ w.current = !1;
259
258
  };
260
- return /* @__PURE__ */ d(
259
+ return /* @__PURE__ */ m(
261
260
  "div",
262
261
  {
263
262
  ref: p,
264
- onPointerDown: we,
263
+ onPointerDown: ft,
265
264
  onPointerMove: o,
266
- onPointerUp: w,
267
- onPointerCancel: w,
265
+ onPointerUp: g,
266
+ onPointerCancel: g,
268
267
  onWheel: (i) => {
269
268
  i.preventDefault(), i.stopPropagation();
270
- const y = Q(i.clientX, i.clientY);
269
+ const y = J(i.clientX, i.clientY);
271
270
  if (!y) return;
272
- const x = i.deltaY > 0 ? 0.9 : 1.1;
273
- K(y.worldX, y.worldY, r * x);
271
+ const S = i.deltaY > 0 ? 0.9 : 1.1;
272
+ K(y.worldX, y.worldY, n * S);
274
273
  },
275
274
  className: "minimap",
276
275
  style: {
277
- width: ee,
278
- height: te
276
+ width: Q,
277
+ height: tt
279
278
  },
280
279
  children: [
281
- M.map(([i, y]) => /* @__PURE__ */ n(
280
+ k.map(([i, y]) => /* @__PURE__ */ r(
282
281
  "div",
283
282
  {
284
283
  className: "minimap__panel",
285
- onPointerDown: (x) => {
286
- x.stopPropagation();
284
+ onPointerDown: (S) => {
285
+ S.stopPropagation();
287
286
  },
288
- onPointerUp: (x) => {
289
- x.stopPropagation();
290
- const F = Date.now(), A = h.current;
291
- if (A && A.id === i && F - A.time < 300) {
292
- x.preventDefault(), f(y, { padding: y.focusPadding, maxScale: y.focusMaxScale }), h.current = null;
287
+ onPointerUp: (S) => {
288
+ S.stopPropagation();
289
+ const F = Date.now(), O = d.current;
290
+ if (O && O.id === i && F - O.time < 300) {
291
+ S.preventDefault(), f(y, { padding: y.focusPadding, maxScale: y.focusMaxScale }), d.current = null;
293
292
  return;
294
293
  }
295
- h.current = { id: i, time: F };
294
+ d.current = { id: i, time: F };
296
295
  },
297
- onDoubleClick: (x) => {
298
- x.preventDefault(), x.stopPropagation(), f(y, { padding: y.focusPadding, maxScale: y.focusMaxScale });
296
+ onDoubleClick: (S) => {
297
+ S.preventDefault(), S.stopPropagation(), f(y, { padding: y.focusPadding, maxScale: y.focusMaxScale });
299
298
  },
300
299
  style: {
301
300
  left: q(y.x),
@@ -306,15 +305,15 @@ function Ze({ loading: e = !1 }) {
306
305
  },
307
306
  i
308
307
  )),
309
- /* @__PURE__ */ n(
308
+ /* @__PURE__ */ r(
310
309
  "div",
311
310
  {
312
311
  className: "minimap__viewport",
313
312
  style: {
314
- left: q($),
313
+ left: q(H),
315
314
  top: j(V),
316
- width: L * C,
317
- height: H * C
315
+ width: E * C,
316
+ height: B * C
318
317
  }
319
318
  }
320
319
  )
@@ -322,198 +321,198 @@ function Ze({ loading: e = !1 }) {
322
321
  }
323
322
  );
324
323
  }
325
- function xt({ children: e, showMinimap: t = !0, minimapLoading: r = !1, extraActions: s }) {
326
- const a = g((c) => c.offset), u = g((c) => c.scale), m = g((c) => c.registryVersion), f = g((c) => c.viewportSize), p = g((c) => c.setOffset), b = g((c) => c.setScale), h = g((c) => c.setViewportSize), k = S(null), M = S(!1), _ = S({ x: 0, y: 0 }), v = S(null), P = S(u), L = S(!1);
324
+ function fe({ children: t, showMinimap: e = !0, minimapLoading: n = !1, extraActions: s }) {
325
+ const a = b((c) => c.offset), u = b((c) => c.scale), h = b((c) => c.registryVersion), f = b((c) => c.viewportSize), p = b((c) => c.setOffset), w = b((c) => c.setScale), d = b((c) => c.setViewportSize), N = M(null), k = M(!1), P = M({ x: 0, y: 0 }), v = M(null), _ = M(u), E = M(!1);
327
326
  Y(() => () => {
328
- g.getState().resetSession();
327
+ b.getState().resetSession();
329
328
  }, []), Y(() => {
330
- P.current = u;
329
+ _.current = u;
331
330
  }, [u]), Y(() => {
332
- const c = k.current;
331
+ const c = N.current;
333
332
  if (!c) return;
334
- const R = () => {
333
+ const T = () => {
335
334
  const z = c.getBoundingClientRect();
336
- h({
335
+ d({
337
336
  width: Math.max(0, z.width),
338
337
  height: Math.max(0, z.height)
339
338
  });
340
339
  };
341
- if (R(), typeof ResizeObserver > "u") return;
342
- const W = new ResizeObserver(R);
343
- return W.observe(c), () => W.disconnect();
344
- }, [h]), Y(() => {
345
- if (L.current) return;
346
- const { panels: c } = g.getState();
347
- c.size === 0 || f.width <= 0 || f.height <= 0 || (L.current = !0, requestAnimationFrame(() => {
348
- g.getState().fitToContent();
340
+ if (T(), typeof ResizeObserver > "u") return;
341
+ const R = new ResizeObserver(T);
342
+ return R.observe(c), () => R.disconnect();
343
+ }, [d]), Y(() => {
344
+ if (E.current) return;
345
+ const { panels: c } = b.getState();
346
+ c.size === 0 || f.width <= 0 || f.height <= 0 || (E.current = !0, requestAnimationFrame(() => {
347
+ b.getState().fitToContent();
349
348
  }));
350
- }, [m, f]);
351
- const H = B((c) => {
352
- c.target === c.currentTarget && (c.button === 0 || c.button === 1) && (M.current = !0, v.current = c.pointerId, _.current = { x: c.clientX, y: c.clientY }, c.currentTarget.setPointerCapture(c.pointerId), c.preventDefault());
353
- }, []), $ = B((c) => {
354
- if (!M.current || v.current !== c.pointerId) return;
355
- const R = c.movementX ?? c.clientX - _.current.x, W = c.movementY ?? c.clientY - _.current.y;
356
- p((z) => ({ x: z.x + R, y: z.y + W })), _.current = { x: c.clientX, y: c.clientY };
357
- }, [p]), V = B((c) => {
349
+ }, [h, f]);
350
+ const B = $((c) => {
351
+ c.target === c.currentTarget && (c.button === 0 || c.button === 1) && (k.current = !0, v.current = c.pointerId, P.current = { x: c.clientX, y: c.clientY }, c.currentTarget.setPointerCapture(c.pointerId), c.preventDefault());
352
+ }, []), H = $((c) => {
353
+ if (!k.current || v.current !== c.pointerId) return;
354
+ const T = c.movementX ?? c.clientX - P.current.x, R = c.movementY ?? c.clientY - P.current.y;
355
+ p((z) => ({ x: z.x + T, y: z.y + R })), P.current = { x: c.clientX, y: c.clientY };
356
+ }, [p]), V = $((c) => {
358
357
  if (v.current !== null)
359
358
  try {
360
359
  c.currentTarget.releasePointerCapture(v.current);
361
360
  } catch {
362
361
  }
363
- M.current = !1, v.current = null;
364
- }, []), I = B((c) => {
365
- const R = P.current, W = c.currentTarget.getBoundingClientRect(), z = { x: c.clientX - W.left, y: c.clientY - W.top }, O = Math.min(3, Math.max(0.2, R * (c.deltaY > 0 ? 0.9 : 1.1))), C = O / R;
366
- p((E) => ({
367
- x: z.x - (z.x - E.x) * C,
368
- y: z.y - (z.y - E.y) * C
369
- })), b(O);
370
- }, [p, b]);
371
- return /* @__PURE__ */ d(re, { children: [
372
- /* @__PURE__ */ n(
362
+ k.current = !1, v.current = null;
363
+ }, []), I = $((c) => {
364
+ const T = _.current, R = c.currentTarget.getBoundingClientRect(), z = { x: c.clientX - R.left, y: c.clientY - R.top }, A = Math.min(3, Math.max(0.2, T * (c.deltaY > 0 ? 0.9 : 1.1))), C = A / T;
365
+ p((L) => ({
366
+ x: z.x - (z.x - L.x) * C,
367
+ y: z.y - (z.y - L.y) * C
368
+ })), w(A);
369
+ }, [p, w]);
370
+ return /* @__PURE__ */ m(et, { children: [
371
+ /* @__PURE__ */ r(
373
372
  "div",
374
373
  {
375
- ref: k,
376
- onPointerDown: H,
377
- onPointerMove: $,
374
+ ref: N,
375
+ onPointerDown: B,
376
+ onPointerMove: H,
378
377
  onPointerUp: V,
379
378
  onPointerCancel: V,
380
379
  onWheel: I,
381
380
  onContextMenu: (c) => c.preventDefault(),
382
381
  className: "whiteboard-shell",
383
- children: /* @__PURE__ */ d(
382
+ children: /* @__PURE__ */ m(
384
383
  "div",
385
384
  {
386
385
  className: "whiteboard-canvas",
387
386
  style: { transform: `translate(${a.x}px, ${a.y}px) scale(${u})` },
388
387
  children: [
389
- /* @__PURE__ */ n("div", { className: "whiteboard-grid", "aria-hidden": !0 }),
390
- e
388
+ /* @__PURE__ */ r("div", { className: "whiteboard-grid", "aria-hidden": !0 }),
389
+ t
391
390
  ]
392
391
  }
393
392
  )
394
393
  }
395
394
  ),
396
- /* @__PURE__ */ n(Ue, { extraActions: s }),
397
- t ? /* @__PURE__ */ n(Ze, { loading: r }) : null
395
+ /* @__PURE__ */ r(Vt, { extraActions: s }),
396
+ e ? /* @__PURE__ */ r(jt, { loading: n }) : null
398
397
  ] });
399
398
  }
400
- const St = Re(function({
401
- title: t,
402
- defaultPosition: r,
399
+ const be = Ct(function({
400
+ title: e,
401
+ defaultPosition: n,
403
402
  width: s = 300,
404
403
  className: a,
405
404
  trackRect: u,
406
- focusable: m,
405
+ focusable: h,
407
406
  focusPadding: f = 40,
408
407
  focusMaxScale: p = 1.5,
409
- headerActions: b,
410
- children: h
408
+ headerActions: w,
409
+ children: d
411
410
  }) {
412
- const k = We(), [M, _] = Se(r), v = S(!1), P = S(M), L = S(null), H = S(null), $ = g((o) => o.scale), V = g((o) => o.snapToGrid), I = g((o) => o.snapGridSize), c = g((o) => o.register), R = g((o) => o.unregister), W = g((o) => o.registerReset), z = g((o) => o.unregisterReset), O = g((o) => o.focusPanel), C = S($), E = S(!1), U = S(20), Z = S(r), X = S(null), q = S(null);
411
+ const N = Tt(), [k, P] = vt(n), v = M(!1), _ = M(k), E = M(null), B = M(null), H = b((o) => o.scale), V = b((o) => o.snapToGrid), I = b((o) => o.snapGridSize), c = b((o) => o.register), T = b((o) => o.unregister), R = b((o) => o.registerReset), z = b((o) => o.unregisterReset), A = b((o) => o.focusPanel), C = M(H), L = M(!1), Z = M(20), U = M(n), X = M(null), q = M(null);
413
412
  Y(() => {
414
- C.current = $;
415
- }, [$]), Y(() => {
416
- E.current = V, U.current = I;
413
+ C.current = H;
414
+ }, [H]), Y(() => {
415
+ L.current = V, Z.current = I;
417
416
  }, [V, I]), Y(() => {
418
417
  const o = () => {
419
- const w = U.current;
420
- _((N) => {
418
+ const g = Z.current;
419
+ P((x) => {
421
420
  const i = {
422
- x: Math.round(N.x / w) * w,
423
- y: Math.round(N.y / w) * w
421
+ x: Math.round(x.x / g) * g,
422
+ y: Math.round(x.y / g) * g
424
423
  };
425
- return i.x === N.x && i.y === N.y ? N : i;
424
+ return i.x === x.x && i.y === x.y ? x : i;
426
425
  });
427
426
  };
428
427
  return window.addEventListener("whiteboard-snap-now", o), () => window.removeEventListener("whiteboard-snap-now", o);
429
428
  }, []), Y(() => {
430
- P.current = M;
431
- }, [M]);
432
- const j = B(() => {
433
- const o = L.current;
429
+ _.current = k;
430
+ }, [k]);
431
+ const j = $(() => {
432
+ const o = E.current;
434
433
  if (!o) return;
435
- const w = {
436
- x: P.current.x,
437
- y: P.current.y,
434
+ const g = {
435
+ x: _.current.x,
436
+ y: _.current.y,
438
437
  width: o.offsetWidth,
439
438
  height: o.offsetHeight,
440
439
  focusPadding: f,
441
440
  focusMaxScale: p
442
- }, N = H.current;
443
- N && N.x === w.x && N.y === w.y && N.width === w.width && N.height === w.height && N.focusPadding === w.focusPadding && N.focusMaxScale === w.focusMaxScale || (H.current = w, c(k, w), u && (u.current = w));
444
- }, [p, f, k, c, u]), Q = B(() => {
445
- const o = L.current;
441
+ }, x = B.current;
442
+ x && x.x === g.x && x.y === g.y && x.width === g.width && x.height === g.height && x.focusPadding === g.focusPadding && x.focusMaxScale === g.focusMaxScale || (B.current = g, c(N, g), u && (u.current = g));
443
+ }, [p, f, N, c, u]), J = $(() => {
444
+ const o = E.current;
446
445
  return o ? {
447
- x: P.current.x,
448
- y: P.current.y,
446
+ x: _.current.x,
447
+ y: _.current.y,
449
448
  width: o.offsetWidth,
450
449
  height: o.offsetHeight,
451
450
  focusPadding: f,
452
451
  focusMaxScale: p
453
452
  } : null;
454
- }, [p, f]), K = B(() => {
455
- const o = Q();
456
- o && O(o, { padding: f, maxScale: p });
457
- }, [O, f, p, Q]);
458
- Y(() => (W(k, () => _(Z.current)), () => {
453
+ }, [p, f]), K = $(() => {
454
+ const o = J();
455
+ o && A(o, { padding: f, maxScale: p });
456
+ }, [A, f, p, J]);
457
+ Y(() => (R(N, () => P(U.current)), () => {
459
458
  var o;
460
- (o = X.current) == null || o.call(X), R(k), z(k), H.current = null;
461
- }), [k, W, R, z]), Xe(() => {
459
+ (o = X.current) == null || o.call(X), T(N), z(N), B.current = null;
460
+ }), [N, R, T, z]), Rt(() => {
462
461
  j();
463
- }, [M.x, M.y, s, j]), Y(() => {
464
- const o = L.current;
462
+ }, [k.x, k.y, s, j]), Y(() => {
463
+ const o = E.current;
465
464
  if (!o || typeof ResizeObserver > "u") return;
466
- const w = new ResizeObserver(() => {
465
+ const g = new ResizeObserver(() => {
467
466
  j();
468
467
  });
469
- return w.observe(o), () => w.disconnect();
468
+ return g.observe(o), () => g.disconnect();
470
469
  }, [j]);
471
- const se = B((o) => {
472
- var ae;
470
+ const nt = $((o) => {
471
+ var rt;
473
472
  if (o.button !== 0) return;
474
473
  v.current = !0;
475
- const w = o.clientX, N = o.clientY, i = P.current.x, y = P.current.y, x = C.current;
474
+ const g = o.clientX, x = o.clientY, i = _.current.x, y = _.current.y, S = C.current;
476
475
  o.preventDefault(), o.stopPropagation(), o.target.setPointerCapture(o.pointerId);
477
- const F = (ie) => {
476
+ const F = (st) => {
478
477
  if (!v.current) return;
479
- const oe = i + (ie.clientX - w) / x, ce = y + (ie.clientY - N) / x, le = U.current, Ce = E.current ? Math.round(oe / le) * le : oe, Te = E.current ? Math.round(ce / le) * le : ce;
480
- _({
481
- x: Ce,
482
- y: Te
478
+ const at = i + (st.clientX - g) / S, it = y + (st.clientY - x) / S, ot = Z.current, _t = L.current ? Math.round(at / ot) * ot : at, zt = L.current ? Math.round(it / ot) * ot : it;
479
+ P({
480
+ x: _t,
481
+ y: zt
483
482
  });
484
- }, A = () => {
485
- v.current = !1, window.removeEventListener("pointermove", F), window.removeEventListener("pointerup", A), X.current = null;
483
+ }, O = () => {
484
+ v.current = !1, window.removeEventListener("pointermove", F), window.removeEventListener("pointerup", O), X.current = null;
486
485
  };
487
- (ae = X.current) == null || ae.call(X), window.addEventListener("pointermove", F), window.addEventListener("pointerup", A), X.current = A;
488
- }, []), we = a ? `floating-panel ${a}` : "floating-panel";
489
- return /* @__PURE__ */ d(
486
+ (rt = X.current) == null || rt.call(X), window.addEventListener("pointermove", F), window.addEventListener("pointerup", O), X.current = O;
487
+ }, []), ft = a ? `floating-panel ${a}` : "floating-panel";
488
+ return /* @__PURE__ */ m(
490
489
  "div",
491
490
  {
492
- ref: L,
493
- className: we,
494
- style: { left: M.x, top: M.y, width: s },
491
+ ref: E,
492
+ className: ft,
493
+ style: { left: k.x, top: k.y, width: s },
495
494
  onPointerDown: (o) => o.stopPropagation(),
496
495
  onPointerUp: (o) => {
497
496
  if (v.current) return;
498
- const w = Date.now(), N = q.current;
499
- if (N && w - N.time < 300) {
500
- const i = o.clientX - N.x, y = o.clientY - N.y;
497
+ const g = Date.now(), x = q.current;
498
+ if (x && g - x.time < 300) {
499
+ const i = o.clientX - x.x, y = o.clientY - x.y;
501
500
  if (i * i + y * y < 100) {
502
501
  o.stopPropagation(), K(), q.current = null;
503
502
  return;
504
503
  }
505
504
  }
506
- q.current = { time: w, x: o.clientX, y: o.clientY };
505
+ q.current = { time: g, x: o.clientX, y: o.clientY };
507
506
  },
508
507
  onWheel: (o) => o.stopPropagation(),
509
508
  onDoubleClick: (o) => {
510
509
  o.stopPropagation(), K();
511
510
  },
512
511
  children: [
513
- /* @__PURE__ */ d("div", { onPointerDown: se, className: "floating-panel__header", children: [
514
- /* @__PURE__ */ n("strong", { className: "floating-panel__title", children: t }),
515
- b,
516
- m && /* @__PURE__ */ n(
512
+ /* @__PURE__ */ m("div", { onPointerDown: nt, className: "floating-panel__header", children: [
513
+ /* @__PURE__ */ r("strong", { className: "floating-panel__title", children: e }),
514
+ w,
515
+ h && /* @__PURE__ */ r(
517
516
  "button",
518
517
  {
519
518
  type: "button",
@@ -522,60 +521,61 @@ const St = Re(function({
522
521
  onPointerDown: (o) => o.stopPropagation(),
523
522
  title: "Focus on this panel",
524
523
  "aria-label": "Focus on this panel",
525
- children: /* @__PURE__ */ n(Oe, { size: 14 })
524
+ children: /* @__PURE__ */ r(Lt, { size: 14 })
526
525
  }
527
526
  )
528
527
  ] }),
529
- /* @__PURE__ */ n("div", { className: "floating-panel__body", children: h })
528
+ /* @__PURE__ */ r("div", { className: "floating-panel__body", children: d })
530
529
  ]
531
530
  }
532
531
  );
533
532
  });
534
- function kt(e) {
535
- return S({ ...e, width: 0, height: 0 });
533
+ function we(t) {
534
+ return M({ ...t, width: 0, height: 0 });
536
535
  }
537
- function Mt(e, t = he) {
538
- return { x: e.x, y: e.y + e.height + t };
536
+ function ge(t, e = ut) {
537
+ return { x: t.x, y: t.y + t.height + e };
539
538
  }
540
- function _t({
541
- open: e,
542
- title: t,
543
- message: r,
539
+ function ye({
540
+ open: t,
541
+ title: e,
542
+ message: n,
544
543
  onConfirm: s,
545
544
  onCancel: a,
546
545
  confirmLabel: u = "Confirm",
547
- loading: m,
548
- error: f
546
+ loadingLabel: h,
547
+ loading: f,
548
+ error: p
549
549
  }) {
550
550
  return Y(() => {
551
- if (!e) return;
552
- const p = (b) => {
553
- b.key === "Escape" && a();
551
+ if (!t) return;
552
+ const w = (d) => {
553
+ d.key === "Escape" && a();
554
554
  };
555
- return window.addEventListener("keydown", p), () => window.removeEventListener("keydown", p);
556
- }, [e, a]), !e || typeof document > "u" ? null : Ie(
557
- /* @__PURE__ */ n("div", { className: "confirm-modal-overlay", onMouseDown: a, children: /* @__PURE__ */ d(
555
+ return window.addEventListener("keydown", w), () => window.removeEventListener("keydown", w);
556
+ }, [t, a]), !t || typeof document > "u" ? null : Yt(
557
+ /* @__PURE__ */ r("div", { className: "confirm-modal-overlay", onMouseDown: a, children: /* @__PURE__ */ m(
558
558
  "div",
559
559
  {
560
560
  className: "confirm-modal",
561
561
  role: "dialog",
562
562
  "aria-modal": "true",
563
- "aria-label": t,
564
- onMouseDown: (p) => p.stopPropagation(),
563
+ "aria-label": e,
564
+ onMouseDown: (w) => w.stopPropagation(),
565
565
  children: [
566
- /* @__PURE__ */ d("div", { className: "confirm-modal__header", children: [
567
- /* @__PURE__ */ d("span", { className: "confirm-modal__title", children: [
568
- /* @__PURE__ */ n(Be, { size: 16 }),
569
- t
566
+ /* @__PURE__ */ m("div", { className: "confirm-modal__header", children: [
567
+ /* @__PURE__ */ m("span", { className: "confirm-modal__title", children: [
568
+ /* @__PURE__ */ r(Ot, { size: 16 }),
569
+ e
570
570
  ] }),
571
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only", onClick: a, "aria-label": "Close dialog", children: /* @__PURE__ */ n(ke, { size: 14 }) })
571
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary wb-btn--icon-only", onClick: a, "aria-label": "Close dialog", children: /* @__PURE__ */ r(Nt, { size: 14 }) })
572
572
  ] }),
573
- /* @__PURE__ */ n("p", { className: "confirm-modal__message", children: r }),
574
- f && /* @__PURE__ */ n("div", { className: "wb-alert wb-alert--error", children: f }),
575
- /* @__PURE__ */ d("div", { className: "wb-btn-row", children: [
576
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--secondary", onClick: a, children: "Cancel" }),
577
- /* @__PURE__ */ n("button", { type: "button", className: "wb-btn wb-btn--danger", onClick: s, disabled: m, children: m ? "Deleting..." : /* @__PURE__ */ d(re, { children: [
578
- /* @__PURE__ */ n(He, { size: 14 }),
573
+ /* @__PURE__ */ r("p", { className: "confirm-modal__message", children: n }),
574
+ p && /* @__PURE__ */ r("div", { className: "wb-alert wb-alert--error", children: p }),
575
+ /* @__PURE__ */ m("div", { className: "wb-btn-row", children: [
576
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--secondary", onClick: a, children: "Cancel" }),
577
+ /* @__PURE__ */ r("button", { type: "button", className: "wb-btn wb-btn--danger", onClick: s, disabled: f, children: f ? h ?? `${u}…` : /* @__PURE__ */ m(et, { children: [
578
+ /* @__PURE__ */ r(At, { size: 14 }),
579
579
  u
580
580
  ] }) })
581
581
  ] })
@@ -585,17 +585,17 @@ function _t({
585
585
  document.body
586
586
  );
587
587
  }
588
- class Pt extends Ye {
588
+ class ve extends Wt {
589
589
  constructor() {
590
590
  super(...arguments), this.state = { error: null };
591
591
  }
592
- static getDerivedStateFromError(t) {
593
- return { error: t };
592
+ static getDerivedStateFromError(e) {
593
+ return { error: e };
594
594
  }
595
595
  render() {
596
- return this.state.error ? /* @__PURE__ */ d("div", { className: "wb-stack wb-stack--sm", children: [
597
- /* @__PURE__ */ n("div", { className: "wb-alert wb-alert--error", children: this.props.fallbackMessage ?? "This panel crashed." }),
598
- /* @__PURE__ */ n(
596
+ return this.state.error ? /* @__PURE__ */ m("div", { className: "wb-stack wb-stack--sm", children: [
597
+ /* @__PURE__ */ r("div", { className: "wb-alert wb-alert--error", children: this.props.fallbackMessage ?? "This panel crashed." }),
598
+ /* @__PURE__ */ r(
599
599
  "button",
600
600
  {
601
601
  type: "button",
@@ -607,624 +607,604 @@ class Pt extends Ye {
607
607
  ] }) : this.props.children;
608
608
  }
609
609
  }
610
- function zt({
611
- widths: e,
612
- startX: t = 20,
613
- y: r = 40,
610
+ function Ne({
611
+ widths: t,
612
+ startX: e = 20,
613
+ y: n = 40,
614
614
  gap: s = 20
615
615
  }) {
616
- const a = ye(() => {
616
+ const a = bt(() => {
617
617
  const f = {};
618
- for (const [p, b] of Object.entries(e))
619
- f[p] = ue(b);
618
+ for (const [p, w] of Object.entries(t))
619
+ f[p] = ct(w);
620
620
  return f;
621
- }, [e]), u = ye(
621
+ }, [t]), u = bt(
622
622
  () => ({
623
- startX: ue(t),
624
- y: ue(r),
625
- gap: ue(s)
623
+ startX: ct(e),
624
+ y: ct(n),
625
+ gap: ct(s)
626
626
  }),
627
- [t, r, s]
628
- ), m = ye(() => {
627
+ [e, n, s]
628
+ ), h = bt(() => {
629
629
  const f = {};
630
630
  let p = u.startX;
631
- for (const [b, h] of Object.entries(a))
632
- f[b] = { x: p, y: u.y }, p += h + u.gap;
631
+ for (const [w, d] of Object.entries(a))
632
+ f[w] = { x: p, y: u.y }, p += d + u.gap;
633
633
  return f;
634
634
  }, [u.gap, u.startX, u.y, a]);
635
- return { layout: u, panelWidth: a, positions: m };
635
+ return { layout: u, panelWidth: a, positions: h };
636
636
  }
637
- function l(...e) {
638
- return e.filter(Boolean).join(" ");
637
+ function l(...t) {
638
+ return t.filter(Boolean).join(" ");
639
639
  }
640
- const qe = {
641
- error: "status-error",
642
- muted: "text-sm text-muted",
643
- info: "ui-alert ui-alert--info",
644
- success: "ui-alert ui-alert--success"
640
+ const Zt = {
641
+ error: "wb-alert wb-alert--error",
642
+ muted: "wb-alert wb-alert--muted",
643
+ info: "wb-alert wb-alert--info",
644
+ success: "wb-alert wb-alert--success"
645
645
  };
646
- function Ct({ tone: e = "info", className: t, ...r }) {
647
- return /* @__PURE__ */ n("p", { className: l(qe[e], t), ...r });
646
+ function xe({ tone: t = "info", className: e, ...n }) {
647
+ return /* @__PURE__ */ r("p", { className: l(Zt[t], e), ...n });
648
648
  }
649
- function Tt({ className: e, ...t }) {
650
- return /* @__PURE__ */ n("span", { className: l("avatar-badge", e), ...t });
649
+ function Se({ className: t, ...e }) {
650
+ return /* @__PURE__ */ r("span", { className: l("avatar-badge", t), ...e });
651
651
  }
652
- const Ke = {
652
+ const Ut = {
653
653
  primary: "",
654
- secondary: "secondary-btn",
655
- danger: "danger-btn"
656
- }, Me = me(function({
657
- variant: t = "primary",
658
- fullWidth: r = !1,
654
+ secondary: "wb-btn--secondary",
655
+ danger: "wb-btn--danger"
656
+ }, xt = dt(function({
657
+ variant: e = "primary",
658
+ fullWidth: n = !1,
659
659
  iconOnly: s = !1,
660
660
  loading: a = !1,
661
- disabled: u,
662
- className: m,
663
- children: f,
664
- loadingText: p,
665
- ...b
666
- }, h) {
667
- return /* @__PURE__ */ n(
661
+ type: u = "button",
662
+ disabled: h,
663
+ className: f,
664
+ children: p,
665
+ loadingText: w,
666
+ ...d
667
+ }, N) {
668
+ return /* @__PURE__ */ r(
668
669
  "button",
669
670
  {
670
- ref: h,
671
- className: l(Ke[t], r && "full-width-btn", s && "icon-only-btn", m),
672
- disabled: u || a,
673
- ...b,
674
- children: a ? /* @__PURE__ */ d(re, { children: [
675
- /* @__PURE__ */ n(pe, { size: 14, className: "icon-spin" }),
676
- p || f
677
- ] }) : f
671
+ ref: N,
672
+ type: u,
673
+ className: l("wb-btn", Ut[e], n && "wb-btn--full-width", s && "wb-btn--icon-only", f),
674
+ disabled: h || a,
675
+ ...d,
676
+ children: a ? /* @__PURE__ */ m(et, { children: [
677
+ /* @__PURE__ */ r(ht, { size: 14, className: "icon-spin" }),
678
+ w || p
679
+ ] }) : p
678
680
  }
679
681
  );
680
682
  });
681
- function Je({ as: e = "div", className: t, ...r }) {
682
- return T(e, {
683
- className: l("button-row", t),
684
- ...r
683
+ function qt({ as: t = "div", className: e, ...n }) {
684
+ return W(t, {
685
+ className: l("button-row", e),
686
+ ...n
685
687
  });
686
688
  }
687
- function Rt({ children: e, hint: t, className: r, ...s }) {
688
- return /* @__PURE__ */ n("div", { className: "canvas-wrap", children: /* @__PURE__ */ d("div", { className: l("canvas-stage", r), ...s, children: [
689
- e,
690
- t && /* @__PURE__ */ n("p", { className: "canvas-hint", children: t })
689
+ function Me({ children: t, hint: e, className: n, ...s }) {
690
+ return /* @__PURE__ */ r("div", { className: "canvas-wrap", children: /* @__PURE__ */ m("div", { className: l("canvas-stage", n), ...s, children: [
691
+ t,
692
+ e && /* @__PURE__ */ r("p", { className: "canvas-hint", children: e })
691
693
  ] }) });
692
694
  }
693
- function Wt({ className: e, ...t }) {
694
- return /* @__PURE__ */ n("span", { className: l("chip", e), ...t });
695
+ function ke({ className: t, ...e }) {
696
+ return /* @__PURE__ */ r("span", { className: l("chip", t), ...e });
695
697
  }
696
- function Qe({ active: e = !1, className: t, ...r }) {
697
- return /* @__PURE__ */ n(
698
+ function Kt({ active: t = !1, className: e, ...n }) {
699
+ return /* @__PURE__ */ r(
698
700
  "button",
699
701
  {
700
702
  type: "button",
701
- className: l("choice-card", t),
702
- "data-active": e,
703
- ...r
703
+ className: l("choice-card", e),
704
+ "data-active": t,
705
+ ...n
704
706
  }
705
707
  );
706
708
  }
707
- function fe({ as: e = "ul", reset: t = !0, className: r, ...s }) {
708
- return T(e, {
709
- className: l(t && "list-reset", r),
709
+ function mt({ as: t = "ul", reset: e = !0, className: n, ...s }) {
710
+ return W(t, {
711
+ className: l(e && "list-reset", n),
710
712
  ...s
711
713
  });
712
714
  }
713
- const et = {
715
+ const Jt = {
714
716
  sm: "",
715
717
  md: "skeleton--md",
716
718
  pill: "skeleton--pill"
717
719
  };
718
- function G({ as: e = "div", radius: t = "sm", className: r, ...s }) {
719
- return T(e, {
720
- className: l("skeleton", et[t], r),
720
+ function G({ as: t = "div", radius: e = "sm", className: n, ...s }) {
721
+ return W(t, {
722
+ className: l("skeleton", Jt[e], n),
721
723
  "aria-hidden": !0,
722
724
  ...s
723
725
  });
724
726
  }
725
- function tt(e) {
726
- const { className: t, ...r } = e;
727
- return /* @__PURE__ */ n(G, { className: l("skeleton-input", t), ...r });
727
+ function Qt(t) {
728
+ const { className: e, ...n } = t;
729
+ return /* @__PURE__ */ r(G, { className: l("skeleton-input", e), ...n });
728
730
  }
729
- function ve(e) {
730
- const { className: t, ...r } = e;
731
- return /* @__PURE__ */ n(G, { className: l("skeleton-btn", t), ...r });
731
+ function St(t) {
732
+ const { className: e, ...n } = t;
733
+ return /* @__PURE__ */ r(G, { className: l("skeleton-btn", e), ...n });
732
734
  }
733
- function Xt(e) {
734
- const { className: t, ...r } = e;
735
- return /* @__PURE__ */ n(G, { className: l("skeleton-icon-btn", t), ...r });
735
+ function Pe(t) {
736
+ const { className: e, ...n } = t;
737
+ return /* @__PURE__ */ r(G, { className: l("skeleton-icon-btn", e), ...n });
736
738
  }
737
- function nt(e) {
738
- const { className: t, ...r } = e;
739
- return /* @__PURE__ */ n(G, { className: l("skeleton-select", t), ...r });
739
+ function _e(t) {
740
+ const { className: e, ...n } = t;
741
+ return /* @__PURE__ */ r(G, { className: l("skeleton-select", e), ...n });
740
742
  }
741
- function Yt(e) {
742
- const { className: t, ...r } = e;
743
- return /* @__PURE__ */ n(G, { className: l("skeleton-textarea", t), ...r });
743
+ function ze(t) {
744
+ const { className: e, ...n } = t;
745
+ return /* @__PURE__ */ r(G, { className: l("skeleton-textarea", e), ...n });
744
746
  }
745
- function _e(e) {
746
- const { className: t, ...r } = e;
747
- return /* @__PURE__ */ n(G, { className: l("skeleton-thumb", t), ...r });
747
+ function Mt(t) {
748
+ const { className: e, ...n } = t;
749
+ return /* @__PURE__ */ r(G, { className: l("skeleton-thumb", e), ...n });
748
750
  }
749
- function ne(e) {
750
- const { className: t, ...r } = e;
751
- return /* @__PURE__ */ n(G, { radius: "pill", className: l("skeleton-chip", t), ...r });
751
+ function te(t) {
752
+ const { className: e, ...n } = t;
753
+ return /* @__PURE__ */ r(G, { radius: "pill", className: l("skeleton-chip", e), ...n });
752
754
  }
753
- function ge(e) {
754
- const { className: t, ...r } = e;
755
- return /* @__PURE__ */ n(G, { className: l("skeleton-title", t), ...r });
755
+ function kt(t) {
756
+ const { className: e, ...n } = t;
757
+ return /* @__PURE__ */ r(G, { className: l("skeleton-title", e), ...n });
756
758
  }
757
- function be({ short: e = !1, className: t, ...r }) {
758
- return /* @__PURE__ */ n(G, { className: l("skeleton-line", e && "skeleton-line--short", t), ...r });
759
+ function wt({ short: t = !1, className: e, ...n }) {
760
+ return /* @__PURE__ */ r(G, { className: l("skeleton-line", t && "skeleton-line--short", e), ...n });
759
761
  }
760
- function rt(e) {
761
- const { className: t, ...r } = e;
762
- return /* @__PURE__ */ n(G, { radius: "pill", className: l("skeleton-avatar", t), ...r });
762
+ function Ce(t) {
763
+ const { className: e, ...n } = t;
764
+ return /* @__PURE__ */ r(G, { radius: "pill", className: l("skeleton-avatar", e), ...n });
763
765
  }
764
- function Dt(e) {
765
- const { className: t, ...r } = e;
766
- return /* @__PURE__ */ n(G, { className: l("skeleton-canvas", t), ...r });
766
+ function Te(t) {
767
+ const { className: e, ...n } = t;
768
+ return /* @__PURE__ */ r(G, { className: l("skeleton-canvas", e), ...n });
767
769
  }
768
- function It({
769
- options: e,
770
- value: t,
771
- onChange: r,
770
+ function Re({
771
+ options: t,
772
+ value: e,
773
+ onChange: n,
772
774
  className: s
773
775
  }) {
774
- return /* @__PURE__ */ n(fe, { className: l("choice-list", s), children: e.map((a) => /* @__PURE__ */ n("li", { children: /* @__PURE__ */ n(
775
- Qe,
776
+ return /* @__PURE__ */ r(mt, { className: l("choice-list", s), children: t.map((a) => /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(
777
+ Kt,
776
778
  {
777
- active: t === a.value,
778
- onClick: () => r(a.value),
779
+ active: e === a.value,
780
+ onClick: () => n(a.value),
779
781
  disabled: a.disabled,
780
782
  "data-has-description": a.description ? "true" : "false",
781
- children: a.description ? /* @__PURE__ */ d("span", { className: "choice-card__row", children: [
782
- /* @__PURE__ */ n("span", { className: "choice-card__label", children: a.label }),
783
- /* @__PURE__ */ n("span", { className: "choice-card__description", children: a.description })
784
- ] }) : /* @__PURE__ */ n("span", { className: "choice-card__label", children: a.label })
783
+ children: a.description ? /* @__PURE__ */ m("span", { className: "choice-card__row", children: [
784
+ /* @__PURE__ */ r("span", { className: "choice-card__label", children: a.label }),
785
+ /* @__PURE__ */ r("span", { className: "choice-card__description", children: a.description })
786
+ ] }) : /* @__PURE__ */ r("span", { className: "choice-card__label", children: a.label })
785
787
  }
786
788
  ) }, a.value)) });
787
789
  }
788
- function Ft({ count: e = 4, className: t, withDescription: r = !1 }) {
789
- return /* @__PURE__ */ n(fe, { className: l("choice-list", t), "aria-hidden": !0, children: Array.from({ length: e }).map((s, a) => /* @__PURE__ */ n("li", { children: /* @__PURE__ */ d("div", { className: "choice-card", children: [
790
- /* @__PURE__ */ n(ge, { className: l("skeleton-title--sm", !r && "skeleton-choice-label") }),
791
- r ? /* @__PURE__ */ n(be, { short: !0 }) : null
790
+ function We({ count: t = 4, className: e, withDescription: n = !1 }) {
791
+ return /* @__PURE__ */ r(mt, { className: l("choice-list", e), "aria-hidden": !0, children: Array.from({ length: t }).map((s, a) => /* @__PURE__ */ r("li", { children: /* @__PURE__ */ m("div", { className: "choice-card", children: [
792
+ /* @__PURE__ */ r(kt, { className: l("skeleton-title--sm", !n && "skeleton-choice-label") }),
793
+ n ? /* @__PURE__ */ r(wt, { short: !0 }) : null
792
794
  ] }) }, `choice-skeleton-${a}`)) });
793
795
  }
794
- function Gt({ className: e, ...t }) {
795
- return /* @__PURE__ */ n("div", { className: l("coord-grid", e), ...t });
796
+ function Xe({ className: t, ...e }) {
797
+ return /* @__PURE__ */ r("div", { className: l("coord-grid", t), ...e });
796
798
  }
797
- function Lt({ axis: e, className: t, ...r }) {
798
- return /* @__PURE__ */ d("label", { className: l("coord-input", t), children: [
799
- e,
799
+ function Ye({ axis: t, className: e, ...n }) {
800
+ return /* @__PURE__ */ m("label", { className: l("coord-input", e), children: [
801
+ t,
800
802
  " ",
801
- /* @__PURE__ */ n("input", { type: "number", step: "0.01", ...r })
803
+ /* @__PURE__ */ r("input", { type: "number", step: "0.01", ...n })
802
804
  ] });
803
805
  }
804
- function J({
805
- as: e,
806
- size: t = "md",
807
- className: r,
806
+ function pt({
807
+ as: t,
808
+ size: e = "md",
809
+ className: n,
808
810
  ...s
809
811
  }) {
810
- return T(e ?? "div", {
811
- className: l(t === "sm" ? "panel-stack-sm" : "panel-stack", r),
812
+ return W(t ?? "div", {
813
+ className: l(e === "sm" ? "panel-stack-sm" : "panel-stack", n),
812
814
  ...s
813
815
  });
814
816
  }
815
- const st = {
817
+ const ee = {
816
818
  xs: "text-xs",
817
819
  sm: "text-sm",
818
820
  md: ""
819
821
  };
820
- function at({ as: e = "p", clamp: t = !1, className: r, ...s }) {
821
- return T(e, {
822
- className: l("asset-title", t && "asset-title--clamp", r),
822
+ function ne({ as: t = "p", clamp: e = !1, className: n, ...s }) {
823
+ return W(t, {
824
+ className: l("card-title", e && "card-title--clamp", n),
823
825
  ...s
824
826
  });
825
827
  }
826
- function Et({ as: e = "h3", className: t, ...r }) {
827
- return T(e, {
828
- className: l("story-title", t),
829
- ...r
828
+ function De({ as: t = "h1", className: e, ...n }) {
829
+ return W(t, {
830
+ className: l("page-title", e),
831
+ ...n
830
832
  });
831
833
  }
832
- function Pe({ as: e = "p", size: t = "sm", className: r, ...s }) {
833
- return T(e, {
834
- className: l(st[t], "text-muted", r),
835
- ...s
834
+ function re({ as: t = "span", className: e, ...n }) {
835
+ return W(t, {
836
+ className: l("widget-section__title", e),
837
+ ...n
836
838
  });
837
839
  }
838
- function At({ as: e = "h1", className: t, ...r }) {
839
- return T(e, {
840
- className: l("page-title", t),
841
- ...r
840
+ function se({ as: t = "p", className: e, ...n }) {
841
+ return W(t, {
842
+ className: l("widget-section__description", e),
843
+ ...n
842
844
  });
843
845
  }
844
- function it({ as: e = "span", className: t, ...r }) {
845
- return T(e, {
846
- className: l("widget-section__title", t),
847
- ...r
848
- });
849
- }
850
- function ot({ as: e = "p", className: t, ...r }) {
851
- return T(e, {
852
- className: l("widget-section__description", t),
853
- ...r
846
+ function Pt({ as: t = "p", size: e = "sm", className: n, ...s }) {
847
+ return W(t, {
848
+ className: l(ee[e], "text-muted", n),
849
+ ...s
854
850
  });
855
851
  }
856
- function Ot({ title: e, description: t, action: r }) {
857
- return /* @__PURE__ */ d(J, { size: "sm", children: [
858
- /* @__PURE__ */ n(at, { children: e }),
859
- t ? /* @__PURE__ */ n(Pe, { children: t }) : null,
860
- r
852
+ function Ie({ title: t, description: e, action: n }) {
853
+ return /* @__PURE__ */ m(pt, { size: "sm", children: [
854
+ /* @__PURE__ */ r(ne, { children: t }),
855
+ e ? /* @__PURE__ */ r(Pt, { children: e }) : null,
856
+ n
861
857
  ] });
862
858
  }
863
- function ct({ className: e, ...t }) {
864
- return /* @__PURE__ */ n("label", { className: l("widget-label", e), ...t });
859
+ function ae({ className: t, ...e }) {
860
+ return /* @__PURE__ */ r("label", { className: l("widget-label", t), ...e });
865
861
  }
866
- function Bt({
867
- as: e,
868
- label: t,
869
- htmlFor: r,
862
+ function Fe({
863
+ as: t,
864
+ label: e,
865
+ htmlFor: n,
870
866
  hint: s,
871
867
  error: a,
872
868
  layout: u = "stack",
873
- className: m,
869
+ className: h,
874
870
  children: f,
875
871
  ...p
876
872
  }) {
877
- return T(
878
- e ?? "div",
873
+ return W(
874
+ t ?? "div",
879
875
  {
880
- className: l(u === "control" ? "widget-control" : "panel-stack-sm", m),
876
+ className: l(u === "control" ? "widget-control" : "panel-stack-sm", h),
881
877
  ...p
882
878
  },
883
- /* @__PURE__ */ d(re, { children: [
884
- t ? /* @__PURE__ */ n(ct, { htmlFor: r, children: t }) : null,
879
+ /* @__PURE__ */ m(et, { children: [
880
+ e ? /* @__PURE__ */ r(ae, { htmlFor: n, children: e }) : null,
885
881
  f,
886
- s ? /* @__PURE__ */ n(Pe, { size: "xs", children: s }) : null,
887
- a ? /* @__PURE__ */ n("p", { className: "field-error", children: a }) : null
882
+ s ? /* @__PURE__ */ r(Pt, { size: "xs", children: s }) : null,
883
+ a ? /* @__PURE__ */ r("p", { className: "field-error", children: a }) : null
888
884
  ] })
889
885
  );
890
886
  }
891
- function Ht({ isGenerating: e, children: t, message: r }) {
892
- return /* @__PURE__ */ d("div", { className: "generating-overlay-wrap", children: [
893
- t,
894
- e && /* @__PURE__ */ d("div", { className: "generating-overlay", "aria-live": "polite", children: [
895
- /* @__PURE__ */ n(pe, { size: 20, className: "icon-spin" }),
896
- /* @__PURE__ */ n("span", { children: r ?? "Generating, please wait…" })
887
+ function Ge({ isGenerating: t, children: e, message: n }) {
888
+ return /* @__PURE__ */ m("div", { className: "generating-overlay-wrap", children: [
889
+ e,
890
+ t && /* @__PURE__ */ m("div", { className: "generating-overlay", "aria-live": "polite", children: [
891
+ /* @__PURE__ */ r(ht, { size: 20, className: "icon-spin" }),
892
+ /* @__PURE__ */ r("span", { children: n ?? "Generating, please wait…" })
897
893
  ] })
898
894
  ] });
899
895
  }
900
- function $t({ as: e = "span", icon: t, className: r, children: s, ...a }) {
901
- return T(
902
- e,
896
+ function Ee({ as: t = "span", icon: e, className: n, children: s, ...a }) {
897
+ return W(
898
+ t,
903
899
  {
904
- className: l("inline-row", r),
900
+ className: l("inline-row", n),
905
901
  ...a
906
902
  },
907
- /* @__PURE__ */ d(re, { children: [
908
- t,
903
+ /* @__PURE__ */ m(et, { children: [
904
+ e,
909
905
  s
910
906
  ] })
911
907
  );
912
908
  }
913
- function Vt({
914
- src: e,
915
- alt: t,
916
- placeholder: r = "No image",
909
+ function Le({
910
+ src: t,
911
+ alt: e,
912
+ placeholder: n = "No image",
917
913
  size: s = "md",
918
914
  fit: a = "contain",
919
915
  onImageError: u,
920
- className: m,
916
+ className: h,
921
917
  ...f
922
918
  }) {
923
- const [p, b] = Se(null), h = !!(e && p === e), k = l("image-thumb", `image-thumb--${s}`, `image-thumb--fit-${a}`, m);
924
- return /* @__PURE__ */ n("div", { className: k, ...f, children: e && !h ? /* @__PURE__ */ n(
919
+ const [p, w] = vt(null), d = !!(t && p === t), N = l("image-thumb", `image-thumb--${s}`, `image-thumb--fit-${a}`, h);
920
+ return /* @__PURE__ */ r("div", { className: N, ...f, children: t && !d ? /* @__PURE__ */ r(
925
921
  "img",
926
922
  {
927
- src: e,
928
- alt: t,
923
+ src: t,
924
+ alt: e,
929
925
  className: "image-thumb__img",
930
926
  style: { objectFit: a, objectPosition: "center" },
931
927
  onError: () => {
932
- b(e), u == null || u();
928
+ w(t), u == null || u();
933
929
  }
934
930
  }
935
- ) : /* @__PURE__ */ n("span", { className: "image-thumb__placeholder", children: r }) });
931
+ ) : /* @__PURE__ */ r("span", { className: "image-thumb__placeholder", children: n }) });
936
932
  }
937
- function lt({
938
- as: e,
939
- justify: t = "start",
940
- className: r,
933
+ function Oe({
934
+ as: t,
935
+ justify: e = "start",
936
+ className: n,
941
937
  ...s
942
938
  }) {
943
- return T(e ?? "div", {
944
- className: l(t === "between" ? "space-between" : t === "end" ? "space-end" : "inline-row", r),
939
+ return W(t ?? "div", {
940
+ className: l(e === "between" ? "space-between" : e === "end" ? "space-end" : "inline-row", n),
945
941
  ...s
946
942
  });
947
943
  }
948
- const jt = me(function({ className: t, ...r }, s) {
949
- return /* @__PURE__ */ n("input", { ref: s, className: l(t), ...r });
944
+ const Ae = dt(function({ className: e, ...n }, s) {
945
+ return /* @__PURE__ */ r("input", { ref: s, className: l(e), ...n });
950
946
  });
951
- function ze({ as: e = "div", className: t, ...r }) {
952
- return T(e, {
953
- className: l("item-card", t),
954
- ...r
947
+ function ie({ as: t = "div", className: e, ...n }) {
948
+ return W(t, {
949
+ className: l("item-card", e),
950
+ ...n
955
951
  });
956
952
  }
957
- function ut({ as: e = "div", className: t, ...r }) {
958
- return T(e, {
959
- className: l("item-list", t),
960
- ...r
953
+ function $e({ as: t = "div", className: e, ...n }) {
954
+ return W(t, {
955
+ className: l("item-list", e),
956
+ ...n
961
957
  });
962
958
  }
963
- function Ut({ label: e = "Loading...", className: t }) {
964
- return /* @__PURE__ */ d("span", { className: l("status-inline", t), children: [
965
- /* @__PURE__ */ n(pe, { size: 14, className: "icon-spin" }),
966
- e
959
+ function Be({ label: t = "Loading...", className: e }) {
960
+ return /* @__PURE__ */ m("span", { className: l("status-inline", e), children: [
961
+ /* @__PURE__ */ r(ht, { size: 14, className: "icon-spin" }),
962
+ t
967
963
  ] });
968
964
  }
969
- function Zt({
970
- className: e,
971
- placement: t,
972
- onPointerDown: r,
965
+ function He({
966
+ className: t,
967
+ placement: e,
968
+ onPointerDown: n,
973
969
  onWheel: s,
974
970
  onContextMenu: a,
975
971
  ...u
976
972
  }) {
977
- return /* @__PURE__ */ n(
978
- Me,
973
+ return /* @__PURE__ */ r(
974
+ xt,
979
975
  {
980
976
  variant: "secondary",
981
977
  iconOnly: !0,
982
- className: l("overlay-icon-btn", t && `overlay-icon-btn--${t}`, e),
983
- onPointerDown: (m) => {
984
- m.stopPropagation(), r == null || r(m);
978
+ className: l("overlay-icon-btn", e && `overlay-icon-btn--${e}`, t),
979
+ onPointerDown: (h) => {
980
+ h.stopPropagation(), n == null || n(h);
985
981
  },
986
- onWheel: (m) => {
987
- m.stopPropagation(), s == null || s(m);
982
+ onWheel: (h) => {
983
+ h.stopPropagation(), s == null || s(h);
988
984
  },
989
- onContextMenu: (m) => {
990
- m.stopPropagation(), a == null || a(m);
985
+ onContextMenu: (h) => {
986
+ h.stopPropagation(), a == null || a(h);
991
987
  },
992
988
  ...u
993
989
  }
994
990
  );
995
991
  }
996
- function qt({ children: e, className: t, ...r }) {
997
- return /* @__PURE__ */ n("main", { className: l("page-shell", t), ...r, children: e });
992
+ function Ve({ children: t, className: e, ...n }) {
993
+ return /* @__PURE__ */ r("main", { className: l("page-shell", e), ...n, children: t });
998
994
  }
999
- function Kt({ children: e, className: t, ...r }) {
1000
- return /* @__PURE__ */ n("div", { className: l("page-card", t), ...r, children: e });
995
+ function je({ children: t, className: e, ...n }) {
996
+ return /* @__PURE__ */ r("div", { className: l("page-card", e), ...n, children: t });
1001
997
  }
1002
- function Jt({ onClick: e, label: t = "Close" }) {
1003
- return /* @__PURE__ */ d(Me, { variant: "secondary", className: "panel-close-btn", onClick: e, children: [
1004
- /* @__PURE__ */ n(ke, { size: 14 }),
1005
- t
998
+ function Ze({ onClick: t, label: e = "Close" }) {
999
+ return /* @__PURE__ */ m(xt, { variant: "secondary", className: "panel-close-btn", onClick: t, children: [
1000
+ /* @__PURE__ */ r(Nt, { size: 14 }),
1001
+ e
1006
1002
  ] });
1007
1003
  }
1008
- function Qt({ heading: e, description: t, actions: r, className: s, children: a, ...u }) {
1009
- return /* @__PURE__ */ d("section", { className: l("widget-section", s), ...u, children: [
1010
- e || r ? /* @__PURE__ */ d("header", { className: r ? "title-row" : void 0, children: [
1011
- e ? /* @__PURE__ */ n(it, { children: e }) : null,
1012
- r
1004
+ function Ue({ heading: t, description: e, actions: n, className: s, children: a, ...u }) {
1005
+ return /* @__PURE__ */ m("section", { className: l("widget-section", s), ...u, children: [
1006
+ t || n ? /* @__PURE__ */ m("header", { className: n ? "title-row" : void 0, children: [
1007
+ t ? /* @__PURE__ */ r(re, { children: t }) : null,
1008
+ n
1013
1009
  ] }) : null,
1014
- t ? /* @__PURE__ */ n(ot, { children: t }) : null,
1010
+ e ? /* @__PURE__ */ r(se, { children: e }) : null,
1015
1011
  a
1016
1012
  ] });
1017
1013
  }
1018
- function en({ icon: e, label: t }) {
1019
- return /* @__PURE__ */ d("span", { className: "panel-title-with-icon", children: [
1020
- /* @__PURE__ */ n(e, { size: 13, className: "panel-title-icon" }),
1021
- /* @__PURE__ */ n("span", { children: t })
1014
+ function qe({ icon: t, label: e }) {
1015
+ return /* @__PURE__ */ m("span", { className: "panel-title-with-icon", children: [
1016
+ /* @__PURE__ */ r(t, { size: 13, className: "panel-title-icon" }),
1017
+ /* @__PURE__ */ r("span", { children: e })
1022
1018
  ] });
1023
1019
  }
1024
- function dt({ as: e = "button", className: t, ...r }) {
1025
- return T(e, {
1026
- className: l("picker-card", t),
1027
- ...r
1020
+ function oe({ as: t = "button", className: e, ...n }) {
1021
+ return W(t, {
1022
+ className: l("picker-card", e),
1023
+ ...n
1028
1024
  });
1029
1025
  }
1030
- const ht = {
1031
- elements: "picker-grid--elements",
1032
- characters: "picker-grid--characters",
1033
- library: "picker-grid--library"
1034
- };
1035
- function tn({ variant: e, className: t, ...r }) {
1036
- return /* @__PURE__ */ n(fe, { className: l("picker-grid", ht[e], t), ...r });
1026
+ function Ke({ minItemWidth: t = 120, className: e, style: n, ...s }) {
1027
+ const a = {
1028
+ gridTemplateColumns: `repeat(auto-fill, minmax(${t}px, 1fr))`,
1029
+ ...n
1030
+ };
1031
+ return /* @__PURE__ */ r(mt, { className: l("picker-grid", e), style: a, ...s });
1037
1032
  }
1038
- const mt = {
1033
+ const ce = {
1039
1034
  default: "",
1040
1035
  success: "success",
1041
1036
  warning: "warning",
1042
1037
  danger: "danger"
1043
1038
  };
1044
- function nn({ tone: e = "default", className: t, ...r }) {
1045
- return /* @__PURE__ */ n("span", { className: l("pill", mt[e], t), ...r });
1046
- }
1047
- const rn = me(function({ className: t, ...r }, s) {
1048
- return /* @__PURE__ */ n("select", { ref: s, className: l(t), ...r });
1049
- }), pt = {
1050
- element: "split-layout--element",
1051
- character: "split-layout--character",
1052
- user: "split-layout--user"
1039
+ function Je({ tone: t = "default", className: e, ...n }) {
1040
+ return /* @__PURE__ */ r("span", { className: l("pill", ce[t], e), ...n });
1041
+ }
1042
+ const Qe = dt(function({ className: e, ...n }, s) {
1043
+ return /* @__PURE__ */ r("select", { ref: s, className: l(e), ...n });
1044
+ }), le = {
1045
+ "media-content": "split-layout--media-content",
1046
+ single: "split-layout--single",
1047
+ "media-content-actions": "split-layout--media-content-actions"
1053
1048
  };
1054
- function ft({ variant: e, className: t, ...r }) {
1055
- return /* @__PURE__ */ n("div", { className: l("split-layout", pt[e], t), ...r });
1049
+ function tn({ variant: t, className: e, ...n }) {
1050
+ return /* @__PURE__ */ r("div", { className: l("split-layout", le[t], e), ...n });
1056
1051
  }
1057
- function gt({ className: e, ...t }) {
1058
- return /* @__PURE__ */ n("div", { className: l("tag-row", e), ...t });
1052
+ function ue({ className: t, ...e }) {
1053
+ return /* @__PURE__ */ r("div", { className: l("tag-row", t), ...e });
1059
1054
  }
1060
- const sn = me(function({ className: t, ...r }, s) {
1061
- return /* @__PURE__ */ n("textarea", { ref: s, className: l(t), ...r });
1055
+ const en = dt(function({ className: e, ...n }, s) {
1056
+ return /* @__PURE__ */ r("textarea", { ref: s, className: l(e), ...n });
1062
1057
  });
1063
- function an({ className: e, theme: t = "light", onToggle: r, lightIcon: s, darkIcon: a }) {
1064
- return /* @__PURE__ */ n("button", { className: e, onClick: r, title: `Switch to ${t === "light" ? "dark" : "light"} mode`, "aria-label": "Toggle theme", children: t === "light" ? a ?? /* @__PURE__ */ n($e, {}) : s ?? /* @__PURE__ */ n(Ve, {}) });
1058
+ function nn({ className: t, theme: e = "light", onToggle: n, lightIcon: s, darkIcon: a }) {
1059
+ return /* @__PURE__ */ r(
1060
+ "button",
1061
+ {
1062
+ type: "button",
1063
+ className: l("wb-btn", "wb-btn--secondary", "wb-btn--icon-only", t),
1064
+ onClick: n,
1065
+ title: `Switch to ${e === "light" ? "dark" : "light"} mode`,
1066
+ "aria-label": "Toggle theme",
1067
+ children: e === "light" ? a ?? /* @__PURE__ */ r($t, { size: 14 }) : s ?? /* @__PURE__ */ r(Bt, { size: 14 })
1068
+ }
1069
+ );
1065
1070
  }
1066
- function on({ className: e, ...t }) {
1067
- return /* @__PURE__ */ n("div", { className: l("title-row", e), ...t });
1071
+ function rn({ className: t, ...e }) {
1072
+ return /* @__PURE__ */ r("div", { className: l("title-row", t), ...e });
1068
1073
  }
1069
- function cn({
1070
- children: e,
1071
- bottom: t,
1072
- position: r = "left",
1074
+ function sn({
1075
+ children: t,
1076
+ bottom: e,
1077
+ position: n = "left",
1073
1078
  className: s,
1074
1079
  ...a
1075
1080
  }) {
1076
- return /* @__PURE__ */ d(
1081
+ return /* @__PURE__ */ m(
1077
1082
  "nav",
1078
1083
  {
1079
1084
  className: l(
1080
1085
  "vertical-toolbar",
1081
- r === "right" && "vertical-toolbar--right",
1082
- r === "static" && "vertical-toolbar--static",
1086
+ n === "right" && "vertical-toolbar--right",
1087
+ n === "static" && "vertical-toolbar--static",
1083
1088
  s
1084
1089
  ),
1085
1090
  ...a,
1086
1091
  children: [
1087
- /* @__PURE__ */ n("div", { className: "vertical-toolbar__links", children: e }),
1088
- t
1092
+ /* @__PURE__ */ r("div", { className: "vertical-toolbar__links", children: t }),
1093
+ e
1089
1094
  ]
1090
1095
  }
1091
1096
  );
1092
1097
  }
1093
- function ln({ inputs: e = 1, showButton: t = !0, className: r, ...s }) {
1094
- return /* @__PURE__ */ d(J, { className: r, ...s, children: [
1095
- Array.from({ length: e }).map((a, u) => /* @__PURE__ */ n(tt, {}, `panel-form-input-${u}`)),
1096
- t && /* @__PURE__ */ n(ve, {})
1097
- ] });
1098
- }
1099
- function un() {
1100
- return /* @__PURE__ */ d("article", { className: "story-card", children: [
1101
- /* @__PURE__ */ n("div", { className: "story-cover", children: /* @__PURE__ */ n("div", { className: "story-cover__placeholder story-cover__placeholder--skeleton" }) }),
1102
- /* @__PURE__ */ n("div", { className: "story-card__overlay story-card__overlay--skeleton", children: /* @__PURE__ */ d("div", { className: "story-card__overlay-text", children: [
1103
- /* @__PURE__ */ d(lt, { as: "header", children: [
1104
- /* @__PURE__ */ n(ne, {}),
1105
- /* @__PURE__ */ n(ne, {})
1106
- ] }),
1107
- /* @__PURE__ */ n(ge, {}),
1108
- /* @__PURE__ */ n(be, { short: !0 })
1109
- ] }) })
1098
+ function an({ inputs: t = 1, showButton: e = !0, className: n, ...s }) {
1099
+ return /* @__PURE__ */ m(pt, { className: n, ...s, children: [
1100
+ Array.from({ length: t }).map((a, u) => /* @__PURE__ */ r(Qt, {}, `panel-form-input-${u}`)),
1101
+ e && /* @__PURE__ */ r(St, {})
1110
1102
  ] });
1111
1103
  }
1112
- function bt() {
1113
- return /* @__PURE__ */ n(ze, { as: "li", children: /* @__PURE__ */ d(ft, { variant: "user", children: [
1114
- /* @__PURE__ */ n(rt, {}),
1115
- /* @__PURE__ */ d(J, { size: "sm", children: [
1116
- /* @__PURE__ */ n(ge, {}),
1117
- /* @__PURE__ */ n(be, { short: !0 })
1118
- ] }),
1119
- /* @__PURE__ */ d(J, { size: "sm", children: [
1120
- /* @__PURE__ */ n(ne, {}),
1121
- /* @__PURE__ */ n(nt, {})
1122
- ] })
1123
- ] }) });
1124
- }
1125
- function dn({ count: e = 3 }) {
1126
- return /* @__PURE__ */ n(ut, { as: "ul", children: Array.from({ length: e }).map((t, r) => /* @__PURE__ */ n(bt, {}, `user-skeleton-${r}`)) });
1127
- }
1128
- function hn() {
1129
- return /* @__PURE__ */ d(ze, { as: "li", children: [
1130
- /* @__PURE__ */ d(J, { size: "sm", children: [
1131
- /* @__PURE__ */ n(_e, { className: "asset-thumb" }),
1132
- /* @__PURE__ */ n(ge, {}),
1133
- /* @__PURE__ */ d(gt, { children: [
1134
- /* @__PURE__ */ n(ne, {}),
1135
- /* @__PURE__ */ n(ne, {})
1136
- ] })
1104
+ function on({
1105
+ withThumb: t = !0,
1106
+ chipCount: e = 0,
1107
+ actionCount: n = 0,
1108
+ className: s,
1109
+ ...a
1110
+ }) {
1111
+ return /* @__PURE__ */ m(ie, { as: "li", className: s, ...a, children: [
1112
+ /* @__PURE__ */ m(pt, { size: "sm", children: [
1113
+ t ? /* @__PURE__ */ r(Mt, {}) : null,
1114
+ e > 0 ? /* @__PURE__ */ r(ue, { children: Array.from({ length: e }).map((u, h) => /* @__PURE__ */ r(te, {}, `card-skeleton-chip-${h}`)) }) : null,
1115
+ /* @__PURE__ */ r(kt, {}),
1116
+ /* @__PURE__ */ r(wt, { short: !0 })
1137
1117
  ] }),
1138
- /* @__PURE__ */ d(Je, { children: [
1139
- /* @__PURE__ */ n(ve, {}),
1140
- /* @__PURE__ */ n(ve, {})
1141
- ] })
1118
+ n > 0 ? /* @__PURE__ */ r(qt, { children: Array.from({ length: n }).map((u, h) => /* @__PURE__ */ r(St, {}, `card-skeleton-btn-${h}`)) }) : null
1142
1119
  ] });
1143
1120
  }
1144
- function mn({ count: e = 8, gridClass: t }) {
1145
- return /* @__PURE__ */ n(fe, { className: l("picker-grid", t), children: Array.from({ length: e }).map((r, s) => /* @__PURE__ */ n("li", { children: /* @__PURE__ */ n(dt, { as: "div", className: "picker-card--skeleton", children: /* @__PURE__ */ d(J, { size: "sm", children: [
1146
- /* @__PURE__ */ n(_e, { className: "asset-thumb" }),
1147
- /* @__PURE__ */ n(be, { short: !0 })
1148
- ] }) }) }, `picker-skeleton-${s}`)) });
1121
+ function cn({ count: t = 8, minItemWidth: e = 120 }) {
1122
+ return /* @__PURE__ */ r(
1123
+ mt,
1124
+ {
1125
+ className: "picker-grid",
1126
+ style: { gridTemplateColumns: `repeat(auto-fill, minmax(${e}px, 1fr))` },
1127
+ children: Array.from({ length: t }).map((n, s) => /* @__PURE__ */ r("li", { children: /* @__PURE__ */ r(oe, { as: "div", className: "picker-card--skeleton", children: /* @__PURE__ */ m(pt, { size: "sm", children: [
1128
+ /* @__PURE__ */ r(Mt, {}),
1129
+ /* @__PURE__ */ r(wt, { short: !0 })
1130
+ ] }) }) }, `picker-skeleton-${s}`))
1131
+ }
1132
+ );
1149
1133
  }
1150
1134
  export {
1151
- Ct as Alert,
1152
- hn as AssetCardSkeleton,
1153
- at as AssetTitle,
1154
- Tt as AvatarBadge,
1155
- rt as AvatarSkeleton,
1156
- Me as Button,
1157
- Je as ButtonRow,
1158
- ve as ButtonSkeleton,
1159
- Dt as CanvasSkeleton,
1160
- Rt as CanvasStage,
1161
- Wt as Chip,
1162
- ne as ChipSkeleton,
1163
- Qe as ChoiceCard,
1164
- It as ChoiceGroup,
1165
- Ft as ChoiceGroupSkeleton,
1166
- _t as ConfirmDialog,
1167
- Gt as CoordGrid,
1168
- Lt as CoordInput,
1169
- Ot as EmptyState,
1170
- Bt as Field,
1171
- St as FloatingPanel,
1172
- Ht as GeneratingOverlay,
1173
- Xt as IconButtonSkeleton,
1174
- $t as IconText,
1175
- Vt as ImageThumb,
1176
- lt as Inline,
1177
- jt as Input,
1178
- tt as InputSkeleton,
1179
- ze as ItemCard,
1180
- ut as ItemList,
1181
- ct as Label,
1182
- be as LineSkeleton,
1183
- fe as List,
1184
- Ut as LoadingState,
1185
- Ze as Minimap,
1186
- Pe as MutedText,
1187
- Zt as OverlayIconButton,
1188
- Kt as PageCard,
1189
- qt as PageShell,
1190
- At as PageTitle,
1191
- Jt as PanelCloseButton,
1192
- Pt as PanelErrorBoundary,
1193
- ln as PanelFormSkeleton,
1194
- Qt as PanelSection,
1195
- en as PanelTitle,
1196
- dt as PickerCard,
1197
- tn as PickerGrid,
1198
- mn as PickerGridSkeleton,
1199
- nn as Pill,
1200
- ot as SectionDescription,
1201
- it as SectionTitle,
1202
- rn as Select,
1203
- nt as SelectSkeleton,
1135
+ xe as Alert,
1136
+ Se as AvatarBadge,
1137
+ Ce as AvatarSkeleton,
1138
+ xt as Button,
1139
+ qt as ButtonRow,
1140
+ St as ButtonSkeleton,
1141
+ Te as CanvasSkeleton,
1142
+ Me as CanvasStage,
1143
+ on as CardSkeleton,
1144
+ ne as CardTitle,
1145
+ ke as Chip,
1146
+ te as ChipSkeleton,
1147
+ Kt as ChoiceCard,
1148
+ Re as ChoiceGroup,
1149
+ We as ChoiceGroupSkeleton,
1150
+ ye as ConfirmDialog,
1151
+ Xe as CoordGrid,
1152
+ Ye as CoordInput,
1153
+ Ie as EmptyState,
1154
+ Fe as Field,
1155
+ be as FloatingPanel,
1156
+ Ge as GeneratingOverlay,
1157
+ Pe as IconButtonSkeleton,
1158
+ Ee as IconText,
1159
+ Le as ImageThumb,
1160
+ Oe as Inline,
1161
+ Ae as Input,
1162
+ Qt as InputSkeleton,
1163
+ ie as ItemCard,
1164
+ $e as ItemList,
1165
+ ae as Label,
1166
+ wt as LineSkeleton,
1167
+ mt as List,
1168
+ Be as LoadingState,
1169
+ jt as Minimap,
1170
+ Pt as MutedText,
1171
+ He as OverlayIconButton,
1172
+ je as PageCard,
1173
+ Ve as PageShell,
1174
+ De as PageTitle,
1175
+ Ze as PanelCloseButton,
1176
+ ve as PanelErrorBoundary,
1177
+ an as PanelFormSkeleton,
1178
+ Ue as PanelSection,
1179
+ qe as PanelTitle,
1180
+ oe as PickerCard,
1181
+ Ke as PickerGrid,
1182
+ cn as PickerGridSkeleton,
1183
+ Je as Pill,
1184
+ se as SectionDescription,
1185
+ re as SectionTitle,
1186
+ Qe as Select,
1187
+ _e as SelectSkeleton,
1204
1188
  G as Skeleton,
1205
- ft as SplitLayout,
1206
- J as Stack,
1207
- un as StoryCardSkeleton,
1208
- Et as StoryTitle,
1209
- gt as TagRow,
1210
- sn as Textarea,
1211
- Yt as TextareaSkeleton,
1212
- an as ThemeToggle,
1213
- _e as ThumbSkeleton,
1214
- on as TitleRow,
1215
- ge as TitleSkeleton,
1216
- bt as UserCardSkeleton,
1217
- dn as UserListSkeleton,
1218
- cn as VerticalToolbar,
1219
- he as WHITEBOARD_GRID,
1220
- xt as WhiteboardShell,
1221
- Ue as ZoomBar,
1222
- Mt as belowPanel,
1189
+ tn as SplitLayout,
1190
+ pt as Stack,
1191
+ ue as TagRow,
1192
+ en as Textarea,
1193
+ ze as TextareaSkeleton,
1194
+ nn as ThemeToggle,
1195
+ Mt as ThumbSkeleton,
1196
+ rn as TitleRow,
1197
+ kt as TitleSkeleton,
1198
+ sn as VerticalToolbar,
1199
+ ut as WHITEBOARD_GRID,
1200
+ fe as WhiteboardShell,
1201
+ Vt as ZoomBar,
1202
+ ge as belowPanel,
1223
1203
  l as cn,
1224
- Ne as computeWhiteboardFit,
1225
- je as computeWhiteboardRectFocus,
1226
- ue as snapToWhiteboardGrid,
1227
- kt as usePanelRect,
1228
- zt as useWhiteboardLayout,
1229
- g as useWhiteboardStore
1204
+ gt as computeWhiteboardFit,
1205
+ Ht as computeWhiteboardRectFocus,
1206
+ ct as snapToWhiteboardGrid,
1207
+ we as usePanelRect,
1208
+ Ne as useWhiteboardLayout,
1209
+ b as useWhiteboardStore
1230
1210
  };