@praxisui/dynamic-form 1.0.0-beta.59 → 1.0.0-beta.60

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/index.d.ts CHANGED
@@ -5,7 +5,7 @@ import { Router, ActivatedRoute } from '@angular/router';
5
5
  import { MatDialog } from '@angular/material/dialog';
6
6
  import { MatSnackBar } from '@angular/material/snack-bar';
7
7
  import { CdkDragStart, CdkDragMove, CdkDragEnd, CdkDragDrop } from '@angular/cdk/drag-drop';
8
- import { AsyncConfigStorage, FormLayout, FieldMetadata, FormLayoutRule, FormRuleTargetType as FormRuleTargetType$1, FormSection, FormRow, FormColumn, FormConfig, FormActionButton, BackConfig, FormHooksLayout, EndpointConfig, FormSubmitEvent, FormReadyEvent, FormValueChangeEvent, SyncResult, FormInitializationError, LoadingState, FormCustomActionEvent, FormActionConfirmationEvent, GenericCrudService, ConnectionStorage, DynamicFormService, ErrorMessageService, SchemaNormalizerService, ComponentMetadataRegistry, GlobalConfigService, ComponentKeyService, LoadingOrchestrator, PraxisLoadingRenderer, FormHooksRegistry, FormHookPreset, LoggerService, FormConfigState, FieldDefinition, Breakpoint, ComponentDocMeta, IconPickerService, AiCapabilityCategory, AiValueKind, AiCapability, AiCapabilityCatalog } from '@praxisui/core';
8
+ import { AsyncConfigStorage, FormLayout, FieldMetadata, FormLayoutRule, FormRuleTargetType as FormRuleTargetType$1, FormSection, FormRow, FormColumn, FormConfig, FormActionButton, BackConfig, FormHooksLayout, EndpointConfig, FormSubmitEvent, FormReadyEvent, FormValueChangeEvent, SyncResult, FormInitializationError, LoadingState, FormCustomActionEvent, FormActionConfirmationEvent, WidgetDefinition, GenericCrudService, ConnectionStorage, DynamicFormService, ErrorMessageService, SchemaNormalizerService, ComponentMetadataRegistry, GlobalConfigService, ComponentKeyService, LoadingOrchestrator, PraxisLoadingRenderer, FormHooksRegistry, FormHookPreset, LoggerService, FormConfigState, FieldDefinition, Breakpoint, ComponentDocMeta, IconPickerService, AiCapabilityCategory, AiValueKind, AiCapability, AiCapabilityCatalog } from '@praxisui/core';
9
9
  import * as rxjs from 'rxjs';
10
10
  import { Observable, BehaviorSubject } from 'rxjs';
11
11
  import { SettingsPanelService, SettingsValueProvider } from '@praxisui/settings-panel';
@@ -379,6 +379,12 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
379
379
  private readonly DEBUG;
380
380
  resourcePath?: string;
381
381
  resourceId?: string | number;
382
+ /**
383
+ * Shared editorial context for widgets hosted before/after the form.
384
+ * Treat this input as immutable: in-place mutations do not invalidate the cached
385
+ * widget context snapshot used to avoid re-binding on every change detection pass.
386
+ */
387
+ editorialContext: Record<string, unknown> | null;
382
388
  mode: 'create' | 'edit' | 'view';
383
389
  config: FormConfig;
384
390
  /**
@@ -459,6 +465,13 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
459
465
  }>;
460
466
  /** Forwarded from DynamicFieldLoader to allow host-side observability. */
461
467
  fieldRenderError: EventEmitter<DynamicFieldRenderErrorEvent>;
468
+ /** Re-emits events from editorial widgets hosted before/after the form sections. */
469
+ widgetEvent: EventEmitter<{
470
+ placement: "before" | "after";
471
+ sourceId: string;
472
+ output?: string;
473
+ payload?: any;
474
+ }>;
462
475
  isLoading: boolean;
463
476
  submitting: boolean;
464
477
  submitError: string | null;
@@ -491,6 +504,27 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
491
504
  private lastFieldPatchAt;
492
505
  schemaOutdated: boolean;
493
506
  private resolvedPrefs;
507
+ private editorialWidgetContextCache;
508
+ private editorialWidgetContextDeps;
509
+ get formBlocksBefore(): WidgetDefinition[];
510
+ get formBlocksAfter(): WidgetDefinition[];
511
+ /**
512
+ * Precedence for editorial widget interpolation:
513
+ * 1. form runtime context
514
+ * 2. config.editorialContext
515
+ * 3. host editorialContext input
516
+ * Later layers override earlier ones.
517
+ * Widget explicit inputs still win after interpolation because they are bound directly.
518
+ *
519
+ * Invariant: config.editorialContext and editorialContext must be replaced immutably.
520
+ * In-place mutations do not invalidate the cached merged context snapshot.
521
+ */
522
+ getEditorialWidgetContext(): Record<string, unknown>;
523
+ onEditorialWidgetEvent(placement: 'before' | 'after', event: {
524
+ sourceId: string;
525
+ output?: string;
526
+ payload?: any;
527
+ }): void;
494
528
  private reactiveValidate$?;
495
529
  private warnedMissingId;
496
530
  private schemaState;
@@ -759,7 +793,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
759
793
  private applyPresentationVars;
760
794
  private applyPresentationConfig;
761
795
  static ɵfac: i0.ɵɵFactoryDeclaration<PraxisDynamicForm, [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }]>;
762
- static ɵcmp: i0.ɵɵComponentDeclaration<PraxisDynamicForm, "praxis-dynamic-form", never, { "resourcePath": { "alias": "resourcePath"; "required": false; }; "resourceId": { "alias": "resourceId"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "config": { "alias": "config"; "required": false; }; "schemaSource": { "alias": "schemaSource"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "formId": { "alias": "formId"; "required": false; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "layout": { "alias": "layout"; "required": false; }; "backConfig": { "alias": "backConfig"; "required": false; }; "hooks": { "alias": "hooks"; "required": false; }; "removeEmptyContainersOnSave": { "alias": "removeEmptyContainersOnSave"; "required": false; }; "reactiveValidation": { "alias": "reactiveValidation"; "required": false; }; "reactiveValidationDebounceMs": { "alias": "reactiveValidationDebounceMs"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "readonlyModeGlobal": { "alias": "readonlyModeGlobal"; "required": false; }; "disabledModeGlobal": { "alias": "disabledModeGlobal"; "required": false; }; "presentationModeGlobal": { "alias": "presentationModeGlobal"; "required": false; }; "visibleGlobal": { "alias": "visibleGlobal"; "required": false; }; "customEndpoints": { "alias": "customEndpoints"; "required": false; }; }, { "formSubmit": "formSubmit"; "formCancel": "formCancel"; "formReset": "formReset"; "configChange": "configChange"; "formReady": "formReady"; "valueChange": "valueChange"; "syncCompleted": "syncCompleted"; "initializationError": "initializationError"; "loadingStateChange": "loadingStateChange"; "editModeEnabledChange": "editModeEnabledChange"; "customAction": "customAction"; "actionConfirmation": "actionConfirmation"; "schemaStatusChange": "schemaStatusChange"; "fieldRenderError": "fieldRenderError"; }, never, never, true, never>;
796
+ static ɵcmp: i0.ɵɵComponentDeclaration<PraxisDynamicForm, "praxis-dynamic-form", never, { "resourcePath": { "alias": "resourcePath"; "required": false; }; "resourceId": { "alias": "resourceId"; "required": false; }; "editorialContext": { "alias": "editorialContext"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "config": { "alias": "config"; "required": false; }; "schemaSource": { "alias": "schemaSource"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "formId": { "alias": "formId"; "required": false; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "layout": { "alias": "layout"; "required": false; }; "backConfig": { "alias": "backConfig"; "required": false; }; "hooks": { "alias": "hooks"; "required": false; }; "removeEmptyContainersOnSave": { "alias": "removeEmptyContainersOnSave"; "required": false; }; "reactiveValidation": { "alias": "reactiveValidation"; "required": false; }; "reactiveValidationDebounceMs": { "alias": "reactiveValidationDebounceMs"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "readonlyModeGlobal": { "alias": "readonlyModeGlobal"; "required": false; }; "disabledModeGlobal": { "alias": "disabledModeGlobal"; "required": false; }; "presentationModeGlobal": { "alias": "presentationModeGlobal"; "required": false; }; "visibleGlobal": { "alias": "visibleGlobal"; "required": false; }; "customEndpoints": { "alias": "customEndpoints"; "required": false; }; }, { "formSubmit": "formSubmit"; "formCancel": "formCancel"; "formReset": "formReset"; "configChange": "configChange"; "formReady": "formReady"; "valueChange": "valueChange"; "syncCompleted": "syncCompleted"; "initializationError": "initializationError"; "loadingStateChange": "loadingStateChange"; "editModeEnabledChange": "editModeEnabledChange"; "customAction": "customAction"; "actionConfirmation": "actionConfirmation"; "schemaStatusChange": "schemaStatusChange"; "fieldRenderError": "fieldRenderError"; "widgetEvent": "widgetEvent"; }, never, never, true, never>;
763
797
  }
764
798
 
765
799
  declare class FormConfigService {
@@ -1367,6 +1401,7 @@ declare module '@praxisui/core' {
1367
1401
  metadata: true;
1368
1402
  hooks: true;
1369
1403
  actions: true;
1404
+ editorial: true;
1370
1405
  }
1371
1406
  }
1372
1407
  type CapabilityCategory$1 = AiCapabilityCategory;
@@ -1495,6 +1530,7 @@ declare const ENUMS: {
1495
1530
  fieldHintPosition: FieldHintPosition[];
1496
1531
  sectionTitleStyle: SectionTitleStyle[];
1497
1532
  sectionDescriptionStyle: SectionDescriptionStyle[];
1533
+ editorialContentFormat: string[];
1498
1534
  };
1499
1535
  declare const FORM_AI_CAPABILITIES: CapabilityCatalog$1;
1500
1536
  declare const TASK_PRESETS: Record<string, string[]>;
package/package.json CHANGED
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "@praxisui/dynamic-form",
3
- "version": "1.0.0-beta.59",
3
+ "version": "1.0.0-beta.60",
4
4
  "description": "Angular dynamic form engine for Praxis UI: metadata-driven forms, hooks, and services integrating @praxisui/* packages.",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^20.0.0",
7
7
  "@angular/core": "^20.0.0",
8
8
  "@angular/cdk": "^20.0.0",
9
- "@praxisui/settings-panel": "^1.0.0-beta.59",
10
- "@praxisui/visual-builder": "^1.0.0-beta.59",
11
- "@praxisui/specification-core": "^1.0.0-beta.59",
12
- "@praxisui/specification": "^1.0.0-beta.59",
13
- "@praxisui/core": "^1.0.0-beta.59",
14
- "@praxisui/cron-builder": "^1.0.0-beta.59"
9
+ "@praxisui/settings-panel": "^1.0.0-beta.60",
10
+ "@praxisui/visual-builder": "^1.0.0-beta.60",
11
+ "@praxisui/specification-core": "^1.0.0-beta.60",
12
+ "@praxisui/specification": "^1.0.0-beta.60",
13
+ "@praxisui/core": "^1.0.0-beta.60",
14
+ "@praxisui/cron-builder": "^1.0.0-beta.60"
15
15
  },
16
16
  "dependencies": {
17
17
  "tslib": "^2.3.0",