@praxisui/page-builder 9.0.46 → 9.0.47

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 CHANGED
@@ -289,6 +289,13 @@ Compiled links may retain `metadata.source: 'ui-composition-plan'` as explicit a
289
289
 
290
290
  `bindings[].from` accepts `global-action` as the canonical continuation source for results emitted through `dynamicPage.composition.dispatch`. The authored source declares only a stable `actionId`; the runtime dispatch payload is the value delivered to state or component targets. `payload`, `payloadExpr`, `meta`, labels and result-type hints do not participate in endpoint matching and fail closed when placed on a global-action source. Those fields remain valid only for global-action targets, where they configure command dispatch. The compiler persists the source as `{ kind: 'global-action', ref: { actionId } }`, matching Core's existing runtime contract without a host adapter.
291
291
 
292
+ When a `template` transform changes the semantic kind of its source, declare
293
+ `transform.output.semanticKind` (and, when applicable, `schemaId`, `schemaRef`
294
+ and `stableShape`). The compiler projects the same output hint onto the canonical
295
+ pipeline and its materializing step, allowing registry-aware preflight to compare
296
+ the transformed contract with the target port. Do not relax target compatibility
297
+ or relabel the source port to hide a transformation.
298
+
292
299
  The official Employee Operations case is an executable regression for this boundary. Its first-class `*.ui-composition-plan.json` artifact expresses 22 persisted links as one `selectionSyncs` declaration, two `contextScopes` declarations and one explicit transformed binding, while compilation preserves the same 22 source/target paths, guards, transforms and policies. This reduces the wiring declarations from 22 to 4 (82%) without hiding the executable graph from runtime inspection, audit or the public JSON viewer. Context scopes are deliberately limited to direct inheritance: a value that must be wrapped or reshaped remains an explicit binding with a canonical transform.
293
300
 
294
301
  Page-owned copy can remain compact in the authoring plan. When a `PraxisTextValue` descriptor declares only `{ key }` and the key exists in `i18n.dictionaries[fallbackLocale]`, both canonical compilers materialize that message as the descriptor's runtime `text` fallback. The persisted `WidgetPageDefinition` therefore stays portable while authors do not repeat the same fallback beside every key. Explicit `text` still wins and unknown keys remain untouched, so the compiler never invents copy.
@@ -313,11 +320,23 @@ Workspace contributors can exercise this path in the reference host at
313
320
  `/dynamic-page-lab`. Its **Certificação do UiCompositionPlan** station displays
314
321
  the compact plan, registry-aware preflight, compiled `WidgetPageDefinition`, real
315
322
  Dynamic Page, diagnostics, widget-event trail and sanitized runtime observation
316
- without introducing another compiler or registry. The initial deterministic
317
- scenario covers Table, shell, page state and a global-action target; an unknown
318
- component proves fail-closed behavior. The broader certification matrix and the
319
- known Page Builder limitation for a global action used as a binding source are
320
- tracked in issues #430 and #431 respectively.
323
+ without introducing another compiler or registry. Its scenario catalog reuses the
324
+ same A2-A4 plan fixtures exercised by focused certification specs—forms/filters,
325
+ CRUD lifecycle and parent/related-resource—alongside the certified A5
326
+ Table/shell/global-action contracts. An unknown component proves fail-closed
327
+ behavior. The browser proof for the related-resource scenario requires a real
328
+ parent selection, the relationship filter and visible child columns/data derived
329
+ from the remote schema; request success alone is insufficient. The same route's
330
+ People Operations dashboard is authored as a 9-widget/10-binding plan and proves
331
+ filter and governed decision propagation through the compiled graph. The broader
332
+ certification matrix remains tracked in issue #430; issue #431 closed the former
333
+ global-action source limitation.
334
+
335
+ For multi-consumer interaction state, author one `event -> state` binding and
336
+ project `state -> component-port` to each consumer. A direct event delivery is
337
+ transient; it must not become the page's durable semantic source across runtime
338
+ recomposition. The People Operations certification scenario applies this rule to
339
+ `state.activeFilter` and verifies the complete fan-out in the browser.
321
340
 
322
341
  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.
323
342
 
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": "1.0.0",
3
- "generatedAt": "2026-08-30T19:35:50.928Z",
3
+ "generatedAt": "2026-08-30T21:38:22.309Z",
4
4
  "packageName": "@praxisui/page-builder",
5
- "packageVersion": "9.0.46",
5
+ "packageVersion": "9.0.47",
6
6
  "sourceRegistry": "praxis-component-registry-ingestion",
7
7
  "sourceRegistryVersion": "1.0.0",
8
8
  "componentCount": 1,
@@ -15840,6 +15840,7 @@ function toCompositionTransform(transform) {
15840
15840
  }
15841
15841
  if (transform.kind === 'template') {
15842
15842
  const template = clone(transform.template);
15843
+ const output = transform.output ? clone(transform.output) : undefined;
15843
15844
  const structuredKind = Array.isArray(template)
15844
15845
  ? 'array-template'
15845
15846
  : template !== null && typeof template === 'object'
@@ -15863,8 +15864,10 @@ function toCompositionTransform(transform) {
15863
15864
  config: {
15864
15865
  template,
15865
15866
  },
15867
+ ...(output ? { output } : {}),
15866
15868
  },
15867
15869
  ],
15870
+ ...(output ? { output } : {}),
15868
15871
  };
15869
15872
  }
15870
15873
  if (transform.kind === 'constant') {
@@ -21732,6 +21735,7 @@ function projectKnowledgeTarget(changeSet, conceptKey) {
21732
21735
 
21733
21736
  const AGENTIC_AUTHORING_TURN_INACTIVITY_TIMEOUT_MS = 180_000;
21734
21737
  const AGENTIC_LOCAL_PREVIEW_HISTORY_LIMIT = 20;
21738
+ const DEFAULT_RUNTIME_AUTHORING_CAPABILITIES = Object.freeze({});
21735
21739
  const AGENTIC_PAGE_COMPOSITION_REQUEST_OUTPUT = 'agenticPageCompositionRequested';
21736
21740
  class DynamicPageBuilderComponent {
21737
21741
  dialog;
@@ -21833,9 +21837,8 @@ class DynamicPageBuilderComponent {
21833
21837
  top: 96,
21834
21838
  margin: 24,
21835
21839
  }), ...(ngDevMode ? [{ debugName: "agenticAuthoringPanelLayout" }] : /* istanbul ignore next */ []));
21836
- previewMode = false;
21837
- runtimePreviewPageCache;
21838
- runtimeAuthoringPageCache;
21840
+ previewMode = signal(false, ...(ngDevMode ? [{ debugName: "previewMode" }] : /* istanbul ignore next */ []));
21841
+ runtimePageCache;
21839
21842
  agenticComponentCapabilities;
21840
21843
  agenticComponentCapabilitiesPromise;
21841
21844
  agenticTurnController;
@@ -21868,7 +21871,6 @@ class DynamicPageBuilderComponent {
21868
21871
  this.currentPage.set(this.parsePage(this.page) || { widgets: [] });
21869
21872
  }
21870
21873
  if (changes['authoringCapabilities']) {
21871
- this.runtimeAuthoringPageCache = undefined;
21872
21874
  if (!this.isAuthoringCapabilityEnabled('connections')) {
21873
21875
  this.connectionsViewerOpen.set(false);
21874
21876
  }
@@ -21918,7 +21920,7 @@ class DynamicPageBuilderComponent {
21918
21920
  this.observabilityMetricsSubscription.unsubscribe();
21919
21921
  }
21920
21922
  showSettings() {
21921
- return !!this.enableCustomization && !this.previewMode;
21923
+ return !!this.enableCustomization && !this.previewMode();
21922
21924
  }
21923
21925
  canInsertWidgets() {
21924
21926
  return this.showSettings() && this.isAuthoringCapabilityEnabled('insertWidgets');
@@ -21960,27 +21962,22 @@ class DynamicPageBuilderComponent {
21960
21962
  return this.authoringCapabilities?.[capability] !== false;
21961
21963
  }
21962
21964
  isPreviewMode() {
21963
- return this.previewMode;
21965
+ return this.previewMode();
21964
21966
  }
21965
21967
  runtimePage() {
21966
21968
  const page = this.currentPage();
21967
- if (!this.previewMode && this.showSettings()) {
21968
- if (this.runtimeAuthoringPageCache?.source === page) {
21969
- return this.runtimeAuthoringPageCache.value;
21970
- }
21971
- const value = this.toAuthoringRuntimePage(page);
21972
- this.runtimeAuthoringPageCache = { source: page, value };
21973
- return value;
21974
- }
21975
- if (this.runtimePreviewPageCache?.source === page) {
21976
- return this.runtimePreviewPageCache.value;
21969
+ if (this.runtimePageCache?.source === page) {
21970
+ return this.runtimePageCache.value;
21977
21971
  }
21978
- const value = this.toPresentationRuntimePage(page);
21979
- this.runtimePreviewPageCache = { source: page, value };
21972
+ const value = this.toRuntimeBasePage(page);
21973
+ this.runtimePageCache = { source: page, value };
21980
21974
  return value;
21981
21975
  }
21976
+ runtimeAuthoringCapabilities() {
21977
+ return this.authoringCapabilities || DEFAULT_RUNTIME_AUTHORING_CAPABILITIES;
21978
+ }
21982
21979
  builderModeLabel() {
21983
- if (this.previewMode) {
21980
+ if (this.previewMode()) {
21984
21981
  return this.tx('builderMode.preview', 'Prévia');
21985
21982
  }
21986
21983
  if (this.showSettings() && this.connectionsViewerOpen()) {
@@ -21995,7 +21992,7 @@ class DynamicPageBuilderComponent {
21995
21992
  return this.tx('builderMode.presentation', 'Presentation');
21996
21993
  }
21997
21994
  onRuntimePageChange(next) {
21998
- const canonical = this.toCanonicalPageFromAuthoringRuntime(next);
21995
+ const canonical = this.toCanonicalPageFromRuntime(next);
21999
21996
  if (JSON.stringify(canonical) === JSON.stringify(this.currentPage())) {
22000
21997
  return;
22001
21998
  }
@@ -22041,8 +22038,8 @@ class DynamicPageBuilderComponent {
22041
22038
  togglePreview() {
22042
22039
  if (!this.canPreviewPage())
22043
22040
  return;
22044
- this.previewMode = !this.previewMode;
22045
- if (this.previewMode) {
22041
+ this.previewMode.update((current) => !current);
22042
+ if (this.previewMode()) {
22046
22043
  this.enterPreviewMode();
22047
22044
  }
22048
22045
  }
@@ -22197,8 +22194,7 @@ class DynamicPageBuilderComponent {
22197
22194
  this.agenticAuthoringStatus.set(this.tx('agentic.status.reviewNeedsAttention', 'Complete this review in the assistant before saving.'));
22198
22195
  return;
22199
22196
  }
22200
- const runtimeSnapshot = this.runtime?.getPageSnapshot();
22201
- const cloned = this.toCanonicalPageFromAuthoringRuntime(runtimeSnapshot || this.currentPage());
22197
+ const cloned = this.clonePage(this.currentPage());
22202
22198
  this.currentPage.set(cloned);
22203
22199
  this.pageChange.emit(cloned);
22204
22200
  this.pageSaveRequested.emit(this.clonePage(cloned));
@@ -22302,8 +22298,8 @@ class DynamicPageBuilderComponent {
22302
22298
  const action = issue.action;
22303
22299
  if (!action || !this.canRunPremiumReadinessAction(action))
22304
22300
  return;
22305
- if (this.previewMode) {
22306
- this.previewMode = false;
22301
+ if (this.previewMode()) {
22302
+ this.previewMode.set(false);
22307
22303
  }
22308
22304
  switch (action.kind) {
22309
22305
  case 'open-page-settings':
@@ -22459,7 +22455,7 @@ class DynamicPageBuilderComponent {
22459
22455
  if (this.showSettings()) {
22460
22456
  return true;
22461
22457
  }
22462
- return this.previewMode && this.hasAgenticAuthoringSession();
22458
+ return this.previewMode() && this.hasAgenticAuthoringSession();
22463
22459
  }
22464
22460
  showAgenticAuthoringDock() {
22465
22461
  return this.showSettings()
@@ -24749,24 +24745,20 @@ class DynamicPageBuilderComponent {
24749
24745
  return JSON.stringify(this.currentPage());
24750
24746
  }
24751
24747
  enterPreviewMode() {
24752
- this.previewMode = true;
24753
- this.runtimePreviewPageCache = undefined;
24748
+ this.previewMode.set(true);
24754
24749
  this.connectionsViewerOpen.set(false);
24755
24750
  this.agenticAuthoringLlmDiagnostics.set(null);
24756
24751
  this.sharedRuleCockpitCollapsed.set(true);
24757
24752
  this.projectKnowledgeCockpitCollapsed.set(true);
24758
24753
  this.selectedWidgetKey.set(null);
24759
24754
  }
24760
- toPresentationRuntimePage(page) {
24761
- const cloned = this.clonePage(page);
24762
- cloned.widgets = (cloned.widgets || []).map((widget) => this.toPresentationRuntimeWidget(widget));
24763
- return cloned;
24764
- }
24765
- toAuthoringRuntimePage(page) {
24755
+ /**
24756
+ * Builds one mode-independent runtime projection for the authored page.
24757
+ * Child authoring chrome is materialized by the embedded dynamic page from
24758
+ * host capabilities, so JSON/Visual mode changes never replace this object.
24759
+ */
24760
+ toRuntimeBasePage(page) {
24766
24761
  const cloned = this.clonePage(page);
24767
- if (!this.isAuthoringCapabilityEnabled('childCustomization')) {
24768
- return cloned;
24769
- }
24770
24762
  cloned.widgets = (cloned.widgets || []).map((widget) => {
24771
24763
  const metadata = this.componentMetadata.get(widget.definition?.id);
24772
24764
  if (!metadata?.inputs?.some((input) => input.name === 'enableCustomization')) {
@@ -24777,23 +24769,16 @@ class DynamicPageBuilderComponent {
24777
24769
  definition: {
24778
24770
  ...widget.definition,
24779
24771
  inputs: {
24780
- ...(widget.definition?.inputs || {}),
24781
- enableCustomization: true,
24772
+ ...(widget.definition.inputs || {}),
24773
+ enableCustomization: false,
24782
24774
  },
24783
24775
  },
24784
24776
  };
24785
24777
  });
24786
24778
  return cloned;
24787
24779
  }
24788
- /**
24789
- * Removes authoring-only inputs from a page emitted by the embedded runtime.
24790
- *
24791
- * The runtime must receive `enableCustomization=true` so nested components can
24792
- * expose their editors, but that projection is not part of the authored page.
24793
- * Restore the canonical value by widget key before publishing `pageChange` so
24794
- * a presentation-only edit cannot accidentally persist authoring chrome.
24795
- */
24796
- toCanonicalPageFromAuthoringRuntime(page) {
24780
+ /** Restores authoring-only child inputs from the canonical builder page. */
24781
+ toCanonicalPageFromRuntime(page) {
24797
24782
  const canonicalByKey = new Map((this.currentPage().widgets || []).map((widget) => [widget.key, widget]));
24798
24783
  const cloned = this.clonePage(page);
24799
24784
  cloned.widgets = (cloned.widgets || []).map((widget) => {
@@ -24801,43 +24786,23 @@ class DynamicPageBuilderComponent {
24801
24786
  if (!metadata?.inputs?.some((input) => input.name === 'enableCustomization')) {
24802
24787
  return widget;
24803
24788
  }
24804
- const canonicalInputs = canonicalByKey.get(widget.key)?.definition?.inputs;
24805
- const inputs = { ...(widget.definition?.inputs || {}) };
24806
- if (canonicalInputs && Object.prototype.hasOwnProperty.call(canonicalInputs, 'enableCustomization')) {
24807
- inputs['enableCustomization'] = canonicalInputs['enableCustomization'];
24789
+ const canonicalInputs = canonicalByKey.get(widget.key)?.definition.inputs;
24790
+ const inputs = { ...(widget.definition.inputs || {}) };
24791
+ if (canonicalInputs &&
24792
+ Object.prototype.hasOwnProperty.call(canonicalInputs, 'enableCustomization')) {
24793
+ inputs['enableCustomization'] =
24794
+ canonicalInputs['enableCustomization'];
24808
24795
  }
24809
24796
  else {
24810
24797
  delete inputs['enableCustomization'];
24811
24798
  }
24812
24799
  return {
24813
24800
  ...widget,
24814
- definition: {
24815
- ...widget.definition,
24816
- inputs,
24817
- },
24801
+ definition: { ...widget.definition, inputs },
24818
24802
  };
24819
24803
  });
24820
24804
  return cloned;
24821
24805
  }
24822
- toPresentationRuntimeWidget(widget) {
24823
- const metadata = this.componentMetadata.get(widget.definition?.id);
24824
- if (!metadata?.inputs?.some((input) => input.name === 'enableCustomization')) {
24825
- return widget;
24826
- }
24827
- const inputs = widget.definition?.inputs || {};
24828
- if (inputs['enableCustomization'] === false)
24829
- return widget;
24830
- return {
24831
- ...widget,
24832
- definition: {
24833
- ...widget.definition,
24834
- inputs: {
24835
- ...inputs,
24836
- enableCustomization: false,
24837
- },
24838
- },
24839
- };
24840
- }
24841
24806
  async applyAgenticTurnState(state) {
24842
24807
  // A terminal turn state is the canonical end of processing. Clear the local
24843
24808
  // interaction flag before projecting preview/review so the shell never
@@ -25645,7 +25610,7 @@ class DynamicPageBuilderComponent {
25645
25610
  [strictValidation]="strictValidation"
25646
25611
  [autoPersist]="false"
25647
25612
  [enableCustomization]="showSettings()"
25648
- [authoringCapabilities]="authoringCapabilities"
25613
+ [authoringCapabilities]="runtimeAuthoringCapabilities()"
25649
25614
  [showPageSettingsButton]="false"
25650
25615
  [pageIdentity]="pageIdentity"
25651
25616
  [componentInstanceId]="componentInstanceId"
@@ -26209,7 +26174,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
26209
26174
  [strictValidation]="strictValidation"
26210
26175
  [autoPersist]="false"
26211
26176
  [enableCustomization]="showSettings()"
26212
- [authoringCapabilities]="authoringCapabilities"
26177
+ [authoringCapabilities]="runtimeAuthoringCapabilities()"
26213
26178
  [showPageSettingsButton]="false"
26214
26179
  [pageIdentity]="pageIdentity"
26215
26180
  [componentInstanceId]="componentInstanceId"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@praxisui/page-builder",
3
- "version": "9.0.46",
3
+ "version": "9.0.47",
4
4
  "description": "Page and widget builder utilities for Praxis UI (grid, dynamic widgets, editors).",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^21.0.0",
@@ -8,9 +8,9 @@
8
8
  "@angular/forms": "^21.0.0",
9
9
  "@angular/cdk": "^21.0.0",
10
10
  "@angular/material": "^21.0.0",
11
- "@praxisui/ai": "^9.0.46",
12
- "@praxisui/core": "^9.0.46",
13
- "@praxisui/settings-panel": "^9.0.46",
11
+ "@praxisui/ai": "^9.0.47",
12
+ "@praxisui/core": "^9.0.47",
13
+ "@praxisui/settings-panel": "^9.0.47",
14
14
  "rxjs": "~7.8.0"
15
15
  },
16
16
  "dependencies": {
@@ -1,7 +1,7 @@
1
1
  import { MatDialogRef, MatDialog } from '@angular/material/dialog';
2
2
  import * as _angular_core from '@angular/core';
3
3
  import { EventEmitter, OnInit, WritableSignal, InjectionToken, Provider, OnChanges, OnDestroy, Type, SimpleChanges } from '@angular/core';
4
- import { ComponentDocMeta, ComponentMetadataRegistry, PraxisI18nService, WidgetShellConfig, WidgetPageAuthoringCapabilities, WidgetShellAction, EndpointRef, ComponentPortPathSegment, LinkIntent, CompositionLink, WidgetPageDefinition, TransformKind, SurfaceOpenPayload, SettingsValueProvider as SettingsValueProvider$1, WidgetPageGroupingDefinition, BUILTIN_PAGE_LAYOUT_PRESETS, BUILTIN_PAGE_THEME_PRESETS, PageIdentity, WidgetStateNode, WidgetDerivedStateNode, AiCapability, AiCapabilityCategory, AiCapabilityCatalog, AiValueKind, DomainKnowledgeChangeSetRequest, DomainKnowledgeChangeSet, DomainKnowledgeChangeSetTimelineResponse, DomainKnowledgeChangeSetFilters, DomainKnowledgeValidationResponse, DomainKnowledgeStatusTransitionRequest, DomainRuleIntakeRequest, DomainRuleIntakeResponse, DomainRuleDefinitionRequest, DomainRuleDefinition, DomainRuleSimulationRequest, DomainRuleSimulationResponse, DomainRuleStatusTransitionRequest, DomainRulePublicationRequest, DomainRulePublicationResponse, DomainRuleMaterializationFilters, DomainRuleMaterialization, DomainRuleTimelineResponse, PraxisRuntimeComponentObservationEnvelope, WidgetPageCanvasLayout, WidgetPageDeviceLayouts, WidgetPageSlotAssignments, WidgetPageStateInput, WidgetInstance, ComponentContextPack, ComponentAuthoringManifest, DiagnosticRecord, NestedPortCatalogRegistry, CompositionValidatorService, DynamicWidgetPageComponent, WidgetEventEnvelope, ObservabilityAgenticTurnMetrics, SettingsPanelBridge, ObservabilityAgenticTurnMetricBucket, RichTimelineItem } from '@praxisui/core';
4
+ import { ComponentDocMeta, ComponentMetadataRegistry, PraxisI18nService, WidgetShellConfig, WidgetPageAuthoringCapabilities, WidgetShellAction, EndpointRef, ComponentPortPathSegment, LinkIntent, CompositionLink, WidgetPageDefinition, TransformKind, SurfaceOpenPayload, SettingsValueProvider as SettingsValueProvider$1, WidgetPageGroupingDefinition, BUILTIN_PAGE_LAYOUT_PRESETS, BUILTIN_PAGE_THEME_PRESETS, PageIdentity, WidgetStateNode, WidgetDerivedStateNode, AiCapability, AiCapabilityCategory, AiCapabilityCatalog, AiValueKind, DomainKnowledgeChangeSetRequest, DomainKnowledgeChangeSet, DomainKnowledgeChangeSetTimelineResponse, DomainKnowledgeChangeSetFilters, DomainKnowledgeValidationResponse, DomainKnowledgeStatusTransitionRequest, DomainRuleIntakeRequest, DomainRuleIntakeResponse, DomainRuleDefinitionRequest, DomainRuleDefinition, DomainRuleSimulationRequest, DomainRuleSimulationResponse, DomainRuleStatusTransitionRequest, DomainRulePublicationRequest, DomainRulePublicationResponse, DomainRuleMaterializationFilters, DomainRuleMaterialization, DomainRuleTimelineResponse, PraxisRuntimeComponentObservationEnvelope, WidgetPageCanvasLayout, WidgetPageDeviceLayouts, WidgetPageSlotAssignments, WidgetPageStateInput, WidgetInstance, TransformOutputHint, TransformSemanticKind, ComponentContextPack, ComponentAuthoringManifest, DiagnosticRecord, NestedPortCatalogRegistry, CompositionValidatorService, DynamicWidgetPageComponent, WidgetEventEnvelope, ObservabilityAgenticTurnMetrics, SettingsPanelBridge, ObservabilityAgenticTurnMetricBucket, RichTimelineItem } from '@praxisui/core';
5
5
  import * as rxjs from 'rxjs';
6
6
  import { BehaviorSubject, Observable } from 'rxjs';
7
7
  import { FormGroup, FormControl, FormArray } from '@angular/forms';
@@ -1532,6 +1532,9 @@ declare class PageBuilderAgenticAuthoringService {
1532
1532
  }
1533
1533
 
1534
1534
  type UiCompositionPlanInputSource = 'event' | 'payload' | 'state' | 'context' | 'constant';
1535
+ type UiCompositionPlanTransformOutput = TransformOutputHint & {
1536
+ semanticKind: TransformSemanticKind;
1537
+ };
1535
1538
  type UiCompositionPlanComponentPortEndpoint = {
1536
1539
  kind: 'component-port';
1537
1540
  widget: string;
@@ -1581,6 +1584,8 @@ type UiCompositionPlanTransform = {
1581
1584
  id: string;
1582
1585
  template: unknown;
1583
1586
  inputSource?: UiCompositionPlanInputSource;
1587
+ /** Explicit semantic contract produced by the template after materialization. */
1588
+ output?: UiCompositionPlanTransformOutput;
1584
1589
  };
1585
1590
  interface UiCompositionPlanWidget {
1586
1591
  key: string;
@@ -1981,9 +1986,8 @@ declare class DynamicPageBuilderComponent implements OnChanges, OnDestroy {
1981
1986
  readonly selectedWidgetKey: _angular_core.WritableSignal<string | null>;
1982
1987
  readonly agenticAuthoringWidgetContextKey: _angular_core.WritableSignal<string | null>;
1983
1988
  readonly agenticAuthoringPanelLayout: _angular_core.WritableSignal<PraxisAssistantShellLayout>;
1984
- private previewMode;
1985
- private runtimePreviewPageCache?;
1986
- private runtimeAuthoringPageCache?;
1989
+ private readonly previewMode;
1990
+ private runtimePageCache?;
1987
1991
  private agenticComponentCapabilities?;
1988
1992
  private agenticComponentCapabilitiesPromise?;
1989
1993
  private agenticTurnController?;
@@ -2009,6 +2013,7 @@ declare class DynamicPageBuilderComponent implements OnChanges, OnDestroy {
2009
2013
  private isAuthoringCapabilityEnabled;
2010
2014
  isPreviewMode(): boolean;
2011
2015
  runtimePage(): WidgetPageDefinition;
2016
+ runtimeAuthoringCapabilities(): PageBuilderAuthoringCapabilities;
2012
2017
  builderModeLabel(): string;
2013
2018
  onRuntimePageChange(next: WidgetPageDefinition): void;
2014
2019
  onRuntimeWidgetEvent(event: WidgetEventEnvelope): void;
@@ -2190,18 +2195,14 @@ declare class DynamicPageBuilderComponent implements OnChanges, OnDestroy {
2190
2195
  private clearAgenticLocalPreviewHistory;
2191
2196
  private agenticCurrentPageFingerprint;
2192
2197
  private enterPreviewMode;
2193
- private toPresentationRuntimePage;
2194
- private toAuthoringRuntimePage;
2195
2198
  /**
2196
- * Removes authoring-only inputs from a page emitted by the embedded runtime.
2197
- *
2198
- * The runtime must receive `enableCustomization=true` so nested components can
2199
- * expose their editors, but that projection is not part of the authored page.
2200
- * Restore the canonical value by widget key before publishing `pageChange` so
2201
- * a presentation-only edit cannot accidentally persist authoring chrome.
2199
+ * Builds one mode-independent runtime projection for the authored page.
2200
+ * Child authoring chrome is materialized by the embedded dynamic page from
2201
+ * host capabilities, so JSON/Visual mode changes never replace this object.
2202
2202
  */
2203
- private toCanonicalPageFromAuthoringRuntime;
2204
- private toPresentationRuntimeWidget;
2203
+ private toRuntimeBasePage;
2204
+ /** Restores authoring-only child inputs from the canonical builder page. */
2205
+ private toCanonicalPageFromRuntime;
2205
2206
  private applyAgenticTurnState;
2206
2207
  private primeSharedRuleHandoff;
2207
2208
  private moveAgenticAuthoringPanelToReviewSidecar;
@@ -2273,4 +2274,4 @@ declare const PRAXIS_PAGE_BUILDER_COMPONENT_METADATA: ComponentDocMeta;
2273
2274
  declare function providePraxisPageBuilderMetadata(): Provider;
2274
2275
 
2275
2276
  export { ComponentPaletteDialogComponent, ConfirmDialogComponent, ConnectionEditorComponent, DynamicPageBuilderComponent, DynamicPageConfigEditorComponent, FloatingToolbarComponent, PAGE_BUILDER_AGENTIC_AUTHORING_OPTIONS, PAGE_BUILDER_AI_CAPABILITIES, PAGE_BUILDER_COMPONENT_CONTEXT_PACK, PAGE_BUILDER_WIDGET_AI_CATALOGS, PLACEHOLDER, PRAXIS_PAGE_BUILDER_AUTHORING_MANIFEST, PRAXIS_PAGE_BUILDER_COMPONENT_METADATA, PageBuilderAgenticAuthoringService, PageConfigEditorComponent, TileToolbarComponent, WidgetShellEditorComponent, clearWidgetAiCatalogs, compileUiCompositionPlan, getPageAiCatalog, getWidgetAiCapabilities, preflightUiCompositionPlan, providePageBuilderWidgetAiCatalogs, providePraxisPageBuilderMetadata, registerWidgetAiCatalog, registerWidgetAiCatalogs, resolveUiCompositionPlanTemplate, validateUiCompositionPlan };
2276
- export type { Capability, CapabilityCatalog, CapabilityCategory, ComponentPaletteData, ComponentPaletteSelection, ConfirmDialogData, PageBuilderAgenticAuthoringAttachmentSummary, PageBuilderAgenticAuthoringCandidate, PageBuilderAgenticAuthoringComponentCapabilitiesResult, PageBuilderAgenticAuthoringComponentCapability, PageBuilderAgenticAuthoringComponentCapabilityCatalog, PageBuilderAgenticAuthoringComponentCapabilityExample, PageBuilderAgenticAuthoringComponentFieldAlias, PageBuilderAgenticAuthoringConversationMessage, PageBuilderAgenticAuthoringGateResult, PageBuilderAgenticAuthoringIntentResolutionRequest, PageBuilderAgenticAuthoringIntentResolutionResult, PageBuilderAgenticAuthoringOptions, PageBuilderAgenticAuthoringPendingClarification, PageBuilderAgenticAuthoringPromptRequest, PageBuilderAgenticAuthoringProvider, PageBuilderAgenticAuthoringQuickReply, PageBuilderAgenticAuthoringResourceCandidatesRequest, PageBuilderAgenticAuthoringResourceCandidatesResult, PageBuilderAgenticAuthoringSharedRuleHandoff, PageBuilderAgenticAuthoringTarget, PageBuilderAgenticAuthoringTurnStreamConnectionError, PageBuilderAgenticAuthoringTurnStreamEvent, PageBuilderAgenticAuthoringTurnStreamRequest, PageBuilderAgenticAuthoringTurnStreamStartResponse, PageBuilderApplyRequest, PageBuilderApplyResult, PageBuilderAuthoringCapabilities, PageBuilderCompiledFormPatch, PageBuilderMinimalFormPlanResult, PageBuilderPreviewDiagnostics, PageBuilderPreviewResult, PageBuilderProjectKnowledgeAudit, UiCompositionPlan, UiCompositionPlanAuthoringInput, UiCompositionPlanBinding, UiCompositionPlanCompileResult, UiCompositionPlanComponentPortEndpoint, UiCompositionPlanContextScope, UiCompositionPlanContextScopeTarget, UiCompositionPlanContextValue, UiCompositionPlanDiagnostic, UiCompositionPlanEndpoint, UiCompositionPlanGlobalActionEndpoint, UiCompositionPlanGlobalActionSourceEndpoint, UiCompositionPlanInputSource, UiCompositionPlanPreflightResult, UiCompositionPlanSelectionSync, UiCompositionPlanSelectionSyncMapping, UiCompositionPlanSourceEndpoint, UiCompositionPlanStateEndpoint, UiCompositionPlanTargetEndpoint, UiCompositionPlanTemplateMaterialization, UiCompositionPlanTemplateRef, UiCompositionPlanTemplateReference, UiCompositionPlanTemplateResolutionResult, UiCompositionPlanTemplateRevision, UiCompositionPlanTransform, UiCompositionPlanWidget, ValueKind };
2277
+ export type { Capability, CapabilityCatalog, CapabilityCategory, ComponentPaletteData, ComponentPaletteSelection, ConfirmDialogData, PageBuilderAgenticAuthoringAttachmentSummary, PageBuilderAgenticAuthoringCandidate, PageBuilderAgenticAuthoringComponentCapabilitiesResult, PageBuilderAgenticAuthoringComponentCapability, PageBuilderAgenticAuthoringComponentCapabilityCatalog, PageBuilderAgenticAuthoringComponentCapabilityExample, PageBuilderAgenticAuthoringComponentFieldAlias, PageBuilderAgenticAuthoringConversationMessage, PageBuilderAgenticAuthoringGateResult, PageBuilderAgenticAuthoringIntentResolutionRequest, PageBuilderAgenticAuthoringIntentResolutionResult, PageBuilderAgenticAuthoringOptions, PageBuilderAgenticAuthoringPendingClarification, PageBuilderAgenticAuthoringPromptRequest, PageBuilderAgenticAuthoringProvider, PageBuilderAgenticAuthoringQuickReply, PageBuilderAgenticAuthoringResourceCandidatesRequest, PageBuilderAgenticAuthoringResourceCandidatesResult, PageBuilderAgenticAuthoringSharedRuleHandoff, PageBuilderAgenticAuthoringTarget, PageBuilderAgenticAuthoringTurnStreamConnectionError, PageBuilderAgenticAuthoringTurnStreamEvent, PageBuilderAgenticAuthoringTurnStreamRequest, PageBuilderAgenticAuthoringTurnStreamStartResponse, PageBuilderApplyRequest, PageBuilderApplyResult, PageBuilderAuthoringCapabilities, PageBuilderCompiledFormPatch, PageBuilderMinimalFormPlanResult, PageBuilderPreviewDiagnostics, PageBuilderPreviewResult, PageBuilderProjectKnowledgeAudit, UiCompositionPlan, UiCompositionPlanAuthoringInput, UiCompositionPlanBinding, UiCompositionPlanCompileResult, UiCompositionPlanComponentPortEndpoint, UiCompositionPlanContextScope, UiCompositionPlanContextScopeTarget, UiCompositionPlanContextValue, UiCompositionPlanDiagnostic, UiCompositionPlanEndpoint, UiCompositionPlanGlobalActionEndpoint, UiCompositionPlanGlobalActionSourceEndpoint, UiCompositionPlanInputSource, UiCompositionPlanPreflightResult, UiCompositionPlanSelectionSync, UiCompositionPlanSelectionSyncMapping, UiCompositionPlanSourceEndpoint, UiCompositionPlanStateEndpoint, UiCompositionPlanTargetEndpoint, UiCompositionPlanTemplateMaterialization, UiCompositionPlanTemplateRef, UiCompositionPlanTemplateReference, UiCompositionPlanTemplateResolutionResult, UiCompositionPlanTemplateRevision, UiCompositionPlanTransform, UiCompositionPlanTransformOutput, UiCompositionPlanWidget, ValueKind };