@salsita-ai/sdk 0.50.0-develop.f81ab6ac76 → 0.50.0-develop.f87b940e67

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 (617) hide show
  1. package/dist/application/index.d.ts +1 -0
  2. package/dist/application/index.js +1 -1
  3. package/dist/application/mount-application.d.ts +1 -1
  4. package/dist/application/mount-application.js +1 -1
  5. package/dist/application/mount-configurator.d.ts +19 -0
  6. package/dist/application/mount-configurator.js +1 -0
  7. package/dist/application/mounted-application-runtime.d.ts +4 -0
  8. package/dist/application/mounted-application-runtime.js +1 -0
  9. package/dist/application/register-web-component.d.ts +2 -0
  10. package/dist/application/register-web-component.js +1 -0
  11. package/dist/application-spec/errors/diagnostic-codes.d.ts +9 -0
  12. package/dist/application-spec/errors/diagnostic-codes.js +1 -1
  13. package/dist/application-spec/errors/diagnostic-messages.d.ts +10 -1
  14. package/dist/application-spec/errors/diagnostic-messages.js +1 -1
  15. package/dist/application-spec/generate-application/code/domain-runtime-files.js +1 -1
  16. package/dist/application-spec/generate-application/code/templates/application-types.js +6 -6
  17. package/dist/application-spec/generate-application/code/templates/common/doc-comment.d.ts +2 -0
  18. package/dist/application-spec/generate-application/code/templates/common/doc-comment.js +1 -0
  19. package/dist/application-spec/generate-application/code/templates/configurator-globals.d.ts +2 -1
  20. package/dist/application-spec/generate-application/code/templates/configurator-globals.js +19 -6
  21. package/dist/application-spec/generate-application/code/templates/global-definition/generate-action-types.js +7 -7
  22. package/dist/application-spec/generate-application/code/templates/global-definition/generate-assistant-form-element-types.d.ts +12 -0
  23. package/dist/application-spec/generate-application/code/templates/global-definition/generate-assistant-form-element-types.js +7 -0
  24. package/dist/application-spec/generate-application/code/templates/global-definition/generate-phx-types.js +24 -22
  25. package/dist/application-spec/generate-application/code/templates/global-definition/index.d.ts +1 -0
  26. package/dist/application-spec/generate-application/code/templates/global-definition/index.js +1 -1
  27. package/dist/application-spec/generate-application/code/templates/skills/sdk-content.d.ts +13 -6
  28. package/dist/application-spec/generate-application/code/templates/skills/sdk-content.js +2 -2
  29. package/dist/application-spec/generate-application/implementations/phx-application-types.d.ts +25 -0
  30. package/dist/application-spec/generate-application/implementations/phx-application-types.js +1 -0
  31. package/dist/application-spec/generate-application/implementations/phx-domain.d.ts +36 -0
  32. package/dist/application-spec/generate-application/implementations/phx-domain.js +1 -0
  33. package/dist/application-spec/generate-application/implementations/phx-model.d.ts +24 -0
  34. package/dist/application-spec/generate-application/implementations/phx-model.js +1 -0
  35. package/dist/application-spec/generate-application/implementations/phx.d.ts +22 -0
  36. package/dist/application-spec/generate-application/implementations/phx.js +1 -0
  37. package/dist/application-spec/generate-application/index.d.ts +2 -0
  38. package/dist/application-spec/generate-application/index.js +1 -1
  39. package/dist/application-spec/generate-application/runtime/admin-runtime/admin-model-runtime.d.ts +3 -3
  40. package/dist/application-spec/generate-application/runtime/admin-runtime/admin-runtime.d.ts +7 -4
  41. package/dist/application-spec/generate-application/runtime/admin-runtime/admin-runtime.js +1 -1
  42. package/dist/application-spec/generate-application/runtime/admin-runtime/admin-spec-runtime.d.ts +16 -0
  43. package/dist/application-spec/generate-application/runtime/admin-runtime/admin-spec-runtime.js +1 -0
  44. package/dist/application-spec/generate-application/runtime/application-runtime.d.ts +17 -4
  45. package/dist/application-spec/generate-application/runtime/application-runtime.js +1 -1
  46. package/dist/application-spec/generate-application/runtime/application-spec-slice.d.ts +71 -0
  47. package/dist/application-spec/generate-application/runtime/application-spec-slice.js +1 -0
  48. package/dist/application-spec/generate-application/runtime/configurator-runtime/configurator-model-runtime.d.ts +3 -3
  49. package/dist/application-spec/generate-application/runtime/configurator-runtime/configurator-runtime.d.ts +7 -5
  50. package/dist/application-spec/generate-application/runtime/configurator-runtime/configurator-runtime.js +1 -1
  51. package/dist/application-spec/generate-application/runtime/configurator-runtime/configurator-spec-runtime.d.ts +16 -0
  52. package/dist/application-spec/generate-application/runtime/configurator-runtime/configurator-spec-runtime.js +1 -0
  53. package/dist/application-spec/generate-application/runtime/create-application.d.ts +57 -0
  54. package/dist/application-spec/generate-application/runtime/create-application.js +1 -0
  55. package/dist/application-spec/generate-application/runtime/index.d.ts +8 -0
  56. package/dist/application-spec/generate-application/runtime/index.js +1 -0
  57. package/dist/application-spec/generate-application/runtime/sections/expression-runtime.d.ts +9 -3
  58. package/dist/application-spec/generate-application/runtime/sections/expression-runtime.js +1 -1
  59. package/dist/application-spec/generate-application/runtime/spec-runtime.d.ts +21 -0
  60. package/dist/application-spec/generate-application/runtime/spec-runtime.js +1 -0
  61. package/dist/application-spec/generate-application/runtime-spec/encoded-runtime-spec.d.ts +3 -2
  62. package/dist/application-spec/generate-application/runtime-spec/runtime-spec.d.ts +44 -9
  63. package/dist/application-spec/generate-application/runtime-spec/runtime-spec.js +1 -1
  64. package/dist/application-spec/parse-application-files/raw-spec/raw-assistant.d.ts +33 -3
  65. package/dist/application-spec/parse-application-files/raw-spec/raw-assistant.js +1 -1
  66. package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-form-elements.d.ts +9 -0
  67. package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-form-elements.js +1 -0
  68. package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-schema.d.ts +4 -1
  69. package/dist/application-spec/parse-application-files/spec/sections/assistant/assistant-schema.js +1 -1
  70. package/dist/configurator/ConfiguratorApp.js +1 -1
  71. package/dist/configurator/app-loader-content/DefaultAppLoaderContent.d.ts +2 -0
  72. package/dist/configurator/app-loader-content/DefaultAppLoaderContent.js +5 -0
  73. package/dist/configurator/app-loader-content/index.d.ts +1 -0
  74. package/dist/configurator/app-loader-content/index.js +1 -0
  75. package/dist/configurator/application-runtime/extensions/selectors.js +1 -1
  76. package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-system.d.ts +4 -3
  77. package/dist/configurator/application-runtime/extensions/systems/assistant-system/assistant-system.js +1 -1
  78. package/dist/configurator/application-runtime/extensions/systems/assistant-system/graphql-tools.d.ts +33 -7
  79. package/dist/configurator/application-runtime/extensions/systems/assistant-system/graphql-tools.js +1 -1
  80. package/dist/configurator/application-runtime/extensions/systems/camera-control-system/camera-control-system.d.ts +1 -1
  81. package/dist/configurator/application-runtime/extensions/systems/canvas-system.d.ts +8 -0
  82. package/dist/configurator/application-runtime/extensions/systems/canvas-system.js +1 -1
  83. package/dist/configurator/application-runtime/extensions/systems/export-system/export-busy-error.d.ts +8 -0
  84. package/dist/configurator/application-runtime/extensions/systems/export-system/export-busy-error.js +1 -0
  85. package/dist/configurator/application-runtime/extensions/systems/export-system/export-system.d.ts +23 -1
  86. package/dist/configurator/application-runtime/extensions/systems/export-system/export-system.js +1 -1
  87. package/dist/configurator/application-runtime/extensions/systems/graphql-system/entity-meta.d.ts +14 -1
  88. package/dist/configurator/application-runtime/extensions/systems/graphql-system/entity-meta.js +1 -1
  89. package/dist/configurator/application-runtime/extensions/systems/graphql-system/graphql-system.d.ts +45 -4
  90. package/dist/configurator/application-runtime/extensions/systems/graphql-system/graphql-system.js +1 -1
  91. package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/image-rendering-system.d.ts +14 -5
  92. package/dist/configurator/application-runtime/extensions/systems/image-rendering-system/image-rendering-system.js +1 -1
  93. package/dist/configurator/application-runtime/extensions/systems/index.d.ts +1 -1
  94. package/dist/configurator/common/configurator-interface.d.ts +111 -5
  95. package/dist/configurator/common/configurator-interface.js +1 -1
  96. package/dist/configurator/configuration-not-found-page/BuiltInConfigurationNotFoundPage.d.ts +5 -0
  97. package/dist/configurator/configuration-not-found-page/BuiltInConfigurationNotFoundPage.js +1 -0
  98. package/dist/configurator/configuration-not-found-page/ConfigurationNotFoundPageElement.d.ts +0 -6
  99. package/dist/configurator/configuration-not-found-page/ConfigurationNotFoundPageElement.js +1 -1
  100. package/dist/configurator/configuration-not-found-page/index.d.ts +2 -1
  101. package/dist/configurator/configuration-not-found-page/index.js +1 -1
  102. package/dist/configurator/configurator-context/ConfiguratorResponsiveProvider.d.ts +12 -0
  103. package/dist/configurator/configurator-context/ConfiguratorResponsiveProvider.js +1 -0
  104. package/dist/configurator/configurator-context/PreviewContextProvider.js +1 -1
  105. package/dist/configurator/configurator-context/ViewportStateSync.d.ts +2 -2
  106. package/dist/configurator/configurator-context/ViewportStateSync.js +1 -1
  107. package/dist/configurator/configurator-context/configurator-hooks/layout-hooks.d.ts +10 -0
  108. package/dist/configurator/configurator-context/configurator-routing/ConfiguratorRoutingProvider.js +1 -1
  109. package/dist/configurator/configurator-error-page/BuiltInConfiguratorErrorPage.d.ts +6 -0
  110. package/dist/configurator/configurator-error-page/BuiltInConfiguratorErrorPage.js +1 -0
  111. package/dist/configurator/configurator-error-page/ConfiguratorErrorPageElement.d.ts +7 -0
  112. package/dist/configurator/configurator-error-page/ConfiguratorErrorPageElement.js +1 -0
  113. package/dist/configurator/configurator-error-page/index.d.ts +2 -0
  114. package/dist/configurator/configurator-error-page/index.js +1 -0
  115. package/dist/configurator/index.d.ts +10 -0
  116. package/dist/configurator/index.js +1 -1
  117. package/dist/configurator/pages/ConfiguratorErrorPage.d.ts +0 -1
  118. package/dist/configurator/pages/ConfiguratorErrorPage.js +1 -1
  119. package/dist/configurator/pages/LoadedConfiguratorDetailPage.js +1 -1
  120. package/dist/configurator/pages/PresetCreationErrorPage.d.ts +1 -1
  121. package/dist/configurator/pages/PresetCreationErrorPage.js +1 -1
  122. package/dist/configurator/pages/default-configurator-elements.d.ts +4 -2
  123. package/dist/configurator/pages/default-configurator-elements.js +1 -1
  124. package/dist/configurator/pages/default-elements/index.d.ts +1 -0
  125. package/dist/configurator/pages/default-elements/index.js +1 -1
  126. package/dist/configurator/pages/default-elements/scene-controls/BuiltInAddEntityFab.d.ts +3 -0
  127. package/dist/configurator/pages/default-elements/scene-controls/BuiltInAddEntityFab.js +1 -0
  128. package/dist/configurator/pages/default-elements/scene-controls/BuiltInDeleteEntityFab.d.ts +3 -0
  129. package/dist/configurator/pages/default-elements/scene-controls/BuiltInDeleteEntityFab.js +1 -0
  130. package/dist/configurator/pages/default-elements/scene-controls/BuiltInNavigationHotspot.d.ts +3 -0
  131. package/dist/configurator/pages/default-elements/scene-controls/BuiltInNavigationHotspot.js +1 -0
  132. package/dist/configurator/pages/default-elements/scene-controls/BuiltInSelectionHotspot.d.ts +3 -0
  133. package/dist/configurator/pages/default-elements/scene-controls/BuiltInSelectionHotspot.js +1 -0
  134. package/dist/configurator/pages/default-elements/scene-controls/BuiltInToolMenuFab.d.ts +3 -0
  135. package/dist/configurator/pages/default-elements/scene-controls/BuiltInToolMenuFab.js +1 -0
  136. package/dist/configurator/pages/default-elements/scene-controls/index.d.ts +6 -0
  137. package/dist/configurator/pages/default-elements/scene-controls/index.js +1 -0
  138. package/dist/configurator/pages/default-elements/scene-controls/scene-control-elements.d.ts +6 -0
  139. package/dist/configurator/pages/default-elements/scene-controls/scene-control-elements.js +1 -0
  140. package/dist/configurator/pages/error-boundaries/GeneralErrorBoundary.js +1 -1
  141. package/dist/configurator/pages/error-boundaries/LoadingErrorBoundary.js +1 -1
  142. package/dist/configurator/scene/index.d.ts +1 -0
  143. package/dist/configurator/scene/index.js +1 -1
  144. package/dist/configurator/scene/scene-controls/ToolFab.d.ts +4 -0
  145. package/dist/configurator/scene/scene-controls/ToolFab.js +1 -1
  146. package/dist/configurator/scene/scene-controls/use-scene-control-tooltip.d.ts +2 -1
  147. package/dist/configurator/scene/scene-entity/scene-controls/SceneEntityHtmlHotspots.js +1 -1
  148. package/dist/configurator/toolbar-actions/index.d.ts +3 -0
  149. package/dist/configurator/toolbar-actions/index.js +1 -0
  150. package/dist/configurator/toolbar-actions/use-assistant-panel.d.ts +18 -0
  151. package/dist/configurator/toolbar-actions/use-assistant-panel.js +1 -0
  152. package/dist/configurator/toolbar-actions/use-measurements.d.ts +35 -0
  153. package/dist/configurator/toolbar-actions/use-measurements.js +1 -0
  154. package/dist/configurator/toolbar-actions/use-toolbar-actions.d.ts +100 -0
  155. package/dist/configurator/toolbar-actions/use-toolbar-actions.js +1 -0
  156. package/dist/configurator/toolbar-actions/use-toolbar-help.d.ts +7 -0
  157. package/dist/configurator/toolbar-actions/use-toolbar-help.js +1 -0
  158. package/dist/configurator/ui/assistant/AssistantChips.d.ts +3 -2
  159. package/dist/configurator/ui/assistant/AssistantChips.js +1 -1
  160. package/dist/configurator/ui/assistant/AssistantMarkdown.d.ts +1 -1
  161. package/dist/configurator/ui/assistant/AssistantMarkdown.js +1 -1
  162. package/dist/configurator/ui/assistant/alert/AssistantAlert.d.ts +8 -0
  163. package/dist/configurator/ui/assistant/alert/AssistantAlert.js +1 -0
  164. package/dist/configurator/ui/assistant/alert/index.d.ts +2 -0
  165. package/dist/configurator/ui/assistant/alert/index.js +1 -0
  166. package/dist/configurator/ui/assistant/alert/remark-alerts.d.ts +10 -0
  167. package/dist/configurator/ui/assistant/alert/remark-alerts.js +1 -0
  168. package/dist/configurator/ui/assistant/form/AssistantForm.js +1 -1
  169. package/dist/configurator/ui/assistant/form/compose-answer.d.ts +1 -1
  170. package/dist/configurator/ui/assistant/form/compose-answer.js +1 -1
  171. package/dist/configurator/ui/assistant/form/form-model.d.ts +3 -4
  172. package/dist/configurator/ui/assistant/form/form-state.d.ts +1 -1
  173. package/dist/configurator/ui/assistant/form/index.d.ts +2 -0
  174. package/dist/configurator/ui/assistant/form/index.js +1 -1
  175. package/dist/configurator/ui/assistant/form/parse-form-block.d.ts +3 -2
  176. package/dist/configurator/ui/assistant/form/parse-form-block.js +1 -1
  177. package/dist/configurator/ui/assistant/form/read-form-attributes.d.ts +1 -1
  178. package/dist/configurator/ui/assistant/form/read-form-attributes.js +1 -1
  179. package/dist/configurator/ui/assistant/form/registry/built-in-form-elements.d.ts +3 -0
  180. package/dist/configurator/ui/assistant/form/registry/built-in-form-elements.js +1 -0
  181. package/dist/configurator/ui/assistant/form/registry/create-assistant-form-element.d.ts +31 -0
  182. package/dist/configurator/ui/assistant/form/registry/create-assistant-form-element.js +1 -0
  183. package/dist/configurator/ui/assistant/form/{form-element-definition.d.ts → registry/form-element-definition.d.ts} +3 -1
  184. package/dist/configurator/ui/assistant/form/registry/form-element-definition.js +1 -0
  185. package/dist/configurator/ui/assistant/form/{form-registry.d.ts → registry/form-registry.d.ts} +2 -2
  186. package/dist/configurator/ui/assistant/form/registry/form-registry.js +1 -0
  187. package/dist/configurator/ui/assistant/form/registry/index.d.ts +6 -0
  188. package/dist/configurator/ui/assistant/form/registry/index.js +1 -0
  189. package/dist/configurator/ui/assistant/form/registry/use-form-registry.d.ts +8 -0
  190. package/dist/configurator/ui/assistant/form/registry/use-form-registry.js +1 -0
  191. package/dist/configurator/ui/assistant/form-elements/FormCard.d.ts +9 -0
  192. package/dist/configurator/ui/assistant/form-elements/FormCard.js +1 -0
  193. package/dist/configurator/ui/assistant/form-elements/FormConfirm.d.ts +9 -0
  194. package/dist/configurator/ui/assistant/form-elements/FormConfirm.js +1 -0
  195. package/dist/configurator/ui/assistant/form-elements/FormGroup.d.ts +4 -1
  196. package/dist/configurator/ui/assistant/form-elements/FormNumber.d.ts +9 -0
  197. package/dist/configurator/ui/assistant/form-elements/FormNumber.js +1 -0
  198. package/dist/configurator/ui/assistant/form-elements/FormOptions.d.ts +4 -1
  199. package/dist/configurator/ui/assistant/form-elements/FormReply.d.ts +4 -1
  200. package/dist/configurator/ui/assistant/form-elements/FormReply.js +1 -1
  201. package/dist/configurator/ui/assistant/form-elements/FormSwatch.d.ts +10 -0
  202. package/dist/configurator/ui/assistant/form-elements/FormSwatch.js +1 -0
  203. package/dist/configurator/ui/assistant/form-elements/FormText.d.ts +4 -1
  204. package/dist/configurator/ui/assistant/form-elements/FormText.js +1 -1
  205. package/dist/configurator/ui/assistant/form-elements/clamp-form-number.d.ts +10 -0
  206. package/dist/configurator/ui/assistant/form-elements/clamp-form-number.js +1 -0
  207. package/dist/configurator/ui/assistant/form-elements/form-element-props.d.ts +20 -16
  208. package/dist/configurator/ui/assistant/form-elements/index.d.ts +4 -0
  209. package/dist/configurator/ui/assistant/form-elements/index.js +1 -1
  210. package/dist/configurator/ui/assistant/index.d.ts +3 -0
  211. package/dist/configurator/ui/assistant/index.js +1 -1
  212. package/dist/configurator/ui/assistant/resource-image/index.d.ts +1 -1
  213. package/dist/configurator/ui/assistant/resource-image/index.js +1 -1
  214. package/dist/configurator/ui/assistant/resource-image/resource-path.d.ts +0 -9
  215. package/dist/configurator/ui/assistant/resource-image/resource-path.js +1 -1
  216. package/dist/configurator/ui/assistant/screenshots/ScreenshotThumbnails.d.ts +9 -0
  217. package/dist/configurator/ui/assistant/screenshots/ScreenshotThumbnails.js +1 -0
  218. package/dist/configurator/ui/assistant/screenshots/index.d.ts +2 -0
  219. package/dist/configurator/ui/assistant/screenshots/index.js +1 -0
  220. package/dist/configurator/ui/assistant/screenshots/tool-screenshots.d.ts +14 -0
  221. package/dist/configurator/ui/assistant/screenshots/tool-screenshots.js +1 -0
  222. package/dist/configurator/ui/assistant/streamed-markdown.d.ts +2 -2
  223. package/dist/configurator/ui/assistant/streamed-markdown.js +2 -2
  224. package/dist/configurator/ui/assistant/tool-chip.js +1 -1
  225. package/dist/configurator/ui/configurator-layout/slots/canvas/LayoutCanvas.js +1 -1
  226. package/dist/configurator/ui/configurator-layout/slots/canvas/SharedCanvas.js +1 -1
  227. package/dist/configurator/ui/configurator-layout/universal/ExportingOverlay.d.ts +5 -0
  228. package/dist/configurator/ui/configurator-layout/universal/ExportingOverlay.js +1 -0
  229. package/dist/configurator/ui/configurator-layout/universal/Layout.js +1 -1
  230. package/dist/configurator/ui/configurator-layout/universal/use-layout-scene-safe-area.d.ts +1 -1
  231. package/dist/configurator/ui/configurator-layout/universal/use-layout-scene-safe-area.js +1 -1
  232. package/dist/configurator/ui/configurator-layout/universal/use-scene-safe-area.d.ts +1 -1
  233. package/dist/configurator/ui/index.d.ts +1 -0
  234. package/dist/configurator/ui/index.js +1 -1
  235. package/dist/configurator/ui/legacy/layout/common/ReactiveInterfaceLayout.js +1 -1
  236. package/dist/configurator/ui/phoenix-layout-elements/AppLoader.d.ts +0 -7
  237. package/dist/configurator/ui/phoenix-layout-elements/AppLoader.js +2 -6
  238. package/dist/configurator/ui/phoenix-layout-elements/AssistantToolbarButton.js +1 -1
  239. package/dist/configurator/ui/phoenix-layout-elements/LanguageMenuAction.js +1 -1
  240. package/dist/configurator/ui/phoenix-layout-elements/LanguageToolbarButton.js +1 -1
  241. package/dist/configurator/ui/phoenix-layout-elements/MeasurementsMenuAction.js +1 -1
  242. package/dist/configurator/ui/phoenix-layout-elements/MeasurementsToolbarButton.js +1 -1
  243. package/dist/configurator/ui/phoenix-layout-elements/ShareToolbarButton.js +1 -1
  244. package/dist/configurator/ui/phoenix-layout-elements/header/common/step-navigation/DesktopNavigationSteps.d.ts +1 -1
  245. package/dist/configurator/ui/phoenix-layout-elements/header/common/step-navigation/DesktopNavigationSteps.js +1 -1
  246. package/dist/configurator/ui/phoenix-layout-elements/header/common/step-navigation/StepsNavigation.d.ts +2 -8
  247. package/dist/configurator/ui/phoenix-layout-elements/header/common/step-navigation/StepsNavigation.js +1 -1
  248. package/dist/configurator/ui/phoenix-layout-elements/index.d.ts +8 -1
  249. package/dist/configurator/ui/phoenix-layout-elements/index.js +1 -1
  250. package/dist/configurator/ui/phoenix-layout-elements/measurements/DimensionUnitSelector.js +1 -1
  251. package/dist/configurator/ui/phoenix-layout-elements/measurements/MeasurementsIndicatorsSwitch.js +1 -1
  252. package/dist/configurator/ui/phoenix-layout-elements/share/ShareModal.js +1 -1
  253. package/dist/configurator/ui/phoenix-layout-elements/share/use-share.d.ts +7 -8
  254. package/dist/configurator/ui/phoenix-layout-elements/share/use-share.js +1 -1
  255. package/dist/configurator/ui/phoenix-layout-elements/sidebar-footer/common/FinalizeActions.js +1 -1
  256. package/dist/configurator/ui/phoenix-layout-elements/sidebar-footer/common/NextStepButton.js +1 -1
  257. package/dist/configurator/ui/phoenix-layout-elements/sidebar-footer/common/PreviousStepButton.js +1 -1
  258. package/dist/configurator/ui/preset-layout/PresetUi.d.ts +0 -2
  259. package/dist/configurator/ui/preset-layout/PresetUi.js +1 -1
  260. package/dist/configurator/ui/preset-layout/index.d.ts +6 -1
  261. package/dist/configurator/ui/preset-layout/index.js +1 -1
  262. package/dist/configurator/ui/save-message-snackbars/SaveMessageSnackbars.js +1 -1
  263. package/dist/docs/complex-use-cases/focus-mode.mdx +2 -0
  264. package/dist/docs/fabs/basic.mdx +4 -0
  265. package/dist/docs/index.json +95 -1
  266. package/dist/docs/integrations/webcomponent-api/basics.mdx +2 -0
  267. package/dist/docs/layouts/custom-layout.mdx +321 -159
  268. package/dist/docs/layouts/gallery/ardent-compressor.mdx +3516 -0
  269. package/dist/docs/layouts/gallery/corvid-drone.mdx +3428 -0
  270. package/dist/docs/layouts/gallery/fenwick-window.mdx +2803 -0
  271. package/dist/docs/layouts/gallery/ferrule-bar-station.mdx +6567 -0
  272. package/dist/docs/layouts/gallery/kestrel-kettle.mdx +1858 -0
  273. package/dist/docs/layouts/gallery/nightjar-guitar.mdx +3698 -0
  274. package/dist/docs/layouts/gallery/sunfold-solar.mdx +2683 -0
  275. package/dist/docs/layouts/gallery/tidepool-aquascape.mdx +5203 -0
  276. package/dist/docs/other-features/client-side-rendering/declarative.mdx +1 -1
  277. package/dist/docs/other-features/error-5xx.mdx +1 -1
  278. package/dist/docs/other-features/navigation-hotspot.mdx +2 -0
  279. package/dist/docs/other-features/not-found-404.mdx +1 -1
  280. package/dist/docs/phoenix/configurator-interface.mdx +202 -67
  281. package/dist/docs/phoenix/finalization.mdx +1 -1
  282. package/dist/docs/phoenix/layout-slots.mdx +5 -5
  283. package/dist/docs/phoenix/sdk-builder-workflow.mdx +1 -1
  284. package/dist/docs/phoenix/sessions-and-access.mdx +2 -0
  285. package/dist/docs/phoenix/testing.mdx +2 -2
  286. package/dist/docs/selection-and-highlight/hotspots.mdx +2 -0
  287. package/dist/domain/application/assistant/assistant-manifest.d.ts +16 -1
  288. package/dist/domain/application/assistant/assistant-resolved-manifest.d.ts +8 -1
  289. package/dist/domain/application/assistant/build-assistant-manifest.js +1 -1
  290. package/dist/domain/application/assistant/form/assistant-form-element-name.d.ts +11 -0
  291. package/dist/domain/application/assistant/form/assistant-form-element-name.js +8 -0
  292. package/dist/domain/application/assistant/form/assistant-form-elements.d.ts +174 -0
  293. package/dist/domain/application/assistant/form/assistant-form-elements.js +1 -0
  294. package/dist/domain/application/assistant/form/assistant-resource-path.d.ts +10 -0
  295. package/dist/domain/application/assistant/form/assistant-resource-path.js +1 -0
  296. package/dist/domain/application/assistant/form/index.d.ts +4 -0
  297. package/dist/domain/application/assistant/form/index.js +1 -0
  298. package/dist/domain/application/assistant/generate-assistant-prompt.d.ts +3 -0
  299. package/dist/domain/application/assistant/generate-assistant-prompt.js +1 -1
  300. package/dist/domain/application/assistant/index.d.ts +2 -3
  301. package/dist/domain/application/assistant/index.js +1 -1
  302. package/dist/domain/application/assistant/session-setup/apply-assistant-setup.js +1 -1
  303. package/dist/domain/application/assistant/session-setup/assistant-setup-manifest.d.ts +2 -0
  304. package/dist/domain/application/assistant/session-setup/assistant-setup-manifest.js +1 -1
  305. package/dist/domain/application/configurator-builder.d.ts +7 -1
  306. package/dist/domain/application/configurator-builder.js +1 -1
  307. package/dist/domain/application/index.d.ts +1 -1
  308. package/dist/domain/application/index.js +1 -1
  309. package/dist/domain/application/standard-properties.js +1 -1
  310. package/dist/domain/application/web-component-property.d.ts +3 -1
  311. package/dist/domain/application/web-component-property.js +1 -1
  312. package/dist/domain/available-system-components.d.ts +1 -1
  313. package/dist/domain/available-system-components.js +1 -1
  314. package/dist/domain/domain-builder.d.ts +9 -3
  315. package/dist/domain/domain-builder.js +1 -1
  316. package/dist/domain/domain-context/store-system/store-system.d.ts +5 -0
  317. package/dist/domain/domain-context/store-system/store-system.js +1 -1
  318. package/dist/domain/domain-runtime/application.d.ts +39 -0
  319. package/dist/domain/domain-runtime/application.js +1 -0
  320. package/dist/domain/domain-runtime/domain-context/selectors.d.ts +1 -0
  321. package/dist/domain/domain-runtime/domain-context/selectors.js +1 -1
  322. package/dist/domain/domain-runtime/domain-runtime.d.ts +44 -4
  323. package/dist/domain/domain-runtime/domain-runtime.js +1 -1
  324. package/dist/domain/domain-runtime/environment/initialize.d.ts +1 -1
  325. package/dist/domain/domain-runtime/environment/types.d.ts +1 -1
  326. package/dist/domain/domain-runtime/errors/implementation-error-collector.d.ts +2 -0
  327. package/dist/domain/domain-runtime/errors/implementation-error-collector.js +1 -1
  328. package/dist/domain/domain-runtime/index.d.ts +2 -1
  329. package/dist/domain/domain-runtime/index.js +1 -1
  330. package/dist/domain/domain-runtime/spec/index.d.ts +1 -1
  331. package/dist/domain/domain-runtime/spec/index.js +1 -1
  332. package/dist/domain/domain-runtime/spec/initialize.js +1 -1
  333. package/dist/domain/domain-runtime/spec/module-checks/element-registration.d.ts +15 -1
  334. package/dist/domain/domain-runtime/spec/module-checks/element-registration.js +1 -1
  335. package/dist/domain/domain-runtime/spec/module-checks/find-assistant-form-element-errors.d.ts +12 -0
  336. package/dist/domain/domain-runtime/spec/module-checks/find-assistant-form-element-errors.js +1 -0
  337. package/dist/domain/domain-runtime/spec/module-checks/index.d.ts +3 -1
  338. package/dist/domain/domain-runtime/spec/module-checks/index.js +1 -1
  339. package/dist/domain/domain-runtime/spec/module-checks/merge-expression-modules.d.ts +23 -0
  340. package/dist/domain/domain-runtime/spec/module-checks/merge-expression-modules.js +1 -0
  341. package/dist/domain/domain-runtime/spec/module-checks/resolve-expression-modules.d.ts +3 -4
  342. package/dist/domain/domain-runtime/spec/module-checks/resolve-expression-modules.js +1 -1
  343. package/dist/domain/domain-runtime/spec/selectors.d.ts +3 -1
  344. package/dist/domain/domain-runtime/spec/selectors.js +1 -1
  345. package/dist/domain/domain-runtime/web-component/actions.d.ts +3 -0
  346. package/dist/domain/domain-runtime/web-component/actions.js +1 -1
  347. package/dist/domain/domain-runtime/web-component/initialize.d.ts +1 -0
  348. package/dist/domain/domain-runtime/web-component/initialize.js +1 -1
  349. package/dist/domain/domain-runtime/web-component/selectors.d.ts +2 -0
  350. package/dist/domain/domain-runtime/web-component/selectors.js +1 -1
  351. package/dist/domain/domain-runtime/web-component/types.d.ts +6 -3
  352. package/dist/domain/extensions/export-images/agent-screenshot.d.ts +24 -0
  353. package/dist/domain/extensions/export-images/agent-screenshot.js +1 -0
  354. package/dist/domain/extensions/{client-side-image.d.ts → export-images/client-side-image.d.ts} +2 -2
  355. package/dist/domain/extensions/export-images/client-side-image.js +1 -0
  356. package/dist/domain/extensions/export-images/index.d.ts +3 -0
  357. package/dist/domain/extensions/export-images/index.js +1 -0
  358. package/dist/domain/extensions/{save-template-thumbnail.d.ts → export-images/save-template-thumbnail.d.ts} +2 -2
  359. package/dist/domain/extensions/export-images/save-template-thumbnail.js +1 -0
  360. package/dist/domain/extensions/index.d.ts +1 -2
  361. package/dist/domain/extensions/index.js +1 -1
  362. package/dist/domain/mocks/create-mock-domain-runtime.d.ts +9 -0
  363. package/dist/editor/domain-editors/DomainSpecContext.js +1 -1
  364. package/dist/editor/domain-editors/apply-spec-update.d.ts +10 -2
  365. package/dist/editor/domain-editors/apply-spec-update.js +1 -1
  366. package/dist/editor/domain-editors/use-implementation-files.d.ts +6 -14
  367. package/dist/editor/domain-editors/use-implementation-files.js +1 -1
  368. package/dist/editor/screenshot/ScreenshotHandler.js +1 -1
  369. package/dist/i18n/locales/cs/messages.js +1 -1
  370. package/dist/i18n/locales/da/messages.js +1 -1
  371. package/dist/i18n/locales/de/messages.js +1 -1
  372. package/dist/i18n/locales/de-AT/messages.js +1 -1
  373. package/dist/i18n/locales/en/messages.js +1 -1
  374. package/dist/i18n/locales/en-AU/messages.js +1 -1
  375. package/dist/i18n/locales/en-GB/messages.js +1 -1
  376. package/dist/i18n/locales/es/messages.js +1 -1
  377. package/dist/i18n/locales/fr/messages.js +1 -1
  378. package/dist/i18n/locales/hu/messages.js +1 -1
  379. package/dist/i18n/locales/it/messages.js +1 -1
  380. package/dist/i18n/locales/nl/messages.js +1 -1
  381. package/dist/i18n/locales/pl/messages.js +1 -1
  382. package/dist/i18n/locales/pt/messages.js +1 -1
  383. package/dist/i18n/locales/ro/messages.js +1 -1
  384. package/dist/i18n/locales/sk/messages.js +1 -1
  385. package/dist/i18n/locales/tr/messages.js +1 -1
  386. package/dist/legacy/domain-cli/utils/cache.d.ts +1 -1
  387. package/dist/legacy/domain-cli/utils/cache.js +1 -1
  388. package/dist/legacy/domain-spec/__generated/domain-schema.d.ts +16 -0
  389. package/dist/legacy/domain-spec/spec/domain-spec.js +1 -1
  390. package/dist/legacy/phoenix-cli/project-gen/generators/file-templates/agents/claude-md.d.ts +1 -1
  391. package/dist/legacy/phoenix-cli/project-gen/generators/file-templates/agents/cursor-rules.d.ts +1 -1
  392. package/dist/legacy/phoenix-cli/project-gen/generators/file-templates/agents/shared-sdk-content.d.ts +1 -1
  393. package/dist/legacy/phoenix-cli/project-gen/generators/file-templates/agents/shared-sdk-content.js +11 -5
  394. package/dist/react-sdk/application-runtime/common-services/analytics/analytics-service.d.ts +1 -1
  395. package/dist/react-sdk/application-runtime/common-services/analytics/frontend-analytics.d.ts +4 -0
  396. package/dist/react-sdk/application-runtime/common-services/initialize.d.ts +2 -2
  397. package/dist/react-sdk/application-runtime/hooks/index.d.ts +2 -0
  398. package/dist/react-sdk/application-runtime/hooks/index.js +1 -1
  399. package/dist/react-sdk/application-runtime/hooks/loading/index.d.ts +5 -0
  400. package/dist/react-sdk/application-runtime/hooks/loading/index.js +1 -0
  401. package/dist/react-sdk/application-runtime/hooks/loading/loader-host-context.d.ts +11 -0
  402. package/dist/react-sdk/application-runtime/hooks/loading/loader-host-context.js +1 -0
  403. package/dist/react-sdk/application-runtime/hooks/loading/use-is-awaiting-loading-phase.d.ts +8 -0
  404. package/dist/react-sdk/application-runtime/hooks/loading/use-is-awaiting-loading-phase.js +1 -0
  405. package/dist/react-sdk/application-runtime/hooks/loading/use-is-loader-hosted.d.ts +7 -0
  406. package/dist/react-sdk/application-runtime/hooks/loading/use-is-loader-hosted.js +1 -0
  407. package/dist/react-sdk/application-runtime/hooks/loading/use-loading-actions.d.ts +9 -0
  408. package/dist/react-sdk/application-runtime/hooks/loading/use-loading-actions.js +1 -0
  409. package/dist/react-sdk/application-runtime/hooks/loading/use-loading-application.d.ts +24 -0
  410. package/dist/react-sdk/application-runtime/hooks/loading/use-loading-application.js +1 -0
  411. package/dist/react-sdk/application-runtime/hooks/responsive/index.d.ts +3 -0
  412. package/dist/react-sdk/application-runtime/hooks/responsive/index.js +1 -0
  413. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-actions.d.ts +9 -0
  414. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-actions.js +1 -0
  415. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-application.d.ts +26 -0
  416. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-application.js +1 -0
  417. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-state.d.ts +10 -0
  418. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-state.js +1 -0
  419. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-store.d.ts +24 -0
  420. package/dist/react-sdk/application-runtime/hooks/responsive/use-responsive-store.js +1 -0
  421. package/dist/react-sdk/application-runtime/hooks/use-access-service.d.ts +5 -0
  422. package/dist/react-sdk/application-runtime/hooks/use-access-service.js +1 -1
  423. package/dist/react-sdk/application-runtime/hooks/use-phoenix-element-slots.d.ts +2 -1
  424. package/dist/react-sdk/application-runtime/hooks/use-web-component-readonly-sync.d.ts +4 -11
  425. package/dist/react-sdk/application-runtime/hooks/use-web-component-readonly-sync.js +1 -1
  426. package/dist/react-sdk/application-runtime/hooks/use-web-component.d.ts +5 -0
  427. package/dist/react-sdk/application-runtime/hooks/use-web-component.js +1 -1
  428. package/dist/react-sdk/application-runtime/host-properties/actions.d.ts +15 -0
  429. package/dist/react-sdk/application-runtime/host-properties/actions.js +1 -0
  430. package/dist/react-sdk/application-runtime/host-properties/connect-host-properties.d.ts +30 -0
  431. package/dist/react-sdk/application-runtime/host-properties/connect-host-properties.js +1 -0
  432. package/dist/react-sdk/application-runtime/host-properties/domain-host-properties.d.ts +7 -0
  433. package/dist/react-sdk/application-runtime/host-properties/domain-host-properties.js +1 -0
  434. package/dist/react-sdk/application-runtime/host-properties/host-property-descriptors.d.ts +21 -0
  435. package/dist/react-sdk/application-runtime/host-properties/host-property-descriptors.js +1 -0
  436. package/dist/react-sdk/application-runtime/host-properties/host-property-scopes.d.ts +42 -0
  437. package/dist/react-sdk/application-runtime/host-properties/host-property-scopes.js +1 -0
  438. package/dist/react-sdk/application-runtime/host-properties/index.d.ts +8 -0
  439. package/dist/react-sdk/application-runtime/host-properties/index.js +1 -0
  440. package/dist/react-sdk/application-runtime/host-properties/initialize.d.ts +7 -0
  441. package/dist/react-sdk/application-runtime/host-properties/initialize.js +1 -0
  442. package/dist/react-sdk/application-runtime/host-properties/selectors.d.ts +54 -0
  443. package/dist/react-sdk/application-runtime/host-properties/selectors.js +1 -0
  444. package/dist/react-sdk/application-runtime/host-properties/types.d.ts +18 -0
  445. package/dist/react-sdk/application-runtime/index.d.ts +3 -0
  446. package/dist/react-sdk/application-runtime/integration/initialize.d.ts +7 -6
  447. package/dist/react-sdk/application-runtime/integration/initialize.js +1 -1
  448. package/dist/react-sdk/application-runtime/integration/selectors.d.ts +11 -2
  449. package/dist/react-sdk/application-runtime/integration/selectors.js +1 -1
  450. package/dist/react-sdk/application-runtime/integration/types.d.ts +5 -2
  451. package/dist/react-sdk/application-runtime/loading/actions.d.ts +45 -0
  452. package/dist/react-sdk/application-runtime/loading/actions.js +1 -0
  453. package/dist/react-sdk/application-runtime/loading/index.d.ts +4 -0
  454. package/dist/react-sdk/application-runtime/loading/index.js +1 -0
  455. package/dist/react-sdk/application-runtime/loading/initialize.d.ts +3 -0
  456. package/dist/react-sdk/application-runtime/loading/initialize.js +1 -0
  457. package/dist/react-sdk/application-runtime/loading/selectors.d.ts +18 -0
  458. package/dist/react-sdk/application-runtime/loading/selectors.js +1 -0
  459. package/dist/react-sdk/application-runtime/loading/types.d.ts +59 -0
  460. package/dist/react-sdk/application-runtime/loading/types.js +1 -0
  461. package/dist/react-sdk/application-runtime/mocks/create-mock-application-runtime.js +1 -1
  462. package/dist/react-sdk/application-runtime/provider/ApplicationRuntime.d.ts +6 -0
  463. package/dist/react-sdk/application-runtime/provider/ApplicationRuntime.js +1 -1
  464. package/dist/react-sdk/application-runtime/provider/ApplicationType.d.ts +7 -0
  465. package/dist/react-sdk/application-runtime/provider/ApplicationType.js +1 -1
  466. package/dist/react-sdk/application-runtime/responsive/actions.d.ts +47 -0
  467. package/dist/react-sdk/application-runtime/responsive/actions.js +1 -0
  468. package/dist/react-sdk/application-runtime/responsive/index.d.ts +4 -0
  469. package/dist/react-sdk/application-runtime/responsive/index.js +1 -0
  470. package/dist/react-sdk/application-runtime/responsive/initialize.d.ts +3 -0
  471. package/dist/react-sdk/application-runtime/responsive/initialize.js +1 -0
  472. package/dist/react-sdk/application-runtime/responsive/selectors.d.ts +20 -0
  473. package/dist/react-sdk/application-runtime/responsive/selectors.js +1 -0
  474. package/dist/react-sdk/application-runtime/responsive/types.d.ts +104 -0
  475. package/dist/react-sdk/application-runtime/responsive/types.js +1 -0
  476. package/dist/react-sdk/application-runtime/routing/routing-service.d.ts +34 -2
  477. package/dist/react-sdk/application-runtime/routing/routing-service.js +1 -1
  478. package/dist/react-sdk/application-runtime/runtime/create-application-runtime.d.ts +313 -10
  479. package/dist/react-sdk/application-runtime/runtime/create-application-runtime.js +1 -1
  480. package/dist/react-sdk/domain-application-context/BackendDataProvider.js +1 -1
  481. package/dist/react-sdk/domain-application-context/FrontendDataProvider.js +1 -1
  482. package/dist/react-sdk/domain-application-context/PublishedDataProvider.js +1 -1
  483. package/dist/react-sdk/domain-context/common-hooks/index.d.ts +9 -0
  484. package/dist/react-sdk/domain-context/common-hooks/index.js +1 -0
  485. package/dist/react-sdk/domain-context/common-hooks/use-configuration-save-state.d.ts +23 -0
  486. package/dist/react-sdk/domain-context/common-hooks/use-configuration-save-state.js +1 -0
  487. package/dist/react-sdk/domain-context/common-hooks/use-domain-context.d.ts +1 -0
  488. package/dist/react-sdk/domain-context/component-hooks/index.d.ts +1 -0
  489. package/dist/react-sdk/domain-context/component-hooks/index.js +1 -0
  490. package/dist/react-sdk/domain-context/component-hooks/use-component.js +1 -1
  491. package/dist/react-sdk/domain-context/entity-hooks/use-domain-entity-state.js +1 -1
  492. package/dist/react-sdk/domain-context/entity-hooks/use-entity-price.js +1 -1
  493. package/dist/react-sdk/domain-context/entity-hooks/use-root-entity-id.js +1 -1
  494. package/dist/react-sdk/domain-context/entity-hooks/use-root-entity-state.js +1 -1
  495. package/dist/react-sdk/domain-context/index.d.ts +5 -0
  496. package/dist/react-sdk/domain-context/index.js +1 -1
  497. package/dist/react-sdk/domain-context/system-hooks/composition-hooks.js +1 -1
  498. package/dist/react-sdk/domain-context/system-hooks/dimension-hooks.js +1 -1
  499. package/dist/react-sdk/domain-context/system-hooks/generate-share-link-hooks.d.ts +8 -0
  500. package/dist/react-sdk/domain-context/system-hooks/generate-share-link-hooks.js +1 -0
  501. package/dist/react-sdk/domain-context/system-hooks/hover-hooks.js +1 -1
  502. package/dist/react-sdk/domain-context/system-hooks/locale-switch-hooks.d.ts +24 -0
  503. package/dist/react-sdk/domain-context/system-hooks/locale-switch-hooks.js +1 -0
  504. package/dist/react-sdk/domain-context/system-hooks/navigation-hooks.js +1 -1
  505. package/dist/react-sdk/domain-context/system-hooks/selection-hooks.js +1 -1
  506. package/dist/react-sdk/domain-context/system-hooks/share-links-hooks.d.ts +32 -0
  507. package/dist/react-sdk/domain-context/system-hooks/share-links-hooks.js +1 -0
  508. package/dist/react-sdk/domain-context/system-hooks/step-navigation-hooks.d.ts +57 -0
  509. package/dist/react-sdk/domain-context/system-hooks/step-navigation-hooks.js +1 -0
  510. package/dist/react-sdk/domain-context/system-hooks/tab-navigation-hooks.js +1 -1
  511. package/dist/react-sdk/domain-context/system-hooks/undo-redo-hooks.js +1 -1
  512. package/dist/react-sdk/handlers/FinalizeActionRunner.d.ts +13 -0
  513. package/dist/react-sdk/handlers/FinalizeActionRunner.js +1 -0
  514. package/dist/react-sdk/handlers/FinalizeActionsHost.d.ts +10 -0
  515. package/dist/react-sdk/handlers/FinalizeActionsHost.js +1 -0
  516. package/dist/react-sdk/handlers/FinalizeActionsProvider.d.ts +11 -0
  517. package/dist/react-sdk/handlers/FinalizeActionsProvider.js +1 -0
  518. package/dist/react-sdk/handlers/finalize-actions-context.d.ts +6 -0
  519. package/dist/react-sdk/handlers/finalize-actions-context.js +1 -0
  520. package/dist/react-sdk/handlers/finalize-actions-store.d.ts +23 -0
  521. package/dist/react-sdk/handlers/finalize-actions-store.js +1 -0
  522. package/dist/react-sdk/handlers/index.d.ts +5 -0
  523. package/dist/react-sdk/handlers/index.js +1 -1
  524. package/dist/react-sdk/handlers/use-finalize-action.d.ts +3 -2
  525. package/dist/react-sdk/handlers/use-finalize-action.js +1 -1
  526. package/dist/react-sdk/handlers/use-finalize-actions.d.ts +53 -0
  527. package/dist/react-sdk/handlers/use-finalize-actions.js +1 -0
  528. package/dist/react-sdk/index.d.ts +2 -0
  529. package/dist/react-sdk/index.js +1 -1
  530. package/dist/react-sdk/loading-state/LoaderHost.d.ts +20 -0
  531. package/dist/react-sdk/loading-state/LoaderHost.js +1 -0
  532. package/dist/react-sdk/loading-state/built-in-loading-phase.d.ts +9 -0
  533. package/dist/react-sdk/loading-state/built-in-loading-phase.js +1 -0
  534. package/dist/react-sdk/loading-state/create-app-loader.d.ts +18 -0
  535. package/dist/react-sdk/loading-state/create-app-loader.js +1 -0
  536. package/dist/react-sdk/loading-state/index.d.ts +4 -2
  537. package/dist/react-sdk/loading-state/index.js +1 -1
  538. package/dist/react-sdk/loading-state/{LoadingStateProvider.d.ts → loading-state-hooks.d.ts} +3 -12
  539. package/dist/react-sdk/loading-state/loading-state-hooks.js +1 -0
  540. package/dist/react-sdk/page-elements/ConfigurationNotFoundPagePropsProvider.d.ts +17 -0
  541. package/dist/react-sdk/page-elements/ConfigurationNotFoundPagePropsProvider.js +1 -0
  542. package/dist/react-sdk/page-elements/ConfiguratorErrorPagePropsProvider.d.ts +17 -0
  543. package/dist/react-sdk/page-elements/ConfiguratorErrorPagePropsProvider.js +1 -0
  544. package/dist/react-sdk/page-elements/configurator-error-page-props.d.ts +20 -0
  545. package/dist/react-sdk/page-elements/configurator-error-page-props.js +1 -0
  546. package/dist/react-sdk/page-elements/create-configuration-not-found-page.d.ts +15 -0
  547. package/dist/react-sdk/page-elements/create-configuration-not-found-page.js +1 -0
  548. package/dist/react-sdk/page-elements/create-configurator-error-page.d.ts +14 -0
  549. package/dist/react-sdk/page-elements/create-configurator-error-page.js +1 -0
  550. package/dist/react-sdk/page-elements/create-preset-ui.d.ts +9 -0
  551. package/dist/react-sdk/page-elements/create-preset-ui.js +1 -0
  552. package/dist/react-sdk/page-elements/index.d.ts +6 -0
  553. package/dist/react-sdk/page-elements/index.js +1 -0
  554. package/dist/react-sdk/scene-control-elements/AddEntityFabElement.d.ts +36 -0
  555. package/dist/react-sdk/scene-control-elements/AddEntityFabElement.js +1 -0
  556. package/dist/react-sdk/scene-control-elements/DeleteEntityFabElement.d.ts +44 -0
  557. package/dist/react-sdk/scene-control-elements/DeleteEntityFabElement.js +1 -0
  558. package/dist/react-sdk/scene-control-elements/NavigationHotspotElement.d.ts +38 -0
  559. package/dist/react-sdk/scene-control-elements/NavigationHotspotElement.js +1 -0
  560. package/dist/react-sdk/scene-control-elements/SelectionHotspotElement.d.ts +30 -0
  561. package/dist/react-sdk/scene-control-elements/SelectionHotspotElement.js +1 -0
  562. package/dist/react-sdk/scene-control-elements/ToolMenuFabElement.d.ts +30 -0
  563. package/dist/react-sdk/scene-control-elements/ToolMenuFabElement.js +1 -0
  564. package/dist/react-sdk/scene-control-elements/create-add-entity-fab.d.ts +9 -0
  565. package/dist/react-sdk/scene-control-elements/create-add-entity-fab.js +1 -0
  566. package/dist/react-sdk/scene-control-elements/create-delete-entity-fab.d.ts +9 -0
  567. package/dist/react-sdk/scene-control-elements/create-delete-entity-fab.js +1 -0
  568. package/dist/react-sdk/scene-control-elements/create-navigation-hotspot.d.ts +10 -0
  569. package/dist/react-sdk/scene-control-elements/create-navigation-hotspot.js +1 -0
  570. package/dist/react-sdk/scene-control-elements/create-selection-hotspot.d.ts +9 -0
  571. package/dist/react-sdk/scene-control-elements/create-selection-hotspot.js +1 -0
  572. package/dist/react-sdk/scene-control-elements/create-tool-menu-fab.d.ts +9 -0
  573. package/dist/react-sdk/scene-control-elements/create-tool-menu-fab.js +1 -0
  574. package/dist/react-sdk/scene-control-elements/index.d.ts +11 -0
  575. package/dist/react-sdk/scene-control-elements/index.js +1 -0
  576. package/dist/react-sdk/scene-control-elements/scene-control-tooltip-visibility.d.ts +5 -0
  577. package/dist/react-sdk/scene-control-elements/scene-control-tooltip-visibility.js +1 -0
  578. package/dist/react-sdk/session/SessionServiceProvider.js +1 -1
  579. package/dist/react-sdk/web-component/create-web-component.js +1 -1
  580. package/dist/react-sdk/web-component/god-mode/god-mode-registry.d.ts +30 -0
  581. package/dist/react-sdk/web-component/god-mode/god-mode-registry.js +1 -0
  582. package/dist/react-sdk/web-component/god-mode/index.d.ts +1 -0
  583. package/dist/react-sdk/web-component/god-mode/index.js +1 -0
  584. package/dist/ui-sdk/icons/__generated/Lightbulb.d.ts +3 -0
  585. package/dist/ui-sdk/icons/__generated/Lightbulb.js +1 -0
  586. package/dist/ui-sdk/icons/__generated/XCircle.d.ts +3 -0
  587. package/dist/ui-sdk/icons/__generated/XCircle.js +1 -0
  588. package/dist/ui-sdk/icons/__generated/index.d.ts +4 -0
  589. package/dist/ui-sdk/icons/__generated/index.js +1 -1
  590. package/dist/ui-sdk/icons/icons-registry.js +1 -1
  591. package/dist/ui-sdk/responsive-application/ResponsiveApplicationProvider.d.ts +9 -0
  592. package/dist/ui-sdk/responsive-application/ResponsiveApplicationProvider.js +1 -1
  593. package/dist/ui-sdk/responsive-application/index.d.ts +1 -0
  594. package/dist/ui-sdk/responsive-application/responsive-state-store.d.ts +59 -0
  595. package/dist/ui-sdk/responsive-application/responsive-state-store.js +1 -0
  596. package/dist/ui-sdk/responsive-application/use-store-responsive-info.d.ts +7 -0
  597. package/dist/ui-sdk/responsive-application/use-store-responsive-info.js +1 -0
  598. package/dist/ui-sdk/theme/types.d.ts +5 -1
  599. package/package.json +13 -3
  600. package/schema/domain-spec.json +140 -0
  601. package/dist/configurator/ui/assistant/form/built-in-form-registry.d.ts +0 -10
  602. package/dist/configurator/ui/assistant/form/built-in-form-registry.js +0 -1
  603. package/dist/configurator/ui/assistant/form/form-registry.js +0 -8
  604. package/dist/configurator/ui/phoenix-layout-elements/language/use-locale-options.d.ts +0 -4
  605. package/dist/configurator/ui/phoenix-layout-elements/language/use-locale-options.js +0 -1
  606. package/dist/configurator/ui/phoenix-layout-elements/measurements/use-measurements-visibility.d.ts +0 -4
  607. package/dist/configurator/ui/phoenix-layout-elements/measurements/use-measurements-visibility.js +0 -1
  608. package/dist/domain/application/assistant/assistant-form-elements.d.ts +0 -28
  609. package/dist/domain/application/assistant/assistant-form-elements.js +0 -1
  610. package/dist/domain/extensions/client-side-image.js +0 -1
  611. package/dist/domain/extensions/save-template-thumbnail.js +0 -1
  612. package/dist/react-sdk/application-runtime/runtime/god-mode.d.ts +0 -19
  613. package/dist/react-sdk/application-runtime/runtime/god-mode.js +0 -1
  614. package/dist/react-sdk/loading-state/LoadingStateProvider.js +0 -1
  615. package/dist/react-sdk/loading-state/loading-state-manager.d.ts +0 -32
  616. package/dist/react-sdk/loading-state/loading-state-manager.js +0 -1
  617. /package/dist/{configurator/ui/assistant/form/form-element-definition.js → react-sdk/application-runtime/host-properties/types.js} +0 -0
@@ -1,31 +1,33 @@
1
- import{generateInvariantBlueprintMembers as e,getDomainFactoryTypes as t}from"../domain-spec/index.js";let a="CustomInvariantBlueprints",n="AdminCustomInvariantBlueprints",o=["authHandlerBuilder","webhookBuilder","taskFactory","finalizeHandlerBuilder","callbackBuilder","prefetchBuilder","dynamicResourcesFactory"],i=(e,t)=>e.replaceAll("\n",`
2
- ${t}`),r=e=>{let t=(e.infra.resources??[]).map(e=>JSON.stringify(e.name));return["AnyDomainEntity","RootEntity","$Map","NavigationState","ViewState","ToolState","ExportState","PublishedData","SessionData","FrontendData","Admin.AnyDomainEntity","Admin.RootEntity","Admin.$Map","AdminNavigationState","never","FinalizeData","PrefetchedFinalizeData","FinalizeResult","CallbackData",t.length>0?[...new Set(t)].join(" | "):"never"].join(", ")},s=()=>{let e=new Map;return{member:(t,a)=>(e.set(t,a),t),declarations:()=>[...e].map(([e,t])=>`type ${e} = ${t}`).join("\n")}},d=(o,s,d)=>{for(let e of["$DomainEntityReflection","DomainComponentOpticBuilder","DomainContextSystems","DomainEntityReflection","EnhancedAliasReflection","EnumLike","RawAliasReflection","RuntimeExpressionContext","SchemaReflection","createActionFactory","createAssistantSetupHandlerFactory","createCustomExpressionFactory","createCustomInvariantFactory","createDataRowValidatorHandler","createMapPublishedChunkedDataHandlerFactory","createMapPublishedRevisionDataHandlerFactory","createRecipeFactory","createSheetValidatorHandler"])s.addTypeImport("@salsita-ai/sdk/domain",e);s.addTypeImport("@salsita-ai/sdk/configurator","createConfiguratorInterface");let l=t(o.configurator,""),p=t(o.admin,"Admin"),c=r(o),m=(e,t)=>t?`interface ${e} {
1
+ import{generateInvariantBlueprintMembers as e,getDomainFactoryTypes as t}from"../domain-spec/index.js";let a="@salsita-ai/sdk/configurator",n="CustomInvariantBlueprints",o="AdminCustomInvariantBlueprints",i=["authHandlerBuilder","webhookBuilder","taskFactory","finalizeHandlerBuilder","callbackBuilder","prefetchBuilder","dynamicResourcesFactory"],r=(e,t)=>e.replaceAll("\n",`
2
+ ${t}`),s=e=>{let t=(e.infra.resources??[]).map(e=>JSON.stringify(e.name));return["AnyDomainEntity","RootEntity","$Map","NavigationState","ViewState","ToolState","ExportState","PublishedData","SessionData","FrontendData","Admin.AnyDomainEntity","Admin.RootEntity","Admin.$Map","AdminNavigationState","never","FinalizeData","PrefetchedFinalizeData","FinalizeResult","CallbackData",t.length>0?[...new Set(t)].join(" | "):"never"].join(", ")},l=()=>{let e=new Map;return{member:(t,a)=>(e.set(t,a),t),declarations:()=>[...e].map(([e,t])=>`type ${e} = ${t}`).join("\n")}},d=(i,l,d)=>{for(let e of["$DomainEntityReflection","DomainComponentOpticBuilder","DomainContextSystems","DomainEntityReflection","EnhancedAliasReflection","EnumLike","RawAliasReflection","RuntimeExpressionContext","SchemaReflection","createActionFactory","createAssistantSetupHandlerFactory","createCustomExpressionFactory","createCustomInvariantFactory","createDataRowValidatorHandler","createMapPublishedChunkedDataHandlerFactory","createMapPublishedRevisionDataHandlerFactory","createRecipeFactory","createSheetValidatorHandler"])l.addTypeImport("@salsita-ai/sdk/domain",e);l.addTypeImport(a,"createConfiguratorInterface"),l.addTypeImport(a,"CreateAssistantFormElement");let p=t(i.configurator,""),m=t(i.admin,"Admin"),y=s(i),c=(e,t)=>t?`interface ${e} {
3
3
  ${t}
4
- }`:`interface ${e} {}`,{member:y}=d,u=`{
5
- readonly model: ${i(l.modelType," ")}
6
- readonly enhancedModel: ${i(l.enhancedModelType," ")}
7
- readonly implementCustomExpressions: ${y("PhxImplementCustomExpressions",`ReturnType<typeof createCustomExpressionFactory<${l.typeArguments}, ${l.contextExtension}>>`)}
8
- readonly implementCustomInvariants: ${y("PhxImplementCustomInvariants",`ReturnType<ReturnType<typeof createCustomInvariantFactory<${l.typeArguments}, ${a}, ${l.contextExtension}>>>`)}
9
- readonly implementActions: ${y("PhxImplementActions",`ReturnType<typeof createActionFactory<AnyDomainEntity, RootEntity, PublishedData, SessionData, FrontendData, ActionTypes, ${l.contextExtension}, ${l.systems}>>`)}
10
- readonly createAssistantSetupHandler: ${y("PhxCreateAssistantSetupHandler","ReturnType<typeof createAssistantSetupHandlerFactory<SessionData, AnyDomainEntity, $Map, ActionTypes>>")}
11
- readonly attachComponent: ${y("PhxAttachComponent",`ReturnType<typeof DomainComponentOpticBuilder.from<${l.typeArguments}, ${l.contextExtension}>>`)}
12
- readonly createRecipe: ${y("PhxCreateRecipe","ReturnType<typeof createRecipeFactory<AnyDomainEntity>>")}
4
+ }`:`interface ${e} {}`,{member:u}=d,$=`{
5
+ readonly model: ${r(p.modelType," ")}
6
+ readonly enhancedModel: ${r(p.enhancedModelType," ")}
7
+ readonly implementCustomExpressions: ${u("PhxImplementCustomExpressions",`ReturnType<typeof createCustomExpressionFactory<${p.typeArguments}, ${p.contextExtension}>>`)}
8
+ readonly implementCustomInvariants: ${u("PhxImplementCustomInvariants",`ReturnType<ReturnType<typeof createCustomInvariantFactory<${p.typeArguments}, ${n}, ${p.contextExtension}>>>`)}
9
+ readonly implementActions: ${u("PhxImplementActions",`ReturnType<typeof createActionFactory<AnyDomainEntity, RootEntity, PublishedData, SessionData, FrontendData, ActionTypes, ${p.contextExtension}, ${p.systems}>>`)}
10
+ readonly createAssistantSetupHandler: ${u("PhxCreateAssistantSetupHandler","ReturnType<typeof createAssistantSetupHandlerFactory<SessionData, AnyDomainEntity, $Map, ActionTypes>>")}
11
+ readonly attachComponent: ${u("PhxAttachComponent",`ReturnType<typeof DomainComponentOpticBuilder.from<${p.typeArguments}, ${p.contextExtension}>>`)}
12
+ readonly createRecipe: ${u("PhxCreateRecipe","ReturnType<typeof createRecipeFactory<AnyDomainEntity>>")}
13
13
  readonly admin: {
14
- readonly model: ${i(p.modelType," ")}
15
- readonly enhancedModel: ${i(p.enhancedModelType," ")}
16
- readonly implementCustomExpressions: ${y("PhxAdminImplementCustomExpressions",`ReturnType<typeof createCustomExpressionFactory<${p.typeArguments}, ${p.contextExtension}>>`)}
17
- readonly implementCustomInvariants: ${y("PhxAdminImplementCustomInvariants",`ReturnType<ReturnType<typeof createCustomInvariantFactory<${p.typeArguments}, ${n}, ${p.contextExtension}>>>`)}
18
- readonly attachComponent: ${y("PhxAdminAttachComponent",`ReturnType<typeof DomainComponentOpticBuilder.from<${p.typeArguments}, ${p.contextExtension}>>`)}
19
- readonly createMapPublishedRevisionDataHandler: ${y("PhxAdminCreateMapPublishedRevisionDataHandler","ReturnType<typeof createMapPublishedRevisionDataHandlerFactory<Admin.AnyDomainEntity, Admin.RootEntity, Admin.$Map, PublishedData>>")}
20
- readonly createMapPublishedChunkedDataHandler: ${y("PhxAdminCreateMapPublishedChunkedDataHandler","ReturnType<typeof createMapPublishedChunkedDataHandlerFactory<Admin.AnyDomainEntity, Admin.RootEntity, Admin.$Map>>")}
14
+ readonly model: ${r(m.modelType," ")}
15
+ readonly enhancedModel: ${r(m.enhancedModelType," ")}
16
+ readonly implementCustomExpressions: ${u("PhxAdminImplementCustomExpressions",`ReturnType<typeof createCustomExpressionFactory<${m.typeArguments}, ${m.contextExtension}>>`)}
17
+ readonly implementCustomInvariants: ${u("PhxAdminImplementCustomInvariants",`ReturnType<ReturnType<typeof createCustomInvariantFactory<${m.typeArguments}, ${o}, ${m.contextExtension}>>>`)}
18
+ readonly attachComponent: ${u("PhxAdminAttachComponent",`ReturnType<typeof DomainComponentOpticBuilder.from<${m.typeArguments}, ${m.contextExtension}>>`)}
19
+ readonly createMapPublishedRevisionDataHandler: ${u("PhxAdminCreateMapPublishedRevisionDataHandler","ReturnType<typeof createMapPublishedRevisionDataHandlerFactory<Admin.AnyDomainEntity, Admin.RootEntity, Admin.$Map, PublishedData>>")}
20
+ readonly createMapPublishedChunkedDataHandler: ${u("PhxAdminCreateMapPublishedChunkedDataHandler","ReturnType<typeof createMapPublishedChunkedDataHandlerFactory<Admin.AnyDomainEntity, Admin.RootEntity, Admin.$Map>>")}
21
21
  readonly createDataRowValidatorHandler: typeof createDataRowValidatorHandler
22
22
  readonly createSheetValidatorHandler: typeof createSheetValidatorHandler
23
- readonly createRecipe: ${y("PhxAdminCreateRecipe","ReturnType<typeof createRecipeFactory<Admin.AnyDomainEntity>>")}
23
+ readonly createRecipe: ${u("PhxAdminCreateRecipe","ReturnType<typeof createRecipeFactory<Admin.AnyDomainEntity>>")}
24
24
  }
25
- }`,$=y("PhxFrontend",`ReturnType<typeof createConfiguratorInterface<${c}>>`),{latestModel:h}=o.configurator;return{declarations:[m(a,e(o.configurator.invariants," ")),m(n,e(o.admin.invariants," "))].join("\n\n"),domainType:u,configuratorInterfaceType:$,applicationTypeNames:[...h.entityTypes.map(String),...[...h.aliases].map(([e])=>String(e)),...[...h.commonTypes].map(([e])=>String(e)),...h.entityTypes.map(e=>`$${String(e)}`),...[...h.aliases].map(([e])=>`$${String(e)}`),"Aliases","$Map","ActionTypes","Admin","PublishedData","SessionData","FrontendData","BackendData","FinalizeData","PrefetchedFinalizeData","FinalizeResult","CallbackData","NavigationState","ViewState","ToolState","ExportState","AdminNavigationState"]}};export const generatePhxTypes=(e,t)=>{let a=s(),n=d(e,t,a);return{...n,declarations:`${n.declarations}
25
+ }`,A=u("PhxFrontend",`ReturnType<typeof createConfiguratorInterface<${y}>> & {
26
+ readonly createAssistantFormElement: CreateAssistantFormElement<AssistantFormElementTypes>
27
+ }`),{latestModel:h}=i.configurator;return{declarations:[c(n,e(i.configurator.invariants," ")),c(o,e(i.admin.invariants," "))].join("\n\n"),domainType:$,configuratorInterfaceType:A,applicationTypeNames:[...h.entityTypes.map(String),...[...h.aliases].map(([e])=>String(e)),...[...h.commonTypes].map(([e])=>String(e)),...h.entityTypes.map(e=>`$${String(e)}`),...[...h.aliases].map(([e])=>`$${String(e)}`),"Aliases","$Map","ActionTypes","AssistantFormElementTypes","Admin","PublishedData","SessionData","FrontendData","BackendData","FinalizeData","PrefetchedFinalizeData","FinalizeResult","CallbackData","NavigationState","ViewState","ToolState","ExportState","AdminNavigationState"]}};export const generatePhxTypes=(e,t)=>{let a=l(),n=d(e,t,a);return{...n,declarations:`${n.declarations}
26
28
 
27
- ${a.declarations()}`}};export const generateGlobalPhxTypes=(e,t)=>{let a=s(),{member:n}=a,i=d(e,t,a);t.addTypeImport("@salsita-ai/sdk/admin","createAdminInterface"),t.addTypeImport("@salsita-ai/sdk/webhook","createDomainWebhook");let l=r(e),p=n("PhxFrontendAdmin",`ReturnType<typeof createAdminInterface<${l}>>`),c=n("PhxWebhookBuilders",`ReturnType<typeof createDomainWebhook<${l}>>`),m=o.map(e=>` readonly ${e}: ${n(`PhxWebhooks${e.charAt(0).toUpperCase()}${e.slice(1)}`,`${c}['${e}']`)}`);return{...i,declarations:`${i.declarations}
29
+ ${a.declarations()}`}};export const generateGlobalPhxTypes=(e,t)=>{let a=l(),{member:n}=a,o=d(e,t,a);t.addTypeImport("@salsita-ai/sdk/admin","createAdminInterface"),t.addTypeImport("@salsita-ai/sdk/webhook","createDomainWebhook");let r=s(e),p=n("PhxFrontendAdmin",`ReturnType<typeof createAdminInterface<${r}>>`),m=n("PhxWebhookBuilders",`ReturnType<typeof createDomainWebhook<${r}>>`),y=i.map(e=>` readonly ${e}: ${n(`PhxWebhooks${e.charAt(0).toUpperCase()}${e.slice(1)}`,`${m}['${e}']`)}`);return{...o,declarations:`${o.declarations}
28
30
 
29
31
  ${a.declarations()}`,adminInterfaceType:p,webhooksType:`{
30
- ${m.join("\n")}
32
+ ${y.join("\n")}
31
33
  }`}};
@@ -1,4 +1,5 @@
1
1
  export { generateActionTypeDecls } from './generate-action-types.js';
2
+ export { generateAssistantFormElementTypeDecls } from './generate-assistant-form-element-types.js';
2
3
  export { generateModelTypeDecls } from './generate-model-types.js';
3
4
  export { generateExpressionTypeDecls, generateEntityExpressionComposites } from './generate-expression-types.js';
4
5
  export { generateDataSchemaTypeDecls } from './generate-data-schema-types.js';
@@ -1 +1 @@
1
- export{generateActionTypeDecls}from"./generate-action-types.js";export{generateModelTypeDecls}from"./generate-model-types.js";export{generateExpressionTypeDecls,generateEntityExpressionComposites}from"./generate-expression-types.js";export{generateDataSchemaTypeDecls}from"./generate-data-schema-types.js";export{generateGlobalPhxTypes,generatePhxTypes}from"./generate-phx-types.js";
1
+ export{generateActionTypeDecls}from"./generate-action-types.js";export{generateAssistantFormElementTypeDecls}from"./generate-assistant-form-element-types.js";export{generateModelTypeDecls}from"./generate-model-types.js";export{generateExpressionTypeDecls,generateEntityExpressionComposites}from"./generate-expression-types.js";export{generateDataSchemaTypeDecls}from"./generate-data-schema-types.js";export{generateGlobalPhxTypes,generatePhxTypes}from"./generate-phx-types.js";
@@ -40,12 +40,19 @@ Without a lockfile, use the package manager the \`packageManager\` field of \`pa
40
40
  - \`src/components/\` — ECS system components (\`phx.domain.attachComponent.withEntity()\`)
41
41
  - \`src/elements/\` — Page-level React components (\`phx.frontend.createCustomPhoenixLayoutElement()\`)
42
42
  - \`ConfiguratorLayout\`: a layout element with this name replaces everything the built-in layout renders for a loaded configuration, in owner and read mode, finalization included. Prefer arranging the spec's layout components; write one for shell-level changes, such as moving the sidebar or adding an area the built-in layout has no place for
43
- - Mount \`LayoutSlots.SharedCanvas\` (from \`@salsita-ai/sdk/configurator\`) in a positioned root covering the page, or the app loader stays on screen; put the UI above it, positioned and after it in the markup. Call \`useSceneSafeArea()\` (same import) and put \`containerRef\` on the element covering the whole canvas and \`safeAreaRef\` on the region the UI leaves free, with \`pointerEvents: 'none'\`, so the camera frames the scene there
43
+ - Mount \`LayoutSlots.SharedCanvas\` (from \`@salsita-ai/sdk/configurator\`) in a positioned root covering the page; put the UI above it, positioned and after it in the markup. With the canvas mounted the app loader waits until the scene has loaded; a layout without a canvas is not held by the loader. Call \`phx.frontend.useSceneSafeArea()\` and put \`containerRef\` on the element covering the whole canvas and \`safeAreaRef\` on the region the UI leaves free, with \`pointerEvents: 'none'\`, so the camera frames the scene there
44
44
  - Sidebar moved, contents as the spec configures them: mount \`LayoutSlots.DesktopSidebar\` in a positioned container that sets its size, with \`side="start"\` on the left; \`docs/layouts/sidebar/in-a-custom-layout.mdx\` is the whole layout
45
- - Your own UI: "Hooks for a Project Layout" in \`docs/phoenix/configurator-interface.mdx\` lists the hooks with what each returns (\`pnpm phoenix docs -r docs/phoenix/configurator-interface.mdx\`), \`docs/phoenix/layout-slots.mdx\` the built-in pieces you can still mount, and \`docs/layouts/custom-layout.mdx\` is a worked example
46
- - Messages: mount \`LayoutSlots.Services\` for the built-in snackbars, or show violations, side-effect hints and errors yourself with \`phx.frontend.useConfiguratorMessages(onMessage)\`, not both. Either way mount a snackbar root (\`LayoutSlots.DesktopSnackbarsRoot\` or \`LayoutSlots.MobileSnackbarsRoot\`): save and built-in action errors are always snackbars
47
- - Finalize over the spec's \`finalizeAction\` components, each naming a handler registered with \`phx.frontend.createPhoenixHandler\`: run each with \`phx.frontend.useFinalizeAction(handler)\` in a component of its own wrapped in \`PhoenixHandlerBoundary\` (from \`@salsita-ai/sdk/react\`), or mount \`FinalizeActions\` (from \`@salsita-ai/sdk/configurator\`) for the built-in buttons. \`finalizePage\` and \`finalizeButton\` are legacy
48
- - Read mode and fullscreen are the layout's job, no hook enforces them: hide what a viewer must not change while \`phx.frontend.useAccessService().accessInfo.viewMode\` is \`true\`, and remove panels while \`phx.frontend.useIsFullscreenActive()\` is set; \`phx.frontend.useSetFullscreen()\` returns its setter
45
+ - Your own UI: "Hooks for a Project Layout" in \`docs/phoenix/configurator-interface.mdx\` lists the hooks with what each returns (\`pnpm phoenix docs -r docs/phoenix/configurator-interface.mdx\`), \`docs/phoenix/layout-slots.mdx\` the built-in pieces you can still mount, and \`docs/layouts/custom-layout.mdx\` is a worked example. Call the hooks as \`phx.frontend.useX()\`; besides those below, these are often needed: \`usePreview()\` (\`isPreview\` while the preview start screen shows), \`useCloseAction()\` (the host's close action or \`null\`), \`useActiveViewports()\` (the container's breakpoints, \`null\` until measured, \`desktop\` above 768 px: the desktop/phone switch), \`useResolveLocalizable()\` and \`useLocalizable(text)\` (spec texts to strings), \`useIsCloningAllowed()\` (a read-mode "edit a copy" action with \`LayoutSlots.CloneToEditDialog\`)
46
+ - Undo and redo: \`phx.frontend.useUndoRedo()\` returns \`{ canUndo, canRedo, undo, redo }\`; disable each button from \`canUndo\`/\`canRedo\`
47
+ - Tabs: \`phx.frontend.useTabNavigation()\` returns \`{ source, tabs, activeTab, select }\` for the spec's \`sidebarTabs\` (of the selected entity) or \`horizontalTabs\`; render \`tabs\` (each \`{ index, label, icon, state, isActive }\`, \`icon\` a PhxIcon name) and call \`select(tab.index)\` on click. Pass \`{ source: 'sidebarTabs' }\` or \`{ source: 'horizontalTabs' }\` when the layout shows one kind only. Not \`LayoutSlots.useSidebarTabs()\`: it serves the built-in sidebar and returns no tabs while its summary shows
48
+ - Steps: \`phx.frontend.useStepNavigation()\` returns \`{ steps, activeStep, activeIndex, isFirst, isLast, canGoNext, canGoPrevious, next, previous, goTo }\` for the spec's \`navigationSteps\`; render \`steps\` (each \`{ index, label, state, status }\`, \`status\` \`'complete' | 'active' | 'upcoming'\`), call \`next()\`/\`previous()\` for Back and Next and \`goTo(step.index)\` from a stepper. It enforces no order and no validity: enable only \`'complete'\` steps for an "earlier steps only" stepper, and to block moving on while the configuration has a problem, require \`phx.frontend.useStateValidity().severity !== 'warning'\` besides \`canGoNext\`: a change with a \`fixable\` or \`fatal\` violation is rejected, so the configuration is never invalid, and a \`warning\` is the problem that stays (it blocks finalizing too). \`useSteps\` and \`useHasSteps\` from \`@salsita-ai/sdk/configurator\` are deprecated
49
+ - Messages: mount \`LayoutSlots.Services\` for the built-in snackbars, or show violations, side-effect hints, errors and failed saves yourself with \`phx.frontend.useConfiguratorMessages(onMessage)\`, not both. A failed save arrives as \`saveError\`, the next successful save as \`saveRecovery\`; a layout that mounts neither shows no sign of a failed save. Either way mount a snackbar root (\`LayoutSlots.DesktopSnackbarsRoot\` or \`LayoutSlots.MobileSnackbarsRoot\`): errors of the built-in actions are always snackbars
50
+ - Finalize over the spec's \`finalizeAction\` components, each naming a handler registered with \`phx.frontend.createPhoenixHandler\`: \`phx.frontend.useFinalizeActions()\` returns \`{ actions, primary, secondary, disabled, hints }\`; render \`primary\` (and \`secondary\` in a menu or list) in a loop, each action \`{ key, label, title, icon, run, isPending, error, disabled }\`, and call \`action.run()\` on click (its promise never rejects; show \`action.error\` on failure). The configurator runs the handlers itself, outside the layout, so a handler must not rely on a provider the layout adds. For one known handler, \`phx.frontend.useFinalizeAction(handler)\` in a component wrapped in \`PhoenixHandlerBoundary\` (from \`@salsita-ai/sdk/react\`) works too; \`FinalizeActions\` (from \`@salsita-ai/sdk/configurator\`) mounts the built-in buttons. \`finalizePage\` and \`finalizeButton\` are legacy
51
+ - Read mode and fullscreen are the layout's job, no hook enforces them (\`useUndoRedo\`, \`useFinalizeActions\` and \`useStepNavigation\` included): hide undo, redo, finalization and whatever else a viewer must not change while \`phx.frontend.useAccessService().accessInfo.viewMode\` is \`true\` (tabs are navigation, so a viewer may switch them), and remove panels while \`phx.frontend.useIsFullscreenActive()\` is set; \`phx.frontend.useSetFullscreen()\` returns its setter
52
+ - \`ConfigurationNotFoundPage\`: \`phx.frontend.createConfigurationNotFoundPage(({ onBack }) => …)\` replaces the "configuration not accessible" page; show a way back only when the optional \`onBack\` is set. The not-authenticated page's default renders it too; only the admin's not-authorized page keeps the built-in page
53
+ - \`ConfiguratorErrorPage\`: \`phx.frontend.createConfiguratorErrorPage(({ reason, onRetry }) => …)\` replaces the production error page; \`reason\` is \`uncaughtError\` or \`presetCreationFailed\`. A page that throws falls back to the built-in one, and development keeps the detailed error pages, so the project page shows only in a production build. Register both pages with these helpers: \`createCustomPhoenixLayoutElement\` with the name works too, but types the component as taking only \`children\`, so the typed props do not compile there in a strict project
54
+ - \`AppLoaderContent\`: \`phx.frontend.createAppLoader(({ phases }) => …)\` replaces what the loading overlay shows (each phase \`{ id, label?, progress? }\`, the list possibly empty); Phoenix keeps the overlay itself
55
+ - Assistant form elements: an element declared under \`assistant.formElements\` (\`description\`, \`role\`, scalar \`attributes\` beside the built-in \`label\`, a \`value\` included, \`required\`) is the default export \`phx.frontend.createAssistantFormElement('name', Component)\` of one file; the name types the component's props by its role (\`AssistantFormElementProps<'name'>\`): an option reports its answer with \`onSelect(answer)\`, an input with \`onChange(state, answer)\`; and the application does not start while a declared element has no registration or a registration no declaration
49
56
  - \`src/handlers/\` — Event & lifecycle handlers
50
57
  - \`src/webhooks/\` — Server-side webhook handlers (\`phx.webhooks.*Builder\`); the webhook is the default export of \`src/webhooks/index.ts\`, which you create when the project needs its own handlers — without it the build uses a built-in inert webhook that answers only anonymous auth, so create the file before setting \`useAuthHook\` or \`useClerk\`
51
58
  - \`src/migrations/\` — Schema version migrations (v*.ts)
@@ -87,7 +94,7 @@ The default export must be what the folder's phx factory returns (for example \`
87
94
  readonly webhookMembership: `## Webhook Membership
88
95
  - User-authored components, admin components, and handlers are frontend-only by default.
89
96
  - A handler that registers \`phx.domain.createAssistantSetupHandler\`, \`createMapPublishedRevisionDataHandler\`, \`createMapPublishedChunkedDataHandler\`, \`createDataRowValidatorHandler\`, or \`createSheetValidatorHandler\` is included in the webhook automatically.
90
- - An assistant setup handler receives the declaration-shaped whitelist and { role, sessionData, access }. Keep the exact entity/alias split from YAML; inherited fields and expanded member entries are absent. Narrow original declarations, then the SDK expands them. Use project-defined role/session data for per-user customization. Keep the handler synchronous, pure and deterministic. The handler runs in the browser and webhook. Return null to disable assistant execution, or omit whitelist entries to restrict them. Button and panel visibility use spec presence; project developers own dynamic UI filtering through normal layout mechanics such as $filter. Leaves expose optional descriptions; writable options allow only validate: true and allowDryRuns: false; recipe groups allow descriptions and allowDryRuns: false. Deletable entries are {}. Names, component bindings, hints and types are internal. Omitted overrides retain baseline values. Existing entity, enhanced-entity and action types constrain the handler; no separate generated manifest types. Browser GraphQL, tools and change recording use the session-derived manifest; rejected setup fails closed. UI reads the pure spec selector. Omitted server instructions or AI fields preserve the baseline. An empty server instructions string clears it.
97
+ - An assistant setup handler receives the declaration-shaped whitelist and { role, sessionData, access }. Keep the exact entity/alias split from YAML; inherited fields and expanded member entries are absent. Narrow original declarations, then the SDK expands them. Use project-defined role/session data for per-user customization. Keep the handler synchronous, pure and deterministic. The handler runs in the browser and webhook. Return null to disable assistant execution, or omit whitelist entries to restrict them. Button and panel visibility use spec presence; project developers own dynamic UI filtering through normal layout mechanics such as $filter. Leaves expose optional descriptions; writable options allow only validate: true and allowDryRuns: false; recipe groups allow descriptions and allowDryRuns: false; screenshot views allow descriptions. Deletable entries are {}. Names, component bindings, hints and types are internal. Omitted overrides retain baseline values. Existing entity, enhanced-entity and action types constrain the handler; no separate generated manifest types. Browser GraphQL, tools and change recording use the session-derived manifest; rejected setup fails closed. UI reads the pure spec selector. Omitted server instructions or AI fields preserve the baseline. An empty server instructions string clears it.
91
98
  - To include another component or handler in the webhook, put \`'use webhook'\` as its first statement (leading comments are allowed).
92
99
  - A webhook-included file and its runtime local-import closure must not import browser SDK entrypoints (\`application\`, \`admin\`, \`configurator\`, \`editor\`, \`react\`, \`ui\`) or style/font/image assets. Spec parsing reports the unsafe import and inclusion reason as a diagnostic.
93
100
  - Keep browser rendering in an unpinned file. Move shared server-safe logic into a separate module when both frontend and webhook code need it.`;
@@ -1,10 +1,10 @@
1
- export const sdkGuidanceSections={packageManager:"## Package Manager\nThe project installs with its own package manager, and the commands in this skill are written for pnpm. Run them through the package manager the project uses, which the lockfile in the project root names:\n- `pnpm-lock.yaml`: `pnpm phoenix <command>`, `pnpm install`, `pnpm add <package>`\n- `package-lock.json`: `npx phoenix <command>`, `npm install`, `npm install <package>`\n- `yarn.lock`: `yarn phoenix <command>`, `yarn install`, `yarn add <package>`\n- `bun.lock` or `bun.lockb`: `bunx phoenix <command>`, `bun install`, `bun add <package>`\n\nWithout a lockfile, use the package manager the `packageManager` field of `package.json` names, or ask the user.",buildCommands:"## Build Commands\n- `pnpm phoenix build` — Full production build\n- `pnpm phoenix dev` — Development mode with hot reload\n- `pnpm phoenix sync` — Sync generated files without full build\n- `pnpm phoenix deps` — Add the SDK's missing peer dependencies to `package.json` and move out-of-range ones into the SDK's range; it installs nothing, so install after it",devLogs:"## Dev Logs\n- `pnpm phoenix dev` writes all logs to `.phoenix/phoenix-dev.log`\n- Contains: spec parse errors, build errors, browser runtime errors, file watcher events\n- After making changes, always check the log for errors: `tail -50 .phoenix/phoenix-dev.log` or `grep ERROR .phoenix/phoenix-dev.log`\n- Rotated automatically at 10MB (`.log.1`, `.log.2` are older rotations)",projectStructure:"## Project Structure\n- `spec/` — Domain YAML specs (entities, relations, expressions, invariants, components, application config)\n- `src/expressions/` — Computed/derived entity properties (`phx.domain.implementCustomExpressions()`)\n- `src/actions/` — Domain operations declared under `actions:` in the spec (`phx.domain.implementActions()`), run by controls and exposed to the assistant\n- `src/invariants/` — Business rule constraints (`phx.domain.implementCustomInvariants()`)\n- `src/transformers/` — Automatic state fixers (`phx.frontend.transformerBuilder`)\n- `src/components/` — ECS system components (`phx.domain.attachComponent.withEntity()`)\n- `src/elements/` — Page-level React components (`phx.frontend.createCustomPhoenixLayoutElement()`)\n - `ConfiguratorLayout`: a layout element with this name replaces everything the built-in layout renders for a loaded configuration, in owner and read mode, finalization included. Prefer arranging the spec's layout components; write one for shell-level changes, such as moving the sidebar or adding an area the built-in layout has no place for\n - Mount `LayoutSlots.SharedCanvas` (from `@salsita-ai/sdk/configurator`) in a positioned root covering the page, or the app loader stays on screen; put the UI above it, positioned and after it in the markup. Call `useSceneSafeArea()` (same import) and put `containerRef` on the element covering the whole canvas and `safeAreaRef` on the region the UI leaves free, with `pointerEvents: 'none'`, so the camera frames the scene there\n - Sidebar moved, contents as the spec configures them: mount `LayoutSlots.DesktopSidebar` in a positioned container that sets its size, with `side=\"start\"` on the left; `docs/layouts/sidebar/in-a-custom-layout.mdx` is the whole layout\n - Your own UI: \"Hooks for a Project Layout\" in `docs/phoenix/configurator-interface.mdx` lists the hooks with what each returns (`pnpm phoenix docs -r docs/phoenix/configurator-interface.mdx`), `docs/phoenix/layout-slots.mdx` the built-in pieces you can still mount, and `docs/layouts/custom-layout.mdx` is a worked example\n - Messages: mount `LayoutSlots.Services` for the built-in snackbars, or show violations, side-effect hints and errors yourself with `phx.frontend.useConfiguratorMessages(onMessage)`, not both. Either way mount a snackbar root (`LayoutSlots.DesktopSnackbarsRoot` or `LayoutSlots.MobileSnackbarsRoot`): save and built-in action errors are always snackbars\n - Finalize over the spec's `finalizeAction` components, each naming a handler registered with `phx.frontend.createPhoenixHandler`: run each with `phx.frontend.useFinalizeAction(handler)` in a component of its own wrapped in `PhoenixHandlerBoundary` (from `@salsita-ai/sdk/react`), or mount `FinalizeActions` (from `@salsita-ai/sdk/configurator`) for the built-in buttons. `finalizePage` and `finalizeButton` are legacy\n - Read mode and fullscreen are the layout's job, no hook enforces them: hide what a viewer must not change while `phx.frontend.useAccessService().accessInfo.viewMode` is `true`, and remove panels while `phx.frontend.useIsFullscreenActive()` is set; `phx.frontend.useSetFullscreen()` returns its setter\n- `src/handlers/` — Event & lifecycle handlers\n- `src/webhooks/` — Server-side webhook handlers (`phx.webhooks.*Builder`); the webhook is the default export of `src/webhooks/index.ts`, which you create when the project needs its own handlers — without it the build uses a built-in inert webhook that answers only anonymous auth, so create the file before setting `useAuthHook` or `useClerk`\n- `src/migrations/` — Schema version migrations (v*.ts)\n- `src/locales/` — Locale catalogs (authored .po sources; compiled .ts, do not edit)\n- `src/admin/` — Admin interface (mirrors main src/ structure)\n- `src/_shared/` — Shared utilities (NOT auto-imported, requires explicit imports)\n- `.phoenix/` — Auto-generated files (DO NOT EDIT, except the option files in `.phoenix/variants/`)\n- `public/` — Static assets (3D models, textures, images, HDRI maps, fonts)\n- `assets/` — Uploadable resources (PDF templates, email assets)",architecturePrinciples:"## Architecture Principles\n- YAML-first: 99% of configuration in spec/*.yaml, custom code is last resort\n- ECS pattern: entities (domain objects) + components (behavior/UI) + systems (SDK runtime)\n- Reactive state: immutable domain state flows through RxJS pipelines\n- Data binding: `$read` (read-only), `$write` (write-only), `$bind` (bidirectional) connect components to domain\n- memoEval: all component implementations must use memoEval for stable object references",keyPatterns:"## Key Patterns\n- Expressions = computed properties on entities (prefix: `$`), implemented per-entity in src/expressions/\n- Actions = named domain operations (`actions:` in YAML with `params` and `result` schemas), implemented in src/actions/, prepared through `actionSystem.prepareAction()` and exposed as assistant mutations through `assistant.actions`\n- Invariants = validation rules returning violations, static or dynamic\n- Transformers = auto-fixers maintaining consistency after state changes\n- Components defined in YAML with `$read`/`$bind` bindings, or custom in src/components/ using attachComponent builder\n- Webhooks = server-side finalization tasks (PDF, email, CSV, image rendering)\n- Filters = contextual component activation via navigationStates, viewStates, modes, selectedEntityIds",fileConventions:`## File Conventions
1
+ export const sdkGuidanceSections={packageManager:"## Package Manager\nThe project installs with its own package manager, and the commands in this skill are written for pnpm. Run them through the package manager the project uses, which the lockfile in the project root names:\n- `pnpm-lock.yaml`: `pnpm phoenix <command>`, `pnpm install`, `pnpm add <package>`\n- `package-lock.json`: `npx phoenix <command>`, `npm install`, `npm install <package>`\n- `yarn.lock`: `yarn phoenix <command>`, `yarn install`, `yarn add <package>`\n- `bun.lock` or `bun.lockb`: `bunx phoenix <command>`, `bun install`, `bun add <package>`\n\nWithout a lockfile, use the package manager the `packageManager` field of `package.json` names, or ask the user.",buildCommands:"## Build Commands\n- `pnpm phoenix build` — Full production build\n- `pnpm phoenix dev` — Development mode with hot reload\n- `pnpm phoenix sync` — Sync generated files without full build\n- `pnpm phoenix deps` — Add the SDK's missing peer dependencies to `package.json` and move out-of-range ones into the SDK's range; it installs nothing, so install after it",devLogs:"## Dev Logs\n- `pnpm phoenix dev` writes all logs to `.phoenix/phoenix-dev.log`\n- Contains: spec parse errors, build errors, browser runtime errors, file watcher events\n- After making changes, always check the log for errors: `tail -50 .phoenix/phoenix-dev.log` or `grep ERROR .phoenix/phoenix-dev.log`\n- Rotated automatically at 10MB (`.log.1`, `.log.2` are older rotations)",projectStructure:"## Project Structure\n- `spec/` — Domain YAML specs (entities, relations, expressions, invariants, components, application config)\n- `src/expressions/` — Computed/derived entity properties (`phx.domain.implementCustomExpressions()`)\n- `src/actions/` — Domain operations declared under `actions:` in the spec (`phx.domain.implementActions()`), run by controls and exposed to the assistant\n- `src/invariants/` — Business rule constraints (`phx.domain.implementCustomInvariants()`)\n- `src/transformers/` — Automatic state fixers (`phx.frontend.transformerBuilder`)\n- `src/components/` — ECS system components (`phx.domain.attachComponent.withEntity()`)\n- `src/elements/` — Page-level React components (`phx.frontend.createCustomPhoenixLayoutElement()`)\n - `ConfiguratorLayout`: a layout element with this name replaces everything the built-in layout renders for a loaded configuration, in owner and read mode, finalization included. Prefer arranging the spec's layout components; write one for shell-level changes, such as moving the sidebar or adding an area the built-in layout has no place for\n - Mount `LayoutSlots.SharedCanvas` (from `@salsita-ai/sdk/configurator`) in a positioned root covering the page; put the UI above it, positioned and after it in the markup. With the canvas mounted the app loader waits until the scene has loaded; a layout without a canvas is not held by the loader. Call `phx.frontend.useSceneSafeArea()` and put `containerRef` on the element covering the whole canvas and `safeAreaRef` on the region the UI leaves free, with `pointerEvents: 'none'`, so the camera frames the scene there\n - Sidebar moved, contents as the spec configures them: mount `LayoutSlots.DesktopSidebar` in a positioned container that sets its size, with `side=\"start\"` on the left; `docs/layouts/sidebar/in-a-custom-layout.mdx` is the whole layout\n - Your own UI: \"Hooks for a Project Layout\" in `docs/phoenix/configurator-interface.mdx` lists the hooks with what each returns (`pnpm phoenix docs -r docs/phoenix/configurator-interface.mdx`), `docs/phoenix/layout-slots.mdx` the built-in pieces you can still mount, and `docs/layouts/custom-layout.mdx` is a worked example. Call the hooks as `phx.frontend.useX()`; besides those below, these are often needed: `usePreview()` (`isPreview` while the preview start screen shows), `useCloseAction()` (the host's close action or `null`), `useActiveViewports()` (the container's breakpoints, `null` until measured, `desktop` above 768 px: the desktop/phone switch), `useResolveLocalizable()` and `useLocalizable(text)` (spec texts to strings), `useIsCloningAllowed()` (a read-mode \"edit a copy\" action with `LayoutSlots.CloneToEditDialog`)\n - Undo and redo: `phx.frontend.useUndoRedo()` returns `{ canUndo, canRedo, undo, redo }`; disable each button from `canUndo`/`canRedo`\n - Tabs: `phx.frontend.useTabNavigation()` returns `{ source, tabs, activeTab, select }` for the spec's `sidebarTabs` (of the selected entity) or `horizontalTabs`; render `tabs` (each `{ index, label, icon, state, isActive }`, `icon` a PhxIcon name) and call `select(tab.index)` on click. Pass `{ source: 'sidebarTabs' }` or `{ source: 'horizontalTabs' }` when the layout shows one kind only. Not `LayoutSlots.useSidebarTabs()`: it serves the built-in sidebar and returns no tabs while its summary shows\n - Steps: `phx.frontend.useStepNavigation()` returns `{ steps, activeStep, activeIndex, isFirst, isLast, canGoNext, canGoPrevious, next, previous, goTo }` for the spec's `navigationSteps`; render `steps` (each `{ index, label, state, status }`, `status` `'complete' | 'active' | 'upcoming'`), call `next()`/`previous()` for Back and Next and `goTo(step.index)` from a stepper. It enforces no order and no validity: enable only `'complete'` steps for an \"earlier steps only\" stepper, and to block moving on while the configuration has a problem, require `phx.frontend.useStateValidity().severity !== 'warning'` besides `canGoNext`: a change with a `fixable` or `fatal` violation is rejected, so the configuration is never invalid, and a `warning` is the problem that stays (it blocks finalizing too). `useSteps` and `useHasSteps` from `@salsita-ai/sdk/configurator` are deprecated\n - Messages: mount `LayoutSlots.Services` for the built-in snackbars, or show violations, side-effect hints, errors and failed saves yourself with `phx.frontend.useConfiguratorMessages(onMessage)`, not both. A failed save arrives as `saveError`, the next successful save as `saveRecovery`; a layout that mounts neither shows no sign of a failed save. Either way mount a snackbar root (`LayoutSlots.DesktopSnackbarsRoot` or `LayoutSlots.MobileSnackbarsRoot`): errors of the built-in actions are always snackbars\n - Finalize over the spec's `finalizeAction` components, each naming a handler registered with `phx.frontend.createPhoenixHandler`: `phx.frontend.useFinalizeActions()` returns `{ actions, primary, secondary, disabled, hints }`; render `primary` (and `secondary` in a menu or list) in a loop, each action `{ key, label, title, icon, run, isPending, error, disabled }`, and call `action.run()` on click (its promise never rejects; show `action.error` on failure). The configurator runs the handlers itself, outside the layout, so a handler must not rely on a provider the layout adds. For one known handler, `phx.frontend.useFinalizeAction(handler)` in a component wrapped in `PhoenixHandlerBoundary` (from `@salsita-ai/sdk/react`) works too; `FinalizeActions` (from `@salsita-ai/sdk/configurator`) mounts the built-in buttons. `finalizePage` and `finalizeButton` are legacy\n - Read mode and fullscreen are the layout's job, no hook enforces them (`useUndoRedo`, `useFinalizeActions` and `useStepNavigation` included): hide undo, redo, finalization and whatever else a viewer must not change while `phx.frontend.useAccessService().accessInfo.viewMode` is `true` (tabs are navigation, so a viewer may switch them), and remove panels while `phx.frontend.useIsFullscreenActive()` is set; `phx.frontend.useSetFullscreen()` returns its setter\n - `ConfigurationNotFoundPage`: `phx.frontend.createConfigurationNotFoundPage(({ onBack }) => …)` replaces the \"configuration not accessible\" page; show a way back only when the optional `onBack` is set. The not-authenticated page's default renders it too; only the admin's not-authorized page keeps the built-in page\n - `ConfiguratorErrorPage`: `phx.frontend.createConfiguratorErrorPage(({ reason, onRetry }) => …)` replaces the production error page; `reason` is `uncaughtError` or `presetCreationFailed`. A page that throws falls back to the built-in one, and development keeps the detailed error pages, so the project page shows only in a production build. Register both pages with these helpers: `createCustomPhoenixLayoutElement` with the name works too, but types the component as taking only `children`, so the typed props do not compile there in a strict project\n - `AppLoaderContent`: `phx.frontend.createAppLoader(({ phases }) => …)` replaces what the loading overlay shows (each phase `{ id, label?, progress? }`, the list possibly empty); Phoenix keeps the overlay itself\n - Assistant form elements: an element declared under `assistant.formElements` (`description`, `role`, scalar `attributes` beside the built-in `label`, a `value` included, `required`) is the default export `phx.frontend.createAssistantFormElement('name', Component)` of one file; the name types the component's props by its role (`AssistantFormElementProps<'name'>`): an option reports its answer with `onSelect(answer)`, an input with `onChange(state, answer)`; and the application does not start while a declared element has no registration or a registration no declaration\n- `src/handlers/` — Event & lifecycle handlers\n- `src/webhooks/` — Server-side webhook handlers (`phx.webhooks.*Builder`); the webhook is the default export of `src/webhooks/index.ts`, which you create when the project needs its own handlers — without it the build uses a built-in inert webhook that answers only anonymous auth, so create the file before setting `useAuthHook` or `useClerk`\n- `src/migrations/` — Schema version migrations (v*.ts)\n- `src/locales/` — Locale catalogs (authored .po sources; compiled .ts, do not edit)\n- `src/admin/` — Admin interface (mirrors main src/ structure)\n- `src/_shared/` — Shared utilities (NOT auto-imported, requires explicit imports)\n- `.phoenix/` — Auto-generated files (DO NOT EDIT, except the option files in `.phoenix/variants/`)\n- `public/` — Static assets (3D models, textures, images, HDRI maps, fonts)\n- `assets/` — Uploadable resources (PDF templates, email assets)",architecturePrinciples:"## Architecture Principles\n- YAML-first: 99% of configuration in spec/*.yaml, custom code is last resort\n- ECS pattern: entities (domain objects) + components (behavior/UI) + systems (SDK runtime)\n- Reactive state: immutable domain state flows through RxJS pipelines\n- Data binding: `$read` (read-only), `$write` (write-only), `$bind` (bidirectional) connect components to domain\n- memoEval: all component implementations must use memoEval for stable object references",keyPatterns:"## Key Patterns\n- Expressions = computed properties on entities (prefix: `$`), implemented per-entity in src/expressions/\n- Actions = named domain operations (`actions:` in YAML with `params` and `result` schemas), implemented in src/actions/, prepared through `actionSystem.prepareAction()` and exposed as assistant mutations through `assistant.actions`\n- Invariants = validation rules returning violations, static or dynamic\n- Transformers = auto-fixers maintaining consistency after state changes\n- Components defined in YAML with `$read`/`$bind` bindings, or custom in src/components/ using attachComponent builder\n- Webhooks = server-side finalization tasks (PDF, email, CSV, image rendering)\n- Filters = contextual component activation via navigationStates, viewStates, modes, selectedEntityIds",fileConventions:`## File Conventions
2
2
  - Components: PascalCase (.tsx)
3
3
  - Utilities: kebab-case (.ts)
4
4
  - Expressions: entity-name.ts
5
5
  - Migrations: v*.ts (sequential)
6
6
  - Specs: kebab-case.yaml
7
- - Underscore folders (_shared/, _utils/) are NOT auto-imported`,exportRules:'## Export Rules\nAll files in src/expressions/, src/actions/, src/invariants/, src/transformers/, src/components/, src/handlers/, src/elements/, src/webhooks/ MUST use default exports. Can be a single item or an array. Named exports are ignored by the SDK auto-import system.\nThe default export must be what the folder\'s phx factory returns (for example `phx.frontend.createCustomPhoenixLayoutElement()` in src/elements/). Any other value, such as a plain React component, stops the application at start with an "Invalid default export in <file>" error. Put plain components and helpers in an underscore folder.',webhookMembership:"## Webhook Membership\n- User-authored components, admin components, and handlers are frontend-only by default.\n- A handler that registers `phx.domain.createAssistantSetupHandler`, `createMapPublishedRevisionDataHandler`, `createMapPublishedChunkedDataHandler`, `createDataRowValidatorHandler`, or `createSheetValidatorHandler` is included in the webhook automatically.\n- An assistant setup handler receives the declaration-shaped whitelist and { role, sessionData, access }. Keep the exact entity/alias split from YAML; inherited fields and expanded member entries are absent. Narrow original declarations, then the SDK expands them. Use project-defined role/session data for per-user customization. Keep the handler synchronous, pure and deterministic. The handler runs in the browser and webhook. Return null to disable assistant execution, or omit whitelist entries to restrict them. Button and panel visibility use spec presence; project developers own dynamic UI filtering through normal layout mechanics such as $filter. Leaves expose optional descriptions; writable options allow only validate: true and allowDryRuns: false; recipe groups allow descriptions and allowDryRuns: false. Deletable entries are {}. Names, component bindings, hints and types are internal. Omitted overrides retain baseline values. Existing entity, enhanced-entity and action types constrain the handler; no separate generated manifest types. Browser GraphQL, tools and change recording use the session-derived manifest; rejected setup fails closed. UI reads the pure spec selector. Omitted server instructions or AI fields preserve the baseline. An empty server instructions string clears it.\n- To include another component or handler in the webhook, put `'use webhook'` as its first statement (leading comments are allowed).\n- A webhook-included file and its runtime local-import closure must not import browser SDK entrypoints (`application`, `admin`, `configurator`, `editor`, `react`, `ui`) or style/font/image assets. Spec parsing reports the unsafe import and inclusion reason as a diagnostic.\n- Keep browser rendering in an unpinned file. Move shared server-safe logic into a separate module when both frontend and webhook code need it.",doNotEdit:"## Do Not Edit\n- `.phoenix/` directory — completely regenerated on each build. The one exception is `.phoenix/variants/`, where the `phoenix-variants` skill has you write option files; a rebuild keeps it. The project's TypeScript settings come from `.phoenix/tsconfig.json`; the root `tsconfig.json` is the project's and extends it. `phoenix dev`, `phoenix build` and the webhook bundle do not resolve `paths` aliases, so an alias added to the root file passes `phoenix check` and fails the build; use relative imports\n- `src/locales/` .ts files — compiled from .po files\n- `phoenix` and `phoenix-*` folders under `.claude/skills/` and `.agents/skills/` — Phoenix rewrites its skills on every sync, removes anything else inside their folders and removes any other `phoenix-*` skill folder. To customise a skill, copy it to a folder whose name does not start with `phoenix`",modelVersioning:"## Version the Domain Model Once It Is Deployed\nA deployed model version cannot change, because saved configurations depend on it. `pnpm phoenix deploy` is refused, before anything is uploaded, when the model differs from the one already deployed under the same version. The version is not written anywhere: `model.latest` is always the highest numbered version plus one, so a spec with only `latest` is v1, and `applicationVersion` plays no part. `pnpm phoenix dev` accepts every model change, so a working preview does not show that the deploy will pass.\n\nTo change a model that has been deployed as v<N>:\n1. Keep the deployed model, unchanged, as `model.v<N>` in the spec. A file of its own, such as `spec/model-v<N>.yaml`, keeps `latest` readable.\n2. Make the change in `model.latest`, which is now v<N+1>.\n3. Add `src/migrations/v<N+1>.ts` exporting `migrateToV<N+1>`. It receives the saved entities of v<N> and returns entities that are valid in v<N+1>; `ModelV<N>` and `ModelV<N+1>` are generated global namespaces.\n\nThe admin model is versioned on its own, under `src/admin/migrations/`, with its types in `AdminV<N>`.\n\n**Replacing the starter.** When the first deployment of the workspace was the starter, its `Box` model is v1 in production. When the real model replaces it, keep the starter's model as `model.v1` and define the real model in `latest`. Configurations saved from the starter are not worth converting, so the migration returns the starting state of the new model, the `initialDomainEntities` of its preset, and drops the boxes:\n```typescript\n// src/migrations/v2.ts\nimport type { Migration } from '@salsita-ai/sdk/domain'\n\nexport const migrateToV2: Migration<ModelV1.AnyDomainEntity, ModelV2.AnyDomainEntity> = () => [\n // the entities of the new model's preset\n]\n```\nAn entity of a type the new version no longer has must not stay in the returned state. An entity id starts with its type (`Box-1`), so an entity that keeps its data under a new type name needs a new id and every relation pointing at it rewritten. Read `docs/phoenix/migrations.mdx` before writing any other migration.",sdkDocumentation:'## SDK Documentation\n\nAlways search SDK docs for relevant examples before implementing Phoenix features.\n\n### Commands\n- `pnpm phoenix docs` — Full documentation index with descriptions\n- `pnpm phoenix docs -s <term>` — Search all doc content and metadata (case-insensitive)\n- `pnpm phoenix docs --dir` — Print the absolute docs directory for grep or ripgrep\n- `pnpm phoenix docs -r <path>` — Read specific doc (raw text to stdout)\n- `pnpm phoenix docs -c <category>` — List docs in a category\n- `pnpm phoenix docs -l` — List all doc paths with titles\n\n### Key Docs\n- `docs/phoenix/getting-started.mdx` — Setup, prerequisites, first project\n- `docs/phoenix/quickstart.mdx` — End-to-end tutorial building a configurator\n- `docs/phoenix/domain-model.mdx` — Entities, attributes, relations, specs\n- `docs/phoenix/components.mdx` — ECS pattern, YAML components, custom components\n- `docs/phoenix/project-structure.mdx` — Files, folders, conventions\n- `docs/phoenix/best-practices.mdx` — YAML-first, code patterns, common pitfalls\n- `docs/phoenix/state-management.mdx` — Reactive state, RxJS pipelines, data flow\n- `docs/phoenix/expression-context.mdx` — Expression API, context object, helpers\n- `docs/phoenix/webhooks.mdx` — Server-side finalization workflows\n- `docs/phoenix/finalization.mdx` — Finalization system, PDF/email/CSV generation\n- `docs/phoenix/migrations.mdx` — Schema versioning, migration files\n\n### Agent Workflow\n1. Find relevant docs by content: `pnpm phoenix docs -s \'camera\'`\n2. Read matching doc: `pnpm phoenix docs -r docs/3d-scene/cameras/transitions.mdx`\n3. Search within a doc: `pnpm phoenix docs -r <path> | grep "example"`\n4. Search titles only as a fallback: `pnpm phoenix docs -l | grep "camera"`\n5. Search generated files directly when needed: `grep -rn "camera" "$(pnpm phoenix docs --dir)"`\n6. Browse a topic area: `pnpm phoenix docs -c "Layouts"`',assetInspection:"## 3D Asset Inspection\n\nRun `pnpm phoenix inspect:assets` to discover all glTF/GLB files in `public/` and get a summary table. Use `--file <path>` for detailed single-file inspection.\n\n**When to use:** before writing YAML/code that references objectName, materialsToOverride, morphTargetInfluences, or object positioning.\n\n**What it shows per node:**\n- Name, type (Mesh/Light/Camera/Empty), children\n- Transform: `pos=`, `rot=`, `scale=` (only non-default values shown)\n- Per-node morph targets: `morphs=Width,Height`\n- Bounding box: `bounds=WxHxD` (width x height x depth in meters)\n- Origin placement: `origin=center`, `bottom-center`, `top-center`, `bottom-corner`, etc. with numerical offset\n\n**Use cases:**\n- Find exact node names for `objectName` in scene entity components\n- Find material names for `materialsToOverride`\n- Find morph target names for `morphTargetInfluences`\n- Check model dimensions (bounds) for positioning, dimension indicators, or invariants\n- Check origin placement to understand how models anchor (center vs bottom-center)\n- Use `--json` for programmatic access to all data\n\n**Flags:** `--objects`, `--materials`, `--morphs`, `--animations`, `--json`",screenshotCli:"## Screenshot CLI\n\nCapture 3D canvas screenshots from a running dev server via `pnpm phoenix screenshot`.\n\n**Prerequisites:**\n1. `phoenix dev` must be running (starts the WebSocket server on port 3020)\n2. Configurator must be open in a browser (the browser does the actual rendering)\n\n**Options:**\n- `--output, -o` — Output file path (default: `./screenshot.png`)\n- `--width, -w` — Width in pixels (default: 1920)\n- `--height` — Height in pixels (default: 1080)\n- `--format, -f` — Image format: PNG or JPEG (default: PNG)\n- `--port` — WebSocket server port (default: 3020)\n\n**Example workflow:**\n1. Start dev server: `pnpm phoenix dev`\n2. Open configurator in browser (or via Playwright MCP)\n3. Take screenshot: `pnpm phoenix screenshot -o ./render.png -w 2560 --height 1440`\n\n**Use cases:** visual regression testing, generating product images, debugging 3D renders",inspectState:"## Inspect: State\n\nGet the current editor runtime state as JSON via `pnpm phoenix inspect:state`.\n\n**Prerequisites:** same as screenshot (dev server running + browser open)\n\n**Options:**\n- `--output, -o` — Output file path (prints to stdout if omitted)\n- `--sections, -s` — Comma-separated: entities, navigation, validation (default: all)\n- `--pretty` — Pretty-print JSON (default: true)\n- `--port` — WebSocket server port (default: 3020)\n\n**Example:** `pnpm phoenix inspect:state -o ./state.json -s entities,navigation`\n\n**Lifecycle status:** Always included in response. Shows which systems are ready:\n- `domainLoaded` — domain data loaded\n- `domainContextReady` — domain context initialized (entities available)\n- `configuratorReady` — 3D configurator initialized\n- `sessionAuthenticated` — session service active\n- `editorMode` — editor mode enabled\n\n**Tips:** Use `--sections` to limit payload size. Pipe through `head`/`tail` for partial output (e.g., `pnpm phoenix inspect:state | head -50`).\n\n**Use cases:** AI agent context, debugging entity state, inspecting navigation/validation",inspectData:`## Inspect: Data
7
+ - Underscore folders (_shared/, _utils/) are NOT auto-imported`,exportRules:'## Export Rules\nAll files in src/expressions/, src/actions/, src/invariants/, src/transformers/, src/components/, src/handlers/, src/elements/, src/webhooks/ MUST use default exports. Can be a single item or an array. Named exports are ignored by the SDK auto-import system.\nThe default export must be what the folder\'s phx factory returns (for example `phx.frontend.createCustomPhoenixLayoutElement()` in src/elements/). Any other value, such as a plain React component, stops the application at start with an "Invalid default export in <file>" error. Put plain components and helpers in an underscore folder.',webhookMembership:"## Webhook Membership\n- User-authored components, admin components, and handlers are frontend-only by default.\n- A handler that registers `phx.domain.createAssistantSetupHandler`, `createMapPublishedRevisionDataHandler`, `createMapPublishedChunkedDataHandler`, `createDataRowValidatorHandler`, or `createSheetValidatorHandler` is included in the webhook automatically.\n- An assistant setup handler receives the declaration-shaped whitelist and { role, sessionData, access }. Keep the exact entity/alias split from YAML; inherited fields and expanded member entries are absent. Narrow original declarations, then the SDK expands them. Use project-defined role/session data for per-user customization. Keep the handler synchronous, pure and deterministic. The handler runs in the browser and webhook. Return null to disable assistant execution, or omit whitelist entries to restrict them. Button and panel visibility use spec presence; project developers own dynamic UI filtering through normal layout mechanics such as $filter. Leaves expose optional descriptions; writable options allow only validate: true and allowDryRuns: false; recipe groups allow descriptions and allowDryRuns: false; screenshot views allow descriptions. Deletable entries are {}. Names, component bindings, hints and types are internal. Omitted overrides retain baseline values. Existing entity, enhanced-entity and action types constrain the handler; no separate generated manifest types. Browser GraphQL, tools and change recording use the session-derived manifest; rejected setup fails closed. UI reads the pure spec selector. Omitted server instructions or AI fields preserve the baseline. An empty server instructions string clears it.\n- To include another component or handler in the webhook, put `'use webhook'` as its first statement (leading comments are allowed).\n- A webhook-included file and its runtime local-import closure must not import browser SDK entrypoints (`application`, `admin`, `configurator`, `editor`, `react`, `ui`) or style/font/image assets. Spec parsing reports the unsafe import and inclusion reason as a diagnostic.\n- Keep browser rendering in an unpinned file. Move shared server-safe logic into a separate module when both frontend and webhook code need it.",doNotEdit:"## Do Not Edit\n- `.phoenix/` directory — completely regenerated on each build. The one exception is `.phoenix/variants/`, where the `phoenix-variants` skill has you write option files; a rebuild keeps it. The project's TypeScript settings come from `.phoenix/tsconfig.json`; the root `tsconfig.json` is the project's and extends it. `phoenix dev`, `phoenix build` and the webhook bundle do not resolve `paths` aliases, so an alias added to the root file passes `phoenix check` and fails the build; use relative imports\n- `src/locales/` .ts files — compiled from .po files\n- `phoenix` and `phoenix-*` folders under `.claude/skills/` and `.agents/skills/` — Phoenix rewrites its skills on every sync, removes anything else inside their folders and removes any other `phoenix-*` skill folder. To customise a skill, copy it to a folder whose name does not start with `phoenix`",modelVersioning:"## Version the Domain Model Once It Is Deployed\nA deployed model version cannot change, because saved configurations depend on it. `pnpm phoenix deploy` is refused, before anything is uploaded, when the model differs from the one already deployed under the same version. The version is not written anywhere: `model.latest` is always the highest numbered version plus one, so a spec with only `latest` is v1, and `applicationVersion` plays no part. `pnpm phoenix dev` accepts every model change, so a working preview does not show that the deploy will pass.\n\nTo change a model that has been deployed as v<N>:\n1. Keep the deployed model, unchanged, as `model.v<N>` in the spec. A file of its own, such as `spec/model-v<N>.yaml`, keeps `latest` readable.\n2. Make the change in `model.latest`, which is now v<N+1>.\n3. Add `src/migrations/v<N+1>.ts` exporting `migrateToV<N+1>`. It receives the saved entities of v<N> and returns entities that are valid in v<N+1>; `ModelV<N>` and `ModelV<N+1>` are generated global namespaces.\n\nThe admin model is versioned on its own, under `src/admin/migrations/`, with its types in `AdminV<N>`.\n\n**Replacing the starter.** When the first deployment of the workspace was the starter, its `Box` model is v1 in production. When the real model replaces it, keep the starter's model as `model.v1` and define the real model in `latest`. Configurations saved from the starter are not worth converting, so the migration returns the starting state of the new model, the `initialDomainEntities` of its preset, and drops the boxes:\n```typescript\n// src/migrations/v2.ts\nimport type { Migration } from '@salsita-ai/sdk/domain'\n\nexport const migrateToV2: Migration<ModelV1.AnyDomainEntity, ModelV2.AnyDomainEntity> = () => [\n // the entities of the new model's preset\n]\n```\nAn entity of a type the new version no longer has must not stay in the returned state. An entity id starts with its type (`Box-1`), so an entity that keeps its data under a new type name needs a new id and every relation pointing at it rewritten. Read `docs/phoenix/migrations.mdx` before writing any other migration.",sdkDocumentation:'## SDK Documentation\n\nAlways search SDK docs for relevant examples before implementing Phoenix features.\n\n### Commands\n- `pnpm phoenix docs` — Full documentation index with descriptions\n- `pnpm phoenix docs -s <term>` — Search all doc content and metadata (case-insensitive)\n- `pnpm phoenix docs --dir` — Print the absolute docs directory for grep or ripgrep\n- `pnpm phoenix docs -r <path>` — Read specific doc (raw text to stdout)\n- `pnpm phoenix docs -c <category>` — List docs in a category\n- `pnpm phoenix docs -l` — List all doc paths with titles\n\n### Key Docs\n- `docs/phoenix/getting-started.mdx` — Setup, prerequisites, first project\n- `docs/phoenix/quickstart.mdx` — End-to-end tutorial building a configurator\n- `docs/phoenix/domain-model.mdx` — Entities, attributes, relations, specs\n- `docs/phoenix/components.mdx` — ECS pattern, YAML components, custom components\n- `docs/phoenix/project-structure.mdx` — Files, folders, conventions\n- `docs/phoenix/best-practices.mdx` — YAML-first, code patterns, common pitfalls\n- `docs/phoenix/state-management.mdx` — Reactive state, RxJS pipelines, data flow\n- `docs/phoenix/expression-context.mdx` — Expression API, context object, helpers\n- `docs/phoenix/webhooks.mdx` — Server-side finalization workflows\n- `docs/phoenix/finalization.mdx` — Finalization system, PDF/email/CSV generation\n- `docs/phoenix/migrations.mdx` — Schema versioning, migration files\n\n### Agent Workflow\n1. Find relevant docs by content: `pnpm phoenix docs -s \'camera\'`\n2. Read matching doc: `pnpm phoenix docs -r docs/3d-scene/cameras/transitions.mdx`\n3. Search within a doc: `pnpm phoenix docs -r <path> | grep "example"`\n4. Search titles only as a fallback: `pnpm phoenix docs -l | grep "camera"`\n5. Search generated files directly when needed: `grep -rn "camera" "$(pnpm phoenix docs --dir)"`\n6. Browse a topic area: `pnpm phoenix docs -c "Layouts"`',assetInspection:"## 3D Asset Inspection\n\nRun `pnpm phoenix inspect:assets` to discover all glTF/GLB files in `public/` and get a summary table. Use `--file <path>` for detailed single-file inspection.\n\n**When to use:** before writing YAML/code that references objectName, materialsToOverride, morphTargetInfluences, or object positioning.\n\n**What it shows per node:**\n- Name, type (Mesh/Light/Camera/Empty), children\n- Transform: `pos=`, `rot=`, `scale=` (only non-default values shown)\n- Per-node morph targets: `morphs=Width,Height`\n- Bounding box: `bounds=WxHxD` (width x height x depth in meters)\n- Origin placement: `origin=center`, `bottom-center`, `top-center`, `bottom-corner`, etc. with numerical offset\n\n**Use cases:**\n- Find exact node names for `objectName` in scene entity components\n- Find material names for `materialsToOverride`\n- Find morph target names for `morphTargetInfluences`\n- Check model dimensions (bounds) for positioning, dimension indicators, or invariants\n- Check origin placement to understand how models anchor (center vs bottom-center)\n- Use `--json` for programmatic access to all data\n\n**Flags:** `--objects`, `--materials`, `--morphs`, `--animations`, `--json`",screenshotCli:"## Screenshot CLI\n\nCapture 3D canvas screenshots from a running dev server via `pnpm phoenix screenshot`.\n\n**Prerequisites:**\n1. `phoenix dev` must be running (starts the WebSocket server on port 3020)\n2. Configurator must be open in a browser (the browser does the actual rendering)\n\n**Options:**\n- `--output, -o` — Output file path (default: `./screenshot.png`)\n- `--width, -w` — Width in pixels (default: 1920)\n- `--height` — Height in pixels (default: 1080)\n- `--format, -f` — Image format: PNG or JPEG (default: PNG)\n- `--port` — WebSocket server port (default: 3020)\n\n**Example workflow:**\n1. Start dev server: `pnpm phoenix dev`\n2. Open configurator in browser (or via Playwright MCP)\n3. Take screenshot: `pnpm phoenix screenshot -o ./render.png -w 2560 --height 1440`\n\n**Use cases:** visual regression testing, generating product images, debugging 3D renders",inspectState:"## Inspect: State\n\nGet the current editor runtime state as JSON via `pnpm phoenix inspect:state`.\n\n**Prerequisites:** same as screenshot (dev server running + browser open)\n\n**Options:**\n- `--output, -o` — Output file path (prints to stdout if omitted)\n- `--sections, -s` — Comma-separated: entities, navigation, validation (default: all)\n- `--pretty` — Pretty-print JSON (default: true)\n- `--port` — WebSocket server port (default: 3020)\n\n**Example:** `pnpm phoenix inspect:state -o ./state.json -s entities,navigation`\n\n**Lifecycle status:** Always included in response. Shows which systems are ready:\n- `domainLoaded` — domain data loaded\n- `domainContextReady` — domain context initialized (entities available)\n- `configuratorReady` — 3D configurator initialized\n- `sessionAuthenticated` — session service active\n- `editorMode` — editor mode enabled\n\n**Tips:** Use `--sections` to limit payload size. Pipe through `head`/`tail` for partial output (e.g., `pnpm phoenix inspect:state | head -50`).\n\n**Use cases:** AI agent context, debugging entity state, inspecting navigation/validation",inspectData:`## Inspect: Data
8
8
 
9
9
  Get the current editor context data as JSON via \`pnpm phoenix inspect:data\`.
10
10
 
@@ -0,0 +1,25 @@
1
+ import { type EnumLike } from '#package/domain';
2
+ import type { RuntimeSpec } from '../runtime-spec/index.js';
3
+ /**
4
+ * The value of `phx.applicationTypes`: the application's version and published data hash, the JSON
5
+ * schemas of its data (`undefined` for data the spec leaves out), and its state enums.
6
+ */
7
+ export interface PhxApplicationTypes {
8
+ readonly ApplicationVersion: string;
9
+ readonly PublishedDataHash: string;
10
+ readonly PublishedData: unknown;
11
+ readonly SessionData: unknown;
12
+ readonly FrontendData: unknown;
13
+ readonly BackendData: unknown;
14
+ readonly FinalizeData: unknown;
15
+ readonly PrefetchedFinalizeData: unknown;
16
+ readonly FinalizeResult: unknown;
17
+ readonly CallbackData: unknown;
18
+ readonly NavigationState: EnumLike<string>;
19
+ readonly ViewState: EnumLike<string>;
20
+ readonly ToolState: EnumLike<string>;
21
+ readonly ExportState: EnumLike<string>;
22
+ readonly AdminNavigationState: EnumLike<string>;
23
+ }
24
+ /** Builds `phx.applicationTypes` from the spec, with the values generated `domain-spec.ts` writes. */
25
+ export declare const createPhxApplicationTypes: (spec: RuntimeSpec) => PhxApplicationTypes;
@@ -0,0 +1 @@
1
+ import{EnumReflection as a}from"#package/domain";let t=(t,e)=>new a(t,{enum:[...e]});export const createPhxApplicationTypes=a=>{let{dataSchemas:e,states:i}=a.configurator;return{ApplicationVersion:a.appMetadata.applicationVersion,PublishedDataHash:e.publishedDataHash,PublishedData:e.publishedData.runtimeSchema,SessionData:e.sessionData.runtimeSchema,FrontendData:e.frontendData.runtimeSchema,BackendData:e.backendData?.runtimeSchema,FinalizeData:e.finalizeData.runtimeSchema,PrefetchedFinalizeData:e.prefetchedFinalizeData.runtimeSchema,FinalizeResult:e.finalizeResult.runtimeSchema,CallbackData:e.callbackData.runtimeSchema,NavigationState:t("NavigationState",i.navigationStates),ViewState:t("ViewState",i.viewStates),ToolState:t("ToolState",i.toolStates),ExportState:t("ExportState",i.exportStates),AdminNavigationState:t("AdminNavigationState",a.admin.states.navigationStates)}};
@@ -0,0 +1,36 @@
1
+ import type { FactoryDataRuntime } from '../runtime/index.js';
2
+ import type { PhxModel } from './phx-model.js';
3
+ /**
4
+ * The value of `phx.domain`: the reflections and the factories project code writes its expressions,
5
+ * invariants, actions, components and recipes with, and the same for the admin domain under `admin`.
6
+ * The factories carry only the data the spec gives them (aliases, static violations, defaults); their
7
+ * types come from the project's `globals.d.ts`, which declares every member.
8
+ */
9
+ export interface PhxDomain extends PhxModel {
10
+ readonly implementCustomExpressions: unknown;
11
+ readonly implementCustomInvariants: unknown;
12
+ readonly implementActions: unknown;
13
+ readonly createAssistantSetupHandler: unknown;
14
+ readonly attachComponent: unknown;
15
+ readonly createRecipe: unknown;
16
+ readonly admin: PhxModel & {
17
+ readonly implementCustomExpressions: unknown;
18
+ readonly implementCustomInvariants: unknown;
19
+ readonly attachComponent: unknown;
20
+ readonly createMapPublishedRevisionDataHandler: unknown;
21
+ readonly createMapPublishedChunkedDataHandler: unknown;
22
+ readonly createDataRowValidatorHandler: unknown;
23
+ readonly createSheetValidatorHandler: unknown;
24
+ readonly createRecipe: unknown;
25
+ };
26
+ }
27
+ interface PhxDomainInput {
28
+ readonly model: PhxModel;
29
+ readonly factoryData: FactoryDataRuntime;
30
+ }
31
+ /**
32
+ * Builds `phx.domain` from the reflections and the factory data of both domains, with the same
33
+ * factories and the same data generated `domain-spec.ts` passes them.
34
+ */
35
+ export declare const createPhxDomain: (configurator: PhxDomainInput, admin: PhxDomainInput) => PhxDomain;
36
+ export {};
@@ -0,0 +1 @@
1
+ import{DomainComponentOpticBuilder as a,createActionFactory as t,createAssistantSetupHandlerFactory as e,createCustomExpressionFactory as o,createCustomInvariantFactory as i,createDataRowValidatorHandler as s,createMapPublishedChunkedDataHandlerFactory as n,createMapPublishedRevisionDataHandlerFactory as m,createRecipeFactory as r,createSheetValidatorHandler as c}from"#package/domain";let l=a=>r(a.aliases,a.entityReflections,a.defaults);export const createPhxDomain=(r,p)=>({...r.model,implementCustomExpressions:o(),implementCustomInvariants:i()(r.factoryData.staticViolations),implementActions:t(),createAssistantSetupHandler:e(),attachComponent:a.from(r.factoryData.aliases),createRecipe:l(r.factoryData),admin:{...p.model,implementCustomExpressions:o(),implementCustomInvariants:i()(p.factoryData.staticViolations),attachComponent:a.from(p.factoryData.aliases),createMapPublishedRevisionDataHandler:m(),createMapPublishedChunkedDataHandler:n(),createDataRowValidatorHandler:s,createSheetValidatorHandler:c,createRecipe:l(p.factoryData)}});
@@ -0,0 +1,24 @@
1
+ import type { Expressions } from '../../parse-application-files/index.js';
2
+ import type { RuntimeLatestModelVersion } from '../runtime-spec/index.js';
3
+ import type { AdminModelRuntime, ConfiguratorModelRuntime, SpecCodeMap } from '../runtime/index.js';
4
+ /**
5
+ * The reflections of one domain that project code reads from `phx.domain` (or `phx.domain.admin`):
6
+ * `model` holds the entity, alias, common type and shape reflections, `enhancedModel` the enhanced
7
+ * reflection of every entity and alias, named `$<Name>`.
8
+ */
9
+ export interface PhxModel {
10
+ readonly model: Readonly<Record<string, unknown>>;
11
+ readonly enhancedModel: Readonly<Record<string, unknown>>;
12
+ }
13
+ interface PhxModelSpec {
14
+ readonly latestModel: RuntimeLatestModelVersion;
15
+ readonly expressions: Expressions;
16
+ }
17
+ /**
18
+ * Builds the reflections of one domain from its runtime spec and its model runtime. The entity and
19
+ * alias reflections and the enhanced entity reflections are the model runtime's own, so the domain
20
+ * built from the same model runtime validates with the same objects; common types, shapes and
21
+ * enhanced aliases are built here, in the order generated code lists them.
22
+ */
23
+ export declare const createPhxModel: (domainSpec: PhxModelSpec, modelRuntime: ConfiguratorModelRuntime | AdminModelRuntime, code: SpecCodeMap | undefined) => PhxModel;
24
+ export {};
@@ -0,0 +1 @@
1
+ import{EnhancedAliasReflection as e,EnumReflection as t,SchemaReflection as n}from"#package/domain";import{evaluateReflectionConstants as o}from"../runtime/index.js";let r=e=>e,i=(e,o,i)=>{let l,s=r(i);return void 0!==(l=o.enum)&&l.length>0&&l.every(e=>"string"==typeof e)?new t(e,{...s,enum:[...o.enum]}):new n(e,s)};export const createPhxModel=(t,l,s)=>{let a={...l.entities,...l.aliasReflections};for(let[e,n]of t.latestModel.commonTypes)a[String(e)]=i(String(e),n.schema,n.runtimeSchema);for(let e of t.latestModel.shapes.values()){let t=`${String(e.name)}Shape`;a[t]=new n(t,r(e.runtimeSchema))}let m={};for(let[e,t]of Object.entries(l.$entityReflections))m[`$${e}`]=t;for(let[n,r]of t.latestModel.aliases){let i=String(n);m[`$${i}`]=new e(`$${i}`,r.map(String),o(t.expressions,i,s))}return{model:a,enhancedModel:m}};
@@ -0,0 +1,22 @@
1
+ import type { RuntimeReferenceStore } from '../../caching/index.js';
2
+ import type { RuntimeSpec } from '../runtime-spec/index.js';
3
+ import { type SpecCodeModule } from '../runtime/index.js';
4
+ import { type PhxApplicationTypes } from './phx-application-types.js';
5
+ import { type PhxDomain } from './phx-domain.js';
6
+ /** The `phx` values an application's project modules read while they load. */
7
+ export interface Phx {
8
+ readonly domain: PhxDomain;
9
+ readonly applicationTypes: PhxApplicationTypes;
10
+ }
11
+ /**
12
+ * Builds the values of `phx.domain` and `phx.applicationTypes` from an application's runtime spec
13
+ * (`.phoenix/application-spec.json`, decoded with `decodeRuntimeSpec`) and its generated code module
14
+ * (`.phoenix/spec-code.ts`): the model reflections of both domains, and the factories with the
15
+ * static violations, aliases and defaults of the spec.
16
+ *
17
+ * It builds the spec's sections in `referenceStore`. The application's `ApplicationRuntime` is
18
+ * built later in the same store, so `phx.domain.model` holds the reflections the application's
19
+ * domain validates with. It assigns nothing: the generated entry assigns `phx` before it imports
20
+ * the project's modules, because a development server renames the global in project files only.
21
+ */
22
+ export declare const createPhx: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, specCode?: SpecCodeModule) => Phx;
@@ -0,0 +1 @@
1
+ import{SpecRuntime as o}from"../runtime/index.js";import{createPhxApplicationTypes as t}from"./phx-application-types.js";import{createPhxDomain as a}from"./phx-domain.js";import{createPhxModel as m}from"./phx-model.js";export const createPhx=(r,i,e)=>{let{configurator:n,admin:p}=o(r,i,e);return{domain:a({model:m(r.configurator,n.modelRuntime,e?.configurator),factoryData:n.factoryDataRuntime},{model:m(r.admin,p.modelRuntime,e?.admin),factoryData:p.factoryDataRuntime}),applicationTypes:t(r)}};
@@ -1,5 +1,7 @@
1
1
  export * from './runtime/sections/index.js';
2
2
  export * from './runtime/application-runtime.js';
3
+ export { applicationSpecSlice, type ApplicationSpecSliceModules } from './runtime/application-spec-slice.js';
4
+ export { type ApplicationModules, createApplication } from './runtime/create-application.js';
3
5
  export * from './runtime/factory-data/index.js';
4
6
  export * from './runtime/migrations/index.js';
5
7
  export { isConfiguratorModelSchemaCompatible } from './runtime/configurator-runtime/configurator-model-runtime.js';
@@ -1 +1 @@
1
- export*from"./runtime/sections/index.js";export*from"./runtime/application-runtime.js";export*from"./runtime/factory-data/index.js";export*from"./runtime/migrations/index.js";export{isConfiguratorModelSchemaCompatible}from"./runtime/configurator-runtime/configurator-model-runtime.js";export*from"./code/index.js";export{generateRuntimeInstance}from"./runtime/generate-runtime-instance.js";
1
+ export*from"./runtime/sections/index.js";export*from"./runtime/application-runtime.js";export{applicationSpecSlice}from"./runtime/application-spec-slice.js";export{createApplication}from"./runtime/create-application.js";export*from"./runtime/factory-data/index.js";export*from"./runtime/migrations/index.js";export{isConfiguratorModelSchemaCompatible}from"./runtime/configurator-runtime/configurator-model-runtime.js";export*from"./code/index.js";export{generateRuntimeInstance}from"./runtime/generate-runtime-instance.js";
@@ -1,8 +1,8 @@
1
1
  import { Branded } from '@salsita-ai/common/utils';
2
2
  import { type $DomainEntity, $DomainEntityReflection, DomainBuilder, type DomainEntity, DomainEntityReflection, RawAliasReflection, SchemaReflection } from '#package/domain';
3
3
  import type { RuntimeReferenceStore } from '../../../caching/index.js';
4
- import type { DataSchemas, Expressions } from '../../../parse-application-files/index.js';
5
- import type { RuntimeModelVersion, RuntimeResolvedVersions } from '../../runtime-spec/index.js';
4
+ import type { Expressions } from '../../../parse-application-files/index.js';
5
+ import type { RuntimeDataSchemas, RuntimeModelVersion, RuntimeResolvedVersions } from '../../runtime-spec/index.js';
6
6
  import type { SpecCodeMap } from '../spec-code/index.js';
7
7
  type AnyEntity = DomainEntity<string>;
8
8
  type AnyAliases = Record<string, AnyEntity>;
@@ -26,5 +26,5 @@ interface AdminModelRuntimeFields {
26
26
  readonly schemaChanged: boolean;
27
27
  }
28
28
  export type AdminModelRuntime = Branded<'AdminModelRuntime', AdminModelRuntimeFields>;
29
- export declare const AdminModelRuntime: (domainSpec: AdminModelRuntimeSpec, dataSchemas: DataSchemas, referenceStore: RuntimeReferenceStore, code: SpecCodeMap | undefined) => AdminModelRuntime;
29
+ export declare const AdminModelRuntime: (domainSpec: AdminModelRuntimeSpec, dataSchemas: RuntimeDataSchemas, referenceStore: RuntimeReferenceStore, code: SpecCodeMap | undefined) => AdminModelRuntime;
30
30
  export {};
@@ -1,13 +1,14 @@
1
1
  import { Branded } from '@salsita-ai/common/utils';
2
+ import { type ImplementationErrorCollector, type ProjectModule } from '#package/domain';
2
3
  import type { RuntimeReferenceStore } from '../../../caching/index.js';
3
4
  import type { RuntimeSpec } from '../../runtime-spec/index.js';
4
- import { FactoryDataRuntime } from '../factory-data/index.js';
5
+ import type { FactoryDataRuntime } from '../factory-data/index.js';
5
6
  import { type MigrationModules, MigrationRuntime } from '../migrations/index.js';
6
7
  import { ComponentOptics } from '../sections/component-optic.js';
7
- import { type ExpressionImplementations, ExpressionRuntime, type InvariantImplementations, type MissingExpression } from '../sections/expression-runtime.js';
8
+ import { ExpressionRuntime, type InvariantImplementations, type MissingExpression } from '../sections/expression-runtime.js';
8
9
  import { PresetRuntime } from '../sections/preset-runtime.js';
9
10
  import type { SpecCodeMap } from '../spec-code/index.js';
10
- import { AdminModelRuntime } from './admin-model-runtime.js';
11
+ import type { AdminModelRuntime } from './admin-model-runtime.js';
11
12
  import { AdminStatesRuntime } from './states-runtime.js';
12
13
  export type AdminRuntime = Branded<'AdminRuntime', {
13
14
  readonly modelRuntime: AdminModelRuntime;
@@ -24,5 +25,7 @@ export type AdminRuntimeResult = {
24
25
  } | {
25
26
  readonly ok: false;
26
27
  readonly missingExpressions: readonly MissingExpression[];
28
+ /** The migrations the migration modules do not export, as `migrationRuntime.missingMigrations` lists them. */
29
+ readonly missingMigrations: readonly string[];
27
30
  };
28
- export declare const AdminRuntime: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, implementations: ExpressionImplementations, invariantImplementations: InvariantImplementations, migrationModules: MigrationModules, code: SpecCodeMap | undefined) => AdminRuntimeResult;
31
+ export declare const AdminRuntime: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, expressionModules: readonly ProjectModule[], invariantImplementations: InvariantImplementations, migrationModules: MigrationModules, code: SpecCodeMap | undefined, errors: ImplementationErrorCollector) => AdminRuntimeResult;
@@ -1 +1 @@
1
- import{Branded as e}from"@salsita-ai/common/utils";import{Preset as t,PresetCategory as i,commonAdminCustomExpressions as n,commonAdminViolationExpressions as r}from"#package/domain";import{FactoryDataRuntime as s}from"../factory-data/index.js";import{MigrationRuntime as o}from"../migrations/index.js";import{ComponentOptics as m}from"../sections/component-optic.js";import{ExpressionRuntime as a}from"../sections/expression-runtime.js";import{PresetRuntime as p}from"../sections/preset-runtime.js";import{AdminModelRuntime as f}from"./admin-model-runtime.js";import{AdminStatesRuntime as u}from"./states-runtime.js";let c={Preset:[{evaluate:(e,i,n)=>{let s=n.domain.get$Entity(e,i);return t.assert(s),r.Preset.nameNotEmpty(s)}}]},l={PresetCategory:{$isDraft:{origin:{name:"$isDraft",typeOrAlias:"PresetCategory"},evaluate:(e,t,r)=>{let s=r.domain.get$Entity(e,t);return i.assert(s),n.PresetCategory.$isDraft(s)},meta:{}}}},d=new WeakMap;export const AdminRuntime=(t,i,n,r,g,R)=>{let y={...l};for(let[e,t]of Object.entries(n))y[e]={...y[e],...t};let j=f(t.admin,t.configurator.dataSchemas,i,R),k=a(t.admin,i,y,"adminExpressionRuntime",((e,t)=>{if(0===Object.keys(e).length)return c;let i=d.get(t)??new WeakMap;d.set(t,i);let n=i.get(e);if(n)return n;let r={};for(let i of[c,e])for(let[e,n]of Object.entries(i))for(let i of t[e]??[e])r[i]=[...r[i]??[],...n];return i.set(e,r),r})(r,j.aliases),R);return k.ok?{ok:!0,runtime:e({modelRuntime:j,componentOptics:m(i,{components:t.admin.components,referenceScope:"adminRuntime/componentOptics",modelRuntime:j,code:R}),expressionRuntime:k.runtime,presetRuntime:p(i,{referenceScope:"adminRuntime/presetRuntime",presets:t.admin.presets.presets}),statesRuntime:u(t,i),migrationRuntime:o(i,{referenceScope:"adminRuntime/migrationRuntime",resolvedVersions:t.admin.resolvedVersions,latestEntities:j.entities,migrationModules:g}),factoryDataRuntime:s(i,{referenceScope:"adminRuntime/factoryDataRuntime",invariants:t.admin.invariants,defaults:t.admin.defaults,aliases:j.aliases,entities:j.entities})})}:{ok:!1,missingExpressions:k.missing}};
1
+ import{Branded as e}from"@salsita-ai/common/utils";import{Preset as t,PresetCategory as i,commonAdminCustomExpressions as s,commonAdminViolationExpressions as n}from"#package/domain";import{MigrationRuntime as r}from"../migrations/index.js";import{ComponentOptics as o}from"../sections/component-optic.js";import{ExpressionRuntime as m}from"../sections/expression-runtime.js";import{PresetRuntime as a}from"../sections/preset-runtime.js";import{AdminSpecRuntime as p}from"./admin-spec-runtime.js";import{AdminStatesRuntime as u}from"./states-runtime.js";let c={Preset:[{evaluate:(e,i,s)=>{let r=s.domain.get$Entity(e,i);return t.assert(r),n.Preset.nameNotEmpty(r)}}]},f={PresetCategory:{$isDraft:{origin:{name:"$isDraft",typeOrAlias:"PresetCategory"},evaluate:(e,t,n)=>{let r=n.domain.get$Entity(e,t);return i.assert(r),s.PresetCategory.$isDraft(r)},meta:{}}}},l=new WeakMap;export const AdminRuntime=(t,i,s,n,g,d,R)=>{let{modelRuntime:j,factoryDataRuntime:y}=p(t,i,d),k=m(t.admin,i,s,"adminExpressionRuntime",((e,t)=>{if(0===Object.keys(e).length)return c;let i=l.get(t)??new WeakMap;l.set(t,i);let s=i.get(e);if(s)return s;let n={};for(let i of[c,e])for(let[e,s]of Object.entries(i))for(let i of t[e]??[e])n[i]=[...n[i]??[],...s];return i.set(e,n),n})(n,j.aliases),d,R,f),x=r(i,{referenceScope:"adminRuntime/migrationRuntime",resolvedVersions:t.admin.resolvedVersions,latestEntities:j.entities,migrationModules:g});return k.ok?{ok:!0,runtime:e({modelRuntime:j,componentOptics:o(i,{components:t.admin.components,referenceScope:"adminRuntime/componentOptics",modelRuntime:j,code:d}),expressionRuntime:k.runtime,presetRuntime:a(i,{referenceScope:"adminRuntime/presetRuntime",presets:t.admin.presets.presets}),statesRuntime:u(t,i),migrationRuntime:x,factoryDataRuntime:y})}:{ok:!1,missingExpressions:k.missing,missingMigrations:x.missingMigrations}};
@@ -0,0 +1,16 @@
1
+ import { Branded } from '@salsita-ai/common/utils';
2
+ import type { RuntimeReferenceStore } from '../../../caching/index.js';
3
+ import type { RuntimeSpec } from '../../runtime-spec/index.js';
4
+ import { FactoryDataRuntime } from '../factory-data/index.js';
5
+ import type { SpecCodeMap } from '../spec-code/index.js';
6
+ import { AdminModelRuntime } from './admin-model-runtime.js';
7
+ /**
8
+ * The sections of the admin domain that the spec alone determines: its model and the data of its
9
+ * `phx.domain.admin` factories. `AdminRuntime` builds its own from this function, so a build of
10
+ * either in the same reference store returns the same objects.
11
+ */
12
+ export type AdminSpecRuntime = Branded<'AdminSpecRuntime', {
13
+ readonly modelRuntime: AdminModelRuntime;
14
+ readonly factoryDataRuntime: FactoryDataRuntime;
15
+ }>;
16
+ export declare const AdminSpecRuntime: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, code: SpecCodeMap | undefined) => AdminSpecRuntime;
@@ -0,0 +1 @@
1
+ import{Branded as a}from"@salsita-ai/common/utils";import{FactoryDataRuntime as t}from"../factory-data/index.js";import{AdminModelRuntime as i}from"./admin-model-runtime.js";export const AdminSpecRuntime=(e,n,m)=>{let r=i(e.admin,e.configurator.dataSchemas,n,m);return a({modelRuntime:r,factoryDataRuntime:t(n,{referenceScope:"adminRuntime/factoryDataRuntime",invariants:e.admin.invariants,defaults:e.admin.defaults,aliases:r.aliases,entities:r.entities})})};
@@ -1,12 +1,12 @@
1
1
  import { Branded } from '@salsita-ai/common/utils';
2
- import type { ImportedTransformer } from '#package/domain';
2
+ import { type ImplementationErrorCollector, type ImportedTransformer, type ProjectModule } from '#package/domain';
3
3
  import type { RuntimeReferenceStore } from '../../caching/index.js';
4
4
  import type { RuntimeSpec } from '../runtime-spec/index.js';
5
5
  import { AdminRuntime } from './admin-runtime/admin-runtime.js';
6
6
  import { ConfiguratorRuntime } from './configurator-runtime/configurator-runtime.js';
7
7
  import type { MigrationModules } from './migrations/index.js';
8
8
  import { DataRuntime } from './sections/data-runtime.js';
9
- import type { ExpressionImplementations, InvariantImplementations, MissingExpression } from './sections/expression-runtime.js';
9
+ import type { InvariantImplementations, MissingExpression } from './sections/expression-runtime.js';
10
10
  import type { SpecCodeModule } from './spec-code/index.js';
11
11
  /**
12
12
  * Runtime objects built from a RuntimeSpec.
@@ -23,6 +23,11 @@ export type ApplicationRuntimeResult = {
23
23
  } | {
24
24
  readonly ok: false;
25
25
  readonly missingExpressions: readonly MissingExpression[];
26
+ /**
27
+ * The migrations of both domains the migration modules do not export, which a built
28
+ * runtime lists in `migrationRuntime.missingMigrations` of each domain.
29
+ */
30
+ readonly missingMigrations: readonly string[];
26
31
  };
27
32
  /**
28
33
  * Builds an ApplicationRuntime from a RuntimeSpec: the part of the parsed spec the runtime reads, which a
@@ -42,6 +47,14 @@ export type ApplicationRuntimeResult = {
42
47
  * same generation as `spec`; an id carries a hash of its code, so a module from another generation
43
48
  * misses the ids of changed code instead of running an old closure.
44
49
  *
45
- * Returns an error result when declared expressions are missing implementations.
50
+ * `expressionModules` and `adminExpressionModules` are the project's expression files
51
+ * (`src/expressions/`, `src/admin/expressions/`), as the generated barrels or the editor's reload
52
+ * hand them over; each domain merges them with the aliases of its spec (`mergeExpressionModules`).
53
+ *
54
+ * The mistakes of the project files are recorded in `errors` as `ImplementationError`s: a file with
55
+ * the wrong export, an expression two files define, or that a file defines although the spec or the
56
+ * SDK gives it a value (`DUPLICATE_DEFINITION`), and a declared expression no file implements
57
+ * (`MISSING_IMPLEMENTATION`), which also makes the result an error. Without `errors`, everything
58
+ * recorded is thrown together as one `ImplementationErrors` before the result is returned.
46
59
  */
47
- export declare const ApplicationRuntime: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, implementations: ExpressionImplementations, importedTransformers: readonly ImportedTransformer[], invariantImplementations?: InvariantImplementations, adminImplementations?: ExpressionImplementations, adminInvariantImplementations?: InvariantImplementations, migrationModules?: MigrationModules, specCode?: SpecCodeModule) => ApplicationRuntimeResult;
60
+ export declare const ApplicationRuntime: (spec: RuntimeSpec, referenceStore: RuntimeReferenceStore, expressionModules: readonly ProjectModule[], importedTransformers: readonly ImportedTransformer[], invariantImplementations?: InvariantImplementations, adminExpressionModules?: readonly ProjectModule[], adminInvariantImplementations?: InvariantImplementations, migrationModules?: MigrationModules, specCode?: SpecCodeModule, errors?: ImplementationErrorCollector) => ApplicationRuntimeResult;
@@ -1 +1 @@
1
- import{Branded as i}from"@salsita-ai/common/utils";import{AdminRuntime as r}from"./admin-runtime/admin-runtime.js";import{ConfiguratorRuntime as n}from"./configurator-runtime/configurator-runtime.js";import{DataRuntime as o}from"./sections/data-runtime.js";export const ApplicationRuntime=(s,t,m,e,a,u={},p={},f={},c)=>{let g=n(s,t,m,e,a,f,c?.configurator);if(!g.ok)return{ok:!1,missingExpressions:g.missingExpressions};let d=r(s,t,u,p,f,c?.admin);return d.ok?{ok:!0,runtime:i({configurator:g.runtime,admin:d.runtime,data:o(s,t)})}:{ok:!1,missingExpressions:d.missingExpressions}};
1
+ import{Branded as i}from"@salsita-ai/common/utils";import{createImplementationErrorCollector as n}from"#package/domain";import{AdminRuntime as o}from"./admin-runtime/admin-runtime.js";import{ConfiguratorRuntime as r}from"./configurator-runtime/configurator-runtime.js";import{DataRuntime as m}from"./sections/data-runtime.js";export const ApplicationRuntime=(t,s,a,e,g,u=[],p={},f={},c,k)=>{let d=k??n(),M=r(t,s,a,e,g,f,c?.configurator,d),l=o(t,s,u,p,f,c?.admin,d);return(void 0===k&&d.throwIfAny(),M.ok&&l.ok)?{ok:!0,runtime:i({configurator:M.runtime,admin:l.runtime,data:m(t,s)})}:{ok:!1,missingExpressions:[...M.ok?[]:M.missingExpressions,...l.ok?[]:l.missingExpressions],missingMigrations:[...M.ok?M.runtime.migrationRuntime.missingMigrations:M.missingMigrations,...l.ok?l.runtime.migrationRuntime.missingMigrations:l.missingMigrations]}};