@praxisui/dynamic-form 8.0.0-beta.1 → 8.0.0-beta.11
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 +16 -2
- package/fesm2022/praxisui-dynamic-form.mjs +1283 -452
- package/index.d.ts +33 -11
- package/package.json +6 -6
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, 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';
|
|
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, GlobalActionCatalogEntry, FieldDefinition, ComponentDocMeta, Breakpoint, IconPickerService, GlobalActionRef, SurfaceOpenPayload, AiCapabilityCategory, AiValueKind, AiCapabilityCatalog, ComponentAuthoringManifest } 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';
|
|
@@ -349,6 +349,7 @@ declare class PraxisFormActionsComponent implements OnChanges, OnDestroy {
|
|
|
349
349
|
getInvalidSubmitHint(): string;
|
|
350
350
|
private applyOverrides;
|
|
351
351
|
private registerActionShortcuts;
|
|
352
|
+
private resolveButtonActionId;
|
|
352
353
|
private isSecondaryButton;
|
|
353
354
|
static ɵfac: i0.ɵɵFactoryDeclaration<PraxisFormActionsComponent, never>;
|
|
354
355
|
static ɵcmp: i0.ɵɵComponentDeclaration<PraxisFormActionsComponent, "praxis-form-actions", never, { "actions": { "alias": "actions"; "required": false; }; "editorialVisualContext": { "alias": "editorialVisualContext"; "required": false; }; "isSubmitting": { "alias": "isSubmitting"; "required": false; }; "formIsValid": { "alias": "formIsValid"; "required": false; }; "submitError": { "alias": "submitError"; "required": false; }; "invalidRequiredFieldLabels": { "alias": "invalidRequiredFieldLabels"; "required": false; }; "formId": { "alias": "formId"; "required": false; }; "actionOverrides": { "alias": "actionOverrides"; "required": false; }; }, { "action": "action"; }, never, never, true, never>;
|
|
@@ -808,6 +809,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
808
809
|
private hasInteractiveFormState;
|
|
809
810
|
private captureFormRuntimeState;
|
|
810
811
|
private getDirtyFieldNames;
|
|
812
|
+
private collectDirtyFieldNames;
|
|
811
813
|
private buildCurrentFormRuntimeContext;
|
|
812
814
|
private buildRestoreTargetContext;
|
|
813
815
|
private isCompatibleRuntimeStateContext;
|
|
@@ -911,6 +913,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
911
913
|
private _showConfirmationDialog;
|
|
912
914
|
onFormAction(event: PraxisFormActionEvent): void;
|
|
913
915
|
private _executeAction;
|
|
916
|
+
private getFormActionEventId;
|
|
914
917
|
onSubmit(): Promise<void>;
|
|
915
918
|
private navigateAfterSave;
|
|
916
919
|
private shouldConfirmCancelOnDirty;
|
|
@@ -978,6 +981,7 @@ declare class PraxisDynamicForm implements OnInit, OnChanges, OnDestroy {
|
|
|
978
981
|
private getControlTypeName;
|
|
979
982
|
private applyNullDeletionPatch;
|
|
980
983
|
private stripNullMarkersFromPatch;
|
|
984
|
+
private mergeMetadataObjectPatch;
|
|
981
985
|
private deleteMetadataPath;
|
|
982
986
|
private getMetadataPath;
|
|
983
987
|
/**
|
|
@@ -1200,13 +1204,16 @@ declare class PraxisDynamicFormConfigEditor implements SettingsValueProvider, On
|
|
|
1200
1204
|
};
|
|
1201
1205
|
private destroy$;
|
|
1202
1206
|
private hasProcessedInitialRuleState;
|
|
1207
|
+
private jsonEditorIsValid;
|
|
1208
|
+
private globalActionValidationIssues;
|
|
1209
|
+
private readonly globalActionCatalog;
|
|
1203
1210
|
isDirty$: BehaviorSubject<boolean>;
|
|
1204
1211
|
isValid$: BehaviorSubject<boolean>;
|
|
1205
1212
|
isBusy$: BehaviorSubject<boolean>;
|
|
1206
1213
|
private lastRulesSignature;
|
|
1207
1214
|
private readonly DEBUG;
|
|
1208
1215
|
private debugLog;
|
|
1209
|
-
constructor(storage: AsyncConfigStorage, configService: FormConfigService, settingsPanel: SettingsPanelService, cdr: ChangeDetectorRef, injectedData?: any);
|
|
1216
|
+
constructor(storage: AsyncConfigStorage, configService: FormConfigService, settingsPanel: SettingsPanelService, cdr: ChangeDetectorRef, globalActionCatalogSource?: ReadonlyArray<GlobalActionCatalogEntry[]>, injectedData?: any);
|
|
1210
1217
|
ngOnInit(): void;
|
|
1211
1218
|
reset(): void;
|
|
1212
1219
|
updateDirtyState(reason?: string): void;
|
|
@@ -1216,6 +1223,11 @@ declare class PraxisDynamicFormConfigEditor implements SettingsValueProvider, On
|
|
|
1216
1223
|
onJsonValidationChange(result: JsonValidationResult): void;
|
|
1217
1224
|
onJsonEditorEvent(_event: JsonEditorEvent): void;
|
|
1218
1225
|
onConfigChange(newConfig: FormConfig): void;
|
|
1226
|
+
private updateValidityState;
|
|
1227
|
+
private collectGlobalActionValidationIssues;
|
|
1228
|
+
private collectGlobalActionValidationTargets;
|
|
1229
|
+
private findGlobalActionCatalogEntry;
|
|
1230
|
+
private buildGlobalActionCatalog;
|
|
1219
1231
|
onRulesChanged(state: RuleBuilderState): void;
|
|
1220
1232
|
get jsonDocument(): DynamicFormAuthoringDocument;
|
|
1221
1233
|
onBackConfigChange(): void;
|
|
@@ -1248,7 +1260,7 @@ declare class PraxisDynamicFormConfigEditor implements SettingsValueProvider, On
|
|
|
1248
1260
|
private toPresentationSnapshot;
|
|
1249
1261
|
private toSchemaPrefsSnapshot;
|
|
1250
1262
|
private toBackConfigSnapshot;
|
|
1251
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PraxisDynamicFormConfigEditor, [null, null, null, null, { optional: true; }]>;
|
|
1263
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PraxisDynamicFormConfigEditor, [null, null, null, null, { optional: true; }, { optional: true; }]>;
|
|
1252
1264
|
static ɵcmp: i0.ɵɵComponentDeclaration<PraxisDynamicFormConfigEditor, "praxis-dynamic-form-config-editor", never, {}, {}, never, never, true, never>;
|
|
1253
1265
|
}
|
|
1254
1266
|
interface FormConfigLike {
|
|
@@ -1581,6 +1593,7 @@ type ActionCatalogOption = {
|
|
|
1581
1593
|
id: string;
|
|
1582
1594
|
label: string;
|
|
1583
1595
|
description?: string;
|
|
1596
|
+
payloadSchema?: GlobalActionCatalogEntry['payloadSchema'];
|
|
1584
1597
|
param?: {
|
|
1585
1598
|
required?: boolean;
|
|
1586
1599
|
label?: string;
|
|
@@ -1634,7 +1647,6 @@ declare class SectionEditorComponent implements OnInit, AfterViewInit, OnDestroy
|
|
|
1634
1647
|
isBusy$: BehaviorSubject<boolean>;
|
|
1635
1648
|
private readonly globalActionCatalogSource;
|
|
1636
1649
|
private readonly i18n;
|
|
1637
|
-
readonly legacyActionSpecs: _praxisui_core.GlobalActionSpec[];
|
|
1638
1650
|
readonly globalActionCatalog: ActionCatalogOption[];
|
|
1639
1651
|
readonly customActionValue = "__custom__";
|
|
1640
1652
|
private destroy$;
|
|
@@ -1654,12 +1666,12 @@ declare class SectionEditorComponent implements OnInit, AfterViewInit, OnDestroy
|
|
|
1654
1666
|
label?: string;
|
|
1655
1667
|
}): string;
|
|
1656
1668
|
getHeaderActionSpecById(id: string): ActionCatalogOption | undefined;
|
|
1657
|
-
getHeaderActionSelectValue(value?: string): string;
|
|
1658
|
-
getHeaderActionParam(value?: string): string;
|
|
1659
|
-
getHeaderActionCustomValue(value?: string): string;
|
|
1660
|
-
getHeaderGlobalActionSchema(value?: string): _praxisui_core.GlobalActionUiSchema | undefined;
|
|
1661
|
-
getHeaderSurfaceOpenActionPayload(value?: string): SurfaceOpenPayload;
|
|
1662
|
-
isHeaderActionParamMissing(value?: string): boolean;
|
|
1669
|
+
getHeaderActionSelectValue(value?: string, globalAction?: GlobalActionRef): string;
|
|
1670
|
+
getHeaderActionParam(value?: string, globalAction?: GlobalActionRef): string;
|
|
1671
|
+
getHeaderActionCustomValue(value?: string, globalAction?: GlobalActionRef): string;
|
|
1672
|
+
getHeaderGlobalActionSchema(value?: string, globalAction?: GlobalActionRef): _praxisui_core.GlobalActionUiSchema | undefined;
|
|
1673
|
+
getHeaderSurfaceOpenActionPayload(value?: string, globalAction?: GlobalActionRef): SurfaceOpenPayload;
|
|
1674
|
+
isHeaderActionParamMissing(value?: string, globalAction?: GlobalActionRef): boolean;
|
|
1663
1675
|
onHeaderActionSelectChange(index: number, value: string): void;
|
|
1664
1676
|
onHeaderActionParamChange(index: number, value: string): void;
|
|
1665
1677
|
onHeaderActionCustomChange(index: number, value: string): void;
|
|
@@ -1693,6 +1705,7 @@ declare class SectionEditorComponent implements OnInit, AfterViewInit, OnDestroy
|
|
|
1693
1705
|
private normalizeHeaderActions;
|
|
1694
1706
|
private mapCatalogEntryToActionSpec;
|
|
1695
1707
|
private getActionCatalogDescription;
|
|
1708
|
+
private normalizeHeaderGlobalAction;
|
|
1696
1709
|
private headerActionStyleValidator;
|
|
1697
1710
|
private stringifyHeaderActionStyle;
|
|
1698
1711
|
private parseHeaderActionStyle;
|
|
@@ -1973,5 +1986,14 @@ declare const FORM_COMPONENT_AI_CAPABILITIES: CapabilityCatalog;
|
|
|
1973
1986
|
*/
|
|
1974
1987
|
declare function getFormAiCatalog(formConfig?: FormConfig): AiCapabilityCatalog;
|
|
1975
1988
|
|
|
1976
|
-
|
|
1989
|
+
/**
|
|
1990
|
+
* Manifesto de authoring canônico para o componente praxis-dynamic-form.
|
|
1991
|
+
* Este arquivo define as operações permitidas pela IA para editar formulários.
|
|
1992
|
+
*
|
|
1993
|
+
* @version 1.4.0
|
|
1994
|
+
* @status COMPLIANT - Alinhado com contrato v2, gate de aceitação e semântica local/schema-backed.
|
|
1995
|
+
*/
|
|
1996
|
+
declare const PRAXIS_DYNAMIC_FORM_AUTHORING_MANIFEST: ComponentAuthoringManifest;
|
|
1997
|
+
|
|
1998
|
+
export { ActionsEditorComponent, CanvasStateService, CanvasToolbarComponent, ColumnEditorComponent, DynamicFormLayoutService, FORM_AI_CAPABILITIES, FORM_COMPONENT_AI_CAPABILITIES, FieldConfiguratorComponent, FieldEditorComponent, FormConfigService, FormContextService, FormLayoutService, JsonConfigEditorComponent, LayoutColorToken, LayoutEditorComponent, LayoutPrefsService, PRAXIS_DYNAMIC_FORM_AUTHORING_MANIFEST, PRAXIS_DYNAMIC_FORM_COMPONENT_METADATA, PRAXIS_FILTER_FORM_COMPONENT_METADATA, PraxisDynamicForm, PraxisDynamicFormConfigEditor, PraxisFilterForm, PraxisFormActionsComponent, RowConfiguratorComponent, RowEditorComponent, SETTINGS_PANEL_DYNAMIC_FORM_PROVIDER, SectionEditorComponent, TASK_PRESETS, applyVisibilityRules, buildDynamicFormApplyPlan, createDynamicFormAuthoringDocument, formLayoutRulesToBuilderState, getFormAiCatalog, getFormCapabilities, getFormEnum, isRuleSatisfied, normalizeDateArrays, normalizeDynamicFormAuthoringDocument, parseLegacyOrDynamicFormDocument, providePraxisDynamicFormMetadata, providePraxisFilterFormMetadata, provideSettingsPanelDynamicForm, ruleBuilderStateToFormLayoutRules, serializeDynamicFormAuthoringDocument, stripLegacyFieldMetadata, toCanonicalDynamicFormConfig, validateDynamicFormAuthoringDocument, validateDynamicFormAuthoringInput };
|
|
1977
1999
|
export type { CanvasElement, CanvasElementType, CanvasPathPart, Capability$1 as Capability, CapabilityCatalog$1 as CapabilityCatalog, CapabilityCategory$1 as CapabilityCategory, DynamicFieldRenderErrorEvent, DynamicFormApplyPlan, DynamicFormAuthoringDocument, DynamicFormBindings, DynamicFormContextSnapshot, DynamicFormMode, DynamicFormPresentationSnapshot, DynamicFormProjectionContext, DynamicFormResolvedRuntimeContract, DynamicFormRuntimeContext, DynamicFormRuntimeValueSource, DynamicFormSchemaPrefsSnapshot, DynamicFormValidationContext, EditorDiagnostic, EditorDocument, FieldPath, FieldPathContainer, FieldPathWithIndex, Capability as FormComponentCapability, CapabilityCatalog as FormComponentCapabilityCatalog, CapabilityCategory as FormComponentCapabilityCategory, ValueKind as FormComponentValueKind, FormConfigLike, IdPath, JsonEditorEvent, JsonValidationResult, LayoutChange, LayoutResult, Operation, Path, PathWithIndex, PraxisFormActionEvent, RemovePolicy, ValidationReport, ValueKind$1 as ValueKind };
|
package/package.json
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/dynamic-form",
|
|
3
|
-
"version": "8.0.0-beta.
|
|
3
|
+
"version": "8.0.0-beta.11",
|
|
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/rich-content": "^8.0.0-beta.
|
|
10
|
-
"@praxisui/settings-panel": "^8.0.0-beta.
|
|
11
|
-
"@praxisui/visual-builder": "^8.0.0-beta.
|
|
12
|
-
"@praxisui/core": "^8.0.0-beta.
|
|
13
|
-
"@praxisui/cron-builder": "^8.0.0-beta.
|
|
9
|
+
"@praxisui/rich-content": "^8.0.0-beta.11",
|
|
10
|
+
"@praxisui/settings-panel": "^8.0.0-beta.11",
|
|
11
|
+
"@praxisui/visual-builder": "^8.0.0-beta.11",
|
|
12
|
+
"@praxisui/core": "^8.0.0-beta.11",
|
|
13
|
+
"@praxisui/cron-builder": "^8.0.0-beta.11"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
16
|
"tslib": "^2.3.0",
|