@antelopejs/dms 0.25.8 → 0.25.9-next.1183.ga9db169

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 (477) hide show
  1. package/CHANGELOG.md +0 -48
  2. package/E2E.md +138 -0
  3. package/README.md +2 -2
  4. package/data/mockup-example/spec.json +13 -0
  5. package/data/mockup-spec.schema.json +399 -16
  6. package/dist/e2e/index.d.mts +2 -1
  7. package/dist/implementations/dms/live-pages.d.ts +6 -0
  8. package/dist/implementations/dms/live-pages.js +139 -0
  9. package/dist/implementations/dms/live-pages.js.map +1 -0
  10. package/dist/implementations/dms/page/notifications.js +2 -0
  11. package/dist/implementations/dms/page/notifications.js.map +1 -1
  12. package/dist/implementations/dms/page/registry.js +19 -4
  13. package/dist/implementations/dms/page/registry.js.map +1 -1
  14. package/dist/implementations/dms/registry-snapshot.d.ts +32 -0
  15. package/dist/implementations/dms/registry-snapshot.js +55 -0
  16. package/dist/implementations/dms/registry-snapshot.js.map +1 -0
  17. package/dist/implementations/dms/services.d.ts +2 -0
  18. package/dist/implementations/dms/services.js +2 -0
  19. package/dist/implementations/dms/services.js.map +1 -1
  20. package/dist/implementations/dms/tenant-access.d.ts +1 -0
  21. package/dist/implementations/dms/tenant-access.js +7 -0
  22. package/dist/implementations/dms/tenant-access.js.map +1 -1
  23. package/dist/implementations/dms-builder/engine/compose-page.js +1 -1
  24. package/dist/implementations/dms-builder/engine/compose-page.js.map +1 -1
  25. package/dist/implementations/dms-builder/engine/map-resources-pages.js +1 -1
  26. package/dist/implementations/dms-builder/engine/map-resources-pages.js.map +1 -1
  27. package/dist/implementations/dms-builder/engine/ops-blocks.d.ts +2 -1
  28. package/dist/implementations/dms-builder/engine/ops-blocks.js +12 -1
  29. package/dist/implementations/dms-builder/engine/ops-blocks.js.map +1 -1
  30. package/dist/implementations/dms-builder/engine/table-view-settings.js +9 -33
  31. package/dist/implementations/dms-builder/engine/table-view-settings.js.map +1 -1
  32. package/dist/index.js +2 -0
  33. package/dist/index.js.map +1 -1
  34. package/dist/mcp/index.d.ts +2 -0
  35. package/dist/mcp/index.js +9 -0
  36. package/dist/mcp/index.js.map +1 -1
  37. package/dist/mcp/mockup-export/capture.d.ts +19 -0
  38. package/dist/mcp/mockup-export/capture.js +99 -0
  39. package/dist/mcp/mockup-export/capture.js.map +1 -0
  40. package/dist/mcp/mockup-export/document.d.ts +4 -0
  41. package/dist/mcp/mockup-export/document.js +199 -0
  42. package/dist/mcp/mockup-export/document.js.map +1 -0
  43. package/dist/mcp/mockup-export/index.d.ts +20 -0
  44. package/dist/mcp/mockup-export/index.js +112 -0
  45. package/dist/mcp/mockup-export/index.js.map +1 -0
  46. package/dist/mcp/mockup-export/jobs.d.ts +32 -0
  47. package/dist/mcp/mockup-export/jobs.js +49 -0
  48. package/dist/mcp/mockup-export/jobs.js.map +1 -0
  49. package/dist/mcp/mockup-export/plan.d.ts +78 -0
  50. package/dist/mcp/mockup-export/plan.js +296 -0
  51. package/dist/mcp/mockup-export/plan.js.map +1 -0
  52. package/dist/mcp/mockup-export/route.d.ts +23 -0
  53. package/dist/mcp/mockup-export/route.js +91 -0
  54. package/dist/mcp/mockup-export/route.js.map +1 -0
  55. package/dist/mcp/page-verify/index.d.ts +15 -0
  56. package/dist/mcp/page-verify/index.js +16 -6
  57. package/dist/mcp/page-verify/index.js.map +1 -1
  58. package/dist/mcp/page-verify/mockup.d.ts +3 -1
  59. package/dist/mcp/page-verify/mockup.js +2 -0
  60. package/dist/mcp/page-verify/mockup.js.map +1 -1
  61. package/dist/mcp/page-verify/modules.d.ts +1 -0
  62. package/dist/mcp/page-verify/modules.js +22 -0
  63. package/dist/mcp/page-verify/modules.js.map +1 -0
  64. package/dist/mcp/page-verify/page-probe.d.ts +5 -0
  65. package/dist/mcp/page-verify/page-probe.js +2 -0
  66. package/dist/mcp/page-verify/page-probe.js.map +1 -1
  67. package/dist/mcp/page-verify/playwright.d.ts +22 -4
  68. package/dist/mcp/page-verify/playwright.js.map +1 -1
  69. package/dist/mcp/page-verify/report.d.ts +1 -0
  70. package/dist/mcp/tools/builder-compose.js +4 -1
  71. package/dist/mcp/tools/builder-compose.js.map +1 -1
  72. package/dist/mcp/tools/builder-pages.js +1 -1
  73. package/dist/mcp/tools/builder-pages.js.map +1 -1
  74. package/dist/mcp/tools/index.d.ts +2 -0
  75. package/dist/mcp/tools/index.js +6 -1
  76. package/dist/mcp/tools/index.js.map +1 -1
  77. package/dist/mcp/tools/mockup-export-pdf.d.ts +1 -0
  78. package/dist/mcp/tools/mockup-export-pdf.js +69 -0
  79. package/dist/mcp/tools/mockup-export-pdf.js.map +1 -0
  80. package/dist/mcp/tools/mockup-install-modules.d.ts +9 -0
  81. package/dist/mcp/tools/mockup-install-modules.js +122 -0
  82. package/dist/mcp/tools/mockup-install-modules.js.map +1 -0
  83. package/dist/mcp/tools/mockup-module-catalog.d.ts +3 -0
  84. package/dist/mcp/tools/mockup-module-catalog.js +52 -0
  85. package/dist/mcp/tools/mockup-module-catalog.js.map +1 -0
  86. package/dist/mcp/tools/mockup-patch-spec.js +1 -1
  87. package/dist/mcp/tools/mockup-patch-spec.js.map +1 -1
  88. package/dist/mcp/tools/mockup-read-spec.js +8 -6
  89. package/dist/mcp/tools/mockup-read-spec.js.map +1 -1
  90. package/dist/mcp/tools/mockup-support.js +18 -5
  91. package/dist/mcp/tools/mockup-support.js.map +1 -1
  92. package/dist/mcp/tools/mockup-write-spec.js +1 -1
  93. package/dist/mcp/tools/mockup-write-spec.js.map +1 -1
  94. package/dist/mcp/tools/mockup.js +6 -0
  95. package/dist/mcp/tools/mockup.js.map +1 -1
  96. package/dist/mcp/tools/page-verify.d.ts +1 -0
  97. package/dist/mcp/tools/page-verify.js +6 -2
  98. package/dist/mcp/tools/page-verify.js.map +1 -1
  99. package/dist/mcp/tools/pages.d.ts +1 -0
  100. package/dist/mcp/tools/pages.js +9 -3
  101. package/dist/mcp/tools/pages.js.map +1 -1
  102. package/dist/mockup/annotations.js +2 -2
  103. package/dist/mockup/annotations.js.map +1 -1
  104. package/dist/mockup/apply-notes.js +1 -1
  105. package/dist/mockup/apply-notes.js.map +1 -1
  106. package/dist/mockup/compile-layouts.d.ts +5 -0
  107. package/dist/mockup/compile-layouts.js +74 -0
  108. package/dist/mockup/compile-layouts.js.map +1 -0
  109. package/dist/mockup/compile-modules.d.ts +5 -0
  110. package/dist/mockup/compile-modules.js +40 -0
  111. package/dist/mockup/compile-modules.js.map +1 -0
  112. package/dist/mockup/compile-nodes.d.ts +11 -0
  113. package/dist/mockup/compile-nodes.js +119 -0
  114. package/dist/mockup/compile-nodes.js.map +1 -0
  115. package/dist/mockup/compile-pages.d.ts +20 -0
  116. package/dist/mockup/compile-pages.js +272 -0
  117. package/dist/mockup/compile-pages.js.map +1 -0
  118. package/dist/mockup/compile.d.ts +10 -12
  119. package/dist/mockup/compile.js +36 -292
  120. package/dist/mockup/compile.js.map +1 -1
  121. package/dist/mockup/controller-blocks.js +2 -0
  122. package/dist/mockup/controller-blocks.js.map +1 -1
  123. package/dist/mockup/create.d.ts +16 -0
  124. package/dist/mockup/create.js +78 -0
  125. package/dist/mockup/create.js.map +1 -0
  126. package/dist/mockup/created-watch.d.ts +18 -0
  127. package/dist/mockup/created-watch.js +110 -0
  128. package/dist/mockup/created-watch.js.map +1 -0
  129. package/dist/mockup/database-routes.d.ts +15 -0
  130. package/dist/mockup/database-routes.js +58 -0
  131. package/dist/mockup/database-routes.js.map +1 -0
  132. package/dist/mockup/database-schema.d.ts +17 -0
  133. package/dist/mockup/database-schema.js +41 -0
  134. package/dist/mockup/database-schema.js.map +1 -0
  135. package/dist/mockup/entities.d.ts +20 -0
  136. package/dist/mockup/entities.js +213 -0
  137. package/dist/mockup/entities.js.map +1 -0
  138. package/dist/mockup/etag.d.ts +1 -0
  139. package/dist/mockup/etag.js +10 -0
  140. package/dist/mockup/etag.js.map +1 -0
  141. package/dist/mockup/extensions.d.ts +34 -0
  142. package/dist/mockup/extensions.js +107 -0
  143. package/dist/mockup/extensions.js.map +1 -0
  144. package/dist/mockup/files.d.ts +2 -1
  145. package/dist/mockup/files.js +2 -1
  146. package/dist/mockup/files.js.map +1 -1
  147. package/dist/mockup/fixture-answers.d.ts +3 -2
  148. package/dist/mockup/fixture-answers.js +13 -4
  149. package/dist/mockup/fixture-answers.js.map +1 -1
  150. package/dist/mockup/fixture-batch.d.ts +21 -0
  151. package/dist/mockup/fixture-batch.js +111 -0
  152. package/dist/mockup/fixture-batch.js.map +1 -0
  153. package/dist/mockup/fixture-routes.d.ts +21 -0
  154. package/dist/mockup/fixture-routes.js +136 -0
  155. package/dist/mockup/fixture-routes.js.map +1 -0
  156. package/dist/mockup/fixtures.d.ts +2 -29
  157. package/dist/mockup/fixtures.js +0 -111
  158. package/dist/mockup/fixtures.js.map +1 -1
  159. package/dist/mockup/from-page.js +2 -9
  160. package/dist/mockup/from-page.js.map +1 -1
  161. package/dist/mockup/generate.js +4 -1
  162. package/dist/mockup/generate.js.map +1 -1
  163. package/dist/mockup/history-routes.d.ts +2 -4
  164. package/dist/mockup/history-routes.js +30 -39
  165. package/dist/mockup/history-routes.js.map +1 -1
  166. package/dist/mockup/history.js +7 -3
  167. package/dist/mockup/history.js.map +1 -1
  168. package/dist/mockup/index.d.ts +14 -0
  169. package/dist/mockup/index.js +14 -0
  170. package/dist/mockup/index.js.map +1 -1
  171. package/dist/mockup/json-schema-entities.d.ts +5 -0
  172. package/dist/mockup/json-schema-entities.js +141 -0
  173. package/dist/mockup/json-schema-entities.js.map +1 -0
  174. package/dist/mockup/json-schema-layout.d.ts +1 -0
  175. package/dist/mockup/json-schema-layout.js +95 -2
  176. package/dist/mockup/json-schema-layout.js.map +1 -1
  177. package/dist/mockup/json-schema.d.ts +1 -1
  178. package/dist/mockup/json-schema.js +41 -20
  179. package/dist/mockup/json-schema.js.map +1 -1
  180. package/dist/mockup/json.d.ts +8 -0
  181. package/dist/mockup/json.js +20 -0
  182. package/dist/mockup/json.js.map +1 -0
  183. package/dist/mockup/layout-model.d.ts +156 -0
  184. package/dist/mockup/layout-model.js +96 -0
  185. package/dist/mockup/layout-model.js.map +1 -0
  186. package/dist/mockup/layouts.d.ts +9 -0
  187. package/dist/mockup/layouts.js +40 -0
  188. package/dist/mockup/layouts.js.map +1 -0
  189. package/dist/mockup/manage-routes.d.ts +3 -1
  190. package/dist/mockup/manage-routes.js +38 -1
  191. package/dist/mockup/manage-routes.js.map +1 -1
  192. package/dist/mockup/manage.js +1 -1
  193. package/dist/mockup/manage.js.map +1 -1
  194. package/dist/mockup/model.d.ts +145 -99
  195. package/dist/mockup/model.js +101 -86
  196. package/dist/mockup/model.js.map +1 -1
  197. package/dist/mockup/module-context.d.ts +25 -0
  198. package/dist/mockup/module-context.js +83 -0
  199. package/dist/mockup/module-context.js.map +1 -0
  200. package/dist/mockup/module-install.d.ts +22 -0
  201. package/dist/mockup/module-install.js +71 -0
  202. package/dist/mockup/module-install.js.map +1 -0
  203. package/dist/mockup/module-states.d.ts +17 -0
  204. package/dist/mockup/module-states.js +167 -0
  205. package/dist/mockup/module-states.js.map +1 -0
  206. package/dist/mockup/modules-schema.d.ts +2 -0
  207. package/dist/mockup/modules-schema.js +38 -0
  208. package/dist/mockup/modules-schema.js.map +1 -0
  209. package/dist/mockup/modules.d.ts +9 -10
  210. package/dist/mockup/modules.js +104 -25
  211. package/dist/mockup/modules.js.map +1 -1
  212. package/dist/mockup/page-capture-routes.d.ts +19 -0
  213. package/dist/mockup/page-capture-routes.js +92 -0
  214. package/dist/mockup/page-capture-routes.js.map +1 -0
  215. package/dist/mockup/page-captures.d.ts +61 -0
  216. package/dist/mockup/page-captures.js +252 -0
  217. package/dist/mockup/page-captures.js.map +1 -0
  218. package/dist/mockup/page-descriptions.d.ts +2 -0
  219. package/dist/mockup/page-descriptions.js +18 -0
  220. package/dist/mockup/page-descriptions.js.map +1 -0
  221. package/dist/mockup/parse-spec.d.ts +10 -0
  222. package/dist/mockup/parse-spec.js +62 -0
  223. package/dist/mockup/parse-spec.js.map +1 -0
  224. package/dist/mockup/places.d.ts +17 -0
  225. package/dist/mockup/places.js +75 -0
  226. package/dist/mockup/places.js.map +1 -0
  227. package/dist/mockup/presence-board.js +1 -1
  228. package/dist/mockup/presence-board.js.map +1 -1
  229. package/dist/mockup/presence-routes.js +2 -2
  230. package/dist/mockup/presence-routes.js.map +1 -1
  231. package/dist/mockup/refusals.d.ts +6 -0
  232. package/dist/mockup/refusals.js +17 -0
  233. package/dist/mockup/refusals.js.map +1 -1
  234. package/dist/mockup/routes.d.ts +3 -5
  235. package/dist/mockup/routes.js +24 -163
  236. package/dist/mockup/routes.js.map +1 -1
  237. package/dist/mockup/sketch-limits.d.ts +1 -0
  238. package/dist/mockup/sketch-limits.js +2 -1
  239. package/dist/mockup/sketch-limits.js.map +1 -1
  240. package/dist/mockup/sketch.d.ts +2 -2
  241. package/dist/mockup/sketch.js +2 -1
  242. package/dist/mockup/sketch.js.map +1 -1
  243. package/dist/mockup/slug.d.ts +3 -0
  244. package/dist/mockup/slug.js +7 -0
  245. package/dist/mockup/slug.js.map +1 -0
  246. package/dist/mockup/source-routes.d.ts +5 -4
  247. package/dist/mockup/source-routes.js +26 -17
  248. package/dist/mockup/source-routes.js.map +1 -1
  249. package/dist/mockup/source.d.ts +3 -3
  250. package/dist/mockup/source.js +4 -3
  251. package/dist/mockup/source.js.map +1 -1
  252. package/dist/mockup/state-patch.d.ts +22 -0
  253. package/dist/mockup/state-patch.js +76 -0
  254. package/dist/mockup/state-patch.js.map +1 -0
  255. package/dist/mockup/state.d.ts +163 -0
  256. package/dist/mockup/state.js +24 -0
  257. package/dist/mockup/state.js.map +1 -0
  258. package/dist/mockup/store-list.d.ts +28 -0
  259. package/dist/mockup/store-list.js +89 -0
  260. package/dist/mockup/store-list.js.map +1 -0
  261. package/dist/mockup/store.d.ts +25 -38
  262. package/dist/mockup/store.js +126 -203
  263. package/dist/mockup/store.js.map +1 -1
  264. package/dist/mockup/table-archive.d.ts +0 -1
  265. package/dist/mockup/table-archive.js +0 -16
  266. package/dist/mockup/table-archive.js.map +1 -1
  267. package/dist/mockup/tenancy.d.ts +19 -0
  268. package/dist/mockup/tenancy.js +73 -0
  269. package/dist/mockup/tenancy.js.map +1 -0
  270. package/dist/mockup/tenant-rows.d.ts +4 -0
  271. package/dist/mockup/tenant-rows.js +19 -0
  272. package/dist/mockup/tenant-rows.js.map +1 -0
  273. package/dist/mockup/unknown-keys.d.ts +2 -2
  274. package/dist/mockup/unknown-keys.js +8 -4
  275. package/dist/mockup/unknown-keys.js.map +1 -1
  276. package/dist/mockup/validate.d.ts +2 -2
  277. package/dist/mockup/validate.js.map +1 -1
  278. package/dist/store/catalog.d.ts +5 -1
  279. package/dist/store/catalog.js +12 -1
  280. package/dist/store/catalog.js.map +1 -1
  281. package/dist/store/changes.d.ts +3 -0
  282. package/dist/store/changes.js +22 -0
  283. package/dist/store/changes.js.map +1 -0
  284. package/dist/store/index.d.ts +2 -0
  285. package/dist/store/index.js +2 -0
  286. package/dist/store/index.js.map +1 -1
  287. package/dist/store/listing.js +5 -5
  288. package/dist/store/listing.js.map +1 -1
  289. package/dist/store/operations.d.ts +8 -0
  290. package/dist/store/operations.js +27 -3
  291. package/dist/store/operations.js.map +1 -1
  292. package/dist/store/registry.d.ts +1 -0
  293. package/dist/store/registry.js +9 -0
  294. package/dist/store/registry.js.map +1 -1
  295. package/dist/store/types.d.ts +3 -0
  296. package/dist/types/index.d.ts +1 -0
  297. package/dist/types/index.js +1 -0
  298. package/dist/types/index.js.map +1 -1
  299. package/dist/types/live-pages.d.ts +41 -0
  300. package/dist/types/live-pages.js +3 -0
  301. package/dist/types/live-pages.js.map +1 -0
  302. package/dist/validation/store.schema.d.ts +1 -0
  303. package/dist/validation/store.schema.js +4 -4
  304. package/dist/validation/store.schema.js.map +1 -1
  305. package/e2e/index.mjs +3 -2
  306. package/frontend-vue/build/viewer-chunks.ts +181 -0
  307. package/frontend-vue/dms.frontend.build.ts +2 -1
  308. package/frontend-vue/dms.frontend.ts +7 -0
  309. package/frontend-vue/eslint-globals.generated.mjs +27 -24
  310. package/frontend-vue/layers/dms-core/app/build/utils/asyncDataScope.ts +3 -31
  311. package/frontend-vue/layers/dms-core/app/build/utils/previewFrame.ts +6 -1
  312. package/frontend-vue/layers/dms-core/app/composables/auth/useAuthFetch.ts +8 -2
  313. package/frontend-vue/layers/dms-core/app/utils/localFetchAnswers.ts +124 -0
  314. package/frontend-vue/layers/dms-core/app/utils/textDigest.ts +29 -0
  315. package/frontend-vue/layers/dms-core/i18n/locales/core-en-GB.json +4 -0
  316. package/frontend-vue/layers/dms-core/i18n/locales/core-fr-FR.json +4 -0
  317. package/frontend-vue/layers/dms-layout/app/build/components/layout/DashboardSidebar.vue +89 -31
  318. package/frontend-vue/layers/dms-layout/app/build/components/layout/MockupSidebarMenu.vue +21 -6
  319. package/frontend-vue/layers/dms-layout/app/build/components/layout/SidebarUserMenu.vue +61 -8
  320. package/frontend-vue/layers/dms-layout/app/build/components/layout/mockupMenu.ts +79 -9
  321. package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/shell/SettingsNav.vue +57 -8
  322. package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/shell/SettingsShell.vue +12 -0
  323. package/frontend-vue/layers/dms-layout/app/build/composables/settings/useSettingsNavigation.ts +42 -62
  324. package/frontend-vue/layers/dms-layout/app/build/mockups/created-mockups.ts +12 -2
  325. package/frontend-vue/layers/dms-layout/app/build/mockups/created-toast.ts +9 -1
  326. package/frontend-vue/layers/dms-layout/app/composables/page/useMockupStoreInstaller.ts +85 -0
  327. package/frontend-vue/layers/dms-layout/app/custom-layouts/MockupLayout.vue +0 -2
  328. package/frontend-vue/layers/dms-layout/app/custom-layouts/PreviewLayout.vue +53 -6
  329. package/frontend-vue/layers/dms-layout/app/plugins/mockup-store-installer.ts +10 -0
  330. package/frontend-vue/layers/dms-layout/app/plugins/registered-sidebar-widgets.ts +10 -0
  331. package/frontend-vue/layers/dms-layout/app/plugins/seo.ts +7 -0
  332. package/frontend-vue/layers/dms-layout/app/theme/actions.ts +11 -7
  333. package/frontend-vue/layers/dms-onboarding/app/middleware/onboarding.global.ts +3 -3
  334. package/frontend-vue/layers/dms-onboarding/app/plugins/onboarding-preload.ts +5 -1
  335. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/BlockPreviewSketch.vue +31 -5
  336. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupCanvasChrome.vue +2 -2
  337. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupDatabase.vue +204 -0
  338. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupDatabaseData.vue +288 -0
  339. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupDatabaseDiagram.vue +91 -0
  340. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupDatabaseRelationEdge.vue +40 -0
  341. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupDatabaseTableNode.vue +133 -0
  342. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupEmptyState.vue +23 -0
  343. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupModuleStore.vue +240 -0
  344. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupOverview.vue +54 -33
  345. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupOverviewSectionLabel.vue +52 -0
  346. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupOverviewSlot.vue +65 -12
  347. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupPagesList.vue +21 -0
  348. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupPinCard.vue +1 -1
  349. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupPinLayer.vue +1 -1
  350. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupReconnecting.vue +17 -0
  351. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupTenantBanner.vue +48 -0
  352. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupTitle.vue +24 -15
  353. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupToolbar.vue +196 -0
  354. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupTopBar.vue +200 -179
  355. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupWarningsMenu.vue +59 -0
  356. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupWorkbench.vue +152 -57
  357. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupWorkspaceSwitcher.vue +142 -0
  358. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/previewAdmission.ts +20 -0
  359. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/previewCapture.ts +71 -4
  360. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/previewNavigation.ts +44 -4
  361. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/previewSwapHold.ts +157 -0
  362. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/registeredSidebarWidgets.ts +20 -0
  363. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/storeModuleInstaller.ts +32 -0
  364. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useBlockInspector.ts +14 -2
  365. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useBlockPreviewEmbed.ts +309 -41
  366. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useFixtureBatches.ts +154 -0
  367. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupActivation.ts +182 -0
  368. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupConnectionTables.ts +80 -0
  369. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupDatabase.ts +212 -0
  370. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupEditing.ts +13 -1
  371. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupFrameRender.ts +126 -0
  372. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupFrameSize.ts +10 -5
  373. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupOverview.ts +50 -23
  374. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupPageFrame.ts +103 -29
  375. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupPageZoom.ts +146 -0
  376. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupPdfExport.ts +124 -0
  377. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupPins.ts +1 -1
  378. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupRealData.ts +11 -4
  379. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupRoutePage.ts +60 -14
  380. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupSession.ts +8 -3
  381. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupSpec.ts +6 -2
  382. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupTenancy.ts +36 -0
  383. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupToolModes.ts +5 -7
  384. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupViewerActivation.ts +59 -0
  385. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupViewerExport.ts +46 -0
  386. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupViewerPages.ts +44 -10
  387. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupViewerShortcuts.ts +13 -2
  388. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useMockupWarningFocus.ts +145 -0
  389. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/useOverviewCaptures.ts +39 -10
  390. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/usePersistedCaptures.ts +151 -0
  391. package/frontend-vue/layers/dms-ui/app/build/composables/block-preview/usePreviewFrame.ts +41 -0
  392. package/frontend-vue/layers/dms-ui/app/build/mockups/MockupCards.vue +37 -3
  393. package/frontend-vue/layers/dms-ui/app/build/mockups/MockupCreateModal.vue +130 -0
  394. package/frontend-vue/layers/dms-ui/app/build/mockups/manage.ts +20 -1
  395. package/frontend-vue/layers/dms-ui/app/build/utils/blockPreview.ts +137 -78
  396. package/frontend-vue/layers/dms-ui/app/build/utils/blockPreviewChannel.ts +1 -8
  397. package/frontend-vue/layers/dms-ui/app/build/utils/blockPreviewMessages.ts +165 -103
  398. package/frontend-vue/layers/dms-ui/app/build/utils/blockPreviewNavigation.ts +321 -0
  399. package/frontend-vue/layers/dms-ui/app/build/utils/blockPreviewRects.ts +22 -0
  400. package/frontend-vue/layers/dms-ui/app/build/utils/mockup.ts +112 -175
  401. package/frontend-vue/layers/dms-ui/app/build/utils/mockupActivation.ts +120 -0
  402. package/frontend-vue/layers/dms-ui/app/build/utils/mockupAnnotations.ts +146 -0
  403. package/frontend-vue/layers/dms-ui/app/build/utils/mockupCaptures.ts +118 -9
  404. package/frontend-vue/layers/dms-ui/app/build/utils/mockupDiagram.ts +330 -0
  405. package/frontend-vue/layers/dms-ui/app/build/utils/mockupEntities.ts +80 -0
  406. package/frontend-vue/layers/dms-ui/app/build/utils/mockupFrame.ts +123 -8
  407. package/frontend-vue/layers/dms-ui/app/build/utils/mockupLinks.ts +11 -2
  408. package/frontend-vue/layers/dms-ui/app/build/utils/mockupModuleNavigation.ts +215 -0
  409. package/frontend-vue/layers/dms-ui/app/build/utils/mockupModules.ts +240 -0
  410. package/frontend-vue/layers/dms-ui/app/build/utils/mockupOverview.ts +21 -3
  411. package/frontend-vue/layers/dms-ui/app/build/utils/mockupOverviewSections.ts +66 -0
  412. package/frontend-vue/layers/dms-ui/app/build/utils/mockupPageTree.ts +15 -0
  413. package/frontend-vue/layers/dms-ui/app/build/utils/mockupPins.ts +6 -8
  414. package/frontend-vue/layers/dms-ui/app/build/utils/mockupRealData.ts +23 -5
  415. package/frontend-vue/layers/dms-ui/app/build/utils/mockupRows.ts +83 -0
  416. package/frontend-vue/layers/dms-ui/app/build/utils/mockupSchema.ts +173 -0
  417. package/frontend-vue/layers/dms-ui/app/build/utils/mockupSettings.ts +218 -0
  418. package/frontend-vue/layers/dms-ui/app/build/utils/mockupShortcuts.ts +17 -6
  419. package/frontend-vue/layers/dms-ui/app/build/utils/mockupSpec.ts +20 -0
  420. package/frontend-vue/layers/dms-ui/app/build/utils/mockupStatePatch.ts +180 -0
  421. package/frontend-vue/layers/dms-ui/app/build/utils/mockupStream.ts +17 -2
  422. package/frontend-vue/layers/dms-ui/app/build/utils/mockupTenancy.ts +148 -0
  423. package/frontend-vue/layers/dms-ui/app/build/utils/mockupTenants.ts +23 -0
  424. package/frontend-vue/layers/dms-ui/app/build/utils/mockupTitles.ts +33 -0
  425. package/frontend-vue/layers/dms-ui/app/build/utils/mockupVersions.ts +2 -7
  426. package/frontend-vue/layers/dms-ui/app/build/utils/previewFixtureAnswers.ts +156 -0
  427. package/frontend-vue/layers/dms-ui/app/build/utils/previewFixturesOnly.ts +37 -19
  428. package/frontend-vue/layers/dms-ui/app/build/utils/previewOptionRules.ts +129 -0
  429. package/frontend-vue/layers/dms-ui/app/build/utils/previewPageLayout.ts +108 -6
  430. package/frontend-vue/layers/dms-ui/app/build/utils/previewPageQuery.ts +5 -1
  431. package/frontend-vue/layers/dms-ui/app/build/utils/previewRows.ts +400 -0
  432. package/frontend-vue/layers/dms-ui/app/build/utils/recordGuards.ts +15 -0
  433. package/frontend-vue/layers/dms-ui/app/build/utils/settingsGroups.ts +73 -0
  434. package/frontend-vue/layers/dms-ui/app/build/utils/sketch.ts +68 -12
  435. package/frontend-vue/layers/dms-ui/app/build/utils/urlVariables.ts +15 -0
  436. package/frontend-vue/layers/dms-ui/app/components/block-preview/BlockPreview.vue +61 -12
  437. package/frontend-vue/layers/dms-ui/app/components/block-preview/MockupViewer.vue +4 -1
  438. package/frontend-vue/layers/dms-ui/app/entries/components/block-preview/MockupModuleStore.ts +2 -0
  439. package/frontend-vue/layers/dms-ui/app/entries/components/block-preview/MockupTenantBanner.ts +2 -0
  440. package/frontend-vue/layers/dms-ui/app/entries/components/block-preview/MockupWorkspaceSwitcher.ts +2 -0
  441. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/registeredSidebarWidgets.ts +1 -0
  442. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/storeModuleInstaller.ts +1 -0
  443. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useFixtureBatches.ts +1 -0
  444. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupActivation.ts +1 -0
  445. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupOverview.ts +1 -0
  446. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupPdfExport.ts +1 -0
  447. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupRoutePage.ts +1 -0
  448. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupSession.ts +1 -0
  449. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/useMockupTenancy.ts +1 -0
  450. package/frontend-vue/layers/dms-ui/app/entries/composables/block-preview/usePersistedCaptures.ts +1 -0
  451. package/frontend-vue/layers/dms-ui/app/entries/utils/blockPreview.ts +1 -0
  452. package/frontend-vue/layers/dms-ui/app/entries/utils/json.ts +1 -0
  453. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupActivation.ts +1 -0
  454. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupAnnotations.ts +1 -0
  455. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupDiagram.ts +1 -0
  456. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupModuleNavigation.ts +1 -0
  457. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupOverviewSections.ts +1 -0
  458. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupRows.ts +1 -0
  459. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupSchema.ts +1 -0
  460. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupSettings.ts +1 -0
  461. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupStatePatch.ts +1 -0
  462. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupTenancy.ts +1 -0
  463. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupTenants.ts +1 -0
  464. package/frontend-vue/layers/dms-ui/app/entries/utils/mockupTitles.ts +1 -0
  465. package/frontend-vue/layers/dms-ui/app/entries/utils/previewFixtureAnswers.ts +1 -0
  466. package/frontend-vue/layers/dms-ui/app/entries/utils/previewRows.ts +1 -0
  467. package/frontend-vue/layers/dms-ui/app/entries/utils/settingsGroups.ts +1 -0
  468. package/frontend-vue/layers/dms-ui/i18n/locales/ui-en-GB.json +85 -7
  469. package/frontend-vue/layers/dms-ui/i18n/locales/ui-fr-FR.json +85 -7
  470. package/frontend-vue/package.json +2 -2
  471. package/frontend-vue/scripts/test-dms-components.mjs +1 -1
  472. package/package.json +6 -5
  473. package/dist/mockup/row-filters.d.ts +0 -8
  474. package/dist/mockup/row-filters.js +0 -107
  475. package/dist/mockup/row-filters.js.map +0 -1
  476. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupModules.vue +0 -47
  477. package/frontend-vue/layers/dms-ui/app/build/components/block-preview/MockupOverviewZoom.vue +0 -67
@@ -1 +1 @@
1
- {"version":3,"file":"annotations.js","sourceRoot":"","sources":["../../src/mockup/annotations.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,6CAA0C;AAC1C,6BAAwB;AACxB,qCAQkB;AAClB,uCAAsC;AACtC,yDAU4B;AAC5B,mCAA6D;AAC7D,uCAA0C;AAQ1C,mCAAiE;AACjE,qCAAgD;AAChD,qCAKkB;AAElB,MAAM,QAAQ,GAAG,IAAI,CAAC;AACtB,MAAM,WAAW,GAAG,IAAI,CAAC;AACzB,MAAM,QAAQ,GAAG,EAAE,CAAC;AAEpB,MAAM,UAAU,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;AAG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,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;QAC/D,IAAI,IAAI,CAAC,MAAM,KAAK,IAAI,CAAC,WAAW,CAAC,MAAM;YAAE,OAAO,KAAK,CAAC;QAC1D,MAAM,IAAA,uCAAoB,EAAC,IAAI,CAAC,IAAI,EAAE,EAAE,GAAG,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC;QACtE,OAAO,IAAI,CAAC;IACd,CAAC,CAAC,CAAC;AACL,CAAC"}
@@ -13,6 +13,6 @@ exports.WIRING_REASONS = {
13
13
  name: "a new block whose id gives it the block name of another block at its place. Give the node an id of its own.",
14
14
  placement: "a slot or colSpan on a block at the page's top level, which the builder lays out in order only: the block was written without it.",
15
15
  "header-actions": "the page's headerActions, the buttons right of its title: the builder cannot write a page's layout. Declare them in the page's DefaultLayout({ headerActions }), each with the target its button needs and the confirm the spec writes: a 'page:<id>' target opens the live page that spec page is built into.",
16
- layout: "the page's layout, the frame it is drawn in: the builder cannot write a page's layout. Declare it as the page's layout argument, the factory the layout names (DefaultLayout, FormPageLayout, SettingsLayout or EmptyLayout) called with its options.",
16
+ layout: "the page's layout, the frame it is drawn in: the builder cannot write a page's layout. Declare it as the page's layout argument, the factory the layout names (DefaultLayout, FormPageLayout, SettingsLayout or EmptyLayout) called with its options. A custom layout, { type: 'custom', id }, is a layout of the project: write it as a Vue layout component and the factory returning its ComponentInfo, from the sketch regions the spec's layouts entry of that id draws (header, aside, footer), never in interface-dms, and declare the page with that factory.",
17
17
  };
18
18
  //# sourceMappingURL=apply-notes.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"apply-notes.js","sourceRoot":"","sources":["../../src/mockup/apply-notes.ts"],"names":[],"mappings":";;;AAea,QAAA,cAAc,GAA2C;IACpE,IAAI,EAAE,uLAAuL;IAC7L,kBAAkB,EAChB,kHAAkH;IACpH,KAAK,EACH,yIAAyI;IAC3I,YAAY,EACV,gIAAgI;IAClI,IAAI,EAAE,0IAA0I;IAChJ,MAAM,EACJ,gOAAgO;IAClO,MAAM,EACJ,gIAAgI;IAClI,IAAI,EAAE,8GAA8G;IACpH,IAAI,EAAE,6GAA6G;IACnH,SAAS,EACP,mIAAmI;IACrI,gBAAgB,EACd,gTAAgT;IAClT,MAAM,EACJ,uPAAuP;CAC1P,CAAC"}
1
+ {"version":3,"file":"apply-notes.js","sourceRoot":"","sources":["../../src/mockup/apply-notes.ts"],"names":[],"mappings":";;;AAea,QAAA,cAAc,GAA2C;IACpE,IAAI,EAAE,uLAAuL;IAC7L,kBAAkB,EAChB,kHAAkH;IACpH,KAAK,EACH,yIAAyI;IAC3I,YAAY,EACV,gIAAgI;IAClI,IAAI,EAAE,0IAA0I;IAChJ,MAAM,EACJ,gOAAgO;IAClO,MAAM,EACJ,gIAAgI;IAClI,IAAI,EAAE,8GAA8G;IACpH,IAAI,EAAE,6GAA6G;IACnH,SAAS,EACP,mIAAmI;IACrI,gBAAgB,EACd,gTAAgT;IAClT,MAAM,EACJ,uiBAAuiB;CAC1iB,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { MockupCustomLayout, MockupCustomLayoutState, MockupIssue, MockupPageLayout, MockupPageLayoutState } from "./model";
2
+ export type CustomLayouts = ReadonlyMap<string, MockupCustomLayoutState>;
3
+ export declare function compileLayouts(layouts: readonly MockupCustomLayout[], issues: MockupIssue[]): CustomLayouts;
4
+ export declare const SETTINGS_LAYOUT_STATE: MockupPageLayoutState;
5
+ export declare function layoutStateOf(layout: MockupPageLayout | undefined, inSettings: boolean, layouts: CustomLayouts): MockupPageLayoutState | undefined;
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SETTINGS_LAYOUT_STATE = void 0;
4
+ exports.compileLayouts = compileLayouts;
5
+ exports.layoutStateOf = layoutStateOf;
6
+ const layouts_1 = require("./layouts");
7
+ const model_1 = require("./model");
8
+ const sketch_1 = require("./sketch");
9
+ function compileRegion(source, pointer, issues) {
10
+ const checked = (0, sketch_1.checkSketch)(source);
11
+ if (checked.ok)
12
+ return checked.sketch;
13
+ for (const { field, what } of checked.refusals) {
14
+ issues.push({
15
+ path: `${pointer}/${field}`,
16
+ message: `a layout region is static HTML and CSS, so it may not hold ${what}`,
17
+ });
18
+ }
19
+ return { html: "" };
20
+ }
21
+ function regionState(region, at, pointer, issues) {
22
+ const { html, css } = region;
23
+ const drawn = compileRegion(css === undefined ? { html } : { html, css }, pointer, issues);
24
+ const state = {
25
+ html: drawn.html,
26
+ height: region.height ?? model_1.LAYOUT_REGION_DEFAULT_HEIGHTS[at],
27
+ };
28
+ if (drawn.css !== undefined)
29
+ state.css = drawn.css;
30
+ return state;
31
+ }
32
+ function compileLayout(layout, pointer, issues) {
33
+ const state = {
34
+ type: "custom",
35
+ id: layout.id,
36
+ title: layout.title,
37
+ dashboard: layout.dashboard ?? true,
38
+ };
39
+ if (layout.header) {
40
+ state.header = regionState(layout.header, "header", `${pointer}/header`, issues);
41
+ }
42
+ if (layout.aside) {
43
+ const aside = {
44
+ ...regionState(layout.aside, "aside", `${pointer}/aside`, issues),
45
+ width: layout.aside.width ?? model_1.LAYOUT_ASIDE_DEFAULT_WIDTH,
46
+ side: layout.aside.side ?? model_1.LAYOUT_ASIDE_DEFAULT_SIDE,
47
+ };
48
+ state.aside = aside;
49
+ }
50
+ if (layout.footer) {
51
+ state.footer = regionState(layout.footer, "footer", `${pointer}/footer`, issues);
52
+ }
53
+ return state;
54
+ }
55
+ function compileLayouts(layouts, issues) {
56
+ const compiled = new Map();
57
+ layouts.forEach((layout, index) => {
58
+ const state = compileLayout(layout, `/layouts/${index}`, issues);
59
+ if (!compiled.has(layout.id))
60
+ compiled.set(layout.id, state);
61
+ });
62
+ return compiled;
63
+ }
64
+ exports.SETTINGS_LAYOUT_STATE = {
65
+ type: "settings",
66
+ };
67
+ function layoutStateOf(layout, inSettings, layouts) {
68
+ if (layout === undefined)
69
+ return inSettings ? exports.SETTINGS_LAYOUT_STATE : undefined;
70
+ if (!(0, layouts_1.isCustomLayoutRef)(layout))
71
+ return layout;
72
+ return layouts.get(layout.id);
73
+ }
74
+ //# sourceMappingURL=compile-layouts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compile-layouts.js","sourceRoot":"","sources":["../../src/mockup/compile-layouts.ts"],"names":[],"mappings":";;;;;AAAA,uCAA8C;AAU9C,mCAIiB;AACjB,qCAA0D;AAU1D,SAAS,aAAa,CACpB,MAAoB,EACpB,OAAe,EACf,MAAqB;IAErB,MAAM,OAAO,GAAG,IAAA,oBAAW,EAAC,MAAM,CAAC,CAAC;IACpC,IAAI,OAAO,CAAC,EAAE;QAAE,OAAO,OAAO,CAAC,MAAM,CAAC;IACtC,KAAK,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,IAAI,OAAO,CAAC,QAAQ,EAAE,CAAC;QAC/C,MAAM,CAAC,IAAI,CAAC;YACV,IAAI,EAAE,GAAG,OAAO,IAAI,KAAK,EAAE;YAC3B,OAAO,EAAE,8DAA8D,IAAI,EAAE;SAC9E,CAAC,CAAC;IACL,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;AACtB,CAAC;AAED,SAAS,WAAW,CAClB,MAAuD,EACvD,EAA8C,EAC9C,OAAe,EACf,MAAqB;IAErB,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,MAAM,CAAC;IAC7B,MAAM,KAAK,GAAG,aAAa,CACzB,GAAG,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,GAAG,EAAE,EAC5C,OAAO,EACP,MAAM,CACP,CAAC;IACF,MAAM,KAAK,GAA4B;QACrC,IAAI,EAAE,KAAK,CAAC,IAAI;QAChB,MAAM,EAAE,MAAM,CAAC,MAAM,IAAI,qCAA6B,CAAC,EAAE,CAAC;KAC3D,CAAC;IACF,IAAI,KAAK,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C,MAAM,KAAK,GAAG,aAAa,CAAC,MAAM,EAAE,YAAY,KAAK,EAAE,EAAE,MAAM,CAAC,CAAC;QACjE,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;YAAE,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;IAC/D,CAAC,CAAC,CAAC;IACH,OAAO,QAAQ,CAAC;AAClB,CAAC;AAGY,QAAA,qBAAqB,GAA0B;IAC1D,IAAI,EAAE,UAAU;CACjB,CAAC;AAQF,uBACE,MAAoC,EACpC,UAAmB,EACnB,OAAsB;IAEtB,IAAI,MAAM,KAAK,SAAS;QACtB,OAAO,UAAU,CAAC,CAAC,CAAC,QAAA,qBAAqB,CAAC,CAAC,CAAC,SAAS,CAAC;IACxD,IAAI,CAAC,IAAA,2BAAiB,EAAC,MAAM,CAAC;QAAE,OAAO,MAAM,CAAC;IAC9C,OAAO,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAChC,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { type CompiledSpec } from "./compile";
2
+ import type { MockupName, MockupSpec } from "./model";
3
+ import { type ModuleLoader } from "./module-context";
4
+ export declare const loadForViewer: ModuleLoader;
5
+ export declare function compileSpecWithModules(name: MockupName, spec: MockupSpec, now?: number, load?: ModuleLoader): Promise<CompiledSpec>;
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.loadForViewer = void 0;
4
+ exports.compileSpecWithModules = compileSpecWithModules;
5
+ const compile_1 = require("./compile");
6
+ const module_context_1 = require("./module-context");
7
+ const module_states_1 = require("./module-states");
8
+ function extensionTargets(pages) {
9
+ return [
10
+ ...new Set(pages.flatMap((page) => page.extends === undefined ? [] : [page.extends])),
11
+ ];
12
+ }
13
+ const EXTENDS_WARNING_PATH = /^\/pages\/(\d+)\/extends$/;
14
+ function withoutCoveredTargets(warnings, spec, missing) {
15
+ return warnings.filter((warning) => {
16
+ const index = EXTENDS_WARNING_PATH.exec(warning.path)?.[1];
17
+ const target = index === undefined ? undefined : spec.pages[Number(index)]?.extends;
18
+ return target === undefined || !missing.has(target.split(".")[0] ?? target);
19
+ });
20
+ }
21
+ const loadForViewer = (modules, targets) => (0, module_context_1.loadModuleContext)(modules, { targets, withSettings: true });
22
+ exports.loadForViewer = loadForViewer;
23
+ async function compileSpecWithModules(name, spec, now = Date.now(), load = (modules, targets) => (0, module_context_1.loadModuleContext)(modules, { targets })) {
24
+ const listed = spec.modules ?? [];
25
+ const context = await load(listed, extensionTargets(spec.pages));
26
+ const compiled = (0, compile_1.compileSpec)(name, spec, now, context.live);
27
+ const { modules, issues, warnings } = (0, module_states_1.compileModules)(listed, context);
28
+ const missing = new Set(modules.flatMap((module) => module.kind === "catalog" && !module.installed ? [module.id] : []));
29
+ return {
30
+ ...compiled,
31
+ ...(modules.length > 0 && { modules }),
32
+ ...(context.settings && { settings: context.settings }),
33
+ issues: [...compiled.issues, ...issues],
34
+ warnings: [
35
+ ...withoutCoveredTargets(compiled.warnings, spec, missing),
36
+ ...warnings,
37
+ ],
38
+ };
39
+ }
40
+ //# sourceMappingURL=compile-modules.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compile-modules.js","sourceRoot":"","sources":["../../src/mockup/compile-modules.ts"],"names":[],"mappings":";;;;AAAA,uCAA2D;AAO3D,qDAAwE;AACxE,mDAAiD;AAGjD,SAAS,gBAAgB,CACvB,KAAiD;IAEjD,OAAO;QACL,GAAG,IAAI,GAAG,CACR,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE,CACrB,IAAI,CAAC,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CACjD,CACF;KACF,CAAC;AACJ,CAAC;AAED,MAAM,oBAAoB,GAAG,2BAA2B,CAAC;AAQzD,SAA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AAM,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,IAAA,8BAAc,EAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACtE,MAAM,OAAO,GAAG,IAAI,GAAG,CACrB,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE,CACzB,MAAM,CAAC,IAAI,KAAK,SAAS,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAClE,CACF,CAAC;IACF,OAAO;QACL,GAAG,QAAQ;QACX,GAAG,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,IAAI,EAAE,OAAO,EAAE,CAAC;QACtC,GAAG,CAAC,OAAO,CAAC,QAAQ,IAAI,EAAE,QAAQ,EAAE,OAAO,CAAC,QAAQ,EAAE,CAAC;QACvD,MAAM,EAAE,CAAC,GAAG,QAAQ,CAAC,MAAM,EAAE,GAAG,MAAM,CAAC;QACvC,QAAQ,EAAE;YACR,GAAG,qBAAqB,CAAC,QAAQ,CAAC,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC;YAC1D,GAAG,QAAQ;SACZ;KACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { type Catalog } from "./block-catalog";
2
+ import type { FixtureScope } from "./fixtures";
3
+ import { type FixtureAnswers } from "./fixture-answers";
4
+ import type { MockupNode } from "./model";
5
+ export interface PageScope extends FixtureScope {
6
+ catalog: Catalog;
7
+ paths: Record<string, string>;
8
+ answers: FixtureAnswers;
9
+ }
10
+ export declare function compileNode(node: MockupNode, pointer: string, layoutPath: string, scope: PageScope): MockupNode;
11
+ export declare const ROOT_LAYOUT_PREFIX = "block-";
@@ -0,0 +1,119 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ROOT_LAYOUT_PREFIX = void 0;
4
+ exports.compileNode = compileNode;
5
+ const block_catalog_1 = require("./block-catalog");
6
+ const controller_blocks_1 = require("./controller-blocks");
7
+ const fixtures_1 = require("./fixtures");
8
+ const fixture_answers_1 = require("./fixture-answers");
9
+ const form_fields_1 = require("./form-fields");
10
+ const page_links_1 = require("./page-links");
11
+ const sample_routes_1 = require("./sample-routes");
12
+ const sketch_1 = require("./sketch");
13
+ const validate_1 = require("./validate");
14
+ function compileChildren(node, pointer, layoutPath, scope) {
15
+ if (!node.children)
16
+ return node;
17
+ const children = node.children.map((child, index) => {
18
+ const childPointer = `${pointer}/children/${index}`;
19
+ const childPath = `${layoutPath}.${child.id ?? index}`;
20
+ if (Object.hasOwn(scope.paths, childPath)) {
21
+ scope.issues.push({
22
+ path: child.id === undefined ? childPointer : `${childPointer}/id`,
23
+ message: `another child of this block already has the id "${child.id ?? index}"`,
24
+ });
25
+ }
26
+ return compileNode(child, childPointer, childPath, scope);
27
+ });
28
+ return { ...node, children };
29
+ }
30
+ function withOptions(node, pointer, scope) {
31
+ return {
32
+ ...node,
33
+ options: (0, fixtures_1.rewriteObject)(node.options ?? {}, `${pointer}/options`, scope),
34
+ };
35
+ }
36
+ const sketchKind = {
37
+ resolve: (node, scope) => node.type === sketch_1.SKETCH_TYPE
38
+ ? (pointer) => (0, sketch_1.compileSketch)(node, pointer, scope.issues, (0, page_links_1.sketchLinks)(scope))
39
+ : undefined,
40
+ };
41
+ const controllerKind = {
42
+ resolve(node, scope) {
43
+ const descriptor = (0, block_catalog_1.descriptorOf)(node, scope.catalog);
44
+ if (!descriptor?.controllerArg)
45
+ return undefined;
46
+ const block = controller_blocks_1.CONTROLLER_BLOCKS.get(descriptor.type);
47
+ return (pointer, layoutPath) => {
48
+ if (block) {
49
+ const built = block.compile(node, pointer, scope);
50
+ return compileChildren(built, pointer, layoutPath, scope);
51
+ }
52
+ scope.issues.push({
53
+ path: pointer,
54
+ message: `${descriptor.type} needs a controller class, which a mockup cannot build: draw it with a sketch`,
55
+ });
56
+ return compileChildren(withOptions(node, pointer, scope), pointer, layoutPath, scope);
57
+ };
58
+ },
59
+ };
60
+ const blockKind = {
61
+ resolve(node, scope) {
62
+ const descriptor = (0, block_catalog_1.descriptorOf)(node, scope.catalog);
63
+ if (!descriptor)
64
+ return undefined;
65
+ return (pointer, layoutPath) => {
66
+ const compiled = withOptions(node, pointer, scope);
67
+ (0, validate_1.validateBlockOptions)(descriptor, node, compiled.options, `${pointer}/options`, scope);
68
+ (0, validate_1.validateBlockChildren)(descriptor, node, pointer, scope.issues, (child) => (0, block_catalog_1.descriptorOf)(child, scope.catalog)?.type ?? child.type);
69
+ const options = (0, form_fields_1.withFieldInputs)(descriptor, compiled.options, `${pointer}/options`, scope.issues);
70
+ return compileChildren({ ...compiled, options: (0, validate_1.componentOptionsOf)(descriptor, options) }, pointer, layoutPath, scope);
71
+ };
72
+ },
73
+ };
74
+ function unknownIssue(node, pointer) {
75
+ if (node.type !== undefined) {
76
+ return {
77
+ path: `${pointer}/type`,
78
+ message: `no block type is registered as "${node.type}"`,
79
+ };
80
+ }
81
+ if (node.componentName !== undefined) {
82
+ return {
83
+ path: `${pointer}/componentName`,
84
+ message: `no registered block emits the component "${node.componentName}"`,
85
+ };
86
+ }
87
+ return { path: pointer, message: "a node needs a type or a componentName" };
88
+ }
89
+ const unknownKind = {
90
+ resolve: (node, scope) => (pointer, layoutPath) => {
91
+ scope.issues.push(unknownIssue(node, pointer));
92
+ return compileChildren(withOptions(node, pointer, scope), pointer, layoutPath, scope);
93
+ },
94
+ };
95
+ const NODE_KINDS = [
96
+ sketchKind,
97
+ controllerKind,
98
+ blockKind,
99
+ unknownKind,
100
+ ];
101
+ function drawnOn(node, scope) {
102
+ if (scope.routes || !node.options)
103
+ return node;
104
+ return { ...node, options: (0, sample_routes_1.confineToFixtures)(node.options, scope) };
105
+ }
106
+ function compileNode(node, pointer, layoutPath, scope) {
107
+ scope.paths[layoutPath] = pointer;
108
+ const descriptor = (0, block_catalog_1.descriptorOf)(node, scope.catalog);
109
+ if (descriptor)
110
+ (0, fixture_answers_1.checkFixtureAnswer)(descriptor, node, pointer, scope);
111
+ for (const kind of NODE_KINDS) {
112
+ const compile = kind.resolve(node, scope);
113
+ if (compile)
114
+ return drawnOn(compile(pointer, layoutPath), scope);
115
+ }
116
+ return node;
117
+ }
118
+ exports.ROOT_LAYOUT_PREFIX = "block-";
119
+ //# sourceMappingURL=compile-nodes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compile-nodes.js","sourceRoot":"","sources":["../../src/mockup/compile-nodes.ts"],"names":[],"mappings":";;;;AAAA,mDAA6D;AAC7D,2DAAwD;AAExD,yCAA2C;AAC3C,uDAA4E;AAC5E,+CAAgD;AAEhD,6CAA2C;AAC3C,mDAAoD;AACpD,qCAAsD;AACtD,yCAIoB;AAmBpB,SAAS,eAAe,CACtB,IAAgB,EAChB,OAAe,EACf,UAAkB,EAClB,KAAgB;IAEhB,IAAI,CAAC,IAAI,CAAC,QAAQ;QAAE,OAAO,IAAI,CAAC;IAChC,MAAM,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE;QAClD,MAAM,YAAY,GAAG,GAAG,OAAO,aAAa,KAAK,EAAE,CAAC;QACpD,MAAM,SAAS,GAAG,GAAG,UAAU,IAAI,KAAK,CAAC,EAAE,IAAI,KAAK,EAAE,CAAC;QACvD,IAAI,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,EAAE,SAAS,CAAC,EAAE,CAAC;YAC1C,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC;gBAChB,IAAI,EAAE,KAAK,CAAC,EAAE,KAAK,SAAS,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,GAAG,YAAY,KAAK;gBAClE,OAAO,EAAE,mDAAmD,KAAK,CAAC,EAAE,IAAI,KAAK,GAAG;aACjF,CAAC,CAAC;QACL,CAAC;QACD,OAAO,WAAW,CAAC,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,KAAK,CAAC,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,KAAK,CAAC,UAAU,CAAC,GAAG,OAAO,CAAC;IAClC,MAAM,UAAU,GAAG,IAAA,4BAAY,EAAC,IAAI,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IACrD,IAAI,UAAU;QAAE,IAAA,oCAAkB,EAAC,UAAU,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,CAAC;IACrE,KAAK,MAAM,IAAI,IAAI,UAAU,EAAE,CAAC;QAC9B,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;QAC1C,IAAI,OAAO;YAAE,OAAO,OAAO,CAAC,OAAO,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,KAAK,CAAC,CAAC;IACnE,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAGY,QAAA,kBAAkB,GAAG,QAAQ,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { type CustomLayouts } from "./compile-layouts";
2
+ import { type PageScope } from "./compile-nodes";
3
+ import type { RegisteredPage } from "../types";
4
+ import type { JsonObject, MockupName, MockupPageState, MockupSpecPage } from "./model";
5
+ import { type LinkedPage } from "./page-links";
6
+ import { type PlacedEntry } from "./places";
7
+ export type SpecPage = MockupSpecPage & {
8
+ pointer: string;
9
+ };
10
+ export type PageGraph = ReadonlyMap<string, LinkedPage>;
11
+ export declare function pageGraph(pages: readonly MockupSpecPage[]): PageGraph;
12
+ export interface SpecScope extends Pick<PageScope, "catalog" | "issues" | "warnings" | "answers"> {
13
+ name: MockupName;
14
+ layouts: CustomLayouts;
15
+ graph: PageGraph;
16
+ fixtures: ReadonlyMap<string, JsonObject>;
17
+ live: ReadonlyMap<string, RegisteredPage>;
18
+ generated: MockupPageState[];
19
+ }
20
+ export declare function compileEntry(entry: PlacedEntry<SpecPage>, spec: SpecScope): MockupPageState;
@@ -0,0 +1,272 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.pageGraph = pageGraph;
4
+ exports.compileEntry = compileEntry;
5
+ const compile_layouts_1 = require("./compile-layouts");
6
+ const compile_nodes_1 = require("./compile-nodes");
7
+ const extensions_1 = require("./extensions");
8
+ const model_1 = require("./model");
9
+ const page_links_1 = require("./page-links");
10
+ const places_1 = require("./places");
11
+ const sketch_1 = require("./sketch");
12
+ const SETTINGS_LAYOUT_COMPONENT = "dms-settings-layout";
13
+ function isInSettings(place, target) {
14
+ return (place.kind === "settings" || target?.layout === SETTINGS_LAYOUT_COMPONENT);
15
+ }
16
+ function compileCustomPage(page, pointer, scope) {
17
+ const fields = {};
18
+ for (const field of model_1.CUSTOM_PAGE_FIELDS) {
19
+ const value = page[field];
20
+ if (value !== undefined)
21
+ fields[field] = value;
22
+ }
23
+ return [(0, sketch_1.compileSketchPage)(fields, pointer, scope.issues, (0, page_links_1.sketchLinks)(scope))];
24
+ }
25
+ function pageGraph(pages) {
26
+ return new Map(pages.map((page) => [
27
+ page.id,
28
+ {
29
+ ...(page.parent !== undefined && { parent: page.parent }),
30
+ ...(page.route !== undefined && { param: page.route.slice(1) }),
31
+ },
32
+ ]));
33
+ }
34
+ function ancestorsOf(id, graph) {
35
+ const found = [];
36
+ for (let at = graph.get(id)?.parent; at !== undefined;) {
37
+ if (at === id || found.includes(at) || !graph.has(at))
38
+ break;
39
+ found.push(at);
40
+ at = graph.get(at)?.parent;
41
+ }
42
+ return found;
43
+ }
44
+ function scopeOf(page, spec, { issues, warnings }) {
45
+ const ancestors = ancestorsOf(page.id, spec.graph).map((id) => ({ id, fixtures: spec.fixtures.get(id) ?? {} }));
46
+ const param = spec.graph.get(page.id)?.param;
47
+ return {
48
+ catalog: spec.catalog,
49
+ issues,
50
+ warnings,
51
+ name: spec.name,
52
+ pageId: page.id,
53
+ fixtures: spec.fixtures.get(page.id) ?? {},
54
+ pages: spec.graph,
55
+ links: new Set(),
56
+ generatedPages: [],
57
+ ancestors,
58
+ answers: spec.answers,
59
+ ...(param !== undefined && { route: { param } }),
60
+ ...(page.livePage && { livePage: true }),
61
+ paths: {},
62
+ };
63
+ }
64
+ function rootPath(index) {
65
+ return `${compile_nodes_1.ROOT_LAYOUT_PREFIX}${index}`;
66
+ }
67
+ function compileTree(page, pointer, scope, pathOf) {
68
+ return page.tree.map((node, index) => (0, compile_nodes_1.compileNode)(node, `${pointer}/tree/${index}`, pathOf(index), scope));
69
+ }
70
+ function compileBody(page, host, spec, pathOf) {
71
+ const scope = scopeOf(page, spec, spec);
72
+ const isCustom = page.custom === true;
73
+ const tree = isCustom
74
+ ? compileCustomPage(page, page.pointer, scope)
75
+ : compileTree(page, page.pointer, scope, pathOf);
76
+ spec.generated.push(...scope.generatedPages.map((generated) => ({
77
+ id: generated.id,
78
+ title: generated.title,
79
+ description: generated.description,
80
+ place: host.place,
81
+ options: host.options,
82
+ links: [],
83
+ tree: generated.tree,
84
+ paths: {},
85
+ menu: false,
86
+ generated: true,
87
+ parent: host.id,
88
+ ...(generated.route && { route: generated.route }),
89
+ ...(host.inSettings && { layout: compile_layouts_1.SETTINGS_LAYOUT_STATE }),
90
+ })));
91
+ const body = {
92
+ tree,
93
+ links: scope.links,
94
+ paths: scope.paths,
95
+ roots: tree.length,
96
+ ...(scope.route && { route: scope.route }),
97
+ };
98
+ if (page.headerActions && page.id === host.id) {
99
+ body.headerActions = (0, page_links_1.headerActionLinks)(page.headerActions, `${page.pointer}/headerActions`, scope);
100
+ }
101
+ if (page.liveRoutes && !isCustom) {
102
+ body.realTree = compileTree(page, page.pointer, {
103
+ ...scopeOf(page, spec, { issues: [], warnings: [] }),
104
+ routes: page.liveRoutes,
105
+ }, pathOf);
106
+ }
107
+ return body;
108
+ }
109
+ function pageState(lead, host, body, spec, titles = lead) {
110
+ const state = {
111
+ id: lead.id,
112
+ title: titles.title,
113
+ place: host.place,
114
+ options: lead.options ?? {},
115
+ links: [...spec.graph.keys()].filter((id) => body.links.has(id)),
116
+ tree: body.tree,
117
+ paths: body.paths,
118
+ };
119
+ if (body.realTree)
120
+ state.realTree = body.realTree;
121
+ if (body.route)
122
+ state.route = body.route;
123
+ if (lead.menu === false)
124
+ state.menu = false;
125
+ if (lead.parent !== undefined)
126
+ state.parent = lead.parent;
127
+ if (titles.icon !== undefined)
128
+ state.icon = titles.icon;
129
+ if (titles.description !== undefined) {
130
+ state.description = titles.description;
131
+ }
132
+ if (body.headerActions)
133
+ state.headerActions = body.headerActions;
134
+ const layout = (0, compile_layouts_1.layoutStateOf)(lead.layout, host.inSettings, spec.layouts);
135
+ if (layout)
136
+ state.layout = layout;
137
+ return state;
138
+ }
139
+ function compilePage(page, place, spec) {
140
+ const host = {
141
+ id: page.id,
142
+ options: page.options ?? {},
143
+ place,
144
+ inSettings: isInSettings(place, undefined),
145
+ };
146
+ const state = pageState(page, host, compileBody(page, host, spec, rootPath), spec);
147
+ if (page.custom === true)
148
+ state.custom = true;
149
+ if (place.kind === "app" && page.category !== undefined) {
150
+ state.category = page.category;
151
+ }
152
+ if (page.livePage)
153
+ state.livePage = { ref: page.livePage.ref };
154
+ return state;
155
+ }
156
+ function nestedRootId(page, index) {
157
+ return `ext-${page.id}-${index}`;
158
+ }
159
+ function liveNode(block, target, children) {
160
+ return {
161
+ componentName: block.componentName,
162
+ ...(block.options !== undefined && { options: block.options }),
163
+ ...(children.length > 0 && { children }),
164
+ id: block.id,
165
+ ...(block.slot !== undefined && { slot: block.slot }),
166
+ ...(block.colSpan !== undefined && { colSpan: block.colSpan }),
167
+ live: { page: target.id, api: target.api, key: block.id },
168
+ };
169
+ }
170
+ function unknownAnchorWarning(target, { page, side, anchor, known }) {
171
+ const path = `${page.pointer}/${side}`;
172
+ const offered = known.length > 0 ? known.join(", ") : "none";
173
+ const outcome = anchor.includes(".")
174
+ ? "a running page drops the blocks anchored on a nested block it does not declare, so the built page would not draw them; the viewer draws them at the end of the page"
175
+ : "a running page appends the blocks at its end, where the viewer draws them";
176
+ return {
177
+ path,
178
+ message: `${side} "${anchor}" names no block ${target} declares: ${outcome}. The blocks it declares here are ${offered}`,
179
+ fix: known.length > 0
180
+ ? `set ${side} to one of ${known.join(", ")}, such as { "op": "replace", "path": "${path}", "value": "${known[0]}" }`
181
+ : `remove it, { "op": "remove", "path": "${path}" }`,
182
+ };
183
+ }
184
+ function unregisteredTargetWarning(target, page) {
185
+ const path = `${page.pointer}/extends`;
186
+ return {
187
+ path,
188
+ message: `extends "${target}", which no running module registers: the viewer draws the page's blocks alone`,
189
+ fix: `install the module that registers ${target} (ask the user, then call mockup_install_modules with approved: true), or name a page the project has, { "op": "replace", "path": "${path}", "value": "<full page id>" }`,
190
+ };
191
+ }
192
+ function compileExtension(entry, spec) {
193
+ const place = {
194
+ kind: "extension",
195
+ target: entry.target,
196
+ menu: entry.menu,
197
+ };
198
+ const lead = (0, places_1.leadOf)(entry);
199
+ const target = spec.live.get(entry.target);
200
+ const host = {
201
+ id: lead.id,
202
+ options: lead.options ?? {},
203
+ place,
204
+ inSettings: isInSettings(place, target),
205
+ };
206
+ const plan = (0, extensions_1.planExtensions)(target, entry.pages);
207
+ spec.warnings.push(...plan.unknown.map((unknown) => unknownAnchorWarning(entry.target, unknown)));
208
+ if (!target) {
209
+ spec.warnings.push(...entry.pages.map((page) => unregisteredTargetWarning(entry.target, page)));
210
+ }
211
+ const drawing = { roots: 0, bodies: [] };
212
+ const drawPage = (page, parent) => {
213
+ const first = drawing.roots;
214
+ const body = compileBody(page, host, spec, parent === undefined
215
+ ? (index) => rootPath(first + index)
216
+ : (index) => `${parent}.${nestedRootId(page, index)}`);
217
+ drawing.bodies.push(body);
218
+ const placed = (nodes) => parent === undefined
219
+ ? nodes
220
+ : nodes.map((node, index) => ({
221
+ ...node,
222
+ id: nestedRootId(page, index),
223
+ }));
224
+ if (parent === undefined)
225
+ drawing.roots += body.roots;
226
+ return {
227
+ tree: placed(body.tree),
228
+ real: placed(body.realTree ?? body.tree),
229
+ };
230
+ };
231
+ const drawSlots = (slots, parent) => {
232
+ const drawn = { tree: [], real: [] };
233
+ for (const slot of slots) {
234
+ const part = slot.kind === "page"
235
+ ? drawPage(slot.page, parent)
236
+ : drawBlock(slot.block, slot.slots, parent);
237
+ drawn.tree.push(...part.tree);
238
+ drawn.real.push(...part.real);
239
+ }
240
+ return drawn;
241
+ };
242
+ const drawBlock = (block, slots, parent) => {
243
+ const path = parent === undefined
244
+ ? rootPath(drawing.roots++)
245
+ : `${parent}.${block.id}`;
246
+ const children = drawSlots(slots, path);
247
+ return {
248
+ tree: target ? [liveNode(block, target, children.tree)] : [],
249
+ real: target ? [liveNode(block, target, children.real)] : [],
250
+ };
251
+ };
252
+ const { tree, real } = drawSlots(plan.slots, undefined);
253
+ const merged = {
254
+ tree,
255
+ links: new Set(drawing.bodies.flatMap((body) => [...body.links])),
256
+ paths: Object.fromEntries(drawing.bodies.flatMap((body) => Object.entries(body.paths))),
257
+ roots: drawing.roots,
258
+ };
259
+ if (drawing.bodies.some((body) => body.realTree))
260
+ merged.realTree = real;
261
+ const state = pageState(lead, host, merged, spec, target ?? lead);
262
+ if (entry.menu === "app" && lead.category !== undefined) {
263
+ state.category = lead.category;
264
+ }
265
+ return state;
266
+ }
267
+ function compileEntry(entry, spec) {
268
+ return entry.kind === "page"
269
+ ? compilePage(entry.page, entry.place, spec)
270
+ : compileExtension(entry, spec);
271
+ }
272
+ //# sourceMappingURL=compile-pages.js.map