@praxisui/page-builder 9.0.35 → 9.0.36
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.
- package/README.md +10 -0
- package/ai/component-registry.json +74 -34
- package/fesm2022/praxisui-page-builder.mjs +484 -132
- package/package.json +4 -4
- package/types/praxisui-page-builder.d.ts +18 -3
package/README.md
CHANGED
|
@@ -16,6 +16,7 @@ Use this package when an application must let users compose governed operational
|
|
|
16
16
|
- Dynamic page examples: https://praxisui.dev/examples/dynamic-page
|
|
17
17
|
- Live demo: https://praxis-ui-4e602.web.app
|
|
18
18
|
- Quickstart app: https://github.com/codexrodrigues/praxis-ui-quickstart
|
|
19
|
+
- Factory readiness and prioritized evolution: [docs/ui-composition-plan-factory-readiness.md](docs/ui-composition-plan-factory-readiness.md)
|
|
19
20
|
|
|
20
21
|
## Install
|
|
21
22
|
|
|
@@ -273,6 +274,8 @@ Page-owned copy can remain compact in the authoring plan. When a `PraxisTextValu
|
|
|
273
274
|
|
|
274
275
|
An explicit `layout` is a complete spatial decision. When a plan provides `layout` and omits both `canvas` and a preset/master-detail intent, the compiler preserves the layout without synthesizing a canvas that would take precedence at runtime. Automatic canvas materialization remains available for plans without an explicit layout and for preset- or role-driven master-detail plans.
|
|
275
276
|
|
|
277
|
+
Master-detail materialization uses the existing semantic envelope instead of component-name inference. An authored `canvas`, `slotAssignments`, or `deviceLayouts` remains authoritative; otherwise the compiler resolves the official `master-detail-dashboard` preset family from `layoutPresetOptions.presetFamily` and exact widget roles/slots (`master`, `detail`, `filters`, `actions`, `supporting`, or `detail-*`). It derives side-by-side desktop placement and deterministic tablet/mobile stacks, emits stable diagnostics for missing or ambiguous roles, and persists only canonical `WidgetPageDefinition` fields. Selection still travels through authored component ports and composition links.
|
|
278
|
+
|
|
276
279
|
Schema-derived table columns already use the canonical `TableConfig.columnProjection` contract. Omit `columns` or keep it empty, set `columnProjection.source: 'schema'`, optionally restrict the ordered projection through `include`, and declare only field-keyed editorial differences in `overrides` (plus genuinely local columns in `additions`). Do not introduce a parallel `useSurfaceDefaults`/`columnOverrides` dialect: the related-resource outlet and table runtime already materialize schema defaults and validate the projection against the remote schema.
|
|
277
280
|
|
|
278
281
|
`ComponentDocMeta.insertionPresets` remains the canonical catalog for reusable defaults owned by one component. It is not a page/domain template system: do not publish Employee Operations presets from CRUD, tabs, or related-resource outlet metadata merely to shorten a business recipe.
|
|
@@ -281,6 +284,12 @@ For complete governed page templates, the additive `UiCompositionPlanTemplateRef
|
|
|
281
284
|
|
|
282
285
|
Keep the compact authoring plan, the compiled executable page, and the surrounding recipe metadata as distinct artifacts. `UiCompositionPlan` is the reviewable authoring intent; `WidgetPageDefinition` is the explicit runtime graph; recipe metadata and operational evidence document when and how the example should be used. The server compiler must produce the same executable page as the Page Builder compiler before persistence.
|
|
283
286
|
|
|
287
|
+
Every official local apply of a `UiCompositionPlan` now runs a fail-closed preflight against the `ComponentMetadataRegistry` of the target host. The gate compiles the plan, delegates executable link validation to Core's `CompositionValidatorService`, resolves every top-level and nested component port against the same registry used by the runtime, and preserves canonical `DiagnosticRecord` codes and paths. A missing registry, component, materializable Angular type, port, compatible direction or semantic contract blocks apply before `applyConfigFromAdapter` can mutate the active page. Non-blocking layout diagnostics remain visible as preview warnings.
|
|
288
|
+
|
|
289
|
+
`preflightUiCompositionPlan(plan, targetRegistry)` is exported by `@praxisui/page-builder` for official Dynamic Page hosts that compile plans outside `DynamicPageBuilderComponent`. Those hosts must inject their runtime `ComponentMetadataRegistry`; omitting it fails closed with `UI_COMPOSITION_TARGET_REGISTRY_REQUIRED`.
|
|
290
|
+
|
|
291
|
+
When a preview contains both `uiCompositionPlan` and `compiledFormPatch`, the semantic plan is the attested source for local preview. Persistence rebuilds `patch.page` from that locally materialized page so a backend patch cannot bypass the registry-aware gate. Provider readiness in this cut means that the target registry contains owner metadata with a materializable Angular component type; uniform certification of the owner providers and bootstrap recipes remains tracked by issue #392 and is not inferred through Page Builder heuristics.
|
|
292
|
+
|
|
284
293
|
Streaming apply is fail-closed. A preview is persistable only when it is the unchanged payload of an applicable terminal `result` event and its diagnostics carry the matching `streamId`, `threadId`, `turnId`, and `resultEventId`. A locally regenerated or normalized preview remains available for review, but it cannot reuse an older terminal reference or call `page-apply`; the backend must issue a new terminal result for the new patch.
|
|
285
294
|
|
|
286
295
|
## Public API
|
|
@@ -301,6 +310,7 @@ Main exports:
|
|
|
301
310
|
- `providePageBuilderWidgetAiCatalogs`
|
|
302
311
|
- `PRAXIS_PAGE_BUILDER_AUTHORING_MANIFEST`
|
|
303
312
|
- `UiCompositionPlan` contracts
|
|
313
|
+
- `preflightUiCompositionPlan`
|
|
304
314
|
|
|
305
315
|
## Notes
|
|
306
316
|
|