@tpitre/story-ui 3.4.0 → 3.4.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 (282) hide show
  1. package/dist/cli/index.js +0 -0
  2. package/dist/mcp-server/index.js +32 -0
  3. package/package.json +2 -1
  4. package/dist/cli/index.js.map +0 -1
  5. package/dist/cli/setup.js.map +0 -1
  6. package/dist/cloudflare-edge/src/mcp-session.js +0 -462
  7. package/dist/cloudflare-edge/src/types.js +0 -4
  8. package/dist/cloudflare-edge/src/worker.js +0 -106
  9. package/dist/cloudflare-pages/vite.config.js +0 -14
  10. package/dist/index.d.ts +0 -13
  11. package/dist/index.d.ts.map +0 -1
  12. package/dist/index.js +0 -12
  13. package/dist/index.js.map +0 -1
  14. package/dist/mcp-server/index.js.map +0 -1
  15. package/dist/mcp-server/mcp-stdio-server.js.map +0 -1
  16. package/dist/mcp-server/routes/claude.js.map +0 -1
  17. package/dist/mcp-server/routes/components.js.map +0 -1
  18. package/dist/mcp-server/routes/generateStory.js.map +0 -1
  19. package/dist/mcp-server/routes/hybridStories.d.ts +0 -18
  20. package/dist/mcp-server/routes/hybridStories.d.ts.map +0 -1
  21. package/dist/mcp-server/routes/hybridStories.js +0 -216
  22. package/dist/mcp-server/routes/hybridStories.js.map +0 -1
  23. package/dist/mcp-server/routes/memoryStories.d.ts +0 -26
  24. package/dist/mcp-server/routes/memoryStories.d.ts.map +0 -1
  25. package/dist/mcp-server/routes/memoryStories.js +0 -158
  26. package/dist/mcp-server/routes/memoryStories.js.map +0 -1
  27. package/dist/mcp-server/routes/storySync.d.ts +0 -26
  28. package/dist/mcp-server/routes/storySync.d.ts.map +0 -1
  29. package/dist/mcp-server/routes/storySync.js +0 -147
  30. package/dist/mcp-server/routes/storySync.js.map +0 -1
  31. package/dist/mcp-server/routes/updateStory.js +0 -246
  32. package/dist/mcp-server/sessionManager.d.ts +0 -50
  33. package/dist/mcp-server/sessionManager.d.ts.map +0 -1
  34. package/dist/mcp-server/sessionManager.js +0 -125
  35. package/dist/mcp-server/sessionManager.js.map +0 -1
  36. package/dist/playground/components/AIAssistant/AIAssistant.d.ts +0 -6
  37. package/dist/playground/components/AIAssistant/AIAssistant.d.ts.map +0 -1
  38. package/dist/playground/components/AIAssistant/AIAssistant.js +0 -109
  39. package/dist/playground/components/AIAssistant/AIAssistant.js.map +0 -1
  40. package/dist/playground/components/AIAssistant/AIAssistant.module.css +0 -166
  41. package/dist/playground/components/Canvas/Canvas.d.ts +0 -9
  42. package/dist/playground/components/Canvas/Canvas.d.ts.map +0 -1
  43. package/dist/playground/components/Canvas/Canvas.js +0 -58
  44. package/dist/playground/components/Canvas/Canvas.js.map +0 -1
  45. package/dist/playground/components/Canvas/Canvas.module.css +0 -189
  46. package/dist/playground/components/Canvas/CanvasWithDnd.d.ts +0 -9
  47. package/dist/playground/components/Canvas/CanvasWithDnd.d.ts.map +0 -1
  48. package/dist/playground/components/Canvas/CanvasWithDnd.js +0 -158
  49. package/dist/playground/components/Canvas/CanvasWithDnd.js.map +0 -1
  50. package/dist/playground/components/Canvas/ComponentRenderer.d.ts +0 -15
  51. package/dist/playground/components/Canvas/ComponentRenderer.d.ts.map +0 -1
  52. package/dist/playground/components/Canvas/ComponentRenderer.js +0 -177
  53. package/dist/playground/components/Canvas/ComponentRenderer.js.map +0 -1
  54. package/dist/playground/components/Canvas/DraggableComponent.d.ts +0 -15
  55. package/dist/playground/components/Canvas/DraggableComponent.d.ts.map +0 -1
  56. package/dist/playground/components/Canvas/DraggableComponent.js +0 -49
  57. package/dist/playground/components/Canvas/DraggableComponent.js.map +0 -1
  58. package/dist/playground/components/Canvas/index.d.ts +0 -9
  59. package/dist/playground/components/Canvas/index.d.ts.map +0 -1
  60. package/dist/playground/components/Canvas/index.js +0 -5
  61. package/dist/playground/components/Canvas/index.js.map +0 -1
  62. package/dist/playground/components/CodeView/CodeView.d.ts +0 -12
  63. package/dist/playground/components/CodeView/CodeView.d.ts.map +0 -1
  64. package/dist/playground/components/CodeView/CodeView.js +0 -77
  65. package/dist/playground/components/CodeView/CodeView.js.map +0 -1
  66. package/dist/playground/components/CodeView/CodeView.module.css +0 -178
  67. package/dist/playground/components/ComponentPalette/ComponentPalette.d.ts +0 -17
  68. package/dist/playground/components/ComponentPalette/ComponentPalette.d.ts.map +0 -1
  69. package/dist/playground/components/ComponentPalette/ComponentPalette.js +0 -138
  70. package/dist/playground/components/ComponentPalette/ComponentPalette.js.map +0 -1
  71. package/dist/playground/components/ComponentPalette/ComponentPalette.module.css +0 -217
  72. package/dist/playground/components/ComponentPalette/index.d.ts +0 -3
  73. package/dist/playground/components/ComponentPalette/index.d.ts.map +0 -1
  74. package/dist/playground/components/ComponentPalette/index.js +0 -2
  75. package/dist/playground/components/ComponentPalette/index.js.map +0 -1
  76. package/dist/playground/components/DropZone/DropZone.d.ts +0 -17
  77. package/dist/playground/components/DropZone/DropZone.d.ts.map +0 -1
  78. package/dist/playground/components/DropZone/DropZone.js +0 -73
  79. package/dist/playground/components/DropZone/DropZone.js.map +0 -1
  80. package/dist/playground/components/DropZone/DropZone.module.css +0 -86
  81. package/dist/playground/components/ExportDialog/ExportDialog.d.ts +0 -10
  82. package/dist/playground/components/ExportDialog/ExportDialog.d.ts.map +0 -1
  83. package/dist/playground/components/ExportDialog/ExportDialog.js +0 -57
  84. package/dist/playground/components/ExportDialog/ExportDialog.js.map +0 -1
  85. package/dist/playground/components/ExportDialog/ExportDialog.module.css +0 -328
  86. package/dist/playground/components/LayoutHelpers/LayoutHelpers.d.ts +0 -134
  87. package/dist/playground/components/LayoutHelpers/LayoutHelpers.d.ts.map +0 -1
  88. package/dist/playground/components/LayoutHelpers/LayoutHelpers.js +0 -254
  89. package/dist/playground/components/LayoutHelpers/LayoutHelpers.js.map +0 -1
  90. package/dist/playground/components/LayoutHelpers/index.d.ts +0 -3
  91. package/dist/playground/components/LayoutHelpers/index.d.ts.map +0 -1
  92. package/dist/playground/components/LayoutHelpers/index.js +0 -2
  93. package/dist/playground/components/LayoutHelpers/index.js.map +0 -1
  94. package/dist/playground/components/Playground/Playground.d.ts +0 -10
  95. package/dist/playground/components/Playground/Playground.d.ts.map +0 -1
  96. package/dist/playground/components/Playground/Playground.js +0 -128
  97. package/dist/playground/components/Playground/Playground.js.map +0 -1
  98. package/dist/playground/components/Playground/Playground.module.css +0 -308
  99. package/dist/playground/components/PropertiesPanel/PropertiesPanel.d.ts +0 -10
  100. package/dist/playground/components/PropertiesPanel/PropertiesPanel.d.ts.map +0 -1
  101. package/dist/playground/components/PropertiesPanel/PropertiesPanel.js +0 -150
  102. package/dist/playground/components/PropertiesPanel/PropertiesPanel.js.map +0 -1
  103. package/dist/playground/components/PropertiesPanel/PropertiesPanel.module.css +0 -155
  104. package/dist/playground/components/PropertiesPanel/index.d.ts +0 -3
  105. package/dist/playground/components/PropertiesPanel/index.d.ts.map +0 -1
  106. package/dist/playground/components/PropertiesPanel/index.js +0 -2
  107. package/dist/playground/components/PropertiesPanel/index.js.map +0 -1
  108. package/dist/playground/components/PropertyEditors/BooleanEditor.d.ts +0 -12
  109. package/dist/playground/components/PropertyEditors/BooleanEditor.d.ts.map +0 -1
  110. package/dist/playground/components/PropertyEditors/BooleanEditor.js +0 -14
  111. package/dist/playground/components/PropertyEditors/BooleanEditor.js.map +0 -1
  112. package/dist/playground/components/PropertyEditors/ColorEditor.d.ts +0 -12
  113. package/dist/playground/components/PropertyEditors/ColorEditor.d.ts.map +0 -1
  114. package/dist/playground/components/PropertyEditors/ColorEditor.js +0 -62
  115. package/dist/playground/components/PropertyEditors/ColorEditor.js.map +0 -1
  116. package/dist/playground/components/PropertyEditors/IconEditor.d.ts +0 -12
  117. package/dist/playground/components/PropertyEditors/IconEditor.d.ts.map +0 -1
  118. package/dist/playground/components/PropertyEditors/IconEditor.js +0 -123
  119. package/dist/playground/components/PropertyEditors/IconEditor.js.map +0 -1
  120. package/dist/playground/components/PropertyEditors/NumberEditor.d.ts +0 -15
  121. package/dist/playground/components/PropertyEditors/NumberEditor.d.ts.map +0 -1
  122. package/dist/playground/components/PropertyEditors/NumberEditor.js +0 -46
  123. package/dist/playground/components/PropertyEditors/NumberEditor.js.map +0 -1
  124. package/dist/playground/components/PropertyEditors/PropertyEditors.module.css +0 -432
  125. package/dist/playground/components/PropertyEditors/SelectEditor.d.ts +0 -19
  126. package/dist/playground/components/PropertyEditors/SelectEditor.d.ts.map +0 -1
  127. package/dist/playground/components/PropertyEditors/SelectEditor.js +0 -17
  128. package/dist/playground/components/PropertyEditors/SelectEditor.js.map +0 -1
  129. package/dist/playground/components/PropertyEditors/SpacingEditor.d.ts +0 -19
  130. package/dist/playground/components/PropertyEditors/SpacingEditor.d.ts.map +0 -1
  131. package/dist/playground/components/PropertyEditors/SpacingEditor.js +0 -162
  132. package/dist/playground/components/PropertyEditors/SpacingEditor.js.map +0 -1
  133. package/dist/playground/components/PropertyEditors/SpacingEditor.module.css +0 -214
  134. package/dist/playground/components/PropertyEditors/TextEditor.d.ts +0 -14
  135. package/dist/playground/components/PropertyEditors/TextEditor.d.ts.map +0 -1
  136. package/dist/playground/components/PropertyEditors/TextEditor.js +0 -38
  137. package/dist/playground/components/PropertyEditors/TextEditor.js.map +0 -1
  138. package/dist/playground/components/PropertyEditors/TokenEditor.d.ts +0 -23
  139. package/dist/playground/components/PropertyEditors/TokenEditor.d.ts.map +0 -1
  140. package/dist/playground/components/PropertyEditors/TokenEditor.js +0 -50
  141. package/dist/playground/components/PropertyEditors/TokenEditor.js.map +0 -1
  142. package/dist/playground/components/PropertyEditors/index.d.ts +0 -20
  143. package/dist/playground/components/PropertyEditors/index.d.ts.map +0 -1
  144. package/dist/playground/components/PropertyEditors/index.js +0 -12
  145. package/dist/playground/components/PropertyEditors/index.js.map +0 -1
  146. package/dist/playground/components/TreeView/TreeView.d.ts +0 -10
  147. package/dist/playground/components/TreeView/TreeView.d.ts.map +0 -1
  148. package/dist/playground/components/TreeView/TreeView.js +0 -146
  149. package/dist/playground/components/TreeView/TreeView.js.map +0 -1
  150. package/dist/playground/components/TreeView/TreeView.module.css +0 -214
  151. package/dist/playground/components/TreeView/index.d.ts +0 -3
  152. package/dist/playground/components/TreeView/index.d.ts.map +0 -1
  153. package/dist/playground/components/TreeView/index.js +0 -2
  154. package/dist/playground/components/TreeView/index.js.map +0 -1
  155. package/dist/playground/config/propertyDefinitions.d.ts +0 -73
  156. package/dist/playground/config/propertyDefinitions.d.ts.map +0 -1
  157. package/dist/playground/config/propertyDefinitions.js +0 -809
  158. package/dist/playground/config/propertyDefinitions.js.map +0 -1
  159. package/dist/playground/hooks/useKeyboardShortcuts.d.ts +0 -38
  160. package/dist/playground/hooks/useKeyboardShortcuts.d.ts.map +0 -1
  161. package/dist/playground/hooks/useKeyboardShortcuts.js +0 -191
  162. package/dist/playground/hooks/useKeyboardShortcuts.js.map +0 -1
  163. package/dist/playground/index.d.ts +0 -21
  164. package/dist/playground/index.d.ts.map +0 -1
  165. package/dist/playground/index.js +0 -23
  166. package/dist/playground/index.js.map +0 -1
  167. package/dist/playground/services/CodeGenerator.d.ts +0 -73
  168. package/dist/playground/services/CodeGenerator.d.ts.map +0 -1
  169. package/dist/playground/services/CodeGenerator.js +0 -359
  170. package/dist/playground/services/CodeGenerator.js.map +0 -1
  171. package/dist/playground/services/DragDropManager.d.ts +0 -95
  172. package/dist/playground/services/DragDropManager.d.ts.map +0 -1
  173. package/dist/playground/services/DragDropManager.js +0 -408
  174. package/dist/playground/services/DragDropManager.js.map +0 -1
  175. package/dist/playground/services/StoryParser.d.ts +0 -73
  176. package/dist/playground/services/StoryParser.d.ts.map +0 -1
  177. package/dist/playground/services/StoryParser.js +0 -419
  178. package/dist/playground/services/StoryParser.js.map +0 -1
  179. package/dist/playground/store/playgroundStore.d.ts +0 -86
  180. package/dist/playground/store/playgroundStore.d.ts.map +0 -1
  181. package/dist/playground/store/playgroundStore.js +0 -337
  182. package/dist/playground/store/playgroundStore.js.map +0 -1
  183. package/dist/playground/stories/PlaygroundDragDrop.stories.d.ts +0 -13
  184. package/dist/playground/stories/PlaygroundDragDrop.stories.d.ts.map +0 -1
  185. package/dist/playground/stories/PlaygroundDragDrop.stories.js +0 -227
  186. package/dist/playground/stories/PlaygroundDragDrop.stories.js.map +0 -1
  187. package/dist/playground/stories/PlaygroundPhase4.stories.d.ts +0 -13
  188. package/dist/playground/stories/PlaygroundPhase4.stories.d.ts.map +0 -1
  189. package/dist/playground/stories/PlaygroundPhase4.stories.js +0 -334
  190. package/dist/playground/stories/PlaygroundPhase4.stories.js.map +0 -1
  191. package/dist/playground/stories/PlaygroundPhase5.stories.d.ts +0 -14
  192. package/dist/playground/stories/PlaygroundPhase5.stories.d.ts.map +0 -1
  193. package/dist/playground/stories/PlaygroundPhase5.stories.js +0 -512
  194. package/dist/playground/stories/PlaygroundPhase5.stories.js.map +0 -1
  195. package/dist/playground/stories/PlaygroundProperties.stories.d.ts +0 -13
  196. package/dist/playground/stories/PlaygroundProperties.stories.d.ts.map +0 -1
  197. package/dist/playground/stories/PlaygroundProperties.stories.js +0 -342
  198. package/dist/playground/stories/PlaygroundProperties.stories.js.map +0 -1
  199. package/dist/playground/types/index.d.ts +0 -251
  200. package/dist/playground/types/index.d.ts.map +0 -1
  201. package/dist/playground/types/index.js +0 -5
  202. package/dist/playground/types/index.js.map +0 -1
  203. package/dist/scripts/verify-framework-adapters.js +0 -105
  204. package/dist/story-generator/componentBlacklist.js.map +0 -1
  205. package/dist/story-generator/componentDiscovery.js.map +0 -1
  206. package/dist/story-generator/configLoader.js.map +0 -1
  207. package/dist/story-generator/considerationsLoader.js.map +0 -1
  208. package/dist/story-generator/documentation-sources.js.map +0 -1
  209. package/dist/story-generator/documentationLoader.js.map +0 -1
  210. package/dist/story-generator/dynamicPackageDiscovery.js.map +0 -1
  211. package/dist/story-generator/enhancedComponentDiscovery.js.map +0 -1
  212. package/dist/story-generator/generateStory.js.map +0 -1
  213. package/dist/story-generator/gitignoreManager.js.map +0 -1
  214. package/dist/story-generator/inMemoryStoryService.d.ts +0 -89
  215. package/dist/story-generator/inMemoryStoryService.d.ts.map +0 -1
  216. package/dist/story-generator/inMemoryStoryService.js +0 -128
  217. package/dist/story-generator/inMemoryStoryService.js.map +0 -1
  218. package/dist/story-generator/logger.js.map +0 -1
  219. package/dist/story-generator/postProcessStory.js.map +0 -1
  220. package/dist/story-generator/postgresStoryService.d.ts +0 -56
  221. package/dist/story-generator/postgresStoryService.d.ts.map +0 -1
  222. package/dist/story-generator/postgresStoryService.js +0 -240
  223. package/dist/story-generator/productionGitignoreManager.d.ts +0 -91
  224. package/dist/story-generator/productionGitignoreManager.d.ts.map +0 -1
  225. package/dist/story-generator/productionGitignoreManager.js +0 -340
  226. package/dist/story-generator/productionGitignoreManager.js.map +0 -1
  227. package/dist/story-generator/promptGenerator.js.map +0 -1
  228. package/dist/story-generator/providerPresets.d.ts +0 -54
  229. package/dist/story-generator/providerPresets.d.ts.map +0 -1
  230. package/dist/story-generator/providerPresets.js +0 -214
  231. package/dist/story-generator/storyHistory.js.map +0 -1
  232. package/dist/story-generator/storyServiceFactory.d.ts +0 -22
  233. package/dist/story-generator/storyServiceFactory.d.ts.map +0 -1
  234. package/dist/story-generator/storyServiceFactory.js +0 -97
  235. package/dist/story-generator/storyServiceInterface.d.ts +0 -85
  236. package/dist/story-generator/storyServiceInterface.d.ts.map +0 -1
  237. package/dist/story-generator/storyServiceInterface.js +0 -5
  238. package/dist/story-generator/storySync.d.ts +0 -68
  239. package/dist/story-generator/storySync.d.ts.map +0 -1
  240. package/dist/story-generator/storySync.js +0 -201
  241. package/dist/story-generator/storySync.js.map +0 -1
  242. package/dist/story-generator/storyTracker.js.map +0 -1
  243. package/dist/story-generator/storyValidator.js.map +0 -1
  244. package/dist/story-generator/test_validation.d.ts +0 -2
  245. package/dist/story-generator/test_validation.d.ts.map +0 -1
  246. package/dist/story-generator/test_validation.js +0 -51
  247. package/dist/story-generator/universalDesignSystemAdapter.js.map +0 -1
  248. package/dist/story-generator/urlRedirectService.js.map +0 -1
  249. package/dist/story-generator/validateStory.js.map +0 -1
  250. package/dist/story-ui.config.js.map +0 -1
  251. package/dist/story-ui.config.loader.d.ts +0 -36
  252. package/dist/story-ui.config.loader.d.ts.map +0 -1
  253. package/dist/story-ui.config.loader.js +0 -205
  254. package/dist/story-ui.config.loader.js.map +0 -1
  255. package/dist/temp/package/templates/StoryUI/StoryUIPanel.js +0 -807
  256. package/dist/temp/package/templates/StoryUI/StoryUIPanel.stories.js +0 -37
  257. package/dist/temp/package/templates/StoryUI/index.js +0 -2
  258. package/dist/templates/StoryUI/StoryUIPanel.js.map +0 -1
  259. package/dist/templates/StoryUI/StoryUIPanel.stories.js.map +0 -1
  260. package/dist/templates/StoryUI/index.js.map +0 -1
  261. package/dist/templates/StoryUI/manager.d.ts +0 -14
  262. package/dist/templates/StoryUI/manager.d.ts.map +0 -1
  263. package/dist/templates/production-app/src/App.d.ts +0 -10
  264. package/dist/templates/production-app/src/App.d.ts.map +0 -1
  265. package/dist/templates/production-app/src/App.js +0 -653
  266. package/dist/templates/production-app/src/LivePreviewRenderer.d.ts +0 -24
  267. package/dist/templates/production-app/src/LivePreviewRenderer.d.ts.map +0 -1
  268. package/dist/templates/production-app/src/LivePreviewRenderer.js +0 -199
  269. package/dist/templates/production-app/src/componentRegistry.d.ts +0 -20
  270. package/dist/templates/production-app/src/componentRegistry.d.ts.map +0 -1
  271. package/dist/templates/production-app/src/componentRegistry.js +0 -316
  272. package/dist/templates/production-app/src/main.d.ts +0 -9
  273. package/dist/templates/production-app/src/main.d.ts.map +0 -1
  274. package/dist/templates/production-app/src/main.js +0 -18
  275. package/dist/templates/production-app/vite.config.d.ts +0 -3
  276. package/dist/templates/production-app/vite.config.d.ts.map +0 -1
  277. package/dist/templates/production-app/vite.config.js +0 -71
  278. package/dist/test-storybooks/angular-material-storybook/src/main.js +0 -66
  279. package/dist/test-storybooks/chakra-storybook/vite.config.js +0 -6
  280. package/dist/test-storybooks/mantine-storybook/vite.config.js +0 -93
  281. package/dist/test-storybooks/web-components-shoelace/vite.config.js +0 -9
  282. package/dist/tsconfig.tsbuildinfo +0 -1
@@ -1,337 +0,0 @@
1
- /**
2
- * Zustand store for Playground state management
3
- */
4
- import { create } from 'zustand';
5
- import { devtools } from 'zustand/middleware';
6
- import { immer } from 'zustand/middleware/immer';
7
- import { enableMapSet } from 'immer';
8
- // Enable MapSet plugin for Immer to support Map and Set objects
9
- enableMapSet();
10
- const initialState = {
11
- // Component State
12
- components: new Map([
13
- ['root', {
14
- id: 'root',
15
- type: 'Container',
16
- displayName: 'Root Container',
17
- props: {},
18
- children: [],
19
- style: {
20
- width: '100%',
21
- minHeight: '100vh',
22
- padding: '20px'
23
- }
24
- }]
25
- ]),
26
- rootId: 'root',
27
- // Selection State
28
- selectedIds: new Set(),
29
- hoveredId: null,
30
- focusedId: null,
31
- // Drag State
32
- draggedItem: null,
33
- dropZones: new Map(),
34
- dragState: 'idle',
35
- // UI State
36
- mode: 'edit',
37
- sidebarTab: 'ai',
38
- propertiesPanelOpen: true,
39
- canvasZoom: 1,
40
- canvasOffset: { x: 0, y: 0 },
41
- showGrid: true,
42
- snapToGrid: true,
43
- gridSize: 8,
44
- // History
45
- history: [],
46
- historyIndex: -1,
47
- maxHistorySize: 50,
48
- // AI Integration
49
- generatedStoryCode: null,
50
- isParsingStory: false,
51
- parseError: null,
52
- // Component Registry
53
- availableComponents: [],
54
- loadingComponents: new Set(),
55
- failedComponents: new Map()
56
- };
57
- export const usePlaygroundStore = create()(devtools(immer((set, get) => ({
58
- ...initialState,
59
- // Component Actions
60
- addComponent: (component) => set((state) => {
61
- state.components.set(component.id, component);
62
- // Add to parent's children if specified
63
- if (component.parentId) {
64
- const parent = state.components.get(component.parentId);
65
- if (parent) {
66
- if (!parent.children)
67
- parent.children = [];
68
- parent.children.push(component.id);
69
- }
70
- }
71
- // Save snapshot after adding
72
- get().saveSnapshot('Add component');
73
- }),
74
- updateComponent: (id, updates) => {
75
- set((state) => {
76
- const component = state.components.get(id);
77
- if (component) {
78
- Object.assign(component, updates);
79
- }
80
- });
81
- // Only save snapshot for significant changes, not every keystroke
82
- const significantChanges = ['style', 'props', 'textContent', 'hidden'];
83
- if (Object.keys(updates).some(key => significantChanges.includes(key))) {
84
- // Debounce snapshot saving to avoid too many snapshots
85
- setTimeout(() => {
86
- get().saveSnapshot('Update component');
87
- }, 500);
88
- }
89
- },
90
- deleteComponent: (id) => set((state) => {
91
- const component = state.components.get(id);
92
- if (!component || id === state.rootId)
93
- return;
94
- // Remove from parent's children
95
- if (component.parentId) {
96
- const parent = state.components.get(component.parentId);
97
- if (parent && parent.children) {
98
- parent.children = parent.children.filter(childId => childId !== id);
99
- }
100
- }
101
- // Delete component and all its children recursively
102
- const deleteRecursive = (compId) => {
103
- const comp = state.components.get(compId);
104
- if (comp?.children) {
105
- comp.children.forEach(childId => deleteRecursive(childId));
106
- }
107
- state.components.delete(compId);
108
- };
109
- deleteRecursive(id);
110
- state.selectedIds.delete(id);
111
- // Save snapshot after deletion
112
- get().saveSnapshot('Delete component');
113
- }),
114
- moveComponent: (id, newParentId, index) => set((state) => {
115
- const component = state.components.get(id);
116
- const newParent = state.components.get(newParentId);
117
- if (!component || !newParent)
118
- return;
119
- // Remove from old parent
120
- if (component.parentId) {
121
- const oldParent = state.components.get(component.parentId);
122
- if (oldParent?.children) {
123
- oldParent.children = oldParent.children.filter(childId => childId !== id);
124
- }
125
- }
126
- // Add to new parent
127
- if (!newParent.children)
128
- newParent.children = [];
129
- newParent.children.splice(index, 0, id);
130
- component.parentId = newParentId;
131
- // Save snapshot after move
132
- get().saveSnapshot('Move component');
133
- }),
134
- duplicateComponent: (id) => {
135
- const state = get();
136
- const component = state.components.get(id);
137
- if (!component)
138
- return '';
139
- const duplicateRecursive = (comp, newParentId) => {
140
- const newId = `${comp.type}_${Date.now()}_${Math.random().toString(36).substr(2, 9)}`;
141
- const duplicate = {
142
- ...comp,
143
- id: newId,
144
- parentId: newParentId ?? comp.parentId,
145
- children: comp.children?.map(childId => {
146
- const childComp = state.components.get(childId);
147
- if (childComp) {
148
- const duplicatedChild = duplicateRecursive(childComp, newId);
149
- state.components.set(duplicatedChild.id, duplicatedChild);
150
- return duplicatedChild.id;
151
- }
152
- return childId;
153
- })
154
- };
155
- return duplicate;
156
- };
157
- const duplicate = duplicateRecursive(component, component.parentId);
158
- state.addComponent(duplicate);
159
- return duplicate.id;
160
- },
161
- clearComponents: () => set((state) => {
162
- state.components.clear();
163
- state.selectedIds.clear();
164
- state.hoveredId = null;
165
- state.focusedId = null;
166
- // Save snapshot after clearing
167
- get().saveSnapshot('Clear components');
168
- }),
169
- // Selection Actions
170
- selectComponent: (id, multi = false) => set((state) => {
171
- if (multi) {
172
- if (state.selectedIds.has(id)) {
173
- state.selectedIds.delete(id);
174
- }
175
- else {
176
- state.selectedIds.add(id);
177
- }
178
- }
179
- else {
180
- state.selectedIds.clear();
181
- state.selectedIds.add(id);
182
- }
183
- state.focusedId = id;
184
- // Open properties panel when selecting a component
185
- if (!state.propertiesPanelOpen && state.selectedIds.size > 0) {
186
- state.propertiesPanelOpen = true;
187
- }
188
- }),
189
- deselectComponent: (id) => set((state) => {
190
- state.selectedIds.delete(id);
191
- if (state.focusedId === id) {
192
- state.focusedId = null;
193
- }
194
- }),
195
- selectAll: () => set((state) => {
196
- state.components.forEach((_, id) => {
197
- if (id !== state.rootId) {
198
- state.selectedIds.add(id);
199
- }
200
- });
201
- }),
202
- deselectAll: () => set((state) => {
203
- state.selectedIds.clear();
204
- state.focusedId = null;
205
- }),
206
- setHoveredComponent: (id) => set((state) => {
207
- state.hoveredId = id;
208
- }),
209
- // Drag Actions
210
- startDrag: (item) => set((state) => {
211
- state.draggedItem = item;
212
- state.dragState = 'dragging';
213
- }),
214
- updateDrag: (updates) => set((state) => {
215
- if (state.draggedItem) {
216
- Object.assign(state.draggedItem, updates);
217
- }
218
- }),
219
- endDrag: () => set((state) => {
220
- state.draggedItem = null;
221
- state.dragState = 'idle';
222
- }),
223
- registerDropZone: (zone) => set((state) => {
224
- state.dropZones.set(zone.id, zone);
225
- }),
226
- unregisterDropZone: (id) => set((state) => {
227
- state.dropZones.delete(id);
228
- }),
229
- updateDropZone: (id, updates) => set((state) => {
230
- const zone = state.dropZones.get(id);
231
- if (zone) {
232
- Object.assign(zone, updates);
233
- }
234
- }),
235
- // UI Actions
236
- setMode: (mode) => set({ mode }),
237
- setSidebarTab: (tab) => set({ sidebarTab: tab }),
238
- togglePropertiesPanel: () => set((state) => {
239
- state.propertiesPanelOpen = !state.propertiesPanelOpen;
240
- }),
241
- setCanvasZoom: (zoom) => set((state) => {
242
- state.canvasZoom = Math.min(Math.max(zoom, 0.25), 4);
243
- }),
244
- panCanvas: (dx, dy) => set((state) => {
245
- state.canvasOffset.x += dx;
246
- state.canvasOffset.y += dy;
247
- }),
248
- resetCanvas: () => set((state) => {
249
- state.canvasZoom = 1;
250
- state.canvasOffset = { x: 0, y: 0 };
251
- }),
252
- toggleGrid: () => set((state) => {
253
- state.showGrid = !state.showGrid;
254
- }),
255
- toggleSnapToGrid: () => set((state) => {
256
- state.snapToGrid = !state.snapToGrid;
257
- }),
258
- setGridSize: (size) => set({ gridSize: size }),
259
- // History Actions
260
- undo: () => set((state) => {
261
- if (state.historyIndex > 0) {
262
- state.historyIndex--;
263
- const snapshot = state.history[state.historyIndex];
264
- state.components = new Map(snapshot.components);
265
- }
266
- }),
267
- redo: () => set((state) => {
268
- if (state.historyIndex < state.history.length - 1) {
269
- state.historyIndex++;
270
- const snapshot = state.history[state.historyIndex];
271
- state.components = new Map(snapshot.components);
272
- }
273
- }),
274
- saveSnapshot: (description) => set((state) => {
275
- const snapshot = {
276
- components: new Map(state.components),
277
- timestamp: Date.now(),
278
- description
279
- };
280
- // Remove any history after current index
281
- state.history = state.history.slice(0, state.historyIndex + 1);
282
- // Add new snapshot
283
- state.history.push(snapshot);
284
- // Limit history size
285
- if (state.history.length > state.maxHistorySize) {
286
- state.history.shift();
287
- }
288
- else {
289
- state.historyIndex++;
290
- }
291
- }),
292
- clearHistory: () => set((state) => {
293
- state.history = [];
294
- state.historyIndex = -1;
295
- }),
296
- // AI Actions
297
- setGeneratedStoryCode: (code) => set({ generatedStoryCode: code }),
298
- setIsParsingStory: (parsing) => set({ isParsingStory: parsing }),
299
- setParseError: (error) => set({ parseError: error }),
300
- loadComponentsFromStory: (components) => set((state) => {
301
- // Clear existing components except root
302
- state.components.clear();
303
- state.components.set('root', initialState.components.get('root'));
304
- // Add new components
305
- components.forEach(component => {
306
- state.components.set(component.id, component);
307
- });
308
- // Update root's children
309
- const root = state.components.get('root');
310
- if (root) {
311
- root.children = components.filter(c => !c.parentId || c.parentId === 'root').map(c => c.id);
312
- }
313
- // Clear selection
314
- state.selectedIds.clear();
315
- // Save snapshot
316
- get().saveSnapshot('Load from AI generation');
317
- }),
318
- // Component Registry Actions
319
- setAvailableComponents: (components) => set({ availableComponents: components }),
320
- addLoadingComponent: (name) => set((state) => {
321
- state.loadingComponents.add(name);
322
- }),
323
- removeLoadingComponent: (name) => set((state) => {
324
- state.loadingComponents.delete(name);
325
- }),
326
- setComponentError: (name, error) => set((state) => {
327
- state.failedComponents.set(name, error);
328
- }),
329
- // Utility Actions
330
- reset: () => set(initialState),
331
- loadFromSnapshot: (snapshot) => set((state) => {
332
- state.components = new Map(snapshot.components);
333
- state.selectedIds.clear();
334
- get().saveSnapshot('Load from snapshot');
335
- })
336
- })), { name: 'playground-store' }));
337
- //# sourceMappingURL=playgroundStore.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"playgroundStore.js","sourceRoot":"","sources":["../../../playground/store/playgroundStore.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAErC,gEAAgE;AAChE,YAAY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storybook/react';
5
- import { Playground } from '../components/Playground/Playground';
6
- declare const meta: Meta<typeof Playground>;
7
- export default meta;
8
- type Story = StoryObj<typeof Playground>;
9
- export declare const BasicDragDrop: Story;
10
- export declare const EmptyCanvas: Story;
11
- export declare const WithAIAssistant: Story;
12
- export declare const NestedComponents: Story;
13
- //# sourceMappingURL=PlaygroundDragDrop.stories.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PlaygroundDragDrop.stories.d.ts","sourceRoot":"","sources":["../../../playground/stories/PlaygroundDragDrop.stories.tsx"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAGjE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAMjC,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAC;AA+FzC,eAAO,MAAM,aAAa,EAAE,KAgB3B,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAkBzB,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,KAkB7B,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,KAsF9B,CAAC"}
@@ -1,227 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- /**
3
- * Storybook stories for testing Playground drag & drop functionality
4
- */
5
- import React from 'react';
6
- import { Playground } from '../components/Playground/Playground';
7
- import { usePlaygroundStore } from '../store/playgroundStore';
8
- const meta = {
9
- title: 'StoryUI/Playground/DragDrop',
10
- component: Playground,
11
- parameters: {
12
- layout: 'fullscreen',
13
- },
14
- };
15
- export default meta;
16
- // Helper to initialize the store with test data
17
- const initializeWithTestData = () => {
18
- const store = usePlaygroundStore.getState();
19
- // Clear existing components
20
- store.components.clear();
21
- // Add root container
22
- store.addComponent({
23
- id: 'root',
24
- type: 'Container',
25
- displayName: 'Root Container',
26
- props: {
27
- style: {
28
- padding: '20px',
29
- minHeight: '100vh',
30
- background: '#f5f5f5'
31
- }
32
- },
33
- children: []
34
- });
35
- // Add a few test components
36
- store.addComponent({
37
- id: 'card1',
38
- type: 'Card',
39
- displayName: 'Sample Card',
40
- parentId: 'root',
41
- props: {
42
- style: {
43
- padding: '16px',
44
- background: 'white',
45
- borderRadius: '8px',
46
- marginBottom: '16px',
47
- boxShadow: '0 2px 4px rgba(0,0,0,0.1)'
48
- }
49
- },
50
- children: []
51
- });
52
- store.addComponent({
53
- id: 'text1',
54
- type: 'Text',
55
- displayName: 'Sample Text',
56
- parentId: 'card1',
57
- textContent: 'This is a draggable text component',
58
- props: {
59
- style: {
60
- fontSize: '16px',
61
- color: '#333'
62
- }
63
- }
64
- });
65
- store.addComponent({
66
- id: 'button1',
67
- type: 'Button',
68
- displayName: 'Sample Button',
69
- parentId: 'root',
70
- textContent: 'Click Me',
71
- props: {
72
- style: {
73
- padding: '8px 16px',
74
- background: '#3b82f6',
75
- color: 'white',
76
- border: 'none',
77
- borderRadius: '6px',
78
- cursor: 'pointer'
79
- }
80
- }
81
- });
82
- // Update root children
83
- const root = store.components.get('root');
84
- if (root) {
85
- root.children = ['card1', 'button1'];
86
- store.components.set('root', root);
87
- }
88
- // Update card children
89
- const card = store.components.get('card1');
90
- if (card) {
91
- card.children = ['text1'];
92
- store.components.set('card1', card);
93
- }
94
- // Set mode to edit
95
- store.setMode('edit');
96
- // Open component palette
97
- store.setSidebarTab('components');
98
- };
99
- export const BasicDragDrop = {
100
- render: () => {
101
- React.useEffect(() => {
102
- initializeWithTestData();
103
- }, []);
104
- return _jsx(Playground, { initialMode: "edit" });
105
- },
106
- name: 'Basic Drag & Drop',
107
- parameters: {
108
- docs: {
109
- description: {
110
- story: 'Test drag & drop functionality with pre-populated components. Try dragging components from the palette or rearranging existing components.'
111
- }
112
- }
113
- }
114
- };
115
- export const EmptyCanvas = {
116
- render: () => {
117
- React.useEffect(() => {
118
- const store = usePlaygroundStore.getState();
119
- store.setMode('edit');
120
- store.setSidebarTab('components');
121
- }, []);
122
- return _jsx(Playground, { initialMode: "edit" });
123
- },
124
- name: 'Empty Canvas',
125
- parameters: {
126
- docs: {
127
- description: {
128
- story: 'Start with an empty canvas. Drag components from the palette to build your layout.'
129
- }
130
- }
131
- }
132
- };
133
- export const WithAIAssistant = {
134
- render: () => {
135
- React.useEffect(() => {
136
- const store = usePlaygroundStore.getState();
137
- store.setMode('edit');
138
- store.setSidebarTab('ai');
139
- }, []);
140
- return _jsx(Playground, { initialMode: "edit" });
141
- },
142
- name: 'With AI Assistant',
143
- parameters: {
144
- docs: {
145
- description: {
146
- story: 'Use the AI Assistant to generate a layout, then drag & drop to refine it.'
147
- }
148
- }
149
- }
150
- };
151
- export const NestedComponents = {
152
- render: () => {
153
- React.useEffect(() => {
154
- const store = usePlaygroundStore.getState();
155
- // Clear and create nested structure
156
- store.components.clear();
157
- // Root
158
- store.addComponent({
159
- id: 'root',
160
- type: 'Container',
161
- displayName: 'Root',
162
- props: { style: { padding: '20px', minHeight: '100vh' } },
163
- children: []
164
- });
165
- // Main container
166
- store.addComponent({
167
- id: 'main',
168
- type: 'Box',
169
- displayName: 'Main Container',
170
- parentId: 'root',
171
- props: { style: { padding: '20px', background: '#fff' } },
172
- children: []
173
- });
174
- // Nested containers
175
- store.addComponent({
176
- id: 'row1',
177
- type: 'HStack',
178
- displayName: 'Row 1',
179
- parentId: 'main',
180
- props: { style: { gap: '16px', marginBottom: '16px' } },
181
- children: []
182
- });
183
- store.addComponent({
184
- id: 'col1',
185
- type: 'Box',
186
- displayName: 'Column 1',
187
- parentId: 'row1',
188
- props: { style: { flex: 1, padding: '12px', background: '#f0f0f0' } },
189
- children: []
190
- });
191
- store.addComponent({
192
- id: 'col2',
193
- type: 'Box',
194
- displayName: 'Column 2',
195
- parentId: 'row1',
196
- props: { style: { flex: 1, padding: '12px', background: '#f0f0f0' } },
197
- children: []
198
- });
199
- // Build tree structure
200
- const root = store.components.get('root');
201
- const main = store.components.get('main');
202
- const row1 = store.components.get('row1');
203
- const col1 = store.components.get('col1');
204
- const col2 = store.components.get('col2');
205
- if (root && main && row1 && col1 && col2) {
206
- row1.children = ['col1', 'col2'];
207
- main.children = ['row1'];
208
- root.children = ['main'];
209
- store.components.set('row1', row1);
210
- store.components.set('main', main);
211
- store.components.set('root', root);
212
- }
213
- store.setMode('edit');
214
- store.setSidebarTab('components');
215
- }, []);
216
- return _jsx(Playground, { initialMode: "edit" });
217
- },
218
- name: 'Nested Components',
219
- parameters: {
220
- docs: {
221
- description: {
222
- story: 'Test drag & drop with deeply nested component structures.'
223
- }
224
- }
225
- }
226
- };
227
- //# sourceMappingURL=PlaygroundDragDrop.stories.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PlaygroundDragDrop.stories.js","sourceRoot":"","sources":["../../../playground/stories/PlaygroundDragDrop.stories.tsx"],"names":[],"mappings":";AAAA;;GAEG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACjE,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAE9D,MAAM,IAAI,GAA4B;IACpC,KAAK,EAAE,6BAA6B;IACpC,SAAS,EAAE,UAAU;IACrB,UAAU,EAAE;QACV,MAAM,EAAE,YAAY;KACrB;CACF,CAAC;AAEF,eAAe,IAAI,CAAC;AAGpB,gDAAgD;AAChD,MAAM,sBAAsB,GAAG,GAAG,EAAE;IAClC,MAAM,KAAK,GAAG,kBAAkB,CAAC,QAAQ,EAAE,CAAC;IAE5C,4BAA4B;IAC5B,KAAK,CAAC,UAAU,CAAC,KAAK,EAAE,CAAC;IAEzB,qBAAqB;IACrB,KAAK,CAAC,YAAY,CAAC;QACjB,EAAE,EAAE,MAAM;QACV,IAAI,EAAE,WAAW;QACjB,WAAW,EAAE,gBAAgB;QAC7B,KAAK,EAAE;YACL,K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ybook/react';
5
- import { Playground } from '../components/Playground/Playground';
6
- declare const meta: Meta<typeof Playground>;
7
- export default meta;
8
- type Story = StoryObj<typeof Playground>;
9
- export declare const ComponentSearch: Story;
10
- export declare const LayoutHelpers: Story;
11
- export declare const TreeView: Story;
12
- export declare const CompletePhase4: Story;
13
- //# sourceMappingURL=PlaygroundPhase4.stories.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PlaygroundPhase4.stories.d.ts","sourceRoot":"","sources":["../../../playground/stories/PlaygroundPhase4.stories.tsx"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAGjE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CAMjC,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAC;AA8QzC,eAAO,MAAM,eAAe,EAAE,KAkB7B,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,KAkB3B,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAkBtB,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,KAuB5B,CAAC"}