@weasel-js/labkit 1.0.0 → 1.0.2

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.
@@ -1,5 +1,5 @@
1
- export { LayerStack } from '../../chunk-HNXVLKBG.js';
2
- import '../../chunk-FP5LYDVX.js';
3
- import '../../chunk-XVBXYKFJ.js';
1
+ export { LayerStack } from '../../chunk-2ZRE7WGQ.js';
2
+ import '../../chunk-R4TACNW7.js';
3
+ import '../../chunk-3P56ZCCJ.js';
4
4
  //# sourceMappingURL=index.js.map
5
5
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@weasel-js/labkit",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "React widgets for building self-contained interactive lab pages",
5
5
  "license": "MIT",
6
6
  "author": "orochi235",
@@ -76,7 +76,7 @@
76
76
  "build": "tsup && npm run build:dts && npm run build:css && npm run build:fonts",
77
77
  "build:dts": "tsx scripts/build-dts.mts",
78
78
  "prepublishOnly": "npm run build",
79
- "build:css": "lessc src/styles.less dist/styles.css",
79
+ "build:css": "node scripts/build-css.mjs",
80
80
  "build:fonts": "mkdir -p dist/fonts && cp ../theme/fonts/*.woff2 dist/fonts/",
81
81
  "test": "vitest run",
82
82
  "test:watch": "vitest",
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 {
@@ -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';
@@ -1,6 +1,6 @@
1
1
  import type { Meta, StoryObj } from '@storybook/react-vite';
2
- import { useTheme } from '@weasel-js/theme/react';
3
2
  import type { TokenName } from '@weasel-js/theme';
3
+ import { useTheme } from '@weasel-js/theme/react';
4
4
  import {
5
5
  CheckboxRow,
6
6
  ColorRow,
@@ -1,5 +1,5 @@
1
- import { describe, expect, it } from 'vitest';
2
1
  import { resolveTheme } from '@weasel-js/theme';
2
+ import { describe, expect, it } from 'vitest';
3
3
  import { interstellarTheme } from './interstellar';
4
4
 
5
5
  describe('interstellarTheme', () => {
@@ -24,7 +24,6 @@ interface DemoArgs {
24
24
 
25
25
  const meta: Meta<DemoArgs> = {
26
26
  title: 'labkit/UI/Properties/PropertyPanel',
27
- component: PropertyPanel,
28
27
  argTypes: {
29
28
  title: { control: 'text' },
30
29
  pack: {