@weasel-js/labkit 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_dts/{DrawCommand-BwRCZYuo.d.ts → DrawCommand-CitWPxMY.d.ts} +8 -1
- package/dist/{chunk-HNXVLKBG.js → chunk-EXBV7A6X.js} +3 -3
- package/dist/{chunk-HNXVLKBG.js.map → chunk-EXBV7A6X.js.map} +1 -1
- package/dist/{chunk-XVBXYKFJ.js → chunk-ISEK5LXT.js} +642 -226
- package/dist/chunk-ISEK5LXT.js.map +1 -0
- package/dist/chunk-NRD3TDNQ.js +5946 -0
- package/dist/chunk-NRD3TDNQ.js.map +1 -0
- package/dist/index.js +22 -22
- package/dist/index.js.map +1 -1
- package/dist/passthrough/weasel-canvas.d.ts +29 -6
- package/dist/passthrough/weasel-canvas.js +1 -1
- package/dist/passthrough/weasel-ui.d.ts +73 -11
- package/dist/passthrough/weasel-ui.js +2 -2
- package/dist/ui/layers/index.js +3 -3
- package/package.json +1 -1
- package/src/lab/Lab.tsx +2 -2
- package/src/lab/LabShell.tsx +1 -1
- package/src/passthrough/weasel-ui.ts +4 -0
- package/src/theme/Interstellar.stories.tsx +1 -1
- package/src/theme/interstellar.test.ts +1 -1
- package/src/ui/properties/PropertyPanel.stories.tsx +0 -1
- package/dist/chunk-FP5LYDVX.js +0 -6039
- package/dist/chunk-FP5LYDVX.js.map +0 -1
- package/dist/chunk-XVBXYKFJ.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { Ref } from 'react';
|
|
3
|
-
import { N as Node, V as View, D as DrawCommand, S as Scene, B as Bounds, a as ViewportDims, P as PathDrawCommand } from '../_dts/DrawCommand-
|
|
3
|
+
import { N as Node, V as View, D as DrawCommand, S as Scene, B as Bounds, a as ViewportDims, P as PathDrawCommand } from '../_dts/DrawCommand-CitWPxMY.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* `renderSceneToCanvas` — substrate for detached, read-only scene views
|
|
@@ -55,6 +55,10 @@ interface RenderSceneToCanvasArgs<TData, TLayer extends string, TPose> {
|
|
|
55
55
|
* minimap's visible-window indicator. Wrapped in the same view transform
|
|
56
56
|
* as scene commands. */
|
|
57
57
|
extraCommands?: DrawCommand[];
|
|
58
|
+
/** Optional per-id alpha multiplier, mirroring `<SceneCanvas>`'s scene-slot
|
|
59
|
+
* `alphaFor`. Pass the same function the main canvas uses to keep a
|
|
60
|
+
* scoping-dim treatment consistent across both. Defaults to `() => 1`. */
|
|
61
|
+
alphaFor?: (id: string) => number;
|
|
58
62
|
/** Optional device-pixel ratio. Defaults to `window.devicePixelRatio || 1`
|
|
59
63
|
* when available, otherwise 1. Tests typically pin this to 1 or 2. */
|
|
60
64
|
dpr?: number;
|
|
@@ -62,16 +66,27 @@ interface RenderSceneToCanvasArgs<TData, TLayer extends string, TPose> {
|
|
|
62
66
|
/**
|
|
63
67
|
* Build the DrawCommand list that `renderSceneToCanvas` would dispatch.
|
|
64
68
|
*
|
|
65
|
-
* Pure — no GL, no DOM, no side effects.
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
* so the output is in screen
|
|
69
|
+
* Pure — no GL, no DOM, no side effects. Walks the scene through
|
|
70
|
+
* `buildSceneTree` — the same walk `<SceneCanvas>`'s `buildSceneLayer` uses —
|
|
71
|
+
* appends any `extraCommands`, and wraps the result in a single
|
|
72
|
+
* `{ kind: 'group', transform: viewToMat3(view) }` so the output is in screen
|
|
73
|
+
* space. Sharing the walk is what keeps hidden layers unpainted and container
|
|
74
|
+
* clips applied here; a hand-rolled `renderOrder()` loop silently dropped both.
|
|
75
|
+
*
|
|
76
|
+
* Each node's commands additionally go through `wrapNodeOutput` — pose
|
|
77
|
+
* rotation, then the `alphaFor` multiplier — exactly as `buildSceneLayer`
|
|
78
|
+
* does, so a `drawOne` shared between the two paints the same thing in both.
|
|
79
|
+
* A `drawOne` that rotates its own output will therefore rotate twice here;
|
|
80
|
+
* emit unrotated geometry and let the pose drive it.
|
|
81
|
+
*
|
|
82
|
+
* Output shape follows `buildSceneTree`: one group per **visible** layer, in
|
|
83
|
+
* scene-layer order, each holding one group per node on that layer.
|
|
69
84
|
*
|
|
70
85
|
* Exported for tests and for callers that want to render into something
|
|
71
86
|
* other than a real `<canvas>` (e.g. an offscreen renderer or a
|
|
72
87
|
* snapshot fixture).
|
|
73
88
|
*/
|
|
74
|
-
declare function buildSceneViewCommands<TData, TLayer extends string, TPose>(scene: Scene<TData, TLayer, TPose>, view: View, drawOne: SceneViewDrawOne<TData, TLayer, TPose>, extraCommands?: ReadonlyArray<DrawCommand
|
|
89
|
+
declare function buildSceneViewCommands<TData, TLayer extends string, TPose>(scene: Scene<TData, TLayer, TPose>, view: View, drawOne: SceneViewDrawOne<TData, TLayer, TPose>, extraCommands?: ReadonlyArray<DrawCommand>, alphaFor?: (id: string) => number): DrawCommand[];
|
|
75
90
|
/**
|
|
76
91
|
* Render one frame of `scene` at `view` into `canvas`. See module docstring
|
|
77
92
|
* for the design context.
|
|
@@ -110,6 +125,10 @@ interface SceneViewCanvasProps<TData, TLayer extends string, TPose> {
|
|
|
110
125
|
* indicator; available to other consumers that want to overlay a
|
|
111
126
|
* world-space annotation. */
|
|
112
127
|
extraCommands?: ReadonlyArray<DrawCommand>;
|
|
128
|
+
/** Optional per-id alpha multiplier, mirroring `<SceneCanvas>`'s scene-slot
|
|
129
|
+
* `alphaFor`. Pass the same function the main canvas uses to keep a
|
|
130
|
+
* scoping-dim treatment consistent across both. Defaults to `() => 1`. */
|
|
131
|
+
alphaFor?: (id: string) => number;
|
|
113
132
|
/** Optional CSS class for sizing / positioning the `<canvas>`. The kit
|
|
114
133
|
* does not emit inline styles for layout — use a class. */
|
|
115
134
|
className?: string;
|
|
@@ -236,6 +255,10 @@ interface MinimapCanvasProps<TData, TLayer extends string, TPose> {
|
|
|
236
255
|
/** Pose → AABB. Defaults to identity (`pose as Bounds`), matching
|
|
237
256
|
* `sceneAdapter` / `useSelectTool`. */
|
|
238
257
|
poseBounds?: (pose: TPose) => Bounds;
|
|
258
|
+
/** Optional per-id alpha multiplier, mirroring `<SceneCanvas>`'s scene-slot
|
|
259
|
+
* `alphaFor`. Pass the same function the main canvas uses so a
|
|
260
|
+
* scoping-dim treatment shows up in the minimap too. */
|
|
261
|
+
alphaFor?: (id: string) => number;
|
|
239
262
|
/** Visual tuning of the indicator stroke. */
|
|
240
263
|
indicatorStyle?: IndicatorStyle;
|
|
241
264
|
/** CSS class for sizing / positioning the canvas. */
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { FALLBACK_FIT_VIEW, MinimapCanvas, SceneViewCanvas, buildSceneViewCommands, computeFitView2 as computeFitView, computeIndicatorCommand, renderSceneToCanvas } from '../chunk-
|
|
1
|
+
export { FALLBACK_FIT_VIEW, MinimapCanvas, SceneViewCanvas, buildSceneViewCommands, computeFitView2 as computeFitView, computeIndicatorCommand, renderSceneToCanvas } from '../chunk-ISEK5LXT.js';
|
|
2
2
|
//# sourceMappingURL=weasel-canvas.js.map
|
|
3
3
|
//# sourceMappingURL=weasel-canvas.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as react from 'react';
|
|
3
|
-
import { ReactNode, CSSProperties, ButtonHTMLAttributes, ReactElement, MutableRefObject, PointerEvent as PointerEvent$1, KeyboardEvent, RefCallback } from 'react';
|
|
4
|
-
import { V as View, D as DrawCommand, O as Op, b as NodeId, c as Path, S as Scene, H as History, B as Bounds } from '../_dts/DrawCommand-
|
|
3
|
+
import { ReactNode, CSSProperties, ButtonHTMLAttributes, ReactElement, MutableRefObject, PointerEvent as PointerEvent$1, KeyboardEvent, RefCallback, RefObject } from 'react';
|
|
4
|
+
import { V as View, D as DrawCommand, O as Op, b as NodeId, c as Path, S as Scene, H as History, B as Bounds } from '../_dts/DrawCommand-CitWPxMY.js';
|
|
5
5
|
import { TextFieldProps, ValidationResult, CheckboxProps as CheckboxProps$1, SwitchProps as SwitchProps$1, TabProps as TabProps$1, TabListProps as TabListProps$1, TabPanelProps as TabPanelProps$1, TabsProps as TabsProps$1, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, NumberFieldProps as NumberFieldProps$1, SelectProps as SelectProps$1, ListBoxItemProps, ComboBoxProps as ComboBoxProps$1, SliderProps as SliderProps$1, ModalOverlayProps, DialogProps as DialogProps$1 } from 'react-aria-components';
|
|
6
6
|
|
|
7
7
|
/**
|
|
@@ -1854,17 +1854,28 @@ type ModSpec = Partial<{
|
|
|
1854
1854
|
mod: boolean | 'optional';
|
|
1855
1855
|
shift: boolean | 'optional';
|
|
1856
1856
|
}>;
|
|
1857
|
+
/** The predicate form of {@link TargetSpec}. `hit` is the raw target
|
|
1858
|
+
* (affordance for drag, `e.target` otherwise); `bodyTarget` is the optional
|
|
1859
|
+
* body-class string ('empty' | 'selected-body' | 'unselected-body') when
|
|
1860
|
+
* `classifyTarget` is wired. Predicates that only need one of the two can
|
|
1861
|
+
* ignore the other. */
|
|
1862
|
+
interface TargetPredicate {
|
|
1863
|
+
(hit: unknown, bodyTarget?: string): boolean;
|
|
1864
|
+
/** `false` declares that the predicate reads `bodyTarget` only. An
|
|
1865
|
+
* exclusive affordance claim bars bindings whose target doesn't consult
|
|
1866
|
+
* the hit; a body predicate that declares nothing looks like it does. */
|
|
1867
|
+
readsAffordance?: boolean;
|
|
1868
|
+
}
|
|
1857
1869
|
/** Target selector for click and drag gesture specs. String forms are sugar
|
|
1858
1870
|
* for the kit-owned object-kind registry (TODO.md Tier 1 follow-up); until
|
|
1859
1871
|
* that ships, consumers can pass `{ kindOf: predicate }` to classify hits
|
|
1860
|
-
* themselves.
|
|
1872
|
+
* themselves.
|
|
1873
|
+
*
|
|
1874
|
+
* Adding a form here is a compile error in `parseTargetSpec` until
|
|
1875
|
+
* `TargetSpecForm` grows a matching variant — which is in turn a compile
|
|
1876
|
+
* error at every site that switches on one. */
|
|
1861
1877
|
type TargetSpec = 'empty' | 'selected-body' | 'unselected-body' | `kind:${string}` | `kind:${string}:selected` | `affordance:${string}` | {
|
|
1862
|
-
|
|
1863
|
-
* `e.target` otherwise); `bodyTarget` is the optional body-class
|
|
1864
|
-
* string ('empty' | 'selected-body' | 'unselected-body') when
|
|
1865
|
-
* `classifyTarget` is wired. Predicates that only need one of the
|
|
1866
|
-
* two can ignore the other. */
|
|
1867
|
-
kindOf: (hit: unknown, bodyTarget?: string) => boolean;
|
|
1878
|
+
kindOf: TargetPredicate;
|
|
1868
1879
|
};
|
|
1869
1880
|
/** Phase qualifier on a gesture spec. Restricts when the spec matches based
|
|
1870
1881
|
* on per-tool gesture-lifecycle state.
|
|
@@ -4428,6 +4439,57 @@ interface ReorderDragHandlers {
|
|
|
4428
4439
|
}
|
|
4429
4440
|
declare function useReorderDragList(opts: UseReorderDragListOptions): ReorderDragHandlers;
|
|
4430
4441
|
|
|
4442
|
+
/** The only thing the hook needs to know about a bar's items: which are
|
|
4443
|
+
* skipped by arrow navigation. */
|
|
4444
|
+
type RovingItem = {
|
|
4445
|
+
disabled?: boolean;
|
|
4446
|
+
};
|
|
4447
|
+
type UseRovingTabIndexOptions = {
|
|
4448
|
+
/** In the same order as the elements carrying `itemClassName`. */
|
|
4449
|
+
items: readonly RovingItem[];
|
|
4450
|
+
/** Class on the focusable element of each item, inside the container the
|
|
4451
|
+
* returned `rootRef` is attached to. Their DOM order must match `items`. */
|
|
4452
|
+
itemClassName: string;
|
|
4453
|
+
/** Index that carries `tabIndex=0`. Defaults to the first enabled item; a
|
|
4454
|
+
* radiogroup-style bar passes its selected index so Tab lands on the
|
|
4455
|
+
* current value. */
|
|
4456
|
+
tabStopIndex?: number;
|
|
4457
|
+
/** Called with the new index as arrow/Home/End focus moves, before focus
|
|
4458
|
+
* moves. This is where a selection-follows-focus bar commits the value. */
|
|
4459
|
+
onNavigate?: (index: number) => void;
|
|
4460
|
+
/** Space/Enter on the item at `index`. When omitted the keypress is left
|
|
4461
|
+
* alone, which on a native `<button>` produces an ordinary click. */
|
|
4462
|
+
onActivate?: (index: number) => void;
|
|
4463
|
+
};
|
|
4464
|
+
type RovingTabIndex<T extends HTMLElement = HTMLDivElement> = {
|
|
4465
|
+
/** Attach to the container element that holds the items. */
|
|
4466
|
+
rootRef: RefObject<T | null>;
|
|
4467
|
+
/** `tabIndex` value for the item at `index`. */
|
|
4468
|
+
tabIndexFor: (index: number) => 0 | -1;
|
|
4469
|
+
/** `onKeyDown` for the item at `index`. */
|
|
4470
|
+
onKeyDown: (index: number) => (e: KeyboardEvent<HTMLElement>) => void;
|
|
4471
|
+
};
|
|
4472
|
+
/**
|
|
4473
|
+
* Roving tabindex for a bar of items: one item is in the tab order, and the
|
|
4474
|
+
* arrow keys move focus among the rest, skipping disabled ones and wrapping
|
|
4475
|
+
* at both ends. Home and End go to the first and last enabled item. Both axes
|
|
4476
|
+
* navigate, so the same bar works laid out either way.
|
|
4477
|
+
*
|
|
4478
|
+
* Backs `ActionsBar`, `OptionsBar`, and `ToggleBar`.
|
|
4479
|
+
*
|
|
4480
|
+
* **When a bar should not use this.** Only when the bar owns its items. A
|
|
4481
|
+
* container of arbitrary compound controls — a number field, a select, a
|
|
4482
|
+
* color field — must leave the arrow keys alone, because those controls edit
|
|
4483
|
+
* their own value with them; taking the arrows over would break the control
|
|
4484
|
+
* to navigate between controls. `ToolOptionsBar` is that case and keeps plain
|
|
4485
|
+
* DOM tab order. A bar whose items are all simple buttons is the case this
|
|
4486
|
+
* hook is for.
|
|
4487
|
+
*
|
|
4488
|
+
* With every item disabled there is no tab stop and the bar drops out of the
|
|
4489
|
+
* tab order entirely.
|
|
4490
|
+
*/
|
|
4491
|
+
declare function useRovingTabIndex<T extends HTMLElement = HTMLDivElement>(options: UseRovingTabIndexOptions): RovingTabIndex<T>;
|
|
4492
|
+
|
|
4431
4493
|
/**
|
|
4432
4494
|
* Display-formatter for numbers. Use this anywhere a number is shown to
|
|
4433
4495
|
* a user. The whole point: negative values get prefixed with the real
|
|
@@ -4441,5 +4503,5 @@ declare function useReorderDragList(opts: UseReorderDragListOptions): ReorderDra
|
|
|
4441
4503
|
declare const MINUS_SIGN = "\u2212";
|
|
4442
4504
|
declare function formatNumber(value: number, options?: Intl.NumberFormatOptions): string;
|
|
4443
4505
|
|
|
4444
|
-
export { ActionBar, ActionsBar, Badge, Button, Checkbox, ComboBox, ComboBoxItem, CurveEditor, DataGrid, Dialog, EDGE_PROFILES, Field, Input, KeyCap, KeySequence, MINUS_SIGN, NumberField, OptionsBar, Plot2D, PointPlotter, Powerline, Radio, RadioGroup, RangeSlider, Select, SelectItem, Sidebar, SidebarPanel, Slider, Switch, Tab, TabList, TabPanel, Tabs, ToggleBar, ToolButton, ToolGroup, ToolPalette, chromaAt, detectPlatform, dlog, fieldClasses, formatNumber, formatShortcut, formatShortcutParts, inferKeycapKind, isDebugEnabled, keyGlyph, keySpecFromKey, keySpecsFromMods, oklchToHex, paintGradientTrack, useReorderDragList };
|
|
4445
|
-
export type { ActionBarProps, ActionsBarItem, ActionsBarProps, ActionsBarSize, ActionsBarVariant, AddPointMode, AnchorRenderProps, AxesSettings, BadgeProps, BadgeShape, BadgeSize, BadgeTone, BadgeVariant, BoundsCtx, BuiltInEdgeName, ButtonProps, ButtonSize, ButtonVariant, CheckboxProps, ChromaCurve, ChromaCurvePoint, ComboBoxItemProps, ComboBoxOption, ComboBoxProps, ControlPoint, CurveDomain, CurveEditorProps, DataGridColumn, DataGridProps, DialogProps, EdgeCap, EdgeProfile, EndpointMode, FieldOrientation, FieldProps, FillSettings, GradientTrackOpts, GridSettings, InputProps, InterpolationMode, KeyCapProps, KeyCapVariant, KeySequenceProps, KeySpec$1 as KeySpec, KeycapKind, LayerListItem, LogicalMod, LogicalModSpec, NumberFieldProps, OptionsBarItem, OptionsBarProps, OptionsBarSize, OptionsBarVariant, Platform, Plot2DCoords, Plot2DHandle, Plot2DProps, PointPlotterProps, PowerlineProps, PowerlineSegment, RadioGroupProps, RadioProps, RangeSliderProps, ReorderDragHandlers, ReorderDragState, SelectItemProps, SelectOption, SelectProps, SidebarPanelProps, SidebarProps, SliderProps, SwitchProps, TabListProps, TabPanelProps, TabProps, TabsProps, Thumb, ThumbRenderCtx, ThumbShape, ToggleBarItem, ToggleBarProps, ToggleBarSize, ToggleBarVariant, ToolButtonProps, ToolGroupProps, ToolPaletteProps, TrackCtx, UseReorderDragListOptions };
|
|
4506
|
+
export { ActionBar, ActionsBar, Badge, Button, Checkbox, ComboBox, ComboBoxItem, CurveEditor, DataGrid, Dialog, EDGE_PROFILES, Field, Input, KeyCap, KeySequence, MINUS_SIGN, NumberField, OptionsBar, Plot2D, PointPlotter, Powerline, Radio, RadioGroup, RangeSlider, Select, SelectItem, Sidebar, SidebarPanel, Slider, Switch, Tab, TabList, TabPanel, Tabs, ToggleBar, ToolButton, ToolGroup, ToolPalette, chromaAt, detectPlatform, dlog, fieldClasses, formatNumber, formatShortcut, formatShortcutParts, inferKeycapKind, isDebugEnabled, keyGlyph, keySpecFromKey, keySpecsFromMods, oklchToHex, paintGradientTrack, useReorderDragList, useRovingTabIndex };
|
|
4507
|
+
export type { ActionBarProps, ActionsBarItem, ActionsBarProps, ActionsBarSize, ActionsBarVariant, AddPointMode, AnchorRenderProps, AxesSettings, BadgeProps, BadgeShape, BadgeSize, BadgeTone, BadgeVariant, BoundsCtx, BuiltInEdgeName, ButtonProps, ButtonSize, ButtonVariant, CheckboxProps, ChromaCurve, ChromaCurvePoint, ComboBoxItemProps, ComboBoxOption, ComboBoxProps, ControlPoint, CurveDomain, CurveEditorProps, DataGridColumn, DataGridProps, DialogProps, EdgeCap, EdgeProfile, EndpointMode, FieldOrientation, FieldProps, FillSettings, GradientTrackOpts, GridSettings, InputProps, InterpolationMode, KeyCapProps, KeyCapVariant, KeySequenceProps, KeySpec$1 as KeySpec, KeycapKind, LayerListItem, LogicalMod, LogicalModSpec, NumberFieldProps, OptionsBarItem, OptionsBarProps, OptionsBarSize, OptionsBarVariant, Platform, Plot2DCoords, Plot2DHandle, Plot2DProps, PointPlotterProps, PowerlineProps, PowerlineSegment, RadioGroupProps, RadioProps, RangeSliderProps, ReorderDragHandlers, ReorderDragState, RovingItem, RovingTabIndex, SelectItemProps, SelectOption, SelectProps, SidebarPanelProps, SidebarProps, SliderProps, SwitchProps, TabListProps, TabPanelProps, TabProps, TabsProps, Thumb, ThumbRenderCtx, ThumbShape, ToggleBarItem, ToggleBarProps, ToggleBarSize, ToggleBarVariant, ToolButtonProps, ToolGroupProps, ToolPaletteProps, TrackCtx, UseReorderDragListOptions, UseRovingTabIndexOptions };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { m as ActionBar,
|
|
2
|
-
import '../chunk-
|
|
1
|
+
export { m as ActionBar, r3 as ActionsBar, Ft as Badge, a as Button, o3 as Checkbox, p4 as ComboBox, m2 as ComboBoxItem, F as CurveEditor, l as DataGrid, c2 as Dialog, qe as EDGE_PROFILES, n as Field, u2 as Input, s2 as KeyCap, c as KeySequence, a2 as MINUS_SIGN, f3 as NumberField, r2 as OptionsBar, _ as Plot2D, n4 as PointPlotter, r4 as Powerline, u3 as Radio, l2 as RadioGroup, l3 as RangeSlider, p3 as Select, h as SelectItem, n2 as Sidebar, o4 as SidebarPanel, f2 as Slider, a4 as Switch, c3 as Tab, s3 as TabList, l4 as TabPanel, o6 as Tabs, r as ToggleBar, o5 as ToolButton, n3 as ToolGroup, _2 as ToolPalette, ze as chromaAt, u as detectPlatform, p as dlog, r5 as fieldClasses, o2 as formatNumber, d2 as formatShortcut, u4 as formatShortcutParts, o as inferKeycapKind, f as isDebugEnabled, e as keyGlyph, p2 as keySpecFromKey, d as keySpecsFromMods, Re as oklchToHex, p5 as paintGradientTrack, s as useReorderDragList, a3 as useRovingTabIndex } from '../chunk-NRD3TDNQ.js';
|
|
2
|
+
import '../chunk-ISEK5LXT.js';
|
|
3
3
|
//# sourceMappingURL=weasel-ui.js.map
|
|
4
4
|
//# sourceMappingURL=weasel-ui.js.map
|
package/dist/ui/layers/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { LayerStack } from '../../chunk-
|
|
2
|
-
import '../../chunk-
|
|
3
|
-
import '../../chunk-
|
|
1
|
+
export { LayerStack } from '../../chunk-EXBV7A6X.js';
|
|
2
|
+
import '../../chunk-NRD3TDNQ.js';
|
|
3
|
+
import '../../chunk-ISEK5LXT.js';
|
|
4
4
|
//# sourceMappingURL=index.js.map
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
package/src/lab/Lab.tsx
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
|
+
import { ThemeProvider } from '@weasel-js/theme/react';
|
|
1
2
|
import { type CSSProperties, type ReactNode, useEffect, useMemo, useRef } from 'react';
|
|
2
3
|
import { useStore } from 'zustand/react';
|
|
3
|
-
import { ThemeProvider } from '@weasel-js/theme/react';
|
|
4
4
|
import type { Instrument } from '../instrument/types';
|
|
5
5
|
import { noneAdapter } from '../state/adapters';
|
|
6
6
|
import { LabStoreContext } from '../state/context';
|
|
7
7
|
import { createLabStore, type LabStore } from '../state/store';
|
|
8
8
|
import type { LabMode, StorageAdapter, WorkspaceRecord } from '../state/types';
|
|
9
9
|
import { interstellarTheme } from '../theme/interstellar';
|
|
10
|
-
import { useResolvedMode } from './useSystemMode';
|
|
11
10
|
import { Workspace } from '../workspace/Workspace';
|
|
12
11
|
import {
|
|
13
12
|
addWorkspace as addWorkspaceOp,
|
|
@@ -17,6 +16,7 @@ import {
|
|
|
17
16
|
} from '../workspace/workspaceOps';
|
|
18
17
|
import { LabContext, type LabContextValue } from './LabContext';
|
|
19
18
|
import { LabShell } from './LabShell';
|
|
19
|
+
import { useResolvedMode } from './useSystemMode';
|
|
20
20
|
import { WorkspaceGrid } from './WorkspaceGrid';
|
|
21
21
|
|
|
22
22
|
export interface LabProps {
|
package/src/lab/LabShell.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
2
1
|
import { ThemeProvider, useThemeOptional } from '@weasel-js/theme/react';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
3
|
import type { LabMode } from '../state/types';
|
|
4
4
|
import { interstellarTheme } from '../theme/interstellar';
|
|
5
5
|
import { useResolvedMode } from './useSystemMode';
|
|
@@ -109,6 +109,8 @@ export {
|
|
|
109
109
|
type RangeSliderProps,
|
|
110
110
|
type ReorderDragHandlers,
|
|
111
111
|
type ReorderDragState,
|
|
112
|
+
type RovingItem,
|
|
113
|
+
type RovingTabIndex,
|
|
112
114
|
Select,
|
|
113
115
|
SelectItem,
|
|
114
116
|
type SelectItemProps,
|
|
@@ -146,5 +148,7 @@ export {
|
|
|
146
148
|
type ToolPaletteProps,
|
|
147
149
|
type TrackCtx,
|
|
148
150
|
type UseReorderDragListOptions,
|
|
151
|
+
type UseRovingTabIndexOptions,
|
|
149
152
|
useReorderDragList,
|
|
153
|
+
useRovingTabIndex,
|
|
150
154
|
} from '@weasel-js/ui';
|