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