@acorex/platform 20.9.9 → 20.9.10
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-common.mjs +18 -0
- package/fesm2022/acorex-platform-common.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-entity.mjs +72 -47
- package/fesm2022/acorex-platform-layout-entity.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-views.mjs +34 -29
- package/fesm2022/acorex-platform-layout-views.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-widget-core.mjs +19 -1
- package/fesm2022/acorex-platform-layout-widget-core.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-widgets.mjs +145 -22
- package/fesm2022/acorex-platform-layout-widgets.mjs.map +1 -1
- package/package.json +1 -1
- package/types/acorex-platform-common.d.ts +6 -0
- package/types/acorex-platform-layout-entity.d.ts +4 -2
- package/types/acorex-platform-layout-widget-core.d.ts +5 -0
- package/types/acorex-platform-layout-widgets.d.ts +34 -0
package/package.json
CHANGED
|
@@ -781,6 +781,7 @@ interface AXPGroupSearchResult {
|
|
|
781
781
|
interface AXPSettingsServiceInterface {
|
|
782
782
|
load(): Promise<AXPSettingValue[]>;
|
|
783
783
|
get<T = any>(key: string): Promise<T>;
|
|
784
|
+
peekCached(key: string): unknown | undefined;
|
|
784
785
|
defaultValues(scope: AXPPlatformScope): Promise<Record<string, unknown>>;
|
|
785
786
|
scope(scope: AXPPlatformScope): ScopedSettingService;
|
|
786
787
|
}
|
|
@@ -802,6 +803,11 @@ declare class AXPSettingsService implements AXPSettingsServiceInterface {
|
|
|
802
803
|
* it is not read at runtime—use it to document the expected result (e.g. `get<boolean>(key)`).
|
|
803
804
|
*/
|
|
804
805
|
get<T = any>(key: string): Promise<T>;
|
|
806
|
+
/**
|
|
807
|
+
* Synchronous read from the in-memory scope cache (User → Tenant → Platform).
|
|
808
|
+
* Returns `undefined` when the key is not cached yet (e.g. before {@link load} completes).
|
|
809
|
+
*/
|
|
810
|
+
peekCached(key: string): unknown | undefined;
|
|
805
811
|
/**
|
|
806
812
|
* Effective value (user → tenant → platform) when set; otherwise the definition default. Used for reads and coercion hints.
|
|
807
813
|
*/
|
|
@@ -1825,14 +1825,16 @@ declare const layoutOrderingMiddlewareProvider: AXPEntityModifierProvider;
|
|
|
1825
1825
|
/**
|
|
1826
1826
|
* Provides synchronous access to the ApplyLayoutOrdering setting.
|
|
1827
1827
|
* Used by layout ordering middleware to avoid async in the modifier and prevent startup deadlocks.
|
|
1828
|
-
*
|
|
1828
|
+
* Reads from the settings in-memory cache when available; refreshes entity definitions when the value changes.
|
|
1829
1829
|
*/
|
|
1830
1830
|
declare class AXPLayoutOrderingConfigService {
|
|
1831
1831
|
private readonly settingsService;
|
|
1832
|
+
private readonly entityRegistry;
|
|
1832
1833
|
private readonly _applyOrdering;
|
|
1833
|
-
private
|
|
1834
|
+
private asyncWarmupScheduled;
|
|
1834
1835
|
constructor();
|
|
1835
1836
|
getApplyOrdering(): boolean;
|
|
1837
|
+
private handleSettingsEvent;
|
|
1836
1838
|
private syncFromSettings;
|
|
1837
1839
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXPLayoutOrderingConfigService, never>;
|
|
1838
1840
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<AXPLayoutOrderingConfigService>;
|
|
@@ -243,6 +243,11 @@ declare abstract class AXPDataListWidgetComponent extends AXPValueWidgetComponen
|
|
|
243
243
|
private lastStringDataSourceRef;
|
|
244
244
|
private buildRegistryQueryOptions;
|
|
245
245
|
private rf;
|
|
246
|
+
/**
|
|
247
|
+
* Registry datasources are cached globally; each widget needs its own {@link AXDataSource}
|
|
248
|
+
* instance so per-widget filters (e.g. cascade parent id) do not leak across fields.
|
|
249
|
+
*/
|
|
250
|
+
private isolateRegistryDataSource;
|
|
246
251
|
/** Invalidates cached registry datasource and forces a reload on the next effect run. */
|
|
247
252
|
protected refreshRegistryDataSource(): void;
|
|
248
253
|
protected extractItem(item: unknown): Promise<any>;
|
|
@@ -5,6 +5,7 @@ import * as _angular_core from '@angular/core';
|
|
|
5
5
|
import { OnInit, WritableSignal, InjectionToken, EventEmitter, Signal, AfterViewInit, OnDestroy, ElementRef, ChangeDetectorRef, ComponentRef } from '@angular/core';
|
|
6
6
|
import * as _acorex_platform_contracts from '@acorex/platform/contracts';
|
|
7
7
|
import { AXPWidgetNode, AXPContextChangeEvent, AXPFilterClause, AXPFilterDefinition, AXPValidationRule, AXPAddressMode, AXPAddressLabel, AXPAddressData, AXPFileListItem, AXPIntegrationProviderListItemDto, AXPSafeIntegrationConnectionDto, AXPStatusDefinition, AXPStatusTransition, AXPStatusProvider, AXPMultiLanguageString, AXPActionMenuItem } from '@acorex/platform/contracts';
|
|
8
|
+
import * as _acorex_cdk_common from '@acorex/cdk/common';
|
|
8
9
|
import { AXValueChangedEvent, AXDataSourceFilterOption, AXStyleColorType, AXClickEvent, AXStyleLookType, AXDataSource, AXDirection, AXButtonClickEvent, AXOrientation } from '@acorex/cdk/common';
|
|
9
10
|
import { AXBasePageComponent } from '@acorex/components/page';
|
|
10
11
|
import { AXPDeviceService, AXPTag, AXPExpressionEvaluatorService, AXPDataSourceDefinition } from '@acorex/platform/core';
|
|
@@ -1622,6 +1623,7 @@ declare class AXPSelectBoxWidgetColumnComponent extends AXPColumnWidgetComponent
|
|
|
1622
1623
|
|
|
1623
1624
|
declare class AXPSelectBoxWidgetEditComponent extends AXPDataListWidgetComponent {
|
|
1624
1625
|
#private;
|
|
1626
|
+
private static readonly emptyDataSource;
|
|
1625
1627
|
private selectBox;
|
|
1626
1628
|
protected widgetsConfigs: StrategyConfig;
|
|
1627
1629
|
private readonly filterOperatorMiddleware;
|
|
@@ -1630,6 +1632,9 @@ declare class AXPSelectBoxWidgetEditComponent extends AXPDataListWidgetComponent
|
|
|
1630
1632
|
private readonly destroyRef;
|
|
1631
1633
|
/** Toggled to force ax-select-box to re-render after locale / language changes. */
|
|
1632
1634
|
protected readonly selectBoxKey: _angular_core.WritableSignal<boolean>;
|
|
1635
|
+
/** Registry list query runs only after the user interacts (not on form mount). */
|
|
1636
|
+
private readonly listLoadEnabled;
|
|
1637
|
+
private readonly isLazyRegistrySelect;
|
|
1633
1638
|
private readonly selectBoxLocaleChanged;
|
|
1634
1639
|
/**
|
|
1635
1640
|
* Expose configuration similar to lookup widget. Can be:
|
|
@@ -1650,6 +1655,19 @@ declare class AXPSelectBoxWidgetEditComponent extends AXPDataListWidgetComponent
|
|
|
1650
1655
|
protected isItemTruncated: _angular_core.Signal<boolean>;
|
|
1651
1656
|
protected filter: _angular_core.Signal<AXDataSourceFilterOption>;
|
|
1652
1657
|
protected filterMode: _angular_core.Signal<boolean>;
|
|
1658
|
+
/**
|
|
1659
|
+
* True when a cascade/parent filter is configured but required values are still empty
|
|
1660
|
+
* (e.g. state select before country is chosen).
|
|
1661
|
+
*/
|
|
1662
|
+
protected hasPendingCascadeFilter: _angular_core.Signal<boolean>;
|
|
1663
|
+
/**
|
|
1664
|
+
* Registry-backed selects defer list loading until the user opens the dropdown.
|
|
1665
|
+
* Existing values are still resolved via `byKey` in the base widget.
|
|
1666
|
+
*/
|
|
1667
|
+
protected shouldDeferListLoad: _angular_core.Signal<boolean>;
|
|
1668
|
+
/** Only swap datasource when cascade parent is missing; defer load via patched `load` instead. */
|
|
1669
|
+
protected effectiveDataSource: _angular_core.Signal<_acorex_cdk_common.AXDataSource<any>>;
|
|
1670
|
+
protected isSelectBoxDisabled: _angular_core.Signal<boolean>;
|
|
1653
1671
|
/** For filter mode: display valueField from object to avoid [object Object] when value is stored as full item */
|
|
1654
1672
|
protected selectFilterDisplayValue: _angular_core.Signal<any>;
|
|
1655
1673
|
/**
|
|
@@ -1681,7 +1699,18 @@ declare class AXPSelectBoxWidgetEditComponent extends AXPDataListWidgetComponent
|
|
|
1681
1699
|
*/
|
|
1682
1700
|
private syncExposePathsToSavedBaseline;
|
|
1683
1701
|
protected handleSearchValueChange(e: AXValueChangedEvent): void;
|
|
1702
|
+
/** Normalized, middleware-ready filter for the current widget options (or null). */
|
|
1703
|
+
private resolveActiveWidgetFilter;
|
|
1704
|
+
/**
|
|
1705
|
+
* Patches registry `load` to defer list fetch until the user opens the dropdown.
|
|
1706
|
+
* Filtering is handled via {@link #filterEffect} on the datasource (lookup-select pattern).
|
|
1707
|
+
*/
|
|
1708
|
+
private patchRegistryDataSourceLoad;
|
|
1684
1709
|
refresh(): void;
|
|
1710
|
+
/** Push the current widget filter onto the isolated datasource. */
|
|
1711
|
+
private applyActiveFilterToDataSource;
|
|
1712
|
+
/** Allow the patched datasource `load` before the dropdown panel opens. */
|
|
1713
|
+
protected enableListLoad(): void;
|
|
1685
1714
|
/** Re-mount ax-select-box so translate pipe picks up the active locale. */
|
|
1686
1715
|
private rerenderSelectBox;
|
|
1687
1716
|
clear(): void;
|
|
@@ -1695,6 +1724,11 @@ declare class AXPSelectBoxWidgetEditComponent extends AXPDataListWidgetComponent
|
|
|
1695
1724
|
* Return a single value for single-select, or the full list for multi-select
|
|
1696
1725
|
*/
|
|
1697
1726
|
private singleOrMultiple;
|
|
1727
|
+
/**
|
|
1728
|
+
* Normalizes filter payloads for datasource queries: unwraps filter-mode values and
|
|
1729
|
+
* reduces selected row objects to scalar keys (default `id`).
|
|
1730
|
+
*/
|
|
1731
|
+
private normalizeDataSourceFilter;
|
|
1698
1732
|
/**
|
|
1699
1733
|
* In filterMode, widget context stores values as `{ value, operation, displayText }`.
|
|
1700
1734
|
* DataSource filtering expects the raw scalar/array value, so unwrap `value.value`.
|