@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,419 +0,0 @@
1
- /**
2
- * StoryParser - Parses AI-generated story code into playground components
3
- */
4
- export class StoryParser {
5
- constructor() {
6
- this.componentIdCounter = 0;
7
- }
8
- /**
9
- * Parse story code into playground components
10
- */
11
- async parseStoryToComponents(code) {
12
- try {
13
- // Extract the story component definition
14
- const componentMatch = this.extractStoryComponent(code);
15
- if (!componentMatch) {
16
- return {
17
- success: false,
18
- components: [],
19
- imports: [],
20
- error: 'Could not find story component in code'
21
- };
22
- }
23
- // Extract imports
24
- const imports = this.extractImports(code);
25
- // Parse JSX into components
26
- const components = this.parseJSX(componentMatch.jsx);
27
- // Build component tree
28
- const tree = this.buildComponentTree(components);
29
- return {
30
- success: true,
31
- components: tree,
32
- imports,
33
- warnings: componentMatch.warnings
34
- };
35
- }
36
- catch (error) {
37
- return {
38
- success: false,
39
- components: [],
40
- imports: [],
41
- error: error instanceof Error ? error.message : 'Unknown parsing error'
42
- };
43
- }
44
- }
45
- /**
46
- * Extract the story component from the code
47
- */
48
- extractStoryComponent(code) {
49
- const warnings = [];
50
- // Try to find the story export
51
- const storyExportRegex = /export\s+const\s+\w+\s*=\s*\(\)\s*=>\s*{?\s*return\s*\(([\s\S]*?)\);?\s*}?;?/;
52
- const storyMatch = code.match(storyExportRegex);
53
- if (storyMatch) {
54
- return { jsx: storyMatch[1].trim(), warnings };
55
- }
56
- // Try to find a default export
57
- const defaultExportRegex = /export\s+default\s+(?:function\s+\w+\s*\(\)|(?:\(\)|\w+)\s*=>\s*){?\s*return\s*\(([\s\S]*?)\);?\s*}?;?/;
58
- const defaultMatch = code.match(defaultExportRegex);
59
- if (defaultMatch) {
60
- return { jsx: defaultMatch[1].trim(), warnings };
61
- }
62
- // Try to find any JSX in the code
63
- const jsxRegex = /<([A-Z][A-Za-z0-9]*)[^>]*>[\s\S]*?<\/\1>|<([A-Z][A-Za-z0-9]*)[^>]*\/>/;
64
- const jsxMatch = code.match(jsxRegex);
65
- if (jsxMatch) {
66
- warnings.push('Could not find proper story export, extracting raw JSX');
67
- // Find all JSX in the code
68
- const allJsx = code.match(/<[A-Z][^>]*>[\s\S]*?<\/[A-Z][^>]*>|<[A-Z][^>]*\/>/g);
69
- if (allJsx) {
70
- return { jsx: allJsx.join('\n'), warnings };
71
- }
72
- }
73
- return null;
74
- }
75
- /**
76
- * Extract import statements from code
77
- */
78
- extractImports(code) {
79
- const imports = [];
80
- const importRegex = /import\s+(?:(\*\s+as\s+\w+)|(?:(\w+)|{([^}]+)}))?\s*(?:,\s*(?:(\w+)|{([^}]+)}))?\s+from\s+['"]([^'"]+)['"]/g;
81
- let match;
82
- while ((match = importRegex.exec(code)) !== null) {
83
- const [, namespace, defaultImport1, named1, defaultImport2, named2, source] = match;
84
- const statement = {
85
- source,
86
- specifiers: []
87
- };
88
- if (namespace) {
89
- statement.isNamespace = true;
90
- statement.specifiers.push(namespace.replace(/\*\s+as\s+/, ''));
91
- }
92
- if (defaultImport1 || defaultImport2) {
93
- statement.isDefault = true;
94
- statement.specifiers.push(defaultImport1 || defaultImport2);
95
- }
96
- if (named1 || named2) {
97
- const namedImports = (named1 || named2)
98
- .split(',')
99
- .map(s => s.trim())
100
- .filter(Boolean);
101
- statement.specifiers.push(...namedImports);
102
- }
103
- imports.push(statement);
104
- }
105
- return imports;
106
- }
107
- /**
108
- * Parse JSX string into component objects
109
- */
110
- parseJSX(jsx) {
111
- const components = [];
112
- // Simple JSX parser - in production, we'd use a proper parser like @babel/parser
113
- const parseElement = (jsxString, parentId) => {
114
- // Match opening tag
115
- const openTagRegex = /^<([A-Z][A-Za-z0-9\.]*)\s*([^>]*)>/;
116
- const openMatch = jsxString.match(openTagRegex);
117
- if (!openMatch) {
118
- // Check if it's just text content
119
- const textContent = jsxString.trim();
120
- if (textContent && !textContent.startsWith('<')) {
121
- return {
122
- id: this.generateId(),
123
- type: 'Text',
124
- props: {},
125
- textContent,
126
- parentId
127
- };
128
- }
129
- return null;
130
- }
131
- const [fullOpenTag, tagName, propsString] = openMatch;
132
- const isSelfClosing = propsString.endsWith('/');
133
- // Parse props
134
- const props = this.parseProps(isSelfClosing ? propsString.slice(0, -1) : propsString);
135
- // Create component
136
- const component = {
137
- id: this.generateId(),
138
- type: tagName,
139
- displayName: tagName,
140
- props,
141
- parentId
142
- };
143
- // Extract styles if present
144
- if (props.style && typeof props.style === 'string') {
145
- component.style = this.parseInlineStyles(props.style);
146
- delete props.style;
147
- }
148
- if (!isSelfClosing) {
149
- // Find closing tag
150
- const closeTagRegex = new RegExp(`<\\/${tagName}>`);
151
- const closeIndex = jsxString.search(closeTagRegex);
152
- if (closeIndex > 0) {
153
- const contentStart = fullOpenTag.length;
154
- const content = jsxString.substring(contentStart, closeIndex);
155
- // Parse children
156
- if (content.trim()) {
157
- const childComponents = this.parseChildrenAsComponents(content, component.id);
158
- component.children = childComponents.map(c => c.id);
159
- }
160
- }
161
- }
162
- return component;
163
- };
164
- // Parse all top-level elements
165
- const elementRegex = /<([A-Z][A-Za-z0-9\.]*)[^>]*>[\s\S]*?<\/\1>|<([A-Z][A-Za-z0-9\.]*)[^>]*\/>/g;
166
- let match;
167
- while ((match = elementRegex.exec(jsx)) !== null) {
168
- const element = parseElement(match[0]);
169
- if (element) {
170
- components.push(element);
171
- }
172
- }
173
- return components;
174
- }
175
- /**
176
- * Parse JSX props string
177
- */
178
- parseProps(propsString) {
179
- const props = {};
180
- if (!propsString.trim())
181
- return props;
182
- // Match prop patterns: name="value", name={value}, name
183
- const propRegex = /(\w+)(?:=(?:"([^"]*)"|'([^']*)'|{([^}]*)}|\{([^}]*)\}))?/g;
184
- let match;
185
- while ((match = propRegex.exec(propsString)) !== null) {
186
- const [, name, doubleQuoted, singleQuoted, expression1, expression2] = match;
187
- if (doubleQuoted !== undefined) {
188
- props[name] = doubleQuoted;
189
- }
190
- else if (singleQuoted !== undefined) {
191
- props[name] = singleQuoted;
192
- }
193
- else if (expression1 !== undefined || expression2 !== undefined) {
194
- const expr = expression1 || expression2;
195
- // Try to evaluate simple expressions
196
- props[name] = this.evaluateExpression(expr);
197
- }
198
- else {
199
- // Boolean prop
200
- props[name] = true;
201
- }
202
- }
203
- return props;
204
- }
205
- /**
206
- * Parse inline style string
207
- */
208
- parseInlineStyles(styleString) {
209
- const styles = {};
210
- // Handle object notation {key: value}
211
- if (styleString.startsWith('{') && styleString.endsWith('}')) {
212
- styleString = styleString.slice(1, -1);
213
- }
214
- // Parse CSS properties
215
- const styleRegex = /(\w+):\s*['"]?([^'",;]+)['"]?/g;
216
- let match;
217
- while ((match = styleRegex.exec(styleString)) !== null) {
218
- const [, property, value] = match;
219
- // Convert kebab-case to camelCase
220
- const camelProperty = property.replace(/-([a-z])/g, (_, letter) => letter.toUpperCase());
221
- styles[camelProperty] = value;
222
- }
223
- return styles;
224
- }
225
- /**
226
- * Parse children content
227
- */
228
- parseChildren(content, parentId) {
229
- const children = [];
230
- // Find all child elements
231
- const elementRegex = /<([A-Z][A-Za-z0-9\.]*)[^>]*>[\s\S]*?<\/\1>|<([A-Z][A-Za-z0-9\.]*)[^>]*\/>/g;
232
- let lastIndex = 0;
233
- let match;
234
- while ((match = elementRegex.exec(content)) !== null) {
235
- // Check for text content before this element
236
- if (match.index > lastIndex) {
237
- const textContent = content.substring(lastIndex, match.index).trim();
238
- if (textContent) {
239
- const textId = this.generateId();
240
- children.push(textId);
241
- }
242
- }
243
- // Parse the element
244
- const child = this.parseJSX(match[0])[0];
245
- if (child) {
246
- child.parentId = parentId;
247
- children.push(child.id);
248
- }
249
- lastIndex = match.index + match[0].length;
250
- }
251
- // Check for text content after last element
252
- if (lastIndex < content.length) {
253
- const textContent = content.substring(lastIndex).trim();
254
- if (textContent) {
255
- const textId = this.generateId();
256
- children.push(textId);
257
- }
258
- }
259
- return children;
260
- }
261
- /**
262
- * Parse children content and return components
263
- */
264
- parseChildrenAsComponents(content, parentId) {
265
- const children = [];
266
- // Find all child elements
267
- const elementRegex = /<([A-Z][A-Za-z0-9\.]*)[^>]*>[\s\S]*?<\/\1>|<([A-Z][A-Za-z0-9\.]*)[^>]*\/>/g;
268
- let lastIndex = 0;
269
- let match;
270
- while ((match = elementRegex.exec(content)) !== null) {
271
- // Check for text content before this element
272
- if (match.index > lastIndex) {
273
- const textContent = content.substring(lastIndex, match.index).trim();
274
- if (textContent) {
275
- children.push({
276
- id: this.generateId(),
277
- type: 'Text',
278
- props: {},
279
- textContent,
280
- parentId
281
- });
282
- }
283
- }
284
- // Parse the element
285
- const child = this.parseJSX(match[0])[0];
286
- if (child) {
287
- child.parentId = parentId;
288
- children.push(child);
289
- }
290
- lastIndex = match.index + match[0].length;
291
- }
292
- // Check for text content after last element
293
- if (lastIndex < content.length) {
294
- const textContent = content.substring(lastIndex).trim();
295
- if (textContent) {
296
- children.push({
297
- id: this.generateId(),
298
- type: 'Text',
299
- props: {},
300
- textContent,
301
- parentId
302
- });
303
- }
304
- }
305
- return children;
306
- }
307
- /**
308
- * Evaluate simple JavaScript expressions
309
- */
310
- evaluateExpression(expr) {
311
- expr = expr.trim();
312
- // Boolean values
313
- if (expr === 'true')
314
- return true;
315
- if (expr === 'false')
316
- return false;
317
- // Null/undefined
318
- if (expr === 'null')
319
- return null;
320
- if (expr === 'undefined')
321
- return undefined;
322
- // Numbers
323
- if (/^-?\d+(\.\d+)?$/.test(expr)) {
324
- return parseFloat(expr);
325
- }
326
- // Arrays
327
- if (expr.startsWith('[') && expr.endsWith(']')) {
328
- try {
329
- // Simple array parsing - in production, use proper parser
330
- return JSON.parse(expr);
331
- }
332
- catch {
333
- return expr;
334
- }
335
- }
336
- // Objects
337
- if (expr.startsWith('{') && expr.endsWith('}')) {
338
- try {
339
- // Convert JS object notation to JSON
340
- const jsonStr = expr
341
- .replace(/(\w+):/g, '"$1":')
342
- .replace(/'/g, '"');
343
- return JSON.parse(jsonStr);
344
- }
345
- catch {
346
- return expr;
347
- }
348
- }
349
- // Default to string
350
- return expr;
351
- }
352
- /**
353
- * Build component tree from flat list
354
- */
355
- buildComponentTree(components) {
356
- const tree = [];
357
- const componentMap = new Map();
358
- // First pass: create map
359
- components.forEach(component => {
360
- componentMap.set(component.id, component);
361
- if (!component.children) {
362
- component.children = [];
363
- }
364
- });
365
- // Second pass: build tree
366
- components.forEach(component => {
367
- if (component.parentId) {
368
- const parent = componentMap.get(component.parentId);
369
- if (parent) {
370
- if (!parent.children)
371
- parent.children = [];
372
- parent.children.push(component.id);
373
- }
374
- }
375
- else {
376
- tree.push(component);
377
- }
378
- });
379
- return tree;
380
- }
381
- /**
382
- * Generate unique component ID
383
- */
384
- generateId() {
385
- return `component_${Date.now()}_${this.componentIdCounter++}`;
386
- }
387
- /**
388
- * Validate parsed components
389
- */
390
- validateComponents(components) {
391
- const errors = [];
392
- const warnings = [];
393
- // Check for empty tree
394
- if (components.length === 0) {
395
- errors.push('No components found in story');
396
- }
397
- // Check for missing IDs
398
- components.forEach(component => {
399
- if (!component.id) {
400
- errors.push(`Component of type ${component.type} is missing an ID`);
401
- }
402
- // Check for unknown component types
403
- // This would be validated against registered components in production
404
- if (!component.type) {
405
- errors.push(`Component ${component.id} is missing a type`);
406
- }
407
- // Warn about missing display names
408
- if (!component.displayName) {
409
- warnings.push(`Component ${component.id} is missing a display name`);
410
- }
411
- });
412
- return {
413
- valid: errors.length === 0,
414
- errors,
415
- warnings
416
- };
417
- }
418
- }
419
- //# sourceMappingURL=StoryParser.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"StoryParser.js","sourceRoot":"","sources":["../../../playground/services/StoryParser.ts"],"names":[],"mappings":"AAAA;;GAEG;AAmBH,MAAM,OAAO,WAAW;IAAxB;QACU,uBAAkB,GAAG,CAAC,CAAC;IAgejC,CAAC;IA9dC;;OAEG;IACH,KAAK,CAAC,sBAAsB,CAAC,IAAY;QACvC,IAAI,CAAC;YACH,yCAAyC;YACzC,MAAM,cAAc,GAAG,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,CAAC;YACxD,IAAI,C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IAAI,CAAC,kBAAkB,EAAE,EAAE,CAAC;IAChE,CAAC;IAED;;OAEG;IACH,kBAAkB,CAAC,UAAiC;QAKlD,MAAM,MAAM,GAAa,EAAE,CAAC;QAC5B,MAAM,QAAQ,GAAa,EAAE,CAAC;QAE9B,uBAAuB;QACvB,IAAI,UAAU,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YAC5B,MAAM,CAAC,IAAI,CAAC,8BAA8B,CAAC,CAAC;QAC9C,CAAC;QAED,wBAAwB;QACxB,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE;YAC7B,IAAI,CAAC,SAAS,CAAC,EAAE,EAAE,CAAC;gBAClB,MAAM,CAAC,IAAI,CAAC,qBAAqB,SAAS,CAAC,IAAI,mBAAmB,CAAC,CAAC;YACtE,CAAC;YAED,oCAAoC;YACpC,sEAAsE;YACtE,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,CAAC;gBACpB,MAAM,CAAC,IAAI,CAAC,aAAa,SAAS,CAAC,EAAE,oBAAoB,CAAC,CAAC;YAC7D,CAAC;YAED,mCAAmC;YACnC,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE,CAAC;gBAC3B,QAAQ,CAAC,IAAI,CAAC,aAAa,SAAS,CAAC,EAAE,4BAA4B,CAAC,CAAC;YACvE,CAAC;QACH,CAAC,CAAC,CAAC;QAEH,OAAO;YACL,KAAK,EAAE,MAAM,CAAC,MAAM,KAAK,CAAC;YAC1B,MAAM;YACN,QAAQ;SACT,CAAC;IACJ,CAAC;CACF"}
@@ -1,86 +0,0 @@
1
- /**
2
- * Zustand store for Playground state management
3
- */
4
- import type { PlaygroundComponent, DraggedItem, DropZone, CanvasSnapshot, PlaygroundMode, SidebarTab, ComponentDefinition } from '../types';
5
- export interface PlaygroundState {
6
- components: Map<string, PlaygroundComponent>;
7
- rootId: string;
8
- selectedIds: Set<string>;
9
- hoveredId: string | null;
10
- focusedId: string | null;
11
- draggedItem: DraggedItem | null;
12
- dropZones: Map<string, DropZone>;
13
- dragState: 'idle' | 'dragging' | 'dropping';
14
- mode: PlaygroundMode;
15
- sidebarTab: SidebarTab;
16
- propertiesPanelOpen: boolean;
17
- canvasZoom: number;
18
- canvasOffset: {
19
- x: number;
20
- y: number;
21
- };
22
- showGrid: boolean;
23
- snapToGrid: boolean;
24
- gridSize: number;
25
- history: CanvasSnapshot[];
26
- historyIndex: number;
27
- maxHistorySize: number;
28
- generatedStoryCode: string | null;
29
- isParsingStory: boolean;
30
- parseError: string | null;
31
- availableComponents: ComponentDefinition[];
32
- loadingComponents: Set<string>;
33
- failedComponents: Map<string, Error>;
34
- }
35
- export interface PlaygroundActions {
36
- addComponent: (component: PlaygroundComponent) => void;
37
- updateComponent: (id: string, updates: Partial<PlaygroundComponent>) => void;
38
- deleteComponent: (id: string) => void;
39
- moveComponent: (id: string, newParentId: string, index: number) => void;
40
- duplicateComponent: (id: string) => string;
41
- clearComponents: () => void;
42
- selectComponent: (id: string, multi?: boolean) => void;
43
- deselectComponent: (id: string) => void;
44
- selectAll: () => void;
45
- deselectAll: () => void;
46
- setHoveredComponent: (id: string | null) => void;
47
- startDrag: (item: DraggedItem) => void;
48
- updateDrag: (item: Partial<DraggedItem>) => void;
49
- endDrag: () => void;
50
- registerDropZone: (zone: DropZone) => void;
51
- unregisterDropZone: (id: string) => void;
52
- updateDropZone: (id: string, updates: Partial<DropZone>) => void;
53
- setMode: (mode: PlaygroundMode) => void;
54
- setSidebarTab: (tab: SidebarTab) => void;
55
- togglePropertiesPanel: () => void;
56
- setCanvasZoom: (zoom: number) => void;
57
- panCanvas: (dx: number, dy: number) => void;
58
- resetCanvas: () => void;
59
- toggleGrid: () => void;
60
- toggleSnapToGrid: () => void;
61
- setGridSize: (size: number) => void;
62
- undo: () => void;
63
- redo: () => void;
64
- saveSnapshot: (description?: string) => void;
65
- clearHistory: () => void;
66
- setGeneratedStoryCode: (code: string | null) => void;
67
- setIsParsingStory: (parsing: boolean) => void;
68
- setParseError: (error: string | null) => void;
69
- loadComponentsFromStory: (components: PlaygroundComponent[]) => void;
70
- setAvailableComponents: (components: ComponentDefinition[]) => void;
71
- addLoadingComponent: (name: string) => void;
72
- removeLoadingComponent: (name: string) => void;
73
- setComponentError: (name: string, error: Error) => void;
74
- reset: () => void;
75
- loadFromSnapshot: (snapshot: CanvasSnapshot) => void;
76
- }
77
- export declare const usePlaygroundStore: import("zustand").UseBoundStore<Omit<Omit<import("zustand").StoreApi<PlaygroundState & PlaygroundActions>, "setState"> & {
78
- setState<A extends string | {
79
- type: string;
80
- }>(partial: (PlaygroundState & PlaygroundActions) | Partial<PlaygroundState & PlaygroundActions> | ((state: PlaygroundState & PlaygroundActions) => (PlaygroundState & PlaygroundActions) | Partial<PlaygroundState & PlaygroundActions>), replace?: boolean | undefined, action?: A | undefined): void;
81
- }, "setState"> & {
82
- setState(nextStateOrUpdater: (PlaygroundState & PlaygroundActions) | Partial<PlaygroundState & PlaygroundActions> | ((state: import("immer").WritableDraft<PlaygroundState & PlaygroundActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
83
- type: string;
84
- } | undefined): void;
85
- }>;
86
- //# sourceMappingURL=playgroundStore.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"playgroundStore.d.ts","sourceRoot":"","sources":["../../../playground/store/playgroundStore.ts"],"names":[],"mappings":"AAAA;;GAEG;AASH,OAAO,KAAK,EACV,mBAAmB,EACnB,WAAW,EACX,QAAQ,EACR,cAAc,EACd,cAAc,EACd,UAAU,EACV,mBAAmB,EACpB,MAAM,UAAU,CAAC;AAElB,MAAM,WAAW,eAAe;IAE9B,UAAU,EAAE,GAAG,CAAC,MAAM,EAAE,mBAAmB,CAAC,CAAC;IAC7C,MAAM,EAAE,MAAM,CAAC;IAGf,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IACzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IAGzB,WAAW,EAAE,WA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