@weasel-js/labkit 1.7.1 → 1.7.3

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 (67) hide show
  1. package/dist/chrome/index.js +4 -4
  2. package/dist/{chunk-CEGFXTBD.js → chunk-4TJ34FXA.js} +4 -4
  3. package/dist/{chunk-CEGFXTBD.js.map → chunk-4TJ34FXA.js.map} +1 -1
  4. package/dist/{chunk-GAHELLJT.js → chunk-4X44DMRS.js} +7 -7
  5. package/dist/{chunk-GAHELLJT.js.map → chunk-4X44DMRS.js.map} +1 -1
  6. package/dist/chunk-HBGH344L.js +302 -0
  7. package/dist/chunk-HBGH344L.js.map +1 -0
  8. package/dist/{chunk-4KSC7NXL.js → chunk-IRMPZIYU.js} +1984 -1892
  9. package/dist/chunk-IRMPZIYU.js.map +1 -0
  10. package/dist/{chunk-FB4MIZOO.js → chunk-LPGBC63T.js} +6 -6
  11. package/dist/chunk-LPGBC63T.js.map +1 -0
  12. package/dist/{chunk-JFOJESJF.js → chunk-XSJJTXNA.js} +22 -22
  13. package/dist/chunk-XSJJTXNA.js.map +1 -0
  14. package/dist/controls/index.d.ts +55 -3
  15. package/dist/controls/index.js +3 -2
  16. package/dist/fonts/oswald-tabular-digits.woff2 +0 -0
  17. package/dist/index.d.ts +1 -1
  18. package/dist/index.js +135 -134
  19. package/dist/index.js.map +1 -1
  20. package/dist/layers/index.js +1 -1
  21. package/dist/passthrough/weasel-ui.js +1 -1
  22. package/dist/primitives/index.js +3 -3
  23. package/dist/styles.css +238 -11
  24. package/package.json +11 -11
  25. package/src/annotations/capture.browser.test.ts +9 -3
  26. package/src/canvas/Stage.test.tsx +34 -25
  27. package/src/chrome/labRegions.test.tsx +37 -26
  28. package/src/chrome/regions/PaletteRegion.test.tsx +2 -2
  29. package/src/controls/ControlMatrix.less +250 -0
  30. package/src/controls/ControlMatrix.stories.less +13 -0
  31. package/src/controls/ControlMatrix.stories.tsx +135 -0
  32. package/src/controls/ControlMatrix.test.tsx +206 -0
  33. package/src/controls/ControlMatrix.tsx +446 -0
  34. package/src/controls/ControlPanel.tsx +4 -2
  35. package/src/controls/index.ts +6 -0
  36. package/src/dragdrop/dragDrop.test.tsx +34 -33
  37. package/src/index.ts +6 -0
  38. package/src/lab/Lab.chrome.test.tsx +15 -10
  39. package/src/lab/Lab.nebula.test.tsx +5 -5
  40. package/src/lab/Lab.surface.test.tsx +30 -21
  41. package/src/lab/Lab.test.tsx +75 -74
  42. package/src/lab/Lab.undock.test.tsx +15 -10
  43. package/src/lab/LabHeader.test.tsx +15 -14
  44. package/src/lab/LabPalette.test.tsx +12 -7
  45. package/src/lab/LabShell.less +1 -2
  46. package/src/lab/LabZoom.test.tsx +55 -44
  47. package/src/lab/Workspace.surface.test.tsx +16 -13
  48. package/src/lab/Workspace.test.tsx +32 -27
  49. package/src/overview/OverviewMarks.test.tsx +9 -8
  50. package/src/overview/TrialOverview.test.tsx +18 -17
  51. package/src/primitives/FpsMeter.less +1 -2
  52. package/src/primitives/JobProgress.less +1 -2
  53. package/src/primitives/ScaleIndicator.less +1 -1
  54. package/src/primitives/StatusBar.less +1 -1
  55. package/src/specimen/Specimen.less +1 -0
  56. package/src/styles.less +5 -0
  57. package/src/trial/Trial.annotations.persist.test.tsx +20 -9
  58. package/src/trial/Trial.annotations.test.tsx +46 -41
  59. package/src/trial/Trial.canvas.test.tsx +21 -17
  60. package/src/trial/Trial.config.test.tsx +34 -27
  61. package/src/trial/Trial.loupe.test.tsx +27 -18
  62. package/src/trial/Trial.targets.test.tsx +9 -8
  63. package/src/trial/Trial.test.tsx +51 -46
  64. package/src/trial/Trial.trialId.test.tsx +7 -6
  65. package/dist/chunk-4KSC7NXL.js.map +0 -1
  66. package/dist/chunk-FB4MIZOO.js.map +0 -1
  67. package/dist/chunk-JFOJESJF.js.map +0 -1
package/dist/index.js CHANGED
@@ -9,22 +9,23 @@ import { useJob } from './chunk-EFXRM6XQ.js';
9
9
  export { useJob } from './chunk-EFXRM6XQ.js';
10
10
  import { markCommands, boundsOf, roundFrac, worldToFrac, fracToWorld, fracEncloses, fracContains, POINT_MARK_SHAPE, roundPoints, fromShape, markSvgNodes, toShape } from './chunk-F4ACIK7Z.js';
11
11
  export { fracContains, fracEncloses, fracToWorld, markCommands, markSvgNodes, roundFrac, worldToFrac } from './chunk-F4ACIK7Z.js';
12
- import { ANNOTATION_WEASEL_TOOLS, annotationToolInfo, suppressContributions, mergeContributions, builtinContributions, TRANSIENT_BUILTINS, TitleBarRegion, ToolbarRegion, PaletteRegion, ViewportRegion, SidebarRegion, StatusRegion, resolveLabTool, useLabChromeContext, labContributions, labAnnotationTools, LabHeaderRegion, LabFooterRegion, LabAsideRegion, LabSidebarRegion } from './chunk-GAHELLJT.js';
13
- export { ANNOTATION_TOOLS, ANNOTATION_WEASEL_TOOLS, ExportMenu, LabAsideRegion, LabFooterRegion, LabHeaderRegion, LabSidebarRegion, MarkList, PaletteRegion, SidebarRegion, StatusRegion, TRANSIENT_BUILTINS, TitleBarRegion, ToolbarRegion, ViewportRegion, annotationToolInfo, builtinContributions, contributionsIn, labContributions, mergeContributions, suppressContributions, toolContributions, useLabChromeContext } from './chunk-GAHELLJT.js';
12
+ import { ANNOTATION_WEASEL_TOOLS, annotationToolInfo, suppressContributions, mergeContributions, builtinContributions, TRANSIENT_BUILTINS, TitleBarRegion, ToolbarRegion, PaletteRegion, ViewportRegion, SidebarRegion, StatusRegion, resolveLabTool, useLabChromeContext, labContributions, labAnnotationTools, LabHeaderRegion, LabFooterRegion, LabAsideRegion, LabSidebarRegion } from './chunk-4X44DMRS.js';
13
+ export { ANNOTATION_TOOLS, ANNOTATION_WEASEL_TOOLS, ExportMenu, LabAsideRegion, LabFooterRegion, LabHeaderRegion, LabSidebarRegion, MarkList, PaletteRegion, SidebarRegion, StatusRegion, TRANSIENT_BUILTINS, TitleBarRegion, ToolbarRegion, ViewportRegion, annotationToolInfo, builtinContributions, contributionsIn, labContributions, mergeContributions, suppressContributions, toolContributions, useLabChromeContext } from './chunk-4X44DMRS.js';
14
14
  import { AnnotationsContext } from './chunk-3RY6WL5T.js';
15
15
  export { AnnotationsContext, useAnnotations, useAnnotationsOptional } from './chunk-3RY6WL5T.js';
16
- import { Split, JobProgress, Legend } from './chunk-FB4MIZOO.js';
17
- export { JobProgress, Legend, Readout, Split } from './chunk-FB4MIZOO.js';
16
+ import { Split, JobProgress, Legend } from './chunk-LPGBC63T.js';
17
+ export { JobProgress, Legend, Readout, Split } from './chunk-LPGBC63T.js';
18
18
  import { FloatingPanel } from './chunk-XE5HJOPL.js';
19
19
  export { FloatingPanel } from './chunk-XE5HJOPL.js';
20
- import { Toolbar, StatusBar, ScaleIndicator, ZoomControl } from './chunk-CEGFXTBD.js';
21
- export { FpsMeter, ScaleIndicator, StatusBar, Toolbar, ZoomControl } from './chunk-CEGFXTBD.js';
20
+ import { Toolbar, StatusBar, ScaleIndicator, ZoomControl } from './chunk-4TJ34FXA.js';
21
+ export { FpsMeter, ScaleIndicator, StatusBar, Toolbar, ZoomControl } from './chunk-4TJ34FXA.js';
22
22
  import './chunk-CZZPXUOU.js';
23
23
  import { unruledConfigSchema, createLabStore, openLabStore, panelKey } from './chunk-IBVRMHW5.js';
24
24
  export { CURRENT_DOCUMENT_VERSION, dockPanel, labDocumentKey, openLabStore, panelKey, quarantineKey, undockPanel, useTrialState } from './chunk-IBVRMHW5.js';
25
25
  import { newId, useWarnIgnoredChange, useOpenOnce, PersistenceContext, createRecordCache, noneAdapter, defaultStorage, usePersistedState } from './chunk-PMLZP7RT.js';
26
26
  export { Persistence, createIndexedDbAdapter, createMemoryAdapter, indexedDbAdapter, localStorageAdapter, noneAdapter, sessionStorageAdapter, urlHashAdapter, usePersistedState } from './chunk-PMLZP7RT.js';
27
- export { ControlPanel, inDialog, summarizeValue } from './chunk-JFOJESJF.js';
27
+ export { ControlMatrix } from './chunk-HBGH344L.js';
28
+ export { ControlPanel, inDialog, summarizeValue } from './chunk-XSJJTXNA.js';
28
29
  import { useConfigSchema } from './chunk-E6NARGU7.js';
29
30
  export { sectionTree, useConfigSchema } from './chunk-E6NARGU7.js';
30
31
  import { useLabContext, LabContext } from './chunk-Z76KEZAX.js';
@@ -49,8 +50,8 @@ export { CanvasStackContext } from './chunk-ZQIHJXP4.js';
49
50
  import { LabStoreContext, TrialIdProvider, TrialIdContext } from './chunk-2YILQ7Y5.js';
50
51
  export { LabStoreContext, LabStoreProvider, TrialIdContext, TrialIdProvider, useLabStore, useTrialId } from './chunk-2YILQ7Y5.js';
51
52
  import './chunk-2RVCB2PT.js';
52
- import { D2, S2, X, U, G, p4, o3, c, Xt, c5, a7, l4, u3, a6, r3, a9, i2, o5, s3, c6, l8, p, f2, u2, y, O2, b4, l9, S, c7, i4, h2, j, k2, oe, se, R, b3, j2, n6, a10, C3, l2, u, v2, d3, j3, r4, n7, r5, i5, p2, f, n8, o4, c4, l7, w, L, n9, j4, be, n2 } from './chunk-4KSC7NXL.js';
53
- export { c as Button, V as CloseIcon, xe as CollapseIcon, _ as CurveField, i3 as DetailList, a4 as DetailRow, Se as ExpandIcon, l as Icon, u2 as Input, l10 as Jog, D2 as LayerList, re as PauseIcon, ne as PlayIcon, z2 as PropertyControl, R as PropertyField, b3 as PropertyGroup, se as PropertyList, oe as PropertyPanel, F2 as PropertyRow, ce as PropertySpan, B as ResetIcon, O2 as Select, ae as StepBackIcon, $ as StepForwardIcon, ie as StopIcon, x2 as Subpanel, a6 as ToggleBar, oe2 as TokenPanel, H2 as inferTokenType, S2 as moveLayers, O3 as refitScale } from './chunk-4KSC7NXL.js';
53
+ import { D2, S2, X, U, G, p4, o3, c, Xt, c6, a6, l5, u3, a5, r3, a8, i3, o5, s4, c7, l9, p, f2, u2, y, O2, b4, l10, S, c8, i4, h2, j, k2, ae2, oe, de, b3, j2, n6, a9, C3, l3, u, v2, d3, j3, r4, n7, r5, i5, p2, f, n8, o4, c5, l8, w, L, n9, j4, xe2, n2 } from './chunk-IRMPZIYU.js';
54
+ export { c as Button, V as CloseIcon, xe as CollapseIcon, _ as CurveField, s as DetailList, c2 as DetailRow, Se as ExpandIcon, l as Icon, u2 as Input, l11 as Jog, D2 as LayerList, re as PauseIcon, ne as PlayIcon, fe2 as PropertyControl, de as PropertyField, b3 as PropertyGroup, oe as PropertyList, ae2 as PropertyPanel, L2 as PropertyRow, se as PropertySpan, B as ResetIcon, O2 as Select, ae as StepBackIcon, $ as StepForwardIcon, ie as StopIcon, x2 as Subpanel, a5 as ToggleBar, oe2 as TokenPanel, H2 as inferTokenType, S2 as moveLayers, O3 as refitScale } from './chunk-IRMPZIYU.js';
54
55
  import { serializeSvg } from './chunk-E23Q6A3Y.js';
55
56
  import './chunk-XVUKDSYV.js';
56
57
  import { makeViewportZoomAction, createScene, asNodeId as asNodeId$1, registerNodeShape, useLatest, WeaselProvider, SceneCanvas, createPointerStore, PointerContextProvider, DepRegistryProvider, ActionsProvider, ActiveToolContextProvider, useActionsRegistry, useDepSource, ActionDisabledReason, useGestureDispatcher, sceneFromJSON, warmRender, renderSceneToPixels, useActiveToolContext } from '@weasel-js/core';
@@ -91,7 +92,7 @@ function createMarkDrawOne(opts) {
91
92
  }
92
93
  function resolveMarkStyle(data, opts) {
93
94
  return {
94
- color: opts.meaning?.statuses?.find((s2) => s2.id === data.status)?.color,
95
+ color: opts.meaning?.statuses?.find((s3) => s3.id === data.status)?.color,
95
96
  // Read off the node rather than through the store's `isStale`, which
96
97
  // wants a projected Annotation this path does not have.
97
98
  stale: isStale(data.seen, opts.config, opts.positionDependsOn ?? [])
@@ -273,8 +274,8 @@ var MarkHistory = class {
273
274
  /** The target `undo` would act on, skipping any whose scene has nothing
274
275
  * left — a scene can drop entries this ordering still lists. */
275
276
  next(stack, can, at) {
276
- for (let i5 = stack.length - 1; i5 >= 0; i5--) {
277
- const target = stack[i5];
277
+ for (let i4 = stack.length - 1; i4 >= 0; i4--) {
278
+ const target = stack[i4];
278
279
  if (target === void 0) continue;
279
280
  const scene = at(target);
280
281
  if (scene && can(scene)) return target;
@@ -282,13 +283,13 @@ var MarkHistory = class {
282
283
  return null;
283
284
  }
284
285
  canUndo(at) {
285
- return this.next(this.undoable, (s2) => s2.canUndo(), at) !== null;
286
+ return this.next(this.undoable, (s3) => s3.canUndo(), at) !== null;
286
287
  }
287
288
  canRedo(at) {
288
- return this.next(this.redoable, (s2) => s2.canRedo(), at) !== null;
289
+ return this.next(this.redoable, (s3) => s3.canRedo(), at) !== null;
289
290
  }
290
291
  undo(at) {
291
- const target = this.next(this.undoable, (s2) => s2.canUndo(), at);
292
+ const target = this.next(this.undoable, (s3) => s3.canUndo(), at);
292
293
  const scene = target === null ? void 0 : at(target);
293
294
  if (!scene) return false;
294
295
  this.replaying = "undo";
@@ -299,7 +300,7 @@ var MarkHistory = class {
299
300
  }
300
301
  }
301
302
  redo(at) {
302
- const target = this.next(this.redoable, (s2) => s2.canRedo(), at);
303
+ const target = this.next(this.redoable, (s3) => s3.canRedo(), at);
303
304
  const scene = target === null ? void 0 : at(target);
304
305
  if (!scene) return false;
305
306
  this.replaying = "redo";
@@ -311,9 +312,9 @@ var MarkHistory = class {
311
312
  }
312
313
  };
313
314
  function drop(stack, value) {
314
- for (let i5 = stack.length - 1; i5 >= 0; i5--) {
315
- if (stack[i5] === value) {
316
- stack.splice(i5, 1);
315
+ for (let i4 = stack.length - 1; i4 >= 0; i4--) {
316
+ if (stack[i4] === value) {
317
+ stack.splice(i4, 1);
317
318
  return;
318
319
  }
319
320
  }
@@ -428,21 +429,21 @@ function createAnnotationStore(opts) {
428
429
  if (!scene) return [];
429
430
  const out = [];
430
431
  for (const id of scene.renderOrder()) {
431
- const a6 = project(target, String(id));
432
- if (a6) out.push(a6);
432
+ const a5 = project(target, String(id));
433
+ if (a5) out.push(a5);
433
434
  }
434
435
  return out;
435
436
  };
436
437
  const all = () => liveTargets().flatMap(marksOn);
437
- const matches = (a6, q) => {
438
- if (q.target !== void 0 && a6.target !== q.target) return false;
439
- if (q.kind !== void 0 && a6.kind !== q.kind) return false;
440
- if (q.status !== void 0 && a6.status !== q.status) return false;
438
+ const matches = (a5, q) => {
439
+ if (q.target !== void 0 && a5.target !== q.target) return false;
440
+ if (q.kind !== void 0 && a5.kind !== q.kind) return false;
441
+ if (q.status !== void 0 && a5.status !== q.status) return false;
441
442
  if (q.tags !== void 0) {
442
- const have = a6.tags ?? [];
443
+ const have = a5.tags ?? [];
443
444
  for (const t of q.tags) if (!have.includes(t)) return false;
444
445
  }
445
- if (q.where && !q.where(a6)) return false;
446
+ if (q.where && !q.where(a5)) return false;
446
447
  return true;
447
448
  };
448
449
  const nodeOf = (id) => {
@@ -460,17 +461,17 @@ function createAnnotationStore(opts) {
460
461
  return parts ? project(parts.target, parts.node) : void 0;
461
462
  },
462
463
  query(q) {
463
- return q ? all().filter((a6) => matches(a6, q)) : all();
464
+ return q ? all().filter((a5) => matches(a5, q)) : all();
464
465
  },
465
466
  hitTest(target, pt, tol = 0) {
466
- return marksOn(target).filter((a6) => fracContains(a6.frac, pt, tol)).reverse();
467
+ return marksOn(target).filter((a5) => fracContains(a5.frac, pt, tol)).reverse();
467
468
  },
468
469
  within(target, box) {
469
- return marksOn(target).filter((a6) => fracEncloses(box, a6.frac));
470
+ return marksOn(target).filter((a5) => fracEncloses(box, a5.frac));
470
471
  },
471
- isStale(a6, config) {
472
- const keys = targetOf(a6.target)?.positionDependsOn ?? [];
473
- return isStale(a6.seen, config, keys);
472
+ isStale(a5, config) {
473
+ const keys = targetOf(a5.target)?.positionDependsOn ?? [];
474
+ return isStale(a5.seen, config, keys);
474
475
  },
475
476
  canUndo() {
476
477
  return history.canUndo(historySceneAt);
@@ -511,7 +512,7 @@ function createAnnotationStore(opts) {
511
512
  for (const [target, scene] of scenes) {
512
513
  const next = wanted.get(target) ?? [];
513
514
  const now = scene.getSelection();
514
- if (now.length === next.length && next.every((n6, i5) => String(now[i5]) === n6)) continue;
515
+ if (now.length === next.length && next.every((n6, i4) => String(now[i4]) === n6)) continue;
515
516
  scene.setSelection(next.map(asNodeId$1));
516
517
  }
517
518
  });
@@ -623,7 +624,7 @@ function fitView(content, pane) {
623
624
  const zoom = content.w > 0 && content.h > 0 ? Math.min(pane.w / content.w, pane.h / content.h) : 1;
624
625
  return { zoom: Number.isFinite(zoom) && zoom > 0 ? zoom : 1, pan: { x: 0, y: 0 } };
625
626
  }
626
- var sameRect = (a6, b3) => a6 !== null && a6.x === b3.x && a6.y === b3.y && a6.w === b3.w && a6.h === b3.h;
627
+ var sameRect = (a5, b3) => a5 !== null && a5.x === b3.x && a5.y === b3.y && a5.w === b3.w && a5.h === b3.h;
627
628
  function ToolBridge({ toolId }) {
628
629
  const tools = useActiveToolContext();
629
630
  const setActive = tools.setActive;
@@ -1122,7 +1123,7 @@ function Portalled({
1122
1123
  }
1123
1124
  function UndockedSections({ trialId, sections, onDock }) {
1124
1125
  if (sections.length === 0) return null;
1125
- return /* @__PURE__ */ jsx(Fragment, { children: sections.map((c6) => /* @__PURE__ */ jsx(Portalled, { trialId, contribution: c6, onDock }, c6.id)) });
1126
+ return /* @__PURE__ */ jsx(Fragment, { children: sections.map((c7) => /* @__PURE__ */ jsx(Portalled, { trialId, contribution: c7, onDock }, c7.id)) });
1126
1127
  }
1127
1128
  var NO_OP = () => {
1128
1129
  };
@@ -1146,15 +1147,15 @@ function TrialChrome({
1146
1147
  const lab = useLabContext();
1147
1148
  const storeCtx = useContext(LabStoreContext);
1148
1149
  if (!storeCtx) throw new Error("[labkit] TrialChrome requires <LabStoreProvider>");
1149
- const updateTrialView = useStore(storeCtx.store, (s2) => s2.updateTrialView);
1150
- const updateTrialSidebarWidth = useStore(storeCtx.store, (s2) => s2.updateTrialSidebarWidth);
1151
- const setTrialTitle = useStore(storeCtx.store, (s2) => s2.setTrialTitle);
1152
- const setTrialSectionCollapsed = useStore(storeCtx.store, (s2) => s2.setTrialSectionCollapsed);
1153
- const updateTrialConfig = useStore(storeCtx.store, (s2) => s2.updateTrialConfig);
1154
- const updateTrialState = useStore(storeCtx.store, (s2) => s2.updateTrialState);
1155
- const undockPanelAction = useStore(storeCtx.store, (s2) => s2.undockPanel);
1156
- const dockPanelAction = useStore(storeCtx.store, (s2) => s2.dockPanel);
1157
- const undockedPanels = useStore(storeCtx.store, (s2) => s2.undockedPanels);
1150
+ const updateTrialView = useStore(storeCtx.store, (s3) => s3.updateTrialView);
1151
+ const updateTrialSidebarWidth = useStore(storeCtx.store, (s3) => s3.updateTrialSidebarWidth);
1152
+ const setTrialTitle = useStore(storeCtx.store, (s3) => s3.setTrialTitle);
1153
+ const setTrialSectionCollapsed = useStore(storeCtx.store, (s3) => s3.setTrialSectionCollapsed);
1154
+ const updateTrialConfig = useStore(storeCtx.store, (s3) => s3.updateTrialConfig);
1155
+ const updateTrialState = useStore(storeCtx.store, (s3) => s3.updateTrialState);
1156
+ const undockPanelAction = useStore(storeCtx.store, (s3) => s3.undockPanel);
1157
+ const dockPanelAction = useStore(storeCtx.store, (s3) => s3.dockPanel);
1158
+ const undockedPanels = useStore(storeCtx.store, (s3) => s3.undockedPanels);
1158
1159
  const undockedIds = useMemo(
1159
1160
  () => Object.values(undockedPanels).filter((p4) => p4.trialId === trialId).map((p4) => p4.sectionId),
1160
1161
  [undockedPanels, trialId]
@@ -1174,9 +1175,9 @@ function TrialChrome({
1174
1175
  () => cameras?.get(trialId) ?? null
1175
1176
  );
1176
1177
  const ctx = useMemo(() => {
1177
- const setZoom = (z2) => {
1178
- if (camera) zoomCameraTo(camera, z2);
1179
- else if (view2d) updateTrialView(trialId, withZoom(view2d, z2));
1178
+ const setZoom = (z) => {
1179
+ if (camera) zoomCameraTo(camera, z);
1180
+ else if (view2d) updateTrialView(trialId, withZoom(view2d, z));
1180
1181
  };
1181
1182
  return {
1182
1183
  trialId,
@@ -1217,7 +1218,7 @@ function TrialChrome({
1217
1218
  undockedPanels: undockedIds,
1218
1219
  undockPanel: (sectionId, as) => undockPanelAction(trialId, sectionId, as),
1219
1220
  dockPanel: (sectionId) => dockPanelAction(trialId, sectionId),
1220
- savedSnapshots: lab.savedSnapshots.filter((s2) => s2.trialId === trialId),
1221
+ savedSnapshots: lab.savedSnapshots.filter((s3) => s3.trialId === trialId),
1221
1222
  saveSnapshot: (name) => lab.saveSnapshot(trialId, name),
1222
1223
  loadSnapshot: (snapshotId) => lab.loadSnapshot(trialId, snapshotId),
1223
1224
  clone: () => lab.cloneTrial(trialId),
@@ -1265,7 +1266,7 @@ function TrialChrome({
1265
1266
  ),
1266
1267
  [instrument, ctx, trialChrome, chrome, suppress, lab.controls]
1267
1268
  );
1268
- const inRegion = (region) => contributions.filter((c6) => c6.region === region);
1269
+ const inRegion = (region) => contributions.filter((c7) => c7.region === region);
1269
1270
  const handleKeyDown = (e) => {
1270
1271
  const mod = e.metaKey || e.ctrlKey;
1271
1272
  if (!mod) return;
@@ -1311,7 +1312,7 @@ function TrialChrome({
1311
1312
  UndockedSections,
1312
1313
  {
1313
1314
  trialId,
1314
- sections: inRegion("sidebar").filter((c6) => undockedIds.includes(c6.id)),
1315
+ sections: inRegion("sidebar").filter((c7) => undockedIds.includes(c7.id)),
1315
1316
  onDock: ctx.dockPanel
1316
1317
  }
1317
1318
  )
@@ -1335,9 +1336,9 @@ function Trial({ id, chrome, suppress }) {
1335
1336
  const lab = useLabContext();
1336
1337
  const storeCtx = useContext(LabStoreContext);
1337
1338
  if (!storeCtx) throw new Error("[labkit] <Trial> requires <LabStoreProvider>");
1338
- const instruments = useStore(storeCtx.store, (s2) => s2.instruments) ?? lab.instruments;
1339
- const record = useStore(storeCtx.store, (s2) => s2.trials.find((w2) => w2.id === id));
1340
- const instrument = record ? instruments.find((i5) => i5.name === record.instrumentName) : void 0;
1339
+ const instruments = useStore(storeCtx.store, (s3) => s3.instruments) ?? lab.instruments;
1340
+ const record = useStore(storeCtx.store, (s3) => s3.trials.find((w2) => w2.id === id));
1341
+ const instrument = record ? instruments.find((i4) => i4.name === record.instrumentName) : void 0;
1341
1342
  const kept = useKeptMarks(instrument?.annotations?.storage, id);
1342
1343
  if (!record) {
1343
1344
  return /* @__PURE__ */ jsxs("div", { className: "lk-trial lk-trial--unknown", children: [
@@ -1409,14 +1410,14 @@ function TrialRuntime({
1409
1410
  );
1410
1411
  const [pointer] = useState(createPointerStore);
1411
1412
  const canvasContainerRef = useRef(null);
1412
- const updateTrialState = useStore(store, (s2) => s2.updateTrialState);
1413
- const updateTrialConfig = useStore(store, (s2) => s2.updateTrialConfig);
1414
- const updateTrialView = useStore(store, (s2) => s2.updateTrialView);
1415
- const updateTrialUndoStack = useStore(store, (s2) => s2.updateTrialUndoStack);
1416
- const updateTrialAnnotations = useStore(store, (s2) => s2.updateTrialAnnotations);
1417
- const labToolId = useStore(store, (s2) => s2.activeToolId);
1418
- const setLabTool = useStore(store, (s2) => s2.setLabTool);
1419
- const setTrialTool = useStore(store, (s2) => s2.setTrialTool);
1413
+ const updateTrialState = useStore(store, (s3) => s3.updateTrialState);
1414
+ const updateTrialConfig = useStore(store, (s3) => s3.updateTrialConfig);
1415
+ const updateTrialView = useStore(store, (s3) => s3.updateTrialView);
1416
+ const updateTrialUndoStack = useStore(store, (s3) => s3.updateTrialUndoStack);
1417
+ const updateTrialAnnotations = useStore(store, (s3) => s3.updateTrialAnnotations);
1418
+ const labToolId = useStore(store, (s3) => s3.activeToolId);
1419
+ const setLabTool = useStore(store, (s3) => s3.setLabTool);
1420
+ const setTrialTool = useStore(store, (s3) => s3.setTrialTool);
1420
1421
  const schema = useConfigSchema(instrument);
1421
1422
  const { config } = useResolvedConfig(schema, record.config, record.auto);
1422
1423
  const busRef = useRef(null);
@@ -1566,9 +1567,9 @@ function TrialRuntime({
1566
1567
  view: record.view,
1567
1568
  setView,
1568
1569
  zoom: view2d?.zoom ?? 1,
1569
- setZoom: (z2) => {
1570
+ setZoom: (z) => {
1570
1571
  if (!view2d) return;
1571
- updateTrialView(record.id, withZoom(view2d, z2));
1572
+ updateTrialView(record.id, withZoom(view2d, z));
1572
1573
  },
1573
1574
  activeToolId: resolvedToolId,
1574
1575
  visibleLayers,
@@ -1608,7 +1609,7 @@ function TrialRuntime({
1608
1609
  const canvasLayers = useMemo(() => {
1609
1610
  if (!instrument.canvas) return [];
1610
1611
  const baseLayers = instrument.canvas.layers;
1611
- const ordered = layerOrder ? [...baseLayers].sort((a6, b3) => layerOrder.indexOf(a6.id) - layerOrder.indexOf(b3.id)) : baseLayers;
1612
+ const ordered = layerOrder ? [...baseLayers].sort((a5, b3) => layerOrder.indexOf(a5.id) - layerOrder.indexOf(b3.id)) : baseLayers;
1612
1613
  return ordered.map((layer) => ({
1613
1614
  id: layer.id,
1614
1615
  visible: layerVisibility[layer.id] !== false,
@@ -1623,7 +1624,7 @@ function TrialRuntime({
1623
1624
  return instrument.layers.ids.map((l8) => typeof l8 === "string" ? { id: l8, label: l8 } : l8);
1624
1625
  }, [instrument.layers]);
1625
1626
  const layerItems = useMemo(() => {
1626
- const ordered = layerOrder ? [...layerDescriptors].sort((a6, b3) => layerOrder.indexOf(a6.id) - layerOrder.indexOf(b3.id)) : layerDescriptors;
1627
+ const ordered = layerOrder ? [...layerDescriptors].sort((a5, b3) => layerOrder.indexOf(a5.id) - layerOrder.indexOf(b3.id)) : layerDescriptors;
1627
1628
  const pinnedLast = [
1628
1629
  ...ordered.filter((l8) => !l8.alwaysOn),
1629
1630
  ...ordered.filter((l8) => l8.alwaysOn)
@@ -1636,7 +1637,7 @@ function TrialRuntime({
1636
1637
  }));
1637
1638
  }, [layerDescriptors, layerOrder, layerVisibility]);
1638
1639
  const dragDropResult = useDragDrop({
1639
- capability: instrument.dragDrop ?? { palette: [], onDrop: (_p, _i, s2) => s2 },
1640
+ capability: instrument.dragDrop ?? { palette: [], onDrop: (_p, _i, s3) => s3 },
1640
1641
  canvasContainerRef,
1641
1642
  view: view2d ?? DEFAULT_VIEW,
1642
1643
  worldSpec: instrument.canvas?.worldSpec,
@@ -1793,7 +1794,7 @@ function TrialRuntime({
1793
1794
  // src/trial/trialOps.ts
1794
1795
  var DEFAULT_VIEW2 = { zoom: 1, pan: { x: 0, y: 0 } };
1795
1796
  function findInstrument(instruments, name) {
1796
- const found = instruments.find((i5) => i5.name === name);
1797
+ const found = instruments.find((i4) => i4.name === name);
1797
1798
  if (!found) {
1798
1799
  throw new Error(`[labkit] Unknown instrument: "${name}"`);
1799
1800
  }
@@ -1912,7 +1913,7 @@ function findOvershoot(bound, items, tolerance = 1) {
1912
1913
  return worst;
1913
1914
  }
1914
1915
  function tagAndClasses(el) {
1915
- return el.tagName.toLowerCase() + [...el.classList].map((c6) => `.${c6}`).join("");
1916
+ return el.tagName.toLowerCase() + [...el.classList].map((c7) => `.${c7}`).join("");
1916
1917
  }
1917
1918
  function describeElement(el) {
1918
1919
  if (el.classList.length > 0) return tagAndClasses(el);
@@ -1999,7 +2000,7 @@ function LabHeader({ addTrial: addTrial2 = true }) {
1999
2000
  {
2000
2001
  "aria-label": "Add trial",
2001
2002
  label: "Add trial\u2026",
2002
- items: lab.instruments.map((i5) => ({ value: i5.name, label: i5.title ?? i5.name })),
2003
+ items: lab.instruments.map((i4) => ({ value: i4.name, label: i4.title ?? i4.name })),
2003
2004
  onAction: (name) => lab.addTrial(name)
2004
2005
  }
2005
2006
  ) });
@@ -2011,7 +2012,7 @@ function LabThemeSwitcher() {
2011
2012
  function LabPalette({ tools, contributions }) {
2012
2013
  const ctx = useLabChromeContext();
2013
2014
  const all = labContributions(tools, contributions);
2014
- return /* @__PURE__ */ jsx(PaletteRegion, { contributions: all.filter((c6) => c6.region === "palette"), ctx });
2015
+ return /* @__PURE__ */ jsx(PaletteRegion, { contributions: all.filter((c7) => c7.region === "palette"), ctx });
2015
2016
  }
2016
2017
  function LabRoot({ children, mode = "auto", className }) {
2017
2018
  const resolved = useResolvedColorMode(mode);
@@ -2084,13 +2085,13 @@ function LabSwitcher({ title, pages, path, className }) {
2084
2085
  ]
2085
2086
  }
2086
2087
  ) }),
2087
- open && /* @__PURE__ */ jsx("div", { className: "lk-switcher-menu", id: menuId, role: "menu", children: pages.map((page, i5) => /* @__PURE__ */ jsx(
2088
+ open && /* @__PURE__ */ jsx("div", { className: "lk-switcher-menu", id: menuId, role: "menu", children: pages.map((page, i4) => /* @__PURE__ */ jsx(
2088
2089
  "a",
2089
2090
  {
2090
2091
  href: page.href,
2091
2092
  role: "menuitem",
2092
2093
  className: "lk-switcher-item",
2093
- "aria-current": i5 === here ? "page" : void 0,
2094
+ "aria-current": i4 === here ? "page" : void 0,
2094
2095
  onClick: close,
2095
2096
  children: page.label
2096
2097
  },
@@ -2157,8 +2158,8 @@ function LabZoomControls() {
2157
2158
  cameras?.subscribe ?? noSubscribe2,
2158
2159
  () => cameras && focusedTrialId ? cameras.get(focusedTrialId) : null
2159
2160
  );
2160
- const zoom = useStore(storeCtx.store, (s2) => {
2161
- const record = s2.trials.find((t) => t.id === focusedTrialId);
2161
+ const zoom = useStore(storeCtx.store, (s3) => {
2162
+ const record = s3.trials.find((t) => t.id === focusedTrialId);
2162
2163
  return as2DView(record?.view)?.zoom ?? null;
2163
2164
  });
2164
2165
  const live = zoom !== null && camera !== null;
@@ -2280,7 +2281,7 @@ function Workspace({
2280
2281
  const tilePanels = useMemo(() => (panels ?? []).filter((p4) => p4.as === "tile"), [panels]);
2281
2282
  const floatPanels = useMemo(() => (panels ?? []).filter((p4) => p4.as === "floating"), [panels]);
2282
2283
  const idKey = JSON.stringify([
2283
- ...items.map((_2, i5) => ids?.[i5] ?? `lk-ws-${i5}`),
2284
+ ...items.map((_2, i4) => ids?.[i4] ?? `lk-ws-${i4}`),
2284
2285
  ...tilePanels.map((p4) => `lk-panel-${p4.key}`)
2285
2286
  ]);
2286
2287
  const nodeIds = useMemo(() => JSON.parse(idKey).map(asNodeId), [idKey]);
@@ -2331,7 +2332,7 @@ function Workspace({
2331
2332
  [onReorder]
2332
2333
  );
2333
2334
  const chrome = useMemo(() => {
2334
- const byId = new Map(nodeIds.map((id, i5) => [id, items[i5]]));
2335
+ const byId = new Map(nodeIds.map((id, i4) => [id, items[i4]]));
2335
2336
  const panelByNode = new Map(
2336
2337
  tilePanels.map((p4) => [`lk-panel-${p4.key}`, p4])
2337
2338
  );
@@ -2397,7 +2398,7 @@ async function openStoredLab({ instruments, defaultInstrument, mode }, storageKe
2397
2398
  const marks = /* @__PURE__ */ new Map();
2398
2399
  await Promise.all(
2399
2400
  opened.store.getState().trials.map(async (trial) => {
2400
- const kept = instruments.find((i5) => i5.name === trial.instrumentName)?.annotations?.storage;
2401
+ const kept = instruments.find((i4) => i4.name === trial.instrumentName)?.annotations?.storage;
2401
2402
  if (!kept) return;
2402
2403
  try {
2403
2404
  marks.set(trial.id, await kept.load());
@@ -2447,10 +2448,10 @@ var NEBULA_SLOTS = [
2447
2448
  function buildNebula(list, theme, mode, density) {
2448
2449
  const ctx = { theme, resolved: resolveTheme(theme, { mode, density }) };
2449
2450
  const n6 = colorCount(list, ctx) ?? NEBULA_SLOTS.length;
2450
- const colors = Array.from({ length: n6 }, (_2, i5) => colorAt(list, i5, ctx));
2451
- const blobs = colors.map((c6, i5) => {
2452
- const p4 = NEBULA_SLOTS[i5 % NEBULA_SLOTS.length];
2453
- return `radial-gradient(ellipse ${p4.sx} ${p4.sy} at ${p4.cx} ${p4.cy}, color-mix(in srgb, ${c6} 22%, transparent), transparent ${p4.stop})`;
2451
+ const colors = Array.from({ length: n6 }, (_2, i4) => colorAt(list, i4, ctx));
2452
+ const blobs = colors.map((c7, i4) => {
2453
+ const p4 = NEBULA_SLOTS[i4 % NEBULA_SLOTS.length];
2454
+ return `radial-gradient(ellipse ${p4.sx} ${p4.sy} at ${p4.cx} ${p4.cy}, color-mix(in srgb, ${c7} 22%, transparent), transparent ${p4.stop})`;
2454
2455
  });
2455
2456
  blobs.push("radial-gradient(ellipse at center, #0a0a18 0%, #02020a 100%)");
2456
2457
  return blobs.join(", ");
@@ -2470,7 +2471,7 @@ function LabPanes({
2470
2471
  void 0,
2471
2472
  { scope: "lab" }
2472
2473
  );
2473
- const main = contributions.some((c6) => c6.region === "aside") ? /* @__PURE__ */ jsx(
2474
+ const main = contributions.some((c7) => c7.region === "aside") ? /* @__PURE__ */ jsx(
2474
2475
  Split,
2475
2476
  {
2476
2477
  className: "lk-lab__panes",
@@ -2488,7 +2489,7 @@ function LabPanes({
2488
2489
  children
2489
2490
  }
2490
2491
  ) : children;
2491
- if (!contributions.some((c6) => c6.region === "sidebar")) return main;
2492
+ if (!contributions.some((c7) => c7.region === "sidebar")) return main;
2492
2493
  return /* @__PURE__ */ jsx(
2493
2494
  Split,
2494
2495
  {
@@ -2557,14 +2558,14 @@ function LabRuntime({
2557
2558
  useLayoutEffect(() => {
2558
2559
  store.getState().setInstruments(instruments);
2559
2560
  }, [instruments, store]);
2560
- const trials = useStore(store, (s2) => s2.trials);
2561
+ const trials = useStore(store, (s3) => s3.trials);
2561
2562
  const [cameras] = useState(createCameraRegistry);
2562
2563
  const [focusPick, setFocusPick] = useState(null);
2563
2564
  const focusedTrialId = trials.some((t) => t.id === focusPick) ? focusPick : trials[0]?.id ?? null;
2564
- const savedSnapshots = useStore(store, (s2) => s2.savedSnapshots);
2565
- const modeValue = useStore(store, (s2) => s2.mode);
2566
- const layout = useStore(store, (s2) => s2.layout);
2567
- const undockedPanels = useStore(store, (s2) => s2.undockedPanels);
2565
+ const savedSnapshots = useStore(store, (s3) => s3.savedSnapshots);
2566
+ const modeValue = useStore(store, (s3) => s3.mode);
2567
+ const layout = useStore(store, (s3) => s3.layout);
2568
+ const undockedPanels = useStore(store, (s3) => s3.undockedPanels);
2568
2569
  const panelHostsRef = useRef(null);
2569
2570
  if (panelHostsRef.current === null) panelHostsRef.current = createPanelHostRegistry();
2570
2571
  const outerSurface = useSurfaceOptional();
@@ -2577,17 +2578,17 @@ function LabRuntime({
2577
2578
  const bufferRef = useRef({ w: 0, h: 0 });
2578
2579
  const surfaceRef = useRef(null);
2579
2580
  const onFrame = useCallback((frame) => {
2580
- const canvases = [ownUnderRef.current, ownOverRef.current].filter((c6) => c6 !== null);
2581
+ const canvases = [ownUnderRef.current, ownOverRef.current].filter((c7) => c7 !== null);
2581
2582
  if (canvases.length === 0) return;
2582
2583
  const w2 = Math.round(frame.size.width * frame.dpr);
2583
2584
  const h2 = Math.round(frame.size.height * frame.dpr);
2584
2585
  if (bufferRef.current.w !== w2 || bufferRef.current.h !== h2) {
2585
2586
  bufferRef.current = { w: w2, h: h2 };
2586
- for (const c6 of canvases) {
2587
- c6.width = w2;
2588
- c6.height = h2;
2589
- c6.style.width = `${frame.size.width}px`;
2590
- c6.style.height = `${frame.size.height}px`;
2587
+ for (const c7 of canvases) {
2588
+ c7.width = w2;
2589
+ c7.height = h2;
2590
+ c7.style.width = `${frame.size.width}px`;
2591
+ c7.style.height = `${frame.size.height}px`;
2591
2592
  }
2592
2593
  surfaceRef.current?.invalidateAll();
2593
2594
  return;
@@ -2653,8 +2654,8 @@ function LabRuntime({
2653
2654
  () => labContributions([...annotationTools, ...tools ?? []], labChrome),
2654
2655
  [annotationTools, tools, labChrome]
2655
2656
  );
2656
- const hasFooterChrome = labChromeAll.some((c6) => c6.region === "footer");
2657
- const hasPaneChrome = labChromeAll.some((c6) => c6.region === "sidebar" || c6.region === "aside");
2657
+ const hasFooterChrome = labChromeAll.some((c7) => c7.region === "footer");
2658
+ const hasPaneChrome = labChromeAll.some((c7) => c7.region === "sidebar" || c7.region === "aside");
2658
2659
  useEffect(() => {
2659
2660
  if (mode && mode !== store.getState().mode) {
2660
2661
  store.getState().setMode(mode);
@@ -2706,15 +2707,15 @@ function LabRuntime({
2706
2707
  const next = resetTrial(store.getState().trials, id, instruments);
2707
2708
  const record = next.find((w2) => w2.id === id);
2708
2709
  if (!record) return;
2709
- store.setState((s2) => ({
2710
- trials: s2.trials.map(
2710
+ store.setState((s3) => ({
2711
+ trials: s3.trials.map(
2711
2712
  (w2) => w2.id === id ? { ...w2, config: record.config, state: record.state, view: record.view } : w2
2712
2713
  )
2713
2714
  }));
2714
2715
  },
2715
2716
  savedSnapshots,
2716
2717
  saveSnapshot: (trialId, name) => {
2717
- const taken = store.getState().savedSnapshots.filter((s2) => s2.trialId === trialId).length;
2718
+ const taken = store.getState().savedSnapshots.filter((s3) => s3.trialId === trialId).length;
2718
2719
  store.getState().saveSnapshot(trialId, name ?? `Snapshot ${taken + 1}`);
2719
2720
  },
2720
2721
  loadSnapshot: (trialId, snapshotId) => {
@@ -2939,18 +2940,18 @@ function ButtonsAndToggles() {
2939
2940
  /* @__PURE__ */ jsx(Xt, { status: "muted", children: "MUTED" })
2940
2941
  ] }) }),
2941
2942
  /* @__PURE__ */ jsx(Cell, { label: "Checkbox, Switch", children: /* @__PURE__ */ jsxs("div", { className: "lk-specimen__row", children: [
2942
- /* @__PURE__ */ jsx(c5, { isSelected: snap, onChange: setSnap, children: "Snap to grid" }),
2943
- /* @__PURE__ */ jsx(c5, { isIndeterminate: true, children: "Mixed" }),
2944
- /* @__PURE__ */ jsx(a7, { isSelected: wifi, onChange: setWifi, children: "Wifi" })
2943
+ /* @__PURE__ */ jsx(c6, { isSelected: snap, onChange: setSnap, children: "Snap to grid" }),
2944
+ /* @__PURE__ */ jsx(c6, { isIndeterminate: true, children: "Mixed" }),
2945
+ /* @__PURE__ */ jsx(a6, { isSelected: wifi, onChange: setWifi, children: "Wifi" })
2945
2946
  ] }) }),
2946
- /* @__PURE__ */ jsx(Cell, { label: "RadioGroup", children: /* @__PURE__ */ jsxs(l4, { label: "Snap mode", orientation: "horizontal", defaultValue: "grid", children: [
2947
+ /* @__PURE__ */ jsx(Cell, { label: "RadioGroup", children: /* @__PURE__ */ jsxs(l5, { label: "Snap mode", orientation: "horizontal", defaultValue: "grid", children: [
2947
2948
  /* @__PURE__ */ jsx(u3, { value: "off", children: "Off" }),
2948
2949
  /* @__PURE__ */ jsx(u3, { value: "grid", children: "Grid" }),
2949
2950
  /* @__PURE__ */ jsx(u3, { value: "pixel", children: "Pixel" })
2950
2951
  ] }) }),
2951
2952
  /* @__PURE__ */ jsxs(Cell, { label: "ToggleBar", children: [
2952
2953
  /* @__PURE__ */ jsx(
2953
- a6,
2954
+ a5,
2954
2955
  {
2955
2956
  ariaLabel: "Align",
2956
2957
  value: align,
@@ -2963,7 +2964,7 @@ function ButtonsAndToggles() {
2963
2964
  }
2964
2965
  ),
2965
2966
  /* @__PURE__ */ jsx(
2966
- a6,
2967
+ a5,
2967
2968
  {
2968
2969
  ariaLabel: "Align, flat",
2969
2970
  variant: "flat",
@@ -2989,7 +2990,7 @@ function ButtonsAndToggles() {
2989
2990
  }
2990
2991
  ),
2991
2992
  /* @__PURE__ */ jsx(
2992
- a9,
2993
+ a8,
2993
2994
  {
2994
2995
  items: [
2995
2996
  { value: "undo", label: "Undo", onAction: () => {
@@ -3013,17 +3014,17 @@ function ButtonsAndToggles() {
3013
3014
  ]
3014
3015
  }
3015
3016
  ),
3016
- /* @__PURE__ */ jsx(i2, { open, onToggle: () => setOpen((o4) => !o4), label: "Shapes" })
3017
+ /* @__PURE__ */ jsx(i3, { open, onToggle: () => setOpen((o4) => !o4), label: "Shapes" })
3017
3018
  ] }) }),
3018
3019
  /* @__PURE__ */ jsx(Cell, { label: "Tabs", children: /* @__PURE__ */ jsxs(o5, { children: [
3019
- /* @__PURE__ */ jsxs(s3, { "aria-label": "Sections", children: [
3020
- /* @__PURE__ */ jsx(c6, { id: "props", children: "Props" }),
3021
- /* @__PURE__ */ jsx(c6, { id: "events", children: "Events" }),
3022
- /* @__PURE__ */ jsx(c6, { id: "snapshot", children: "Snapshot" })
3020
+ /* @__PURE__ */ jsxs(s4, { "aria-label": "Sections", children: [
3021
+ /* @__PURE__ */ jsx(c7, { id: "props", children: "Props" }),
3022
+ /* @__PURE__ */ jsx(c7, { id: "events", children: "Events" }),
3023
+ /* @__PURE__ */ jsx(c7, { id: "snapshot", children: "Snapshot" })
3023
3024
  ] }),
3024
- /* @__PURE__ */ jsx(l8, { id: "props", children: "Props panel." }),
3025
- /* @__PURE__ */ jsx(l8, { id: "events", children: "Events panel." }),
3026
- /* @__PURE__ */ jsx(l8, { id: "snapshot", children: "Snapshot panel." })
3025
+ /* @__PURE__ */ jsx(l9, { id: "props", children: "Props panel." }),
3026
+ /* @__PURE__ */ jsx(l9, { id: "events", children: "Events panel." }),
3027
+ /* @__PURE__ */ jsx(l9, { id: "snapshot", children: "Snapshot panel." })
3027
3028
  ] }) }),
3028
3029
  /* @__PURE__ */ jsx(Cell, { label: "Keycaps", children: /* @__PURE__ */ jsxs("div", { className: "lk-specimen__row", children: [
3029
3030
  /* @__PURE__ */ jsx(p, { keys: [{ label: "\u2318" }, { label: "\u21E7" }, { label: "K" }], separator: "+" }),
@@ -3088,9 +3089,9 @@ function FieldsAndPickers() {
3088
3089
  )
3089
3090
  ] }),
3090
3091
  /* @__PURE__ */ jsxs(Cell, { label: "RangeSlider, Slider", children: [
3091
- /* @__PURE__ */ jsx(l9, { label: "Range", defaultValue: [20, 80], minValue: 0, maxValue: 100 }),
3092
+ /* @__PURE__ */ jsx(l10, { label: "Range", defaultValue: [20, 80], minValue: 0, maxValue: 100 }),
3092
3093
  /* @__PURE__ */ jsx(
3093
- l9,
3094
+ l10,
3094
3095
  {
3095
3096
  label: "Opacity",
3096
3097
  defaultValue: 75,
@@ -3115,7 +3116,7 @@ function FieldsAndPickers() {
3115
3116
  ] }),
3116
3117
  /* @__PURE__ */ jsxs(Cell, { label: "DetentSlider, InlineRange", children: [
3117
3118
  /* @__PURE__ */ jsx(
3118
- c7,
3119
+ c8,
3119
3120
  {
3120
3121
  items: [0.25, 0.5, 1, 2, 4],
3121
3122
  value: rate,
@@ -3170,9 +3171,9 @@ function PanelsAndRows() {
3170
3171
  ]);
3171
3172
  const [panelCollapsed, setPanelCollapsed] = useState(false);
3172
3173
  return /* @__PURE__ */ jsxs(Section, { title: "Panels & property rows", children: [
3173
- /* @__PURE__ */ jsx(Cell, { label: "PropertyPanel", children: /* @__PURE__ */ jsx(oe, { title: "Shape", children: /* @__PURE__ */ jsxs(se, { children: [
3174
+ /* @__PURE__ */ jsx(Cell, { label: "PropertyPanel", children: /* @__PURE__ */ jsx(ae2, { title: "Shape", children: /* @__PURE__ */ jsxs(oe, { children: [
3174
3175
  /* @__PURE__ */ jsx(
3175
- R,
3176
+ de,
3176
3177
  {
3177
3178
  kind: "number",
3178
3179
  control: "slider",
@@ -3185,7 +3186,7 @@ function PanelsAndRows() {
3185
3186
  }
3186
3187
  ),
3187
3188
  /* @__PURE__ */ jsx(
3188
- R,
3189
+ de,
3189
3190
  {
3190
3191
  kind: "number",
3191
3192
  control: "slider",
@@ -3198,7 +3199,7 @@ function PanelsAndRows() {
3198
3199
  }
3199
3200
  ),
3200
3201
  /* @__PURE__ */ jsx(
3201
- R,
3202
+ de,
3202
3203
  {
3203
3204
  kind: "color",
3204
3205
  label: "Fill",
@@ -3208,9 +3209,9 @@ function PanelsAndRows() {
3208
3209
  onAlphaChange: setAlpha
3209
3210
  }
3210
3211
  ),
3211
- /* @__PURE__ */ jsx(R, { kind: "color", label: "Stroke", value: stroke, onChange: setStroke }),
3212
+ /* @__PURE__ */ jsx(de, { kind: "color", label: "Stroke", value: stroke, onChange: setStroke }),
3212
3213
  /* @__PURE__ */ jsx(
3213
- R,
3214
+ de,
3214
3215
  {
3215
3216
  kind: "number",
3216
3217
  label: "Count",
@@ -3222,7 +3223,7 @@ function PanelsAndRows() {
3222
3223
  }
3223
3224
  ),
3224
3225
  /* @__PURE__ */ jsx(
3225
- R,
3226
+ de,
3226
3227
  {
3227
3228
  kind: "enum",
3228
3229
  label: "Line cap",
@@ -3235,7 +3236,7 @@ function PanelsAndRows() {
3235
3236
  }
3236
3237
  ),
3237
3238
  /* @__PURE__ */ jsx(
3238
- R,
3239
+ de,
3239
3240
  {
3240
3241
  kind: "enum",
3241
3242
  control: "toggle",
@@ -3249,10 +3250,10 @@ function PanelsAndRows() {
3249
3250
  ]
3250
3251
  }
3251
3252
  ),
3252
- /* @__PURE__ */ jsx(R, { kind: "string", label: "Label", value: label, onChange: setLabel }),
3253
- /* @__PURE__ */ jsx(R, { kind: "boolean", label: "Visible", value: visible, onChange: setVisible }),
3253
+ /* @__PURE__ */ jsx(de, { kind: "string", label: "Label", value: label, onChange: setLabel }),
3254
+ /* @__PURE__ */ jsx(de, { kind: "boolean", label: "Visible", value: visible, onChange: setVisible }),
3254
3255
  /* @__PURE__ */ jsx(b3, { title: "Bevel", defaultCollapsed: true, children: /* @__PURE__ */ jsx(
3255
- R,
3256
+ de,
3256
3257
  {
3257
3258
  kind: "number",
3258
3259
  control: "slider",
@@ -3286,7 +3287,7 @@ function PanelsAndRows() {
3286
3287
  }
3287
3288
  ) }),
3288
3289
  /* @__PURE__ */ jsx(Cell, { label: "Sidebar, SidebarPanel", children: /* @__PURE__ */ jsx("div", { className: "lk-specimen__box", children: /* @__PURE__ */ jsx(n6, { side: "right", ariaLabel: "Specimen sidebar", children: /* @__PURE__ */ jsx(
3289
- a10,
3290
+ a9,
3290
3291
  {
3291
3292
  title: "Selection",
3292
3293
  collapsed: panelCollapsed,
@@ -3305,7 +3306,7 @@ function OverlaysAndFeedback() {
3305
3306
  const toasts = useMemo(() => C3(), []);
3306
3307
  return /* @__PURE__ */ jsxs(Section, { title: "Overlays & feedback", children: [
3307
3308
  /* @__PURE__ */ jsx(Cell, { label: "Tooltip, Callout, Dialog, Toast", children: /* @__PURE__ */ jsxs("div", { className: "lk-specimen__row", children: [
3308
- /* @__PURE__ */ jsxs(l2, { children: [
3309
+ /* @__PURE__ */ jsxs(l3, { children: [
3309
3310
  /* @__PURE__ */ jsx(Focusable, { children: /* @__PURE__ */ jsx("button", { type: "button", children: "Hover me" }) }),
3310
3311
  /* @__PURE__ */ jsx(u, { placement: "bottom", children: "Duplicates the selected layer" })
3311
3312
  ] }),
@@ -3406,14 +3407,14 @@ function ToolChrome() {
3406
3407
  },
3407
3408
  id
3408
3409
  )) }) }),
3409
- /* @__PURE__ */ jsx(Cell, { label: "ToolOptionsBar", children: /* @__PURE__ */ jsxs(c4, { label: "Text", children: [
3410
+ /* @__PURE__ */ jsx(Cell, { label: "ToolOptionsBar", children: /* @__PURE__ */ jsxs(c5, { label: "Text", children: [
3410
3411
  /* @__PURE__ */ jsx(c, { size: "sm", variant: "ghost", iconOnly: true, ariaLabel: "Bold", children: "B" }),
3411
3412
  /* @__PURE__ */ jsx(c, { size: "sm", variant: "ghost", iconOnly: true, ariaLabel: "Italic", children: "I" })
3412
3413
  ] }) }),
3413
3414
  /* @__PURE__ */ jsx(Cell, { label: "ResizeHandle", children: /* @__PURE__ */ jsxs("div", { className: "lk-specimen__box", children: [
3414
3415
  /* @__PURE__ */ jsx("div", { className: "lk-specimen__box-main", children: "content" }),
3415
3416
  /* @__PURE__ */ jsx(
3416
- l7,
3417
+ l8,
3417
3418
  {
3418
3419
  value: paneWidth,
3419
3420
  min: 100,
@@ -3537,7 +3538,7 @@ function EditorsAndPlots() {
3537
3538
  }
3538
3539
  ) }),
3539
3540
  /* @__PURE__ */ jsx(Cell, { label: "Timeline", wide: true, children: /* @__PURE__ */ jsx("div", { className: "lk-specimen__timeline", children: /* @__PURE__ */ jsx(
3540
- be,
3541
+ xe2,
3541
3542
  {
3542
3543
  tracks,
3543
3544
  duration: 2e3,