@superblocksteam/vite-plugin-file-sync 2.0.7 → 2.0.8-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 (289) hide show
  1. package/dist/ai-service/app-interface/linter.js +1 -1
  2. package/dist/ai-service/app-interface/linter.js.map +1 -1
  3. package/dist/ai-service/const.d.ts +2 -2
  4. package/dist/ai-service/const.d.ts.map +1 -1
  5. package/dist/ai-service/const.js +2 -2
  6. package/dist/ai-service/const.js.map +1 -1
  7. package/dist/ai-service/integration-validator.d.ts +4 -0
  8. package/dist/ai-service/integration-validator.d.ts.map +1 -0
  9. package/dist/ai-service/integration-validator.js +54 -0
  10. package/dist/ai-service/integration-validator.js.map +1 -0
  11. package/dist/ai-service/integrations/from-prompt-context.js +1 -1
  12. package/dist/ai-service/integrations/from-prompt-context.js.map +1 -1
  13. package/dist/ai-service/prompts/draft-subprompts/superblocks-api-draft.d.ts +1 -1
  14. package/dist/ai-service/prompts/draft-subprompts/superblocks-api-draft.d.ts.map +1 -1
  15. package/dist/ai-service/prompts/draft-subprompts/superblocks-api-draft.js +16 -16
  16. package/dist/ai-service/prompts/draft-subprompts/superblocks-layouts-with-grid-examples.d.ts +1 -1
  17. package/dist/ai-service/prompts/draft-subprompts/superblocks-layouts-with-grid-examples.d.ts.map +1 -1
  18. package/dist/ai-service/prompts/draft-subprompts/superblocks-layouts-with-grid-examples.js +49 -49
  19. package/dist/ai-service/prompts/generated/library-components/ButtonPropsDocs.d.ts +2 -0
  20. package/dist/ai-service/prompts/generated/library-components/ButtonPropsDocs.d.ts.map +1 -0
  21. package/dist/ai-service/prompts/generated/library-components/ButtonPropsDocs.js +6 -0
  22. package/dist/ai-service/prompts/generated/library-components/ButtonPropsDocs.js.map +1 -0
  23. package/dist/ai-service/prompts/generated/library-components/CheckboxPropsDocs.d.ts +2 -0
  24. package/dist/ai-service/prompts/generated/library-components/CheckboxPropsDocs.d.ts.map +1 -0
  25. package/dist/ai-service/prompts/generated/library-components/CheckboxPropsDocs.js +6 -0
  26. package/dist/ai-service/prompts/generated/library-components/CheckboxPropsDocs.js.map +1 -0
  27. package/dist/ai-service/prompts/generated/library-components/ColumnPropsDocs.d.ts +2 -0
  28. package/dist/ai-service/prompts/generated/library-components/ColumnPropsDocs.d.ts.map +1 -0
  29. package/dist/ai-service/prompts/generated/library-components/ColumnPropsDocs.js +6 -0
  30. package/dist/ai-service/prompts/generated/library-components/ColumnPropsDocs.js.map +1 -0
  31. package/dist/ai-service/prompts/generated/library-components/ContainerPropsDocs.d.ts +2 -0
  32. package/dist/ai-service/prompts/generated/library-components/ContainerPropsDocs.d.ts.map +1 -0
  33. package/dist/ai-service/prompts/generated/library-components/ContainerPropsDocs.js +6 -0
  34. package/dist/ai-service/prompts/generated/library-components/ContainerPropsDocs.js.map +1 -0
  35. package/dist/ai-service/prompts/generated/library-components/DatePickerPropsDocs.d.ts +2 -0
  36. package/dist/ai-service/prompts/generated/library-components/DatePickerPropsDocs.d.ts.map +1 -0
  37. package/dist/ai-service/prompts/generated/library-components/DatePickerPropsDocs.js +6 -0
  38. package/dist/ai-service/prompts/generated/library-components/DatePickerPropsDocs.js.map +1 -0
  39. package/dist/ai-service/prompts/generated/library-components/DropdownPropsDocs.d.ts +2 -0
  40. package/dist/ai-service/prompts/generated/library-components/DropdownPropsDocs.d.ts.map +1 -0
  41. package/dist/ai-service/prompts/generated/library-components/DropdownPropsDocs.js +6 -0
  42. package/dist/ai-service/prompts/generated/library-components/DropdownPropsDocs.js.map +1 -0
  43. package/dist/ai-service/prompts/generated/library-components/IconPropsDocs.d.ts +2 -0
  44. package/dist/ai-service/prompts/generated/library-components/IconPropsDocs.d.ts.map +1 -0
  45. package/dist/ai-service/prompts/generated/library-components/IconPropsDocs.js +6 -0
  46. package/dist/ai-service/prompts/generated/library-components/IconPropsDocs.js.map +1 -0
  47. package/dist/ai-service/prompts/generated/library-components/ImagePropsDocs.d.ts +2 -0
  48. package/dist/ai-service/prompts/generated/library-components/ImagePropsDocs.d.ts.map +1 -0
  49. package/dist/ai-service/prompts/generated/library-components/ImagePropsDocs.js +6 -0
  50. package/dist/ai-service/prompts/generated/library-components/ImagePropsDocs.js.map +1 -0
  51. package/dist/ai-service/prompts/generated/library-components/InputPropsDocs.d.ts +2 -0
  52. package/dist/ai-service/prompts/generated/library-components/InputPropsDocs.d.ts.map +1 -0
  53. package/dist/ai-service/prompts/generated/library-components/InputPropsDocs.js +6 -0
  54. package/dist/ai-service/prompts/generated/library-components/InputPropsDocs.js.map +1 -0
  55. package/dist/ai-service/prompts/generated/library-components/ModalPropsDocs.d.ts +2 -0
  56. package/dist/ai-service/prompts/generated/library-components/ModalPropsDocs.d.ts.map +1 -0
  57. package/dist/ai-service/prompts/generated/library-components/ModalPropsDocs.js +6 -0
  58. package/dist/ai-service/prompts/generated/library-components/ModalPropsDocs.js.map +1 -0
  59. package/dist/ai-service/prompts/generated/library-components/PagePropsDocs.d.ts +2 -0
  60. package/dist/ai-service/prompts/generated/library-components/PagePropsDocs.d.ts.map +1 -0
  61. package/dist/ai-service/prompts/generated/library-components/PagePropsDocs.js +6 -0
  62. package/dist/ai-service/prompts/generated/library-components/PagePropsDocs.js.map +1 -0
  63. package/dist/ai-service/prompts/generated/library-components/SectionPropsDocs.d.ts +2 -0
  64. package/dist/ai-service/prompts/generated/library-components/SectionPropsDocs.d.ts.map +1 -0
  65. package/dist/ai-service/prompts/generated/library-components/SectionPropsDocs.js +6 -0
  66. package/dist/ai-service/prompts/generated/library-components/SectionPropsDocs.js.map +1 -0
  67. package/dist/ai-service/prompts/generated/library-components/SlideoutPropsDocs.d.ts +2 -0
  68. package/dist/ai-service/prompts/generated/library-components/SlideoutPropsDocs.d.ts.map +1 -0
  69. package/dist/ai-service/prompts/generated/library-components/SlideoutPropsDocs.js +6 -0
  70. package/dist/ai-service/prompts/generated/library-components/SlideoutPropsDocs.js.map +1 -0
  71. package/dist/ai-service/prompts/generated/library-components/SwitchPropsDocs.d.ts +2 -0
  72. package/dist/ai-service/prompts/generated/library-components/SwitchPropsDocs.d.ts.map +1 -0
  73. package/dist/ai-service/prompts/generated/library-components/SwitchPropsDocs.js +6 -0
  74. package/dist/ai-service/prompts/generated/library-components/SwitchPropsDocs.js.map +1 -0
  75. package/dist/ai-service/prompts/generated/library-components/TablePropsDocs.d.ts +2 -0
  76. package/dist/ai-service/prompts/generated/library-components/TablePropsDocs.d.ts.map +1 -0
  77. package/dist/ai-service/prompts/generated/library-components/TablePropsDocs.js +6 -0
  78. package/dist/ai-service/prompts/generated/library-components/TablePropsDocs.js.map +1 -0
  79. package/dist/ai-service/prompts/generated/library-components/TextPropsDocs.d.ts +2 -0
  80. package/dist/ai-service/prompts/generated/library-components/TextPropsDocs.d.ts.map +1 -0
  81. package/dist/ai-service/prompts/generated/library-components/TextPropsDocs.js +6 -0
  82. package/dist/ai-service/prompts/generated/library-components/TextPropsDocs.js.map +1 -0
  83. package/dist/ai-service/prompts/generated/library-components/index.d.ts +16 -16
  84. package/dist/ai-service/prompts/generated/library-components/index.d.ts.map +1 -1
  85. package/dist/ai-service/prompts/generated/library-components/index.js +16 -16
  86. package/dist/ai-service/prompts/generated/library-components/index.js.map +1 -1
  87. package/dist/ai-service/prompts/generated/library-typedefs/Dim.js +1 -1
  88. package/dist/ai-service/prompts/generated/library-typedefs/EventFlow.d.ts +2 -0
  89. package/dist/ai-service/prompts/generated/library-typedefs/EventFlow.d.ts.map +1 -0
  90. package/dist/ai-service/prompts/generated/library-typedefs/EventFlow.js +6 -0
  91. package/dist/ai-service/prompts/generated/library-typedefs/EventFlow.js.map +1 -0
  92. package/dist/ai-service/prompts/generated/library-typedefs/TextStyleWithVariant.js +1 -1
  93. package/dist/ai-service/prompts/generated/library-typedefs/index.d.ts +1 -1
  94. package/dist/ai-service/prompts/generated/library-typedefs/index.d.ts.map +1 -1
  95. package/dist/ai-service/prompts/generated/library-typedefs/index.js +1 -1
  96. package/dist/ai-service/prompts/generated/library-typedefs/index.js.map +1 -1
  97. package/dist/ai-service/prompts/generated/subprompts/full-examples.d.ts +1 -1
  98. package/dist/ai-service/prompts/generated/subprompts/full-examples.d.ts.map +1 -1
  99. package/dist/ai-service/prompts/generated/subprompts/full-examples.js +2 -2
  100. package/dist/ai-service/prompts/generated/subprompts/full-examples.js.map +1 -1
  101. package/dist/ai-service/prompts/generated/subprompts/superblocks-api.d.ts +1 -1
  102. package/dist/ai-service/prompts/generated/subprompts/superblocks-api.d.ts.map +1 -1
  103. package/dist/ai-service/prompts/generated/subprompts/superblocks-api.js +2 -2
  104. package/dist/ai-service/prompts/generated/subprompts/superblocks-api.js.map +1 -1
  105. package/dist/ai-service/prompts/generated/subprompts/superblocks-components-rules.d.ts +1 -1
  106. package/dist/ai-service/prompts/generated/subprompts/superblocks-components-rules.d.ts.map +1 -1
  107. package/dist/ai-service/prompts/generated/subprompts/superblocks-components-rules.js +2 -2
  108. package/dist/ai-service/prompts/generated/subprompts/superblocks-components-rules.js.map +1 -1
  109. package/dist/ai-service/prompts/generated/subprompts/superblocks-custom-components.js +1 -1
  110. package/dist/ai-service/prompts/generated/subprompts/superblocks-data-filtering.d.ts +1 -1
  111. package/dist/ai-service/prompts/generated/subprompts/superblocks-data-filtering.d.ts.map +1 -1
  112. package/dist/ai-service/prompts/generated/subprompts/superblocks-data-filtering.js +2 -2
  113. package/dist/ai-service/prompts/generated/subprompts/superblocks-data-filtering.js.map +1 -1
  114. package/dist/ai-service/prompts/generated/subprompts/superblocks-event-flow.d.ts +1 -1
  115. package/dist/ai-service/prompts/generated/subprompts/superblocks-event-flow.d.ts.map +1 -1
  116. package/dist/ai-service/prompts/generated/subprompts/superblocks-event-flow.js +2 -2
  117. package/dist/ai-service/prompts/generated/subprompts/superblocks-event-flow.js.map +1 -1
  118. package/dist/ai-service/prompts/generated/subprompts/superblocks-forms.d.ts +1 -1
  119. package/dist/ai-service/prompts/generated/subprompts/superblocks-forms.d.ts.map +1 -1
  120. package/dist/ai-service/prompts/generated/subprompts/superblocks-forms.js +2 -2
  121. package/dist/ai-service/prompts/generated/subprompts/superblocks-forms.js.map +1 -1
  122. package/dist/ai-service/prompts/generated/subprompts/superblocks-layouts.d.ts +1 -1
  123. package/dist/ai-service/prompts/generated/subprompts/superblocks-layouts.d.ts.map +1 -1
  124. package/dist/ai-service/prompts/generated/subprompts/superblocks-layouts.js +2 -2
  125. package/dist/ai-service/prompts/generated/subprompts/superblocks-layouts.js.map +1 -1
  126. package/dist/ai-service/prompts/generated/subprompts/superblocks-page.d.ts +1 -1
  127. package/dist/ai-service/prompts/generated/subprompts/superblocks-page.d.ts.map +1 -1
  128. package/dist/ai-service/prompts/generated/subprompts/superblocks-page.js +2 -2
  129. package/dist/ai-service/prompts/generated/subprompts/superblocks-page.js.map +1 -1
  130. package/dist/ai-service/prompts/generated/subprompts/superblocks-rbac.d.ts +1 -1
  131. package/dist/ai-service/prompts/generated/subprompts/superblocks-rbac.d.ts.map +1 -1
  132. package/dist/ai-service/prompts/generated/subprompts/superblocks-rbac.js +2 -2
  133. package/dist/ai-service/prompts/generated/subprompts/superblocks-rbac.js.map +1 -1
  134. package/dist/ai-service/prompts/generated/subprompts/superblocks-routes.js +1 -1
  135. package/dist/ai-service/prompts/generated/subprompts/superblocks-state.d.ts +1 -1
  136. package/dist/ai-service/prompts/generated/subprompts/superblocks-state.d.ts.map +1 -1
  137. package/dist/ai-service/prompts/generated/subprompts/superblocks-state.js +2 -2
  138. package/dist/ai-service/prompts/generated/subprompts/superblocks-state.js.map +1 -1
  139. package/dist/ai-service/prompts/generated/subprompts/superblocks-theming.js +1 -1
  140. package/dist/ai-service/prompts/generated/subprompts/system.d.ts +1 -1
  141. package/dist/ai-service/prompts/generated/subprompts/system.d.ts.map +1 -1
  142. package/dist/ai-service/prompts/generated/subprompts/system.js +2 -2
  143. package/dist/ai-service/prompts/generated/subprompts/system.js.map +1 -1
  144. package/dist/ai-service/prompts/markdown-loader.d.ts +1 -1
  145. package/dist/ai-service/prompts/markdown-loader.js +1 -1
  146. package/dist/ai-service/prompts/system.js +1 -1
  147. package/dist/ai-service/prompts/system.js.map +1 -1
  148. package/dist/ai-service/state-machine/clark-fsm.d.ts +4 -2
  149. package/dist/ai-service/state-machine/clark-fsm.d.ts.map +1 -1
  150. package/dist/ai-service/state-machine/clark-fsm.js.map +1 -1
  151. package/dist/ai-service/state-machine/handlers/agent-planning.d.ts.map +1 -1
  152. package/dist/ai-service/state-machine/handlers/agent-planning.js +29 -4
  153. package/dist/ai-service/state-machine/handlers/agent-planning.js.map +1 -1
  154. package/dist/ai-service/state-machine/handlers/runtime-reviewing.d.ts.map +1 -1
  155. package/dist/ai-service/state-machine/handlers/runtime-reviewing.js +9 -2
  156. package/dist/ai-service/state-machine/handlers/runtime-reviewing.js.map +1 -1
  157. package/dist/ai-service/test-utils/app-generation-mocks/orders-app.d.ts +1 -1
  158. package/dist/ai-service/test-utils/app-generation-mocks/orders-app.js +98 -98
  159. package/dist/ai-service/test-utils/app-generation-mocks/smoketest.d.ts +1 -1
  160. package/dist/ai-service/test-utils/app-generation-mocks/smoketest.js +22 -22
  161. package/dist/codegen.d.ts.map +1 -1
  162. package/dist/file-system-manager.js +12 -12
  163. package/dist/file-system-manager.js.map +1 -1
  164. package/dist/parsing/computed/to-code-computed.js +1 -1
  165. package/dist/parsing/computed/to-code-computed.js.map +1 -1
  166. package/dist/parsing/computed/to-value-computed.d.ts +1 -1
  167. package/dist/parsing/computed/to-value-computed.d.ts.map +1 -1
  168. package/dist/parsing/computed/to-value-computed.js +19 -7
  169. package/dist/parsing/computed/to-value-computed.js.map +1 -1
  170. package/dist/parsing/dim/index.js +1 -1
  171. package/dist/parsing/dim/index.js.map +1 -1
  172. package/dist/parsing/dim/to-value-dimensions.d.ts +2 -1
  173. package/dist/parsing/dim/to-value-dimensions.d.ts.map +1 -1
  174. package/dist/parsing/dim/to-value-dimensions.js +4 -3
  175. package/dist/parsing/dim/to-value-dimensions.js.map +1 -1
  176. package/dist/parsing/events/index.d.ts +1 -1
  177. package/dist/parsing/events/index.d.ts.map +1 -1
  178. package/dist/parsing/events/index.js.map +1 -1
  179. package/dist/parsing/events/to-code-events.d.ts.map +1 -1
  180. package/dist/parsing/events/to-code-events.js +13 -4
  181. package/dist/parsing/events/to-code-events.js.map +1 -1
  182. package/dist/parsing/events/to-value-events.d.ts +2 -2
  183. package/dist/parsing/events/to-value-events.d.ts.map +1 -1
  184. package/dist/parsing/events/to-value-events.js +100 -18
  185. package/dist/parsing/events/to-value-events.js.map +1 -1
  186. package/dist/parsing/ids.js +6 -6
  187. package/dist/parsing/ids.js.map +1 -1
  188. package/dist/parsing/imports.js +4 -4
  189. package/dist/parsing/imports.js.map +1 -1
  190. package/dist/parsing/jsx-utils.d.ts +4 -2
  191. package/dist/parsing/jsx-utils.d.ts.map +1 -1
  192. package/dist/parsing/jsx-utils.js +37 -13
  193. package/dist/parsing/jsx-utils.js.map +1 -1
  194. package/dist/parsing/jsx.d.ts +1 -0
  195. package/dist/parsing/jsx.d.ts.map +1 -1
  196. package/dist/parsing/jsx.js +24 -19
  197. package/dist/parsing/jsx.js.map +1 -1
  198. package/dist/parsing/page.d.ts.map +1 -1
  199. package/dist/parsing/page.js +13 -3
  200. package/dist/parsing/page.js.map +1 -1
  201. package/dist/parsing/properties.js +3 -3
  202. package/dist/parsing/properties.js.map +1 -1
  203. package/dist/parsing/scope.d.ts +2 -2
  204. package/dist/parsing/scope.js +8 -8
  205. package/dist/parsing/scope.js.map +1 -1
  206. package/dist/parsing/template/index.d.ts.map +1 -1
  207. package/dist/parsing/template/index.js.map +1 -1
  208. package/dist/parsing/type-parsing-registry.d.ts +1 -1
  209. package/dist/parsing/types.d.ts +1 -1
  210. package/dist/parsing/types.d.ts.map +1 -1
  211. package/dist/parsing/util.d.ts +3 -3
  212. package/dist/parsing/util.d.ts.map +1 -1
  213. package/dist/parsing/util.js +20 -7
  214. package/dist/parsing/util.js.map +1 -1
  215. package/dist/refactor/entities.js +1 -1
  216. package/dist/refactor/entities.js.map +1 -1
  217. package/dist/rename-manager.js +1 -1
  218. package/dist/rename-manager.js.map +1 -1
  219. package/dist/source-tracker.js +8 -8
  220. package/dist/source-tracker.js.map +1 -1
  221. package/package.json +5 -5
  222. package/dist/ai-service/prompts/generated/library-components/SbButtonPropsDocs.d.ts +0 -2
  223. package/dist/ai-service/prompts/generated/library-components/SbButtonPropsDocs.d.ts.map +0 -1
  224. package/dist/ai-service/prompts/generated/library-components/SbButtonPropsDocs.js +0 -6
  225. package/dist/ai-service/prompts/generated/library-components/SbButtonPropsDocs.js.map +0 -1
  226. package/dist/ai-service/prompts/generated/library-components/SbCheckboxPropsDocs.d.ts +0 -2
  227. package/dist/ai-service/prompts/generated/library-components/SbCheckboxPropsDocs.d.ts.map +0 -1
  228. package/dist/ai-service/prompts/generated/library-components/SbCheckboxPropsDocs.js +0 -6
  229. package/dist/ai-service/prompts/generated/library-components/SbCheckboxPropsDocs.js.map +0 -1
  230. package/dist/ai-service/prompts/generated/library-components/SbColumnPropsDocs.d.ts +0 -2
  231. package/dist/ai-service/prompts/generated/library-components/SbColumnPropsDocs.d.ts.map +0 -1
  232. package/dist/ai-service/prompts/generated/library-components/SbColumnPropsDocs.js +0 -6
  233. package/dist/ai-service/prompts/generated/library-components/SbColumnPropsDocs.js.map +0 -1
  234. package/dist/ai-service/prompts/generated/library-components/SbContainerPropsDocs.d.ts +0 -2
  235. package/dist/ai-service/prompts/generated/library-components/SbContainerPropsDocs.d.ts.map +0 -1
  236. package/dist/ai-service/prompts/generated/library-components/SbContainerPropsDocs.js +0 -6
  237. package/dist/ai-service/prompts/generated/library-components/SbContainerPropsDocs.js.map +0 -1
  238. package/dist/ai-service/prompts/generated/library-components/SbDatePickerPropsDocs.d.ts +0 -2
  239. package/dist/ai-service/prompts/generated/library-components/SbDatePickerPropsDocs.d.ts.map +0 -1
  240. package/dist/ai-service/prompts/generated/library-components/SbDatePickerPropsDocs.js +0 -6
  241. package/dist/ai-service/prompts/generated/library-components/SbDatePickerPropsDocs.js.map +0 -1
  242. package/dist/ai-service/prompts/generated/library-components/SbDropdownPropsDocs.d.ts +0 -2
  243. package/dist/ai-service/prompts/generated/library-components/SbDropdownPropsDocs.d.ts.map +0 -1
  244. package/dist/ai-service/prompts/generated/library-components/SbDropdownPropsDocs.js +0 -6
  245. package/dist/ai-service/prompts/generated/library-components/SbDropdownPropsDocs.js.map +0 -1
  246. package/dist/ai-service/prompts/generated/library-components/SbIconPropsDocs.d.ts +0 -2
  247. package/dist/ai-service/prompts/generated/library-components/SbIconPropsDocs.d.ts.map +0 -1
  248. package/dist/ai-service/prompts/generated/library-components/SbIconPropsDocs.js +0 -6
  249. package/dist/ai-service/prompts/generated/library-components/SbIconPropsDocs.js.map +0 -1
  250. package/dist/ai-service/prompts/generated/library-components/SbImagePropsDocs.d.ts +0 -2
  251. package/dist/ai-service/prompts/generated/library-components/SbImagePropsDocs.d.ts.map +0 -1
  252. package/dist/ai-service/prompts/generated/library-components/SbImagePropsDocs.js +0 -6
  253. package/dist/ai-service/prompts/generated/library-components/SbImagePropsDocs.js.map +0 -1
  254. package/dist/ai-service/prompts/generated/library-components/SbInputPropsDocs.d.ts +0 -2
  255. package/dist/ai-service/prompts/generated/library-components/SbInputPropsDocs.d.ts.map +0 -1
  256. package/dist/ai-service/prompts/generated/library-components/SbInputPropsDocs.js +0 -6
  257. package/dist/ai-service/prompts/generated/library-components/SbInputPropsDocs.js.map +0 -1
  258. package/dist/ai-service/prompts/generated/library-components/SbModalPropsDocs.d.ts +0 -2
  259. package/dist/ai-service/prompts/generated/library-components/SbModalPropsDocs.d.ts.map +0 -1
  260. package/dist/ai-service/prompts/generated/library-components/SbModalPropsDocs.js +0 -6
  261. package/dist/ai-service/prompts/generated/library-components/SbModalPropsDocs.js.map +0 -1
  262. package/dist/ai-service/prompts/generated/library-components/SbPagePropsDocs.d.ts +0 -2
  263. package/dist/ai-service/prompts/generated/library-components/SbPagePropsDocs.d.ts.map +0 -1
  264. package/dist/ai-service/prompts/generated/library-components/SbPagePropsDocs.js +0 -6
  265. package/dist/ai-service/prompts/generated/library-components/SbPagePropsDocs.js.map +0 -1
  266. package/dist/ai-service/prompts/generated/library-components/SbSectionPropsDocs.d.ts +0 -2
  267. package/dist/ai-service/prompts/generated/library-components/SbSectionPropsDocs.d.ts.map +0 -1
  268. package/dist/ai-service/prompts/generated/library-components/SbSectionPropsDocs.js +0 -6
  269. package/dist/ai-service/prompts/generated/library-components/SbSectionPropsDocs.js.map +0 -1
  270. package/dist/ai-service/prompts/generated/library-components/SbSlideoutPropsDocs.d.ts +0 -2
  271. package/dist/ai-service/prompts/generated/library-components/SbSlideoutPropsDocs.d.ts.map +0 -1
  272. package/dist/ai-service/prompts/generated/library-components/SbSlideoutPropsDocs.js +0 -6
  273. package/dist/ai-service/prompts/generated/library-components/SbSlideoutPropsDocs.js.map +0 -1
  274. package/dist/ai-service/prompts/generated/library-components/SbSwitchPropsDocs.d.ts +0 -2
  275. package/dist/ai-service/prompts/generated/library-components/SbSwitchPropsDocs.d.ts.map +0 -1
  276. package/dist/ai-service/prompts/generated/library-components/SbSwitchPropsDocs.js +0 -6
  277. package/dist/ai-service/prompts/generated/library-components/SbSwitchPropsDocs.js.map +0 -1
  278. package/dist/ai-service/prompts/generated/library-components/SbTablePropsDocs.d.ts +0 -2
  279. package/dist/ai-service/prompts/generated/library-components/SbTablePropsDocs.d.ts.map +0 -1
  280. package/dist/ai-service/prompts/generated/library-components/SbTablePropsDocs.js +0 -6
  281. package/dist/ai-service/prompts/generated/library-components/SbTablePropsDocs.js.map +0 -1
  282. package/dist/ai-service/prompts/generated/library-components/SbTextPropsDocs.d.ts +0 -2
  283. package/dist/ai-service/prompts/generated/library-components/SbTextPropsDocs.d.ts.map +0 -1
  284. package/dist/ai-service/prompts/generated/library-components/SbTextPropsDocs.js +0 -6
  285. package/dist/ai-service/prompts/generated/library-components/SbTextPropsDocs.js.map +0 -1
  286. package/dist/ai-service/prompts/generated/library-typedefs/SbEventFlow.d.ts +0 -2
  287. package/dist/ai-service/prompts/generated/library-typedefs/SbEventFlow.d.ts.map +0 -1
  288. package/dist/ai-service/prompts/generated/library-typedefs/SbEventFlow.js +0 -6
  289. package/dist/ai-service/prompts/generated/library-typedefs/SbEventFlow.js.map +0 -1
@@ -12,7 +12,7 @@ const options = (cwd) => ({
12
12
  // NOTE: we are only applying this single rule for now
13
13
  // add more rules as they are validated
14
14
  ruleFilter: ({ ruleId }) => {
15
- if (ruleId === "superblocks/no-sbcomputed-jsx-child") {
15
+ if (ruleId === "superblocks/no-computed-jsx-child") {
16
16
  return true;
17
17
  }
18
18
  return false;
@@ -1 +1 @@
1
- {"version":3,"file":"linter.js","sourceRoot":"","sources":["../../../src/ai-service/app-interface/linter.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAChC,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEjD,MAAM,OAAO,GAAG,CAAC,GAAW,EAAkB,EAAE,CAAC,CAAC;IAChD,GAAG;IACH,KAAK,EAAE,IAAI;IACX,aAAa,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,cAAc,EAAE,cAAc,CAAC;IAC7D,QAAQ,EAAE,CAAC,SAAS,CAAC;IACrB,cAAc,EAAE,CAAC,iBAAiB,CAAC;IACnC,WAAW,EAAE,KAAK;IAClB,uBAAuB,EAAE,KAAK;IAC9B,sDAAsD;IACtD,uCAAuC;IACvC,UAAU,EAAE,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE;QACzB,IAAI,MAAM,KAAK,qCAAqC,EAAE,CAAC;YACrD,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO,KAAK,CAAC;IACf,CAAC;CACF,CAAC,CAAC;AAEH,MAAM,OAAO,MAAM;IACA,MAAM,CAAS;IACf,GAAG,CAAS;IAE7B,YAAY,GAAW;QACrB,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;Q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AAG,MAAM,CAAC;YAC7B,CAAC;YAED,OAAO,GAAG,CAAC;QACb,CAAC,EACD,EAA8B,CAC/B,CAAC;QAEF,MAAM,GAAG,GAAG,WAAW,CAAC,GAAG,EAAE,CAAC;QAC9B,SAAS,EAAE,CAAC,KAAK,CACf,6BAA6B,GAAG,GAAG,KAAK,UAAU,KAAK,CAAC,MAAM,QAAQ,CACvE,CAAC;QACF,OAAO,MAAM,CAAC;IAChB,CAAC;CACF"}
@@ -12,6 +12,6 @@ export declare const enum Paths {
12
12
  AllFiles = "**/*"
13
13
  }
14
14
  export declare const LOG_SYSTEM_PROMPT = false;
15
- export declare const SAVE_LLM_GENERATION_STEPS = false;
16
- export declare const SAVE_RAW_LLM_RESPONSE = false;
15
+ export declare const SAVE_LLM_GENERATION_STEPS = true;
16
+ export declare const SAVE_RAW_LLM_RESPONSE = true;
17
17
  //# sourceMappingURL=const.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"const.d.ts","sourceRoot":"","sources":["../../src/ai-service/const.ts"],"names":[],"mappings":"AAAA,0BAAkB,KAAK;IACrB,aAAa,kCAAkC;IAC/C,QAAQ,2CAA2C;IACnD,WAAW,8BAA8B;IACzC,UAAU,6BAA6B;IACvC,UAAU,8BAA8B;IACxC,QAAQ,aAAa;IACrB,QAAQ,gBAAgB;IACxB,SAAS,gBAAgB;IACzB,OAAO,YAAY;IACnB,WAAW,iBAAiB;IAC5B,QAAQ,SAAS;CAClB;AAED,eAAO,MAAM,iBAAiB,QAAQ,CAAC;AACvC,eAAO,MAAM,yBAAyB,QAAQ,CAAC;AAC/C,eAAO,MAAM,qBAAqB,QAAQ,CAAC"}
1
+ {"version":3,"file":"const.d.ts","sourceRoot":"","sources":["../../src/ai-service/const.ts"],"names":[],"mappings":"AAAA,0BAAkB,KAAK;IACrB,aAAa,kCAAkC;IAC/C,QAAQ,2CAA2C;IACnD,WAAW,8BAA8B;IACzC,UAAU,6BAA6B;IACvC,UAAU,8BAA8B;IACxC,QAAQ,aAAa;IACrB,QAAQ,gBAAgB;IACxB,SAAS,gBAAgB;IACzB,OAAO,YAAY;IACnB,WAAW,iBAAiB;IAC5B,QAAQ,SAAS;CAClB;AAED,eAAO,MAAM,iBAAiB,QAAQ,CAAC;AACvC,eAAO,MAAM,yBAAyB,OAAO,CAAC;AAC9C,eAAO,MAAM,qBAAqB,OAAO,CAAC"}
@@ -13,6 +13,6 @@ export var Paths;
13
13
  Paths["AllFiles"] = "**/*";
14
14
  })(Paths || (Paths = {}));
15
15
  export const LOG_SYSTEM_PROMPT = false;
16
- export const SAVE_LLM_GENERATION_STEPS = false;
17
- export const SAVE_RAW_LLM_RESPONSE = false;
16
+ export const SAVE_LLM_GENERATION_STEPS = true;
17
+ export const SAVE_RAW_LLM_RESPONSE = true;
18
18
  //# sourceMappingURL=const.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"const.js","sourceRoot":"","sources":["../../src/ai-service/const.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAkB,KAYjB;AAZD,WAAkB,KAAK;IACrB,wDAA+C,CAAA;IAC/C,4DAAmD,CAAA;IACnD,kDAAyC,CAAA;IACzC,gDAAuC,CAAA;IACvC,iDAAwC,CAAA;IACxC,8BAAqB,CAAA;IACrB,iCAAwB,CAAA;IACxB,kCAAyB,CAAA;IACzB,4BAAmB,CAAA;IACnB,qCAA4B,CAAA;IAC5B,0BAAiB,CAAA;AACnB,CAAC,EAZiB,KAAK,KAAL,KAAK,QAYtB;AAED,MAAM,CAAC,MAAM,iBAAiB,GAAG,KAAK,CAAC;AACvC,MAAM,CAAC,MAAM,yBAAyB,GAAG,KAAK,CAAC;AAC/C,MAAM,CAAC,MAAM,qBAAqB,GAAG,KAAK,CAAC"}
1
+ {"version":3,"file":"const.js","sourceRoot":"","sources":["../../src/ai-service/const.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAkB,KAYjB;AAZD,WAAkB,KAAK;IACrB,wDAA+C,CAAA;IAC/C,4DAAmD,CAAA;IACnD,kDAAyC,CAAA;IACzC,gDAAuC,CAAA;IACvC,iDAAwC,CAAA;IACxC,8BAAqB,CAAA;IACrB,iCAAwB,CAAA;IACxB,kCAAyB,CAAA;IACzB,4BAAmB,CAAA;IACnB,qCAA4B,CAAA;IAC5B,0BAAiB,CAAA;AACnB,CAAC,EAZiB,KAAK,KAAL,KAAK,QAYtB;AAED,MAAM,CAAC,MAAM,iBAAiB,GAAG,KAAK,CAAC;AACvC,MAAM,CAAC,MAAM,yBAAyB,GAAG,IAAI,CAAC;AAC9C,MAAM,CAAC,MAAM,qBAAqB,GAAG,IAAI,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { FileArtifact } from "./types.js";
2
+ import type { PromptContextIntegration } from "@superblocksteam/library-shared/types";
3
+ export declare function validateIntegrationsInFiles(files: FileArtifact[], availableIntegrations: PromptContextIntegration[]): Record<string, string[]> | null;
4
+ //# sourceMappingURL=integration-validator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"integration-validator.d.ts","sourceRoot":"","sources":["../../src/ai-service/integration-validator.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC/C,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AAEtF,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,YAAY,EAAE,EACrB,qBAAqB,EAAE,wBAAwB,EAAE,GAChD,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,GAAG,IAAI,CAqCjC"}
@@ -0,0 +1,54 @@
1
+ import { getLogger } from "../util/logger.js";
2
+ import { datasourceSdkClassByType } from "./integrations/const.js";
3
+ export function validateIntegrationsInFiles(files, availableIntegrations) {
4
+ const logger = getLogger();
5
+ const availableIntegrationIds = new Set(availableIntegrations.map((integration) => integration.id).filter(Boolean));
6
+ logger.debug(`[ai-service] Debug - availableIntegrations: ${JSON.stringify(availableIntegrations)}`);
7
+ const integrationErrors = {};
8
+ for (const file of files) {
9
+ const integrationReferences = extractIntegrationReferences(file.content);
10
+ for (const ref of integrationReferences) {
11
+ if (!availableIntegrationIds.has(ref.id)) {
12
+ if (!integrationErrors[file.filePath]) {
13
+ integrationErrors[file.filePath] = [];
14
+ }
15
+ const integrationList = availableIntegrations
16
+ .map((integration) => `- Name: ${integration.name}, Type: ${integration.type}, ID: ${integration.id}`)
17
+ .join("\n");
18
+ integrationErrors[file.filePath].push(`Integration ID "${ref.id}" not found in available integrations. Here are the available integrations with their IDs:\n${integrationList}`);
19
+ }
20
+ }
21
+ }
22
+ return Object.keys(integrationErrors).length > 0 ? integrationErrors : null;
23
+ }
24
+ function extractIntegrationReferences(code) {
25
+ const references = [];
26
+ const lines = code.split("\n");
27
+ for (let i = 0; i < lines.length; i++) {
28
+ const line = lines[i];
29
+ if (!line)
30
+ continue;
31
+ // Look for patterns like: new IntegrationClassName("step_name", "integration-id")
32
+ const integrationPattern = /new\s+(\w+)\s*\(\s*["']([^"']+)["']\s*,\s*["']([^"']+)["']/g;
33
+ const matches = Array.from(line.matchAll(integrationPattern));
34
+ for (const match of matches) {
35
+ const className = match[1];
36
+ const stepName = match[2];
37
+ const id = match[3];
38
+ // Check if this className is a known integration SDK class
39
+ if (className &&
40
+ stepName &&
41
+ id &&
42
+ Object.values(datasourceSdkClassByType).includes(className)) {
43
+ references.push({
44
+ id,
45
+ className,
46
+ filePath: "generated-file", // This will be updated by the caller
47
+ line: i + 1,
48
+ });
49
+ }
50
+ }
51
+ }
52
+ return references;
53
+ }
54
+ //# sourceMappingURL=integration-validator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"integration-validator.js","sourceRoot":"","sources":["../../src/ai-service/integration-validator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAInE,MAAM,UAAU,2BAA2B,CACzC,KAAqB,EACrB,qBAAiD;IAE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C;AAC9E,CAAC;AASD,SAAS,4BAA4B,CAAC,IAAY;IAChD,MAAM,UAAU,GAA2B,EAAE,CAAC;IAC9C,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAE/B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACtC,MAAM,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;QACtB,IAAI,CAAC,IAAI;YAAE,SAAS;QAEpB,kFAAkF;QAClF,MAAM,kBAAkB,GACtB,6DAA6D,CAAC;QAChE,MAAM,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,kBAAkB,CAAC,CAAC,CAAC;QAE9D,KAAK,MAAM,KAAK,IAAI,OAAO,EAAE,CAAC;YAC5B,MAAM,SAAS,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;YAC3B,MAAM,QAAQ,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;YAC1B,MAAM,EAAE,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;YAEpB,2DAA2D;YAC3D,IACE,SAAS;gBACT,QAAQ;gBACR,EAAE;gBACF,MAAM,CAAC,MAAM,CAAC,wBAAwB,CAAC,CAAC,QAAQ,CAAC,SAAgB,CAAC,EAClE,CAAC;gBACD,UAAU,CAAC,IAAI,CAAC;oBACd,EAAE;oBACF,SAAS;oBACT,QAAQ,EAAE,gBAAgB,EAAE,qCAAqC;oBACjE,IAAI,EAAE,CAAC,GAAG,CAAC;iBACZ,CAAC,CAAC;YACL,CAAC;QACH,CAAC;IACH,CAAC;IAED,OAAO,UAAU,CAAC;AACpB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { databaseIntegrationTypes, datasourceSdkClassByType } from "./const.js";
2
2
  export const sdkIntegrationFromPromptContext = (integration) => {
3
- const [name, id] = integration.name.split("__");
3
+ const { name, id } = integration;
4
4
  const type = integration.type;
5
5
  if (!name ||
6
6
  !id ||
@@ -1 +1 @@
1
- {"version":3,"file":"from-prompt-context.js","sourceRoot":"","sources":["../../../src/ai-service/integrations/from-prompt-context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAWhF,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAC7C,WAAqC,EACd,EAAE;IACzB,MAAM,CAAC,IAAI,EAAE,EAAE,CAAC,GAAG,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAChD,MAAM,IAAI,GAAG,WAAW,CAAC,IAA0B,CAAC;IAEpD,IACE,CAAC,IAAI;QACL,CAAC,EAAE;QACH,CAAC,gBAAgB,CAAC;YAChB,IAAI;SACL,CAAC,EACF,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO;QACL,IAAI;QACJ,EAAE;QACF,IAAI;QACJ,QAAQ,EAAE,iBAAiB,CAAC,WAAW,CAAC;KACzC,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,iBAAiB,GAAG,CAAC,WAAqC,EAAE,EAAE;IAClE,IACE,CAAC,WAAW,CAAC,QAAQ;QACrB,CAAC,qBAAqB,CAAC;YACrB,IAAI,EAAE,WAAW,CAAC,IAAkC;SACrD,CAAC,EACF,CAAC;QACD,OAAO,WAAW,CAAC,QAAQ,CAAC;IAC9B,CAAC;IAED,mCAAmC;IACnC,MAAM,MAAM,GAAG,WAAW,CAAC,QAAQ,CAAC,MAAM,IAAI,WAAW,CAAC,QAAQ,CAAC,QAAQ,CAAC;IAC5E,IAAI,CAAC,MAAM,IAAI,CAAC,MAAM,CAAC,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC;QAC/D,OAAO,WAAW,CAAC,QAAQ,CAAC;IAC9B,CAAC;IAED,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,CAAC,GAAG,CACxC,CAAC,QAA6B,EAAE,EAAE;QAChC,MAAM,UAAU,GACd,QAAQ,CAAC,OAAO,EAAE,GAAG,CAAC,CAAC,SAA+B,EAAE,EAAE,CAAC,CAAC;YAC1D,IAAI,EAAE,SAAS,CAAC,IAAI;YACpB,IAAI,EAAE,SAAS,CAAC,IAAI;SACrB,CAAC,CAAC,IAAI,EAAE,CAAC;QAEZ,OAAO;YACL,IAAI,EAAE,QAAQ,CAAC,IAAI;YACnB,IAAI,EAAE,QAAQ,CAAC,IAAI;YACnB,MAAM,EAAE,QAAQ,CAAC,MAAM;YACvB,OAAO,EAAE,UAAU;SACpB,CAAC;IACJ,CAAC,CACF,CAAC;IAEF,OAAO;QACL,MAAM,EAAE;YACN,MAAM,EAAE,gBAAgB;SACzB;KACF,CAAC;AACJ,CAAC,CAAC;AAEF,SAAS,gBAAgB,CACvB,WAAoC;IAEpC,OAAO,CACL,OAAO,WAAW,CAAC,IAAI,KAAK,QAAQ;QACpC,WAAW,CAAC,IAAI,IAAI,wBAAwB,CAC7C,CAAC;AACJ,CAAC;AAED,SAAS,qBAAqB,CAC5B,WAAoC;IAEpC,OAAO,wBAAwB,CAAC,QAAQ,CACtC,WAAW,CAAC,IAAkC,CAC/C,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"from-prompt-context.js","sourceRoot":"","sources":["../../../src/ai-service/integrations/from-prompt-context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAWhF,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAC7C,WAAqC,EACd,EAAE;IACzB,MAAM,EAAE,IAAI,EAAE,EAAE,EAAE,GAAG,WAAW,CAAC;IACjC,MAAM,IAAI,GAAG,WAAW,CAAC,IAA0B,CAAC;IAEpD,IACE,CAAC,IAAI;QACL,CAAC,EAAE;QACH,CAAC,gBAAgB,CAAC;YAChB,IAAI;SACL,CAAC,EACF,CAA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CAAC;AAEF,SAAS,gBAAgB,CACvB,WAAoC;IAEpC,OAAO,CACL,OAAO,WAAW,CAAC,IAAI,KAAK,QAAQ;QACpC,WAAW,CAAC,IAAI,IAAI,wBAAwB,CAC7C,CAAC;AACJ,CAAC;AAED,SAAS,qBAAqB,CAC5B,WAAoC;IAEpC,OAAO,wBAAwB,CAAC,QAAQ,CACtC,WAAW,CAAC,IAAkC,CAC/C,CAAC;AACJ,CAAC"}
@@ -1,2 +1,2 @@
1
- export declare const superblocksApiPrompt = "\n#### Example of creating and then registering a Superblocks API:\n\nCreating the API by adding the myApi.ts file:\n\n```ts\n// Path to this api: /pages/Page1/apis/myApi.ts\n\nimport {\n Conditional,\n Condition,\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\"myApi\", [\n new Conditional(\"my_conditional\", {\n if: Condition(true, [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: \"SELECT * FROM orders\",\n }),\n ]),\n else: [\n new JavaScript(\"fallthrough\", () => \"we did not execute the sql query\"),\n ],\n }),\n]);\n```\n\nThen registering the myApi API inside the registerPage call, and executing it when an SbButton is clicked:\n\n```tsx\n// /pages/Page1/index.tsx\n\nimport { SbPage, SbApi, SbTable } from \"@superblocksteam/library\";\nimport { registerPage, showAlert } from \"@superblocksteam/library\";\n\nimport MyExampleAPI from \"./apis/example\";\n\nconst Page1 = () => (\n <SbPage>\n <SbButton\n // APIs can be invoked with the SBEventFlow API.\n onClick={SbEventFlow.runApis([\"myApi\"])}\n />\n <SbTable\n // APIs are part of the state object just like components\n tableData={(state) => state.myApi.response}\n />\n </SbPage>\n);\n\nexport default registerPage(\n Page1,\n {\n name: \"MyPage\",\n // You register APIs just like you would SbVariables\n myApi: SbApi(MyExampleAPI),\n },\n);\n```\n\n#### The Superblocks API TypeScript Type\n\nBelow is the full TypeScript spec for the APIs you create:\n\n```ts\n// @superblocksteam/types\n\nexport type JsonValue = undefined | null | number | string | boolean | JsonValue[] | object;\n\nclass Block {\n constructor(name: string) {}\n public run(): { output: JsonValue } { /* ... */ }\n}\n\ntype State = Record<string, JsonValue>\n\nclass JavaScript extends Block {\n constructor(name: string, config: { fn: ({ /* ... */ }) => JsonValue }) { /* ... */ }\n}\n\ntype Integration = string\ntype Integrations = Record<Integration, JsonValue>;\n\nclass PostgreSQL extends Block {\n static integrations: Integrations = {\n \"eacaad74-192a-4a55-bbfd-3bdd3a6dfd53\": {\n \"schema\": {\n \"tables\": [\n {\n \"type\": \"TABLE\",\n \"name\": \"orders\",\n \"columns\": [\n {\n \"name\": \"id\",\n \"type\": \"int4\",\n },\n {\n \"name\": \"user_id\",\n \"type\": \"int8\",\n },\n {\n \"name\": \"product\",\n \"type\": \"varchar\",\n },\n {\n \"name\": \"date_purchased\",\n \"type\": \"date\",\n },\n {\n \"name\": \"user_email\",\n \"type\": \"varchar\",\n },\n {\n \"name\": \"price\",\n \"type\": \"float8\",\n },\n ],\n \"schema\": \"public\",\n }\n ],\n }\n }\n }\n\n /**\n * @param {string} name The name of the block.\n * @param {string} integration The name of the integration.\n * @param {object} config The config object.\n * @returns {void}\n */\n constructor(name: string, integration: Integration, config: {\n statement: string\n }) { super(name) }\n}\n\nclass RestApi extends Block {\n constructor(\n name: string,\n config: {\n method: \"GET\" | \"POST\" | \"PUT\" | \"DELETE\" | \"PATCH\" | \"OPTIONS\" | \"HEAD\" | \"TRACE\" | \"CONNECT\";\n url: string | (({ /* ... */ }) => string);\n },\n ) { super(name) }\n}\n\nclass Email extends Block {\n constructor(name: string, config: {\n from: string\n to: string\n subject: string\n cc?: string[]\n bcc?: string[]\n body?: string | JsonValue | (({ /* ... */ }) => string | JsonValue)\n }) { super(name) }\n}\n\nexport type Condition = {\n when: boolean | ((state: State) => boolean);\n then: Block[];\n};\n\nexport type Conditions = {\n if: Condition;\n elif?: Condition[];\n else?: Block[];\n};\n\nclass Conditional extends Block {\n constructor(name: string, config: Conditions) { super(name) }\n}\n\nclass TryCatch extends Block {\n constructor(name: string, config: { try: Block[]; catch: Block[]; finally?: Block[] }) { super(name) }\n}\n\n/**\n * A Superblocks variable has the following access pattern:\n *\n * How to retrieve the value of a variable:\n * ```ts\n * CORRECT\n * my_variable.value\n *\n * // INCORRECT\n * my_variable\n * ```\n *\n * How to set the value of a variable:\n * ```ts\n * CORRECT\n * my_variable.set(value)\n *\n * // INCORRECT\n * my_variable = value\n * ```\n */\nclass Variables extends Block {\n constructor(name: string, variables: {\n // The key is the name of the variable.\n // The value is the value of the variable.\n [key: string]: JsonValue | (({ /* ... */ }) => JsonValue)\n }) { super(name) }\n}\n\nclass Loop extends Block {\n constructor(\n name: string,\n // You can either loop over a certain number or times, over an array, or forever until the condition is false.\n over: number | (({ /* ... */ }) => number) | JsonValue[] | (({ /* ... */ }) => JsonValue[]) | boolean | (({ /* ... */ }) => boolean),\n variables: {\n // What the variable name for the current item is.\n item: string,\n // What the variable name for the current index is.\n index: number,\n },\n blocks: Block[]\n ) { super(name) }\n}\n\nclass Parallel extends Block {\n constructor(\n name: string,\n over: JsonValue[] | (({ /* ... */ }) => JsonValue[]),\n variables: {\n // What the variable name for the current item is.\n item: string,\n },\n blocks: Block[],\n ) { super(name) }\n}\n\nclass Api {\n constructor(name: string, steps: Block[]) {}\n public get response(): JsonValue { /* ... */ }\n public get error(): string | undefined { /* ... */ }\n public run(): void { /* ... */ }\n public cancel(): void { /* ... */ }\n}\n```\n\n#### Example Usage\n\nBelow are examples of how you create Superblocks APIs, along with annotations to describe different pieces of functinality and expectations.\n\n##### Example 1: Simple API with conditional\n\n```ts\n// Path to this api would be: /pages/Page1/apis/getOrders.ts\n\nimport {\n Conditional,\n Condition,\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\n \"getOrders\",\n [\n new Conditional(\"my_conditional\", {\n if: {\n when: true,\n then: [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: 'SELECT * FROM orders'\n })\n ]\n },\n else: [\n new JavaScript(\"fallthrough\", { fn: () => \"we did not execute the sql query\" })\n ]\n })\n ]\n)\n```\n\nTo run register and run the API we defined above:\n\n```tsx\n// /pages/Page1/index.tsx\n\nimport { SbPage, SbApi, SbTable, SbButton } from \"@superblocksteam/library\";\nimport { registerPage, showAlert } from \"@superblocksteam/library\";\n\nimport getOrders from \"./apis/getOrders\";\n\nconst Page1 = () => (\n <SbPage>\n <SbButton\n // APIs can be invoked with the SBEventFlow API.\n onClick={SbEventFlow.runApis([\"getOrders\"])}\n />\n // ...\n <SbTable>\n // APIs are part of the state object just like components. tableData=\n {(state) => state.getOrders.response}\n </SbTable>\n </SbPage>\n);\n\nexport default registerPage(\n Page1,\n {\n name: \"MyPage\",\n // You register APIs just like you would SbVariables.\n getOrders: SbApi(getOrders),\n },\n);\n```\n\n##### Example 2: API where steps reference outputs of previous steps\n\nThink hard about how you access the output of previous steps. You MUST use the output property of the previous step variable. There is no other way to access the output of a previous step (other than using a Variable block, but that is not what you want in this case and should only be used in very specific cases).\n\n```ts\n// Path to this api would be: /pages/Page1/apis/getOrders.ts\n\nimport {\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\n \"getOrders\",\n [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: 'SELECT * FROM orders'\n }),\n new JavaScript(\"format_orders\", ({ retrieve_orders }) => {\n // Format the orders data with dates\n // we access the output of the retrieve_orders block using the output property of the retrieve_orders variable\n return retrieve_orders.output.map(order => ({\n ...order,\n date: new Date(order.date).toLocaleDateString()\n }));\n })\n ]\n)\n```\n\nThen you would register the api as normal in the page file inside the registerPage function call, same as the first example.\n\n#### Control Flow blocks\n\nThe API blocks that are considered \"Control Flow\" blocks are:\n\n- Conditional\n- Loop\n- TryCatch\n- Parallel\n\n#### Rules for using Superblocks APIs\n\nThink hard about the following important rules for correctly using Superblocks APIs:\n\n- You must use a deconstructed state object as the function parameter for dynamic block fields. The valid keys are (1) Superblocks entities (components, variables, etc) and (2) previous block outputs that are in the lexial scope. Example below:\n\n```ts\n// CORRECT: uses deconstructed state\n({ Dropdown1, TextInput1 }) => Dropdown1.selectedOptionsValue + TextInput1.value\n\n// INCORRECT: uses state object directly\n(state) => state.Dropdown1.selectedOptionsValue + state.TextInput1.value\n```\n\n- APIs have lexical scope. For example, blocks in the if-statement of a conditional block will not have access to the state of the else-block.\n\n- Block outputs are immutable. Do not mutate the output of a block.\n\n- The output for a control flow block is the output of the last child block inside of that control flow block.\n\n- Favor the defined control flow blocks (conditional, loop, try-catch) over using the JavaScript block to try and control the flow of your API. This allows you to use Superblocks integrations more easily and allows the user to more easily maintain the API.\n\n- Backend APIs CANNOT mutate frontend state inside of the API.\n\n- You will not always be told which integrations to use in your API; you will have to determine that yourself based on the data you need to fetch.\n\n- Never add comments to code you generate.\n";
1
+ export declare const superblocksApiPrompt = "\n#### Example of creating and then registering a Superblocks API:\n\nCreating the API by adding the myApi.ts file:\n\n```ts\n// Path to this api: /pages/Page1/apis/myApi.ts\n\nimport {\n Conditional,\n Condition,\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\"myApi\", [\n new Conditional(\"my_conditional\", {\n if: Condition(true, [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: \"SELECT * FROM orders\",\n }),\n ]),\n else: [\n new JavaScript(\"fallthrough\", () => \"we did not execute the sql query\"),\n ],\n }),\n]);\n```\n\nThen registering the myApi API inside the registerPage call, and executing it when an Button is clicked:\n\n```tsx\n// /pages/Page1/index.tsx\n\nimport { Page, SbApi, Table } from \"@superblocksteam/library\";\nimport { registerPage, showAlert } from \"@superblocksteam/library\";\n\nimport MyExampleAPI from \"./apis/example\";\n\nconst Page1 = () => (\n <Page>\n <Button\n // APIs can be invoked with the EventFlow API.\n onClick={EventFlow.runApis([\"myApi\"])}\n />\n <Table\n // APIs are part of the state object just like components\n tableData={(state) => state.myApi.response}\n />\n </Page>\n);\n\nexport default registerPage(\n Page1,\n {\n name: \"MyPage\",\n // You register APIs just like you would SbVariables\n myApi: SbApi(MyExampleAPI),\n },\n);\n```\n\n#### The Superblocks API TypeScript Type\n\nBelow is the full TypeScript spec for the APIs you create:\n\n```ts\n// @superblocksteam/types\n\nexport type JsonValue = undefined | null | number | string | boolean | JsonValue[] | object;\n\nclass Block {\n constructor(name: string) {}\n public run(): { output: JsonValue } { /* ... */ }\n}\n\ntype State = Record<string, JsonValue>\n\nclass JavaScript extends Block {\n constructor(name: string, config: { fn: ({ /* ... */ }) => JsonValue }) { /* ... */ }\n}\n\ntype Integration = string\ntype Integrations = Record<Integration, JsonValue>;\n\nclass PostgreSQL extends Block {\n static integrations: Integrations = {\n \"eacaad74-192a-4a55-bbfd-3bdd3a6dfd53\": {\n \"schema\": {\n \"tables\": [\n {\n \"type\": \"TABLE\",\n \"name\": \"orders\",\n \"columns\": [\n {\n \"name\": \"id\",\n \"type\": \"int4\",\n },\n {\n \"name\": \"user_id\",\n \"type\": \"int8\",\n },\n {\n \"name\": \"product\",\n \"type\": \"varchar\",\n },\n {\n \"name\": \"date_purchased\",\n \"type\": \"date\",\n },\n {\n \"name\": \"user_email\",\n \"type\": \"varchar\",\n },\n {\n \"name\": \"price\",\n \"type\": \"float8\",\n },\n ],\n \"schema\": \"public\",\n }\n ],\n }\n }\n }\n\n /**\n * @param {string} name The name of the block.\n * @param {string} integration The name of the integration.\n * @param {object} config The config object.\n * @returns {void}\n */\n constructor(name: string, integration: Integration, config: {\n statement: string\n }) { super(name) }\n}\n\nclass RestApi extends Block {\n constructor(\n name: string,\n config: {\n method: \"GET\" | \"POST\" | \"PUT\" | \"DELETE\" | \"PATCH\" | \"OPTIONS\" | \"HEAD\" | \"TRACE\" | \"CONNECT\";\n url: string | (({ /* ... */ }) => string);\n },\n ) { super(name) }\n}\n\nclass Email extends Block {\n constructor(name: string, config: {\n from: string\n to: string\n subject: string\n cc?: string[]\n bcc?: string[]\n body?: string | JsonValue | (({ /* ... */ }) => string | JsonValue)\n }) { super(name) }\n}\n\nexport type Condition = {\n when: boolean | ((state: State) => boolean);\n then: Block[];\n};\n\nexport type Conditions = {\n if: Condition;\n elif?: Condition[];\n else?: Block[];\n};\n\nclass Conditional extends Block {\n constructor(name: string, config: Conditions) { super(name) }\n}\n\nclass TryCatch extends Block {\n constructor(name: string, config: { try: Block[]; catch: Block[]; finally?: Block[] }) { super(name) }\n}\n\n/**\n * A Superblocks variable has the following access pattern:\n *\n * How to retrieve the value of a variable:\n * ```ts\n * CORRECT\n * my_variable.value\n *\n * // INCORRECT\n * my_variable\n * ```\n *\n * How to set the value of a variable:\n * ```ts\n * CORRECT\n * my_variable.set(value)\n *\n * // INCORRECT\n * my_variable = value\n * ```\n */\nclass Variables extends Block {\n constructor(name: string, variables: {\n // The key is the name of the variable.\n // The value is the value of the variable.\n [key: string]: JsonValue | (({ /* ... */ }) => JsonValue)\n }) { super(name) }\n}\n\nclass Loop extends Block {\n constructor(\n name: string,\n // You can either loop over a certain number or times, over an array, or forever until the condition is false.\n over: number | (({ /* ... */ }) => number) | JsonValue[] | (({ /* ... */ }) => JsonValue[]) | boolean | (({ /* ... */ }) => boolean),\n variables: {\n // What the variable name for the current item is.\n item: string,\n // What the variable name for the current index is.\n index: number,\n },\n blocks: Block[]\n ) { super(name) }\n}\n\nclass Parallel extends Block {\n constructor(\n name: string,\n over: JsonValue[] | (({ /* ... */ }) => JsonValue[]),\n variables: {\n // What the variable name for the current item is.\n item: string,\n },\n blocks: Block[],\n ) { super(name) }\n}\n\nclass Api {\n constructor(name: string, steps: Block[]) {}\n public get response(): JsonValue { /* ... */ }\n public get error(): string | undefined { /* ... */ }\n public run(): void { /* ... */ }\n public cancel(): void { /* ... */ }\n}\n```\n\n#### Example Usage\n\nBelow are examples of how you create Superblocks APIs, along with annotations to describe different pieces of functinality and expectations.\n\n##### Example 1: Simple API with conditional\n\n```ts\n// Path to this api would be: /pages/Page1/apis/getOrders.ts\n\nimport {\n Conditional,\n Condition,\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\n \"getOrders\",\n [\n new Conditional(\"my_conditional\", {\n if: {\n when: true,\n then: [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: 'SELECT * FROM orders'\n })\n ]\n },\n else: [\n new JavaScript(\"fallthrough\", { fn: () => \"we did not execute the sql query\" })\n ]\n })\n ]\n)\n```\n\nTo run register and run the API we defined above:\n\n```tsx\n// /pages/Page1/index.tsx\n\nimport { Page, SbApi, Table, Button } from \"@superblocksteam/library\";\nimport { registerPage, showAlert } from \"@superblocksteam/library\";\n\nimport getOrders from \"./apis/getOrders\";\n\nconst Page1 = () => (\n <Page>\n <Button\n // APIs can be invoked with the EventFlow API.\n onClick={EventFlow.runApis([\"getOrders\"])}\n />\n // ...\n <Table>\n // APIs are part of the state object just like components. tableData=\n {(state) => state.getOrders.response}\n </Table>\n </Page>\n);\n\nexport default registerPage(\n Page1,\n {\n name: \"MyPage\",\n // You register APIs just like you would SbVariables.\n getOrders: SbApi(getOrders),\n },\n);\n```\n\n##### Example 2: API where steps reference outputs of previous steps\n\nThink hard about how you access the output of previous steps. You MUST use the output property of the previous step variable. There is no other way to access the output of a previous step (other than using a Variable block, but that is not what you want in this case and should only be used in very specific cases).\n\n```ts\n// Path to this api would be: /pages/Page1/apis/getOrders.ts\n\nimport {\n PostgreSQL,\n JavaScript,\n Api,\n} from \"@superblocksteam/library\";\n\nexport default new Api(\n \"getOrders\",\n [\n new PostgreSQL(\"retrieve_orders\", \"integration_goes_here\", {\n statement: 'SELECT * FROM orders'\n }),\n new JavaScript(\"format_orders\", ({ retrieve_orders }) => {\n // Format the orders data with dates\n // we access the output of the retrieve_orders block using the output property of the retrieve_orders variable\n return retrieve_orders.output.map(order => ({\n ...order,\n date: new Date(order.date).toLocaleDateString()\n }));\n })\n ]\n)\n```\n\nThen you would register the api as normal in the page file inside the registerPage function call, same as the first example.\n\n#### Control Flow blocks\n\nThe API blocks that are considered \"Control Flow\" blocks are:\n\n- Conditional\n- Loop\n- TryCatch\n- Parallel\n\n#### Rules for using Superblocks APIs\n\nThink hard about the following important rules for correctly using Superblocks APIs:\n\n- You must use a deconstructed state object as the function parameter for dynamic block fields. The valid keys are (1) Superblocks entities (components, variables, etc) and (2) previous block outputs that are in the lexial scope. Example below:\n\n```ts\n// CORRECT: uses deconstructed state\n({ Dropdown1, TextInput1 }) => Dropdown1.selectedOptionsValue + TextInput1.value\n\n// INCORRECT: uses state object directly\n(state) => state.Dropdown1.selectedOptionsValue + state.TextInput1.value\n```\n\n- APIs have lexical scope. For example, blocks in the if-statement of a conditional block will not have access to the state of the else-block.\n\n- Block outputs are immutable. Do not mutate the output of a block.\n\n- The output for a control flow block is the output of the last child block inside of that control flow block.\n\n- Favor the defined control flow blocks (conditional, loop, try-catch) over using the JavaScript block to try and control the flow of your API. This allows you to use Superblocks integrations more easily and allows the user to more easily maintain the API.\n\n- Backend APIs CANNOT mutate frontend state inside of the API.\n\n- You will not always be told which integrations to use in your API; you will have to determine that yourself based on the data you need to fetch.\n\n- Never add comments to code you generate.\n";
2
2
  //# sourceMappingURL=superblocks-api-draft.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"superblocks-api-draft.d.ts","sourceRoot":"","sources":["../../../../src/ai-service/prompts/draft-subprompts/superblocks-api-draft.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,oBAAoB,0vWA+XhC,CAAC"}
1
+ {"version":3,"file":"superblocks-api-draft.d.ts","sourceRoot":"","sources":["../../../../src/ai-service/prompts/draft-subprompts/superblocks-api-draft.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,oBAAoB,otWA+XhC,CAAC"}
@@ -29,27 +29,27 @@ export default new Api("myApi", [
29
29
  ]);
30
30
  \`\`\`
31
31
 
32
- Then registering the myApi API inside the registerPage call, and executing it when an SbButton is clicked:
32
+ Then registering the myApi API inside the registerPage call, and executing it when an Button is clicked:
33
33
 
34
34
  \`\`\`tsx
35
35
  // /pages/Page1/index.tsx
36
36
 
37
- import { SbPage, SbApi, SbTable } from "@superblocksteam/library";
37
+ import { Page, SbApi, Table } from "@superblocksteam/library";
38
38
  import { registerPage, showAlert } from "@superblocksteam/library";
39
39
 
40
40
  import MyExampleAPI from "./apis/example";
41
41
 
42
42
  const Page1 = () => (
43
- <SbPage>
44
- <SbButton
45
- // APIs can be invoked with the SBEventFlow API.
46
- onClick={SbEventFlow.runApis(["myApi"])}
43
+ <Page>
44
+ <Button
45
+ // APIs can be invoked with the EventFlow API.
46
+ onClick={EventFlow.runApis(["myApi"])}
47
47
  />
48
- <SbTable
48
+ <Table
49
49
  // APIs are part of the state object just like components
50
50
  tableData={(state) => state.myApi.response}
51
51
  />
52
- </SbPage>
52
+ </Page>
53
53
  );
54
54
 
55
55
  export default registerPage(
@@ -284,23 +284,23 @@ To run register and run the API we defined above:
284
284
  \`\`\`tsx
285
285
  // /pages/Page1/index.tsx
286
286
 
287
- import { SbPage, SbApi, SbTable, SbButton } from "@superblocksteam/library";
287
+ import { Page, SbApi, Table, Button } from "@superblocksteam/library";
288
288
  import { registerPage, showAlert } from "@superblocksteam/library";
289
289
 
290
290
  import getOrders from "./apis/getOrders";
291
291
 
292
292
  const Page1 = () => (
293
- <SbPage>
294
- <SbButton
295
- // APIs can be invoked with the SBEventFlow API.
296
- onClick={SbEventFlow.runApis(["getOrders"])}
293
+ <Page>
294
+ <Button
295
+ // APIs can be invoked with the EventFlow API.
296
+ onClick={EventFlow.runApis(["getOrders"])}
297
297
  />
298
298
  // ...
299
- <SbTable>
299
+ <Table>
300
300
  // APIs are part of the state object just like components. tableData=
301
301
  {(state) => state.getOrders.response}
302
- </SbTable>
303
- </SbPage>
302
+ </Table>
303
+ </Page>
304
304
  );
305
305
 
306
306
  export default registerPage(
@@ -1,2 +1,2 @@
1
- export declare const superblocksLayoutsPrompt = "\n### Layout and Sizing in Superblocks\n\nAll layouts in Superblocks are configured through the `SbContainer` component. \n`SbContainer` provides both layout and optional visual styling.\n\n```jsx\n<SbContainer\n variant=\"card\" | \"none\" // default is \"none\"\n layout=\"vertical\" | \"horizontal\" | \"freeform\" // default is \"vertical\"\n>\n {/* Children here */}\n</SbContainer>\n```\n\nWe have three main layout options in Superblocks:\n\n- Vertical Stack (`vertical`)\n- Horizontal Stack (`horizontal`)\n- Free form (`freeform`)\n\nFor new designs, we recommend using Stacks for most use cases.\n\nThe `variant` prop is optional and can be set to `\"card\"` or `\"none\"`. Default is `\"none\"`.\n`\"card\"` applies a card-like visual style to the container, such as rounded corners, white background, and padding.\n\n---\n\n### Height and Width Options\n\nAll Superblocks components support width and height. They take in a `Dim` object, which has 3 main options:\n\n- `Dim.fit()`: Fit to content size, this is the default behavior and can be omitted.\n- `Dim.px(100)`: Fixed pixel size.\n- `Dim.fill()` or `Dim.fill(2)`: Fill available space with an optional weight.\n\n> IMPORTANT: Prefer using `Dim.fit()` over `Dim.px()` for height and width unless you have a specific reason to use fixed pixel sizes. This is extra true for containers\n> IMPORTANT: Prefer using `Dim.fill()` or `Dim.fit()` over `Dim.px()` for width unless you have a specific reason to use fixed pixel sizes.\n\n**Examples**:\n\n```jsx\n<SbText name=\"Text1\" width={Dim.px(2)}>Hello</SbText> // 2 pixels\n<SbText name=\"Text1\" width={Dim.fit()}>Hello</SbText> // Fit to content (default)\n<SbText name=\"Text1\" width={Dim.fill()}>Hello</SbText> // Fill available space, no weight (aka 1)\n<SbText name=\"Text1\" width={Dim.fill(2)}>Hello</SbText> // Fill available space, with weight of 2\n```\n\n---\n\n### 2. **Grid-Specific Width (Columns)**\n\nWhen using `layout=\"freeform\"`, width is based on columns.\n\n- `Dim.columns(10)` specifies the number of columns.\n- Note: `fill`, `fit`, and `px` are not supported for width in grid layouts.\n\n**Example**:\n\n```jsx\n<SbContainer layout=\"freeform\" columns={12}>\n <SbText name=\"Text1\" width={Dim.columns(2)}>\n Hello\n </SbText>\n</SbContainer>\n```\n\n---\n\n### 3. **Height Options with Rows**\n\nWhen using `layout=\"freeform\"`, height can be configured with rows.\n\n- `Dim.rows(2)` specifies the number of rows.\n- `Dim.px(100)` specifies a fixed pixel size.\n- `Dim.fit()` fits to content size (default).\n- `Dim.fill()` is **not supported** for height inside grid layouts.\n\nYou can specify height using rows to override the default `\"fit\"` behavior, similar to pixel-based height.\n\n**Example**:\n\n```jsx\n<SbContainer layout=\"freeform\" columns={12}>\n <SbText name=\"Text1\" height={Dim.rows(2)} width={Dim.columns(2)}>\n Hello\n </SbText>{' '}\n // 2 rows in height, 2 columns in width\n</SbContainer>\n```\n\n---\n\n### 4. **Grid Layout Setup**\n\nA container with `layout=\"freeform\"` can be configured with columns and rows. \nIndividual children inside the container can have margins, constraints, and dynamic sizing options.\n\n```\nSbContainer (layout=\"freeform\") -\n columns: number\n rows: \"auto\" | number // defaults to auto\n row-size: Dim<px> // defaults to 12px\nGridChild (components inside the container) -\n margin-top: Dim<row | px>\n margin-left: Dim<column>\n height: Dim<row | px | fit>\n width: Dim<column>\n constraintTop: GridChild | [GridChild]\n```\n\n---\n\n#### **Grid Example 1: Items Stacked with a Gap**\n\nTwo items stacked vertically, both full width, with a gap of 1.\n\n```\n[ Text1 ]\n[ Text2 ]\n```\n\n```jsx\n<SbContainer layout=\"freeform\" columns={3}>\n <SbText name=\"Text1\" width={Dim.columns(3)}>\n Hello\n </SbText>\n <SbText name=\"Text2\" constraintTop=\"Text1\" width={Dim.columns(3)}>\n World\n </SbText>\n</SbContainer>\n```\n\n---\n\n#### **Grid Example 2: Items Side by Side**\n\nThree items side by side, each taking part of the grid.\n\n```\n[ Text1 ][ Text2 ][ Text3 ]\n```\n\n```jsx\n<SbContainer layout=\"freeform\" columns={4}>\n <SbText name=\"Text1\" width={Dim.columns(2)}>\n Hello\n </SbText>\n <SbText name=\"Text2\" width={Dim.columns(2)} marginLeft={Dim.columns(2)}>\n World\n </SbText>\n <SbText name=\"Text3\" width={Dim.columns(2)} marginLeft={Dim.columns(4)}>\n World\n </SbText>\n</SbContainer>\n```\n\n---\n\n#### **Grid Example 3: Staggered Items**\n\nA staggered layout using constraints and margins.\n\n```\n[ Text1 ]\n[ Text2 ][ Text3 ]\n```\n\n```jsx\n<SbContainer layout=\"freeform\" columns={2}>\n <SbText name=\"Text1\" width={Dim.columns(1)}>\n Hello\n </SbText>\n <SbText name=\"Text2\" width={Dim.columns(1)} constraintTop=\"Text1\">\n World\n </SbText>\n <SbText name=\"Text3\" width={Dim.columns(1)} marginLeft={Dim.columns(1)} marginTop={Dim.rows(1)}>\n World Again\n </SbText>\n</SbContainer>\n```\n\nIn this example:\n\n- `Text2` is constrained to `Text1`.\n- `Text3` is **not constrained** to `Text2`, but uses a margin of 1 row and 1 column.\n- If `Text1` grows in size, `Text2` moves down, but `Text3` stays in place.\n\n#### **Grid Example 4: Key Value Pairs**\n\n[ Key 1 ][ Value 1 ]\n[ Key 2 ][ Value 2 ]\n\n```jsx\n<SbContainer layout=\"freeform\" columns={12}>\n <SbText name=\"Key1\" width={Dim.columns(4)}>\n Key 1\n </SbText>\n <SbText name=\"Value1\" width={Dim.columns(8)} marginLeft={Dim.columns(4)}>\n Value 1\n </SbText>\n <SbText name=\"Key2\" width={Dim.columns(4)} constraintTop=\"Key1\">\n Key 2\n </SbText>\n <SbText name=\"Value2\" width={Dim.columns(8)} marginLeft={Dim.columns(4)} constraintTop=\"Value1\">\n Value 2\n </SbText>\n</SbContainer>\n\nIMPORTANT: The `constraintTop` prop is used to specify the component that this component should be constrained to. You must use and supply names to all components that you want to reference in the `constraintTop` prop.\n```\n\n### Import Location\n\n```ts\nimport { Dim } from '@superblocksteam/library';\n```\n";
1
+ export declare const superblocksLayoutsPrompt = "\n### Layout and Sizing in Superblocks\n\nAll layouts in Superblocks are configured through the `Container` component. \n`Container` provides both layout and optional visual styling.\n\n```jsx\n<Container\n variant=\"card\" | \"none\" // default is \"none\"\n layout=\"vertical\" | \"horizontal\" | \"freeform\" // default is \"vertical\"\n>\n {/* Children here */}\n</Container>\n```\n\nWe have three main layout options in Superblocks:\n\n- Vertical Stack (`vertical`)\n- Horizontal Stack (`horizontal`)\n- Free form (`freeform`)\n\nFor new designs, we recommend using Stacks for most use cases.\n\nThe `variant` prop is optional and can be set to `\"card\"` or `\"none\"`. Default is `\"none\"`.\n`\"card\"` applies a card-like visual style to the container, such as rounded corners, white background, and padding.\n\n---\n\n### Height and Width Options\n\nAll Superblocks components support width and height. They take in a `Dim` object, which has 3 main options:\n\n- `Dim.fit()`: Fit to content size, this is the default behavior and can be omitted.\n- `Dim.px(100)`: Fixed pixel size.\n- `Dim.fill()` or `Dim.fill(2)`: Fill available space with an optional weight.\n\n> IMPORTANT: Prefer using `Dim.fit()` over `Dim.px()` for height and width unless you have a specific reason to use fixed pixel sizes. This is extra true for containers\n> IMPORTANT: Prefer using `Dim.fill()` or `Dim.fit()` over `Dim.px()` for width unless you have a specific reason to use fixed pixel sizes.\n\n**Examples**:\n\n```jsx\n<Text name=\"Text1\" width={Dim.px(2)}>Hello</Text> // 2 pixels\n<Text name=\"Text1\" width={Dim.fit()}>Hello</Text> // Fit to content (default)\n<Text name=\"Text1\" width={Dim.fill()}>Hello</Text> // Fill available space, no weight (aka 1)\n<Text name=\"Text1\" width={Dim.fill(2)}>Hello</Text> // Fill available space, with weight of 2\n```\n\n---\n\n### 2. **Grid-Specific Width (Columns)**\n\nWhen using `layout=\"freeform\"`, width is based on columns.\n\n- `Dim.columns(10)` specifies the number of columns.\n- Note: `fill`, `fit`, and `px` are not supported for width in grid layouts.\n\n**Example**:\n\n```jsx\n<Container layout=\"freeform\" columns={12}>\n <Text name=\"Text1\" width={Dim.columns(2)}>\n Hello\n </Text>\n</Container>\n```\n\n---\n\n### 3. **Height Options with Rows**\n\nWhen using `layout=\"freeform\"`, height can be configured with rows.\n\n- `Dim.rows(2)` specifies the number of rows.\n- `Dim.px(100)` specifies a fixed pixel size.\n- `Dim.fit()` fits to content size (default).\n- `Dim.fill()` is **not supported** for height inside grid layouts.\n\nYou can specify height using rows to override the default `\"fit\"` behavior, similar to pixel-based height.\n\n**Example**:\n\n```jsx\n<Container layout=\"freeform\" columns={12}>\n <Text name=\"Text1\" height={Dim.rows(2)} width={Dim.columns(2)}>\n Hello\n </Text>{' '}\n // 2 rows in height, 2 columns in width\n</Container>\n```\n\n---\n\n### 4. **Grid Layout Setup**\n\nA container with `layout=\"freeform\"` can be configured with columns and rows. \nIndividual children inside the container can have margins, constraints, and dynamic sizing options.\n\n```\nContainer (layout=\"freeform\") -\n columns: number\n rows: \"auto\" | number // defaults to auto\n row-size: Dim<px> // defaults to 12px\nGridChild (components inside the container) -\n margin-top: Dim<row | px>\n margin-left: Dim<column>\n height: Dim<row | px | fit>\n width: Dim<column>\n constraintTop: GridChild | [GridChild]\n```\n\n---\n\n#### **Grid Example 1: Items Stacked with a Gap**\n\nTwo items stacked vertically, both full width, with a gap of 1.\n\n```\n[ Text1 ]\n[ Text2 ]\n```\n\n```jsx\n<Container layout=\"freeform\" columns={3}>\n <Text name=\"Text1\" width={Dim.columns(3)}>\n Hello\n </Text>\n <Text name=\"Text2\" constraintTop=\"Text1\" width={Dim.columns(3)}>\n World\n </Text>\n</Container>\n```\n\n---\n\n#### **Grid Example 2: Items Side by Side**\n\nThree items side by side, each taking part of the grid.\n\n```\n[ Text1 ][ Text2 ][ Text3 ]\n```\n\n```jsx\n<Container layout=\"freeform\" columns={4}>\n <Text name=\"Text1\" width={Dim.columns(2)}>\n Hello\n </Text>\n <Text name=\"Text2\" width={Dim.columns(2)} marginLeft={Dim.columns(2)}>\n World\n </Text>\n <Text name=\"Text3\" width={Dim.columns(2)} marginLeft={Dim.columns(4)}>\n World\n </Text>\n</Container>\n```\n\n---\n\n#### **Grid Example 3: Staggered Items**\n\nA staggered layout using constraints and margins.\n\n```\n[ Text1 ]\n[ Text2 ][ Text3 ]\n```\n\n```jsx\n<Container layout=\"freeform\" columns={2}>\n <Text name=\"Text1\" width={Dim.columns(1)}>\n Hello\n </Text>\n <Text name=\"Text2\" width={Dim.columns(1)} constraintTop=\"Text1\">\n World\n </Text>\n <Text name=\"Text3\" width={Dim.columns(1)} marginLeft={Dim.columns(1)} marginTop={Dim.rows(1)}>\n World Again\n </Text>\n</Container>\n```\n\nIn this example:\n\n- `Text2` is constrained to `Text1`.\n- `Text3` is **not constrained** to `Text2`, but uses a margin of 1 row and 1 column.\n- If `Text1` grows in size, `Text2` moves down, but `Text3` stays in place.\n\n#### **Grid Example 4: Key Value Pairs**\n\n[ Key 1 ][ Value 1 ]\n[ Key 2 ][ Value 2 ]\n\n```jsx\n<Container layout=\"freeform\" columns={12}>\n <Text name=\"Key1\" width={Dim.columns(4)}>\n Key 1\n </Text>\n <Text name=\"Value1\" width={Dim.columns(8)} marginLeft={Dim.columns(4)}>\n Value 1\n </Text>\n <Text name=\"Key2\" width={Dim.columns(4)} constraintTop=\"Key1\">\n Key 2\n </Text>\n <Text name=\"Value2\" width={Dim.columns(8)} marginLeft={Dim.columns(4)} constraintTop=\"Value1\">\n Value 2\n </Text>\n</Container>\n\nIMPORTANT: The `constraintTop` prop is used to specify the component that this component should be constrained to. You must use and supply names to all components that you want to reference in the `constraintTop` prop.\n```\n\n### Import Location\n\n```ts\nimport { Dim } from '@superblocksteam/library';\n```\n";
2
2
  //# sourceMappingURL=superblocks-layouts-with-grid-examples.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"superblocks-layouts-with-grid-examples.d.ts","sourceRoot":"","sources":["../../../../src/ai-service/prompts/draft-subprompts/superblocks-layouts-with-grid-examples.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,wBAAwB,k/LAyNpC,CAAC"}
1
+ {"version":3,"file":"superblocks-layouts-with-grid-examples.d.ts","sourceRoot":"","sources":["../../../../src/ai-service/prompts/draft-subprompts/superblocks-layouts-with-grid-examples.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,wBAAwB,w4LAyNpC,CAAC"}
@@ -1,16 +1,16 @@
1
1
  export const superblocksLayoutsPrompt = /*md*/ `
2
2
  ### Layout and Sizing in Superblocks
3
3
 
4
- All layouts in Superblocks are configured through the \`SbContainer\` component.
5
- \`SbContainer\` provides both layout and optional visual styling.
4
+ All layouts in Superblocks are configured through the \`Container\` component.
5
+ \`Container\` provides both layout and optional visual styling.
6
6
 
7
7
  \`\`\`jsx
8
- <SbContainer
8
+ <Container
9
9
  variant="card" | "none" // default is "none"
10
10
  layout="vertical" | "horizontal" | "freeform" // default is "vertical"
11
11
  >
12
12
  {/* Children here */}
13
- </SbContainer>
13
+ </Container>
14
14
  \`\`\`
15
15
 
16
16
  We have three main layout options in Superblocks:
@@ -40,10 +40,10 @@ All Superblocks components support width and height. They take in a \`Dim\` obje
40
40
  **Examples**:
41
41
 
42
42
  \`\`\`jsx
43
- <SbText name="Text1" width={Dim.px(2)}>Hello</SbText> // 2 pixels
44
- <SbText name="Text1" width={Dim.fit()}>Hello</SbText> // Fit to content (default)
45
- <SbText name="Text1" width={Dim.fill()}>Hello</SbText> // Fill available space, no weight (aka 1)
46
- <SbText name="Text1" width={Dim.fill(2)}>Hello</SbText> // Fill available space, with weight of 2
43
+ <Text name="Text1" width={Dim.px(2)}>Hello</Text> // 2 pixels
44
+ <Text name="Text1" width={Dim.fit()}>Hello</Text> // Fit to content (default)
45
+ <Text name="Text1" width={Dim.fill()}>Hello</Text> // Fill available space, no weight (aka 1)
46
+ <Text name="Text1" width={Dim.fill(2)}>Hello</Text> // Fill available space, with weight of 2
47
47
  \`\`\`
48
48
 
49
49
  ---
@@ -58,11 +58,11 @@ When using \`layout="freeform"\`, width is based on columns.
58
58
  **Example**:
59
59
 
60
60
  \`\`\`jsx
61
- <SbContainer layout="freeform" columns={12}>
62
- <SbText name="Text1" width={Dim.columns(2)}>
61
+ <Container layout="freeform" columns={12}>
62
+ <Text name="Text1" width={Dim.columns(2)}>
63
63
  Hello
64
- </SbText>
65
- </SbContainer>
64
+ </Text>
65
+ </Container>
66
66
  \`\`\`
67
67
 
68
68
  ---
@@ -81,12 +81,12 @@ You can specify height using rows to override the default \`"fit"\` behavior, si
81
81
  **Example**:
82
82
 
83
83
  \`\`\`jsx
84
- <SbContainer layout="freeform" columns={12}>
85
- <SbText name="Text1" height={Dim.rows(2)} width={Dim.columns(2)}>
84
+ <Container layout="freeform" columns={12}>
85
+ <Text name="Text1" height={Dim.rows(2)} width={Dim.columns(2)}>
86
86
  Hello
87
- </SbText>{' '}
87
+ </Text>{' '}
88
88
  // 2 rows in height, 2 columns in width
89
- </SbContainer>
89
+ </Container>
90
90
  \`\`\`
91
91
 
92
92
  ---
@@ -97,7 +97,7 @@ A container with \`layout="freeform"\` can be configured with columns and rows.
97
97
  Individual children inside the container can have margins, constraints, and dynamic sizing options.
98
98
 
99
99
  \`\`\`
100
- SbContainer (layout="freeform") -
100
+ Container (layout="freeform") -
101
101
  columns: number
102
102
  rows: "auto" | number // defaults to auto
103
103
  row-size: Dim<px> // defaults to 12px
@@ -121,14 +121,14 @@ Two items stacked vertically, both full width, with a gap of 1.
121
121
  \`\`\`
122
122
 
123
123
  \`\`\`jsx
124
- <SbContainer layout="freeform" columns={3}>
125
- <SbText name="Text1" width={Dim.columns(3)}>
124
+ <Container layout="freeform" columns={3}>
125
+ <Text name="Text1" width={Dim.columns(3)}>
126
126
  Hello
127
- </SbText>
128
- <SbText name="Text2" constraintTop="Text1" width={Dim.columns(3)}>
127
+ </Text>
128
+ <Text name="Text2" constraintTop="Text1" width={Dim.columns(3)}>
129
129
  World
130
- </SbText>
131
- </SbContainer>
130
+ </Text>
131
+ </Container>
132
132
  \`\`\`
133
133
 
134
134
  ---
@@ -142,17 +142,17 @@ Three items side by side, each taking part of the grid.
142
142
  \`\`\`
143
143
 
144
144
  \`\`\`jsx
145
- <SbContainer layout="freeform" columns={4}>
146
- <SbText name="Text1" width={Dim.columns(2)}>
145
+ <Container layout="freeform" columns={4}>
146
+ <Text name="Text1" width={Dim.columns(2)}>
147
147
  Hello
148
- </SbText>
149
- <SbText name="Text2" width={Dim.columns(2)} marginLeft={Dim.columns(2)}>
148
+ </Text>
149
+ <Text name="Text2" width={Dim.columns(2)} marginLeft={Dim.columns(2)}>
150
150
  World
151
- </SbText>
152
- <SbText name="Text3" width={Dim.columns(2)} marginLeft={Dim.columns(4)}>
151
+ </Text>
152
+ <Text name="Text3" width={Dim.columns(2)} marginLeft={Dim.columns(4)}>
153
153
  World
154
- </SbText>
155
- </SbContainer>
154
+ </Text>
155
+ </Container>
156
156
  \`\`\`
157
157
 
158
158
  ---
@@ -167,17 +167,17 @@ A staggered layout using constraints and margins.
167
167
  \`\`\`
168
168
 
169
169
  \`\`\`jsx
170
- <SbContainer layout="freeform" columns={2}>
171
- <SbText name="Text1" width={Dim.columns(1)}>
170
+ <Container layout="freeform" columns={2}>
171
+ <Text name="Text1" width={Dim.columns(1)}>
172
172
  Hello
173
- </SbText>
174
- <SbText name="Text2" width={Dim.columns(1)} constraintTop="Text1">
173
+ </Text>
174
+ <Text name="Text2" width={Dim.columns(1)} constraintTop="Text1">
175
175
  World
176
- </SbText>
177
- <SbText name="Text3" width={Dim.columns(1)} marginLeft={Dim.columns(1)} marginTop={Dim.rows(1)}>
176
+ </Text>
177
+ <Text name="Text3" width={Dim.columns(1)} marginLeft={Dim.columns(1)} marginTop={Dim.rows(1)}>
178
178
  World Again
179
- </SbText>
180
- </SbContainer>
179
+ </Text>
180
+ </Container>
181
181
  \`\`\`
182
182
 
183
183
  In this example:
@@ -192,20 +192,20 @@ In this example:
192
192
  [ Key 2 ][ Value 2 ]
193
193
 
194
194
  \`\`\`jsx
195
- <SbContainer layout="freeform" columns={12}>
196
- <SbText name="Key1" width={Dim.columns(4)}>
195
+ <Container layout="freeform" columns={12}>
196
+ <Text name="Key1" width={Dim.columns(4)}>
197
197
  Key 1
198
- </SbText>
199
- <SbText name="Value1" width={Dim.columns(8)} marginLeft={Dim.columns(4)}>
198
+ </Text>
199
+ <Text name="Value1" width={Dim.columns(8)} marginLeft={Dim.columns(4)}>
200
200
  Value 1
201
- </SbText>
202
- <SbText name="Key2" width={Dim.columns(4)} constraintTop="Key1">
201
+ </Text>
202
+ <Text name="Key2" width={Dim.columns(4)} constraintTop="Key1">
203
203
  Key 2
204
- </SbText>
205
- <SbText name="Value2" width={Dim.columns(8)} marginLeft={Dim.columns(4)} constraintTop="Value1">
204
+ </Text>
205
+ <Text name="Value2" width={Dim.columns(8)} marginLeft={Dim.columns(4)} constraintTop="Value1">
206
206
  Value 2
207
- </SbText>
208
- </SbContainer>
207
+ </Text>
208
+ </Container>
209
209
 
210
210
  IMPORTANT: The \`constraintTop\` prop is used to specify the component that this component should be constrained to. You must use and supply names to all components that you want to reference in the \`constraintTop\` prop.
211
211
  \`\`\`
@@ -0,0 +1,2 @@
1
+ export declare const content = "## Button\n\nThe following is the type definition for the Button component.\n\n```typescript\ninterface ButtonProps {\n label?: string;\n /** @default {\"left\":{\"mode\":\"px\",\"value\":10},\"right\":{\"mode\":\"px\",\"value\":10},\"top\":{\"mode\":\"px\",\"value\":8},\"bottom\":{\"mode\":\"px\",\"value\":8}} */\n padding?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n width?: Dim;\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n minHeight?: Dim;\n maxHeight?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n margin?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default true */\n isVisible?: boolean;\n /** @default \"primary\" */\n variant?: \"primary\" | \"secondary\" | \"tertiary\";\n icon?: string;\n /** @default \"left\" */\n iconPosition?: \"left\" | \"right\";\n /** @default \"Computed at runtime\" */\n textStyle?: TextStyleWithVariant;\n /** @default \"Computed at runtime\" */\n backgroundColor?: string;\n /** @default {\"left\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"right\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"top\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"bottom\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"}} */\n border?: { left: Border; right: Border; top: Border; bottom: Border };\n /** @default \"Computed at runtime\" */\n borderRadius?: {\n topLeft: Dim;\n topRight: Dim;\n bottomLeft: Dim;\n bottomRight: Dim;\n };\n /** @default \"center\" */\n horizontalAlign?: \"left\" | \"center\" | \"right\";\n loading?: boolean;\n /** @default false */\n isDisabled?: boolean;\n onClick?: EventFlow;\n}\n```\n";
2
+ //# sourceMappingURL=ButtonPropsDocs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ButtonPropsDocs.d.ts","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/ButtonPropsDocs.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,q5DAAq5D,CAAC"}
@@ -0,0 +1,6 @@
1
+ /* eslint-disable */
2
+ // Auto-generated from ButtonPropsDocs.md
3
+ // Do not edit this file directly
4
+ // Generated at: 2025-07-03T15:08:51.451Z
5
+ export const content = "## Button\n\nThe following is the type definition for the Button component.\n\n```typescript\ninterface ButtonProps {\n label?: string;\n /** @default {\"left\":{\"mode\":\"px\",\"value\":10},\"right\":{\"mode\":\"px\",\"value\":10},\"top\":{\"mode\":\"px\",\"value\":8},\"bottom\":{\"mode\":\"px\",\"value\":8}} */\n padding?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n width?: Dim;\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n minHeight?: Dim;\n maxHeight?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n margin?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default true */\n isVisible?: boolean;\n /** @default \"primary\" */\n variant?: \"primary\" | \"secondary\" | \"tertiary\";\n icon?: string;\n /** @default \"left\" */\n iconPosition?: \"left\" | \"right\";\n /** @default \"Computed at runtime\" */\n textStyle?: TextStyleWithVariant;\n /** @default \"Computed at runtime\" */\n backgroundColor?: string;\n /** @default {\"left\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"right\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"top\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"},\"bottom\":{\"width\":{\"mode\":\"px\",\"value\":1},\"style\":\"solid\",\"color\":\"transparent\"}} */\n border?: { left: Border; right: Border; top: Border; bottom: Border };\n /** @default \"Computed at runtime\" */\n borderRadius?: {\n topLeft: Dim;\n topRight: Dim;\n bottomLeft: Dim;\n bottomRight: Dim;\n };\n /** @default \"center\" */\n horizontalAlign?: \"left\" | \"center\" | \"right\";\n loading?: boolean;\n /** @default false */\n isDisabled?: boolean;\n onClick?: EventFlow;\n}\n```\n";
6
+ //# sourceMappingURL=ButtonPropsDocs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ButtonPropsDocs.js","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/ButtonPropsDocs.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,yCAAyC;AACzC,iCAAiC;AACjC,yCAAyC;AAEzC,MAAM,CAAC,MAAM,OAAO,GAAG,k5DAAk5D,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const content = "## Checkbox\n\nThe following is the type definition for the Checkbox component.\n\n```typescript\ninterface CheckboxProps {\n /** @default \"\" */\n label?: string;\n /** @default true */\n defaultChecked?: boolean;\n /** @default {\"variant\":\"inputLabel\"} */\n labelStyle?: TextStyleWithVariant;\n loading?: boolean;\n width?: Dim;\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n minHeight?: Dim;\n maxHeight?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n margin?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default true */\n isVisible?: boolean;\n isRequired?: boolean;\n /** @default false */\n isDisabled?: boolean;\n /** @default \"tooltip\" */\n errorMessagePlacement?: \"tooltip\" | \"inline\";\n /** @default \"\" */\n customValidationRule?: string;\n /** @default \"\" */\n customErrorMessage?: string;\n onCheckChange?: EventFlow;\n}\n```\n\nAnd the following properties can be referenced on this component in the Superblocks state object:\n\n```typescript\ninterface CheckboxComponentState {\n value?: boolean;\n /** @default {} */\n validationErrors?: any;\n /** @default true */\n isValid?: boolean;\n showError?: boolean;\n}\n```\n\nAnd the following properties are settable via BindEntity.{propertyName} = newValue;\n\n```typescript\ninterface CheckboxMetaProperties {\n /** @default false */\n isTouched?: boolean;\n isChecked?: boolean;\n}\n```\n";
2
+ //# sourceMappingURL=CheckboxPropsDocs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CheckboxPropsDocs.d.ts","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/CheckboxPropsDocs.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,+hDAA+hD,CAAC"}
@@ -0,0 +1,6 @@
1
+ /* eslint-disable */
2
+ // Auto-generated from CheckboxPropsDocs.md
3
+ // Do not edit this file directly
4
+ // Generated at: 2025-07-03T15:08:51.451Z
5
+ export const content = "## Checkbox\n\nThe following is the type definition for the Checkbox component.\n\n```typescript\ninterface CheckboxProps {\n /** @default \"\" */\n label?: string;\n /** @default true */\n defaultChecked?: boolean;\n /** @default {\"variant\":\"inputLabel\"} */\n labelStyle?: TextStyleWithVariant;\n loading?: boolean;\n width?: Dim;\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n minHeight?: Dim;\n maxHeight?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n margin?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default true */\n isVisible?: boolean;\n isRequired?: boolean;\n /** @default false */\n isDisabled?: boolean;\n /** @default \"tooltip\" */\n errorMessagePlacement?: \"tooltip\" | \"inline\";\n /** @default \"\" */\n customValidationRule?: string;\n /** @default \"\" */\n customErrorMessage?: string;\n onCheckChange?: EventFlow;\n}\n```\n\nAnd the following properties can be referenced on this component in the Superblocks state object:\n\n```typescript\ninterface CheckboxComponentState {\n value?: boolean;\n /** @default {} */\n validationErrors?: any;\n /** @default true */\n isValid?: boolean;\n showError?: boolean;\n}\n```\n\nAnd the following properties are settable via BindEntity.{propertyName} = newValue;\n\n```typescript\ninterface CheckboxMetaProperties {\n /** @default false */\n isTouched?: boolean;\n isChecked?: boolean;\n}\n```\n";
6
+ //# sourceMappingURL=CheckboxPropsDocs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CheckboxPropsDocs.js","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/CheckboxPropsDocs.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,2CAA2C;AAC3C,iCAAiC;AACjC,yCAAyC;AAEzC,MAAM,CAAC,MAAM,OAAO,GAAG,4hDAA4hD,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const content = "## Column\n\nThe following is the type definition for the Column component.\n\n```typescript\ninterface ColumnProps {\n /** @default \"vertical\" */\n layout?: \"freeform\" | \"vertical\" | \"horizontal\";\n /** @default \"top\" */\n verticalAlign?:\n | \"top\"\n | \"center\"\n | \"bottom\"\n | \"space-between\"\n | \"space-around\";\n /** @default \"left\" */\n horizontalAlign?:\n | \"left\"\n | \"center\"\n | \"right\"\n | \"space-between\"\n | \"space-around\";\n /** @default {\"mode\":\"px\",\"value\":12} */\n spacing?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":12},\"bottom\":{\"mode\":\"px\",\"value\":12},\"left\":{\"mode\":\"px\",\"value\":12},\"right\":{\"mode\":\"px\",\"value\":12}} */\n padding?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default {\"mode\":\"fill\",\"value\":1} */\n width?: Dim;\n /** @default {\"mode\":\"fill\",\"value\":1} */\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n /** @default 12 */\n columns?: number;\n /** @default 12 */\n rowHeight?: Dim;\n /** @default true */\n shouldScrollContents?: boolean;\n /** @default true */\n isVisible?: boolean;\n backgroundColor?: string;\n border?: { left: Border; right: Border; top: Border; bottom: Border };\n loading?: boolean;\n}\n```\n";
2
+ //# sourceMappingURL=ColumnPropsDocs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ColumnPropsDocs.d.ts","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/ColumnPropsDocs.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,OAAO,2yCAA2yC,CAAC"}
@@ -0,0 +1,6 @@
1
+ /* eslint-disable */
2
+ // Auto-generated from ColumnPropsDocs.md
3
+ // Do not edit this file directly
4
+ // Generated at: 2025-07-03T15:08:51.451Z
5
+ export const content = "## Column\n\nThe following is the type definition for the Column component.\n\n```typescript\ninterface ColumnProps {\n /** @default \"vertical\" */\n layout?: \"freeform\" | \"vertical\" | \"horizontal\";\n /** @default \"top\" */\n verticalAlign?:\n | \"top\"\n | \"center\"\n | \"bottom\"\n | \"space-between\"\n | \"space-around\";\n /** @default \"left\" */\n horizontalAlign?:\n | \"left\"\n | \"center\"\n | \"right\"\n | \"space-between\"\n | \"space-around\";\n /** @default {\"mode\":\"px\",\"value\":12} */\n spacing?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":12},\"bottom\":{\"mode\":\"px\",\"value\":12},\"left\":{\"mode\":\"px\",\"value\":12},\"right\":{\"mode\":\"px\",\"value\":12}} */\n padding?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default {\"mode\":\"fill\",\"value\":1} */\n width?: Dim;\n /** @default {\"mode\":\"fill\",\"value\":1} */\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n /** @default 12 */\n columns?: number;\n /** @default 12 */\n rowHeight?: Dim;\n /** @default true */\n shouldScrollContents?: boolean;\n /** @default true */\n isVisible?: boolean;\n backgroundColor?: string;\n border?: { left: Border; right: Border; top: Border; bottom: Border };\n loading?: boolean;\n}\n```\n";
6
+ //# sourceMappingURL=ColumnPropsDocs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ColumnPropsDocs.js","sourceRoot":"","sources":["../../../../../src/ai-service/prompts/generated/library-components/ColumnPropsDocs.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,yCAAyC;AACzC,iCAAiC;AACjC,yCAAyC;AAEzC,MAAM,CAAC,MAAM,OAAO,GAAG,wyCAAwyC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const content = "## Container\n\nThe following is the type definition for the Container component.\n\n```typescript\ninterface ContainerProps {\n /** @default \"vertical\" */\n layout?: \"freeform\" | \"vertical\" | \"horizontal\";\n /** @default \"top\" */\n verticalAlign?:\n | \"top\"\n | \"center\"\n | \"bottom\"\n | \"space-between\"\n | \"space-around\";\n /** @default \"left\" */\n horizontalAlign?:\n | \"left\"\n | \"center\"\n | \"right\"\n | \"space-between\"\n | \"space-around\";\n /** @default {\"mode\":\"px\",\"value\":12} */\n spacing?: Dim;\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n padding?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n /** @default {\"top\":{\"mode\":\"px\",\"value\":0},\"bottom\":{\"mode\":\"px\",\"value\":0},\"left\":{\"mode\":\"px\",\"value\":0},\"right\":{\"mode\":\"px\",\"value\":0}} */\n margin?: { left: Dim; right: Dim; top: Dim; bottom: Dim };\n width?: Dim;\n height?: Dim;\n minWidth?: Dim;\n maxWidth?: Dim;\n minHeight?: Dim;\n maxHeight?: Dim;\n /** @default 12 */\n columns?: number;\n /** @default 12 */\n rowHeight?: Dim;\n /** @default true */\n shouldScrollContents?: boolean;\n /** @default true */\n isVisible?: boolean;\n /** @default \"none\" */\n variant?: \"none\" | \"card\";\n backgroundColor?: string;\n border?: { left: Border; right: Border; top: Border; bottom: Border };\n borderRadius?: {\n topLeft: Dim;\n topRight: Dim;\n bottomLeft: Dim;\n bottomRight: Dim;\n };\n loading?: boolean;\n}\n```\n";
2
+ //# sourceMappingURL=ContainerPropsDocs.d.ts.map