@mechane-ai/elements 0.68.0 → 0.69.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/dist/ai.js +1 -1
  2. package/dist/{article-Ni152e-v.js → article-CTSxWe4y.js} +1 -1
  3. package/dist/article.js +1 -1
  4. package/dist/catalog.json +67 -7
  5. package/dist/{categorical-values-6Iz03F1i.js → categorical-values-DwomVcSd.js} +1 -1
  6. package/dist/charts/cartesian.js +1 -1
  7. package/dist/charts/comparison.js +1 -1
  8. package/dist/charts/distribution.js +1 -1
  9. package/dist/charts/figure.js +12 -12
  10. package/dist/charts/graph.js +1 -1
  11. package/dist/charts/hierarchy.js +1 -1
  12. package/dist/charts/image.js +1 -1
  13. package/dist/charts/matrix.js +1 -1
  14. package/dist/charts/plot.js +6 -6
  15. package/dist/charts/relationship.js +1 -1
  16. package/dist/charts/text.js +1 -1
  17. package/dist/charts/timeline.js +2 -2
  18. package/dist/charts/trend.js +1 -1
  19. package/dist/charts.js +2 -2
  20. package/dist/content.js +1 -1
  21. package/dist/{dumbbell-plot-jaQvOctJ.js → dumbbell-plot-S4RyfxmW.js} +4 -4
  22. package/dist/{embedding-map-DnZL1kvY.js → embedding-map-Bm7aTA6z.js} +3 -3
  23. package/dist/{figure-frame-96zFqsWz.js → figure-frame-BHCNceS4.js} +1 -1
  24. package/dist/{image-grid-B6fdmE9c.js → image-grid-TTrLxvaI.js} +2 -2
  25. package/dist/kits/evaluation.js +3 -3
  26. package/dist/kits/interpretability.js +6 -6
  27. package/dist/kits/operations.js +3 -3
  28. package/dist/kits/research.js +801 -356
  29. package/dist/kits/training.js +2 -2
  30. package/dist/locate-Dcq5ZZSk.js +14 -0
  31. package/dist/mdx.js +2 -2
  32. package/dist/packages/charts/src/plot/index.d.ts +1 -0
  33. package/dist/packages/charts/src/plot/locate.d.ts +3 -1
  34. package/dist/packages/charts/src/plot/spatial-layer.d.ts +5 -1
  35. package/dist/packages/charts/src/plot/step-history.d.ts +13 -0
  36. package/dist/packages/content/src/timeline-scrubber.d.ts +3 -1
  37. package/dist/packages/kits/src/research/index.d.ts +8 -1
  38. package/dist/packages/kits/src/research/motion-clip.d.ts +1 -39
  39. package/dist/packages/kits/src/research/motion-figure.d.ts +4 -1
  40. package/dist/packages/kits/src/research/motion-frame.d.ts +3 -3
  41. package/dist/packages/kits/src/research/motion-inspection.d.ts +14 -0
  42. package/dist/packages/kits/src/research/motion-location.d.ts +9 -0
  43. package/dist/packages/kits/src/research/motion-scene.d.ts +9 -2
  44. package/dist/packages/kits/src/research/motion-types.d.ts +54 -0
  45. package/dist/packages/kits/src/research/motion-view.d.ts +9 -0
  46. package/dist/packages/kits/src/research/native-motion-figure.d.ts +17 -0
  47. package/dist/packages/kits/src/research/native-motion.d.ts +18 -0
  48. package/dist/plot-BIYlgY2B.js +223 -0
  49. package/dist/{plot-layout-1MG72ZWn.js → plot-layout-CNNFMC8H.js} +1 -1
  50. package/dist/{plot-surface-8-FZI94y.js → plot-surface-BSjoNIva.js} +1 -1
  51. package/dist/{reference-lines-C18o1yEY.js → reference-lines-Bet_hRyA.js} +1 -1
  52. package/dist/{scene-B8dppj5V.js → scene-C88Xkz4l.js} +4 -4
  53. package/dist/scene.js +1 -1
  54. package/dist/{slope-chart-CELflRJd.js → slope-chart-B6Mtcta2.js} +5 -5
  55. package/dist/{src-BsqbWDxS.js → src-DCozYUGI.js} +146 -131
  56. package/dist/styles2.css +4 -4
  57. package/dist/{time-series-DtAtGoT_.js → time-series-DJk-2Mt0.js} +6 -6
  58. package/dist/{timeline-CzianQir.js → timeline-BHpj7i7K.js} +3 -3
  59. package/dist/{token-heatmap-m6oaMwkK.js → token-heatmap-DEqEaoGE.js} +2 -2
  60. package/dist/{token-predictions-CpGVjOIs.js → token-predictions-Bjdh0K-A.js} +4 -4
  61. package/dist/{tree-diagram-D9ekymCQ.js → tree-diagram-BxSDOBFj.js} +3 -3
  62. package/dist/{treemap-DT8q65LQ.js → treemap-DzHAp4ia.js} +4 -4
  63. package/dist/{violin-plot-83HSjnQM.js → violin-plot-B4Cf38Y9.js} +4 -4
  64. package/dist/{waterfall-DmApvdrY.js → waterfall-C9_pHZzv.js} +3 -3
  65. package/package.json +1 -1
  66. package/skills/review-elements/SKILL.md +3 -1
  67. package/skills/use-elements/references/kits.md +10 -0
  68. package/dist/locate-Bcg3QcP4.js +0 -11
  69. package/dist/plot-CpTwLIYN.js +0 -101
@@ -1,20 +1,20 @@
1
1
  import { t as e } from "./accessibility-P89UG9-r.js";
2
- import { A as t, E as n, M as r, S as i, a, j as o, l as s, n as c, o as l, s as u, t as d } from "./plot-layout-1MG72ZWn.js";
2
+ import { A as t, E as n, M as r, S as i, a, j as o, l as s, n as c, o as l, s as u, t as d } from "./plot-layout-CNNFMC8H.js";
3
3
  import { i as f, r as p } from "./chart-link-AE_xuxiP.js";
4
4
  import { a as m } from "./tone-scope-DKiSw-JR.js";
5
5
  import { r as h, t as g } from "./figure-format-BVb7yFCA.js";
6
6
  import { a as _, o as v, r as y } from "./scale-C2xgZyZN.js";
7
7
  import { t as b } from "./chart-cursor-1mFd48Jc.js";
8
- import { c as x, i as ee, l as S, n as C, o as w, r as te, t as T } from "./figure-frame-96zFqsWz.js";
8
+ import { c as x, i as ee, l as S, n as C, o as w, r as te, t as T } from "./figure-frame-BHCNceS4.js";
9
9
  import { n as E } from "./plot-width-D3hTycYX.js";
10
10
  import { t as D } from "./plot-axes-D5S9BnBa.js";
11
11
  import { a as O, c as k, l as A, n as ne, o as re } from "./plot-marks-DgCtcd3L.js";
12
- import { n as ie, r as ae, t as oe } from "./plot-surface-8-FZI94y.js";
12
+ import { n as ie, r as ae, t as oe } from "./plot-surface-BSjoNIva.js";
13
13
  import { t as j } from "./label-spacing-BncjePGb.js";
14
14
  import { n as se, t as ce } from "./label-place-Z0fryBZb.js";
15
- import { t as le } from "./reference-lines-C18o1yEY.js";
15
+ import { t as le } from "./reference-lines-Bet_hRyA.js";
16
16
  import { n as ue, r as M, t as de } from "./path-BglsXpnO.js";
17
- import { t as fe } from "./locate-Bcg3QcP4.js";
17
+ import { t as fe } from "./locate-Dcq5ZZSk.js";
18
18
  import { t as N } from "./heatmap-scale-Zte6Ya-g.js";
19
19
  import * as P from "@stylexjs/stylex";
20
20
  import { useId as pe, useState as me } from "react";
@@ -9,22 +9,22 @@ import { usePart as p, usePrimitive as m } from "@ui-sdk/react/primitive";
9
9
  import { useCallback as h, useLayoutEffect as g, useMemo as _, useRef as v, useState as y, useSyncExternalStore as b } from "react";
10
10
  import { createChange as x, createStickToBottom as S, definePrimitive as C, isRTL as w } from "@ui-sdk/core";
11
11
  import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
12
- import { Check as O, Circle as k, CircleDashed as A, CircleHelp as ee, Clock as j, Pause as M, Play as N, SkipBack as P, SkipForward as F, X as I } from "lucide-react";
13
- import te from "strip-ansi";
14
- import { fuzzyScore as L, matchRanges as ne, matchRanges as R, matchSegments as re, matchSegments as ie } from "@ui-sdk/react/text-match";
15
- import { clamp as z, fractionOf as ae, maxOnGrid as B, scrubTo as V, stepBy as H, stepFromKey as oe, valueAt as se } from "@ui-sdk/core/number";
12
+ import { Check as O, Circle as k, CircleDashed as A, CircleHelp as j, Clock as ee, Pause as te, Play as M, SkipBack as N, SkipForward as P, X as F } from "lucide-react";
13
+ import I from "strip-ansi";
14
+ import { fuzzyScore as L, matchRanges as R, matchRanges as ne, matchSegments as z, matchSegments as re } from "@ui-sdk/react/text-match";
15
+ import { clamp as B, fractionOf as ie, maxOnGrid as ae, scrubTo as V, stepBy as H, stepFromKey as U, valueAt as oe } from "@ui-sdk/core/number";
16
16
  // packages/content/src/json-viewer.tsx
17
- var ce = { body: {
17
+ var se = { body: {
18
18
  kmVPX3: "x1mvvolr",
19
19
  kVQacm: "xysyzu8",
20
20
  kskxy: "x1phlbz0",
21
21
  kMv6JI: "xiard35",
22
22
  kGuDYH: "xy8obcc",
23
23
  $$css: !0
24
- } }, U = 500;
25
- function W({ value: e, name: t, path: n, depth: r, maxDepth: i, maxEntries: o }) {
24
+ } }, W = 500;
25
+ function G({ value: e, name: t, path: n, depth: r, maxDepth: i, maxEntries: o }) {
26
26
  if (typeof e != "object" || !e) {
27
- let n = JSON.stringify(e), r = n.length > U;
27
+ let n = JSON.stringify(e), r = n.length > W;
28
28
  return /* @__PURE__ */ D("div", {
29
29
  className: "xeuugli x126k92a xj0a0fe",
30
30
  children: [
@@ -37,7 +37,7 @@ function W({ value: e, name: t, path: n, depth: r, maxDepth: i, maxEntries: o })
37
37
  0: { className: "xbixft" },
38
38
  1: { className: "x7ixh4y" }
39
39
  }[typeof e == "string" | 0],
40
- children: n.slice(0, U)
40
+ children: n.slice(0, W)
41
41
  }),
42
42
  r && /* @__PURE__ */ E("span", {
43
43
  className: "x153jb6y x1hz01jw",
@@ -80,7 +80,7 @@ function W({ value: e, name: t, path: n, depth: r, maxDepth: i, maxEntries: o })
80
80
  className: "xo02m6d xpilrb4 x1t7ytsu x97x49r xa1dmyi xiard35 xy8obcc",
81
81
  children: [s.slice(0, o).map(([e, t]) => {
82
82
  let a = `${n}/${e.replaceAll("~", "~0").replaceAll("/", "~1")}`;
83
- return /* @__PURE__ */ E(W, {
83
+ return /* @__PURE__ */ E(G, {
84
84
  name: JSON.stringify(e),
85
85
  path: a,
86
86
  value: t,
@@ -95,7 +95,7 @@ function W({ value: e, name: t, path: n, depth: r, maxDepth: i, maxEntries: o })
95
95
  }) })]
96
96
  });
97
97
  }
98
- function le({ value: e, label: t, maxDepth: n = 6, maxEntries: i = 50 }) {
98
+ function K({ value: e, label: t, maxDepth: n = 6, maxEntries: i = 50 }) {
99
99
  let a = o(), l = h(() => JSON.stringify(e, null, 2), [e]);
100
100
  return /* @__PURE__ */ D(c, {
101
101
  kind: "json",
@@ -116,8 +116,8 @@ function le({ value: e, label: t, maxDepth: n = 6, maxEntries: i = 50 }) {
116
116
  role: "region",
117
117
  "aria-label": `${t} fields`,
118
118
  tabIndex: a.tabIndex,
119
- ...f.props(s.scrollRegion, ce.body),
120
- children: /* @__PURE__ */ E(W, {
119
+ ...f.props(s.scrollRegion, se.body),
120
+ children: /* @__PURE__ */ E(G, {
121
121
  name: "root",
122
122
  path: "",
123
123
  value: e,
@@ -129,7 +129,7 @@ function le({ value: e, label: t, maxDepth: n = 6, maxEntries: i = 50 }) {
129
129
  });
130
130
  }
131
131
  // packages/content/src/log-viewer.tsx
132
- var ue = {
132
+ var ce = {
133
133
  kVQacm: "xysyzu8",
134
134
  kmVPX3: "x1mvvolr",
135
135
  kogj98: "x1ghz6dp",
@@ -140,9 +140,9 @@ var ue = {
140
140
  kHjlTd: "xj0a0fe",
141
141
  kKi2Bq: "xeq4nuv",
142
142
  $$css: !0
143
- }, G = {
143
+ }, q = {
144
144
  output: (e) => [
145
- ue,
145
+ ce,
146
146
  {
147
147
  kskxy: e == null ? e : "x1jols5v",
148
148
  $$css: !0
@@ -155,8 +155,8 @@ var ue = {
155
155
  kL6WhQ: "x1qndepd",
156
156
  $$css: !0
157
157
  }
158
- }, de = 2e5;
159
- function fe({ output: e, label: n, variant: i = "default", maxLines: a = 500, maxHeight: l = 320, isRunning: u = !1 }) {
158
+ }, le = 2e5;
159
+ function ue({ output: e, label: n, variant: i = "default", maxLines: a = 500, maxHeight: l = 320, isRunning: u = !1 }) {
160
160
  let d = o(), p = d.viewport, m = v(!1), [h] = y(() => {
161
161
  let e = S();
162
162
  return {
@@ -164,7 +164,7 @@ function fe({ output: e, label: n, variant: i = "default", maxLines: a = 500, ma
164
164
  subscribe: (t) => e.subscribe(t),
165
165
  read: () => e.get()
166
166
  };
167
- }), { following: _ } = b(h.subscribe, h.read, h.read), x = te(e), C = x.slice(-2e5).split("\n"), w = C.slice(-Math.max(1, a)), T = C.length - w.length, O = i === "embedded", k = u && (!O || !_);
167
+ }), { following: _ } = b(h.subscribe, h.read, h.read), x = I(e), C = x.slice(-2e5).split("\n"), w = C.slice(-Math.max(1, a)), T = C.length - w.length, O = i === "embedded", k = u && (!O || !_);
168
168
  return g(() => {
169
169
  let e = p.current;
170
170
  return e === null ? void 0 : h.connect(e);
@@ -203,11 +203,11 @@ function fe({ output: e, label: n, variant: i = "default", maxLines: a = 500, ma
203
203
  })]
204
204
  }),
205
205
  T > 0 && /* @__PURE__ */ D("div", {
206
- ...f.props(s.note, G.notice),
206
+ ...f.props(s.note, q.notice),
207
207
  children: [T, " earlier lines omitted from this view. Copy includes the supplied output."]
208
208
  }),
209
- x.length > de && /* @__PURE__ */ E("div", {
210
- ...f.props(s.note, G.notice),
209
+ x.length > le && /* @__PURE__ */ E("div", {
210
+ ...f.props(s.note, q.notice),
211
211
  children: "Preview limited to the last 200,000 characters. Copy includes the supplied output."
212
212
  }),
213
213
  /* @__PURE__ */ E("pre", {
@@ -215,7 +215,7 @@ function fe({ output: e, label: n, variant: i = "default", maxLines: a = 500, ma
215
215
  role: "region",
216
216
  "aria-label": `${n} output`,
217
217
  tabIndex: d.tabIndex,
218
- ...f.props(s.scrollRegion, G.output(l)),
218
+ ...f.props(s.scrollRegion, q.output(l)),
219
219
  children: /* @__PURE__ */ E("span", {
220
220
  className: "x1lliihq",
221
221
  children: x.length === 0 ? "No output recorded." : w.join("\n")
@@ -225,7 +225,7 @@ function fe({ output: e, label: n, variant: i = "default", maxLines: a = 500, ma
225
225
  });
226
226
  }
227
227
  // packages/content/src/media-viewer.tsx
228
- var K = {
228
+ var J = {
229
229
  viewport: {
230
230
  k1xSpc: "xrvj5dj",
231
231
  kgQiWS: "x1ku5rj1",
@@ -242,15 +242,15 @@ var K = {
242
242
  $$css: !0
243
243
  }
244
244
  };
245
- function pe() {
245
+ function de() {
246
246
  return /* @__PURE__ */ E("div", {
247
247
  "aria-hidden": !0,
248
- ...f.props(s.root, K.viewport, K.placeholder)
248
+ ...f.props(s.root, J.viewport, J.placeholder)
249
249
  });
250
250
  }
251
- function me({ kind: e, src: t, label: n, widthPixels: r, heightPixels: i, onError: a }) {
251
+ function fe({ kind: e, src: t, label: n, widthPixels: r, heightPixels: i, onError: a }) {
252
252
  return /* @__PURE__ */ E("div", {
253
- ...f.props(s.root, K.viewport),
253
+ ...f.props(s.root, J.viewport),
254
254
  children: e === "image" ? /* @__PURE__ */ E("img", {
255
255
  src: t,
256
256
  alt: n,
@@ -273,17 +273,17 @@ function me({ kind: e, src: t, label: n, widthPixels: r, heightPixels: i, onErro
273
273
  });
274
274
  }
275
275
  // packages/content/src/has-renderable-node.ts
276
- function q(e) {
276
+ function Y(e) {
277
277
  return e != null && typeof e != "boolean";
278
278
  }
279
279
  // packages/content/src/playback-bar.tsx
280
- var he = [
280
+ var pe = [
281
281
  .25,
282
282
  .5,
283
283
  1,
284
284
  2,
285
285
  4
286
- ], ge = "Playback controls", J = 16, Y = {
286
+ ], me = "Playback controls", he = 16, ge = {
287
287
  bar: {
288
288
  k1xSpc: "x78zum5",
289
289
  kwnvtZ: "x1a02dak",
@@ -312,8 +312,8 @@ var he = [
312
312
  $$css: !0
313
313
  }
314
314
  }, _e = {
315
- standard: Y.standardBar,
316
- compact: Y.compactBar
315
+ standard: ge.standardBar,
316
+ compact: ge.compactBar
317
317
  };
318
318
  function X(e) {
319
319
  return e !== void 0 && Number.isFinite(e) && e > 0;
@@ -325,12 +325,12 @@ function ve(e, t) {
325
325
  label: `${e}x`
326
326
  }));
327
327
  }
328
- function ye({ isPlaying: e, onPlayingChange: t, onStepBackward: r, onStepForward: a, speed: o, speeds: s = he, onSpeedChange: c, readout: l, actions: d, density: p = "standard", isDisabled: m = !1, playLabel: h = "Play", pauseLabel: g = "Pause", label: _ = ge, xstyle: v }) {
329
- let y = c !== void 0, b = q(d), x = X(o) ? o : void 0, S = y ? ve(s, x) : [], C = x === void 0 ? null : String(x), w = _.trim(), T = w.length > 0 ? w : ge;
328
+ function ye({ isPlaying: e, onPlayingChange: t, onStepBackward: r, onStepForward: a, speed: o, speeds: s = pe, onSpeedChange: c, readout: l, actions: d, density: p = "standard", isDisabled: m = !1, playLabel: h = "Play", pauseLabel: g = "Pause", label: _ = me, xstyle: v }) {
329
+ let y = c !== void 0, b = Y(d), x = X(o) ? o : void 0, S = y ? ve(s, x) : [], C = x === void 0 ? null : String(x), w = _.trim(), T = w.length > 0 ? w : me;
330
330
  return /* @__PURE__ */ D("div", {
331
331
  role: "group",
332
332
  "aria-label": T,
333
- ...f.props(Y.bar, _e[p], v),
333
+ ...f.props(ge.bar, _e[p], v),
334
334
  children: [
335
335
  /* @__PURE__ */ D("div", {
336
336
  className: "x78zum5 x6s0dn4 xunmzkg x2lah0s",
@@ -341,7 +341,7 @@ function ye({ isPlaying: e, onPlayingChange: t, onStepBackward: r, onStepForward
341
341
  "aria-label": "Step backward",
342
342
  disabled: m,
343
343
  onClick: r,
344
- children: /* @__PURE__ */ E(P, { size: J })
344
+ children: /* @__PURE__ */ E(N, { size: he })
345
345
  }),
346
346
  /* @__PURE__ */ E(n, {
347
347
  variant: "outline",
@@ -349,7 +349,7 @@ function ye({ isPlaying: e, onPlayingChange: t, onStepBackward: r, onStepForward
349
349
  "aria-label": e ? g : h,
350
350
  disabled: m,
351
351
  onClick: () => t(!e),
352
- children: E(e ? M : N, { size: J })
352
+ children: E(e ? te : M, { size: he })
353
353
  }),
354
354
  a !== void 0 && /* @__PURE__ */ E(n, {
355
355
  variant: "ghost",
@@ -357,7 +357,7 @@ function ye({ isPlaying: e, onPlayingChange: t, onStepBackward: r, onStepForward
357
357
  "aria-label": "Step forward",
358
358
  disabled: m,
359
359
  onClick: a,
360
- children: /* @__PURE__ */ E(F, { size: J })
360
+ children: /* @__PURE__ */ E(P, { size: he })
361
361
  })
362
362
  ]
363
363
  }),
@@ -447,10 +447,10 @@ var xe = {
447
447
  }
448
448
  };
449
449
  function Se({ text: e, query: t, ranges: n, tone: r = "warning", mode: i = "contains" }) {
450
- let a = n === void 0 ? t.trim() === "" ? [] : ne(e, t, i) : [...n], o = a.length === 0 ? [{
450
+ let a = n === void 0 ? t.trim() === "" ? [] : R(e, t, i) : [...n], o = a.length === 0 ? [{
451
451
  text: e,
452
452
  match: !1
453
- }] : re(e, a), s = r === "accent" ? xe.accent : r === "danger" ? xe.danger : void 0, c = 0;
453
+ }] : z(e, a), s = r === "accent" ? xe.accent : r === "danger" ? xe.danger : void 0, c = 0;
454
454
  return /* @__PURE__ */ E(T, { children: o.map((e) => {
455
455
  let t = `${c}-${e.match ? "m" : "t"}`;
456
456
  return c += e.text.length, e.match ? /* @__PURE__ */ E("mark", {
@@ -486,6 +486,14 @@ var Ce = .1, we = 4, Te = [
486
486
  kk7Lky: "xwj21n9",
487
487
  $$css: !0
488
488
  },
489
+ playhead: {
490
+ kVAEAm: "x10l6tqk",
491
+ k87sOh: "x13vifvy",
492
+ krVfgx: "x1ey2m1c",
493
+ kzqmXN: "x1i1rx1s",
494
+ kWkggS: "x1pt885t",
495
+ $$css: !0
496
+ },
489
497
  fill: {
490
498
  kVAEAm: "x10l6tqk",
491
499
  kYYq5F: "x10no89f",
@@ -617,8 +625,8 @@ function Ae(e, t, n) {
617
625
  if (i !== void 0) return n.find((e) => e.marker.id === i);
618
626
  }
619
627
  function je(e, t) {
620
- let n = B(t);
621
- return n < t.max && e >= (n + t.max) / 2 ? t.max : z(V(e, t).value, t.min, t.max);
628
+ let n = ae(t);
629
+ return n < t.max && e >= (n + t.max) / 2 ? t.max : B(V(e, t).value, t.min, t.max);
622
630
  }
623
631
  function Me(e, t, n) {
624
632
  let r = n / 2, i, a = Infinity;
@@ -739,7 +747,7 @@ var Ie = C({
739
747
  e !== void 0 && (r.preventDefault(), u?.(e.marker));
740
748
  return;
741
749
  }
742
- let p = oe(r, i === void 0 ? void 0 : { dir: w(i) ? "rtl" : "ltr" });
750
+ let p = U(r, i === void 0 ? void 0 : { dir: w(i) ? "rtl" : "ltr" });
743
751
  if (p === null) return;
744
752
  if (r.preventDefault(), p.bound === "min") {
745
753
  n("value", o, {
@@ -755,7 +763,7 @@ var Ie = C({
755
763
  });
756
764
  return;
757
765
  }
758
- let m = s - o, h = Math.max(c, m * Ce), g = z(H(d, p, {
766
+ let m = s - o, h = Math.max(c, m * Ce), g = B(H(d, p, {
759
767
  min: o,
760
768
  max: s,
761
769
  step: c,
@@ -794,41 +802,41 @@ var Ie = C({
794
802
  items: (e) => e.items()
795
803
  }
796
804
  });
797
- function Le({ value: e, max: t, min: n = 0, step: r = 1, onValueChange: i, onScrubStart: a, onScrubEnd: o, markers: s, onMarkerSelect: c, formatValue: l, isDisabled: u = !1, label: d, xstyle: h }) {
798
- let g = v(null), b = v(null), x = v(null), S = v(!1), C = v(null), w = v(null), O = v(null), [k, A] = y(!1), [ee, j] = y(!1), M = Number.isFinite(n) ? n : 0, N = Number.isFinite(t) && t >= M ? t : M, P = Number.isFinite(r) && r > 0 ? r : 1, F = N - M, I = z(Number.isFinite(e) ? e : M, M, N), te = F > 0 ? ae(I, {
805
+ function Le({ backdrop: e, value: t, max: n, min: r = 0, step: i = 1, onValueChange: a, onScrubStart: o, onScrubEnd: s, markers: c, onMarkerSelect: l, formatValue: u, isDisabled: d = !1, label: h, xstyle: g }) {
806
+ let b = v(null), x = v(null), S = v(null), C = v(!1), w = v(null), O = v(null), k = v(null), [A, j] = y(!1), [ee, te] = y(!1), M = Number.isFinite(r) ? r : 0, N = Number.isFinite(n) && n >= M ? n : M, P = Number.isFinite(i) && i > 0 ? i : 1, F = N - M, I = B(Number.isFinite(t) ? t : M, M, N), L = F > 0 ? ie(I, {
799
807
  min: M,
800
808
  max: N
801
- }) * 100 : 0, L = _(() => s === void 0 ? [] : s.filter((e) => Number.isFinite(e.position)).map((e) => ({
809
+ }) * 100 : 0, R = _(() => c === void 0 ? [] : c.filter((e) => Number.isFinite(e.position)).map((e) => ({
802
810
  marker: e,
803
- position: z(e.position, M, N)
811
+ position: B(e.position, M, N)
804
812
  })).toSorted((e, t) => e.position - t.position), [
805
- s,
813
+ c,
806
814
  M,
807
815
  N
808
- ]), ne = _(() => L.map(({ marker: e, position: t }) => ({
816
+ ]), ne = _(() => R.map(({ marker: e, position: t }) => ({
809
817
  id: e.id,
810
818
  position: t,
811
819
  label: e.label,
812
820
  tone: e.tone ?? "neutral"
813
- })), [L]), R = Me(I, L, P), re = l === void 0 ? void 0 : l(I), ie = R === void 0 ? re : `${re ?? String(I)}, marker: ${R.marker.label}`, B = m(Ie, {
821
+ })), [R]), z = Me(I, R, P), re = u === void 0 ? void 0 : u(I), ae = z === void 0 ? re : `${re ?? String(I)}, marker: ${z.marker.label}`, V = m(Ie, {
814
822
  value: I,
815
823
  min: M,
816
824
  max: N,
817
825
  step: P,
818
- markers: L,
826
+ markers: R,
819
827
  markerSummaries: ne,
820
- isDisabled: u,
821
- isDragging: k,
822
- valueText: ie,
823
- onValueChange: i,
824
- onMarkerSelect: c
828
+ isDisabled: d,
829
+ isDragging: A,
830
+ valueText: ae,
831
+ onValueChange: a,
832
+ onMarkerSelect: l
825
833
  });
826
- function V(e) {
834
+ function H(e) {
827
835
  if (F <= 0) return M;
828
- let t = b.current?.getBoundingClientRect();
836
+ let t = x.current?.getBoundingClientRect();
829
837
  if (t === void 0 || t.width <= 0) return I;
830
- let n = z((e - t.left) / t.width, 0, 1);
831
- return je(se(n, {
838
+ let n = B((e - t.left) / t.width, 0, 1);
839
+ return je(oe(n, {
832
840
  min: M,
833
841
  max: N
834
842
  }), {
@@ -837,91 +845,98 @@ function Le({ value: e, max: t, min: n = 0, step: r = 1, onValueChange: i, onScr
837
845
  step: P
838
846
  });
839
847
  }
840
- function H(e, t) {
841
- O.current !== e && (O.current = e, B.api.scrub(e, t));
848
+ function U(e, t) {
849
+ k.current !== e && (k.current = e, V.api.scrub(e, t));
842
850
  }
843
- function oe(e) {
844
- if (x.current !== null || u || e.button !== 0 || F <= 0) return;
845
- e.preventDefault(), g.current?.focus({ preventScroll: !0 }), Oe(e.currentTarget, e.pointerId), x.current = e.pointerId, O.current = null;
846
- let t = Ae(e.target, e.currentTarget, L);
847
- t === void 0 ? (C.current = null, S.current = !0, A(!0), a?.(), H(V(e.clientX), e.nativeEvent)) : (S.current = !1, C.current = {
851
+ function se(e) {
852
+ if (S.current !== null || d || e.button !== 0 || F <= 0) return;
853
+ e.preventDefault(), b.current?.focus({ preventScroll: !0 }), Oe(e.currentTarget, e.pointerId), S.current = e.pointerId, k.current = null;
854
+ let t = Ae(e.target, e.currentTarget, R);
855
+ t === void 0 ? (w.current = null, C.current = !0, j(!0), o?.(), U(H(e.clientX), e.nativeEvent)) : (C.current = !1, w.current = {
848
856
  marker: t.marker,
849
857
  position: t.position,
850
858
  startClientX: e.clientX,
851
859
  startClientY: e.clientY
852
860
  });
853
861
  }
854
- function ce(e) {
855
- if (u || x.current !== e.pointerId) return;
856
- let t = C.current;
862
+ function W(e) {
863
+ if (d || S.current !== e.pointerId) return;
864
+ let t = w.current;
857
865
  if (t !== null) {
858
866
  let n = e.clientX - t.startClientX, r = e.clientY - t.startClientY;
859
867
  if (Math.hypot(n, r) < we) return;
860
- C.current = null, S.current = !0, A(!0), a?.();
868
+ w.current = null, C.current = !0, j(!0), o?.();
861
869
  }
862
- S.current && H(V(e.clientX), e.nativeEvent);
870
+ C.current && U(H(e.clientX), e.nativeEvent);
863
871
  }
864
- function U(e) {
865
- if (x.current !== e.pointerId) return;
866
- let t = C.current, n = S.current;
867
- if (x.current = null, C.current = null, S.current = !1, O.current = null, ke(e.currentTarget, e.pointerId), t !== null && !u) {
872
+ function G(e) {
873
+ if (S.current !== e.pointerId) return;
874
+ let t = w.current, n = C.current;
875
+ if (S.current = null, w.current = null, C.current = !1, k.current = null, ke(e.currentTarget, e.pointerId), t !== null && !d) {
868
876
  let n = t.marker.id;
869
- w.current = n, queueMicrotask(() => {
870
- w.current === n && (w.current = null);
871
- }), B.api.activateMarker(t.marker, t.position, e.nativeEvent);
872
- } else n && (A(!1), o?.());
877
+ O.current = n, queueMicrotask(() => {
878
+ O.current === n && (O.current = null);
879
+ }), V.api.activateMarker(t.marker, t.position, e.nativeEvent);
880
+ } else n && (j(!1), s?.());
873
881
  }
874
- function W(e) {
875
- if (x.current !== e.pointerId) return;
876
- let t = S.current;
877
- x.current = null, C.current = null, S.current = !1, O.current = null, ke(e.currentTarget, e.pointerId), t && (A(!1), o?.());
882
+ function K(e) {
883
+ if (S.current !== e.pointerId) return;
884
+ let t = C.current;
885
+ S.current = null, w.current = null, C.current = !1, k.current = null, ke(e.currentTarget, e.pointerId), t && (j(!1), s?.());
878
886
  }
879
- let le = ee && !u && !k, ue = p(B, "slider", {}, {
880
- ref: g,
881
- "aria-label": d,
887
+ let ce = ee && !d && !A, q = p(V, "slider", {}, {
888
+ ref: b,
889
+ "aria-label": h,
882
890
  className: "x1n2onr6 x78zum5 x6s0dn4 xh8yej3 x17tes2r x17oiadl x5ve5x3 x87ps6o x1ypdohk x1t137rt x1m8qfh3 x13qnu6 x9v5kkp x19rmrnh x7s97pk xv519k6",
883
891
  children: /* @__PURE__ */ D("div", {
884
- ref: b,
892
+ ref: x,
885
893
  className: "x1n2onr6 xh8yej3 xqu0tyb x1ok0vyi x1fa40ue",
886
- children: [/* @__PURE__ */ E("div", { ...f.props(Z.fill, Z.fillWidth(`${te}%`)) }), /* @__PURE__ */ E("div", {
894
+ children: [/* @__PURE__ */ E("div", { ...f.props(Z.fill, Z.fillWidth(`${L}%`)) }), /* @__PURE__ */ E("div", {
887
895
  "aria-hidden": !0,
888
- ...f.props(Z.thumb, Z.insetOffset(`${te}%`), le && Z.thumbHover, k && Z.thumbDragging)
896
+ ...f.props(Z.thumb, Z.insetOffset(`${L}%`), ce && Z.thumbHover, A && Z.thumbDragging)
889
897
  })]
890
898
  })
891
899
  }, "div");
892
- return p(B, "root", {}, {
893
- onPointerDown: oe,
894
- onPointerMove: ce,
895
- onPointerUp: U,
896
- onPointerCancel: W,
897
- onLostPointerCapture: W,
898
- onPointerEnter: () => j(!0),
899
- onPointerLeave: () => j(!1),
900
- ...f.props(Z.root, h),
901
- children: /* @__PURE__ */ D(T, { children: [ue, L.length > 0 && /* @__PURE__ */ E("div", {
902
- className: "x10l6tqk x10no89f x1u5aj70 x1vjfegm x47corl",
903
- children: L.map(({ marker: e, position: t }) => {
904
- let n = F > 0 ? ae(t, {
905
- min: M,
906
- max: N
907
- }) * 100 : 0, r = e.tone ?? "neutral";
908
- return /* @__PURE__ */ E("button", {
909
- type: "button",
910
- tabIndex: -1,
911
- "data-marker-id": e.id,
912
- "aria-label": e.label,
913
- title: e.label,
914
- disabled: u,
915
- onClick: (n) => {
916
- w.current === e.id ? w.current = null : u || F <= 0 || B.api.activateMarker(e, t, n.nativeEvent);
917
- },
918
- ...f.props(Z.markerButton, Z.insetOffset(`${n}%`)),
919
- children: /* @__PURE__ */ E("span", {
920
- "aria-hidden": !0,
921
- ...f.props(Z.markerPip, De[r])
922
- })
923
- }, e.id);
924
- })
900
+ return p(V, "root", {}, {
901
+ onPointerDown: se,
902
+ onPointerMove: W,
903
+ onPointerUp: G,
904
+ onPointerCancel: K,
905
+ onLostPointerCapture: K,
906
+ onPointerEnter: () => te(!0),
907
+ onPointerLeave: () => te(!1),
908
+ ...f.props(Z.root, g),
909
+ children: /* @__PURE__ */ D(T, { children: [e !== void 0 && /* @__PURE__ */ D("div", {
910
+ "aria-hidden": !0,
911
+ className: "x1n2onr6 xnnlda6 x47corl",
912
+ children: [e, /* @__PURE__ */ E("span", { ...f.props(Z.playhead, Z.insetOffset(`${L}%`)) })]
913
+ }), /* @__PURE__ */ D("div", {
914
+ className: "x1n2onr6",
915
+ children: [q, R.length > 0 && /* @__PURE__ */ E("div", {
916
+ className: "x10l6tqk x10no89f x17y0mx6 x1vjfegm x47corl",
917
+ children: R.map(({ marker: e, position: t }) => {
918
+ let n = F > 0 ? ie(t, {
919
+ min: M,
920
+ max: N
921
+ }) * 100 : 0, r = e.tone ?? "neutral";
922
+ return /* @__PURE__ */ E("button", {
923
+ type: "button",
924
+ tabIndex: -1,
925
+ "data-marker-id": e.id,
926
+ "aria-label": e.label,
927
+ title: e.label,
928
+ disabled: d,
929
+ onClick: (n) => {
930
+ O.current === e.id ? O.current = null : d || F <= 0 || V.api.activateMarker(e, t, n.nativeEvent);
931
+ },
932
+ ...f.props(Z.markerButton, Z.insetOffset(`${n}%`)),
933
+ children: /* @__PURE__ */ E("span", {
934
+ "aria-hidden": !0,
935
+ ...f.props(Z.markerPip, De[r])
936
+ })
937
+ }, e.id);
938
+ })
939
+ })]
925
940
  })] })
926
941
  }, "div");
927
942
  }
@@ -959,12 +974,12 @@ var Q = {
959
974
  skipped: Q.skipped,
960
975
  unknown: Q.unknown
961
976
  }, ze = {
962
- pending: j,
977
+ pending: ee,
963
978
  running: k,
964
979
  complete: O,
965
- failed: I,
980
+ failed: F,
966
981
  skipped: A,
967
- unknown: ee
982
+ unknown: j
968
983
  };
969
984
  function Be({ label: e, children: t }) {
970
985
  return /* @__PURE__ */ E("ol", {
@@ -1089,7 +1104,7 @@ var Ue = {
1089
1104
  fill: $.ratioFill
1090
1105
  };
1091
1106
  function Ke({ headerStart: e, headerEnd: t }) {
1092
- let n = q(e), r = q(t);
1107
+ let n = Y(e), r = Y(t);
1093
1108
  return /* @__PURE__ */ D("div", {
1094
1109
  ...f.props(s.header),
1095
1110
  children: [n && /* @__PURE__ */ E("div", {
@@ -1102,7 +1117,7 @@ function Ke({ headerStart: e, headerEnd: t }) {
1102
1117
  });
1103
1118
  }
1104
1119
  function qe({ aspectRatio: e = "16/9", headerStart: t, headerEnd: n, notice: r, state: i = "ready", placeholder: a, children: c, label: l, xstyle: u }) {
1105
- let d = o(), p = q(t), m = q(n), h = p || m, g = q(r), _ = q(a), v = i !== "ready" && _, y = l?.trim(), b = y !== void 0 && y.length > 0, x = b ? y : i === "failed" ? "Viewport error" : "Viewport status";
1120
+ let d = o(), p = Y(t), m = Y(n), h = p || m, g = Y(r), _ = Y(a), v = i !== "ready" && _, y = l?.trim(), b = y !== void 0 && y.length > 0, x = b ? y : i === "failed" ? "Viewport error" : "Viewport status";
1106
1121
  return /* @__PURE__ */ D("div", {
1107
1122
  ...f.props(s.root, $.root, We[e], u),
1108
1123
  children: [
@@ -1137,4 +1152,4 @@ function qe({ aspectRatio: e = "16/9", headerStart: t, headerEnd: n, notice: r,
1137
1152
  ]
1138
1153
  });
1139
1154
  }
1140
- export { L as a, be as c, pe as d, fe as f, Se as i, ye as l, Ue as n, R as o, le as p, Le as r, ie as s, qe as t, me as u };
1155
+ export { L as a, be as c, de as d, ue as f, Se as i, ye as l, Ue as n, ne as o, K as p, Le as r, re as s, qe as t, fe as u };
package/dist/styles2.css CHANGED
@@ -564,10 +564,6 @@
564
564
  inset-inline: 5px;
565
565
  }
566
566
 
567
- .x1u5aj70 {
568
- inset-inline: 7px;
569
- }
570
-
571
567
  .xe8uvvx {
572
568
  list-style: none;
573
569
  }
@@ -3491,6 +3487,10 @@
3491
3487
  height: 52px;
3492
3488
  }
3493
3489
 
3490
+ .xnnlda6 {
3491
+ height: 56px;
3492
+ }
3493
+
3494
3494
  .xols6we {
3495
3495
  height: 6px;
3496
3496
  }
@@ -3,22 +3,22 @@ import { t } from "./accessibility-P89UG9-r.js";
3
3
  import { x as n } from "./src-DceyVyL0.js";
4
4
  import { d as r, u as i } from "./src-CIyuaSCi.js";
5
5
  import { n as a, t as o } from "./chart-tones-ei3BC2AL.js";
6
- import { A as s, D as c, E as l, M as u, S as d, a as f, b as p, c as m, i as h, j as ee, m as g, n as _, o as v, p as y, w as b } from "./plot-layout-1MG72ZWn.js";
7
- import { i as te, n as x, r as S, t as C } from "./categorical-values-6Iz03F1i.js";
6
+ import { A as s, D as c, E as l, M as u, S as d, a as f, b as p, c as m, i as h, j as ee, m as g, n as _, o as v, p as y, w as b } from "./plot-layout-CNNFMC8H.js";
7
+ import { i as te, n as x, r as S, t as C } from "./categorical-values-DwomVcSd.js";
8
8
  import { i as w } from "./chart-link-AE_xuxiP.js";
9
9
  import { a as T } from "./tone-scope-DKiSw-JR.js";
10
10
  import { n as ne, r as re, t as E } from "./figure-format-BVb7yFCA.js";
11
11
  import { a as D, i as O, o as k, r as A, t as ie } from "./scale-C2xgZyZN.js";
12
12
  import { t as ae } from "./chart-cursor-1mFd48Jc.js";
13
- import { c as oe, i as j, l as se, n as ce, o as M, r as le, s as N, t as ue } from "./figure-frame-96zFqsWz.js";
13
+ import { c as oe, i as j, l as se, n as ce, o as M, r as le, s as N, t as ue } from "./figure-frame-BHCNceS4.js";
14
14
  import { n as P, t as F } from "./plot-width-D3hTycYX.js";
15
15
  import { t as de } from "./plot-axes-D5S9BnBa.js";
16
16
  import { a as I, c as L, d as R, f as z, i as fe, l as pe, n as B, o as me, r as V, s as he, t as ge } from "./plot-marks-DgCtcd3L.js";
17
- import { n as _e, r as ve, t as ye } from "./plot-surface-8-FZI94y.js";
18
- import { n as be, t as xe } from "./reference-lines-C18o1yEY.js";
17
+ import { n as _e, r as ve, t as ye } from "./plot-surface-BSjoNIva.js";
18
+ import { n as be, t as xe } from "./reference-lines-Bet_hRyA.js";
19
19
  import { n as Se, r as H, t as Ce } from "./path-BglsXpnO.js";
20
20
  import { t as we } from "./chart-range-Du1gDxCY.js";
21
- import { t as U } from "./locate-Bcg3QcP4.js";
21
+ import { t as U } from "./locate-Dcq5ZZSk.js";
22
22
  import * as W from "@stylexjs/stylex";
23
23
  import { useEffect as G, useId as Te, useRef as K, useState as Ee } from "react";
24
24
  import { bindDrag as De, dispatch as Oe } from "@ui-sdk/core";
@@ -1,8 +1,8 @@
1
- import { A as e, E as t, M as n, S as r, h as i, j as a, l as o, s } from "./plot-layout-1MG72ZWn.js";
1
+ import { A as e, E as t, M as n, S as r, h as i, j as a, l as o, s } from "./plot-layout-CNNFMC8H.js";
2
2
  import { E as c, c as l, m as u, t as d, y as f } from "./src-Bkov5TTa.js";
3
3
  import { t as p } from "./chart-tones-ei3BC2AL.js";
4
4
  import { t as m } from "./chart-cursor-1mFd48Jc.js";
5
- import { i as h, l as g, n as _, r as ee, t as te } from "./figure-frame-96zFqsWz.js";
5
+ import { i as h, l as g, n as _, r as ee, t as te } from "./figure-frame-BHCNceS4.js";
6
6
  import { i as v } from "./chart-link-AE_xuxiP.js";
7
7
  import { t as y } from "./chart-range-Du1gDxCY.js";
8
8
  import { n as ne } from "./plot-width-D3hTycYX.js";
@@ -10,7 +10,7 @@ import { r as re } from "./figure-format-BVb7yFCA.js";
10
10
  import { a as ie } from "./tone-scope-DKiSw-JR.js";
11
11
  import { t as ae } from "./plot-axes-D5S9BnBa.js";
12
12
  import { r as oe } from "./plot-marks-DgCtcd3L.js";
13
- import { n as se, r as ce, t as le } from "./plot-surface-8-FZI94y.js";
13
+ import { n as se, r as ce, t as le } from "./plot-surface-BSjoNIva.js";
14
14
  import { r as ue } from "./scale-C2xgZyZN.js";
15
15
  import * as b from "@stylexjs/stylex";
16
16
  import { useId as de, useRef as fe, useState as pe } from "react";