@praxisui/crud 8.0.0-beta.0 → 8.0.0-beta.100
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/package.json
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/crud",
|
|
3
|
-
"version": "8.0.0-beta.
|
|
3
|
+
"version": "8.0.0-beta.100",
|
|
4
4
|
"description": "CRUD building blocks for Praxis UI: integrates dynamic forms and tables with unified configuration and services.",
|
|
5
5
|
"peerDependencies": {
|
|
6
|
-
"@angular/common": "^
|
|
7
|
-
"@angular/core": "^
|
|
8
|
-
"@praxisui/dynamic-form": "^8.0.0-beta.
|
|
9
|
-
"@praxisui/table": "^8.0.0-beta.
|
|
10
|
-
"@praxisui/core": "^8.0.0-beta.
|
|
11
|
-
"@praxisui/dynamic-fields": "^8.0.0-beta.
|
|
12
|
-
"@praxisui/settings-panel": "^8.0.0-beta.
|
|
6
|
+
"@angular/common": "^21.0.0",
|
|
7
|
+
"@angular/core": "^21.0.0",
|
|
8
|
+
"@praxisui/dynamic-form": "^8.0.0-beta.100",
|
|
9
|
+
"@praxisui/table": "^8.0.0-beta.100",
|
|
10
|
+
"@praxisui/core": "^8.0.0-beta.100",
|
|
11
|
+
"@praxisui/dynamic-fields": "^8.0.0-beta.100",
|
|
12
|
+
"@praxisui/settings-panel": "^8.0.0-beta.100",
|
|
13
|
+
"@angular/cdk": "^21.0.0",
|
|
14
|
+
"@angular/forms": "^21.0.0",
|
|
15
|
+
"@angular/material": "^21.0.0",
|
|
16
|
+
"@angular/router": "^21.0.0",
|
|
17
|
+
"@praxisui/ai": "^8.0.0-beta.100",
|
|
18
|
+
"rxjs": "~7.8.0"
|
|
13
19
|
},
|
|
14
20
|
"dependencies": {
|
|
15
21
|
"tslib": "^2.3.0"
|
|
@@ -37,18 +43,19 @@
|
|
|
37
43
|
],
|
|
38
44
|
"sideEffects": false,
|
|
39
45
|
"module": "fesm2022/praxisui-crud.mjs",
|
|
40
|
-
"typings": "
|
|
46
|
+
"typings": "types/praxisui-crud.d.ts",
|
|
41
47
|
"exports": {
|
|
42
48
|
"./package.json": {
|
|
43
49
|
"default": "./package.json"
|
|
44
50
|
},
|
|
45
51
|
".": {
|
|
46
|
-
"types": "./
|
|
52
|
+
"types": "./types/praxisui-crud.d.ts",
|
|
47
53
|
"default": "./fesm2022/praxisui-crud.mjs"
|
|
48
54
|
},
|
|
49
55
|
"./drawer-adapter": {
|
|
50
|
-
"types": "./drawer-adapter
|
|
56
|
+
"types": "./types/praxisui-crud-drawer-adapter.d.ts",
|
|
51
57
|
"default": "./fesm2022/praxisui-crud-drawer-adapter.mjs"
|
|
52
58
|
}
|
|
53
|
-
}
|
|
59
|
+
},
|
|
60
|
+
"type": "module"
|
|
54
61
|
}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import * as _praxisui_core from '@praxisui/core';
|
|
2
|
-
import {
|
|
2
|
+
import { RowAction, ToolbarAction, ApiEndpoint, ApiUrlEntry, BackConfig, TableConfig, PraxisDataQueryContext, FormConfig, ResourceActionCatalogItem, ResourceSurfaceCatalogItem, LoadingState, RestApiLinks, ResourceCapabilitySnapshot, GenericCrudService, AsyncConfigStorage, ComponentDocMeta, AiCapabilityCatalog, AiCapability, AiCapabilityCategory, AiValueKind, ComponentAuthoringManifest, SettingsValueProvider } from '@praxisui/core';
|
|
3
3
|
export { BackConfig } from '@praxisui/core';
|
|
4
4
|
import * as _angular_core from '@angular/core';
|
|
5
|
-
import { NgZone, OnChanges, EventEmitter, SimpleChanges, OnInit, Provider } from '@angular/core';
|
|
5
|
+
import { NgZone, OnChanges, EventEmitter, SimpleChanges, OnInit, Provider, AfterViewInit, OnDestroy } from '@angular/core';
|
|
6
6
|
import { MatDialogConfig, MatDialogRef, MatDialog } from '@angular/material/dialog';
|
|
7
7
|
export { MAT_DIALOG_DATA as DIALOG_DATA } from '@angular/material/dialog';
|
|
8
8
|
import { ComponentType } from '@angular/cdk/portal';
|
|
9
9
|
import { PraxisDynamicForm } from '@praxisui/dynamic-form';
|
|
10
|
+
import * as _praxisui_crud from '@praxisui/crud';
|
|
10
11
|
import { BehaviorSubject } from 'rxjs';
|
|
11
12
|
import * as _praxisui_settings_panel from '@praxisui/settings-panel';
|
|
12
13
|
import { SettingsPanelService } from '@praxisui/settings-panel';
|
|
@@ -123,7 +124,7 @@ interface CrudValidationContext {
|
|
|
123
124
|
}
|
|
124
125
|
|
|
125
126
|
type CrudActionRuntimeEvent = {
|
|
126
|
-
actionConfig?: ResourceActionCatalogItem | null;
|
|
127
|
+
actionConfig?: ResourceActionCatalogItem | ResourceSurfaceCatalogItem | null;
|
|
127
128
|
};
|
|
128
129
|
type CrudContextAction = {
|
|
129
130
|
action: string;
|
|
@@ -162,6 +163,8 @@ declare class PraxisCrudComponent implements OnChanges {
|
|
|
162
163
|
id: string | number;
|
|
163
164
|
}>;
|
|
164
165
|
error: EventEmitter<unknown>;
|
|
166
|
+
rowClick: EventEmitter<unknown>;
|
|
167
|
+
selectionChange: EventEmitter<unknown>;
|
|
165
168
|
tableRuntimeConfigChange: EventEmitter<_praxisui_core.TableConfigModern>;
|
|
166
169
|
crudAuthoringDocumentApplied: EventEmitter<CrudAuthoringWidgetPersistenceEvent>;
|
|
167
170
|
crudAuthoringDocumentSaved: EventEmitter<CrudAuthoringWidgetPersistenceEvent>;
|
|
@@ -181,9 +184,10 @@ declare class PraxisCrudComponent implements OnChanges {
|
|
|
181
184
|
private readonly snack;
|
|
182
185
|
private readonly dialog;
|
|
183
186
|
private readonly i18n;
|
|
184
|
-
private readonly
|
|
185
|
-
private
|
|
186
|
-
private
|
|
187
|
+
private readonly injector;
|
|
188
|
+
private resourceDiscoveryInstance?;
|
|
189
|
+
private actionOpenAdapterInstance?;
|
|
190
|
+
private surfaceOpenAdapterInstance?;
|
|
187
191
|
private readonly global;
|
|
188
192
|
private readonly surfaceService;
|
|
189
193
|
private readonly componentKeys;
|
|
@@ -199,9 +203,15 @@ declare class PraxisCrudComponent implements OnChanges {
|
|
|
199
203
|
private collectionCapabilitiesResolvedHref;
|
|
200
204
|
private collectionCapabilitiesRequestSeq;
|
|
201
205
|
private currentAuthoringDocument?;
|
|
206
|
+
private getResourceDiscovery;
|
|
207
|
+
private getActionOpenAdapter;
|
|
208
|
+
private getSurfaceOpenAdapter;
|
|
202
209
|
onResetPreferences(): void;
|
|
210
|
+
onTableRowClick(event: unknown): void;
|
|
211
|
+
onTableSelectionChange(event: unknown): void;
|
|
203
212
|
ngOnChanges(changes: SimpleChanges): void;
|
|
204
213
|
onAction(action: string, row?: Record<string, unknown>, runtimeEvent?: CrudActionRuntimeEvent): Promise<void>;
|
|
214
|
+
private hasExplicitOpenBinding;
|
|
205
215
|
getCurrentTableConfigSnapshot(): TableConfig | null;
|
|
206
216
|
onTableMetadataChange(): void;
|
|
207
217
|
onTableLoadingStateChange(state: LoadingState): void;
|
|
@@ -230,6 +240,7 @@ declare class PraxisCrudComponent implements OnChanges {
|
|
|
230
240
|
private resolveDiscoveredActionCatalog;
|
|
231
241
|
private selectDiscoveredWorkflowAction;
|
|
232
242
|
private resolveProvidedWorkflowAction;
|
|
243
|
+
private resolveProvidedSurface;
|
|
233
244
|
private selectSurfaceForCrudAction;
|
|
234
245
|
private getPreferredSurfaceIdsForCrudAction;
|
|
235
246
|
private isDiscoveryManagedCrudAction;
|
|
@@ -265,7 +276,7 @@ declare class PraxisCrudComponent implements OnChanges {
|
|
|
265
276
|
private getCrudActionLabel;
|
|
266
277
|
private tx;
|
|
267
278
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PraxisCrudComponent, never>;
|
|
268
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PraxisCrudComponent, "praxis-crud", never, { "metadata": { "alias": "metadata"; "required": true; }; "crudId": { "alias": "crudId"; "required": true; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "context": { "alias": "context"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "required": false; }; }, { "configureRequested": "configureRequested"; "afterOpen": "afterOpen"; "afterClose": "afterClose"; "afterSave": "afterSave"; "afterDelete": "afterDelete"; "error": "error"; "tableRuntimeConfigChange": "tableRuntimeConfigChange"; "crudAuthoringDocumentApplied": "crudAuthoringDocumentApplied"; "crudAuthoringDocumentSaved": "crudAuthoringDocumentSaved"; }, never, never, true, never>;
|
|
279
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PraxisCrudComponent, "praxis-crud", never, { "metadata": { "alias": "metadata"; "required": true; }; "crudId": { "alias": "crudId"; "required": true; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "context": { "alias": "context"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "required": false; }; }, { "configureRequested": "configureRequested"; "afterOpen": "afterOpen"; "afterClose": "afterClose"; "afterSave": "afterSave"; "afterDelete": "afterDelete"; "error": "error"; "rowClick": "rowClick"; "selectionChange": "selectionChange"; "tableRuntimeConfigChange": "tableRuntimeConfigChange"; "crudAuthoringDocumentApplied": "crudAuthoringDocumentApplied"; "crudAuthoringDocumentSaved": "crudAuthoringDocumentSaved"; }, never, never, true, never>;
|
|
269
280
|
}
|
|
270
281
|
|
|
271
282
|
type CrudDrawerResultType = 'save' | 'delete' | 'close';
|
|
@@ -336,12 +347,15 @@ declare class DynamicFormDialogHostComponent implements OnInit {
|
|
|
336
347
|
submitMethod?: string | null;
|
|
337
348
|
apiEndpointKey?: ApiEndpoint | string | null;
|
|
338
349
|
apiUrlEntry?: ApiUrlEntry | null;
|
|
350
|
+
formActions?: FormConfig['actions'];
|
|
339
351
|
mode: 'create' | 'edit' | 'view';
|
|
340
352
|
backConfig?: BackConfig;
|
|
341
353
|
private idField;
|
|
342
354
|
texts: Record<string, string>;
|
|
343
355
|
constructor(dialogRef: DialogRef<DynamicFormDialogHostComponent>, data: any, dialogService: DialogService, crud: GenericCrudService<any>, configStorage: AsyncConfigStorage);
|
|
344
356
|
private extractInitialValue;
|
|
357
|
+
private resolveFormActions;
|
|
358
|
+
private resolveSubmitLabel;
|
|
345
359
|
ngOnInit(): void;
|
|
346
360
|
onSave(result: unknown): void;
|
|
347
361
|
onCancel(): void;
|
|
@@ -396,6 +410,8 @@ interface CapabilityCatalog extends AiCapabilityCatalog {
|
|
|
396
410
|
}
|
|
397
411
|
declare const CRUD_AI_CAPABILITIES: CapabilityCatalog;
|
|
398
412
|
|
|
413
|
+
declare const PRAXIS_CRUD_AUTHORING_MANIFEST: ComponentAuthoringManifest;
|
|
414
|
+
|
|
399
415
|
declare function createCrudAuthoringDocument(source: {
|
|
400
416
|
metadata?: unknown;
|
|
401
417
|
}): CrudAuthoringDocument;
|
|
@@ -442,7 +458,7 @@ declare class CrudMetadataEditorComponent implements SettingsValueProvider {
|
|
|
442
458
|
private lastExternalSignature;
|
|
443
459
|
readonly effectiveCrudId: _angular_core.Signal<string | null>;
|
|
444
460
|
readonly isReadonly: _angular_core.Signal<boolean>;
|
|
445
|
-
readonly diagnostics: _angular_core.Signal<CrudEditorDiagnostic[]>;
|
|
461
|
+
readonly diagnostics: _angular_core.Signal<_praxisui_crud.CrudEditorDiagnostic[]>;
|
|
446
462
|
readonly errorCount: _angular_core.Signal<number>;
|
|
447
463
|
readonly warningCount: _angular_core.Signal<number>;
|
|
448
464
|
readonly serializedDocument: _angular_core.Signal<string>;
|
|
@@ -473,7 +489,7 @@ declare class CrudMetadataEditorComponent implements SettingsValueProvider {
|
|
|
473
489
|
readonly showHealthMap: _angular_core.Signal<boolean>;
|
|
474
490
|
readonly groupedDiagnostics: _angular_core.Signal<{
|
|
475
491
|
section: CrudEditorSectionKey;
|
|
476
|
-
issues: CrudEditorDiagnostic[];
|
|
492
|
+
issues: _praxisui_crud.CrudEditorDiagnostic[];
|
|
477
493
|
hasError: boolean;
|
|
478
494
|
}[]>;
|
|
479
495
|
constructor();
|
|
@@ -580,6 +596,39 @@ declare class CrudMetadataEditorComponent implements SettingsValueProvider {
|
|
|
580
596
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<CrudMetadataEditorComponent, "praxis-crud-metadata-editor", never, { "documentInput": { "alias": "document"; "required": false; "isSignal": true; }; "metadataInput": { "alias": "metadata"; "required": false; "isSignal": true; }; "crudIdInput": { "alias": "crudId"; "required": false; "isSignal": true; }; "readonlyInput": { "alias": "readonly"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
581
597
|
}
|
|
582
598
|
|
|
599
|
+
interface PraxisCrudWidgetEditorInputs {
|
|
600
|
+
metadata?: CrudMetadata | string | null;
|
|
601
|
+
crudId?: string;
|
|
602
|
+
componentInstanceId?: string;
|
|
603
|
+
context?: Record<string, unknown>;
|
|
604
|
+
enableCustomization?: boolean;
|
|
605
|
+
[key: string]: unknown;
|
|
606
|
+
}
|
|
607
|
+
interface PraxisCrudWidgetEditorValue {
|
|
608
|
+
inputs: PraxisCrudWidgetEditorInputs;
|
|
609
|
+
}
|
|
610
|
+
declare class PraxisCrudWidgetConfigEditor implements SettingsValueProvider, AfterViewInit, OnDestroy {
|
|
611
|
+
inputs: PraxisCrudWidgetEditorInputs | null;
|
|
612
|
+
widgetKey?: string;
|
|
613
|
+
crudEditor?: CrudMetadataEditorComponent;
|
|
614
|
+
readonly isDirty$: BehaviorSubject<boolean>;
|
|
615
|
+
readonly isValid$: BehaviorSubject<boolean>;
|
|
616
|
+
readonly isBusy$: BehaviorSubject<boolean>;
|
|
617
|
+
private readonly subscription;
|
|
618
|
+
ngAfterViewInit(): void;
|
|
619
|
+
ngOnDestroy(): void;
|
|
620
|
+
get metadata(): CrudMetadata;
|
|
621
|
+
get effectiveCrudId(): string | null;
|
|
622
|
+
getSettingsValue(): PraxisCrudWidgetEditorValue;
|
|
623
|
+
onSave(): PraxisCrudWidgetEditorValue;
|
|
624
|
+
reset(): void;
|
|
625
|
+
private buildValue;
|
|
626
|
+
private createDocumentFromInputs;
|
|
627
|
+
private extractDocument;
|
|
628
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<PraxisCrudWidgetConfigEditor, never>;
|
|
629
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<PraxisCrudWidgetConfigEditor, "praxis-crud-widget-config-editor", never, { "inputs": { "alias": "inputs"; "required": false; }; "widgetKey": { "alias": "widgetKey"; "required": false; }; }, {}, never, never, true, never>;
|
|
630
|
+
}
|
|
631
|
+
|
|
583
632
|
type OpenCrudMetadataEditorOptions = {
|
|
584
633
|
id?: string;
|
|
585
634
|
title?: string;
|
|
@@ -591,5 +640,5 @@ type OpenCrudMetadataEditorOptions = {
|
|
|
591
640
|
};
|
|
592
641
|
declare function openCrudMetadataEditor(settings: SettingsPanelService, opts?: OpenCrudMetadataEditorOptions): _praxisui_settings_panel.SettingsPanelRef;
|
|
593
642
|
|
|
594
|
-
export { CRUD_AI_CAPABILITIES, CrudLauncherService, CrudMetadataEditorComponent, CrudPageHeaderComponent, DialogService, DynamicFormDialogHostComponent, PRAXIS_CRUD_COMPONENT_METADATA, PraxisCrudComponent, assertCrudMetadata, createCrudAuthoringDocument, findCrudAction, normalizeCrudAuthoringDocument, openCrudMetadataEditor, parseLegacyOrCrudDocument, providePraxisCrudMetadata, serializeCrudAuthoringDocument, validateCrudAuthoringDocument };
|
|
595
|
-
export type { Capability, CapabilityCatalog, CapabilityCategory, CrudAction, CrudActionFormContract, CrudActionResolutionMode, CrudAuthoringDocument, CrudAuthoringWidgetPersistenceEvent, CrudDefaults, CrudEditorDiagnostic, CrudHeaderConfig, CrudHeaderVariant, CrudMetadata, CrudMetadataAssertionOptions, CrudParamMapping, CrudResource, CrudValidationContext, DialogConfig, DialogRef, FormOpenMode, OpenCrudMetadataEditorOptions, ValueKind };
|
|
643
|
+
export { CRUD_AI_CAPABILITIES, CrudLauncherService, CrudMetadataEditorComponent, CrudPageHeaderComponent, DialogService, DynamicFormDialogHostComponent, PRAXIS_CRUD_AUTHORING_MANIFEST, PRAXIS_CRUD_COMPONENT_METADATA, PraxisCrudComponent, PraxisCrudWidgetConfigEditor, assertCrudMetadata, createCrudAuthoringDocument, findCrudAction, normalizeCrudAuthoringDocument, openCrudMetadataEditor, parseLegacyOrCrudDocument, providePraxisCrudMetadata, serializeCrudAuthoringDocument, validateCrudAuthoringDocument };
|
|
644
|
+
export type { Capability, CapabilityCatalog, CapabilityCategory, CrudAction, CrudActionFormContract, CrudActionResolutionMode, CrudAuthoringDocument, CrudAuthoringWidgetPersistenceEvent, CrudDefaults, CrudEditorDiagnostic, CrudHeaderConfig, CrudHeaderVariant, CrudMetadata, CrudMetadataAssertionOptions, CrudParamMapping, CrudResource, CrudValidationContext, DialogConfig, DialogRef, FormOpenMode, OpenCrudMetadataEditorOptions, PraxisCrudWidgetEditorInputs, PraxisCrudWidgetEditorValue, ValueKind };
|
|
File without changes
|