@mt-gloss/ui 0.0.16 → 0.0.17

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/index.js CHANGED
@@ -1,10 +1,10 @@
1
- import { N as Xt, T as Jt, O as ea, Q as ta, b2 as aa, av as ra, ad as na, Z as oa, aj as sa, K as ia, a4 as la, bl as da, P as ca, B as ua, a as ma, y as ga, H as pa, be as ba, F as fa, J as ha, A as va, z as Ca, bd as ya, E as Da, D as wa, bt as Na, b as Sa, C as Ta, L as xa, o as ka, a9 as Ia, aJ as _a, y as Ra, H as Ma, F as Pa, J as Fa, A as Oa, z as Aa, E as Ea, D as La, aX as Ba, a_ as Ga, aZ as $a, aY as Ha, a$ as za, ay as Ka, am as Wa, k as Za, m as Ya, aB as qa, a7 as Va, b4 as Ua, a5 as ja, bm as Qa, Y as Xa, bD as Ja, bC as er, bE as tr, al as ar, aM as rr, b6 as nr, bI as or, n as sr, ai as ir, bx as lr, bp as dr, a0 as cr, an as ur, a2 as mr, bw as gr, G as pr, d as br, bg as fr, a6 as hr, bF as vr, aP as Cr, r as yr, v as Dr, I as wr, g as Nr, as as Sr, bJ as Tr, M as xr, w as kr, U as Ir, X as _r, V as Rr, W as Mr, ao as Pr, bc as Fr, bL as Or, bH as Ar, ak as Er, t as Lr, bn as Br, aO as Gr, af as $r, aG as Hr, ac as zr, ah as Kr, aq as Wr, aN as Zr, a8 as Yr, ap as qr, c as Vr, R as Ur, j as jr, p as Qr, aD as Xr, bu as Jr, bv as en, ae as tn, aa as an, h as rn, x as nn, b3 as on, ab as sn, bK as ln, b8 as dn, bb as cn, b9 as un, ba as mn, i as gn, b5 as pn, bk as bn, S as fn, bh as hn, bi as vn, ar as Cn, b7 as yn, bM as Dn, ag as wn, s as Nn, bG as Sn, l as Tn, f as xn, q as kn, _ as In, $ as _n, a3 as Rn, bf as Mn, bs as Pn, bz as Fn, aw as On, ax as An, aK as En, aL as Ln, az as Bn, aA as Gn, aC as $n, aR as Hn, aS as zn, bB as Kn, bA as Wn, aU as Zn, aV as Yn, at as qn, au as Vn, b1 as Un, b0 as jn, aW as Qn, aH as Xn, aI as Jn, aT as eo, aE as to, aF as ao, u as ro, by as no, bo as oo, bq as so, br as io, aQ as lo, a1 as co, e as uo, bj as mo } from "./Expandable-Bvd-OyRQ.js";
2
- import { jsxs as R, jsx as c } from "react/jsx-runtime";
3
- import I, { useRef as F, useEffect as B, useState as M, useCallback as f, forwardRef as ge, useMemo as pe, createContext as be, useContext as fe } from "react";
4
- import { B as he, U as j } from "./UIContext-C3E-k7HI.js";
5
- import { a as po, u as bo } from "./UIContext-C3E-k7HI.js";
1
+ import { N as Xt, T as Jt, O as ea, Q as ta, b2 as aa, av as ra, ad as na, Z as oa, aj as sa, K as ia, a4 as la, bl as da, P as ca, B as ua, a as ma, y as pa, H as ga, be as ba, F as ha, J as fa, A as va, z as Ca, bd as ya, E as Da, D as wa, bt as Na, b as Sa, C as Ta, L as xa, o as ka, a9 as Ia, aJ as _a, y as Pa, H as Ra, F as Ma, J as Fa, A as Oa, z as Aa, E as Ea, D as La, aX as Ba, a_ as Ga, aZ as $a, aY as Ha, a$ as za, ay as Ka, am as Wa, k as Za, m as Ya, aB as qa, a7 as Va, b4 as Ua, a5 as ja, bm as Qa, Y as Xa, bD as Ja, bC as er, bE as tr, al as ar, aM as rr, b6 as nr, bI as or, n as sr, ai as ir, bx as lr, bp as dr, a0 as cr, an as ur, a2 as mr, bw as pr, G as gr, d as br, bg as hr, a6 as fr, bF as vr, aP as Cr, r as yr, v as Dr, I as wr, g as Nr, as as Sr, bJ as Tr, M as xr, w as kr, U as Ir, X as _r, V as Pr, W as Rr, ao as Mr, bc as Fr, bL as Or, bH as Ar, ak as Er, t as Lr, bn as Br, aO as Gr, af as $r, aG as Hr, ac as zr, ah as Kr, aq as Wr, aN as Zr, a8 as Yr, ap as qr, c as Vr, R as Ur, j as jr, p as Qr, aD as Xr, bu as Jr, bv as en, ae as tn, aa as an, h as rn, x as nn, b3 as on, ab as sn, bK as ln, b8 as dn, bb as cn, b9 as un, ba as mn, i as pn, b5 as gn, bk as bn, S as hn, bh as fn, bi as vn, ar as Cn, b7 as yn, bM as Dn, ag as wn, s as Nn, bG as Sn, l as Tn, f as xn, q as kn, _ as In, $ as _n, a3 as Pn, bf as Rn, bs as Mn, bz as Fn, aw as On, ax as An, aK as En, aL as Ln, az as Bn, aA as Gn, aC as $n, aR as Hn, aS as zn, bB as Kn, bA as Wn, aU as Zn, aV as Yn, at as qn, au as Vn, b1 as Un, b0 as jn, aW as Qn, aH as Xn, aI as Jn, aT as eo, aE as to, aF as ao, u as ro, by as no, bo as oo, bq as so, br as io, aQ as lo, a1 as co, e as uo, bj as mo } from "./Expandable-Bvd-OyRQ.js";
2
+ import { jsxs as P, jsx as c } from "react/jsx-runtime";
3
+ import I, { useRef as F, useEffect as B, useState as R, useCallback as f, forwardRef as pe, useMemo as ge, createContext as be, useContext as he } from "react";
4
+ import { B as fe, U as j } from "./UIContext-C3E-k7HI.js";
5
+ import { a as go, u as bo } from "./UIContext-C3E-k7HI.js";
6
6
  import { createPortal as ve } from "react-dom";
7
- import { DEFAULT_MARKET_PRESETS as ho, DEFAULT_PINNED as vo, PERIOD_OPTIONS as Co, ROLLING_OPTIONS as yo, TODAY_PRESET as Do, findPreset as wo, formatDateRange as No, formatMarketDates as So, formatTrend as To, formatValue as xo, generateMarketId as ko, getAllPresets as Io, getDateRangeForPreset as _o, getPresetLabel as Ro, isInRange as Mo, isMarketActive as Po, isSameDay as Fo, normalizePresetId as Oo, toUppercasePresetId as Ao } from "@mt-gloss/utils";
7
+ import { DEFAULT_MARKET_PRESETS as fo, DEFAULT_PINNED as vo, PERIOD_OPTIONS as Co, ROLLING_OPTIONS as yo, TODAY_PRESET as Do, findPreset as wo, formatDateRange as No, formatMarketDates as So, formatTrend as To, formatValue as xo, generateMarketId as ko, getAllPresets as Io, getDateRangeForPreset as _o, getPresetLabel as Po, isInRange as Ro, isMarketActive as Mo, isSameDay as Fo, normalizePresetId as Oo, toUppercasePresetId as Ao } from "@mt-gloss/utils";
8
8
  function st(e = {}) {
9
9
  const { enabled: t = !0, returnTo: r } = e, a = F(null);
10
10
  return B(() => {
@@ -24,92 +24,92 @@ function it(e) {
24
24
  orientation: o = "vertical",
25
25
  enabled: s = !0,
26
26
  isItemDisabled: d,
27
- onSelect: m,
28
- onEscape: g
29
- } = e, [y, D] = M(-1), p = r !== void 0 ? r : y, l = f(
30
- (u) => {
31
- r === void 0 && D(u), a?.(u);
27
+ onSelect: u,
28
+ onEscape: p
29
+ } = e, [b, D] = R(-1), g = r !== void 0 ? r : b, l = f(
30
+ (m) => {
31
+ r === void 0 && D(m), a?.(m);
32
32
  },
33
33
  [r, a]
34
- ), b = f(() => t.map((u, w) => ({ item: u, index: w })).filter(({ item: u, index: w }) => !d?.(u, w)).map(({ index: u }) => u), [t, d]), S = f(
35
- (u, w) => {
36
- const v = b();
37
- if (v.length === 0) return -1;
38
- const O = v.indexOf(u);
34
+ ), h = f(() => t.map((m, w) => ({ item: m, index: w })).filter(({ item: m, index: w }) => !d?.(m, w)).map(({ index: m }) => m), [t, d]), S = f(
35
+ (m, w) => {
36
+ const C = h();
37
+ if (C.length === 0) return -1;
38
+ const O = C.indexOf(m);
39
39
  if (O === -1)
40
- return w === 1 ? v.find((E) => E > u) ?? (n ? v[0] : -1) : [...v].reverse().find((G) => G < u) ?? (n ? v[v.length - 1] : -1);
40
+ return w === 1 ? C.find((E) => E > m) ?? (n ? C[0] : -1) : [...C].reverse().find((G) => G < m) ?? (n ? C[C.length - 1] : -1);
41
41
  let k = O + w;
42
- return n ? k = (k + v.length) % v.length : k = Math.max(0, Math.min(v.length - 1, k)), v[k];
42
+ return n ? k = (k + C.length) % C.length : k = Math.max(0, Math.min(C.length - 1, k)), C[k];
43
43
  },
44
- [b, n]
44
+ [h, n]
45
45
  ), T = f(() => {
46
- const u = b();
47
- u.length > 0 && l(u[0]);
48
- }, [b, l]), i = f(() => {
49
- const u = b();
50
- u.length > 0 && l(u[u.length - 1]);
51
- }, [b, l]), h = f(() => {
52
- const u = S(p, 1);
53
- u !== -1 && l(u);
54
- }, [p, S, l]), N = f(() => {
55
- const u = S(p, -1);
56
- u !== -1 && l(u);
57
- }, [p, S, l]), C = f(() => {
46
+ const m = h();
47
+ m.length > 0 && l(m[0]);
48
+ }, [h, l]), i = f(() => {
49
+ const m = h();
50
+ m.length > 0 && l(m[m.length - 1]);
51
+ }, [h, l]), v = f(() => {
52
+ const m = S(g, 1);
53
+ m !== -1 && l(m);
54
+ }, [g, S, l]), N = f(() => {
55
+ const m = S(g, -1);
56
+ m !== -1 && l(m);
57
+ }, [g, S, l]), y = f(() => {
58
58
  l(-1);
59
59
  }, [l]), x = f(
60
- (u) => {
60
+ (m) => {
61
61
  if (!s) return;
62
- const { key: w } = u, v = w === "ArrowUp" && (o === "vertical" || o === "both"), O = w === "ArrowDown" && (o === "vertical" || o === "both"), k = w === "ArrowLeft" && (o === "horizontal" || o === "both"), E = w === "ArrowRight" && (o === "horizontal" || o === "both");
63
- if (v || k) {
64
- u.preventDefault(), p === -1 ? i() : N();
62
+ const { key: w } = m, C = w === "ArrowUp" && (o === "vertical" || o === "both"), O = w === "ArrowDown" && (o === "vertical" || o === "both"), k = w === "ArrowLeft" && (o === "horizontal" || o === "both"), E = w === "ArrowRight" && (o === "horizontal" || o === "both");
63
+ if (C || k) {
64
+ m.preventDefault(), g === -1 ? i() : N();
65
65
  return;
66
66
  }
67
67
  if (O || E) {
68
- u.preventDefault(), p === -1 ? T() : h();
68
+ m.preventDefault(), g === -1 ? T() : v();
69
69
  return;
70
70
  }
71
71
  if (w === "Home") {
72
- u.preventDefault(), T();
72
+ m.preventDefault(), T();
73
73
  return;
74
74
  }
75
75
  if (w === "End") {
76
- u.preventDefault(), i();
76
+ m.preventDefault(), i();
77
77
  return;
78
78
  }
79
- if ((w === "Enter" || w === " ") && p >= 0 && p < t.length) {
80
- u.preventDefault();
81
- const G = t[p];
82
- d?.(G, p) || m?.(G, p);
79
+ if ((w === "Enter" || w === " ") && g >= 0 && g < t.length) {
80
+ m.preventDefault();
81
+ const G = t[g];
82
+ d?.(G, g) || u?.(G, g);
83
83
  return;
84
84
  }
85
85
  if (w === "Escape") {
86
- g?.();
86
+ p?.();
87
87
  return;
88
88
  }
89
89
  },
90
90
  [
91
91
  s,
92
92
  o,
93
- p,
93
+ g,
94
94
  t,
95
95
  T,
96
96
  i,
97
- h,
97
+ v,
98
98
  N,
99
99
  d,
100
- m,
101
- g
100
+ u,
101
+ p
102
102
  ]
103
103
  );
104
104
  return {
105
- focusedIndex: p,
105
+ focusedIndex: g,
106
106
  setFocusedIndex: l,
107
107
  handleKeyDown: x,
108
108
  focusFirst: T,
109
109
  focusLast: i,
110
- focusNext: h,
110
+ focusNext: v,
111
111
  focusPrevious: N,
112
- resetFocus: C
112
+ resetFocus: y
113
113
  };
114
114
  }
115
115
  const K = (e) => {
@@ -169,21 +169,21 @@ const K = (e) => {
169
169
  { variant: "block", width: 200, height: 32, borderRadius: 8 },
170
170
  { variant: "block", width: "80%", height: 12, borderRadius: "4px" },
171
171
  { variant: "block", width: 120, height: 44, borderRadius: 22 }
172
- ], gt = [
172
+ ], pt = [
173
173
  { variant: "text", lines: 3, lineHeight: 14, gap: 8 },
174
174
  { variant: "text", lines: 2, lineHeight: 16, gap: 10 },
175
175
  { variant: "text", lines: 5, lineHeight: 12, gap: 6 }
176
- ], pt = [
176
+ ], gt = [
177
177
  { variant: "circle", size: 24 },
178
178
  { variant: "circle", size: 40 },
179
179
  { variant: "circle", size: 64 }
180
180
  ], bt = [
181
181
  { bars: 10, maxHeight: 120 },
182
182
  { bars: 5, maxHeight: 80 }
183
- ], ft = [
183
+ ], ht = [
184
184
  { rows: 5, columns: 3, hasCheckbox: !1, rowHeight: 44 },
185
185
  { rows: 8, columns: 5, hasCheckbox: !0, rowHeight: 44 }
186
- ], ht = [
186
+ ], ft = [
187
187
  { variant: "value", colSpan: 1 },
188
188
  { variant: "trend", colSpan: 2 },
189
189
  { variant: "target", colSpan: 1 }
@@ -231,7 +231,7 @@ function Te({
231
231
  overflowActions: o,
232
232
  onClose: s
233
233
  }) {
234
- const [d, m] = M(null), g = F(null), y = f(() => {
234
+ const [d, u] = R(null), p = F(null), b = f(() => {
235
235
  if (!t) return { ...J, top: 0, left: 0 };
236
236
  const l = t.getBoundingClientRect();
237
237
  return {
@@ -242,33 +242,33 @@ function Te({
242
242
  }, [t]);
243
243
  if (B(() => {
244
244
  if (!e) return;
245
- const l = (b) => {
246
- b.key === "Escape" && s();
245
+ const l = (h) => {
246
+ h.key === "Escape" && s();
247
247
  };
248
248
  return document.addEventListener("keydown", l), () => document.removeEventListener("keydown", l);
249
249
  }, [e, s]), B(() => {
250
250
  if (!e) return;
251
- const l = (b) => {
252
- g.current && !g.current.contains(b.target) && s();
251
+ const l = (h) => {
252
+ p.current && !p.current.contains(h.target) && s();
253
253
  };
254
254
  return document.addEventListener("pointerdown", l, !0), () => document.removeEventListener("pointerdown", l, !0);
255
255
  }, [e, s]), !e) return null;
256
- const D = o && o.length > 0, p = /* @__PURE__ */ R(
256
+ const D = o && o.length > 0, g = /* @__PURE__ */ P(
257
257
  "div",
258
258
  {
259
- ref: g,
259
+ ref: p,
260
260
  "data-status-chip-menu": r,
261
261
  role: "menu",
262
262
  "aria-label": "Status actions",
263
- style: y(),
263
+ style: b(),
264
264
  children: [
265
265
  /* @__PURE__ */ c(
266
266
  "button",
267
267
  {
268
268
  role: "menuitem",
269
269
  style: Ne(d === "__primary"),
270
- onMouseEnter: () => m("__primary"),
271
- onMouseLeave: () => m(null),
270
+ onMouseEnter: () => u("__primary"),
271
+ onMouseLeave: () => u(null),
272
272
  onClick: () => {
273
273
  a(r), s();
274
274
  },
@@ -280,8 +280,8 @@ function Te({
280
280
  {
281
281
  role: "menuitem",
282
282
  style: Y(d === "__graph"),
283
- onMouseEnter: () => m("__graph"),
284
- onMouseLeave: () => m(null),
283
+ onMouseEnter: () => u("__graph"),
284
+ onMouseLeave: () => u(null),
285
285
  onClick: () => {
286
286
  n(r), s();
287
287
  },
@@ -294,8 +294,8 @@ function Te({
294
294
  {
295
295
  role: "menuitem",
296
296
  style: Y(d === l.id),
297
- onMouseEnter: () => m(l.id),
298
- onMouseLeave: () => m(null),
297
+ onMouseEnter: () => u(l.id),
298
+ onMouseLeave: () => u(null),
299
299
  onClick: () => {
300
300
  l.onSelect(r), s();
301
301
  },
@@ -306,12 +306,24 @@ function Te({
306
306
  ]
307
307
  }
308
308
  );
309
- return ve(p, document.body);
309
+ return ve(g, document.body);
310
310
  }
311
311
  Te.displayName = "StatusSlotChipMenu";
312
- const xe = ge(
312
+ const xe = pe(
313
313
  function({ state: t, onPointerDown: r, onPointerUp: a, edge: n = "right", ariaLabel: o = "Resize card" }, s) {
314
- const d = t === "handle-visible" || t === "dragging";
314
+ const d = t === "handle-visible" || t === "dragging", u = (b) => {
315
+ try {
316
+ b.currentTarget.setPointerCapture(b.pointerId);
317
+ } catch {
318
+ }
319
+ r(b);
320
+ }, p = (b) => {
321
+ try {
322
+ b.currentTarget.hasPointerCapture?.(b.pointerId) && b.currentTarget.releasePointerCapture(b.pointerId);
323
+ } catch {
324
+ }
325
+ a(b);
326
+ };
315
327
  return /* @__PURE__ */ c(
316
328
  "button",
317
329
  {
@@ -325,8 +337,8 @@ const xe = ge(
325
337
  `gloss-edge-handle--${n}`,
326
338
  d ? "gloss-edge-handle--visible" : ""
327
339
  ].filter(Boolean).join(" "),
328
- onPointerDown: r,
329
- onPointerUp: a,
340
+ onPointerDown: u,
341
+ onPointerUp: p,
330
342
  tabIndex: d ? 0 : -1
331
343
  }
332
344
  );
@@ -363,47 +375,47 @@ function vt({
363
375
  enterMs: o = 180,
364
376
  exitMs: s = 120
365
377
  }) {
366
- const [d, m] = M("idle"), g = F(null), y = F(null), D = f(() => {
367
- g.current && (clearTimeout(g.current), g.current = null);
368
- }, []), p = f(() => {
369
- m((i) => i !== "idle" ? i : (g.current = setTimeout(() => m("handle-visible"), n), "dwelling"));
378
+ const [d, u] = R("idle"), p = F(null), b = F(null), D = f(() => {
379
+ p.current && (clearTimeout(p.current), p.current = null);
380
+ }, []), g = f(() => {
381
+ u((i) => i !== "idle" ? i : (p.current = setTimeout(() => u("handle-visible"), n), "dwelling"));
370
382
  }, [n]), l = f(() => {
371
- D(), m((i) => i === "dwelling" || i === "handle-visible" ? "idle" : i);
372
- }, [D]), b = f(
383
+ D(), u((i) => i === "dwelling" || i === "handle-visible" ? "idle" : i);
384
+ }, [D]), h = f(
373
385
  (i) => {
374
- m((h) => h !== "handle-visible" ? h : (y.current = i.clientX, "dragging"));
386
+ u((v) => v !== "handle-visible" ? v : (b.current = i.clientX, "dragging"));
375
387
  },
376
388
  []
377
389
  ), S = f(
378
390
  (i) => {
379
- m((h) => {
380
- if (h !== "dragging") return h;
381
- const N = i.clientX - (y.current ?? i.clientX), x = Math.round(N / 180), u = Math.min(3, Math.max(1, e + x));
382
- if (u === e)
391
+ u((v) => {
392
+ if (v !== "dragging") return v;
393
+ const N = i.clientX - (b.current ?? i.clientX), x = Math.round(N / 180), m = Math.min(3, Math.max(1, e + x));
394
+ if (m === e)
383
395
  return a?.(), "cancelled";
384
- const w = u > e ? "grow" : "shrink";
385
- return r({ direction: w, targetColSpan: u, mode: t ? "slot-fill" : "sparkline-fidelity" }), "committed";
396
+ const w = m > e ? "grow" : "shrink";
397
+ return r({ direction: w, targetColSpan: m, mode: t ? "slot-fill" : "sparkline-fidelity" }), "committed";
386
398
  });
387
399
  },
388
400
  [e, t, r, a]
389
401
  ), T = f(() => {
390
- D(), m((i) => i === "dragging" || i === "handle-visible" ? (a?.(), "cancelled") : i);
402
+ D(), u((i) => i === "dragging" || i === "handle-visible" ? (a?.(), "cancelled") : i);
391
403
  }, [D, a]);
392
404
  return B(() => {
393
405
  if (d !== "dragging" && d !== "handle-visible") return;
394
- const i = (h) => {
395
- h.key === "Escape" && T();
406
+ const i = (v) => {
407
+ v.key === "Escape" && T();
396
408
  };
397
409
  return window.addEventListener("keydown", i), () => window.removeEventListener("keydown", i);
398
410
  }, [d, T]), B(() => () => D(), [D]), B(() => {
399
411
  if (d !== "committed" && d !== "cancelled") return;
400
- const i = setTimeout(() => m("idle"), s);
412
+ const i = setTimeout(() => u("idle"), s);
401
413
  return () => clearTimeout(i);
402
414
  }, [d, s]), {
403
415
  state: d,
404
- enterEdgeZone: p,
416
+ enterEdgeZone: g,
405
417
  leaveEdgeZone: l,
406
- handleProps: { onPointerDown: b, onPointerUp: S },
418
+ handleProps: { onPointerDown: h, onPointerUp: S },
407
419
  ghostProps: { visible: d === "dragging", enterMs: o, exitMs: s }
408
420
  };
409
421
  }
@@ -530,14 +542,14 @@ const Ct = {
530
542
  value: 125430,
531
543
  valueFormat: { prefix: "$", abbreviated: !0 },
532
544
  isError: !0
533
- }, Re = {
545
+ }, Pe = {
534
546
  variant: "standard",
535
547
  label: "Total Revenue",
536
548
  value: null,
537
549
  valueFormat: { prefix: "$", abbreviated: !0 },
538
550
  isEmpty: !0,
539
551
  subtitle: "No data"
540
- }, Me = {
552
+ }, Re = {
541
553
  variant: "standard",
542
554
  label: "Total Revenue",
543
555
  value: 125430,
@@ -545,7 +557,7 @@ const Ct = {
545
557
  trend: { value: 12.5, direction: "up" },
546
558
  subtitle: "MTD",
547
559
  isStale: !0
548
- }, Pe = {
560
+ }, Me = {
549
561
  variant: "sparkline",
550
562
  label: "Daily Orders",
551
563
  value: 847,
@@ -568,9 +580,9 @@ const Ct = {
568
580
  }, Dt = [
569
581
  Ie,
570
582
  _e,
583
+ Pe,
571
584
  Re,
572
585
  Me,
573
- Pe,
574
586
  Fe
575
587
  ], wt = {
576
588
  variant: "sparkline",
@@ -666,23 +678,23 @@ function ne({
666
678
  onCreatePage: s,
667
679
  onManagePages: d
668
680
  }) {
669
- const m = f(
670
- (p) => {
671
- o(p), t();
681
+ const u = f(
682
+ (g) => {
683
+ o(g), t();
672
684
  },
673
685
  [o, t]
674
- ), g = f(
675
- (p, l) => {
676
- (l.key === "Enter" || l.key === " ") && (l.preventDefault(), m(p));
686
+ ), p = f(
687
+ (g, l) => {
688
+ (l.key === "Enter" || l.key === " ") && (l.preventDefault(), u(g));
677
689
  },
678
- [m]
679
- ), y = f(() => {
690
+ [u]
691
+ ), b = f(() => {
680
692
  s(), t();
681
693
  }, [s, t]), D = f(() => {
682
694
  d(), t();
683
695
  }, [d, t]);
684
- return /* @__PURE__ */ R(
685
- he,
696
+ return /* @__PURE__ */ P(
697
+ fe,
686
698
  {
687
699
  definition: {
688
700
  placement: "bottom-end",
@@ -695,9 +707,9 @@ function ne({
695
707
  anchorRef: r,
696
708
  className: "gloss-page-dropdown",
697
709
  children: [
698
- /* @__PURE__ */ c("ul", { role: "menu", className: "gloss-page-dropdown__list", children: a.map((p) => {
699
- const l = p.id === n;
700
- return /* @__PURE__ */ R(
710
+ /* @__PURE__ */ c("ul", { role: "menu", className: "gloss-page-dropdown__list", children: a.map((g) => {
711
+ const l = g.id === n;
712
+ return /* @__PURE__ */ P(
701
713
  "li",
702
714
  {
703
715
  role: "menuitemradio",
@@ -705,8 +717,8 @@ function ne({
705
717
  "aria-current": l ? "page" : void 0,
706
718
  tabIndex: 0,
707
719
  className: `gloss-page-dropdown__item${l ? " gloss-page-dropdown__item--active" : ""}`,
708
- onClick: () => m(p.id),
709
- onKeyDown: (b) => g(p.id, b),
720
+ onClick: () => u(g.id),
721
+ onKeyDown: (h) => p(g.id, h),
710
722
  children: [
711
723
  /* @__PURE__ */ c(
712
724
  "span",
@@ -717,14 +729,14 @@ function ne({
717
729
  /* @__PURE__ */ c(
718
730
  "span",
719
731
  {
720
- className: `gloss-page-dropdown__name${p.named ? "" : " gloss-page-dropdown__name--unnamed"}`,
721
- children: p.name
732
+ className: `gloss-page-dropdown__name${g.named ? "" : " gloss-page-dropdown__name--unnamed"}`,
733
+ children: g.name
722
734
  }
723
735
  ),
724
- /* @__PURE__ */ c("span", { className: "gloss-page-dropdown__count", children: p.cardCount })
736
+ /* @__PURE__ */ c("span", { className: "gloss-page-dropdown__count", children: g.cardCount })
725
737
  ]
726
738
  },
727
- p.id
739
+ g.id
728
740
  );
729
741
  }) }),
730
742
  /* @__PURE__ */ c("hr", { className: "gloss-page-dropdown__separator" }),
@@ -733,7 +745,7 @@ function ne({
733
745
  {
734
746
  role: "menuitem",
735
747
  className: "gloss-page-dropdown__action",
736
- onClick: y,
748
+ onClick: b,
737
749
  children: "+ New page"
738
750
  }
739
751
  ),
@@ -761,16 +773,16 @@ const Oe = function({
761
773
  onManagePages: s,
762
774
  maskRadius: d = "var(--gloss-radius-md)"
763
775
  }) {
764
- const m = F(null), [g, y] = M(!1), D = f(() => {
765
- y((b) => !b);
766
- }, []), p = f(() => {
767
- y(!1);
776
+ const u = F(null), [p, b] = R(!1), D = f(() => {
777
+ b((h) => !h);
778
+ }, []), g = f(() => {
779
+ b(!1);
768
780
  }, []), l = a[t]?.id ?? "";
769
- return /* @__PURE__ */ R(
781
+ return /* @__PURE__ */ P(
770
782
  "div",
771
783
  {
772
784
  className: "gloss-page-chip",
773
- ref: m,
785
+ ref: u,
774
786
  style: { position: "absolute", top: 0, right: 0 },
775
787
  "data-page-chip": !0,
776
788
  children: [
@@ -781,12 +793,12 @@ const Oe = function({
781
793
  style: { "--_nuzzle-r": d }
782
794
  }
783
795
  ),
784
- /* @__PURE__ */ R(
796
+ /* @__PURE__ */ P(
785
797
  "button",
786
798
  {
787
799
  className: "gloss-page-chip__trigger",
788
800
  "aria-haspopup": "menu",
789
- "aria-expanded": g,
801
+ "aria-expanded": p,
790
802
  "aria-label": `Page ${t + 1} of ${r}. Click to switch pages.`,
791
803
  onClick: D,
792
804
  children: [
@@ -799,9 +811,9 @@ const Oe = function({
799
811
  /* @__PURE__ */ c(
800
812
  ne,
801
813
  {
802
- open: g,
803
- onDismiss: p,
804
- anchorRef: m,
814
+ open: p,
815
+ onDismiss: g,
816
+ anchorRef: u,
805
817
  pages: a,
806
818
  activePageId: l,
807
819
  onPageChange: n,
@@ -1142,7 +1154,7 @@ const H = I.createElement("span", { style: { color: "var(--color-text-muted)" }
1142
1154
  cellClassName: "gloss-tabular-nums",
1143
1155
  renderCell: ({ row: e }) => e.date ? se(e.date) : ""
1144
1156
  }
1145
- ], Rt = [
1157
+ ], Pt = [
1146
1158
  {
1147
1159
  field: "sku",
1148
1160
  headerName: "Item ID",
@@ -1238,7 +1250,7 @@ const H = I.createElement("span", { style: { color: "var(--color-text-muted)" }
1238
1250
  userType: "sales-agency",
1239
1251
  entityFilterOptions: Ae,
1240
1252
  itemFilterOptions: Ee
1241
- }, Mt = {
1253
+ }, Rt = {
1242
1254
  ...ie,
1243
1255
  vizState: {
1244
1256
  type: "items",
@@ -1247,7 +1259,7 @@ const H = I.createElement("span", { style: { color: "var(--color-text-muted)" }
1247
1259
  byItem: { id: "i-003", name: "Walnut Console Table" },
1248
1260
  timeFrame: "YTD"
1249
1261
  }
1250
- }, Pt = {
1262
+ }, Mt = {
1251
1263
  ...ie,
1252
1264
  vizState: {
1253
1265
  type: "orders",
@@ -1458,7 +1470,7 @@ const H = I.createElement("span", { style: { color: "var(--color-text-muted)" }
1458
1470
  { id: "ytd", label: "YTD" },
1459
1471
  { id: "lytd", label: "LYTD" }
1460
1472
  ];
1461
- function P(e, t) {
1473
+ function M(e, t) {
1462
1474
  return {
1463
1475
  id: e,
1464
1476
  colSpan: 1,
@@ -1480,21 +1492,21 @@ function P(e, t) {
1480
1492
  }
1481
1493
  function te(e, t) {
1482
1494
  return {
1483
- ...P(e, t),
1495
+ ...M(e, t),
1484
1496
  colSpan: 2
1485
1497
  };
1486
1498
  }
1487
1499
  const zt = [
1488
- P("total-revenue", "Total Revenue"),
1489
- P("total-orders", "Total Orders"),
1500
+ M("total-revenue", "Total Revenue"),
1501
+ M("total-orders", "Total Orders"),
1490
1502
  te("revenue-trend", "Revenue Trend (2x)"),
1491
- P("avg-order", "Avg Order Value"),
1492
- P("new-customers", "New Customers"),
1493
- P("top-salesperson", "Top Salesperson"),
1503
+ M("avg-order", "Avg Order Value"),
1504
+ M("new-customers", "New Customers"),
1505
+ M("top-salesperson", "Top Salesperson"),
1494
1506
  te("order-trend", "Order Trend (2x)"),
1495
- P("repeat-rate", "Repeat Rate"),
1496
- P("open-orders", "Open Orders"),
1497
- P("shipped-orders", "Shipped Orders")
1507
+ M("repeat-rate", "Repeat Rate"),
1508
+ M("open-orders", "Open Orders"),
1509
+ M("shipped-orders", "Shipped Orders")
1498
1510
  ], Kt = {
1499
1511
  columns: 6,
1500
1512
  rowHeight: 120,
@@ -1633,7 +1645,7 @@ const ze = function(t) {
1633
1645
  }
1634
1646
  );
1635
1647
  const { cards: r, composite: a } = t;
1636
- return /* @__PURE__ */ R(
1648
+ return /* @__PURE__ */ P(
1637
1649
  "div",
1638
1650
  {
1639
1651
  className: "gloss-metric-group gloss-metric-group--composite",
@@ -1659,7 +1671,7 @@ const ze = function(t) {
1659
1671
  style: { background: a.accentColor }
1660
1672
  }
1661
1673
  ),
1662
- a?.label && /* @__PURE__ */ R("div", { className: "gloss-metric-group__label", children: [
1674
+ a?.label && /* @__PURE__ */ P("div", { className: "gloss-metric-group__label", children: [
1663
1675
  /* @__PURE__ */ c("span", { children: a.label }),
1664
1676
  a?.trend && /* @__PURE__ */ c(
1665
1677
  "span",
@@ -1725,27 +1737,27 @@ function Ke({
1725
1737
  "[InlineNudge] requires anchorEl or anchorSelector. AP-07: Do not mount InlineNudge in Layout/** or _app.tsx."
1726
1738
  );
1727
1739
  }, [a, n]), I.useLayoutEffect(() => {
1728
- let g = null;
1729
- if (a ? g = a : n && (g = document.querySelector(n)), g) {
1730
- const y = g.getBoundingClientRect();
1740
+ let p = null;
1741
+ if (a ? p = a : n && (p = document.querySelector(n)), p) {
1742
+ const b = p.getBoundingClientRect();
1731
1743
  s({
1732
- top: y.bottom + window.scrollY + 6,
1733
- left: y.left + window.scrollX
1744
+ top: b.bottom + window.scrollY + 6,
1745
+ left: b.left + window.scrollX
1734
1746
  });
1735
1747
  }
1736
1748
  }, [a, n]);
1737
- const m = o ? { top: o.top, left: o.left } : {};
1738
- return /* @__PURE__ */ R(
1749
+ const u = o ? { top: o.top, left: o.left } : {};
1750
+ return /* @__PURE__ */ P(
1739
1751
  "div",
1740
1752
  {
1741
1753
  className: L["gloss-inline-nudge"],
1742
- style: m,
1754
+ style: u,
1743
1755
  role: "status",
1744
1756
  "aria-live": "polite",
1745
1757
  "data-reduced-motion": d ? "true" : void 0,
1746
1758
  children: [
1747
1759
  /* @__PURE__ */ c("span", { className: L["gloss-inline-nudge__message"], children: e }),
1748
- /* @__PURE__ */ R("div", { className: L["gloss-inline-nudge__actions"], children: [
1760
+ /* @__PURE__ */ P("div", { className: L["gloss-inline-nudge__actions"], children: [
1749
1761
  /* @__PURE__ */ c(
1750
1762
  "button",
1751
1763
  {
@@ -1788,39 +1800,39 @@ function Ze({
1788
1800
  max: a = 100,
1789
1801
  disabled: n = !1
1790
1802
  }) {
1791
- const o = F(null), [s, d] = M(null), [m, g] = M(e), y = F(e);
1792
- y.current !== e && (y.current = e, g(e));
1793
- const D = pe(() => We(m, r, a), [m, r, a]), p = f(
1803
+ const o = F(null), [s, d] = R(null), [u, p] = R(e), b = F(e);
1804
+ b.current !== e && (b.current = e, p(e));
1805
+ const D = ge(() => We(u, r, a), [u, r, a]), g = f(
1794
1806
  (i) => {
1795
1807
  if (!o.current) return r;
1796
- const h = o.current.getBoundingClientRect(), N = Math.max(0, Math.min(1, (i - h.left) / h.width)), C = r + N * (a - r);
1797
- return Math.round(C * 100) / 100;
1808
+ const v = o.current.getBoundingClientRect(), N = Math.max(0, Math.min(1, (i - v.left) / v.width)), y = r + N * (a - r);
1809
+ return Math.round(y * 100) / 100;
1798
1810
  },
1799
1811
  [r, a]
1800
1812
  ), l = f(
1801
- (i, h) => {
1802
- const N = m.find((C) => C.id === h);
1803
- n || N?.disabled || (typeof i.currentTarget.setPointerCapture == "function" && i.currentTarget.setPointerCapture(i.pointerId), d(h));
1813
+ (i, v) => {
1814
+ const N = u.find((y) => y.id === v);
1815
+ n || N?.disabled || (typeof i.currentTarget.setPointerCapture == "function" && i.currentTarget.setPointerCapture(i.pointerId), d(v));
1804
1816
  },
1805
- [n, m]
1806
- ), b = f(
1817
+ [n, u]
1818
+ ), h = f(
1807
1819
  (i) => {
1808
1820
  if (!s) return;
1809
- const h = p(i.clientX);
1810
- g(
1811
- (N) => N.map((C) => C.id === s ? { ...C, value: h } : C)
1821
+ const v = g(i.clientX);
1822
+ p(
1823
+ (N) => N.map((y) => y.id === s ? { ...y, value: v } : y)
1812
1824
  );
1813
1825
  },
1814
- [s, p]
1826
+ [s, g]
1815
1827
  ), S = f(
1816
1828
  (i) => {
1817
1829
  if (!s) return;
1818
- const h = p(i.clientX), N = m.map(
1819
- (C) => C.id === s ? { ...C, value: h } : C
1830
+ const v = g(i.clientX), N = u.map(
1831
+ (y) => y.id === s ? { ...y, value: v } : y
1820
1832
  );
1821
- g(N), d(null), t(N);
1833
+ p(N), d(null), t(N);
1822
1834
  },
1823
- [s, p, m, t]
1835
+ [s, g, u, t]
1824
1836
  ), T = a - r || 1;
1825
1837
  return /* @__PURE__ */ c("div", { className: "gloss-threshold-ramp", "data-disabled": n || void 0, children: /* @__PURE__ */ c(
1826
1838
  "div",
@@ -1828,17 +1840,17 @@ function Ze({
1828
1840
  ref: o,
1829
1841
  className: "gloss-threshold-ramp__track",
1830
1842
  style: { background: D },
1831
- onPointerMove: b,
1843
+ onPointerMove: h,
1832
1844
  onPointerUp: S,
1833
1845
  onPointerLeave: S,
1834
- children: m.map((i) => {
1835
- const h = (i.value - r) / T * 100;
1846
+ children: u.map((i) => {
1847
+ const v = (i.value - r) / T * 100;
1836
1848
  return /* @__PURE__ */ c(
1837
1849
  "span",
1838
1850
  {
1839
1851
  className: "gloss-threshold-ramp__stop",
1840
1852
  style: {
1841
- left: `${h}%`,
1853
+ left: `${v}%`,
1842
1854
  color: le(i)
1843
1855
  },
1844
1856
  "data-disabled": i.disabled || void 0,
@@ -1860,7 +1872,7 @@ function Ze({
1860
1872
  Ze.displayName = "ThresholdRamp";
1861
1873
  const de = be(null);
1862
1874
  function Ye() {
1863
- return fe(de);
1875
+ return he(de);
1864
1876
  }
1865
1877
  function qe({ option: e }) {
1866
1878
  const t = Ye(), r = t?.isSelected(e.value) ?? !1, a = e.disabled || t?.groupDisabled, n = f(() => {
@@ -1891,22 +1903,22 @@ function Ve({
1891
1903
  disabled: n = !1,
1892
1904
  name: o
1893
1905
  }) {
1894
- const s = t !== void 0, [d, m] = M(r), g = s ? t : d, y = f(
1906
+ const s = t !== void 0, [d, u] = R(r), p = s ? t : d, b = f(
1895
1907
  (l) => {
1896
- s || m(l), a?.(l);
1908
+ s || u(l), a?.(l);
1897
1909
  },
1898
1910
  [s, a]
1899
1911
  ), D = f(
1900
- (l) => g === l,
1901
- [g]
1902
- ), p = {
1903
- selectedValue: g,
1904
- select: y,
1912
+ (l) => p === l,
1913
+ [p]
1914
+ ), g = {
1915
+ selectedValue: p,
1916
+ select: b,
1905
1917
  isSelected: D,
1906
1918
  groupDisabled: n,
1907
1919
  name: o
1908
1920
  };
1909
- return /* @__PURE__ */ c(de.Provider, { value: p, children: /* @__PURE__ */ c(
1921
+ return /* @__PURE__ */ c(de.Provider, { value: g, children: /* @__PURE__ */ c(
1910
1922
  "div",
1911
1923
  {
1912
1924
  className: "gloss-preset-swatch-row",
@@ -1934,82 +1946,82 @@ function Ue(e, t, r) {
1934
1946
  return a.splice(r, 0, n), a;
1935
1947
  }
1936
1948
  function je(e) {
1937
- const [t, r] = M(() => e.zones), [a, n] = M(null), [o, s] = M(null), d = F(null), m = F(e.onZoneChange);
1938
- m.current = e.onZoneChange;
1939
- const g = f(
1940
- (b) => {
1941
- const S = b.active.id;
1949
+ const [t, r] = R(() => e.zones), [a, n] = R(null), [o, s] = R(null), d = F(null), u = F(e.onZoneChange);
1950
+ u.current = e.onZoneChange;
1951
+ const p = f(
1952
+ (h) => {
1953
+ const S = h.active.id;
1942
1954
  let T = null, i = null;
1943
- for (const h of t) {
1944
- const N = h.items.find((C) => C.id === S);
1955
+ for (const v of t) {
1956
+ const N = v.items.find((y) => y.id === S);
1945
1957
  if (N) {
1946
- T = N, i = h.zoneKey;
1958
+ T = N, i = v.zoneKey;
1947
1959
  break;
1948
1960
  }
1949
1961
  }
1950
1962
  d.current = i, n(T), s(i);
1951
1963
  },
1952
1964
  [t]
1953
- ), y = f(
1954
- (b) => {
1955
- if (!b.over) {
1965
+ ), b = f(
1966
+ (h) => {
1967
+ if (!h.over) {
1956
1968
  s(d.current);
1957
1969
  return;
1958
1970
  }
1959
- const S = ae(t, b.over.id);
1971
+ const S = ae(t, h.over.id);
1960
1972
  s(S);
1961
1973
  },
1962
1974
  [t]
1963
1975
  ), D = f(
1964
- (b) => {
1965
- const { active: S, over: T } = b, i = () => {
1976
+ (h) => {
1977
+ const { active: S, over: T } = h, i = () => {
1966
1978
  d.current = null, n(null), s(null);
1967
1979
  };
1968
1980
  if (!T) {
1969
1981
  i();
1970
1982
  return;
1971
1983
  }
1972
- const h = U(t, S.id), N = ae(t, T.id);
1973
- if (!h || !N) {
1984
+ const v = U(t, S.id), N = ae(t, T.id);
1985
+ if (!v || !N) {
1974
1986
  i();
1975
1987
  return;
1976
1988
  }
1977
- let C = t.map((x) => ({ ...x, items: [...x.items] }));
1978
- if (h === N) {
1979
- const x = C.findIndex((k) => k.zoneKey === h), u = C[x], w = u.items.findIndex((k) => k.id === S.id), v = u.items.findIndex((k) => k.id === T.id), O = v >= 0 ? v : u.items.length - 1;
1980
- C[x] = {
1981
- ...u,
1982
- items: Ue(u.items, w, O)
1989
+ let y = t.map((x) => ({ ...x, items: [...x.items] }));
1990
+ if (v === N) {
1991
+ const x = y.findIndex((k) => k.zoneKey === v), m = y[x], w = m.items.findIndex((k) => k.id === S.id), C = m.items.findIndex((k) => k.id === T.id), O = C >= 0 ? C : m.items.length - 1;
1992
+ y[x] = {
1993
+ ...m,
1994
+ items: Ue(m.items, w, O)
1983
1995
  };
1984
1996
  } else {
1985
- const x = C.findIndex((_) => _.zoneKey === h), u = C.findIndex((_) => _.zoneKey === N), w = C[x], v = C[u], O = w.items.find((_) => _.id === S.id), k = w.items.filter((_) => _.id !== S.id), E = v.items.findIndex((_) => _.id === T.id), G = E >= 0 ? E : v.items.length;
1986
- let Q = k, A = [...v.items];
1987
- if (v.maxItems !== void 0 && A.length >= v.maxItems) {
1997
+ const x = y.findIndex((_) => _.zoneKey === v), m = y.findIndex((_) => _.zoneKey === N), w = y[x], C = y[m], O = w.items.find((_) => _.id === S.id), k = w.items.filter((_) => _.id !== S.id), E = C.items.findIndex((_) => _.id === T.id), G = E >= 0 ? E : C.items.length;
1998
+ let Q = k, A = [...C.items];
1999
+ if (C.maxItems !== void 0 && A.length >= C.maxItems) {
1988
2000
  const _ = A[A.length - 1];
1989
- A = A.slice(0, v.maxItems - 1), Q = [...k, _];
2001
+ A = A.slice(0, C.maxItems - 1), Q = [...k, _];
1990
2002
  }
1991
2003
  const X = Math.min(G, A.length), me = [
1992
2004
  ...A.slice(0, X),
1993
2005
  O,
1994
2006
  ...A.slice(X)
1995
2007
  ];
1996
- C[x] = { ...w, items: Q }, C[u] = { ...v, items: me };
2008
+ y[x] = { ...w, items: Q }, y[m] = { ...C, items: me };
1997
2009
  }
1998
- r(C), m.current?.(C), i();
2010
+ r(y), u.current?.(y), i();
1999
2011
  },
2000
2012
  [t]
2001
- ), p = f(
2002
- (b) => ({
2003
- id: b,
2004
- "data-zone-key": b
2013
+ ), g = f(
2014
+ (h) => ({
2015
+ id: h,
2016
+ "data-zone-key": h
2005
2017
  }),
2006
2018
  []
2007
2019
  ), l = f(
2008
- (b) => {
2009
- const S = U(t, b.id) ?? "";
2020
+ (h) => {
2021
+ const S = U(t, h.id) ?? "";
2010
2022
  return {
2011
- id: b.id,
2012
- "data-item-id": b.id,
2023
+ id: h.id,
2024
+ "data-item-id": h.id,
2013
2025
  "data-zone-key": S
2014
2026
  };
2015
2027
  },
@@ -2019,10 +2031,10 @@ function je(e) {
2019
2031
  zones: t,
2020
2032
  activeZone: o,
2021
2033
  activeItem: a,
2022
- getZoneProps: p,
2034
+ getZoneProps: g,
2023
2035
  getItemProps: l,
2024
- handleDragStart: g,
2025
- handleDragOver: y,
2036
+ handleDragStart: p,
2037
+ handleDragOver: b,
2026
2038
  handleDragEnd: D
2027
2039
  };
2028
2040
  }
@@ -2046,14 +2058,14 @@ function Qe() {
2046
2058
  })(), z);
2047
2059
  }
2048
2060
  function Xe(e) {
2049
- const { zones: t, onZoneChange: r, renderZone: a, renderItem: n, renderDragOverlay: o } = e, s = je({ zones: t, onZoneChange: r }), [d, m] = I.useState($);
2061
+ const { zones: t, onZoneChange: r, renderZone: a, renderItem: n, renderDragOverlay: o } = e, s = je({ zones: t, onZoneChange: r }), [d, u] = I.useState($);
2050
2062
  return I.useEffect(() => {
2051
2063
  if (d) return;
2052
- let g = !0;
2053
- return Qe().then((y) => {
2054
- g && m(y);
2064
+ let p = !0;
2065
+ return Qe().then((b) => {
2066
+ p && u(b);
2055
2067
  }), () => {
2056
- g = !1;
2068
+ p = !1;
2057
2069
  };
2058
2070
  }, [d]), d ? /* @__PURE__ */ c(
2059
2071
  ce,
@@ -2064,9 +2076,9 @@ function Xe(e) {
2064
2076
  renderItem: n,
2065
2077
  renderDragOverlay: o
2066
2078
  }
2067
- ) : /* @__PURE__ */ c("div", { "data-sortable-zones-passive": "true", children: s.zones.map((g) => {
2068
- const y = g.items.map((D) => /* @__PURE__ */ c(I.Fragment, { children: n(D) }, D.id));
2069
- return /* @__PURE__ */ c("div", { ...s.getZoneProps(g.zoneKey), children: a(g.zoneKey, g.items, y) }, g.zoneKey);
2079
+ ) : /* @__PURE__ */ c("div", { "data-sortable-zones-passive": "true", children: s.zones.map((p) => {
2080
+ const b = p.items.map((D) => /* @__PURE__ */ c(I.Fragment, { children: n(D) }, D.id));
2081
+ return /* @__PURE__ */ c("div", { ...s.getZoneProps(p.zoneKey), children: a(p.zoneKey, p.items, b) }, p.zoneKey);
2070
2082
  }) });
2071
2083
  }
2072
2084
  Xe.displayName = "SortableZones";
@@ -2077,31 +2089,31 @@ function ce({
2077
2089
  renderItem: a,
2078
2090
  renderDragOverlay: n
2079
2091
  }) {
2080
- const { core: o, sortable: s, utilities: d } = t, { DndContext: m, DragOverlay: g, useSensors: y, useSensor: D, PointerSensor: p, KeyboardSensor: l, closestCenter: b } = o, { SortableContext: S, verticalListSortingStrategy: T } = s, i = y(
2081
- D(p, { activationConstraint: { distance: 5 } }),
2092
+ const { core: o, sortable: s, utilities: d } = t, { DndContext: u, DragOverlay: p, useSensors: b, useSensor: D, PointerSensor: g, KeyboardSensor: l, closestCenter: h } = o, { SortableContext: S, verticalListSortingStrategy: T } = s, i = b(
2093
+ D(g, { activationConstraint: { distance: 5 } }),
2082
2094
  D(l)
2083
- ), h = m, N = g, C = S;
2084
- return /* @__PURE__ */ R(
2085
- h,
2095
+ ), v = u, N = p, y = S;
2096
+ return /* @__PURE__ */ P(
2097
+ v,
2086
2098
  {
2087
2099
  sensors: i,
2088
- collisionDetection: b,
2100
+ collisionDetection: h,
2089
2101
  onDragStart: e.handleDragStart,
2090
2102
  onDragOver: e.handleDragOver,
2091
2103
  onDragEnd: e.handleDragEnd,
2092
2104
  children: [
2093
2105
  e.zones.map((x) => {
2094
- const u = x.items.map((v) => v.id), w = x.items.map((v) => /* @__PURE__ */ c(
2106
+ const m = x.items.map((C) => C.id), w = x.items.map((C) => /* @__PURE__ */ c(
2095
2107
  ue,
2096
2108
  {
2097
- id: v.id,
2109
+ id: C.id,
2098
2110
  useSortable: s.useSortable,
2099
2111
  cssHelper: d.CSS,
2100
- children: a(v)
2112
+ children: a(C)
2101
2113
  },
2102
- v.id
2114
+ C.id
2103
2115
  ));
2104
- return /* @__PURE__ */ c("div", { ...e.getZoneProps(x.zoneKey), children: /* @__PURE__ */ c(C, { items: u, strategy: T, children: r(x.zoneKey, x.items, w) }) }, x.zoneKey);
2116
+ return /* @__PURE__ */ c("div", { ...e.getZoneProps(x.zoneKey), children: /* @__PURE__ */ c(y, { items: m, strategy: T, children: r(x.zoneKey, x.items, w) }) }, x.zoneKey);
2105
2117
  }),
2106
2118
  /* @__PURE__ */ c(N, { children: e.activeItem ? n?.(e.activeItem) ?? a(e.activeItem) : null })
2107
2119
  ]
@@ -2110,12 +2122,12 @@ function ce({
2110
2122
  }
2111
2123
  ce.displayName = "SortableZonesInner";
2112
2124
  function ue({ id: e, useSortable: t, cssHelper: r, children: a }) {
2113
- const { attributes: n, listeners: o, setNodeRef: s, transform: d, transition: m, isDragging: g } = t({ id: e }), y = {
2125
+ const { attributes: n, listeners: o, setNodeRef: s, transform: d, transition: u, isDragging: p } = t({ id: e }), b = {
2114
2126
  transform: r?.Transform?.toString(d) ?? void 0,
2115
- transition: m,
2116
- opacity: g ? 0.5 : 1
2127
+ transition: u,
2128
+ opacity: p ? 0.5 : 1
2117
2129
  };
2118
- return /* @__PURE__ */ c("div", { ref: s, style: y, "data-sortable-item-id": e, ...n, ...o, children: a });
2130
+ return /* @__PURE__ */ c("div", { ref: s, style: b, "data-sortable-item-id": e, ...n, ...o, children: a });
2119
2131
  }
2120
2132
  ue.displayName = "SortableItem";
2121
2133
  const Je = I.forwardRef(({ density: e = "compact", children: t, ...r }, a) => {
@@ -2125,7 +2137,7 @@ const Je = I.forwardRef(({ density: e = "compact", children: t, ...r }, a) => {
2125
2137
  Je.displayName = "ContainerToolbar";
2126
2138
  const et = I.forwardRef(({ legend: e, description: t, density: r = "default", children: a, ...n }, o) => {
2127
2139
  const s = { ...n };
2128
- return delete s.className, delete s.style, /* @__PURE__ */ R("fieldset", { ref: o, className: "gloss-container-form-section", ...s, children: [
2140
+ return delete s.className, delete s.style, /* @__PURE__ */ P("fieldset", { ref: o, className: "gloss-container-form-section", ...s, children: [
2129
2141
  e && /* @__PURE__ */ c("legend", { className: "gloss-container-form-section__legend", children: e }),
2130
2142
  t && /* @__PURE__ */ c("p", { className: "gloss-container-form-section__description", children: t }),
2131
2143
  /* @__PURE__ */ c(j, { region: "form-section", density: r, children: a })
@@ -2153,11 +2165,11 @@ export {
2153
2165
  ca as Button,
2154
2166
  ua as ButtonGroup,
2155
2167
  ma as ButtonGroupContext,
2156
- ga as Card,
2157
- pa as CardActions,
2168
+ pa as Card,
2169
+ ga as CardActions,
2158
2170
  ba as CardBack,
2159
- fa as CardBody,
2160
- ha as CardFooter,
2171
+ ha as CardBody,
2172
+ fa as CardFooter,
2161
2173
  va as CardHeader,
2162
2174
  Ca as CardMedia,
2163
2175
  ya as CardShell,
@@ -2170,9 +2182,9 @@ export {
2170
2182
  ka as ColorPicker,
2171
2183
  Ia as ComparisonCard,
2172
2184
  _a as ContactForm,
2173
- Ra as ContainerCard,
2174
- Ma as ContainerCardActions,
2175
- Pa as ContainerCardBody,
2185
+ Pa as ContainerCard,
2186
+ Ra as ContainerCardActions,
2187
+ Ma as ContainerCardBody,
2176
2188
  Fa as ContainerCardFooter,
2177
2189
  Oa as ContainerCardHeader,
2178
2190
  Aa as ContainerCardMedia,
@@ -2187,7 +2199,7 @@ export {
2187
2199
  tt as ContainerTable,
2188
2200
  Je as ContainerToolbar,
2189
2201
  Ka as CreditCardForm,
2190
- ho as DEFAULT_MARKET_PRESETS,
2202
+ fo as DEFAULT_MARKET_PRESETS,
2191
2203
  vo as DEFAULT_PINNED,
2192
2204
  Wa as DataTable,
2193
2205
  Za as DatePicker,
@@ -2214,12 +2226,12 @@ export {
2214
2226
  cr as Form,
2215
2227
  ur as FormDialog,
2216
2228
  mr as FormField,
2217
- gr as FusedShape,
2229
+ pr as FusedShape,
2218
2230
  ke as GhostPreview,
2219
- pr as GroupCheckbox,
2231
+ gr as GroupCheckbox,
2220
2232
  br as GroupRadio,
2221
- fr as GutterActions,
2222
- hr as HighlightCard,
2233
+ hr as GutterActions,
2234
+ fr as HighlightCard,
2223
2235
  vr as HybridDatePicker,
2224
2236
  Cr as ImportWizard,
2225
2237
  Ke as InlineNudge,
@@ -2233,9 +2245,9 @@ export {
2233
2245
  kr as MaskedInput,
2234
2246
  Ir as Menu,
2235
2247
  _r as MenuDivider,
2236
- Rr as MenuGroup,
2237
- Mr as MenuItem,
2238
- Pr as MergePrompt,
2248
+ Pr as MenuGroup,
2249
+ Rr as MenuItem,
2250
+ Mr as MergePrompt,
2239
2251
  Fr as MetricCard,
2240
2252
  Or as MetricCardGrid,
2241
2253
  ze as MetricGroupContainer,
@@ -2275,12 +2287,12 @@ export {
2275
2287
  cn as SkeletonCard,
2276
2288
  un as SkeletonChart,
2277
2289
  mn as SkeletonTable,
2278
- gn as Slider,
2279
- pn as Sortable,
2290
+ pn as Slider,
2291
+ gn as Sortable,
2280
2292
  Xe as SortableZones,
2281
2293
  bn as SparklineBg,
2282
- fn as SplitButton,
2283
- hn as StackedGroupCard,
2294
+ hn as SplitButton,
2295
+ fn as StackedGroupCard,
2284
2296
  vn as StatusModeCard,
2285
2297
  Te as StatusSlotChipMenu,
2286
2298
  Cn as Stepper,
@@ -2296,11 +2308,11 @@ export {
2296
2308
  kn as Tooltip,
2297
2309
  In as Transition,
2298
2310
  _n as TransitionGroup,
2299
- Rn as TrendCard,
2300
- Mn as TrendIndicator,
2301
- po as UIContext,
2311
+ Pn as TrendCard,
2312
+ Rn as TrendIndicator,
2313
+ go as UIContext,
2302
2314
  j as UIContextProvider,
2303
- Pn as UnifiedBreakdownTable,
2315
+ Mn as UnifiedBreakdownTable,
2304
2316
  Fn as UnifiedContextMenu,
2305
2317
  On as addressGroupMetadata,
2306
2318
  An as addressSchema,
@@ -2308,11 +2320,11 @@ export {
2308
2320
  Dt as allStateFixtures,
2309
2321
  yt as allVariantFixtures,
2310
2322
  mt as blockSamples,
2311
- ht as cardSamples,
2323
+ ft as cardSamples,
2312
2324
  bt as chartSamples,
2313
- pt as circleSamples,
2325
+ gt as circleSamples,
2314
2326
  Kt as compactLayout,
2315
- Pt as compactState,
2327
+ Mt as compactState,
2316
2328
  En as contactFormMetadata,
2317
2329
  Ln as contactSchema,
2318
2330
  Ft as contextMenuFixtures,
@@ -2323,12 +2335,12 @@ export {
2323
2335
  $n as destructiveModalMetadata,
2324
2336
  Hn as durations,
2325
2337
  zn as easings,
2326
- Re as emptyFixture,
2338
+ Pe as emptyFixture,
2327
2339
  Ce as entityChip,
2328
2340
  Be as entityNameActions,
2329
2341
  ct as entityTabGroup,
2330
2342
  _e as errorFixture,
2331
- Mt as filteredState,
2343
+ Rt as filteredState,
2332
2344
  wo as findPreset,
2333
2345
  No as formatDateRange,
2334
2346
  So as formatMarketDates,
@@ -2340,14 +2352,14 @@ export {
2340
2352
  Io as getAllPresets,
2341
2353
  _o as getDateRangeForPreset,
2342
2354
  Wn as getMenuActions,
2343
- Ro as getPresetLabel,
2355
+ Po as getPresetLabel,
2344
2356
  Zn as getTransitionStyle,
2345
2357
  zt as gridCards,
2346
2358
  Yn as interpolate,
2347
- Mo as isInRange,
2348
- Po as isMarketActive,
2359
+ Ro as isInRange,
2360
+ Mo as isMarketActive,
2349
2361
  Fo as isSameDay,
2350
- Rt as itemColumns,
2362
+ Pt as itemColumns,
2351
2363
  It as itemRows,
2352
2364
  Ie as loadingFixture,
2353
2365
  qn as loginFormMetadata,
@@ -2382,15 +2394,15 @@ export {
2382
2394
  wt as sparklineFixture,
2383
2395
  Nt as sparklineUpFixture,
2384
2396
  Fe as staleDonutFixture,
2385
- Me as staleFixture,
2386
- Pe as staleSparklineFixture,
2397
+ Re as staleFixture,
2398
+ Me as staleSparklineFixture,
2387
2399
  St as standardFixture,
2388
2400
  xt as standardFlatFixture,
2389
2401
  Wt as standardLayout,
2390
2402
  Tt as standardNegativeFixture,
2391
2403
  ye as statusChip,
2392
- ft as tableSamples,
2393
- gt as textSamples,
2404
+ ht as tableSamples,
2405
+ pt as textSamples,
2394
2406
  ut as timeFrameTabGroup,
2395
2407
  Ao as toUppercasePresetId,
2396
2408
  it as useArrowNavigation,
@@ -16,5 +16,14 @@ export interface EdgeHoverHandleProps {
16
16
  *
17
17
  * Motion contract (AN-06): opacity transitions driven by edge-hover.scss
18
18
  * using enterMs=180ms (enter) / exitMs=120ms (exit via ghost-preview).
19
+ *
20
+ * Pointer capture (debug 260417-qt00z / D-02+D-03 root cause): the handle is
21
+ * only 10px wide. On pointerdown we call setPointerCapture(pointerId) so all
22
+ * subsequent pointermove/pointerup events route to this element even after
23
+ * the cursor leaves the handle's hit region. Without this, dragging rightward
24
+ * (the natural grow gesture) moves the pointer off the handle within the
25
+ * first few px — pointerup then fires on whatever is underneath, the handle's
26
+ * React onPointerUp never runs, and the state machine stays stuck at
27
+ * 'dragging' (so onResize is never called and the card never commits).
19
28
  */
20
29
  export declare const EdgeHoverHandle: import('react').ForwardRefExoticComponent<EdgeHoverHandleProps & import('react').RefAttributes<HTMLButtonElement>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mt-gloss/ui",
3
- "version": "0.0.16",
3
+ "version": "0.0.17",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "restricted"