@weasel-js/labkit 1.5.2 → 1.6.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 (139) hide show
  1. package/README.md +3 -7
  2. package/dist/_dts/{CanvasStackContext-CMMo180l.d.ts → CanvasStackContext-DQgcH1ny.d.ts} +1 -1
  3. package/dist/_dts/LayerList.d-2c9yup5Y.d.ts +83 -0
  4. package/dist/_dts/{PrefsForm.d-DPy9I8It.d.ts → PrefsRow.d-DFpPIeIC.d.ts} +16 -1
  5. package/dist/_dts/{Select.d-ZTiwzYyT.d.ts → Select.d-BchGMC2Y.d.ts} +102 -11
  6. package/dist/_dts/{frac-B4hFJMiN.d.ts → frac-DTRq7Xpb.d.ts} +18 -10
  7. package/dist/_dts/inDialog-D5ZKGjiD.d.ts +23 -0
  8. package/dist/_dts/{index-DlKolEIZ.d.ts → index-B0--8PEM.d.ts} +2 -2
  9. package/dist/_dts/index-DINmCuLA.d.ts +453 -0
  10. package/dist/_dts/number.d-OeQYQoUO.d.ts +28 -0
  11. package/dist/_dts/{types-Db-3NNk1.d.ts → types-B7y8hX1D.d.ts} +2 -2
  12. package/dist/_dts/{usePanZoom-SSTZe410.d.ts → usePanZoom-Bq73pwFe.d.ts} +2 -2
  13. package/dist/_dts/{useTrialState-pnAE-UBD.d.ts → useTrialState-CP4jfuKl.d.ts} +1 -1
  14. package/dist/canvas/index.d.ts +6 -5
  15. package/dist/chrome/index.d.ts +5 -4
  16. package/dist/chrome/index.js +7 -7
  17. package/dist/chunk-2RVCB2PT.js +3 -0
  18. package/dist/chunk-2RVCB2PT.js.map +1 -0
  19. package/dist/{chunk-753Y6HE6.js → chunk-3FI7Y4R4.js} +4 -4
  20. package/dist/chunk-3FI7Y4R4.js.map +1 -0
  21. package/dist/{chunk-REOBGYMC.js → chunk-AWH3SRPW.js} +31 -5
  22. package/dist/chunk-AWH3SRPW.js.map +1 -0
  23. package/dist/{chunk-A2ACAGW6.js → chunk-BVL7Y574.js} +22 -5
  24. package/dist/chunk-BVL7Y574.js.map +1 -0
  25. package/dist/{chunk-CKUKF72R.js → chunk-H5VIV7MQ.js} +26 -22
  26. package/dist/chunk-H5VIV7MQ.js.map +1 -0
  27. package/dist/chunk-HFRE4QQV.js +400 -0
  28. package/dist/chunk-HFRE4QQV.js.map +1 -0
  29. package/dist/{chunk-LRI3MBGR.js → chunk-MOLIUNVH.js} +4 -4
  30. package/dist/{chunk-LRI3MBGR.js.map → chunk-MOLIUNVH.js.map} +1 -1
  31. package/dist/chunk-USO6TERP.js +90 -0
  32. package/dist/chunk-USO6TERP.js.map +1 -0
  33. package/dist/{chunk-EMXAIRUJ.js → chunk-VQ47KWD5.js} +3 -3
  34. package/dist/{chunk-EMXAIRUJ.js.map → chunk-VQ47KWD5.js.map} +1 -1
  35. package/dist/chunk-WUJXJC5O.js +14568 -0
  36. package/dist/chunk-WUJXJC5O.js.map +1 -0
  37. package/dist/{chunk-KJCUERQF.js → chunk-ZORVNOKX.js} +6 -25
  38. package/dist/chunk-ZORVNOKX.js.map +1 -0
  39. package/dist/config/index.d.ts +50 -7
  40. package/dist/config/index.js +5 -5
  41. package/dist/controls/index.d.ts +6 -3
  42. package/dist/controls/index.js +4 -4
  43. package/dist/dragdrop/index.d.ts +4 -3
  44. package/dist/index.d.ts +83 -102
  45. package/dist/index.js +430 -458
  46. package/dist/index.js.map +1 -1
  47. package/dist/layers/index.d.ts +6 -35
  48. package/dist/layers/index.js +2 -3
  49. package/dist/loupe/index.d.ts +6 -5
  50. package/dist/passthrough/weasel-ui.d.ts +407 -204
  51. package/dist/passthrough/weasel-ui.js +1 -1
  52. package/dist/primitives/index.d.ts +2 -13
  53. package/dist/primitives/index.js +4 -4
  54. package/dist/state/index.d.ts +6 -5
  55. package/dist/state/index.js +5 -5
  56. package/dist/styles.css +298 -174
  57. package/dist/undo/index.d.ts +4 -3
  58. package/package.json +9 -13
  59. package/src/annotations/frac.test.ts +7 -0
  60. package/src/annotations/paint.test.ts +21 -0
  61. package/src/annotations/paint.ts +12 -0
  62. package/src/annotations/store.test.ts +31 -0
  63. package/src/annotations/types.ts +3 -2
  64. package/src/canvas/Stage.test.tsx +18 -0
  65. package/src/chrome/regions/SidebarRegion.less +197 -0
  66. package/src/chrome/regions/SidebarRegion.test.tsx +20 -0
  67. package/src/chrome/regions/SidebarRegion.tsx +7 -2
  68. package/src/chrome/types.ts +5 -2
  69. package/src/config/autoConfig.ts +2 -2
  70. package/src/config/builder.ts +20 -1
  71. package/src/config/entry.test.ts +8 -0
  72. package/src/config/index.ts +2 -0
  73. package/src/config/rules.ts +2 -0
  74. package/src/config/sectionTree.test.ts +146 -0
  75. package/src/config/sectionTree.ts +124 -0
  76. package/src/controls/ControlPanel.less +4 -0
  77. package/src/controls/ControlPanel.stories.tsx +55 -2
  78. package/src/controls/ControlPanel.test.tsx +30 -3
  79. package/src/controls/ControlPanel.tsx +116 -337
  80. package/src/controls/inDialog.test.tsx +82 -0
  81. package/src/controls/inDialog.tsx +46 -0
  82. package/src/controls/index.ts +1 -0
  83. package/src/index.ts +11 -26
  84. package/src/instrument/types.ts +5 -2
  85. package/src/lab/Lab.nebula.test.tsx +31 -0
  86. package/src/lab/Lab.tsx +38 -15
  87. package/src/lab/LabBoundary.test.tsx +66 -0
  88. package/src/lab/LabBoundary.tsx +56 -0
  89. package/src/lab/LabHeader.tsx +4 -23
  90. package/src/lab/LabRoot.tsx +2 -3
  91. package/src/lab/LabShell.less +0 -1
  92. package/src/lab/LabShell.stories.tsx +15 -0
  93. package/src/lab/LabShell.test.tsx +18 -0
  94. package/src/lab/LabShell.tsx +14 -1
  95. package/src/lab/LabSwitcher.less +1 -1
  96. package/src/lab/LabSwitcher.test.tsx +41 -0
  97. package/src/lab/LabSwitcher.tsx +30 -8
  98. package/src/lab/index.ts +1 -0
  99. package/src/layers/AGENTS.md +18 -74
  100. package/src/layers/index.ts +4 -2
  101. package/src/passthrough/weasel-ui.ts +25 -10
  102. package/src/primitives/index.ts +0 -2
  103. package/src/specimen/Specimen.tsx +42 -56
  104. package/src/state/types.ts +2 -1
  105. package/src/styles.less +4 -2
  106. package/src/theme/Interstellar.stories.tsx +8 -9
  107. package/src/theme/base.less +3 -20
  108. package/src/theme/interstellar.test.ts +6 -3
  109. package/src/theme/interstellar.theme.json +0 -56
  110. package/src/theme/interstellar.ts +2 -2
  111. package/src/trial/Trial.canvas.test.tsx +1 -1
  112. package/src/trial/Trial.tsx +30 -8
  113. package/dist/_dts/index-8LiKe3A-.d.ts +0 -410
  114. package/dist/chunk-6BUQ77ZV.js +0 -18
  115. package/dist/chunk-6BUQ77ZV.js.map +0 -1
  116. package/dist/chunk-753Y6HE6.js.map +0 -1
  117. package/dist/chunk-A2ACAGW6.js.map +0 -1
  118. package/dist/chunk-CKUKF72R.js.map +0 -1
  119. package/dist/chunk-D35PFTS7.js +0 -170
  120. package/dist/chunk-D35PFTS7.js.map +0 -1
  121. package/dist/chunk-FKLT3ITC.js +0 -590
  122. package/dist/chunk-FKLT3ITC.js.map +0 -1
  123. package/dist/chunk-KJCUERQF.js.map +0 -1
  124. package/dist/chunk-LASCBWW7.js +0 -13456
  125. package/dist/chunk-LASCBWW7.js.map +0 -1
  126. package/dist/chunk-REOBGYMC.js.map +0 -1
  127. package/dist/ui/layers/index.d.ts +0 -66
  128. package/dist/ui/layers/index.js +0 -3
  129. package/dist/ui/layers/index.js.map +0 -1
  130. package/src/lab/useSystemMode.ts +0 -30
  131. package/src/layers/LayerList.less +0 -93
  132. package/src/layers/LayerList.stories.tsx +0 -66
  133. package/src/layers/LayerList.test.tsx +0 -232
  134. package/src/layers/LayerList.tsx +0 -268
  135. package/src/primitives/Sidebar.less +0 -112
  136. package/src/primitives/Sidebar.stories.tsx +0 -38
  137. package/src/primitives/Sidebar.test.tsx +0 -74
  138. package/src/primitives/Sidebar.tsx +0 -35
  139. package/src/ui/layers/index.ts +0 -5
@@ -1,38 +1,9 @@
1
- import { ab as LayerDescriptor } from '../_dts/frac-B4hFJMiN.js';
2
- export { aa as LayerCapability } from '../_dts/frac-B4hFJMiN.js';
3
- import * as react_jsx_runtime from 'react/jsx-runtime';
1
+ export { L as LayerList, a as LayerListItem, b as LayerListProps, c as LayerMove, m as moveLayers } from '../_dts/LayerList.d-2c9yup5Y.js';
2
+ export { L as LayerCapability, a as LayerDescriptor } from '../_dts/frac-DTRq7Xpb.js';
3
+ import 'react/jsx-runtime';
4
4
  import 'react';
5
- import '../_dts/types-Db-3NNk1.js';
5
+ import '../_dts/PrefsRow.d-DFpPIeIC.js';
6
+ import '@weasel-js/theme';
6
7
  import '@weasel-js/core';
7
- import '../_dts/PrefsForm.d-DPy9I8It.js';
8
+ import '../_dts/types-B7y8hX1D.js';
8
9
  import '../_dts/types-DJ79Tg5J.js';
9
-
10
- /** A layer that may itself contain layers. A plain `LayerDescriptor` is one
11
- * of these with no children, so a flat list needs no change. */
12
- interface LayerTreeNode extends LayerDescriptor {
13
- children?: LayerTreeNode[];
14
- /** Render this node's children hidden on first paint. Ignored once
15
- * `collapsedIds` is supplied. */
16
- defaultCollapsed?: boolean;
17
- }
18
- /** Props for `<LayerList>`. */
19
- interface LayerListProps {
20
- layers: LayerTreeNode[];
21
- visibility: Record<string, boolean>;
22
- /** The whole tree, with the dragged node moved. Reordering is scoped to a
23
- * node's siblings: a drag never changes which parent a layer sits under. */
24
- onReorder: (newOrder: LayerTreeNode[]) => void;
25
- onToggle: (id: string, visible: boolean) => void;
26
- /** Ids whose children are hidden. Supplying it makes collapse controlled;
27
- * without it the list keeps its own, seeded from `defaultCollapsed`. */
28
- collapsedIds?: readonly string[];
29
- onCollapsedChange?: (ids: string[]) => void;
30
- className?: string;
31
- }
32
- /** A reorderable list of layers with per-layer visibility toggles. Layers
33
- * marked `alwaysOn` are pinned and cannot be reordered or hidden. Layers with
34
- * `children` render as an expandable subtree. */
35
- declare function LayerList({ layers, visibility, onReorder, onToggle, collapsedIds, onCollapsedChange, className, }: LayerListProps): react_jsx_runtime.JSX.Element;
36
-
37
- export { LayerDescriptor, LayerList };
38
- export type { LayerListProps, LayerTreeNode };
@@ -1,5 +1,4 @@
1
- export { LayerList } from '../chunk-D35PFTS7.js';
2
- import '../chunk-SBXNQW4G.js';
3
- import '../chunk-LASCBWW7.js';
1
+ import '../chunk-2RVCB2PT.js';
2
+ export { D as LayerList, S2 as moveLayers } from '../chunk-WUJXJC5O.js';
4
3
  //# sourceMappingURL=index.js.map
5
4
  //# sourceMappingURL=index.js.map
@@ -1,11 +1,12 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { aH as LoupePoint, aI as LoupeMode, k as ViewTransform, W as WorldFrame, a as WorldSpec, V as ViewportSize, ae as LoupeRenderArgs, ah as ResolvedLoupe } from '../_dts/frac-B4hFJMiN.js';
3
- export { a9 as LOUPE_DEFAULTS, ac as LoupeCapability, ad as LoupeDeclaration, aE as resolveLoupe } from '../_dts/frac-B4hFJMiN.js';
4
- import { c as CanvasStackSurface, C as CanvasLayerDescriptor } from '../_dts/CanvasStackContext-CMMo180l.js';
2
+ import { aH as LoupePoint, aI as LoupeMode, m as ViewTransform, W as WorldFrame, b as WorldSpec, V as ViewportSize, ae as LoupeRenderArgs, ah as ResolvedLoupe } from '../_dts/frac-DTRq7Xpb.js';
3
+ export { ab as LOUPE_DEFAULTS, ac as LoupeCapability, ad as LoupeDeclaration, aE as resolveLoupe } from '../_dts/frac-DTRq7Xpb.js';
4
+ import { c as CanvasStackSurface, C as CanvasLayerDescriptor } from '../_dts/CanvasStackContext-DQgcH1ny.js';
5
5
  import { RefObject, ReactNode } from 'react';
6
6
  import { Action } from '@weasel-js/core';
7
- import '../_dts/types-Db-3NNk1.js';
8
- import '../_dts/PrefsForm.d-DPy9I8It.js';
7
+ import '../_dts/PrefsRow.d-DFpPIeIC.js';
8
+ import '@weasel-js/theme';
9
+ import '../_dts/types-B7y8hX1D.js';
9
10
  import '../_dts/types-DJ79Tg5J.js';
10
11
 
11
12
  /** Props for `<CanvasLoupe>`. */