@smoove/studio 0.1.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.
Files changed (276) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +60 -0
  3. package/dist/components/brand/brand.d.ts +9 -0
  4. package/dist/components/brand/brand.d.ts.map +1 -0
  5. package/dist/components/brand/brand.js +11 -0
  6. package/dist/components/brand/brand.js.map +1 -0
  7. package/dist/components/button/button.d.ts +21 -0
  8. package/dist/components/button/button.d.ts.map +1 -0
  9. package/dist/components/button/button.js +20 -0
  10. package/dist/components/button/button.js.map +1 -0
  11. package/dist/components/button/icon-button.d.ts +27 -0
  12. package/dist/components/button/icon-button.d.ts.map +1 -0
  13. package/dist/components/button/icon-button.js +19 -0
  14. package/dist/components/button/icon-button.js.map +1 -0
  15. package/dist/components/header/header-title.d.ts +8 -0
  16. package/dist/components/header/header-title.d.ts.map +1 -0
  17. package/dist/components/header/header-title.js +7 -0
  18. package/dist/components/header/header-title.js.map +1 -0
  19. package/dist/components/header/header.d.ts +7 -0
  20. package/dist/components/header/header.d.ts.map +1 -0
  21. package/dist/components/header/header.js +7 -0
  22. package/dist/components/header/header.js.map +1 -0
  23. package/dist/components/header/zoom.d.ts +3 -0
  24. package/dist/components/header/zoom.d.ts.map +1 -0
  25. package/dist/components/header/zoom.js +16 -0
  26. package/dist/components/header/zoom.js.map +1 -0
  27. package/dist/components/icon/icon.d.ts +11 -0
  28. package/dist/components/icon/icon.d.ts.map +1 -0
  29. package/dist/components/icon/icon.js +7 -0
  30. package/dist/components/icon/icon.js.map +1 -0
  31. package/dist/components/icon/paths.d.ts +47 -0
  32. package/dist/components/icon/paths.d.ts.map +1 -0
  33. package/dist/components/icon/paths.js +54 -0
  34. package/dist/components/icon/paths.js.map +1 -0
  35. package/dist/components/left-panel/library.d.ts +8 -0
  36. package/dist/components/left-panel/library.d.ts.map +1 -0
  37. package/dist/components/left-panel/library.js +49 -0
  38. package/dist/components/left-panel/library.js.map +1 -0
  39. package/dist/components/left-panel/sidebar-group.d.ts +12 -0
  40. package/dist/components/left-panel/sidebar-group.d.ts.map +1 -0
  41. package/dist/components/left-panel/sidebar-group.js +11 -0
  42. package/dist/components/left-panel/sidebar-group.js.map +1 -0
  43. package/dist/components/left-panel/sidebar-item.d.ts +17 -0
  44. package/dist/components/left-panel/sidebar-item.d.ts.map +1 -0
  45. package/dist/components/left-panel/sidebar-item.js +12 -0
  46. package/dist/components/left-panel/sidebar-item.js.map +1 -0
  47. package/dist/components/left-panel/sidebar.d.ts +8 -0
  48. package/dist/components/left-panel/sidebar.d.ts.map +1 -0
  49. package/dist/components/left-panel/sidebar.js +8 -0
  50. package/dist/components/left-panel/sidebar.js.map +1 -0
  51. package/dist/components/primitives/dialog.d.ts +33 -0
  52. package/dist/components/primitives/dialog.d.ts.map +1 -0
  53. package/dist/components/primitives/dialog.js +30 -0
  54. package/dist/components/primitives/dialog.js.map +1 -0
  55. package/dist/components/primitives/menu.d.ts +25 -0
  56. package/dist/components/primitives/menu.d.ts.map +1 -0
  57. package/dist/components/primitives/menu.js +31 -0
  58. package/dist/components/primitives/menu.js.map +1 -0
  59. package/dist/components/primitives/number-field.d.ts +12 -0
  60. package/dist/components/primitives/number-field.d.ts.map +1 -0
  61. package/dist/components/primitives/number-field.js +7 -0
  62. package/dist/components/primitives/number-field.js.map +1 -0
  63. package/dist/components/primitives/portal-context.d.ts +9 -0
  64. package/dist/components/primitives/portal-context.d.ts.map +1 -0
  65. package/dist/components/primitives/portal-context.js +10 -0
  66. package/dist/components/primitives/portal-context.js.map +1 -0
  67. package/dist/components/primitives/select.d.ts +14 -0
  68. package/dist/components/primitives/select.d.ts.map +1 -0
  69. package/dist/components/primitives/select.js +11 -0
  70. package/dist/components/primitives/select.js.map +1 -0
  71. package/dist/components/primitives/slider.d.ts +10 -0
  72. package/dist/components/primitives/slider.d.ts.map +1 -0
  73. package/dist/components/primitives/slider.js +7 -0
  74. package/dist/components/primitives/slider.js.map +1 -0
  75. package/dist/components/primitives/switch.d.ts +5 -0
  76. package/dist/components/primitives/switch.d.ts.map +1 -0
  77. package/dist/components/primitives/switch.js +6 -0
  78. package/dist/components/primitives/switch.js.map +1 -0
  79. package/dist/components/primitives/tabs.d.ts +23 -0
  80. package/dist/components/primitives/tabs.d.ts.map +1 -0
  81. package/dist/components/primitives/tabs.js +17 -0
  82. package/dist/components/primitives/tabs.js.map +1 -0
  83. package/dist/components/primitives/tooltip.d.ts +9 -0
  84. package/dist/components/primitives/tooltip.d.ts.map +1 -0
  85. package/dist/components/primitives/tooltip.js +11 -0
  86. package/dist/components/primitives/tooltip.js.map +1 -0
  87. package/dist/components/render/export-frame-dialog.d.ts +8 -0
  88. package/dist/components/render/export-frame-dialog.d.ts.map +1 -0
  89. package/dist/components/render/export-frame-dialog.js +60 -0
  90. package/dist/components/render/export-frame-dialog.js.map +1 -0
  91. package/dist/components/render/render-dialog.d.ts +8 -0
  92. package/dist/components/render/render-dialog.d.ts.map +1 -0
  93. package/dist/components/render/render-dialog.js +95 -0
  94. package/dist/components/render/render-dialog.js.map +1 -0
  95. package/dist/components/render/render-queue.d.ts +5 -0
  96. package/dist/components/render/render-queue.d.ts.map +1 -0
  97. package/dist/components/render/render-queue.js +40 -0
  98. package/dist/components/render/render-queue.js.map +1 -0
  99. package/dist/components/right-panel/panel-handle.d.ts +3 -0
  100. package/dist/components/right-panel/panel-handle.d.ts.map +1 -0
  101. package/dist/components/right-panel/panel-handle.js +9 -0
  102. package/dist/components/right-panel/panel-handle.js.map +1 -0
  103. package/dist/components/right-panel/panel-tabs.d.ts +3 -0
  104. package/dist/components/right-panel/panel-tabs.d.ts.map +1 -0
  105. package/dist/components/right-panel/panel-tabs.js +26 -0
  106. package/dist/components/right-panel/panel-tabs.js.map +1 -0
  107. package/dist/components/right-panel/panel.d.ts +8 -0
  108. package/dist/components/right-panel/panel.d.ts.map +1 -0
  109. package/dist/components/right-panel/panel.js +16 -0
  110. package/dist/components/right-panel/panel.js.map +1 -0
  111. package/dist/components/schema-form/field.d.ts +9 -0
  112. package/dist/components/schema-form/field.d.ts.map +1 -0
  113. package/dist/components/schema-form/field.js +102 -0
  114. package/dist/components/schema-form/field.js.map +1 -0
  115. package/dist/components/schema-form/schema-form.d.ts +3 -0
  116. package/dist/components/schema-form/schema-form.d.ts.map +1 -0
  117. package/dist/components/schema-form/schema-form.js +18 -0
  118. package/dist/components/schema-form/schema-form.js.map +1 -0
  119. package/dist/components/stage/stage.d.ts +12 -0
  120. package/dist/components/stage/stage.d.ts.map +1 -0
  121. package/dist/components/stage/stage.js +103 -0
  122. package/dist/components/stage/stage.js.map +1 -0
  123. package/dist/components/studio/features.d.ts +4 -0
  124. package/dist/components/studio/features.d.ts.map +1 -0
  125. package/dist/components/studio/features.js +18 -0
  126. package/dist/components/studio/features.js.map +1 -0
  127. package/dist/components/studio/layout.d.ts +19 -0
  128. package/dist/components/studio/layout.d.ts.map +1 -0
  129. package/dist/components/studio/layout.js +17 -0
  130. package/dist/components/studio/layout.js.map +1 -0
  131. package/dist/components/studio/studio-context.d.ts +53 -0
  132. package/dist/components/studio/studio-context.d.ts.map +1 -0
  133. package/dist/components/studio/studio-context.js +3 -0
  134. package/dist/components/studio/studio-context.js.map +1 -0
  135. package/dist/components/studio/studio.d.ts +21 -0
  136. package/dist/components/studio/studio.d.ts.map +1 -0
  137. package/dist/components/studio/studio.js +38 -0
  138. package/dist/components/studio/studio.js.map +1 -0
  139. package/dist/components/timeline/layered-body.d.ts +8 -0
  140. package/dist/components/timeline/layered-body.d.ts.map +1 -0
  141. package/dist/components/timeline/layered-body.js +75 -0
  142. package/dist/components/timeline/layered-body.js.map +1 -0
  143. package/dist/components/timeline/region-handles.d.ts +8 -0
  144. package/dist/components/timeline/region-handles.d.ts.map +1 -0
  145. package/dist/components/timeline/region-handles.js +13 -0
  146. package/dist/components/timeline/region-handles.js.map +1 -0
  147. package/dist/components/timeline/ruler.d.ts +7 -0
  148. package/dist/components/timeline/ruler.d.ts.map +1 -0
  149. package/dist/components/timeline/ruler.js +19 -0
  150. package/dist/components/timeline/ruler.js.map +1 -0
  151. package/dist/components/timeline/scrubber.d.ts +6 -0
  152. package/dist/components/timeline/scrubber.d.ts.map +1 -0
  153. package/dist/components/timeline/scrubber.js +25 -0
  154. package/dist/components/timeline/scrubber.js.map +1 -0
  155. package/dist/components/timeline/timeline-header.d.ts +3 -0
  156. package/dist/components/timeline/timeline-header.d.ts.map +1 -0
  157. package/dist/components/timeline/timeline-header.js +36 -0
  158. package/dist/components/timeline/timeline-header.js.map +1 -0
  159. package/dist/components/timeline/timeline.d.ts +5 -0
  160. package/dist/components/timeline/timeline.d.ts.map +1 -0
  161. package/dist/components/timeline/timeline.js +16 -0
  162. package/dist/components/timeline/timeline.js.map +1 -0
  163. package/dist/components/timeline/transport.d.ts +5 -0
  164. package/dist/components/timeline/transport.d.ts.map +1 -0
  165. package/dist/components/timeline/transport.js +21 -0
  166. package/dist/components/timeline/transport.js.map +1 -0
  167. package/dist/components/timeline/use-scrub-surface.d.ts +20 -0
  168. package/dist/components/timeline/use-scrub-surface.d.ts.map +1 -0
  169. package/dist/components/timeline/use-scrub-surface.js +56 -0
  170. package/dist/components/timeline/use-scrub-surface.js.map +1 -0
  171. package/dist/components/toasts/toasts.d.ts +4 -0
  172. package/dist/components/toasts/toasts.d.ts.map +1 -0
  173. package/dist/components/toasts/toasts.js +22 -0
  174. package/dist/components/toasts/toasts.js.map +1 -0
  175. package/dist/hooks/use-composition.d.ts +10 -0
  176. package/dist/hooks/use-composition.d.ts.map +1 -0
  177. package/dist/hooks/use-composition.js +13 -0
  178. package/dist/hooks/use-composition.js.map +1 -0
  179. package/dist/hooks/use-layers.d.ts +9 -0
  180. package/dist/hooks/use-layers.d.ts.map +1 -0
  181. package/dist/hooks/use-layers.js +34 -0
  182. package/dist/hooks/use-layers.js.map +1 -0
  183. package/dist/hooks/use-playback.d.ts +15 -0
  184. package/dist/hooks/use-playback.d.ts.map +1 -0
  185. package/dist/hooks/use-playback.js +38 -0
  186. package/dist/hooks/use-playback.js.map +1 -0
  187. package/dist/hooks/use-props-form.d.ts +15 -0
  188. package/dist/hooks/use-props-form.d.ts.map +1 -0
  189. package/dist/hooks/use-props-form.js +22 -0
  190. package/dist/hooks/use-props-form.js.map +1 -0
  191. package/dist/hooks/use-real-fps.d.ts +3 -0
  192. package/dist/hooks/use-real-fps.d.ts.map +1 -0
  193. package/dist/hooks/use-real-fps.js +27 -0
  194. package/dist/hooks/use-real-fps.js.map +1 -0
  195. package/dist/hooks/use-shortcuts.d.ts +7 -0
  196. package/dist/hooks/use-shortcuts.d.ts.map +1 -0
  197. package/dist/hooks/use-shortcuts.js +53 -0
  198. package/dist/hooks/use-shortcuts.js.map +1 -0
  199. package/dist/hooks/use-studio.d.ts +4 -0
  200. package/dist/hooks/use-studio.d.ts.map +1 -0
  201. package/dist/hooks/use-studio.js +10 -0
  202. package/dist/hooks/use-studio.js.map +1 -0
  203. package/dist/index.d.ts +145 -0
  204. package/dist/index.d.ts.map +1 -0
  205. package/dist/index.js +117 -0
  206. package/dist/index.js.map +1 -0
  207. package/dist/lib/cn.d.ts +3 -0
  208. package/dist/lib/cn.d.ts.map +1 -0
  209. package/dist/lib/cn.js +8 -0
  210. package/dist/lib/cn.js.map +1 -0
  211. package/dist/lib/constants.d.ts +28 -0
  212. package/dist/lib/constants.d.ts.map +1 -0
  213. package/dist/lib/constants.js +38 -0
  214. package/dist/lib/constants.js.map +1 -0
  215. package/dist/lib/cva.d.ts +25 -0
  216. package/dist/lib/cva.d.ts.map +1 -0
  217. package/dist/lib/cva.js +23 -0
  218. package/dist/lib/cva.js.map +1 -0
  219. package/dist/lib/format.d.ts +13 -0
  220. package/dist/lib/format.d.ts.map +1 -0
  221. package/dist/lib/format.js +25 -0
  222. package/dist/lib/format.js.map +1 -0
  223. package/dist/lib/ids.d.ts +3 -0
  224. package/dist/lib/ids.d.ts.map +1 -0
  225. package/dist/lib/ids.js +6 -0
  226. package/dist/lib/ids.js.map +1 -0
  227. package/dist/registry/define-registry.d.ts +8 -0
  228. package/dist/registry/define-registry.d.ts.map +1 -0
  229. package/dist/registry/define-registry.js +71 -0
  230. package/dist/registry/define-registry.js.map +1 -0
  231. package/dist/registry/props-signal.d.ts +9 -0
  232. package/dist/registry/props-signal.d.ts.map +1 -0
  233. package/dist/registry/props-signal.js +25 -0
  234. package/dist/registry/props-signal.js.map +1 -0
  235. package/dist/schema/kf.d.ts +28 -0
  236. package/dist/schema/kf.d.ts.map +1 -0
  237. package/dist/schema/kf.js +82 -0
  238. package/dist/schema/kf.js.map +1 -0
  239. package/dist/schema/types.d.ts +69 -0
  240. package/dist/schema/types.d.ts.map +1 -0
  241. package/dist/schema/types.js +4 -0
  242. package/dist/schema/types.js.map +1 -0
  243. package/dist/server/index.d.ts +6 -0
  244. package/dist/server/index.d.ts.map +1 -0
  245. package/dist/server/index.js +7 -0
  246. package/dist/server/index.js.map +1 -0
  247. package/dist/server/map.d.ts +19 -0
  248. package/dist/server/map.d.ts.map +1 -0
  249. package/dist/server/map.js +63 -0
  250. package/dist/server/map.js.map +1 -0
  251. package/dist/server/render-queue.d.ts +46 -0
  252. package/dist/server/render-queue.d.ts.map +1 -0
  253. package/dist/server/render-queue.js +147 -0
  254. package/dist/server/render-queue.js.map +1 -0
  255. package/dist/server/temp-storage.d.ts +13 -0
  256. package/dist/server/temp-storage.d.ts.map +1 -0
  257. package/dist/server/temp-storage.js +55 -0
  258. package/dist/server/temp-storage.js.map +1 -0
  259. package/dist/server/types.d.ts +57 -0
  260. package/dist/server/types.d.ts.map +1 -0
  261. package/dist/server/types.js +2 -0
  262. package/dist/server/types.js.map +1 -0
  263. package/dist/signals/signal-bridge.d.ts +18 -0
  264. package/dist/signals/signal-bridge.d.ts.map +1 -0
  265. package/dist/signals/signal-bridge.js +39 -0
  266. package/dist/signals/signal-bridge.js.map +1 -0
  267. package/dist/store/store.d.ts +74 -0
  268. package/dist/store/store.d.ts.map +1 -0
  269. package/dist/store/store.js +276 -0
  270. package/dist/store/store.js.map +1 -0
  271. package/dist/styles/studio.css +2 -0
  272. package/dist/types.d.ts +112 -0
  273. package/dist/types.d.ts.map +1 -0
  274. package/dist/types.js +2 -0
  275. package/dist/types.js.map +1 -0
  276. package/package.json +66 -0
@@ -0,0 +1,145 @@
1
+ import { Brand } from "./components/brand/brand.js";
2
+ import { Header } from "./components/header/header.js";
3
+ import { HeaderTitle } from "./components/header/header-title.js";
4
+ import { Zoom } from "./components/header/zoom.js";
5
+ import { Icon } from "./components/icon/icon.js";
6
+ import { Library } from "./components/left-panel/library.js";
7
+ import { Sidebar } from "./components/left-panel/sidebar.js";
8
+ import { SidebarGroup } from "./components/left-panel/sidebar-group.js";
9
+ import { SidebarItem } from "./components/left-panel/sidebar-item.js";
10
+ import { MenuItem, StMenu } from "./components/primitives/menu.js";
11
+ import { StNumberField } from "./components/primitives/number-field.js";
12
+ import { StSelect } from "./components/primitives/select.js";
13
+ import { StSlider } from "./components/primitives/slider.js";
14
+ import { StSwitch } from "./components/primitives/switch.js";
15
+ import { StTabs, Tab, TabList, TabPanel } from "./components/primitives/tabs.js";
16
+ import { StTooltip } from "./components/primitives/tooltip.js";
17
+ import { ExportFrameDialog } from "./components/render/export-frame-dialog.js";
18
+ import { RenderDialog } from "./components/render/render-dialog.js";
19
+ import { RenderQueue } from "./components/render/render-queue.js";
20
+ import { Panel } from "./components/right-panel/panel.js";
21
+ import { PanelHandle } from "./components/right-panel/panel-handle.js";
22
+ import { PanelTabs } from "./components/right-panel/panel-tabs.js";
23
+ import { SchemaForm } from "./components/schema-form/schema-form.js";
24
+ import { Stage } from "./components/stage/stage.js";
25
+ import { Body, Main, Section } from "./components/studio/layout.js";
26
+ import { StudioRoot } from "./components/studio/studio.js";
27
+ import { LayeredBody } from "./components/timeline/layered-body.js";
28
+ import { Scrubber } from "./components/timeline/scrubber.js";
29
+ import { Timeline } from "./components/timeline/timeline.js";
30
+ import { TimelineHeader } from "./components/timeline/timeline-header.js";
31
+ import { Transport } from "./components/timeline/transport.js";
32
+ import { Toasts } from "./components/toasts/toasts.js";
33
+ /**
34
+ * The compound root + namespace. `<Studio registry render>` provides context;
35
+ * compose the regions as children (`<Studio.Header>`, `<Studio.Stage>`, …).
36
+ */
37
+ export declare const Studio: typeof StudioRoot & {
38
+ Body: typeof Body;
39
+ Main: typeof Main;
40
+ Section: typeof Section;
41
+ Spacer: () => import("react/jsx-runtime").JSX.Element;
42
+ Brand: typeof Brand;
43
+ Sidebar: typeof Sidebar & {
44
+ Group: typeof SidebarGroup;
45
+ Item: typeof SidebarItem;
46
+ };
47
+ Library: typeof Library;
48
+ NavItem: typeof SidebarItem;
49
+ SidebarItem: typeof SidebarItem;
50
+ SidebarGroup: typeof SidebarGroup;
51
+ Header: typeof Header & {
52
+ Title: typeof HeaderTitle;
53
+ };
54
+ HeaderTitle: typeof HeaderTitle;
55
+ Zoom: typeof Zoom;
56
+ Menu: typeof StMenu & {
57
+ Item: typeof MenuItem;
58
+ Separator: () => import("react/jsx-runtime").JSX.Element;
59
+ };
60
+ MenuItem: typeof MenuItem;
61
+ MenuSeparator: () => import("react/jsx-runtime").JSX.Element;
62
+ Stage: typeof Stage;
63
+ Timeline: typeof Timeline;
64
+ TimelineHeader: typeof TimelineHeader;
65
+ Scrubber: typeof Scrubber;
66
+ Transport: typeof Transport;
67
+ LayeredBody: typeof LayeredBody;
68
+ Panel: typeof Panel & {
69
+ Tabs: typeof PanelTabs;
70
+ Handle: typeof PanelHandle;
71
+ };
72
+ PanelTabs: typeof PanelTabs;
73
+ PanelHandle: typeof PanelHandle;
74
+ SchemaForm: typeof SchemaForm;
75
+ RenderDialog: typeof RenderDialog;
76
+ ExportFrameDialog: typeof ExportFrameDialog;
77
+ RenderQueue: typeof RenderQueue;
78
+ Toasts: typeof Toasts;
79
+ Button: import("react").ForwardRefExoticComponent<import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
80
+ tone?: import("./components/button/button.js").ButtonTone;
81
+ size?: import("./components/button/button.js").ButtonSize;
82
+ icon?: import("./index.js").IconName;
83
+ } & import("react").RefAttributes<HTMLButtonElement>>;
84
+ IconButton: import("react").ForwardRefExoticComponent<Omit<import("react").ButtonHTMLAttributes<HTMLButtonElement>, "children"> & {
85
+ icon?: import("./index.js").IconName;
86
+ size?: import("./components/button/icon-button.js").IconButtonSize;
87
+ tone?: import("./components/button/icon-button.js").IconButtonTone;
88
+ active?: boolean;
89
+ iconSize?: number;
90
+ children?: import("react").ReactNode;
91
+ } & import("react").RefAttributes<HTMLButtonElement>>;
92
+ Icon: typeof Icon;
93
+ Dialog: (({ open, onOpenChange, children, }: {
94
+ open?: boolean;
95
+ onOpenChange?: (open: boolean) => void;
96
+ children: import("react").ReactNode;
97
+ }) => import("react/jsx-runtime").JSX.Element) & {
98
+ Popup: ({ width, children, className, }: {
99
+ width?: number;
100
+ children: import("react").ReactNode;
101
+ className?: string;
102
+ }) => import("react/jsx-runtime").JSX.Element;
103
+ Header: ({ icon, title }: {
104
+ icon?: import("./index.js").IconName;
105
+ title: import("react").ReactNode;
106
+ }) => import("react/jsx-runtime").JSX.Element;
107
+ Body: ({ children }: {
108
+ children: import("react").ReactNode;
109
+ }) => import("react/jsx-runtime").JSX.Element;
110
+ Footer: ({ children }: {
111
+ children: import("react").ReactNode;
112
+ }) => import("react/jsx-runtime").JSX.Element;
113
+ Title: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").AlertDialogTitleProps, "ref"> & import("react").RefAttributes<HTMLHeadingElement>>;
114
+ Description: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").AlertDialogDescriptionProps, "ref"> & import("react").RefAttributes<HTMLParagraphElement>>;
115
+ Close: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").AlertDialogCloseProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
116
+ Trigger: import("@base-ui/react").DialogTrigger;
117
+ };
118
+ Tabs: typeof StTabs;
119
+ Tab: typeof Tab;
120
+ TabList: typeof TabList;
121
+ TabPanel: typeof TabPanel;
122
+ Slider: typeof StSlider;
123
+ Switch: typeof StSwitch;
124
+ Select: typeof StSelect;
125
+ Tooltip: typeof StTooltip;
126
+ NumberField: typeof StNumberField;
127
+ };
128
+ export { Icon, type IconProps } from "./components/icon/icon.js";
129
+ export type { IconName } from "./components/icon/paths.js";
130
+ export type { StudioProps } from "./components/studio/studio.js";
131
+ export { useComposition } from "./hooks/use-composition.js";
132
+ export { applyLayerVisibility, deriveLayers, sequencesOf } from "./hooks/use-layers.js";
133
+ export { usePlayback } from "./hooks/use-playback.js";
134
+ export { usePropsForm } from "./hooks/use-props-form.js";
135
+ export { useRealFps } from "./hooks/use-real-fps.js";
136
+ export { useShortcuts } from "./hooks/use-shortcuts.js";
137
+ export { useStudio } from "./hooks/use-studio.js";
138
+ export { LAYER_KINDS, type LayerKind, type LayerKindMeta, ZOOM_STEPS } from "./lib/constants.js";
139
+ export { defineRegistry } from "./registry/define-registry.js";
140
+ export { createPropsSignal } from "./registry/props-signal.js";
141
+ export { defaultForField, defaultsFor, isValueField, kf, resolveDefaults } from "./schema/kf.js";
142
+ export type * from "./schema/types.js";
143
+ export { usePlayerSignal, useSignalValue } from "./signals/signal-bridge.js";
144
+ export type * from "./types.js";
145
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAIpD,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAClE,OAAO,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAC7D,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAC7D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AAC;AAEvC,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAG7E,mBAAmB,YAAY,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,117 @@
1
+ import { Brand } from "./components/brand/brand.js";
2
+ /** @smoove/studio — public barrel. */
3
+ import { Button } from "./components/button/button.js";
4
+ import { IconButton } from "./components/button/icon-button.js";
5
+ import { Header } from "./components/header/header.js";
6
+ import { HeaderTitle } from "./components/header/header-title.js";
7
+ import { Zoom } from "./components/header/zoom.js";
8
+ import { Icon } from "./components/icon/icon.js";
9
+ import { Library } from "./components/left-panel/library.js";
10
+ import { Sidebar } from "./components/left-panel/sidebar.js";
11
+ import { SidebarGroup } from "./components/left-panel/sidebar-group.js";
12
+ import { NavItem, SidebarItem } from "./components/left-panel/sidebar-item.js";
13
+ import { StDialog } from "./components/primitives/dialog.js";
14
+ import { MenuItem, MenuSeparator, StMenu } from "./components/primitives/menu.js";
15
+ import { StNumberField } from "./components/primitives/number-field.js";
16
+ import { StSelect } from "./components/primitives/select.js";
17
+ import { StSlider } from "./components/primitives/slider.js";
18
+ import { StSwitch } from "./components/primitives/switch.js";
19
+ import { StTabs, Tab, TabList, TabPanel } from "./components/primitives/tabs.js";
20
+ import { StTooltip } from "./components/primitives/tooltip.js";
21
+ import { ExportFrameDialog } from "./components/render/export-frame-dialog.js";
22
+ import { RenderDialog } from "./components/render/render-dialog.js";
23
+ import { RenderQueue } from "./components/render/render-queue.js";
24
+ import { Panel } from "./components/right-panel/panel.js";
25
+ import { PanelHandle } from "./components/right-panel/panel-handle.js";
26
+ import { PanelTabs } from "./components/right-panel/panel-tabs.js";
27
+ import { SchemaForm } from "./components/schema-form/schema-form.js";
28
+ import { Stage } from "./components/stage/stage.js";
29
+ import { Body, Main, Section, Spacer } from "./components/studio/layout.js";
30
+ import { StudioRoot } from "./components/studio/studio.js";
31
+ import { LayeredBody } from "./components/timeline/layered-body.js";
32
+ import { Scrubber } from "./components/timeline/scrubber.js";
33
+ import { Timeline } from "./components/timeline/timeline.js";
34
+ import { TimelineHeader } from "./components/timeline/timeline-header.js";
35
+ import { Transport } from "./components/timeline/transport.js";
36
+ import { Toasts } from "./components/toasts/toasts.js";
37
+ const Menu = Object.assign(StMenu, { Item: MenuItem, Separator: MenuSeparator });
38
+ const SidebarNs = Object.assign(Sidebar, { Group: SidebarGroup, Item: SidebarItem });
39
+ const HeaderNs = Object.assign(Header, { Title: HeaderTitle });
40
+ const PanelNs = Object.assign(Panel, { Tabs: PanelTabs, Handle: PanelHandle });
41
+ /**
42
+ * The compound root + namespace. `<Studio registry render>` provides context;
43
+ * compose the regions as children (`<Studio.Header>`, `<Studio.Stage>`, …).
44
+ */
45
+ export const Studio = Object.assign(StudioRoot, {
46
+ // layout shells
47
+ Body,
48
+ Main,
49
+ Section,
50
+ Spacer,
51
+ // brand
52
+ Brand,
53
+ // left panel
54
+ Sidebar: SidebarNs,
55
+ Library,
56
+ NavItem,
57
+ SidebarItem,
58
+ SidebarGroup,
59
+ // header
60
+ Header: HeaderNs,
61
+ HeaderTitle,
62
+ Zoom,
63
+ Menu,
64
+ MenuItem,
65
+ MenuSeparator,
66
+ // stage + timeline
67
+ Stage,
68
+ Timeline,
69
+ TimelineHeader,
70
+ Scrubber,
71
+ Transport,
72
+ LayeredBody,
73
+ // right panel
74
+ Panel: PanelNs,
75
+ PanelTabs,
76
+ PanelHandle,
77
+ SchemaForm,
78
+ // render
79
+ RenderDialog,
80
+ ExportFrameDialog,
81
+ RenderQueue,
82
+ Toasts,
83
+ // primitives
84
+ Button,
85
+ IconButton,
86
+ Icon,
87
+ Dialog: StDialog,
88
+ Tabs: StTabs,
89
+ Tab,
90
+ TabList,
91
+ TabPanel,
92
+ Slider: StSlider,
93
+ Switch: StSwitch,
94
+ Select: StSelect,
95
+ Tooltip: StTooltip,
96
+ NumberField: StNumberField,
97
+ });
98
+ // Icon primitive + type
99
+ export { Icon } from "./components/icon/icon.js";
100
+ export { useComposition } from "./hooks/use-composition.js";
101
+ export { applyLayerVisibility, deriveLayers, sequencesOf } from "./hooks/use-layers.js";
102
+ export { usePlayback } from "./hooks/use-playback.js";
103
+ export { usePropsForm } from "./hooks/use-props-form.js";
104
+ export { useRealFps } from "./hooks/use-real-fps.js";
105
+ export { useShortcuts } from "./hooks/use-shortcuts.js";
106
+ // Hooks
107
+ export { useStudio } from "./hooks/use-studio.js";
108
+ // Catalog constants
109
+ export { LAYER_KINDS, ZOOM_STEPS } from "./lib/constants.js";
110
+ // Registry (isomorphic)
111
+ export { defineRegistry } from "./registry/define-registry.js";
112
+ export { createPropsSignal } from "./registry/props-signal.js";
113
+ // Schema DSL
114
+ export { defaultForField, defaultsFor, isValueField, kf, resolveDefaults } from "./schema/kf.js";
115
+ // React ↔ signal bridges
116
+ export { usePlayerSignal, useSignalValue } from "./signals/signal-bridge.js";
117
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACpD,sCAAsC;AACtC,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAClE,OAAO,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAC7D,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,MAAM,0CAA0C,CAAC;AACxE,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,yCAAyC,CAAC;AAC/E,OAAO,E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G;IACH,OAAO;IACP,QAAQ;IACR,MAAM,EAAE,QAAQ;IAChB,MAAM,EAAE,QAAQ;IAChB,MAAM,EAAE,QAAQ;IAChB,OAAO,EAAE,SAAS;IAClB,WAAW,EAAE,aAAa;CAC3B,CAAC,CAAC;AAEH,wBAAwB;AACxB,OAAO,EAAE,IAAI,EAAkB,MAAM,2BAA2B,CAAC;AAGjE,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,oBAAoB,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACxF,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AACxD,QAAQ;AACR,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,oBAAoB;AACpB,OAAO,EAAE,WAAW,EAAsC,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACjG,wBAAwB;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,aAAa;AACb,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,YAAY,EAAE,EAAE,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEjG,yBAAyB;AACzB,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC"}
@@ -0,0 +1,3 @@
1
+ /** Join truthy class fragments (arrays are flattened). */
2
+ export declare function cn(...parts: Array<string | false | null | undefined | string[]>): string;
3
+ //# sourceMappingURL=cn.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cn.d.ts","sourceRoot":"","sources":["../../src/lib/cn.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAC1D,wBAAgB,EAAE,CAAC,GAAG,KAAK,EAAE,KAAK,CAAC,MAAM,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,EAAE,CAAC,GAAG,MAAM,CAKxF"}
package/dist/lib/cn.js ADDED
@@ -0,0 +1,8 @@
1
+ /** Join truthy class fragments (arrays are flattened). */
2
+ export function cn(...parts) {
3
+ return parts
4
+ .flat(Number.POSITIVE_INFINITY)
5
+ .filter(Boolean)
6
+ .join(" ");
7
+ }
8
+ //# sourceMappingURL=cn.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cn.js","sourceRoot":"","sources":["../../src/lib/cn.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAC1D,MAAM,UAAU,EAAE,CAAC,GAAG,KAA0D;IAC9E,OAAO,KAAK;SACT,IAAI,CAAC,MAAM,CAAC,iBAAsB,CAAC;SACnC,MAAM,CAAC,OAAO,CAAC;SACf,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC"}
@@ -0,0 +1,28 @@
1
+ import type { IconName } from "../components/icon/paths.js";
2
+ export declare const ZOOM_STEPS: readonly [0.25, 0.5, 0.75, 1, 1.25, 1.5, 2];
3
+ export type LayerKind = "sequence" | "audio" | "video" | "group" | "transition";
4
+ export type LayerKindMeta = {
5
+ color: string;
6
+ label: string;
7
+ icon: IconName;
8
+ };
9
+ /** Color + icon per layer kind, consumed by the layered timeline. */
10
+ export declare const LAYER_KINDS: Record<LayerKind, LayerKindMeta>;
11
+ export type SelectOption = {
12
+ value: string;
13
+ label: string;
14
+ desc?: string;
15
+ };
16
+ export declare const RES_PRESETS: Array<SelectOption & {
17
+ w?: number;
18
+ h?: number;
19
+ }>;
20
+ export declare const QUALITY: Array<SelectOption & {
21
+ f: number;
22
+ }>;
23
+ export declare const FORMATS: Array<SelectOption & {
24
+ mul: number;
25
+ }>;
26
+ export declare const estMB: (w: number, h: number, frames: number, qf: number, mul: number) => number;
27
+ export declare const prettyMB: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}
@@ -0,0 +1,38 @@
1
+ export const ZOOM_STEPS = [0.25, 0.5, 0.75, 1, 1.25, 1.5, 2];
2
+ /** Color + icon per layer kind, consumed by the layered timeline. */
3
+ export const LAYER_KINDS = {
4
+ sequence: { color: "#ff5640", label: "Sequence", icon: "layers" },
5
+ audio: { color: "#ff5d8f", label: "Audio", icon: "media" },
6
+ video: { color: "#56b8ff", label: "Video", icon: "film" },
7
+ group: { color: "#ff8a3d", label: "Group", icon: "layout" },
8
+ transition: { color: "#2bd9c4", label: "Transition", icon: "progress" },
9
+ };
10
+ export const RES_PRESETS = [
11
+ { value: "720p", label: "720p · 1280×720", w: 1280, h: 720 },
12
+ { value: "1080p", label: "1080p · 1920×1080", w: 1920, h: 1080 },
13
+ { value: "1440p", label: "1440p · 2560×1440", w: 2560, h: 1440 },
14
+ { value: "2160p", label: "4K · 3840×2160", w: 3840, h: 2160 },
15
+ { value: "square", label: "Square · 1080×1080", w: 1080, h: 1080 },
16
+ { value: "vert", label: "Vertical · 1080×1920", w: 1080, h: 1920 },
17
+ { value: "custom", label: "Custom size" },
18
+ ];
19
+ export const QUALITY = [
20
+ { value: "draft", label: "Draft", desc: "Fast preview · low bitrate", f: 0.07 },
21
+ { value: "standard", label: "Standard", desc: "Balanced · web-ready", f: 0.16 },
22
+ { value: "high", label: "High", desc: "Crisp · high bitrate", f: 0.34 },
23
+ { value: "lossless", label: "Lossless", desc: "Master · largest file", f: 1.3 },
24
+ ];
25
+ export const FORMATS = [
26
+ { value: "mp4", label: "MP4 · H.264", mul: 1 },
27
+ { value: "webm", label: "WebM · VP9", mul: 0.82 },
28
+ { value: "mov", label: "MOV · ProRes", mul: 3.4 },
29
+ { value: "gif", label: "Animated GIF", mul: 1.7 },
30
+ { value: "png", label: "PNG sequence", mul: 5.5 },
31
+ ];
32
+ export const estMB = (w, h, frames, qf, mul) => (w * h * frames * qf * mul) / 90000;
33
+ export const prettyMB = (mb) => mb >= 1024
34
+ ? `${(mb / 1024).toFixed(2)} GB`
35
+ : mb >= 10
36
+ ? `${Math.round(mb)} MB`
37
+ : `${mb.toFixed(1)} MB`;
38
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/lib/constants.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAU,CAAC;AAMtE,qEAAqE;AACrE,MAAM,CAAC,MAAM,WAAW,GAAqC;IAC3D,QAAQ,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE;IACjE,KAAK,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE;IAC1D,KAAK,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE;IACzD,KAAK,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE;IAC3D,UAAU,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,YAAY,EAAE,IAAI,EAAE,UAAU,EAAE;CACxE,CAAC;AAIF,MAAM,CAAC,MAAM,WAAW,GAAqD;IAC3E,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,iBAAiB,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,GAAG,EAAE;IAC5D,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,mBAAmB,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE;IAChE,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,mBAAmB,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAA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AK,EAAE,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,GAAG,EAAE;IACjD,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,cAAc,EAAE,GAAG,EAAE,GAAG,EAAE;CAClD,CAAC;AAEF,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,CAAS,EAAE,MAAc,EAAE,EAAU,EAAE,GAAW,EAAU,EAAE,CAC7F,CAAC,CAAC,GAAG,CAAC,GAAG,MAAM,GAAG,EAAE,GAAG,GAAG,CAAC,GAAG,KAAK,CAAC;AAEtC,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,EAAU,EAAU,EAAE,CAC7C,EAAE,IAAI,IAAI;IACR,CAAC,CAAC,GAAG,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK;IAChC,CAAC,CAAC,EAAE,IAAI,EAAE;QACR,CAAC,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,KAAK;QACxB,CAAC,CAAC,GAAG,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC"}
@@ -0,0 +1,25 @@
1
+ type VariantMap = Record<string, Record<string, string>>;
2
+ type VariantProps<V extends VariantMap> = {
3
+ [K in keyof V]?: keyof V[K];
4
+ };
5
+ type DefaultVariants<V extends VariantMap> = {
6
+ [K in keyof V]?: keyof V[K];
7
+ };
8
+ export type CvaConfig<V extends VariantMap> = {
9
+ variants?: V;
10
+ defaultVariants?: DefaultVariants<V>;
11
+ };
12
+ /**
13
+ * cva-lite: build a className from a base + variant maps.
14
+ *
15
+ * const button = cva("inline-flex …", {
16
+ * variants: { tone: { primary: "…", ghost: "…" } },
17
+ * defaultVariants: { tone: "ghost" },
18
+ * });
19
+ * button({ tone: "primary", className: "extra" });
20
+ */
21
+ export declare function cva<V extends VariantMap>(base: string, config?: CvaConfig<V>): (props?: VariantProps<V> & {
22
+ className?: string;
23
+ }) => string;
24
+ export {};
25
+ //# sourceMappingURL=cva.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cva.d.ts","sourceRoot":"","sources":["../../src/lib/cva.ts"],"names":[],"mappings":"AAEA,KAAK,UAAU,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AAEzD,KAAK,YAAY,CAAC,CAAC,SAAS,UAAU,IAAI;KACvC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC;CAC5B,CAAC;AAEF,KAAK,eAAe,CAAC,CAAC,SAAS,UAAU,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC;CAAE,CAAC;AAE7E,MAAM,MAAM,SAAS,CAAC,CAAC,SAAS,UAAU,IAAI;IAC5C,QAAQ,CAAC,EAAE,CAAC,CAAC;IACb,eAAe,CAAC,EAAE,eAAe,CAAC,CAAC,CAAC,CAAC;CACtC,CAAC;AAEF;;;;;;;;GAQG;AACH,wBAAgB,GAAG,CAAC,CAAC,SAAS,UAAU,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,GAAE,SAAS,CAAC,CAAC,CAAM,IAEvE,QAAO,YAAY,CAAC,CAAC,CAAC,GAAG;IAAE,SAAS,CAAC,EAAE,MAAM,CAAA;CAAO,KAAG,MAAM,CAStE"}
@@ -0,0 +1,23 @@
1
+ import { cn } from "./cn.js";
2
+ /**
3
+ * cva-lite: build a className from a base + variant maps.
4
+ *
5
+ * const button = cva("inline-flex …", {
6
+ * variants: { tone: { primary: "…", ghost: "…" } },
7
+ * defaultVariants: { tone: "ghost" },
8
+ * });
9
+ * button({ tone: "primary", className: "extra" });
10
+ */
11
+ export function cva(base, config = {}) {
12
+ const { variants = {}, defaultVariants = {} } = config;
13
+ return (props = {}) => {
14
+ const { className, ...rest } = props;
15
+ const picks = Object.keys(variants).map((key) => {
16
+ const chosen = rest[key] !== undefined ? rest[key] : defaultVariants[key];
17
+ const group = variants[key];
18
+ return group && chosen != null ? group[chosen] : undefined;
19
+ });
20
+ return cn(base, ...picks, className);
21
+ };
22
+ }
23
+ //# sourceMappingURL=cva.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cva.js","sourceRoot":"","sources":["../../src/lib/cva.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,SAAS,CAAC;AAe7B;;;;;;;;GAQG;AACH,MAAM,UAAU,GAAG,CAAuB,IAAY,EAAE,SAAuB,EAAE;IAC/E,MAAM,EAAE,QAAQ,GAAG,EAAO,EAAE,eAAe,GAAG,EAAwB,EAAE,GAAG,MAAM,CAAC;IAClF,OAAO,CAAC,QAAkD,EAAE,EAAU,EAAE;QACtE,MAAM,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,GAAG,KAAyD,CAAC;QACzF,MAAM,KAAK,GAAI,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAoB,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE;YAClE,MAAM,MAAM,GAAG,IAAI,CAAC,GAAa,CAAC,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,GAAa,CAAC,CAAC,CAAC,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;YAC9F,MAAM,KAAK,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC;YAC5B,OAAO,KAAK,IAAI,MAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,MAAgB,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QACvE,CAAC,CAAC,CAAC;QACH,OAAO,EAAE,CAAC,IAAI,EAAE,GAAG,KAAK,EAAE,SAAS,CAAC,CAAC;IACvC,CAAC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const clamp01: (x: number) => number;
2
+ export declare const clamp: (x: number, lo: number, hi: number) => number;
3
+ export declare const lerp: (a: number, b: number, t: number) => number;
4
+ /** Normalize `t` to [0,1] across the segment [a,b]. */
5
+ export declare const seg: (t: number, a: number, b: number) => number;
6
+ export declare const easeOut: (t: number) => number;
7
+ export declare const easeInOut: (t: number) => number;
8
+ /** "m:ss" timecode from seconds. */
9
+ export declare function fmtTime(s: number): string;
10
+ export type Health = "idle" | "good" | "ok" | "low";
11
+ /** Traffic-light health for the realtime-vs-target fps readout. */
12
+ export declare function fpsHealth(realFps: number, targetFps: number): Health;
13
+ //# sourceMappingURL=format.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format.d.ts","sourceRoot":"","sources":["../../src/lib/format.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,GAAI,GAAG,MAAM,KAAG,MAAqC,CAAC;AAC1E,eAAO,MAAM,KAAK,GAAI,GAAG,MAAM,EAAE,IAAI,MAAM,EAAE,IAAI,MAAM,KAAG,MAAuC,CAAC;AAClG,eAAO,MAAM,IAAI,GAAI,GAAG,MAAM,EAAE,GAAG,MAAM,EAAE,GAAG,MAAM,KAAG,MAAyB,CAAC;AACjF,uDAAuD;AACvD,eAAO,MAAM,GAAG,GAAI,GAAG,MAAM,EAAE,GAAG,MAAM,EAAE,GAAG,MAAM,KAAG,MAAoC,CAAC;AAC3F,eAAO,MAAM,OAAO,GAAI,GAAG,MAAM,KAAG,MAA0B,CAAC;AAC/D,eAAO,MAAM,SAAS,GAAI,GAAG,MAAM,KAAG,MACe,CAAC;AAEtD,oCAAoC;AACpC,wBAAgB,OAAO,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAKzC;AAED,MAAM,MAAM,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,GAAG,KAAK,CAAC;AAEpD,mEAAmE;AACnE,wBAAgB,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAKpE"}
@@ -0,0 +1,25 @@
1
+ export const clamp01 = (x) => Math.max(0, Math.min(1, x));
2
+ export const clamp = (x, lo, hi) => Math.max(lo, Math.min(hi, x));
3
+ export const lerp = (a, b, t) => a + (b - a) * t;
4
+ /** Normalize `t` to [0,1] across the segment [a,b]. */
5
+ export const seg = (t, a, b) => clamp01((t - a) / (b - a));
6
+ export const easeOut = (t) => 1 - (1 - t) ** 3;
7
+ export const easeInOut = (t) => t < 0.5 ? 4 * t * t * t : 1 - (-2 * t + 2) ** 3 / 2;
8
+ /** "m:ss" timecode from seconds. */
9
+ export function fmtTime(s) {
10
+ const v = Math.max(0, s);
11
+ return `${Math.floor(v / 60)}:${Math.floor(v % 60)
12
+ .toString()
13
+ .padStart(2, "0")}`;
14
+ }
15
+ /** Traffic-light health for the realtime-vs-target fps readout. */
16
+ export function fpsHealth(realFps, targetFps) {
17
+ if (!realFps)
18
+ return "idle";
19
+ if (realFps >= targetFps * 0.9)
20
+ return "good";
21
+ if (realFps >= targetFps * 0.6)
22
+ return "ok";
23
+ return "low";
24
+ }
25
+ //# sourceMappingURL=format.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format.js","sourceRoot":"","sources":["../../src/lib/format.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,CAAS,EAAU,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAC1E,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,CAAS,EAAE,EAAU,EAAE,EAAU,EAAU,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;AAClG,MAAM,CAAC,MAAM,IAAI,GAAG,CAAC,CAAS,EAAE,CAAS,EAAE,CAAS,EAAU,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC;AACjF,uDAAuD;AACvD,MAAM,CAAC,MAAM,G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
3
+ //# sourceMappingURL=ids.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ids.d.ts","sourceRoot":"","sources":["../../src/lib/ids.ts"],"names":[],"mappings":"AAEA,6DAA6D;AAC7D,wBAAgB,SAAS,IAAI,MAAM,CAElC"}
@@ -0,0 +1,6 @@
1
+ let jobSeq = 1;
2
+ /** A stable-enough job id for the in-memory render queue. */
3
+ export function makeJobId() {
4
+ return `job-${jobSeq++}-${Math.random().toString(36).slice(2, 6)}`;
5
+ }
6
+ //# sourceMappingURL=ids.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ids.js","sourceRoot":"","sources":["../../src/lib/ids.ts"],"names":[],"mappings":"AAAA,IAAI,MAAM,GAAG,CAAC,CAAC;AAEf,6DAA6D;AAC7D,MAAM,UAAU,SAAS;IACvB,OAAO,OAAO,MAAM,EAAE,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC;AACrE,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { Registry, RegistryEntry } from "../types.js";
2
+ /**
3
+ * Build a Registry from id-keyed entries. `load(id)` is memoized so the preview
4
+ * and an in-process render share one construction. Isomorphic — no React/DOM
5
+ * imports — so a render worker can import it in Node.
6
+ */
7
+ export declare function defineRegistry(entries: RegistryEntry[]): Registry;
8
+ //# sourceMappingURL=define-registry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"define-registry.d.ts","sourceRoot":"","sources":["../../src/registry/define-registry.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAoB,QAAQ,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAa7E;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,aAAa,EAAE,GAAG,QAAQ,CAmDjE"}
@@ -0,0 +1,71 @@
1
+ /** Unwrap a loader result that may be a Composition or a `{ default }` module. */
2
+ function unwrap(value) {
3
+ return value.default ?? value;
4
+ }
5
+ /** Resolve a {@link CompositionInput} (instance | sync/async loader) to a comp. */
6
+ function resolve(input) {
7
+ const value = typeof input === "function" ? input() : input;
8
+ return Promise.resolve(value).then(unwrap);
9
+ }
10
+ /**
11
+ * Build a Registry from id-keyed entries. `load(id)` is memoized so the preview
12
+ * and an in-process render share one construction. Isomorphic — no React/DOM
13
+ * imports — so a render worker can import it in Node.
14
+ */
15
+ export function defineRegistry(entries) {
16
+ const byId = new Map();
17
+ for (const e of entries) {
18
+ if (!e.id)
19
+ throw new Error("defineRegistry: every entry needs an id");
20
+ if (byId.has(e.id))
21
+ throw new Error(`defineRegistry: duplicate id "${e.id}"`);
22
+ byId.set(e.id, e);
23
+ }
24
+ const loaded = new Map();
25
+ const pending = new Map();
26
+ const listeners = new Set();
27
+ return {
28
+ entries: () => entries,
29
+ peek: (id) => loaded.get(id),
30
+ update(id, composition) {
31
+ const entry = byId.get(id);
32
+ if (!entry)
33
+ return;
34
+ entry.composition = composition;
35
+ loaded.delete(id);
36
+ pending.delete(id);
37
+ for (const fn of listeners)
38
+ fn(id);
39
+ },
40
+ onChange(listener) {
41
+ listeners.add(listener);
42
+ return () => {
43
+ listeners.delete(listener);
44
+ };
45
+ },
46
+ load(id) {
47
+ const existing = loaded.get(id);
48
+ if (existing)
49
+ return Promise.resolve(existing);
50
+ const inflight = pending.get(id);
51
+ if (inflight)
52
+ return inflight;
53
+ const entry = byId.get(id);
54
+ if (!entry)
55
+ return Promise.reject(new Error(`Unknown composition id: ${id}`));
56
+ const promise = resolve(entry.composition)
57
+ .then((comp) => {
58
+ loaded.set(id, comp);
59
+ pending.delete(id);
60
+ return comp;
61
+ })
62
+ .catch((err) => {
63
+ pending.delete(id);
64
+ throw err;
65
+ });
66
+ pending.set(id, promise);
67
+ return promise;
68
+ },
69
+ };
70
+ }
71
+ //# sourceMappingURL=define-registry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"define-registry.js","sourceRoot":"","sources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MAAM,CAAC,EAAE,CAAC,CAAC;gBACnB,MAAM,GAAG,CAAC;YACZ,CAAC,CAAC,CAAC;YACL,OAAO,CAAC,GAAG,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;YACzB,OAAO,OAAO,CAAC;QACjB,CAAC;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,9 @@
1
+ import type { WritableSignal } from "../types.js";
2
+ /**
3
+ * A minimal writable signal matching core's `ReadonlySignal` shape (get +
4
+ * subscribe) plus `set`. React-free and Node-safe. An entry's `load` receives
5
+ * the readable side and reads `props.get()` in updaters / subscribes to re-apply
6
+ * the current frame; the studio holds the writable side and pushes form edits.
7
+ */
8
+ export declare function createPropsSignal<T>(initial: T): WritableSignal<T>;
9
+ //# sourceMappingURL=props-signal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"props-signal.d.ts","sourceRoot":"","sources":["../../src/registry/props-signal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAgBlE"}