@acorex/platform 21.0.0-next.42 → 21.0.0-next.44
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/fesm2022/acorex-platform-auth.mjs +4 -0
- package/fesm2022/acorex-platform-auth.mjs.map +1 -1
- package/fesm2022/{acorex-platform-common-common-settings.provider-G9XcXXOG.mjs → acorex-platform-common-common-settings.provider-lWz_f-Ia.mjs} +22 -24
- package/fesm2022/acorex-platform-common-common-settings.provider-lWz_f-Ia.mjs.map +1 -0
- package/fesm2022/acorex-platform-common.mjs +115 -23
- package/fesm2022/acorex-platform-common.mjs.map +1 -1
- package/fesm2022/acorex-platform-core.mjs +172 -19
- package/fesm2022/acorex-platform-core.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-builder.mjs +164 -24
- package/fesm2022/acorex-platform-layout-builder.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-components.mjs +235 -15
- package/fesm2022/acorex-platform-layout-components.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-designer.mjs +40 -5
- package/fesm2022/acorex-platform-layout-designer.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-entity.mjs +539 -8
- package/fesm2022/acorex-platform-layout-entity.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-widgets.mjs +161 -130
- package/fesm2022/acorex-platform-layout-widgets.mjs.map +1 -1
- package/fesm2022/acorex-platform-runtime.mjs +65 -2
- package/fesm2022/acorex-platform-runtime.mjs.map +1 -1
- package/fesm2022/acorex-platform-themes-default.mjs +1 -1
- package/fesm2022/acorex-platform-themes-default.mjs.map +1 -1
- package/fesm2022/{acorex-platform-themes-shared-settings.provider-D13QB3Hr.mjs → acorex-platform-themes-shared-settings.provider-DK6R87Lf.mjs} +23 -24
- package/fesm2022/acorex-platform-themes-shared-settings.provider-DK6R87Lf.mjs.map +1 -0
- package/fesm2022/acorex-platform-themes-shared.mjs +2 -2
- package/package.json +1 -1
- package/types/acorex-platform-common.d.ts +39 -5
- package/types/acorex-platform-core.d.ts +21 -3
- package/types/acorex-platform-layout-builder.d.ts +63 -21
- package/types/acorex-platform-layout-components.d.ts +54 -3
- package/types/acorex-platform-layout-entity.d.ts +143 -6
- package/types/acorex-platform-layout-widgets.d.ts +19 -5
- package/types/acorex-platform-runtime.d.ts +6 -0
- package/fesm2022/acorex-platform-common-common-settings.provider-G9XcXXOG.mjs.map +0 -1
- package/fesm2022/acorex-platform-themes-shared-settings.provider-D13QB3Hr.mjs.map +0 -1
|
@@ -2,8 +2,10 @@ import * as i5 from '@angular/common';
|
|
|
2
2
|
import { CommonModule } from '@angular/common';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
4
|
import { Injectable, inject, input, model, signal, computed, effect, output, viewChild, ChangeDetectionStrategy, Component, NgModule, EventEmitter, Output } from '@angular/core';
|
|
5
|
-
import { provideCommandSetups } from '@acorex/platform/runtime';
|
|
5
|
+
import { provideCommandSetups, AXPCommandService } from '@acorex/platform/runtime';
|
|
6
6
|
import { AXPopupService } from '@acorex/components/popup';
|
|
7
|
+
import * as i4 from '@acorex/platform/core';
|
|
8
|
+
import { AXPHookService, AXPExpressionEvaluatorService, AXPComponentSlotModule, AXPContextStore } from '@acorex/platform/core';
|
|
7
9
|
import * as i1 from '@acorex/platform/layout/widget-core';
|
|
8
10
|
import { AXPWidgetSerializationHelper, AXPWidgetContainerComponent, AXPPageStatus, AXPWidgetCoreModule, AXPWidgetRegistryService } from '@acorex/platform/layout/widget-core';
|
|
9
11
|
import { cloneDeep, isNil, set, isEqual, merge } from 'lodash-es';
|
|
@@ -19,10 +21,35 @@ import { AXLoadingModule } from '@acorex/components/loading';
|
|
|
19
21
|
import { AXBasePageComponent } from '@acorex/components/page';
|
|
20
22
|
import * as i6 from '@acorex/core/translation';
|
|
21
23
|
import { AXTranslationModule, AXTranslationService } from '@acorex/core/translation';
|
|
22
|
-
import * as i4 from '@acorex/platform/core';
|
|
23
|
-
import { AXPExpressionEvaluatorService, AXPComponentSlotModule, AXPContextStore } from '@acorex/platform/core';
|
|
24
24
|
import { AXP_ENTITY_DEFINITION_CRUD_SERVICE } from '@acorex/platform/domain';
|
|
25
25
|
|
|
26
|
+
//#region ---- Imports ----
|
|
27
|
+
//#endregion
|
|
28
|
+
//#region ---- Before open ----
|
|
29
|
+
/**
|
|
30
|
+
* Runs after dialog options and context are prepared and **before** footer customization and popup open.
|
|
31
|
+
* Listeners may mutate {@link AXPLayoutBuilderDialogBeforeOpenPayload.context} by reference.
|
|
32
|
+
*/
|
|
33
|
+
const AXP_LAYOUT_BUILDER_DIALOG_BEFORE_OPEN_HOOK_KEY = 'layout-builder.dialog.before-open';
|
|
34
|
+
//#endregion
|
|
35
|
+
//#region ---- Footer actions ----
|
|
36
|
+
/**
|
|
37
|
+
* Runs after builder-defined footer actions exist and **before** the dialog opens.
|
|
38
|
+
* Listeners receive the live `actions.footer.prefix` / `suffix` arrays (same references as the dialog)
|
|
39
|
+
* so they may push, splice, filter, or replace items. They may also mutate {@link AXPLayoutBuilderDialogFooterPayload.context} by reference.
|
|
40
|
+
*/
|
|
41
|
+
const AXP_LAYOUT_BUILDER_DIALOG_CONFIG_HOOK_KEY = 'layout-builder.dialog.config';
|
|
42
|
+
//#endregion
|
|
43
|
+
//#region ---- Context updates (after open) ----
|
|
44
|
+
/**
|
|
45
|
+
* Runs whenever the dialog layout builder context changes (debounced upstream), **after** the popup is visible.
|
|
46
|
+
* Use for side effects that depend on live context (for example values updated by widgets after render).
|
|
47
|
+
* Payload mirrors `AXPDialogRendererComponent` semantics: {@link AXPLayoutBuilderDialogContextChangedPayload.getContext},
|
|
48
|
+
* {@link AXPLayoutBuilderDialogContextChangedPayload.patchContext}, and optional loading state.
|
|
49
|
+
*/
|
|
50
|
+
const AXP_LAYOUT_BUILDER_DIALOG_CONTEXT_CHANGED_HOOK_KEY = 'layout-builder.dialog.context-changed';
|
|
51
|
+
//#endregion
|
|
52
|
+
|
|
26
53
|
class AXPLayoutConversionService {
|
|
27
54
|
constructor() {
|
|
28
55
|
//#region ---- Caching ----
|
|
@@ -412,12 +439,13 @@ function getNestedValue(obj, path) {
|
|
|
412
439
|
class AXPLayoutBuilderService {
|
|
413
440
|
constructor() {
|
|
414
441
|
this.popupService = inject(AXPopupService);
|
|
442
|
+
this.hookService = inject(AXPHookService, { optional: true }) ?? undefined;
|
|
415
443
|
}
|
|
416
444
|
/**
|
|
417
445
|
* Create a new layout builder
|
|
418
446
|
*/
|
|
419
447
|
create() {
|
|
420
|
-
return new LayoutBuilder(this.popupService);
|
|
448
|
+
return new LayoutBuilder(this.popupService, this.hookService);
|
|
421
449
|
}
|
|
422
450
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPLayoutBuilderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
423
451
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPLayoutBuilderService, providedIn: 'root' }); }
|
|
@@ -435,8 +463,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
|
|
|
435
463
|
* Open/Closed: Extensible through container delegates
|
|
436
464
|
*/
|
|
437
465
|
class LayoutBuilder {
|
|
438
|
-
constructor(popupService) {
|
|
466
|
+
constructor(popupService, hookService) {
|
|
439
467
|
this.popupService = popupService;
|
|
468
|
+
this.hookService = hookService;
|
|
440
469
|
this.root = {
|
|
441
470
|
children: [],
|
|
442
471
|
mode: 'edit',
|
|
@@ -506,7 +535,7 @@ class LayoutBuilder {
|
|
|
506
535
|
if (!this.popupService) {
|
|
507
536
|
throw new Error('LayoutBuilder requires AXPopupService to create dialogs. Please inject it in the service constructor.');
|
|
508
537
|
}
|
|
509
|
-
const container = new DialogContainerBuilder(this.popupService);
|
|
538
|
+
const container = new DialogContainerBuilder(this.popupService, this.hookService);
|
|
510
539
|
if (delegate) {
|
|
511
540
|
delegate(container);
|
|
512
541
|
}
|
|
@@ -1512,7 +1541,7 @@ class ListWidgetBuilder extends WidgetContainerMixin {
|
|
|
1512
1541
|
* Uses composition instead of inheritance for cleaner separation
|
|
1513
1542
|
*/
|
|
1514
1543
|
class DialogContainerBuilder {
|
|
1515
|
-
constructor(popupService) {
|
|
1544
|
+
constructor(popupService, hookService) {
|
|
1516
1545
|
this.dialogState = {
|
|
1517
1546
|
type: 'flex-layout', // This will be overridden when content layout exists
|
|
1518
1547
|
children: [],
|
|
@@ -1535,6 +1564,7 @@ class DialogContainerBuilder {
|
|
|
1535
1564
|
else {
|
|
1536
1565
|
this.popupService = inject(AXPopupService);
|
|
1537
1566
|
}
|
|
1567
|
+
this.hookService = hookService ?? inject(AXPHookService, { optional: true }) ?? undefined;
|
|
1538
1568
|
}
|
|
1539
1569
|
setOptions(options) {
|
|
1540
1570
|
this.dialogState.dialogOptions = { ...this.dialogState.dialogOptions, ...options };
|
|
@@ -1575,7 +1605,12 @@ class DialogContainerBuilder {
|
|
|
1575
1605
|
return this;
|
|
1576
1606
|
}
|
|
1577
1607
|
onAction(handler) {
|
|
1578
|
-
|
|
1608
|
+
this.dialogState.dialogOptions ??= {
|
|
1609
|
+
title: '',
|
|
1610
|
+
size: 'md',
|
|
1611
|
+
closeButton: false,
|
|
1612
|
+
};
|
|
1613
|
+
this.dialogState.dialogOptions.onAction = handler;
|
|
1579
1614
|
return this;
|
|
1580
1615
|
}
|
|
1581
1616
|
addCustomAction(action) {
|
|
@@ -1624,22 +1659,42 @@ class DialogContainerBuilder {
|
|
|
1624
1659
|
const dialogNode = this.build();
|
|
1625
1660
|
// Import the dialog renderer component dynamically
|
|
1626
1661
|
const { AXPDialogRendererComponent } = await Promise.resolve().then(function () { return dialogRenderer_component; });
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1662
|
+
this.dialogState.dialogOptions ??= {};
|
|
1663
|
+
if (this.dialogState.dialogOptions.context == null || typeof this.dialogState.dialogOptions.context !== 'object') {
|
|
1664
|
+
this.dialogState.dialogOptions.context = {};
|
|
1665
|
+
}
|
|
1666
|
+
const initialContext = this.dialogState.dialogOptions.context;
|
|
1667
|
+
this.dialogState.actions ??= { footer: { prefix: [], suffix: [] } };
|
|
1668
|
+
this.dialogState.actions.footer ??= { prefix: [], suffix: [] };
|
|
1669
|
+
this.dialogState.actions.footer.prefix ??= [];
|
|
1670
|
+
this.dialogState.actions.footer.suffix ??= [];
|
|
1671
|
+
const hookService = this.hookService;
|
|
1672
|
+
if (hookService) {
|
|
1673
|
+
const beforePayload = {
|
|
1674
|
+
context: initialContext,
|
|
1675
|
+
dialogOptions: this.dialogState.dialogOptions,
|
|
1676
|
+
};
|
|
1677
|
+
await hookService.runAsync(AXP_LAYOUT_BUILDER_DIALOG_BEFORE_OPEN_HOOK_KEY, beforePayload);
|
|
1678
|
+
}
|
|
1631
1679
|
// Create dialog configuration
|
|
1632
1680
|
const dialogConfig = {
|
|
1633
1681
|
title: this.dialogState.dialogOptions?.title || '',
|
|
1634
|
-
|
|
1682
|
+
//TODO: why we need message?
|
|
1683
|
+
//message: this.dialogState.dialogOptions?.message,
|
|
1635
1684
|
context: initialContext,
|
|
1636
1685
|
definition: dialogNode,
|
|
1686
|
+
metadata: this.dialogState.dialogOptions.metadata,
|
|
1637
1687
|
actions: this.dialogState.actions,
|
|
1638
1688
|
onAction: this.dialogState.dialogOptions?.onAction,
|
|
1639
1689
|
};
|
|
1690
|
+
//
|
|
1691
|
+
if (hookService) {
|
|
1692
|
+
await hookService.runAsync(AXP_LAYOUT_BUILDER_DIALOG_CONFIG_HOOK_KEY, dialogConfig);
|
|
1693
|
+
}
|
|
1640
1694
|
// The Promise resolves when user clicks an action button
|
|
1641
1695
|
return new Promise(async (resolve) => {
|
|
1642
|
-
|
|
1696
|
+
let flag = false;
|
|
1697
|
+
await this.popupService.open(AXPDialogRendererComponent, {
|
|
1643
1698
|
title: dialogConfig.title,
|
|
1644
1699
|
size: this.dialogState.dialogOptions?.size || 'md',
|
|
1645
1700
|
closeButton: this.dialogState.dialogOptions?.closeButton || false,
|
|
@@ -1648,10 +1703,14 @@ class DialogContainerBuilder {
|
|
|
1648
1703
|
data: {
|
|
1649
1704
|
config: dialogConfig,
|
|
1650
1705
|
callBack: (result) => {
|
|
1706
|
+
flag = true;
|
|
1651
1707
|
resolve(result);
|
|
1652
1708
|
},
|
|
1653
1709
|
},
|
|
1654
1710
|
});
|
|
1711
|
+
if (!flag) {
|
|
1712
|
+
resolve({ success: false });
|
|
1713
|
+
}
|
|
1655
1714
|
});
|
|
1656
1715
|
}
|
|
1657
1716
|
}
|
|
@@ -2311,6 +2370,8 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2311
2370
|
super(...arguments);
|
|
2312
2371
|
this.result = new EventEmitter();
|
|
2313
2372
|
this.expressionEvaluator = inject(AXPExpressionEvaluatorService);
|
|
2373
|
+
this.commandService = inject(AXPCommandService);
|
|
2374
|
+
this.hookService = inject(AXPHookService, { optional: true });
|
|
2314
2375
|
this.context = signal({}, ...(ngDevMode ? [{ debugName: "context" }] : /* istanbul ignore next */ []));
|
|
2315
2376
|
// This will be set by the popup service automatically - same as dynamic-dialog
|
|
2316
2377
|
this.callBack = () => { };
|
|
@@ -2318,6 +2379,12 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2318
2379
|
// Aggregated actions for footer rendering
|
|
2319
2380
|
this.footerPrefix = signal([], ...(ngDevMode ? [{ debugName: "footerPrefix" }] : /* istanbul ignore next */ []));
|
|
2320
2381
|
this.footerSuffix = signal([], ...(ngDevMode ? [{ debugName: "footerSuffix" }] : /* istanbul ignore next */ []));
|
|
2382
|
+
/**
|
|
2383
|
+
* Correlate layout context snapshots for distributed hooks (`layout-builder.dialog.context-changed`).
|
|
2384
|
+
*/
|
|
2385
|
+
this.contextChangedHooksSessionKey = typeof crypto !== 'undefined' && typeof crypto.randomUUID === 'function'
|
|
2386
|
+
? crypto.randomUUID()
|
|
2387
|
+
: `layout-dialog-ctx-${Date.now()}-${Math.random().toString(36).slice(2)}`;
|
|
2321
2388
|
//#endregion
|
|
2322
2389
|
//#region ---- View Accessors ----
|
|
2323
2390
|
// Access the internal layout renderer to reach the widgets container injector
|
|
@@ -2348,16 +2415,42 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2348
2415
|
//#region ---- Lifecycle ----
|
|
2349
2416
|
ngOnInit() {
|
|
2350
2417
|
this.context.set(this.config?.context || {});
|
|
2418
|
+
void this.invokeLayoutContextChangedHooks();
|
|
2351
2419
|
}
|
|
2352
2420
|
#eff;
|
|
2353
2421
|
//#endregion
|
|
2354
2422
|
handleContextChanged(event) {
|
|
2355
2423
|
this.context.set(event);
|
|
2356
2424
|
this.aggregateAndEvaluateActions();
|
|
2425
|
+
void this.invokeLayoutContextChangedHooks();
|
|
2357
2426
|
}
|
|
2358
2427
|
handleContextInitiated(event) {
|
|
2359
2428
|
this.context.set(event);
|
|
2360
2429
|
this.aggregateAndEvaluateActions();
|
|
2430
|
+
void this.invokeLayoutContextChangedHooks();
|
|
2431
|
+
}
|
|
2432
|
+
async invokeLayoutContextChangedHooks() {
|
|
2433
|
+
const meta = this.config?.metadata;
|
|
2434
|
+
if (!this.hookService) {
|
|
2435
|
+
return;
|
|
2436
|
+
}
|
|
2437
|
+
const payload = {
|
|
2438
|
+
sessionKey: this.contextChangedHooksSessionKey,
|
|
2439
|
+
getContext: () => (this.context() ?? {}),
|
|
2440
|
+
metadata: meta,
|
|
2441
|
+
patchContext: (partial) => {
|
|
2442
|
+
const merged = merge({}, this.context(), partial);
|
|
2443
|
+
this.context.set(merged);
|
|
2444
|
+
this.layoutRenderer()?.updateContext(merged);
|
|
2445
|
+
},
|
|
2446
|
+
setLoading: (loading) => this.isDialogLoading.set(loading),
|
|
2447
|
+
};
|
|
2448
|
+
try {
|
|
2449
|
+
await this.hookService.runAsync(AXP_LAYOUT_BUILDER_DIALOG_CONTEXT_CHANGED_HOOK_KEY, payload);
|
|
2450
|
+
}
|
|
2451
|
+
catch {
|
|
2452
|
+
// Hook providers are best-effort; avoid breaking the dialog lifecycle.
|
|
2453
|
+
}
|
|
2361
2454
|
}
|
|
2362
2455
|
footerPrefixActions() {
|
|
2363
2456
|
return this.footerPrefix();
|
|
@@ -2379,6 +2472,7 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2379
2472
|
return;
|
|
2380
2473
|
}
|
|
2381
2474
|
}
|
|
2475
|
+
//TODO: matin, why we need this? maybe we can remove it?
|
|
2382
2476
|
if (cmd?.startsWith('widget:')) {
|
|
2383
2477
|
const parsed = this.parseWidgetCommand(cmd);
|
|
2384
2478
|
if (parsed.widgetName && parsed.action) {
|
|
@@ -2387,6 +2481,25 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2387
2481
|
return;
|
|
2388
2482
|
}
|
|
2389
2483
|
}
|
|
2484
|
+
if (cmd && this.commandService.exists(cmd)) {
|
|
2485
|
+
const dialogRef = this.createDialogRef(cmd);
|
|
2486
|
+
const integration = (this.config.metadata ?? {});
|
|
2487
|
+
try {
|
|
2488
|
+
const cmdResult = await this.commandService.execute(cmd, { dialogRef, integration });
|
|
2489
|
+
if (!cmdResult?.success) {
|
|
2490
|
+
return;
|
|
2491
|
+
}
|
|
2492
|
+
if (this.shouldKeepDialogOpenAfterCommandResult(cmdResult)) {
|
|
2493
|
+
return;
|
|
2494
|
+
}
|
|
2495
|
+
this.callBack(cmdResult);
|
|
2496
|
+
await this.closeWithOptionalSkipValidate(cmdResult);
|
|
2497
|
+
}
|
|
2498
|
+
catch (error) {
|
|
2499
|
+
console.error('Error executing action', cmd, error);
|
|
2500
|
+
}
|
|
2501
|
+
return;
|
|
2502
|
+
}
|
|
2390
2503
|
const context = this.context();
|
|
2391
2504
|
const onAction = this.config?.onAction;
|
|
2392
2505
|
if (onAction) {
|
|
@@ -2394,7 +2507,7 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2394
2507
|
try {
|
|
2395
2508
|
this.isDialogLoading.set(true);
|
|
2396
2509
|
const result = await Promise.resolve(onAction(dialogRef));
|
|
2397
|
-
if (result
|
|
2510
|
+
if (this.shouldKeepDialogOpenAfterCommandResult(result)) {
|
|
2398
2511
|
return;
|
|
2399
2512
|
}
|
|
2400
2513
|
this.callBack(result);
|
|
@@ -2432,8 +2545,25 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2432
2545
|
if (cmd.startsWith('widget:')) {
|
|
2433
2546
|
return false;
|
|
2434
2547
|
}
|
|
2548
|
+
if (this.commandService.exists(cmd)) {
|
|
2549
|
+
return false;
|
|
2550
|
+
}
|
|
2435
2551
|
return true;
|
|
2436
2552
|
}
|
|
2553
|
+
/** True when a footer handler or command result asks to leave the dialog open (`keepDialogOpen` on the result or `result.data`). */
|
|
2554
|
+
shouldKeepDialogOpenAfterCommandResult(result) {
|
|
2555
|
+
if (!result || typeof result !== 'object') {
|
|
2556
|
+
return false;
|
|
2557
|
+
}
|
|
2558
|
+
const top = result;
|
|
2559
|
+
if (top.keepDialogOpen === true) {
|
|
2560
|
+
return true;
|
|
2561
|
+
}
|
|
2562
|
+
if (top.data != null && typeof top.data === 'object' && 'keepDialogOpen' in top.data) {
|
|
2563
|
+
return top.data.keepDialogOpen === true;
|
|
2564
|
+
}
|
|
2565
|
+
return false;
|
|
2566
|
+
}
|
|
2437
2567
|
createDialogRef(actionCmd) {
|
|
2438
2568
|
return {
|
|
2439
2569
|
close: (res) => {
|
|
@@ -2623,9 +2753,9 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2623
2753
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.9", type: AXPDialogRendererComponent, isStandalone: true, selector: "axp-dialog-renderer", outputs: { result: "result" }, providers: [AXPContextStore], viewQueries: [{ propertyName: "layoutRenderer", first: true, predicate: AXPLayoutRendererComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: `
|
|
2624
2754
|
<axp-component-slot name="dialog-header" [context]="context()"></axp-component-slot>
|
|
2625
2755
|
<div class="ax-p-4">
|
|
2626
|
-
@if (config.message) {
|
|
2756
|
+
<!-- @if (config.message) {
|
|
2627
2757
|
<p class="ax-mb-4 ax-leading-relaxed">{{ config.message | translate | async }}</p>
|
|
2628
|
-
}
|
|
2758
|
+
} -->
|
|
2629
2759
|
<axp-layout-renderer
|
|
2630
2760
|
[layout]="config.definition"
|
|
2631
2761
|
[context]="context()"
|
|
@@ -2649,8 +2779,13 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2649
2779
|
[color]="action.color"
|
|
2650
2780
|
(onClick)="executeAction(action)"
|
|
2651
2781
|
>
|
|
2782
|
+
@if (isFormLoading()) {
|
|
2783
|
+
<ax-loading></ax-loading>
|
|
2784
|
+
}
|
|
2652
2785
|
<ax-prefix>
|
|
2653
|
-
|
|
2786
|
+
@if (action.icon) {
|
|
2787
|
+
<ax-icon [icon]="action.icon"></ax-icon>
|
|
2788
|
+
}
|
|
2654
2789
|
</ax-prefix>
|
|
2655
2790
|
</ax-button>
|
|
2656
2791
|
}
|
|
@@ -2669,7 +2804,7 @@ class AXPDialogRendererComponent extends AXBasePageComponent {
|
|
|
2669
2804
|
}
|
|
2670
2805
|
@if (action.icon) {
|
|
2671
2806
|
<ax-prefix>
|
|
2672
|
-
<ax-icon icon="
|
|
2807
|
+
<ax-icon [icon]="action.icon"></ax-icon>
|
|
2673
2808
|
</ax-prefix>
|
|
2674
2809
|
}
|
|
2675
2810
|
</ax-button>
|
|
@@ -2699,9 +2834,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
|
|
|
2699
2834
|
template: `
|
|
2700
2835
|
<axp-component-slot name="dialog-header" [context]="context()"></axp-component-slot>
|
|
2701
2836
|
<div class="ax-p-4">
|
|
2702
|
-
@if (config.message) {
|
|
2837
|
+
<!-- @if (config.message) {
|
|
2703
2838
|
<p class="ax-mb-4 ax-leading-relaxed">{{ config.message | translate | async }}</p>
|
|
2704
|
-
}
|
|
2839
|
+
} -->
|
|
2705
2840
|
<axp-layout-renderer
|
|
2706
2841
|
[layout]="config.definition"
|
|
2707
2842
|
[context]="context()"
|
|
@@ -2725,8 +2860,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
|
|
|
2725
2860
|
[color]="action.color"
|
|
2726
2861
|
(onClick)="executeAction(action)"
|
|
2727
2862
|
>
|
|
2863
|
+
@if (isFormLoading()) {
|
|
2864
|
+
<ax-loading></ax-loading>
|
|
2865
|
+
}
|
|
2728
2866
|
<ax-prefix>
|
|
2729
|
-
|
|
2867
|
+
@if (action.icon) {
|
|
2868
|
+
<ax-icon [icon]="action.icon"></ax-icon>
|
|
2869
|
+
}
|
|
2730
2870
|
</ax-prefix>
|
|
2731
2871
|
</ax-button>
|
|
2732
2872
|
}
|
|
@@ -2745,7 +2885,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
|
|
|
2745
2885
|
}
|
|
2746
2886
|
@if (action.icon) {
|
|
2747
2887
|
<ax-prefix>
|
|
2748
|
-
<ax-icon icon="
|
|
2888
|
+
<ax-icon [icon]="action.icon"></ax-icon>
|
|
2749
2889
|
</ax-prefix>
|
|
2750
2890
|
}
|
|
2751
2891
|
</ax-button>
|
|
@@ -2950,5 +3090,5 @@ var previewWidgetField_command = /*#__PURE__*/Object.freeze({
|
|
|
2950
3090
|
* Generated bundle index. Do not edit.
|
|
2951
3091
|
*/
|
|
2952
3092
|
|
|
2953
|
-
export { AXPDialogRendererComponent, AXPLayoutBuilderService, AXPLayoutConversionService, AXPLayoutRendererComponent, AXPPreviewWidgetFieldCommand, AXP_PREVIEW_WIDGET_FIELD_COMMAND_KEY, LayoutBuilderModule };
|
|
3093
|
+
export { AXPDialogRendererComponent, AXPLayoutBuilderService, AXPLayoutConversionService, AXPLayoutRendererComponent, AXPPreviewWidgetFieldCommand, AXP_LAYOUT_BUILDER_DIALOG_BEFORE_OPEN_HOOK_KEY, AXP_LAYOUT_BUILDER_DIALOG_CONFIG_HOOK_KEY, AXP_LAYOUT_BUILDER_DIALOG_CONTEXT_CHANGED_HOOK_KEY, AXP_PREVIEW_WIDGET_FIELD_COMMAND_KEY, LayoutBuilderModule };
|
|
2954
3094
|
//# sourceMappingURL=acorex-platform-layout-builder.mjs.map
|