@praxisui/dynamic-form 6.0.0-beta.0 → 8.0.0-beta.0
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 +47 -60
- package/fesm2022/praxisui-dynamic-form.mjs +232 -124
- package/index.d.ts +19 -15
- package/package.json +6 -5
package/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import { MatDialog } from '@angular/material/dialog';
|
|
|
7
7
|
import { MatSnackBar } from '@angular/material/snack-bar';
|
|
8
8
|
import { CdkDragStart, CdkDragMove, CdkDragEnd, CdkDragDrop } from '@angular/cdk/drag-drop';
|
|
9
9
|
import * as _praxisui_core from '@praxisui/core';
|
|
10
|
-
import { AsyncConfigStorage, FormLayout, FieldMetadata, FormLayoutRule, FormRuleTargetType as FormRuleTargetType$1, PraxisJsonLogicService, FormSection, FormRow, FormColumn, FormConfig, FormActionButton, AiCapability, BackConfig, ApiEndpoint, ApiUrlEntry, FormHooksLayout, EndpointConfig, FormSubmitEvent, FormReadyEvent, FormValueChangeEvent, SyncResult, FormInitializationError, LoadingState, FormCustomActionEvent, FormActionConfirmationEvent,
|
|
10
|
+
import { AsyncConfigStorage, FormLayout, FieldMetadata, FormLayoutRule, FormRuleTargetType as FormRuleTargetType$1, PraxisJsonLogicService, FormSection, FormRow, FormColumn, FormConfig, FormActionButton, AiCapability, BackConfig, ApiEndpoint, ApiUrlEntry, FormHooksLayout, EndpointConfig, FormSubmitEvent, FormReadyEvent, FormValueChangeEvent, SyncResult, FormInitializationError, LoadingState, FormCustomActionEvent, FormActionConfirmationEvent, RichContentDocument, JsonLogicRecord, GenericCrudService, ConnectionStorage, DynamicFormService, ErrorMessageService, SchemaNormalizerService, ComponentMetadataRegistry, GlobalConfigService, ComponentKeyService, LoadingOrchestrator, ApiUrlConfig, PraxisLoadingRenderer, FormHooksRegistry, FormHookPreset, LoggerService, FormSectionHeaderAction, FormSectionHeaderConfig, FormConfigState, FieldDefinition, ComponentDocMeta, Breakpoint, IconPickerService, SurfaceOpenPayload, AiCapabilityCategory, AiValueKind, AiCapabilityCatalog } from '@praxisui/core';
|
|
11
11
|
import * as rxjs from 'rxjs';
|
|
12
12
|
import { Observable, BehaviorSubject } from 'rxjs';
|
|
13
13
|
import { SettingsPanelService, SettingsValueProvider } from '@praxisui/settings-panel';
|
|
@@ -512,10 +512,11 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
512
512
|
private readonly DEBUG;
|
|
513
513
|
resourcePath?: string;
|
|
514
514
|
resourceId?: string | number;
|
|
515
|
+
initialValue?: Record<string, unknown> | null;
|
|
515
516
|
/**
|
|
516
|
-
* Shared editorial context for
|
|
517
|
+
* Shared editorial context for rich content hosted around the form.
|
|
517
518
|
* Treat this input as immutable: in-place mutations do not invalidate the cached
|
|
518
|
-
*
|
|
519
|
+
* merged context snapshot used to avoid re-binding on every change detection pass.
|
|
519
520
|
*/
|
|
520
521
|
editorialContext: Record<string, unknown> | null;
|
|
521
522
|
mode: 'create' | 'edit' | 'view';
|
|
@@ -583,6 +584,8 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
583
584
|
visibleGlobal: boolean | null;
|
|
584
585
|
get effectivePresentation(): boolean;
|
|
585
586
|
get effectiveReadonly(): boolean;
|
|
587
|
+
get effectiveDisabledMode(): boolean | null;
|
|
588
|
+
get effectiveFormIsValid(): boolean;
|
|
586
589
|
/** Value propagated to DynamicFieldLoader; null allows per-field metadata */
|
|
587
590
|
get presentationForLoader(): boolean | null;
|
|
588
591
|
/** Custom endpoints for CRUD operations */
|
|
@@ -610,10 +613,6 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
610
613
|
}>;
|
|
611
614
|
/** Forwarded from DynamicFieldLoader to allow host-side observability. */
|
|
612
615
|
fieldRenderError: EventEmitter<DynamicFieldRenderErrorEvent>;
|
|
613
|
-
/** Re-emits events from editorial widgets hosted before, before actions, or after the form. */
|
|
614
|
-
widgetEvent: EventEmitter<WidgetEventEnvelope & {
|
|
615
|
-
placement: "before" | "beforeActions" | "after";
|
|
616
|
-
}>;
|
|
617
616
|
isLoading: boolean;
|
|
618
617
|
submitting: boolean;
|
|
619
618
|
submitError: string | null;
|
|
@@ -636,6 +635,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
636
635
|
private loadedEntityId;
|
|
637
636
|
private hydratedEntityId;
|
|
638
637
|
private loadedEntityData;
|
|
638
|
+
private entityHydrationPending;
|
|
639
639
|
private schemaCache;
|
|
640
640
|
private lastSchemaMeta?;
|
|
641
641
|
private schemaRootHooks?;
|
|
@@ -643,6 +643,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
643
643
|
private formValueChangesSubscription;
|
|
644
644
|
private formBuildCycleId;
|
|
645
645
|
private suppressedValueChangeBuildId;
|
|
646
|
+
private pendingBootstrapValueChangeBuildId;
|
|
646
647
|
private readonly sectionHeaderBlobUrlCache;
|
|
647
648
|
private readonly sectionHeaderObjectUrls;
|
|
648
649
|
private lastCorrelationId?;
|
|
@@ -654,24 +655,26 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
654
655
|
private resolvedPrefs;
|
|
655
656
|
private editorialWidgetContextCache;
|
|
656
657
|
private editorialWidgetContextDeps;
|
|
657
|
-
|
|
658
|
-
get
|
|
659
|
-
get
|
|
658
|
+
private readonly emptyEditorialRichContentDocument;
|
|
659
|
+
get formBlocksBefore(): RichContentDocument | null;
|
|
660
|
+
get formBlocksAfter(): RichContentDocument | null;
|
|
661
|
+
get formBlocksBeforeActions(): RichContentDocument | null;
|
|
662
|
+
get formBlocksBeforeDocument(): RichContentDocument;
|
|
663
|
+
get formBlocksBeforeActionsDocument(): RichContentDocument;
|
|
664
|
+
get formBlocksAfterDocument(): RichContentDocument;
|
|
660
665
|
get beforeActionsPlacement(): 'insideLastSection' | 'afterSections';
|
|
661
666
|
get actionPlacement(): 'insideLastSection' | 'afterSections' | 'top';
|
|
662
667
|
/**
|
|
663
|
-
* Precedence for editorial
|
|
668
|
+
* Precedence for editorial rich-content interpolation:
|
|
664
669
|
* 1. form runtime context
|
|
665
670
|
* 2. config.editorialContext
|
|
666
671
|
* 3. host editorialContext input
|
|
667
672
|
* Later layers override earlier ones.
|
|
668
|
-
* Widget explicit inputs still win after interpolation because they are bound directly.
|
|
669
673
|
*
|
|
670
674
|
* Invariant: config.editorialContext and editorialContext must be replaced immutably.
|
|
671
675
|
* In-place mutations do not invalidate the cached merged context snapshot.
|
|
672
676
|
*/
|
|
673
|
-
|
|
674
|
-
onEditorialWidgetEvent(placement: 'before' | 'beforeActions' | 'after', event: WidgetEventEnvelope): void;
|
|
677
|
+
getEditorialRichContentContext(): JsonLogicRecord;
|
|
675
678
|
private reactiveValidate$?;
|
|
676
679
|
private warnedMissingId;
|
|
677
680
|
private schemaState;
|
|
@@ -759,6 +762,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
759
762
|
private buildRestoreTargetContext;
|
|
760
763
|
private isCompatibleRuntimeStateContext;
|
|
761
764
|
private restoreFormRuntimeState;
|
|
765
|
+
private getNormalizedInitialValue;
|
|
762
766
|
/**
|
|
763
767
|
* Backward-compatible required validation for DATE_RANGE controls.
|
|
764
768
|
* Some core builds do not enforce required start/end for dateRange fields.
|
|
@@ -1011,7 +1015,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
1011
1015
|
private applyPresentationVars;
|
|
1012
1016
|
private applyPresentationConfig;
|
|
1013
1017
|
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, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }]>;
|
|
1014
|
-
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; }; "schemaUrl": { "alias": "schemaUrl"; "required": false; }; "submitUrl": { "alias": "submitUrl"; "required": false; }; "submitMethod": { "alias": "submitMethod"; "required": false; }; "responseSchemaUrl": { "alias": "responseSchemaUrl"; "required": false; }; "apiEndpointKey": { "alias": "apiEndpointKey"; "required": false; }; "apiUrlEntry": { "alias": "apiUrlEntry"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "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"; "enableCustomizationChange": "enableCustomizationChange"; "customAction": "customAction"; "actionConfirmation": "actionConfirmation"; "schemaStatusChange": "schemaStatusChange"; "fieldRenderError": "fieldRenderError";
|
|
1018
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PraxisDynamicForm, "praxis-dynamic-form", never, { "resourcePath": { "alias": "resourcePath"; "required": false; }; "resourceId": { "alias": "resourceId"; "required": false; }; "initialValue": { "alias": "initialValue"; "required": false; }; "editorialContext": { "alias": "editorialContext"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "config": { "alias": "config"; "required": false; }; "schemaSource": { "alias": "schemaSource"; "required": false; }; "schemaUrl": { "alias": "schemaUrl"; "required": false; }; "submitUrl": { "alias": "submitUrl"; "required": false; }; "submitMethod": { "alias": "submitMethod"; "required": false; }; "responseSchemaUrl": { "alias": "responseSchemaUrl"; "required": false; }; "apiEndpointKey": { "alias": "apiEndpointKey"; "required": false; }; "apiUrlEntry": { "alias": "apiUrlEntry"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "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"; "enableCustomizationChange": "enableCustomizationChange"; "customAction": "customAction"; "actionConfirmation": "actionConfirmation"; "schemaStatusChange": "schemaStatusChange"; "fieldRenderError": "fieldRenderError"; }, never, never, true, never>;
|
|
1015
1019
|
}
|
|
1016
1020
|
|
|
1017
1021
|
declare class FormConfigService {
|
package/package.json
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/dynamic-form",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "8.0.0-beta.0",
|
|
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/
|
|
10
|
-
"@praxisui/
|
|
11
|
-
"@praxisui/
|
|
12
|
-
"@praxisui/
|
|
9
|
+
"@praxisui/rich-content": "^8.0.0-beta.0",
|
|
10
|
+
"@praxisui/settings-panel": "^8.0.0-beta.0",
|
|
11
|
+
"@praxisui/visual-builder": "^8.0.0-beta.0",
|
|
12
|
+
"@praxisui/core": "^8.0.0-beta.0",
|
|
13
|
+
"@praxisui/cron-builder": "^8.0.0-beta.0"
|
|
13
14
|
},
|
|
14
15
|
"dependencies": {
|
|
15
16
|
"tslib": "^2.3.0",
|