@superblocksteam/vite-plugin-file-sync 2.0.114 → 2.0.115-next.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 (355) hide show
  1. package/dist/ai-service/agent/middleware.d.ts.map +1 -1
  2. package/dist/ai-service/agent/middleware.js +19 -0
  3. package/dist/ai-service/agent/middleware.js.map +1 -1
  4. package/dist/ai-service/agent/prompts/api-prompts.d.ts.map +1 -1
  5. package/dist/ai-service/agent/prompts/api-prompts.js +13 -17
  6. package/dist/ai-service/agent/prompts/api-prompts.js.map +1 -1
  7. package/dist/ai-service/agent/prompts/build-base-system-prompt.d.ts.map +1 -1
  8. package/dist/ai-service/agent/prompts/build-base-system-prompt.js +22 -3
  9. package/dist/ai-service/agent/prompts/build-base-system-prompt.js.map +1 -1
  10. package/dist/ai-service/agent/subagents/coding/prompt-builder.d.ts +16 -0
  11. package/dist/ai-service/agent/subagents/coding/prompt-builder.d.ts.map +1 -0
  12. package/dist/ai-service/agent/subagents/coding/prompt-builder.js +30 -0
  13. package/dist/ai-service/agent/subagents/coding/prompt-builder.js.map +1 -0
  14. package/dist/ai-service/agent/subagents/coding/run-coding-subagent.d.ts +29 -0
  15. package/dist/ai-service/agent/subagents/coding/run-coding-subagent.d.ts.map +1 -0
  16. package/dist/ai-service/agent/subagents/coding/run-coding-subagent.js +108 -0
  17. package/dist/ai-service/agent/subagents/coding/run-coding-subagent.js.map +1 -0
  18. package/dist/ai-service/agent/subagents/types.d.ts +9 -1
  19. package/dist/ai-service/agent/subagents/types.d.ts.map +1 -1
  20. package/dist/ai-service/agent/subagents/types.js +8 -0
  21. package/dist/ai-service/agent/subagents/types.js.map +1 -1
  22. package/dist/ai-service/agent/tool-message-utils.d.ts.map +1 -1
  23. package/dist/ai-service/agent/tool-message-utils.js +5 -0
  24. package/dist/ai-service/agent/tool-message-utils.js.map +1 -1
  25. package/dist/ai-service/agent/tools/apis/api-validation-orchestrator.d.ts.map +1 -1
  26. package/dist/ai-service/agent/tools/apis/api-validation-orchestrator.js +2 -1
  27. package/dist/ai-service/agent/tools/apis/api-validation-orchestrator.js.map +1 -1
  28. package/dist/ai-service/agent/tools/apis/get-sdk-api-docs.d.ts +6 -0
  29. package/dist/ai-service/agent/tools/apis/get-sdk-api-docs.d.ts.map +1 -0
  30. package/dist/ai-service/agent/tools/apis/get-sdk-api-docs.js +138 -0
  31. package/dist/ai-service/agent/tools/apis/get-sdk-api-docs.js.map +1 -0
  32. package/dist/ai-service/agent/tools/build-finalize.d.ts.map +1 -1
  33. package/dist/ai-service/agent/tools/build-finalize.js +39 -15
  34. package/dist/ai-service/agent/tools/build-finalize.js.map +1 -1
  35. package/dist/ai-service/agent/tools/build-manage-checklist.d.ts +6 -3
  36. package/dist/ai-service/agent/tools/build-manage-checklist.d.ts.map +1 -1
  37. package/dist/ai-service/agent/tools/build-manage-checklist.js +116 -49
  38. package/dist/ai-service/agent/tools/build-manage-checklist.js.map +1 -1
  39. package/dist/ai-service/agent/tools/index.d.ts +2 -0
  40. package/dist/ai-service/agent/tools/index.d.ts.map +1 -1
  41. package/dist/ai-service/agent/tools/index.js +2 -0
  42. package/dist/ai-service/agent/tools/index.js.map +1 -1
  43. package/dist/ai-service/agent/tools/integrations/execute-request.d.ts +3 -0
  44. package/dist/ai-service/agent/tools/integrations/execute-request.d.ts.map +1 -1
  45. package/dist/ai-service/agent/tools/integrations/execute-request.js +330 -204
  46. package/dist/ai-service/agent/tools/integrations/execute-request.js.map +1 -1
  47. package/dist/ai-service/agent/tools.d.ts.map +1 -1
  48. package/dist/ai-service/agent/tools.js +40 -2
  49. package/dist/ai-service/agent/tools.js.map +1 -1
  50. package/dist/ai-service/agent/tools2/access-control.d.ts +1 -1
  51. package/dist/ai-service/agent/tools2/access-control.d.ts.map +1 -1
  52. package/dist/ai-service/agent/tools2/access-control.js +15 -4
  53. package/dist/ai-service/agent/tools2/access-control.js.map +1 -1
  54. package/dist/ai-service/agent/tools2/registry.d.ts +3 -0
  55. package/dist/ai-service/agent/tools2/registry.d.ts.map +1 -1
  56. package/dist/ai-service/agent/tools2/registry.js +50 -8
  57. package/dist/ai-service/agent/tools2/registry.js.map +1 -1
  58. package/dist/ai-service/agent/tools2/tools/ask-multi-choice.d.ts.map +1 -1
  59. package/dist/ai-service/agent/tools2/tools/ask-multi-choice.js +3 -2
  60. package/dist/ai-service/agent/tools2/tools/ask-multi-choice.js.map +1 -1
  61. package/dist/ai-service/agent/tools2/tools/ask-searchable-dropdown.d.ts.map +1 -1
  62. package/dist/ai-service/agent/tools2/tools/ask-searchable-dropdown.js +2 -1
  63. package/dist/ai-service/agent/tools2/tools/ask-searchable-dropdown.js.map +1 -1
  64. package/dist/ai-service/agent/tools2/tools/deploy-service.d.ts +16 -0
  65. package/dist/ai-service/agent/tools2/tools/deploy-service.d.ts.map +1 -0
  66. package/dist/ai-service/agent/tools2/tools/deploy-service.js +135 -0
  67. package/dist/ai-service/agent/tools2/tools/deploy-service.js.map +1 -0
  68. package/dist/ai-service/agent/tools2/tools/download-attachments.d.ts +33 -0
  69. package/dist/ai-service/agent/tools2/tools/download-attachments.d.ts.map +1 -0
  70. package/dist/ai-service/agent/tools2/tools/download-attachments.js +308 -0
  71. package/dist/ai-service/agent/tools2/tools/download-attachments.js.map +1 -0
  72. package/dist/ai-service/agent/tools2/tools/exit-plan-mode.d.ts.map +1 -1
  73. package/dist/ai-service/agent/tools2/tools/exit-plan-mode.js +8 -4
  74. package/dist/ai-service/agent/tools2/tools/exit-plan-mode.js.map +1 -1
  75. package/dist/ai-service/agent/tools2/tools/git.d.ts +57 -1
  76. package/dist/ai-service/agent/tools2/tools/git.d.ts.map +1 -1
  77. package/dist/ai-service/agent/tools2/tools/git.js +275 -8
  78. package/dist/ai-service/agent/tools2/tools/git.js.map +1 -1
  79. package/dist/ai-service/agent/tools2/tools/index.d.ts +2 -1
  80. package/dist/ai-service/agent/tools2/tools/index.d.ts.map +1 -1
  81. package/dist/ai-service/agent/tools2/tools/index.js +2 -1
  82. package/dist/ai-service/agent/tools2/tools/index.js.map +1 -1
  83. package/dist/ai-service/agent/tools2/tools/list-attachments.d.ts +4 -1
  84. package/dist/ai-service/agent/tools2/tools/list-attachments.d.ts.map +1 -1
  85. package/dist/ai-service/agent/tools2/tools/list-attachments.js +20 -4
  86. package/dist/ai-service/agent/tools2/tools/list-attachments.js.map +1 -1
  87. package/dist/ai-service/agent/tools2/tools/spawn-coding-subagents.d.ts +28 -0
  88. package/dist/ai-service/agent/tools2/tools/spawn-coding-subagents.d.ts.map +1 -0
  89. package/dist/ai-service/agent/tools2/tools/spawn-coding-subagents.js +152 -0
  90. package/dist/ai-service/agent/tools2/tools/spawn-coding-subagents.js.map +1 -0
  91. package/dist/ai-service/agent/tools2/types.d.ts +1 -18
  92. package/dist/ai-service/agent/tools2/types.d.ts.map +1 -1
  93. package/dist/ai-service/agent/tools2/types.js.map +1 -1
  94. package/dist/ai-service/agent/utils.d.ts.map +1 -1
  95. package/dist/ai-service/agent/utils.js +22 -5
  96. package/dist/ai-service/agent/utils.js.map +1 -1
  97. package/dist/ai-service/app-interface/file-system-interface.d.ts +0 -4
  98. package/dist/ai-service/app-interface/file-system-interface.d.ts.map +1 -1
  99. package/dist/ai-service/app-interface/file-system-interface.js +0 -21
  100. package/dist/ai-service/app-interface/file-system-interface.js.map +1 -1
  101. package/dist/ai-service/app-interface/filesystem/virtual-file-system.d.ts +11 -1
  102. package/dist/ai-service/app-interface/filesystem/virtual-file-system.d.ts.map +1 -1
  103. package/dist/ai-service/app-interface/filesystem/virtual-file-system.js +29 -7
  104. package/dist/ai-service/app-interface/filesystem/virtual-file-system.js.map +1 -1
  105. package/dist/ai-service/app-interface/shell.d.ts +6 -0
  106. package/dist/ai-service/app-interface/shell.d.ts.map +1 -1
  107. package/dist/ai-service/app-interface/shell.js +8 -0
  108. package/dist/ai-service/app-interface/shell.js.map +1 -1
  109. package/dist/ai-service/app-skills/helpers.d.ts.map +1 -1
  110. package/dist/ai-service/app-skills/helpers.js +4 -2
  111. package/dist/ai-service/app-skills/helpers.js.map +1 -1
  112. package/dist/ai-service/attachments/store.d.ts +18 -2
  113. package/dist/ai-service/attachments/store.d.ts.map +1 -1
  114. package/dist/ai-service/attachments/store.js +102 -9
  115. package/dist/ai-service/attachments/store.js.map +1 -1
  116. package/dist/ai-service/attachments/uploaded-content-part.d.ts +5 -2
  117. package/dist/ai-service/attachments/uploaded-content-part.d.ts.map +1 -1
  118. package/dist/ai-service/attachments/uploaded-content-part.js +32 -0
  119. package/dist/ai-service/attachments/uploaded-content-part.js.map +1 -1
  120. package/dist/ai-service/chat/chat-session-store.d.ts +2 -2
  121. package/dist/ai-service/chat/chat-session-store.d.ts.map +1 -1
  122. package/dist/ai-service/chat/chat-session-store.js +45 -243
  123. package/dist/ai-service/chat/chat-session-store.js.map +1 -1
  124. package/dist/ai-service/chat/utils.d.ts +6 -0
  125. package/dist/ai-service/chat/utils.d.ts.map +1 -1
  126. package/dist/ai-service/chat/utils.js +47 -0
  127. package/dist/ai-service/chat/utils.js.map +1 -1
  128. package/dist/ai-service/features.d.ts +4 -0
  129. package/dist/ai-service/features.d.ts.map +1 -1
  130. package/dist/ai-service/features.js +4 -0
  131. package/dist/ai-service/features.js.map +1 -1
  132. package/dist/ai-service/index.d.ts +36 -11
  133. package/dist/ai-service/index.d.ts.map +1 -1
  134. package/dist/ai-service/index.js +228 -68
  135. package/dist/ai-service/index.js.map +1 -1
  136. package/dist/ai-service/judge/tools/playwright-action.d.ts +1 -1
  137. package/dist/ai-service/llm/client.d.ts.map +1 -1
  138. package/dist/ai-service/llm/client.js +4 -2
  139. package/dist/ai-service/llm/client.js.map +1 -1
  140. package/dist/ai-service/llm/stream/observers/retry-notification.d.ts.map +1 -1
  141. package/dist/ai-service/llm/stream/observers/retry-notification.js +4 -2
  142. package/dist/ai-service/llm/stream/observers/retry-notification.js.map +1 -1
  143. package/dist/ai-service/prompt-builder-service/classifiers/prompt-interpret-task.d.ts.map +1 -1
  144. package/dist/ai-service/prompt-builder-service/classifiers/prompt-interpret-task.js +1 -16
  145. package/dist/ai-service/prompt-builder-service/classifiers/prompt-interpret-task.js.map +1 -1
  146. package/dist/ai-service/prompt-builder-service/types.d.ts +2 -13
  147. package/dist/ai-service/prompt-builder-service/types.d.ts.map +1 -1
  148. package/dist/ai-service/prompt-builder-service/types.js.map +1 -1
  149. package/dist/ai-service/skills/system/_registry.generated.d.ts.map +1 -1
  150. package/dist/ai-service/skills/system/_registry.generated.js +6 -0
  151. package/dist/ai-service/skills/system/_registry.generated.js.map +1 -1
  152. package/dist/ai-service/skills/system/superblocks-migration/references/focused-debug.generated.d.ts +2 -0
  153. package/dist/ai-service/skills/system/superblocks-migration/references/focused-debug.generated.d.ts.map +1 -0
  154. package/dist/ai-service/skills/system/superblocks-migration/references/focused-debug.generated.js +58 -0
  155. package/dist/ai-service/skills/system/superblocks-migration/references/focused-debug.generated.js.map +1 -0
  156. package/dist/ai-service/skills/system/superblocks-migration/references/yaml-block-mapping.generated.d.ts +2 -0
  157. package/dist/ai-service/skills/system/superblocks-migration/references/yaml-block-mapping.generated.d.ts.map +1 -0
  158. package/dist/ai-service/skills/system/superblocks-migration/references/yaml-block-mapping.generated.js +107 -0
  159. package/dist/ai-service/skills/system/superblocks-migration/references/yaml-block-mapping.generated.js.map +1 -0
  160. package/dist/ai-service/skills/system/superblocks-migration/skill.generated.d.ts +2 -0
  161. package/dist/ai-service/skills/system/superblocks-migration/skill.generated.d.ts.map +1 -0
  162. package/dist/ai-service/skills/system/superblocks-migration/skill.generated.js +137 -0
  163. package/dist/ai-service/skills/system/superblocks-migration/skill.generated.js.map +1 -0
  164. package/dist/ai-service/state-machine/clark-fsm.d.ts +26 -13
  165. package/dist/ai-service/state-machine/clark-fsm.d.ts.map +1 -1
  166. package/dist/ai-service/state-machine/clark-fsm.js +12 -7
  167. package/dist/ai-service/state-machine/clark-fsm.js.map +1 -1
  168. package/dist/ai-service/state-machine/handlers/agent-planning.d.ts.map +1 -1
  169. package/dist/ai-service/state-machine/handlers/agent-planning.js +51 -27
  170. package/dist/ai-service/state-machine/handlers/agent-planning.js.map +1 -1
  171. package/dist/ai-service/state-machine/handlers/awaiting-user.d.ts.map +1 -1
  172. package/dist/ai-service/state-machine/handlers/awaiting-user.js +15 -6
  173. package/dist/ai-service/state-machine/handlers/awaiting-user.js.map +1 -1
  174. package/dist/ai-service/state-machine/handlers/idle.d.ts.map +1 -1
  175. package/dist/ai-service/state-machine/handlers/idle.js +4 -2
  176. package/dist/ai-service/state-machine/handlers/idle.js.map +1 -1
  177. package/dist/ai-service/state-machine/handlers/llm-generating.d.ts.map +1 -1
  178. package/dist/ai-service/state-machine/handlers/llm-generating.js +48 -15
  179. package/dist/ai-service/state-machine/handlers/llm-generating.js.map +1 -1
  180. package/dist/ai-service/state-machine/handlers/post-processing.d.ts +1 -1
  181. package/dist/ai-service/state-machine/handlers/post-processing.d.ts.map +1 -1
  182. package/dist/ai-service/state-machine/handlers/post-processing.js +23 -151
  183. package/dist/ai-service/state-machine/handlers/post-processing.js.map +1 -1
  184. package/dist/ai-service/state-machine/handlers/runtime-reviewing.d.ts.map +1 -1
  185. package/dist/ai-service/state-machine/handlers/runtime-reviewing.js +16 -8
  186. package/dist/ai-service/state-machine/handlers/runtime-reviewing.js.map +1 -1
  187. package/dist/ai-service/state-machine/helpers/change-info.d.ts.map +1 -1
  188. package/dist/ai-service/state-machine/helpers/change-info.js +2 -15
  189. package/dist/ai-service/state-machine/helpers/change-info.js.map +1 -1
  190. package/dist/ai-service/state-machine/helpers/peer.d.ts +3 -3
  191. package/dist/ai-service/state-machine/helpers/peer.d.ts.map +1 -1
  192. package/dist/ai-service/state-machine/helpers/peer.js +9 -23
  193. package/dist/ai-service/state-machine/helpers/peer.js.map +1 -1
  194. package/dist/ai-service/state-machine/helpers/stable-peer.d.ts +52 -0
  195. package/dist/ai-service/state-machine/helpers/stable-peer.d.ts.map +1 -0
  196. package/dist/ai-service/state-machine/helpers/stable-peer.js +141 -0
  197. package/dist/ai-service/state-machine/helpers/stable-peer.js.map +1 -0
  198. package/dist/ai-service/state-machine/mocks.d.ts.map +1 -1
  199. package/dist/ai-service/state-machine/mocks.js +0 -17
  200. package/dist/ai-service/state-machine/mocks.js.map +1 -1
  201. package/dist/ai-service/types.d.ts +2 -21
  202. package/dist/ai-service/types.d.ts.map +1 -1
  203. package/dist/ai-service/types.js.map +1 -1
  204. package/dist/ai-service/util/archive-extractors.d.ts +52 -0
  205. package/dist/ai-service/util/archive-extractors.d.ts.map +1 -0
  206. package/dist/ai-service/util/archive-extractors.js +278 -0
  207. package/dist/ai-service/util/archive-extractors.js.map +1 -0
  208. package/dist/codegen.d.ts +1 -22
  209. package/dist/codegen.d.ts.map +1 -1
  210. package/dist/codegen.js +1 -117
  211. package/dist/codegen.js.map +1 -1
  212. package/dist/components-manager.d.ts +0 -6
  213. package/dist/components-manager.d.ts.map +1 -1
  214. package/dist/components-manager.js +0 -27
  215. package/dist/components-manager.js.map +1 -1
  216. package/dist/file-sync-vite-plugin.d.ts.map +1 -1
  217. package/dist/file-sync-vite-plugin.js +47 -94
  218. package/dist/file-sync-vite-plugin.js.map +1 -1
  219. package/dist/file-system-manager.d.ts +2 -15
  220. package/dist/file-system-manager.d.ts.map +1 -1
  221. package/dist/file-system-manager.js +16 -128
  222. package/dist/file-system-manager.js.map +1 -1
  223. package/dist/git-service/live-branch.d.ts.map +1 -1
  224. package/dist/git-service/live-branch.js +15 -1
  225. package/dist/git-service/live-branch.js.map +1 -1
  226. package/dist/lock-service/index.d.ts.map +1 -1
  227. package/dist/lock-service/index.js +8 -5
  228. package/dist/lock-service/index.js.map +1 -1
  229. package/dist/migration/get-fullstack-template-dir.d.ts +37 -0
  230. package/dist/migration/get-fullstack-template-dir.d.ts.map +1 -0
  231. package/dist/migration/get-fullstack-template-dir.js +99 -0
  232. package/dist/migration/get-fullstack-template-dir.js.map +1 -0
  233. package/dist/migration/migration-checklist.d.ts +60 -0
  234. package/dist/migration/migration-checklist.d.ts.map +1 -0
  235. package/dist/migration/migration-checklist.js +230 -0
  236. package/dist/migration/migration-checklist.js.map +1 -0
  237. package/dist/migration/migration-routes.d.ts +23 -0
  238. package/dist/migration/migration-routes.d.ts.map +1 -0
  239. package/dist/migration/migration-routes.js +533 -0
  240. package/dist/migration/migration-routes.js.map +1 -0
  241. package/dist/migration/restructure.d.ts +76 -0
  242. package/dist/migration/restructure.d.ts.map +1 -0
  243. package/dist/migration/restructure.js +446 -0
  244. package/dist/migration/restructure.js.map +1 -0
  245. package/dist/migration/translation-prompt.d.ts +22 -0
  246. package/dist/migration/translation-prompt.d.ts.map +1 -0
  247. package/dist/migration/translation-prompt.js +27 -0
  248. package/dist/migration/translation-prompt.js.map +1 -0
  249. package/dist/migration-templates/app-fullstack/client/App.tsx +17 -0
  250. package/dist/migration-templates/app-fullstack/client/components/common/sonner.tsx +20 -0
  251. package/dist/migration-templates/app-fullstack/client/components/hooks/use-active-page.ts +73 -0
  252. package/dist/migration-templates/app-fullstack/client/components/hooks/use-mobile.ts +21 -0
  253. package/dist/migration-templates/app-fullstack/client/components/ui/accordion.tsx +197 -0
  254. package/dist/migration-templates/app-fullstack/client/components/ui/area-chart.tsx +432 -0
  255. package/dist/migration-templates/app-fullstack/client/components/ui/aspect-ratio.tsx +45 -0
  256. package/dist/migration-templates/app-fullstack/client/components/ui/avatar.tsx +117 -0
  257. package/dist/migration-templates/app-fullstack/client/components/ui/badge.tsx +143 -0
  258. package/dist/migration-templates/app-fullstack/client/components/ui/bar-chart.tsx +390 -0
  259. package/dist/migration-templates/app-fullstack/client/components/ui/breadcrumb.tsx +259 -0
  260. package/dist/migration-templates/app-fullstack/client/components/ui/button.tsx +182 -0
  261. package/dist/migration-templates/app-fullstack/client/components/ui/calendar.tsx +300 -0
  262. package/dist/migration-templates/app-fullstack/client/components/ui/card.tsx +129 -0
  263. package/dist/migration-templates/app-fullstack/client/components/ui/chart.tsx +403 -0
  264. package/dist/migration-templates/app-fullstack/client/components/ui/chat.tsx +2303 -0
  265. package/dist/migration-templates/app-fullstack/client/components/ui/checkbox.tsx +97 -0
  266. package/dist/migration-templates/app-fullstack/client/components/ui/code-block-content.tsx +66 -0
  267. package/dist/migration-templates/app-fullstack/client/components/ui/date-range-picker.tsx +396 -0
  268. package/dist/migration-templates/app-fullstack/client/components/ui/dialog.tsx +223 -0
  269. package/dist/migration-templates/app-fullstack/client/components/ui/dropdown-menu.tsx +284 -0
  270. package/dist/migration-templates/app-fullstack/client/components/ui/file-dropzone.tsx +395 -0
  271. package/dist/migration-templates/app-fullstack/client/components/ui/file-input.tsx +166 -0
  272. package/dist/migration-templates/app-fullstack/client/components/ui/hover-card.tsx +162 -0
  273. package/dist/migration-templates/app-fullstack/client/components/ui/icon.tsx +133 -0
  274. package/dist/migration-templates/app-fullstack/client/components/ui/image.tsx +68 -0
  275. package/dist/migration-templates/app-fullstack/client/components/ui/input.tsx +219 -0
  276. package/dist/migration-templates/app-fullstack/client/components/ui/label.tsx +55 -0
  277. package/dist/migration-templates/app-fullstack/client/components/ui/line-chart.tsx +380 -0
  278. package/dist/migration-templates/app-fullstack/client/components/ui/link.tsx +139 -0
  279. package/dist/migration-templates/app-fullstack/client/components/ui/navigation-menu.tsx +345 -0
  280. package/dist/migration-templates/app-fullstack/client/components/ui/pagination.tsx +192 -0
  281. package/dist/migration-templates/app-fullstack/client/components/ui/pie-chart.tsx +295 -0
  282. package/dist/migration-templates/app-fullstack/client/components/ui/popover.tsx +162 -0
  283. package/dist/migration-templates/app-fullstack/client/components/ui/progress.tsx +69 -0
  284. package/dist/migration-templates/app-fullstack/client/components/ui/radar-chart.tsx +386 -0
  285. package/dist/migration-templates/app-fullstack/client/components/ui/radial-chart.tsx +402 -0
  286. package/dist/migration-templates/app-fullstack/client/components/ui/scroll-area.tsx +86 -0
  287. package/dist/migration-templates/app-fullstack/client/components/ui/select.tsx +229 -0
  288. package/dist/migration-templates/app-fullstack/client/components/ui/separator.tsx +62 -0
  289. package/dist/migration-templates/app-fullstack/client/components/ui/sheet.tsx +234 -0
  290. package/dist/migration-templates/app-fullstack/client/components/ui/sidebar.tsx +974 -0
  291. package/dist/migration-templates/app-fullstack/client/components/ui/skeleton.tsx +13 -0
  292. package/dist/migration-templates/app-fullstack/client/components/ui/slider.tsx +198 -0
  293. package/dist/migration-templates/app-fullstack/client/components/ui/switch.tsx +95 -0
  294. package/dist/migration-templates/app-fullstack/client/components/ui/table.tsx +145 -0
  295. package/dist/migration-templates/app-fullstack/client/components/ui/tabs.tsx +87 -0
  296. package/dist/migration-templates/app-fullstack/client/components/ui/textarea.tsx +148 -0
  297. package/dist/migration-templates/app-fullstack/client/components/ui/toggle-group.tsx +225 -0
  298. package/dist/migration-templates/app-fullstack/client/components/ui/toggle.tsx +150 -0
  299. package/dist/migration-templates/app-fullstack/client/components/ui/tooltip.tsx +175 -0
  300. package/dist/migration-templates/app-fullstack/client/hooks/useApi.ts +25 -0
  301. package/dist/migration-templates/app-fullstack/client/hooks/useApiData.ts +10 -0
  302. package/dist/migration-templates/app-fullstack/client/index.css +131 -0
  303. package/dist/migration-templates/app-fullstack/client/lib/executeApi.ts +9 -0
  304. package/dist/migration-templates/app-fullstack/client/lib/utils.ts +6 -0
  305. package/dist/migration-templates/app-fullstack/client/pages/Page1/index.tsx +3 -0
  306. package/dist/migration-templates/app-fullstack/client/root.tsx +17 -0
  307. package/dist/migration-templates/app-fullstack/client/router.tsx +48 -0
  308. package/dist/migration-templates/app-fullstack/client/types/node.d.ts +9 -0
  309. package/dist/migration-templates/app-fullstack/components.json +21 -0
  310. package/dist/migration-templates/app-fullstack/eslint.config.js +108 -0
  311. package/dist/migration-templates/app-fullstack/package.json +89 -0
  312. package/dist/migration-templates/app-fullstack/server/.gitkeep +0 -0
  313. package/dist/migration-templates/app-fullstack/server/apis/index.ts +22 -0
  314. package/dist/migration-templates/app-fullstack/server/index.ts +2 -0
  315. package/dist/migration-templates/app-fullstack/tsconfig.client.json +27 -0
  316. package/dist/migration-templates/app-fullstack/tsconfig.eslint.json +8 -0
  317. package/dist/migration-templates/app-fullstack/tsconfig.json +25 -0
  318. package/dist/migration-templates/app-fullstack/tsconfig.server.json +13 -0
  319. package/dist/migration-templates/app-fullstack/vite.config.ts +17 -0
  320. package/dist/parsing/imports.d.ts +0 -16
  321. package/dist/parsing/imports.d.ts.map +1 -1
  322. package/dist/parsing/imports.js +0 -68
  323. package/dist/parsing/imports.js.map +1 -1
  324. package/dist/parsing/jsx.d.ts +0 -2
  325. package/dist/parsing/jsx.d.ts.map +1 -1
  326. package/dist/parsing/jsx.js +0 -62
  327. package/dist/parsing/jsx.js.map +1 -1
  328. package/dist/socket-manager.d.ts.map +1 -1
  329. package/dist/socket-manager.js +109 -32
  330. package/dist/socket-manager.js.map +1 -1
  331. package/dist/source-tracker.d.ts +7 -85
  332. package/dist/source-tracker.d.ts.map +1 -1
  333. package/dist/source-tracker.js +19 -695
  334. package/dist/source-tracker.js.map +1 -1
  335. package/dist/sync-service/index.d.ts +79 -2
  336. package/dist/sync-service/index.d.ts.map +1 -1
  337. package/dist/sync-service/index.js +139 -10
  338. package/dist/sync-service/index.js.map +1 -1
  339. package/package.json +11 -9
  340. package/dist/ai-service/artifacts/bolt.d.ts +0 -8
  341. package/dist/ai-service/artifacts/bolt.d.ts.map +0 -1
  342. package/dist/ai-service/artifacts/bolt.js +0 -92
  343. package/dist/ai-service/artifacts/bolt.js.map +0 -1
  344. package/dist/ai-service/result-buffer/bolt.d.ts +0 -18
  345. package/dist/ai-service/result-buffer/bolt.d.ts.map +0 -1
  346. package/dist/ai-service/result-buffer/bolt.js +0 -100
  347. package/dist/ai-service/result-buffer/bolt.js.map +0 -1
  348. package/dist/ai-service/result-buffer/shared.d.ts +0 -17
  349. package/dist/ai-service/result-buffer/shared.d.ts.map +0 -1
  350. package/dist/ai-service/result-buffer/shared.js +0 -7
  351. package/dist/ai-service/result-buffer/shared.js.map +0 -1
  352. package/dist/inject-no-select.d.ts +0 -15
  353. package/dist/inject-no-select.d.ts.map +0 -1
  354. package/dist/inject-no-select.js +0 -175
  355. package/dist/inject-no-select.js.map +0 -1
@@ -0,0 +1,13 @@
1
+ import { cn } from "@/lib/utils";
2
+
3
+ function Skeleton({ className, ...props }: React.ComponentProps<"div">) {
4
+ return (
5
+ <div
6
+ data-slot="skeleton"
7
+ className={cn("bg-accent animate-pulse rounded-md", className)}
8
+ {...props}
9
+ />
10
+ );
11
+ }
12
+
13
+ export { Skeleton };
@@ -0,0 +1,198 @@
1
+ import * as SliderPrimitive from "@radix-ui/react-slider";
2
+ import * as React from "react";
3
+
4
+ import { registerComponent } from "@superblocksteam/library";
5
+ import {
6
+ Prop,
7
+ Section,
8
+ PropsCategory,
9
+ type PropertiesPanelDefinition,
10
+ type EditorConfig,
11
+ } from "@superblocksteam/library";
12
+
13
+ import { cn } from "@/lib/utils";
14
+
15
+ // Main Component
16
+ function Slider({
17
+ className,
18
+ defaultValue,
19
+ value,
20
+ min = 0,
21
+ max = 100,
22
+ ...props
23
+ }: React.ComponentProps<typeof SliderPrimitive.Root>) {
24
+ const _values = React.useMemo(
25
+ () =>
26
+ Array.isArray(value)
27
+ ? value
28
+ : Array.isArray(defaultValue)
29
+ ? defaultValue
30
+ : [min, max],
31
+ [value, defaultValue, min, max],
32
+ );
33
+ return (
34
+ <SliderPrimitive.Root
35
+ data-slot="slider"
36
+ defaultValue={defaultValue}
37
+ value={value}
38
+ min={min}
39
+ max={max}
40
+ className={cn(
41
+ "relative flex w-full touch-none items-center select-none data-[disabled]:opacity-50 data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-44 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col",
42
+ className,
43
+ )}
44
+ {...props}
45
+ >
46
+ <SliderPrimitive.Track
47
+ data-slot="slider-track"
48
+ className={cn(
49
+ "bg-muted relative grow overflow-hidden rounded-full data-[orientation=horizontal]:h-1.5 data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-1.5",
50
+ )}
51
+ >
52
+ <SliderPrimitive.Range
53
+ data-slot="slider-range"
54
+ className={cn(
55
+ "bg-primary absolute data-[orientation=horizontal]:h-full data-[orientation=vertical]:w-full",
56
+ )}
57
+ />
58
+ </SliderPrimitive.Track>
59
+ {Array.from(
60
+ {
61
+ length: _values.length,
62
+ },
63
+ (_, index) => (
64
+ <SliderPrimitive.Thumb
65
+ data-slot="slider-thumb"
66
+ data-ignore-dnd="true"
67
+ onClick={(e) => {
68
+ e.stopPropagation();
69
+ }}
70
+ key={index}
71
+ className="border-primary bg-background ring-ring/50 block size-4 shrink-0 rounded-full border shadow-sm transition-[color,box-shadow] hover:ring-4 focus-visible:ring-4 focus-visible:outline-hidden disabled:pointer-events-none disabled:opacity-50"
72
+ />
73
+ ),
74
+ )}
75
+ </SliderPrimitive.Root>
76
+ );
77
+ }
78
+
79
+ // Types
80
+ // Properties Definition
81
+ const propertiesDefinition: PropertiesPanelDefinition<
82
+ React.ComponentProps<typeof SliderPrimitive.Root>
83
+ > = {
84
+ general: Section.category(PropsCategory.Content).children({
85
+ value: Prop.array<number>().propertiesPanel({
86
+ label: "Value",
87
+ controlType: "INPUT_TEXT",
88
+ description: "The controlled value of the slider",
89
+ isRemovable: true,
90
+ visibility: "SHOW_NAME",
91
+ }),
92
+ defaultValue: Prop.array<number>().propertiesPanel({
93
+ label: "Default value",
94
+ description:
95
+ "The default selected option value. Changes to the default selection update the component state",
96
+ placeholder: "Enter default option value",
97
+ }),
98
+ min: Prop.number().propertiesPanel({
99
+ label: "Min value",
100
+ description: "The minimum value of the slider",
101
+ placeholder: "Enter min value",
102
+ defaultOnAdd: 0,
103
+ visibility: "SHOW_NAME",
104
+ isRemovable: true,
105
+ }),
106
+ max: Prop.number().propertiesPanel({
107
+ label: "Max value",
108
+ description: "The maximum value of the slider",
109
+ placeholder: "Enter max value",
110
+ defaultOnAdd: 100,
111
+ visibility: "SHOW_NAME",
112
+ isRemovable: true,
113
+ }),
114
+ step: Prop.number().propertiesPanel({
115
+ label: "Step value",
116
+ description: "The step value of the slider",
117
+ placeholder: "Enter step value",
118
+ defaultOnAdd: 1,
119
+ visibility: "SHOW_NAME",
120
+ isRemovable: true,
121
+ }),
122
+ minStepsBetweenThumbs: Prop.number().propertiesPanel({
123
+ label: "Min steps between thumbs",
124
+ description: "The minimum number of steps between multiple thumbs",
125
+ placeholder: "Enter minimum steps",
126
+ defaultOnAdd: 0,
127
+ visibility: "SHOW_NAME",
128
+ isRemovable: true,
129
+ }),
130
+ }),
131
+ appearance: Section.category(PropsCategory.Appearance).children({
132
+ orientation: Prop.string<"horizontal" | "vertical">()
133
+
134
+ .propertiesPanel({
135
+ label: "Orientation",
136
+ description: "The orientation of the slider",
137
+ controlType: "RADIO_BUTTON_GROUP",
138
+ options: [
139
+ { value: "horizontal", label: "Horizontal" },
140
+ { value: "vertical", label: "Vertical" },
141
+ ],
142
+ visibility: "SHOW_NAME",
143
+ isRemovable: true,
144
+ defaultOnAdd: "horizontal",
145
+ }),
146
+ inverted: Prop.boolean().propertiesPanel({
147
+ label: "Inverted",
148
+ description: "Whether the slider is inverted (reverse direction)",
149
+ controlType: "SWITCH",
150
+ visibility: "SHOW_NAME",
151
+ isRemovable: true,
152
+ defaultOnAdd: false,
153
+ }),
154
+ }),
155
+ interaction: Section.category(PropsCategory.Interaction).children({
156
+ disabled: Prop.boolean().propertiesPanel({
157
+ label: "Disabled",
158
+ description: "Disables user interaction with this component",
159
+ controlType: "SWITCH",
160
+ }),
161
+ }),
162
+ events: Section.category(PropsCategory.EventHandlers).children({
163
+ onValueChange: Prop.eventHandler().propertiesPanel({
164
+ label: "onValueChange",
165
+ description: "Event handler called when the value changes",
166
+ computedArgs: [
167
+ {
168
+ name: "value",
169
+ type: "array",
170
+ description: "The new value",
171
+ },
172
+ ],
173
+ }),
174
+ onValueCommit: Prop.eventHandler().propertiesPanel({
175
+ label: "onValueCommit",
176
+ description:
177
+ "Event handler called when the value changes at the end of an interaction. Useful when you only need to capture a final value e.g. to update a backend service",
178
+ computedArgs: [
179
+ {
180
+ name: "value",
181
+ type: "array",
182
+ description: "The new value",
183
+ },
184
+ ],
185
+ }),
186
+ }),
187
+ };
188
+
189
+ // Editor Configuration
190
+ const editorConfig: EditorConfig = {
191
+ icon: "custom",
192
+ hasExtendedClickArea: true,
193
+ };
194
+
195
+ // Registration
196
+ registerComponent(Slider, propertiesDefinition).editorConfig(editorConfig);
197
+
198
+ export { Slider };
@@ -0,0 +1,95 @@
1
+ import * as SwitchPrimitives from "@radix-ui/react-switch";
2
+ import * as React from "react";
3
+
4
+ import { registerComponent } from "@superblocksteam/library";
5
+ import {
6
+ Prop,
7
+ Section,
8
+ PropsCategory,
9
+ type PropertiesPanelDefinition,
10
+ type EditorConfig,
11
+ } from "@superblocksteam/library";
12
+
13
+ import { cn } from "@/lib/utils";
14
+
15
+ // Main Component
16
+ const Switch = React.forwardRef<
17
+ React.ElementRef<typeof SwitchPrimitives.Root>,
18
+ React.ComponentPropsWithoutRef<typeof SwitchPrimitives.Root>
19
+ >(({ className, ...props }, ref) => (
20
+ <SwitchPrimitives.Root
21
+ className={cn(
22
+ "peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",
23
+ className,
24
+ )}
25
+ {...props}
26
+ ref={ref}
27
+ >
28
+ <SwitchPrimitives.Thumb
29
+ className={cn(
30
+ "pointer-events-none block h-4 w-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0",
31
+ )}
32
+ />
33
+ </SwitchPrimitives.Root>
34
+ ));
35
+ Switch.displayName = SwitchPrimitives.Root.displayName;
36
+
37
+ // Types
38
+ // Properties Definition
39
+ const propertiesDefinition: PropertiesPanelDefinition<
40
+ React.ComponentProps<typeof SwitchPrimitives.Root>
41
+ > = {
42
+ general: Section.category(PropsCategory.Content).children({
43
+ checked: Prop.boolean().propertiesPanel({
44
+ label: "Checked",
45
+ controlType: "SWITCH",
46
+ description:
47
+ "The controlled state of the switch. Must be used in conjunction with `onCheckedChange`",
48
+ isRemovable: true,
49
+ visibility: "SHOW_NAME",
50
+ }),
51
+ defaultChecked: Prop.boolean()
52
+ .propertiesPanel({
53
+ label: "Default checked",
54
+ controlType: "SWITCH",
55
+ description: "Whether the switch is checked by default",
56
+ })
57
+ .docs({
58
+ description: "Use when you do not need to control its pressed state",
59
+ }),
60
+ }),
61
+
62
+ interaction: Section.category(PropsCategory.Interaction).children({
63
+ disabled: Prop.boolean().propertiesPanel({
64
+ label: "Disabled",
65
+ controlType: "SWITCH",
66
+ description: "Whether the switch is disabled",
67
+ }),
68
+ }),
69
+
70
+ events: Section.category(PropsCategory.EventHandlers).children({
71
+ onCheckedChange: Prop.eventHandler().propertiesPanel({
72
+ label: "onChange",
73
+ description: "Triggered when the switch checked state changes",
74
+ computedArgs: [
75
+ {
76
+ name: "checked",
77
+ type: "boolean",
78
+ description: "Whether the switch is checked",
79
+ },
80
+ ],
81
+ }),
82
+ }),
83
+ };
84
+
85
+ // Editor Configuration
86
+ const editorConfig: EditorConfig = {
87
+ icon: "switch",
88
+ description:
89
+ "A control that allows the user to toggle between checked and not checked",
90
+ };
91
+
92
+ // Registration
93
+ registerComponent(Switch, propertiesDefinition).editorConfig(editorConfig);
94
+
95
+ export { Switch };
@@ -0,0 +1,145 @@
1
+ import * as React from "react";
2
+
3
+ import { registerComponent } from "@superblocksteam/library";
4
+ import {
5
+ type PropertiesPanelDefinition,
6
+ type EditorConfig,
7
+ } from "@superblocksteam/library";
8
+
9
+ import { cn } from "@/lib/utils";
10
+
11
+ // Table Component
12
+ function Table({
13
+ className,
14
+ rootStyle,
15
+ ...props
16
+ }: React.ComponentProps<"table"> & {
17
+ rootStyle?: React.CSSProperties;
18
+ }) {
19
+ return (
20
+ <div
21
+ data-slot="table-container"
22
+ className="relative w-full h-full overflow-x-auto"
23
+ style={rootStyle}
24
+ >
25
+ <table
26
+ data-slot="table"
27
+ className={cn("w-full caption-bottom text-sm", className)}
28
+ {...props}
29
+ />
30
+ </div>
31
+ );
32
+ }
33
+ function TableHeader({ className, ...props }: React.ComponentProps<"thead">) {
34
+ return (
35
+ <thead
36
+ data-slot="table-header"
37
+ className={cn("[&_tr]:border-b", className)}
38
+ {...props}
39
+ />
40
+ );
41
+ }
42
+ function TableBody({ className, ...props }: React.ComponentProps<"tbody">) {
43
+ return (
44
+ <tbody
45
+ data-slot="table-body"
46
+ className={cn("[&_tr:last-child]:border-0", className)}
47
+ {...props}
48
+ />
49
+ );
50
+ }
51
+ function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">) {
52
+ return (
53
+ <tfoot
54
+ data-slot="table-footer"
55
+ className={cn(
56
+ "bg-muted/50 border-t font-medium [&>tr]:last:border-b-0",
57
+ className,
58
+ )}
59
+ {...props}
60
+ />
61
+ );
62
+ }
63
+ function TableRow({ className, ...props }: React.ComponentProps<"tr">) {
64
+ return (
65
+ <tr
66
+ data-slot="table-row"
67
+ className={cn(
68
+ "hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",
69
+ className,
70
+ )}
71
+ {...props}
72
+ />
73
+ );
74
+ }
75
+ function TableHead({ className, ...props }: React.ComponentProps<"th">) {
76
+ return (
77
+ <th
78
+ data-slot="table-head"
79
+ className={cn(
80
+ "text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
81
+ className,
82
+ )}
83
+ {...props}
84
+ />
85
+ );
86
+ }
87
+ function TableCell({ className, ...props }: React.ComponentProps<"td">) {
88
+ return (
89
+ <td
90
+ data-slot="table-cell"
91
+ className={cn(
92
+ "p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
93
+ className,
94
+ )}
95
+ {...props}
96
+ />
97
+ );
98
+ }
99
+ function TableCaption({
100
+ className,
101
+ ...props
102
+ }: React.ComponentProps<"caption">) {
103
+ return (
104
+ <caption
105
+ data-slot="table-caption"
106
+ className={cn("text-muted-foreground mt-4 text-sm", className)}
107
+ {...props}
108
+ />
109
+ );
110
+ }
111
+
112
+ type TableProps = React.ComponentProps<typeof Table>;
113
+
114
+ // Properties Definition
115
+ const propertiesDefinition: PropertiesPanelDefinition<TableProps> = {};
116
+
117
+ // Editor Configuration
118
+ const editorConfig: EditorConfig = {
119
+ icon: "table",
120
+ description: "A table component for displaying data",
121
+ };
122
+ const tableElementConfig: EditorConfig = {
123
+ icon: "container",
124
+ description: "A table element component for displaying data",
125
+ };
126
+
127
+ // Registration
128
+ registerComponent(Table, propertiesDefinition).editorConfig(editorConfig);
129
+ registerComponent(TableHeader).editorConfig(tableElementConfig);
130
+ registerComponent(TableBody).editorConfig(tableElementConfig);
131
+ registerComponent(TableFooter).editorConfig(tableElementConfig);
132
+ registerComponent(TableHead).editorConfig(tableElementConfig);
133
+ registerComponent(TableRow).editorConfig(tableElementConfig);
134
+ registerComponent(TableCell).editorConfig(tableElementConfig);
135
+ registerComponent(TableCaption).editorConfig(tableElementConfig);
136
+ export {
137
+ Table,
138
+ TableHeader,
139
+ TableBody,
140
+ TableFooter,
141
+ TableHead,
142
+ TableRow,
143
+ TableCell,
144
+ TableCaption,
145
+ };
@@ -0,0 +1,87 @@
1
+ import * as TabsPrimitive from "@radix-ui/react-tabs";
2
+ import * as React from "react";
3
+
4
+ import { registerComponent } from "@superblocksteam/library";
5
+ import {
6
+ type PropertiesPanelDefinition,
7
+ type EditorConfig,
8
+ } from "@superblocksteam/library";
9
+
10
+ import { cn } from "@/lib/utils";
11
+
12
+ function Tabs({
13
+ className,
14
+ ...props
15
+ }: React.ComponentProps<typeof TabsPrimitive.Root>) {
16
+ return (
17
+ <TabsPrimitive.Root
18
+ data-slot="tabs"
19
+ className={cn("flex flex-col gap-2", className)}
20
+ {...props}
21
+ />
22
+ );
23
+ }
24
+
25
+ function TabsList({
26
+ className,
27
+ ...props
28
+ }: React.ComponentProps<typeof TabsPrimitive.List>) {
29
+ return (
30
+ <TabsPrimitive.List
31
+ data-slot="tabs-list"
32
+ className={cn(
33
+ "bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",
34
+ className,
35
+ )}
36
+ {...props}
37
+ />
38
+ );
39
+ }
40
+
41
+ function TabsTrigger({
42
+ className,
43
+ ...props
44
+ }: React.ComponentProps<typeof TabsPrimitive.Trigger>) {
45
+ return (
46
+ <TabsPrimitive.Trigger
47
+ data-slot="tabs-trigger"
48
+ className={cn(
49
+ "data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
50
+ className,
51
+ )}
52
+ {...props}
53
+ />
54
+ );
55
+ }
56
+
57
+ function TabsContent({
58
+ className,
59
+ ...props
60
+ }: React.ComponentProps<typeof TabsPrimitive.Content>) {
61
+ return (
62
+ <TabsPrimitive.Content
63
+ data-slot="tabs-content"
64
+ className={cn("flex-1 outline-none", className)}
65
+ {...props}
66
+ />
67
+ );
68
+ }
69
+
70
+ type TabsProps = React.ComponentProps<typeof Tabs>;
71
+
72
+ // Properties Definition
73
+ const propertiesDefinition: PropertiesPanelDefinition<TabsProps> = {};
74
+
75
+ // Editor Configuration
76
+ const editorConfig: EditorConfig = {
77
+ icon: "tabs",
78
+ description: "A tabs component for displaying content in a tabbed interface",
79
+ };
80
+
81
+ // Registration
82
+ registerComponent(Tabs, propertiesDefinition).editorConfig(editorConfig);
83
+ registerComponent(TabsList);
84
+ registerComponent(TabsTrigger);
85
+ registerComponent(TabsContent);
86
+
87
+ export { Tabs, TabsList, TabsTrigger, TabsContent };
@@ -0,0 +1,148 @@
1
+ import type * as React from "react";
2
+
3
+ import { registerComponent } from "@superblocksteam/library";
4
+ import {
5
+ Prop,
6
+ Section,
7
+ PropsCategory,
8
+ tailwindStylesCategory,
9
+ type PropertiesPanelDefinition,
10
+ } from "@superblocksteam/library";
11
+ import { type EditorConfig } from "@superblocksteam/library";
12
+
13
+ import { cn } from "@/lib/utils";
14
+
15
+ // Main Component
16
+ function Textarea({
17
+ className,
18
+ style,
19
+ ...props
20
+ }: React.ComponentProps<"textarea">) {
21
+ return (
22
+ <textarea
23
+ {...props}
24
+ data-slot="textarea"
25
+ style={style}
26
+ className={cn(
27
+ "border-input placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 flex field-sizing-content min-h-16 w-full rounded-md border bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
28
+ className,
29
+ )}
30
+ />
31
+ );
32
+ }
33
+
34
+ // Types
35
+ type TextareaProps = React.ComponentProps<"textarea">;
36
+
37
+ // Properties Definition
38
+ const propertiesDefinition: PropertiesPanelDefinition<TextareaProps> = {
39
+ general: Section.category(PropsCategory.Content).children({
40
+ value: Prop.string().propertiesPanel({
41
+ label: "Value",
42
+ controlType: "INPUT_TEXT",
43
+ description: "The controlled value of the textarea",
44
+ isRemovable: true,
45
+ visibility: "SHOW_NAME",
46
+ }),
47
+ defaultValue: Prop.string().propertiesPanel({
48
+ label: "Default value",
49
+ controlType: "INPUT_TEXT",
50
+ description: "The current value of the textarea",
51
+ }),
52
+ placeholder: Prop.string().propertiesPanel({
53
+ label: "Placeholder",
54
+ controlType: "INPUT_TEXT",
55
+ description: "Placeholder text shown when textarea is empty",
56
+ }),
57
+ rows: Prop.number().propertiesPanel({
58
+ label: "Rows",
59
+ controlType: "INPUT_TEXT",
60
+ description: "Number of visible text lines",
61
+ isRemovable: true,
62
+ visibility: "SHOW_NAME",
63
+ defaultOnAdd: 3,
64
+ }),
65
+ }),
66
+ styles: tailwindStylesCategory({
67
+ prioritizedTailwindProperties: ["resize"],
68
+ }),
69
+
70
+ interaction: Section.category(PropsCategory.Interaction).children({
71
+ disabled: Prop.boolean().propertiesPanel({
72
+ label: "Disabled",
73
+ controlType: "SWITCH",
74
+ description: "Whether the textarea is disabled",
75
+ }),
76
+ readOnly: Prop.boolean().propertiesPanel({
77
+ label: "Read only",
78
+ controlType: "SWITCH",
79
+ description: "Whether the textarea is read only",
80
+ }),
81
+ autoFocus: Prop.boolean().propertiesPanel({
82
+ label: "Auto focus",
83
+ controlType: "SWITCH",
84
+ description: "Whether the textarea should auto focus on page load",
85
+ }),
86
+ minLength: Prop.number().propertiesPanel({
87
+ label: "Min length",
88
+ controlType: "INPUT_TEXT",
89
+ description: "Minimum number of characters required",
90
+ isRemovable: true,
91
+ visibility: "SHOW_NAME",
92
+ defaultOnAdd: 0,
93
+ }),
94
+ maxLength: Prop.number().propertiesPanel({
95
+ label: "Max length",
96
+ controlType: "INPUT_TEXT",
97
+ description: "Maximum number of characters allowed",
98
+ isRemovable: true,
99
+ visibility: "SHOW_NAME",
100
+ defaultOnAdd: 1000,
101
+ }),
102
+ }),
103
+
104
+ events: Section.category(PropsCategory.EventHandlers).children({
105
+ onChange: Prop.eventHandler().propertiesPanel({
106
+ label: "On change",
107
+ description: "Triggered when the textarea value changes",
108
+ computedArgs: [
109
+ {
110
+ name: "event",
111
+ type: "object",
112
+ description: "The event object",
113
+ },
114
+ ],
115
+ }),
116
+ onFocus: Prop.eventHandler().propertiesPanel({
117
+ label: "On focus",
118
+ description: "Triggered when the textarea receives focus",
119
+ }),
120
+ onBlur: Prop.eventHandler().propertiesPanel({
121
+ label: "On blur",
122
+ description: "Triggered when the textarea loses focus",
123
+ }),
124
+ onKeyDown: Prop.eventHandler().propertiesPanel({
125
+ label: "On key down",
126
+ description: "Triggered when a key is pressed down",
127
+ computedArgs: [
128
+ {
129
+ name: "event",
130
+ type: "object",
131
+ description: "The event object",
132
+ },
133
+ ],
134
+ }),
135
+ }),
136
+ };
137
+
138
+ // Editor Configuration
139
+ const editorConfig: EditorConfig = {
140
+ icon: "input",
141
+ description:
142
+ "A multi-line textarea component for collecting longer text input",
143
+ };
144
+
145
+ // Registration
146
+ registerComponent(Textarea, propertiesDefinition).editorConfig(editorConfig);
147
+
148
+ export { Textarea };