@acorex-platform/framework-client 0.0.37 → 0.0.46
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-framework-client-auth.mjs +212 -44
- package/fesm2022/acorex-platform-framework-client-auth.mjs.map +1 -1
- package/fesm2022/{acorex-platform-framework-client-common-common-settings.provider-CzBr0cRi.mjs → acorex-platform-framework-client-common-common-settings.provider-ChU2tvyt.mjs} +31 -1
- package/fesm2022/acorex-platform-framework-client-common-common-settings.provider-ChU2tvyt.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-common.mjs +848 -76
- package/fesm2022/acorex-platform-framework-client-common.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-core.mjs +273 -96
- package/fesm2022/acorex-platform-framework-client-core.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-builder.mjs +292 -11
- package/fesm2022/acorex-platform-framework-client-layout-builder.mjs.map +1 -1
- package/fesm2022/{acorex-platform-framework-client-layout-components-binding-expression-editor-popup.component-Bp2cNCPO.mjs → acorex-platform-framework-client-layout-components-binding-expression-editor-popup.component-BqPaHKPM.mjs} +10 -6
- package/fesm2022/acorex-platform-framework-client-layout-components-binding-expression-editor-popup.component-BqPaHKPM.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-components-property-viewer-inline-code-editor.component-CcpUTEVQ.mjs +66 -0
- package/fesm2022/acorex-platform-framework-client-layout-components-property-viewer-inline-code-editor.component-CcpUTEVQ.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-components-resource-appointment-board.component-DCkpgsFH.mjs +195 -0
- package/fesm2022/acorex-platform-framework-client-layout-components-resource-appointment-board.component-DCkpgsFH.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-components.mjs +3987 -1020
- package/fesm2022/acorex-platform-framework-client-layout-components.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-designer.mjs +1179 -304
- package/fesm2022/acorex-platform-framework-client-layout-designer.mjs.map +1 -1
- package/fesm2022/{acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-C74cBc-K.mjs → acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-Dc_NpBx6.mjs} +1697 -323
- package/fesm2022/acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-Dc_NpBx6.mjs.map +1 -0
- package/fesm2022/{acorex-platform-framework-client-layout-entity-attachments-page.component-B6nG9dIS.mjs → acorex-platform-framework-client-layout-entity-attachments-page.component-Cx-n7ZuA.mjs} +2 -2
- package/fesm2022/{acorex-platform-framework-client-layout-entity-attachments-page.component-B6nG9dIS.mjs.map → acorex-platform-framework-client-layout-entity-attachments-page.component-Cx-n7ZuA.mjs.map} +1 -1
- package/fesm2022/{acorex-platform-framework-client-layout-entity-bulk-entity.command-DLQA_Q2Y.mjs → acorex-platform-framework-client-layout-entity-bulk-entity.command-BONV249y.mjs} +2 -2
- package/fesm2022/{acorex-platform-framework-client-layout-entity-bulk-entity.command-DLQA_Q2Y.mjs.map → acorex-platform-framework-client-layout-entity-bulk-entity.command-BONV249y.mjs.map} +1 -1
- package/fesm2022/{acorex-platform-framework-client-layout-entity-gallery-page.component-B4wC1iqZ.mjs → acorex-platform-framework-client-layout-entity-gallery-page.component-uTG2nFly.mjs} +2 -2
- package/fesm2022/{acorex-platform-framework-client-layout-entity-gallery-page.component-B4wC1iqZ.mjs.map → acorex-platform-framework-client-layout-entity-gallery-page.component-uTG2nFly.mjs.map} +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-entity.mjs +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-views.mjs +3 -3
- package/fesm2022/acorex-platform-framework-client-layout-views.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-widget-core.mjs +3854 -3278
- package/fesm2022/acorex-platform-framework-client-layout-widget-core.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-widgets-acorex-platform-framework-client-layout-widgets-CDpzvn6z.mjs +33191 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-acorex-platform-framework-client-layout-widgets-CDpzvn6z.mjs.map +1 -0
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-button-widget-designer.component-BDOdcoyN.mjs → acorex-platform-framework-client-layout-widgets-button-widget-designer.component-BkrPu1wO.mjs} +8 -5
- package/fesm2022/acorex-platform-framework-client-layout-widgets-button-widget-designer.component-BkrPu1wO.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-value.util-Cb7R1qLO.mjs +45 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-value.util-Cb7R1qLO.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-column.component-BL621E1r.mjs +68 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-column.component-BL621E1r.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-edit.component-CVsPKhNl.mjs +88 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-edit.component-CVsPKhNl.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-view.component-BEq4O4al.mjs +71 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-code-editor-widget-view.component-BEq4O4al.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-condition-builder-edit-popup.component-WpiEHusZ.mjs +81 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-condition-builder-edit-popup.component-WpiEHusZ.mjs.map +1 -0
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-page-widget-designer.component-WzIiwnGC.mjs → acorex-platform-framework-client-layout-widgets-page-widget-designer.component-Cadl6guA.mjs} +41 -23
- package/fesm2022/acorex-platform-framework-client-layout-widgets-page-widget-designer.component-Cadl6guA.mjs.map +1 -0
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-repeater-widget-column.component-4mX8aYzA.mjs → acorex-platform-framework-client-layout-widgets-repeater-widget-column.component-Cw3NhWL8.mjs} +3 -3
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-repeater-widget-column.component-4mX8aYzA.mjs.map → acorex-platform-framework-client-layout-widgets-repeater-widget-column.component-Cw3NhWL8.mjs.map} +1 -1
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-column.component-Clb27Loe.mjs +71 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-column.component-Clb27Loe.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-edit.component-l7q8A-D3.mjs +111 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-edit.component-l7q8A-D3.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-view.component-Cc1AH09b.mjs +77 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-scheduler-picker-widget-view.component-Cc1AH09b.mjs.map +1 -0
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-tabular-data-edit-popup.component-TWxthl21.mjs → acorex-platform-framework-client-layout-widgets-tabular-data-edit-popup.component-BCLxS3rS.mjs} +3 -3
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-tabular-data-edit-popup.component-TWxthl21.mjs.map → acorex-platform-framework-client-layout-widgets-tabular-data-edit-popup.component-BCLxS3rS.mjs.map} +1 -1
- package/fesm2022/{acorex-platform-framework-client-layout-widgets-text-block-widget-designer.component-D6HFPmGC.mjs → acorex-platform-framework-client-layout-widgets-text-block-widget-designer.component-BEa-vD6O.mjs} +21 -8
- package/fesm2022/acorex-platform-framework-client-layout-widgets-text-block-widget-designer.component-BEa-vD6O.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-trigger-expression-editor-popup.component-C2PGoC7r.mjs +124 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-trigger-expression-editor-popup.component-C2PGoC7r.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-triggers-widget-editor.component-DDDoPoQa.mjs +345 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets-triggers-widget-editor.component-DDDoPoQa.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-layout-widgets.mjs +1 -31985
- package/fesm2022/acorex-platform-framework-client-layout-widgets.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-realtime.mjs +2 -1
- package/fesm2022/acorex-platform-framework-client-realtime.mjs.map +1 -1
- package/fesm2022/acorex-platform-framework-client-runtime.mjs +47 -3
- package/fesm2022/acorex-platform-framework-client-runtime.mjs.map +1 -1
- package/fesm2022/{acorex-platform-framework-client-themes-default-entity-master-single-view.component-DBUwSzvg.mjs → acorex-platform-framework-client-themes-default-entity-master-single-view.component-CHLsBvBE.mjs} +2 -2
- package/fesm2022/{acorex-platform-framework-client-themes-default-entity-master-single-view.component-DBUwSzvg.mjs.map → acorex-platform-framework-client-themes-default-entity-master-single-view.component-CHLsBvBE.mjs.map} +1 -1
- package/fesm2022/acorex-platform-framework-client-themes-default.mjs +373 -70
- package/fesm2022/acorex-platform-framework-client-themes-default.mjs.map +1 -1
- package/fesm2022/{acorex-platform-framework-client-themes-shared-settings.provider-CpsAIsxj.mjs → acorex-platform-framework-client-themes-shared-settings.provider-DIkjSTU7.mjs} +102 -1
- package/fesm2022/acorex-platform-framework-client-themes-shared-settings.provider-DIkjSTU7.mjs.map +1 -0
- package/fesm2022/acorex-platform-framework-client-themes-shared.mjs +174 -22
- package/fesm2022/acorex-platform-framework-client-themes-shared.mjs.map +1 -1
- package/package.json +2 -2
- package/realtime/README.md +1 -1
- package/types/acorex-platform-framework-client-auth.d.ts +18 -1
- package/types/acorex-platform-framework-client-common.d.ts +209 -8
- package/types/acorex-platform-framework-client-core.d.ts +166 -121
- package/types/acorex-platform-framework-client-layout-builder.d.ts +29 -0
- package/types/acorex-platform-framework-client-layout-components.d.ts +699 -146
- package/types/acorex-platform-framework-client-layout-designer.d.ts +192 -14
- package/types/acorex-platform-framework-client-layout-entity.d.ts +159 -91
- package/types/acorex-platform-framework-client-layout-views.d.ts +16 -0
- package/types/acorex-platform-framework-client-layout-widget-core.d.ts +140 -37
- package/types/acorex-platform-framework-client-layout-widgets.d.ts +235 -117
- package/types/acorex-platform-framework-client-realtime.d.ts +16 -3
- package/types/acorex-platform-framework-client-runtime.d.ts +8 -0
- package/types/acorex-platform-framework-client-themes-default.d.ts +62 -11
- package/types/acorex-platform-framework-client-themes-shared.d.ts +25 -2
- package/fesm2022/acorex-platform-framework-client-common-common-settings.provider-CzBr0cRi.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-components-binding-expression-editor-popup.component-Bp2cNCPO.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-components-file-provider-picker.popup.component-BtLEUWAA.mjs +0 -77
- package/fesm2022/acorex-platform-framework-client-layout-components-file-provider-picker.popup.component-BtLEUWAA.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-C74cBc-K.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-widgets-button-widget-designer.component-BDOdcoyN.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-widgets-page-widget-designer.component-WzIiwnGC.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-layout-widgets-text-block-widget-designer.component-D6HFPmGC.mjs.map +0 -1
- package/fesm2022/acorex-platform-framework-client-themes-shared-settings.provider-CpsAIsxj.mjs.map +0 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { mergeForeignKeyFieldIntoCreateActions, collectNestedCreateHiddenProperties, AXPEntityCommandScope, isCardFieldBadgeDisplay, resolveCardFieldBadgeColor, resolveEntityCardAvatarPath, isEntityCardQrField, collectLeftoverCardMoreFieldNames, parseDottedFieldPath, createEntityMasterStylingScope, normalizeEntityMasterStylingClass, resolveEntityMasterStyling, resolveEntityMasterFieldExpression, resolveEntityCardIdentityKind, resolveEntityCardUserId, ENTITY_CARD_LABELED_PREVIEW_MAX, resolveEntityCardLayout, buildDefaultEntityCardLayout, resolveEntityListFilterContextField, resolveEntityListFilterQueryField, resolveEnabledMasterListLayouts, resolveDefaultMasterListLayout, isEntityMasterListCardHost, normalizeEntityMasterListLayoutType, getEntityInfo, collectEntityListSortableFields, collectEntityListFilterDefinitions, collectEntityCardUserIdQueryFields, buildEntityQueryFields, AXPEntityQueryType, ENTITY_ROW_POPUP_TITLE_OPTION, resolveEnabledPageListLayouts, buildPageListWidgetName, normalizeEntityDisplayTemplate, sanitizeResolvedEntityDisplayTitle, isUnresolvedEntityDisplayTemplate, resolveLookupWidgetCreateOptions, promoteLegacyEntityCardLayout, buildEntitySearchTitleContext } from '@acorex-platform/framework-shared/entity';
|
|
2
|
-
import { resolveEntityActionCommandInput, defineCommand, AXP_COMMAND_DEFINITION_CATEGORY_ENTITY, analyzeBulkCommandFailures, ENTITY_DELETE_DEFAULT, ENTITY_GET_BY_ID_DEFAULT, ENTITY_QUERY_DEFAULT, ENTITY_INSERT_DEFAULT, ENTITY_UPDATE_DEFAULT, DOMAIN_GET_ENTITY_LAYOUT_DEFAULT, DOMAIN_LIST_ENTITY_LAYOUTS_DEFAULT, resolveEntityNameFromRuntimeKey } from '@acorex-platform/framework-shared/runtime';
|
|
1
|
+
import { isEntityColumnBand, mergeForeignKeyFieldIntoCreateActions, collectNestedCreateHiddenProperties, relatedEntityListViewWidgetOptions, AXPEntityCommandScope, isCardFieldBadgeDisplay, resolveCardFieldBadgeColor, resolveEntityCardAvatarPath, isEntityCardQrField, collectLeftoverCardMoreFieldNames, parseDottedFieldPath, AXP_ENTITY_LIST_RECORD_STYLING_TARGET, isCompleteEntityListStylingCondition, createEntityMasterStylingScope, normalizeEntityMasterStylingClass, resolveEntityMasterStyling, resolveEntityMasterFieldExpression, resolveEntityCardIdentityKind, resolveEntityCardUserId, ENTITY_CARD_LABELED_PREVIEW_MAX, resolveEntityCardLayout, buildDefaultEntityCardLayout, resolveEntityListFilterContextField, resolveEntityListFilterQueryField, resolveEnabledMasterListLayouts, resolveDefaultMasterListLayout, isEntityMasterListCardHost, normalizeEntityMasterListLayoutType, getEntityInfo, normalizeEntityListUserStylingRules, mergeQueryViewAndUserFilters, mergeDefinitionAndCustomQueryViews, isQueryViewDirty, isCustomQueryView, collectEntityListSortPresets, flattenEntityTableColumns, createCustomQueryViewName, removePersistedCustomQueryView, readPersistedCustomQueryViews, upsertPersistedCustomQueryView, snapshotCustomQueryView, isQueryViewColumnVisible, collectEntityListSortableFields, collectEntityListFilterDefinitions, withQueryViewFilterVisibility, queryViewConditionsToFilterQueries, collectEntityCardUserIdQueryFields, buildEntityQueryFields, normalizeAXPQueryViewColumns, findEntityTableColumnInTree, AXPEntityQueryType, ENTITY_ROW_POPUP_TITLE_OPTION, resolveEnabledPageListLayouts, resolveRelatedEntityListViews, buildPageListWidgetName, applyQueryViewToColumnQueries, normalizeEntityDisplayTemplate, sanitizeResolvedEntityDisplayTitle, isUnresolvedEntityDisplayTemplate, resolveLookupWidgetCreateOptions, promoteLegacyEntityCardLayout, inferEntityListSortPresets, buildEntitySearchTitleContext } from '@acorex-platform/framework-shared/entity';
|
|
2
|
+
import { resolveEntityActionCommandInput, entityActionDataRecord, defineCommand, AXP_COMMAND_DEFINITION_CATEGORY_ENTITY, analyzeBulkCommandFailures, ENTITY_DELETE_DEFAULT, ENTITY_GET_BY_ID_DEFAULT, ENTITY_QUERY_DEFAULT, ENTITY_INSERT_DEFAULT, ENTITY_UPDATE_DEFAULT, DOMAIN_GET_ENTITY_LAYOUT_DEFAULT, DOMAIN_LIST_ENTITY_LAYOUTS_DEFAULT, resolveEntityNameFromRuntimeKey } from '@acorex-platform/framework-shared/runtime';
|
|
3
3
|
import { AXToastService } from '@acorex/components/toast';
|
|
4
4
|
import * as i3$1 from '@acorex/core/translation';
|
|
5
5
|
import { AXTranslationService, AXTranslationModule, resolveMultiLanguageString, translateSync } from '@acorex/core/translation';
|
|
6
6
|
import * as i4$3 from '@acorex-platform/framework-client/common';
|
|
7
|
-
import { AXPNotFoundError, AXPSettingsService, AXPCommonSettings, resolveEntityCreateListBehavior, platformErrorI18nKey, extractRequestErrorInfo, axpNavigateAppPath, AXPFileTypeProviderService, AXPFileStorageService, resolveFileTypeDisplay, resolveEntityRowDisplayTitle, resolveEntityModifyPopupTitle, commandMessageTextForError, resolveStoredImageDisplayUrl, isStoredImageFileId, AXPFilterOperatorMiddlewareService, AXP_ENTITY_LIST_DISPLAY_MODE_DEFAULT, axpRedirectToNotFound, CONTAINS_OPER, toExecuteCommandFailureResult, AXPLocalEntityEngine, AXPLocalEntityRealtimeBridge, AXP_LOCAL_ENTITY_DEFAULT_MAX_ITEMS, resolveSearchableText, evaluateEntityDisplayTemplate, AXPCleanNestedFilters, axpIsEntityRecordNotFound, coerceAXPSettingRawValueByKind, AXPDefaultMultiLanguageConfigService, withDefaultMultiLanguageOnWidgetNodeTree, axpIsEntityListPath, axpIsEntityDetailsPath, axpParseEntityListRoute, axpParseEntityDetailsRoute, axpSaveEntityListReturnUrl, AXP_NOT_FOUND_ROUTE, AXP_PROTECTED_ROUTE_GUARDS, AXP_SEARCH_DEFINITION_PROVIDER, AXP_SEARCH_DEFINITION_LAZY_RESOLVER } from '@acorex-platform/framework-client/common';
|
|
8
|
-
import { AXPWidgetsCatalog, runtimeCommandPayloadData, createRandomUuid, AXPRequestError, runtimeQueryPayloadData, runtimeQueryCollectionData, runtimeQueryFailure, runtimeQuerySuccessObject, runtimeCommandFailure, runtimeCommandSuccessObject, resolveActionLook, AXPWidgetsList, AXPSystemActionType, AXPPlatformScope, AXP_QUERY_QUICK_SEARCH_FIELD, extractValue, setSmart, getChangedPaths, isSelectionValueEqual, runtimeQuerySuccessCollection } from '@acorex-platform/framework-shared/core';
|
|
9
|
-
import { AXPDeviceService, AXPExpressionEvaluatorService, AXPEntityBroadcastService, AXPHookService, AXPDebugService, AXPDataGenerator, AXPContextEvalFactory,
|
|
7
|
+
import { AXPNotFoundError, AXPMenuRouteAccessService, AXPSettingsService, AXPCommonSettings, resolveEntityCreateListBehavior, platformErrorI18nKey, extractRequestErrorInfo, axpNavigateAppPath, AXPFileTypeProviderService, AXPFileStorageService, resolveFileTypeDisplay, resolveEntityRowDisplayTitle, resolveEntityModifyPopupTitle, commandMessageTextForError, resolveStoredImageDisplayUrl, isStoredImageFileId, AXPFilterOperatorMiddlewareService, AXP_ENTITY_LIST_DISPLAY_MODE_DEFAULT, ENTITY_LIST_DEFAULT_INSTANCE_ID, axpNormalizeEntityListInstanceId, axpGetEntityListInstanceIdFromParamMap, axpRedirectToNotFound, CONTAINS_OPER, toExecuteCommandFailureResult, AXPLocalEntityEngine, AXPLocalEntityRealtimeBridge, AXP_LOCAL_ENTITY_DEFAULT_MAX_ITEMS, resolveSearchableText, evaluateEntityDisplayTemplate, AXPCleanNestedFilters, axpIsEntityRecordNotFound, coerceAXPSettingRawValueByKind, AXPDefaultMultiLanguageConfigService, withDefaultMultiLanguageOnWidgetNodeTree, axpIsEntityListPath, axpIsEntityDetailsPath, axpParseEntityListRoute, axpParseEntityDetailsRoute, axpSaveEntityListReturnUrl, AXPMenuRouteGuard, AXP_NOT_FOUND_ROUTE, AXP_PROTECTED_ROUTE_GUARDS, AXP_SEARCH_DEFINITION_PROVIDER, AXP_SEARCH_DEFINITION_LAZY_RESOLVER } from '@acorex-platform/framework-client/common';
|
|
8
|
+
import { AXPWidgetsCatalog, runtimeCommandPayloadData, createRandomUuid, AXPRequestError, runtimeQueryPayloadData, runtimeQueryCollectionData, runtimeQueryFailure, runtimeQuerySuccessObject, runtimeCommandFailure, runtimeCommandSuccessObject, resolveActionLook, listThemeSurfaceClasses, parseRuntimeHexSurface, AXP_THEME_SURFACE_STYLES, AXPWidgetsList, AXPSystemActionType, AXPPlatformScope, flattenQueryFilterUserGroups, AXP_QUERY_QUICK_SEARCH_FIELD, wrapQueryFilterRoot, isPersistableFilterQuery, isCompleteFilterCondition, resolveFilterQueryIdentityField, extractValue, setSmart, getChangedPaths, isSelectionValueEqual, runtimeQuerySuccessCollection } from '@acorex-platform/framework-shared/core';
|
|
9
|
+
import { AXPDeviceService, AXPExpressionEvaluatorService, AXPEntityBroadcastService, AXPHookService, AXPDebugService, AXPDataGenerator, AXPContextEvalFactory, ensureRuntimeSurfaceClass, applyFilterArray, createCommandExpressionScope, toExpressionRecord, AXPDistributedEventListenerService, applySortArray, AXHighlightService, AXPColumnWidthService, objectKeyValueTransforms, setupPopupFooterKeyboardShortcuts, AXPContextStore, AXPModuleManifestRegistry, provideAppStartUpTask, AXP_APP_STARTUP_PRIORITY, defaultColumnWidthProvider, AXP_COLUMN_WIDTH_PROVIDER } from '@acorex-platform/framework-client/core';
|
|
10
10
|
import * as i0 from '@angular/core';
|
|
11
11
|
import { InjectionToken, inject, Injector, runInInjectionContext, Injectable, signal, output, input, computed, effect, ChangeDetectionStrategy, Component, viewChild, untracked, HostBinding, model, ViewEncapsulation, ElementRef, EnvironmentInjector, NgModule, ChangeDetectorRef, Input, afterNextRender, viewChildren, linkedSignal, DestroyRef, makeEnvironmentProviders } from '@angular/core';
|
|
12
12
|
import { cloneDeep, merge, get, isNil, set, isArray, isString, castArray, has, isPlainObject, orderBy, defaultTo, isEmpty, isEqual, isObjectLike } from 'lodash-es';
|
|
13
|
-
import { Subject, filter, takeUntil, fromEvent, auditTime, merge as merge$1 } from 'rxjs';
|
|
13
|
+
import { Subject, filter, takeUntil, map, distinctUntilChanged, fromEvent, auditTime, merge as merge$1 } from 'rxjs';
|
|
14
14
|
import { AXPLayoutBuilderService, LayoutBuilderModule } from '@acorex-platform/framework-client/layout/builder';
|
|
15
15
|
import { AXPSessionService } from '@acorex-platform/framework-client/auth';
|
|
16
16
|
import { Router, NavigationStart, ActivatedRoute, ROUTES } from '@angular/router';
|
|
@@ -44,7 +44,7 @@ import * as i1$5 from '@angular/forms';
|
|
|
44
44
|
import { FormsModule } from '@angular/forms';
|
|
45
45
|
import { AXUploaderModule } from '@acorex/components/uploader';
|
|
46
46
|
import { createStringProperty, createBooleanProperty, createNumberProperty, AXPWidgetGroupEnum, AXPPageStatus, AXPWidgetStatus, createSelectProperty } from '@acorex-platform/framework-shared/widget-core';
|
|
47
|
-
import { AXP_NAME_PROPERTY, AXP_DATA_PATH_PROPERTY, AXP_ALLOW_MULTIPLE_PROPERTY, AXP_DOWNLOADABLE_PROPERTY, AXP_READONLY_PROPERTY, AXP_DESCRIPTION_PROPERTY, AXP_BEHAVIOR_PROPERTY_GROUP, AXP_DISABLED_PROPERTY, AXP_ALLOW_CLEAR_PROPERTY, AXP_DATA_PROPERTY_GROUP, AXP_PLACEHOLDER_PROPERTY, AXPProviderSelectWidgetEditBase, AXP_ROW_EXPR_PREFIX, AXP_REPEATER_ENTITY_BY_KEY_LOOKUP } from '@acorex-platform/framework-client/layout/widgets';
|
|
47
|
+
import { AXP_NAME_PROPERTY, AXP_DATA_PATH_PROPERTY, AXP_ALLOW_MULTIPLE_PROPERTY, AXP_DOWNLOADABLE_PROPERTY, AXP_READONLY_PROPERTY, AXP_DESCRIPTION_PROPERTY, AXP_BEHAVIOR_PROPERTY_GROUP, AXP_DISABLED_PROPERTY, AXP_ALLOW_CLEAR_PROPERTY, AXP_DATA_PROPERTY_GROUP, AXP_PLACEHOLDER_PROPERTY, AXPProviderSelectWidgetEditBase, isDataListColumnBand, AXP_ROW_EXPR_PREFIX, applyLeafVisibilityToDataListColumnTree, AXP_REPEATER_ENTITY_BY_KEY_LOOKUP } from '@acorex-platform/framework-client/layout/widgets';
|
|
48
48
|
import { AXPopupService } from '@acorex/components/popup';
|
|
49
49
|
import * as i1$4 from '@acorex/components/skeleton';
|
|
50
50
|
import { AXSkeletonModule } from '@acorex/components/skeleton';
|
|
@@ -677,38 +677,40 @@ class AXPRelatedColumnEnrichmentService {
|
|
|
677
677
|
if (!columns?.length) {
|
|
678
678
|
return entity;
|
|
679
679
|
}
|
|
680
|
-
const enrichedColumns =
|
|
681
|
-
for (const column of columns) {
|
|
682
|
-
let enriched = { ...column };
|
|
683
|
-
// Derive dataPath for FK columns when missing
|
|
684
|
-
if (!enriched.options?.dataPath) {
|
|
685
|
-
const derivedDataPath = this.deriveDataPathForFkColumn(entity, column);
|
|
686
|
-
if (derivedDataPath) {
|
|
687
|
-
enriched = {
|
|
688
|
-
...enriched,
|
|
689
|
-
options: { ...enriched.options, dataPath: derivedDataPath },
|
|
690
|
-
};
|
|
691
|
-
}
|
|
692
|
-
}
|
|
693
|
-
// Enrich title/showAs for dotted path columns
|
|
694
|
-
const needsMetadataEnrichment = column.name.includes('.') && (!enriched.title || !enriched.showAs);
|
|
695
|
-
if (needsMetadataEnrichment) {
|
|
696
|
-
const metadata = await this.metadataResolver.resolve(entity, column.name);
|
|
697
|
-
if (metadata) {
|
|
698
|
-
enriched = {
|
|
699
|
-
...enriched,
|
|
700
|
-
title: enriched.title ?? metadata.title,
|
|
701
|
-
showAs: enriched.showAs ?? metadata.showAs,
|
|
702
|
-
};
|
|
703
|
-
}
|
|
704
|
-
}
|
|
705
|
-
enrichedColumns.push(enriched);
|
|
706
|
-
}
|
|
680
|
+
const enrichedColumns = await Promise.all(columns.map((column) => this.enrichColumnNode(entity, column)));
|
|
707
681
|
return {
|
|
708
682
|
...entity,
|
|
709
683
|
columns: enrichedColumns,
|
|
710
684
|
};
|
|
711
685
|
}
|
|
686
|
+
async enrichColumnNode(entity, column) {
|
|
687
|
+
if (isEntityColumnBand(column)) {
|
|
688
|
+
const children = await Promise.all((column.children ?? []).map((child) => this.enrichColumnNode(entity, child)));
|
|
689
|
+
return { ...column, children };
|
|
690
|
+
}
|
|
691
|
+
let enriched = { ...column };
|
|
692
|
+
if (!enriched.options?.dataPath) {
|
|
693
|
+
const derivedDataPath = this.deriveDataPathForFkColumn(entity, column);
|
|
694
|
+
if (derivedDataPath) {
|
|
695
|
+
enriched = {
|
|
696
|
+
...enriched,
|
|
697
|
+
options: { ...enriched.options, dataPath: derivedDataPath },
|
|
698
|
+
};
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
const needsMetadataEnrichment = column.name.includes('.') && (!enriched.title || !enriched.showAs);
|
|
702
|
+
if (needsMetadataEnrichment) {
|
|
703
|
+
const metadata = await this.metadataResolver.resolve(entity, column.name);
|
|
704
|
+
if (metadata) {
|
|
705
|
+
enriched = {
|
|
706
|
+
...enriched,
|
|
707
|
+
title: enriched.title ?? metadata.title,
|
|
708
|
+
showAs: enriched.showAs ?? metadata.showAs,
|
|
709
|
+
};
|
|
710
|
+
}
|
|
711
|
+
}
|
|
712
|
+
return enriched;
|
|
713
|
+
}
|
|
712
714
|
/**
|
|
713
715
|
* Derives dataPath for FK columns from lookup property schema.
|
|
714
716
|
* Uses expose.target where source matches textField (default 'title').
|
|
@@ -1768,6 +1770,7 @@ class PropertyFilter {
|
|
|
1768
1770
|
customFilterDefinitions: relatedEntity.customFilterDefinitions,
|
|
1769
1771
|
...(foreignKeyField ? { foreignKeyField } : {}),
|
|
1770
1772
|
...(nestedCreateHiddenProperties?.length ? { nestedCreateHiddenProperties } : {}),
|
|
1773
|
+
...relatedEntityListViewWidgetOptions(relatedEntity),
|
|
1771
1774
|
...(syncRelatedFromRoot && relatedEntity.conditions?.length
|
|
1772
1775
|
? {
|
|
1773
1776
|
relatedFilterConditionSpecs: cloneDeep(relatedEntity.conditions),
|
|
@@ -2389,6 +2392,7 @@ class AXPOpenEntityDetailsCommand {
|
|
|
2389
2392
|
//#region ---- Services & Dependencies ----
|
|
2390
2393
|
this.router = inject(Router);
|
|
2391
2394
|
this.sessionService = inject(AXPSessionService);
|
|
2395
|
+
this.menuRouteAccess = inject(AXPMenuRouteAccessService);
|
|
2392
2396
|
}
|
|
2393
2397
|
//#endregion
|
|
2394
2398
|
//#region ---- Command Execution ----
|
|
@@ -2432,9 +2436,24 @@ class AXPOpenEntityDetailsCommand {
|
|
|
2432
2436
|
},
|
|
2433
2437
|
};
|
|
2434
2438
|
}
|
|
2439
|
+
const commands = ['/', applicationName, 'm', module, 'e', entityName, String(data.id), 'view'];
|
|
2440
|
+
const extras = { queryParams: { page: entityName } };
|
|
2441
|
+
const url = this.router.serializeUrl(this.router.createUrlTree(commands, extras));
|
|
2442
|
+
if (!(await this.menuRouteAccess.canAccessUrl(url))) {
|
|
2443
|
+
return {
|
|
2444
|
+
success: false,
|
|
2445
|
+
message: { text: '@general:errors.codes.FORBIDDEN' },
|
|
2446
|
+
};
|
|
2447
|
+
}
|
|
2435
2448
|
// Explicit segments so IDs containing `/` (and `http:` prefixes) stay one route param.
|
|
2436
2449
|
// Primary page id is the entity name (`main-entity-content-builder`).
|
|
2437
|
-
await this.router.navigate(
|
|
2450
|
+
const navigated = await this.router.navigate(commands, extras);
|
|
2451
|
+
if (!navigated) {
|
|
2452
|
+
return {
|
|
2453
|
+
success: false,
|
|
2454
|
+
message: { text: '@general:errors.codes.FORBIDDEN' },
|
|
2455
|
+
};
|
|
2456
|
+
}
|
|
2438
2457
|
return { success: true, kind: 'object', data: undefined };
|
|
2439
2458
|
}
|
|
2440
2459
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPOpenEntityDetailsCommand, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
@@ -2495,7 +2514,7 @@ class AXPCreateEntityCommand {
|
|
|
2495
2514
|
const processData = options?.process && typeof options.process === 'object'
|
|
2496
2515
|
? options.process.data
|
|
2497
2516
|
: undefined;
|
|
2498
|
-
const createSeed = merge({}, data
|
|
2517
|
+
const createSeed = merge({}, entityActionDataRecord(data) ?? {}, processData && typeof processData === 'object' ? processData : {});
|
|
2499
2518
|
let chain = this.entityForm.entity(`${moduleName}.${entityName}`).create(createSeed);
|
|
2500
2519
|
chain.actions((actions) => {
|
|
2501
2520
|
actions
|
|
@@ -2678,7 +2697,7 @@ const axpCreateEntityCommandDefinition = defineCommand({
|
|
|
2678
2697
|
{
|
|
2679
2698
|
name: 'data',
|
|
2680
2699
|
title: 'Seed data',
|
|
2681
|
-
description: 'Optional create form seed object.',
|
|
2700
|
+
description: 'Optional create form seed as a JSON object (not a string). Include resolved lookup ids and dates.',
|
|
2682
2701
|
interface: { name: 'json' },
|
|
2683
2702
|
},
|
|
2684
2703
|
{
|
|
@@ -2695,18 +2714,48 @@ const axpCreateEntityCommandDefinition = defineCommand({
|
|
|
2695
2714
|
},
|
|
2696
2715
|
capabilities: ['ai'],
|
|
2697
2716
|
ai: {
|
|
2698
|
-
shortDescription: 'Opens create dialog with pre-filled data; execution waits until the user submits or cancels
|
|
2717
|
+
shortDescription: 'Opens create dialog with pre-filled data; execution waits until the user submits or cancels.',
|
|
2718
|
+
instruction: 'Open the native create form when any ListRegisteredEntities property with required true is still empty — including simple text such as title or postal code. Do not ask those missing fields in chat; open Entity:Create with collected data as a JSON object (never a string). Include every slot you already have: lookup FK ids you Query\'d and dates. Leave empty only fields you could not resolve. Do not call Entity:Insert:Default while a required field is missing. Do not Insert a row this conversation already created (Last record).',
|
|
2699
2719
|
usage: {
|
|
2700
2720
|
whenToUse: [
|
|
2701
|
-
'Adding a row when the user should review or
|
|
2721
|
+
'Adding a row when the user should review or fill required values before save.',
|
|
2722
|
+
'Any required field from ListRegisteredEntities is still empty — especially select or lookup.',
|
|
2702
2723
|
],
|
|
2703
2724
|
avoidWhen: [
|
|
2704
|
-
'
|
|
2725
|
+
'Every required property already has a value — use Entity:Insert:Default.',
|
|
2705
2726
|
],
|
|
2706
|
-
followUpTools: ['PlatformManagement:ListRegisteredEntities', '
|
|
2727
|
+
followUpTools: ['PlatformManagement:ListRegisteredEntities', 'Entity:Query:Default'],
|
|
2707
2728
|
},
|
|
2708
2729
|
tags: ['entity', 'create', 'form', 'dialog', 'human-in-the-loop', 'mock', 'entity-storage', 'wait-user'],
|
|
2730
|
+
toolParametersSchema: {
|
|
2731
|
+
type: 'object',
|
|
2732
|
+
properties: {
|
|
2733
|
+
data: {
|
|
2734
|
+
type: 'object',
|
|
2735
|
+
additionalProperties: true,
|
|
2736
|
+
description: 'Create-form seed as a JSON object, not a string. Include resolved lookup ids and dates. Omit only fields still unknown.',
|
|
2737
|
+
},
|
|
2738
|
+
},
|
|
2739
|
+
required: ['entity'],
|
|
2740
|
+
},
|
|
2709
2741
|
toolInputDefaults: { ...axpCreateEntityAiToolInputDefaults },
|
|
2742
|
+
contextBindings: [
|
|
2743
|
+
{
|
|
2744
|
+
slot: 'active-entity',
|
|
2745
|
+
map: { entity: '$input.entity' },
|
|
2746
|
+
text: 'Active entity: {{entity}}',
|
|
2747
|
+
},
|
|
2748
|
+
{
|
|
2749
|
+
slot: 'last-record',
|
|
2750
|
+
map: { entity: '$input.entity', id: 'id' },
|
|
2751
|
+
text: 'Last record {{entity}} id={{id}}',
|
|
2752
|
+
},
|
|
2753
|
+
{
|
|
2754
|
+
slot: 'last-record',
|
|
2755
|
+
map: { entity: '$input.entity', id: 'item.id' },
|
|
2756
|
+
text: 'Last record {{entity}} id={{id}}',
|
|
2757
|
+
},
|
|
2758
|
+
],
|
|
2710
2759
|
},
|
|
2711
2760
|
categories: [AXP_COMMAND_DEFINITION_CATEGORY_ENTITY],
|
|
2712
2761
|
});
|
|
@@ -3135,6 +3184,33 @@ const axpDeleteEntityCommandDefinition = defineCommand({
|
|
|
3135
3184
|
},
|
|
3136
3185
|
ai: {
|
|
3137
3186
|
tags: ['entity', 'delete', 'crud'],
|
|
3187
|
+
contextBindings: [
|
|
3188
|
+
{
|
|
3189
|
+
slot: 'active-entity',
|
|
3190
|
+
map: { entity: '$input.entity' },
|
|
3191
|
+
text: 'Active entity: {{entity}}',
|
|
3192
|
+
},
|
|
3193
|
+
{
|
|
3194
|
+
slot: 'last-deleted',
|
|
3195
|
+
map: { entity: '$input.entity', id: '$input.data' },
|
|
3196
|
+
text: 'Last deleted {{entity}} id={{id}}',
|
|
3197
|
+
},
|
|
3198
|
+
{
|
|
3199
|
+
slot: 'last-deleted',
|
|
3200
|
+
map: { entity: '$input.entity', id: '$input.data.id' },
|
|
3201
|
+
text: 'Last deleted {{entity}} id={{id}}',
|
|
3202
|
+
},
|
|
3203
|
+
{
|
|
3204
|
+
slot: 'last-record',
|
|
3205
|
+
map: { entity: '$input.entity', id: '$input.data' },
|
|
3206
|
+
text: 'Last record {{entity}} id={{id}}',
|
|
3207
|
+
},
|
|
3208
|
+
{
|
|
3209
|
+
slot: 'last-record',
|
|
3210
|
+
map: { entity: '$input.entity', id: '$input.data.id' },
|
|
3211
|
+
text: 'Last record {{entity}} id={{id}}',
|
|
3212
|
+
},
|
|
3213
|
+
],
|
|
3138
3214
|
},
|
|
3139
3215
|
categories: [AXP_COMMAND_DEFINITION_CATEGORY_ENTITY],
|
|
3140
3216
|
});
|
|
@@ -4878,7 +4954,7 @@ class AXPFileUploaderWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
4878
4954
|
return false;
|
|
4879
4955
|
}
|
|
4880
4956
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPFileUploaderWidgetColumnComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
4881
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPFileUploaderWidgetColumnComponent, isStandalone: true, selector: "axp-file-uploader-widget-column", inputs: { rawValue: "rawValue", rowData: "rowData" }, viewQueries: [{ propertyName: "fileListTrigger", first: true, predicate: ["fileListTrigger"], descendants: true, isSignal: true }, { propertyName: "fileListPopover", first: true, predicate: ["fileListPopover"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (fileCount() > 0) {\n <span\n class=\"cursor-pointer text-primary underline\"\n (click)=\"openFileListPopover(); $event.stopPropagation()\"\n #fileListTrigger\n >\n {{\n '@general:widgets.file-uploader.column.files-count'\n | translate: { params: { count: fileCount() } }\n | async\n }}\n </span>\n} @else if (showAttachmentsLink()) {\n <span\n class=\"cursor-pointer text-primary underline\"\n (click)=\"openFileListPopover(); $event.stopPropagation()\"\n #fileListTrigger\n >\n {{ '@general:widgets.file-uploader.attachments.title' | translate | async }}\n </span>\n} @else {\n <span class=\"text-muted\">---</span>\n}\n\n<ax-popover [openOn]=\"'manual'\" #fileListPopover (openChange)=\"onPopoverOpenChange($event)\">\n <div class=\"lightest-surface dark:dark-surface min-w-[17.5rem] max-w-[26rem] overflow-hidden\">\n <div class=\"border-b border-surface px-4 py-3\">\n <h3 class=\"m-0 text-sm font-semibold leading-normal text-on-lightest-surface\">\n {{ popoverTitle() | translate | async }}\n </h3>\n </div>\n <div class=\"max-h-64 overflow-y-auto px-3 py-3\" style=\"max-height: max(30dvh, 12rem)\">\n @if (loadStatus() === 'loading') {\n <div class=\"flex min-h-[120px] items-center justify-center\">\n <ax-loading></ax-loading>\n </div>\n } @else if (loadStatus() === 'error') {\n <div class=\"text-danger text-sm\">{{ loadError() }}</div>\n } @else if (popoverFiles().length === 0) {\n <p class=\"axp-file-uploader-column-popover__empty\">\n {{ '@general:widgets.file-uploader.empty-state.title' | translate | async }}\n </p>\n } @else {\n <axp-file-list\n [files]=\"popoverFiles()\"\n look=\"links\"\n linksLayout=\"menu\"\n [showLabel]=\"false\"\n [readonly]=\"true\"\n />\n }\n </div>\n </div>\n</ax-popover>\n", styles: ["@layer properties;.axp-file-uploader-column-popover__empty{margin:0;padding-block:calc(var(--spacing, .25rem) * 2);text-align:center;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);color:rgb(var(--ax-sys-color-on-lighter-surface))}@property --tw-leading{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-leading: initial}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: AXTranslationModule }, { kind: "ngmodule", type: AXPopoverModule }, { kind: "component", type: i1$1.AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXLoadingModule }, { kind: "component", type: i1$2.AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "component", type: AXPFileListComponent, selector: "axp-file-list", inputs: ["readonly", "fileEditable", "enableTitleDescription", "multiple", "look", "titleKey", "showLabel", "linksLayout", "files", "accept", "maxFileSize", "showUploadZoneHint", "plugins", "excludePlugins", "capabilities"], outputs: ["onRemove", "onRevert", "onRename"] }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
4957
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPFileUploaderWidgetColumnComponent, isStandalone: true, selector: "axp-file-uploader-widget-column", inputs: { rawValue: "rawValue", rowData: "rowData" }, viewQueries: [{ propertyName: "fileListTrigger", first: true, predicate: ["fileListTrigger"], descendants: true, isSignal: true }, { propertyName: "fileListPopover", first: true, predicate: ["fileListPopover"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (fileCount() > 0) {\n <span\n class=\"cursor-pointer text-primary underline\"\n (click)=\"openFileListPopover(); $event.stopPropagation()\"\n #fileListTrigger\n >\n {{\n '@general:widgets.file-uploader.column.files-count'\n | translate: { params: { count: fileCount() } }\n | async\n }}\n </span>\n} @else if (showAttachmentsLink()) {\n <span\n class=\"cursor-pointer text-primary underline\"\n (click)=\"openFileListPopover(); $event.stopPropagation()\"\n #fileListTrigger\n >\n {{ '@general:widgets.file-uploader.attachments.title' | translate | async }}\n </span>\n} @else {\n <span class=\"text-muted\">---</span>\n}\n\n<ax-popover [openOn]=\"'manual'\" #fileListPopover (openChange)=\"onPopoverOpenChange($event)\">\n <div class=\"lightest-surface dark:dark-surface min-w-[17.5rem] max-w-[26rem] overflow-hidden\">\n <div class=\"border-b border-surface px-4 py-3\">\n <h3 class=\"m-0 text-sm font-semibold leading-normal text-on-lightest-surface\">\n {{ popoverTitle() | translate | async }}\n </h3>\n </div>\n <div class=\"max-h-64 overflow-y-auto px-3 py-3\" style=\"max-height: max(30dvh, 12rem)\">\n @if (loadStatus() === 'loading') {\n <div class=\"flex min-h-[120px] items-center justify-center\">\n <ax-loading></ax-loading>\n </div>\n } @else if (loadStatus() === 'error') {\n <div class=\"text-danger text-sm\">{{ loadError() }}</div>\n } @else if (popoverFiles().length === 0) {\n <p class=\"axp-file-uploader-column-popover__empty\">\n {{ '@general:widgets.file-uploader.empty-state.title' | translate | async }}\n </p>\n } @else {\n <axp-file-list\n [files]=\"popoverFiles()\"\n look=\"links\"\n linksLayout=\"menu\"\n [showLabel]=\"false\"\n [readonly]=\"true\"\n />\n }\n </div>\n </div>\n</ax-popover>\n", styles: ["@layer properties;.axp-file-uploader-column-popover__empty{margin:0;padding-block:calc(var(--spacing, .25rem) * 2);text-align:center;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);color:rgb(var(--ax-sys-color-on-lighter-surface))}@property --tw-leading{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-leading: initial}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: AXTranslationModule }, { kind: "ngmodule", type: AXPopoverModule }, { kind: "component", type: i1$1.AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "closeOnNavigation", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXLoadingModule }, { kind: "component", type: i1$2.AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "component", type: AXPFileListComponent, selector: "axp-file-list", inputs: ["readonly", "fileEditable", "enableTitleDescription", "multiple", "look", "titleKey", "showLabel", "linksLayout", "files", "accept", "maxFileSize", "showUploadZoneHint", "plugins", "excludePlugins", "capabilities"], outputs: ["onRemove", "onRevert", "onRename"] }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
4882
4958
|
}
|
|
4883
4959
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPFileUploaderWidgetColumnComponent, decorators: [{
|
|
4884
4960
|
type: Component,
|
|
@@ -5473,7 +5549,7 @@ class AXPFileUploaderWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
5473
5549
|
(onRename)="handleFileRename($event)"
|
|
5474
5550
|
></axp-file-list>
|
|
5475
5551
|
</div>
|
|
5476
|
-
`, isInline: true, styles: [":host.axp-file-uploader-widget-edit--borderless{border:none!important}.__drop-zone--interactive{cursor:pointer;border:2px dashed rgb(var(--ax-sys-color-border-lighter-surface));border-radius:.5rem;transition:border-color .15s ease,background-color .15s ease}.__drop-zone--interactive:hover{border-color:rgb(var(--ax-sys-color-primary-surface));background-color:rgba(var(--ax-sys-color-primary-50),.08)}.__drop-zone--drag-over{border-color:rgb(var(--ax-sys-color-primary-surface))!important;background-color:rgba(var(--ax-sys-color-primary-50),.16)!important;box-shadow:0 0 0 3px rgba(var(--ax-sys-color-primary-50),.35)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXLoadingModule }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "directive", type: AXPFileChooserDirective, selector: "[axpFileChooser]", inputs: ["context", "disabled", "items", "busy"], outputs: ["itemsChange", "busyChange"] }, { kind: "component", type: AXPFileListComponent, selector: "axp-file-list", inputs: ["readonly", "fileEditable", "enableTitleDescription", "multiple", "look", "titleKey", "showLabel", "linksLayout", "files", "accept", "maxFileSize", "showUploadZoneHint", "plugins", "excludePlugins", "capabilities"], outputs: ["onRemove", "onRevert", "onRename"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
5552
|
+
`, isInline: true, styles: [":host.axp-file-uploader-widget-edit--borderless{border:none!important}.__drop-zone--interactive{cursor:pointer;padding-top:.5rem;border:2px dashed rgb(var(--ax-sys-color-border-lighter-surface));border-radius:.5rem;transition:border-color .15s ease,background-color .15s ease}.__drop-zone--interactive:hover{border-color:rgb(var(--ax-sys-color-primary-surface));background-color:rgba(var(--ax-sys-color-primary-50),.08)}.__drop-zone--drag-over{border-color:rgb(var(--ax-sys-color-primary-surface))!important;background-color:rgba(var(--ax-sys-color-primary-50),.16)!important;box-shadow:0 0 0 3px rgba(var(--ax-sys-color-primary-50),.35)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXLoadingModule }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "directive", type: AXPFileChooserDirective, selector: "[axpFileChooser]", inputs: ["context", "disabled", "items", "busy"], outputs: ["itemsChange", "busyChange"] }, { kind: "component", type: AXPFileListComponent, selector: "axp-file-list", inputs: ["readonly", "fileEditable", "enableTitleDescription", "multiple", "look", "titleKey", "showLabel", "linksLayout", "files", "accept", "maxFileSize", "showUploadZoneHint", "plugins", "excludePlugins", "capabilities"], outputs: ["onRemove", "onRevert", "onRename"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
5477
5553
|
}
|
|
5478
5554
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPFileUploaderWidgetEditComponent, decorators: [{
|
|
5479
5555
|
type: Component,
|
|
@@ -5532,7 +5608,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
5532
5608
|
'[class.border]': 'showBorder()',
|
|
5533
5609
|
'[class.rounded-md]': 'showBorder()',
|
|
5534
5610
|
'[class.lightest-surface]': 'showBorder()',
|
|
5535
|
-
}, changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [CommonModule, FormsModule, AXButtonModule, AXDecoratorModule, AXLoadingModule, AXTranslationModule, AXPFileChooserDirective, AXPFileListComponent], styles: [":host.axp-file-uploader-widget-edit--borderless{border:none!important}.__drop-zone--interactive{cursor:pointer;border:2px dashed rgb(var(--ax-sys-color-border-lighter-surface));border-radius:.5rem;transition:border-color .15s ease,background-color .15s ease}.__drop-zone--interactive:hover{border-color:rgb(var(--ax-sys-color-primary-surface));background-color:rgba(var(--ax-sys-color-primary-50),.08)}.__drop-zone--drag-over{border-color:rgb(var(--ax-sys-color-primary-surface))!important;background-color:rgba(var(--ax-sys-color-primary-50),.16)!important;box-shadow:0 0 0 3px rgba(var(--ax-sys-color-primary-50),.35)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"] }]
|
|
5611
|
+
}, changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [CommonModule, FormsModule, AXButtonModule, AXDecoratorModule, AXLoadingModule, AXTranslationModule, AXPFileChooserDirective, AXPFileListComponent], styles: [":host.axp-file-uploader-widget-edit--borderless{border:none!important}.__drop-zone--interactive{cursor:pointer;padding-top:.5rem;border:2px dashed rgb(var(--ax-sys-color-border-lighter-surface));border-radius:.5rem;transition:border-color .15s ease,background-color .15s ease}.__drop-zone--interactive:hover{border-color:rgb(var(--ax-sys-color-primary-surface));background-color:rgba(var(--ax-sys-color-primary-50),.08)}.__drop-zone--drag-over{border-color:rgb(var(--ax-sys-color-primary-surface))!important;background-color:rgba(var(--ax-sys-color-primary-50),.16)!important;box-shadow:0 0 0 3px rgba(var(--ax-sys-color-primary-50),.35)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"] }]
|
|
5536
5612
|
}] });
|
|
5537
5613
|
|
|
5538
5614
|
var fileUploaderWidgetEdit_component = /*#__PURE__*/Object.freeze({
|
|
@@ -7157,9 +7233,17 @@ function createEntityCardDisplayScope(contextEvalFactory, data) {
|
|
|
7157
7233
|
};
|
|
7158
7234
|
}
|
|
7159
7235
|
function createEntityCardLogicScope(data) {
|
|
7236
|
+
const record = (data ?? {});
|
|
7160
7237
|
return {
|
|
7238
|
+
data: record,
|
|
7161
7239
|
context: {
|
|
7162
|
-
eval: (path) => get(
|
|
7240
|
+
eval: (path) => get(record, path),
|
|
7241
|
+
getVariable: (name) => {
|
|
7242
|
+
if (!name || name === 'data') {
|
|
7243
|
+
return record;
|
|
7244
|
+
}
|
|
7245
|
+
return get(record, name);
|
|
7246
|
+
},
|
|
7163
7247
|
},
|
|
7164
7248
|
};
|
|
7165
7249
|
}
|
|
@@ -7256,6 +7340,126 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
7256
7340
|
}, imports: [AXSkeletonModule], template: "<article\n class=\"axp-entity-card-skeleton\"\n [class.axp-entity-card-skeleton--with-body]=\"showContent() && fieldPlaceholders().length && !rowLayout()\"\n [class.axp-entity-card-skeleton--with-footer]=\"showFooter()\"\n [class.axp-entity-card-skeleton--row]=\"rowLayout()\"\n [class.axp-entity-card-skeleton--embedded]=\"embedded()\"\n [class.axp-entity-card-skeleton--elevated]=\"elevated()\"\n aria-hidden=\"true\"\n>\n <!-- ----- Card header placeholders ----- -->\n <div class=\"axp-entity-card-skeleton__identity\">\n <div class=\"axp-entity-card-skeleton__identity-main\">\n @if (showAvatar()) {\n <!-- ----- Avatar placeholder only when the layout has an avatar field ----- -->\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__avatar\"></ax-skeleton>\n }\n <div class=\"axp-entity-card-skeleton__identity-text\">\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__title\"></ax-skeleton>\n @if (showContent()) {\n <!-- ----- Description or inline fact placeholders ----- -->\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__description\"></ax-skeleton>\n }\n </div>\n @for (index of badgePlaceholders(); track index) {\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__badge\"></ax-skeleton>\n }\n </div>\n @if (showHeaderMenu()) {\n <!-- ----- Overflow menu placeholder ----- -->\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__menu\"></ax-skeleton>\n }\n </div>\n\n @if (showContent() && !rowLayout()) {\n <!-- ----- Fact placeholders when card content is shown ----- -->\n <!--------------------------------------------------------------->\n @if (fieldPlaceholders().length) {\n <div class=\"axp-entity-card-skeleton__fields\">\n @for (index of fieldPlaceholders(); track index) {\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__fact\"></ax-skeleton>\n }\n </div>\n }\n }\n\n @if (showFooter()) {\n <!-- ----- Primary action placeholder ----- -->\n <footer class=\"axp-entity-card-skeleton__footer\">\n <ax-skeleton [animated]=\"true\" class=\"axp-entity-card-skeleton__primary-action\"></ax-skeleton>\n </footer>\n }\n</article>\n", styles: ["@layer properties;:host{display:block;width:100%;min-width:0px}:host.axp-entity-card-host--fill{display:flex;width:100%;min-width:0;flex:1 1 auto;flex-direction:column}:host.axp-entity-card-host--elevated{border-radius:var(--radius-md, .375rem);box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-card-skeleton{display:flex;width:100%;flex-direction:column;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / .05));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card-skeleton .axp-entity-card-skeleton__identity{display:flex;align-items:center;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3)}.axp-entity-card-skeleton .axp-entity-card-skeleton__identity-main{display:flex;min-width:0px;flex:1;flex-wrap:wrap;align-items:center;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card-skeleton .axp-entity-card-skeleton__avatar{height:calc(var(--spacing, .25rem) * 12);width:calc(var(--spacing, .25rem) * 12);flex-shrink:0;border-radius:var(--radius-lg, .5rem)}.axp-entity-card-skeleton .axp-entity-card-skeleton__identity-text{display:flex;min-width:0px;flex:1;flex-direction:column;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card-skeleton .axp-entity-card-skeleton__title{height:calc(var(--spacing, .25rem) * 5);width:calc(var(--spacing, .25rem) * 40);max-width:100%;border-radius:.25rem}.axp-entity-card-skeleton .axp-entity-card-skeleton__badge{height:calc(var(--spacing, .25rem) * 5);width:calc(var(--spacing, .25rem) * 14);flex-shrink:0;border-radius:calc(infinity * 1px)}.axp-entity-card-skeleton .axp-entity-card-skeleton__menu{height:calc(var(--spacing, .25rem) * 8);width:calc(var(--spacing, .25rem) * 8);flex-shrink:0;border-radius:.25rem}.axp-entity-card-skeleton .axp-entity-card-skeleton__description{height:calc(var(--spacing, .25rem) * 3.5);width:calc(var(--spacing, .25rem) * 32);max-width:100%;border-radius:.25rem;color:var(--color-gray-400, oklch(70.7% .022 261.325))}.axp-entity-card-skeleton .axp-entity-card-skeleton__fields{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3)}.axp-entity-card-skeleton .axp-entity-card-skeleton__fact{height:calc(var(--spacing, .25rem) * 4);width:calc(var(--spacing, .25rem) * 40);border-radius:.25rem}.axp-entity-card-skeleton .axp-entity-card-skeleton__footer{margin-top:auto;border-bottom-right-radius:var(--radius-md, .375rem);border-bottom-left-radius:var(--radius-md, .375rem);border-top-style:var(--tw-border-style);border-top-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3)}.axp-entity-card-skeleton .axp-entity-card-skeleton__primary-action{height:calc(var(--spacing, .25rem) * 10);width:100%;border-radius:var(--radius-lg, .5rem)}.axp-entity-card-skeleton.axp-entity-card-skeleton--row .axp-entity-card-skeleton__avatar{height:calc(var(--spacing, .25rem) * 10);width:calc(var(--spacing, .25rem) * 10)}.axp-entity-card-skeleton.axp-entity-card-skeleton--elevated{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card-skeleton.axp-entity-card-skeleton--embedded{border-radius:0;border-style:var(--tw-border-style);border-width:0px;--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card-skeleton.axp-entity-card-skeleton--embedded .axp-entity-card-skeleton__identity,.axp-entity-card-skeleton.axp-entity-card-skeleton--embedded .axp-entity-card-skeleton__fields{padding-inline:0px}.axp-entity-card-skeleton.axp-entity-card-skeleton--embedded .axp-entity-card-skeleton__identity{padding-block:0px}:host.axp-entity-card-host--fill .axp-entity-card-skeleton{display:flex;width:100%;min-height:0;flex:1 1 auto;flex-direction:column}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"] }]
|
|
7257
7341
|
}], propDecorators: { fieldCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "fieldCount", required: false }] }], badgeCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "badgeCount", required: false }] }], showFooter: [{ type: i0.Input, args: [{ isSignal: true, alias: "showFooter", required: false }] }], showHeaderMenu: [{ type: i0.Input, args: [{ isSignal: true, alias: "showHeaderMenu", required: false }] }], showContent: [{ type: i0.Input, args: [{ isSignal: true, alias: "showContent", required: false }] }], rowLayout: [{ type: i0.Input, args: [{ isSignal: true, alias: "rowLayout", required: false }] }], showAvatar: [{ type: i0.Input, args: [{ isSignal: true, alias: "showAvatar", required: false }] }], fillHost: [{ type: i0.Input, args: [{ isSignal: true, alias: "fillHost", required: false }] }], embedded: [{ type: i0.Input, args: [{ isSignal: true, alias: "embedded", required: false }] }], elevated: [{ type: i0.Input, args: [{ isSignal: true, alias: "elevated", required: false }] }] } });
|
|
7258
7342
|
|
|
7343
|
+
//#region ----- Imports -----
|
|
7344
|
+
//#endregion
|
|
7345
|
+
//#region ----- Constants -----
|
|
7346
|
+
const STYLE_ELEMENT_ID = 'axp-entity-list-surface-chrome';
|
|
7347
|
+
const registeredHexClassNames = new Set();
|
|
7348
|
+
//#endregion
|
|
7349
|
+
//#region ----- Public API -----
|
|
7350
|
+
/** Injects row/cell/card CSS for every theme style × variant (e.g. `primary-light-surface` vs `primary-darkest-surface`). */
|
|
7351
|
+
function ensureEntityListSurfaceChromeStyles() {
|
|
7352
|
+
if (typeof document === 'undefined' || document.getElementById(STYLE_ELEMENT_ID)) {
|
|
7353
|
+
return;
|
|
7354
|
+
}
|
|
7355
|
+
const styleElement = document.createElement('style');
|
|
7356
|
+
styleElement.id = STYLE_ELEMENT_ID;
|
|
7357
|
+
styleElement.textContent = [
|
|
7358
|
+
listThemeSurfaceClasses().map(buildThemeSurfaceChromeRule).join(''),
|
|
7359
|
+
disableRowAnimation('[class*="-surface"]'),
|
|
7360
|
+
disableRowAnimation('[class*="axp-hex-"]'),
|
|
7361
|
+
].join('');
|
|
7362
|
+
document.head.appendChild(styleElement);
|
|
7363
|
+
}
|
|
7364
|
+
/** Pastel hex classes need the same list chrome as theme surfaces; inject per class. */
|
|
7365
|
+
function ensureEntityListHexChromeClass(className) {
|
|
7366
|
+
const parsed = parseRuntimeHexSurface(className);
|
|
7367
|
+
if (!parsed || registeredHexClassNames.has(parsed.className) || typeof document === 'undefined') {
|
|
7368
|
+
return;
|
|
7369
|
+
}
|
|
7370
|
+
ensureEntityListSurfaceChromeStyles();
|
|
7371
|
+
const styleElement = document.getElementById(STYLE_ELEMENT_ID);
|
|
7372
|
+
if (!styleElement) {
|
|
7373
|
+
return;
|
|
7374
|
+
}
|
|
7375
|
+
styleElement.appendChild(document.createTextNode(buildListChromeRule(parsed.className, parsed.background, parsed.color, parsed.border, parsed.border)));
|
|
7376
|
+
registeredHexClassNames.add(parsed.className);
|
|
7377
|
+
}
|
|
7378
|
+
//#endregion
|
|
7379
|
+
//#region ----- CSS generate -----
|
|
7380
|
+
function disableRowAnimation(selector) {
|
|
7381
|
+
return `axp-entity-master-list-data-table ax-data-table tbody tr${selector}:not(.ax-row-color-pulse) td{animation:none!important;}`;
|
|
7382
|
+
}
|
|
7383
|
+
function buildThemeSurfaceChromeRule(className) {
|
|
7384
|
+
const background = `rgb(var(--ax-sys-color-${className}))`;
|
|
7385
|
+
const color = `rgb(var(--ax-sys-color-on-${className}))`;
|
|
7386
|
+
const border = `rgb(var(--ax-sys-color-border-${className}))`;
|
|
7387
|
+
const borderSoft = `rgb(var(--ax-sys-color-border-${className}) / 0.35)`;
|
|
7388
|
+
return buildListChromeRule(className, background, color, border, borderSoft);
|
|
7389
|
+
}
|
|
7390
|
+
function buildListChromeRule(className, background, color, border, borderSoft) {
|
|
7391
|
+
return (`axp-entity-master-list-data-table ax-data-table tbody tr.${className} > td{background:${background}!important;color:${color};}` +
|
|
7392
|
+
`axp-entity-master-list-data-table ax-data-table tbody tr > td.${className}{background:${background}!important;color:${color};box-shadow:inset 0 0 0 1px ${borderSoft};}` +
|
|
7393
|
+
`.axp-entity-card.${className}{--axp-entity-card-surface:${background};--axp-entity-card-border:${border};color:${color};background-color:var(--axp-entity-card-surface);}` +
|
|
7394
|
+
`.axp-entity-card.${className} .axp-entity-card__footer{background-color:transparent;}` +
|
|
7395
|
+
`.axp-entity-card__field-row.${className},.axp-entity-card__fact.${className},.axp-entity-card__header-badge.${className}{background-color:${background};color:${color};box-shadow:inset 0 0 0 1px ${borderSoft};}` +
|
|
7396
|
+
`.axp-entity-card__field-row.${className}{width:auto;margin-inline:calc(-1 * var(--axp-entity-card-gutter));padding-inline:var(--axp-entity-card-gutter);}`);
|
|
7397
|
+
}
|
|
7398
|
+
//#endregion
|
|
7399
|
+
|
|
7400
|
+
//#region ----- Imports -----
|
|
7401
|
+
//#endregion
|
|
7402
|
+
//#region ----- Public API -----
|
|
7403
|
+
function joinEntityListStylingClasses(...parts) {
|
|
7404
|
+
ensureEntityListSurfaceChromeStyles();
|
|
7405
|
+
const tokens = parts.flatMap((part) => part ? part.split(/\s+/).filter(Boolean).map(toEntityListStylingChromeClass) : []);
|
|
7406
|
+
if (!tokens.length) {
|
|
7407
|
+
return undefined;
|
|
7408
|
+
}
|
|
7409
|
+
const unique = [...new Set(tokens)];
|
|
7410
|
+
for (const token of unique) {
|
|
7411
|
+
ensureRuntimeSurfaceClass(token);
|
|
7412
|
+
ensureEntityListHexChromeClass(token);
|
|
7413
|
+
}
|
|
7414
|
+
return unique.join(' ');
|
|
7415
|
+
}
|
|
7416
|
+
/** Keep full theme surfaces (`primary-darkest-surface`); unwrap `ax-row-color-warning` to `warning` for cards. */
|
|
7417
|
+
function toEntityListStylingChromeClass(className) {
|
|
7418
|
+
const trimmed = className.trim();
|
|
7419
|
+
const rowColor = /^ax-row-color-([a-z0-9]+)$/i.exec(trimmed);
|
|
7420
|
+
if (rowColor && AXP_THEME_SURFACE_STYLES.includes(rowColor[1].toLowerCase())) {
|
|
7421
|
+
return rowColor[1].toLowerCase();
|
|
7422
|
+
}
|
|
7423
|
+
return trimmed;
|
|
7424
|
+
}
|
|
7425
|
+
/** Classes from personal rules whose target is the whole row. */
|
|
7426
|
+
function resolveEntityListUserRecordStylingClass(row, rules) {
|
|
7427
|
+
return resolveEntityListUserStylingClass(row, rules, AXP_ENTITY_LIST_RECORD_STYLING_TARGET);
|
|
7428
|
+
}
|
|
7429
|
+
/** Classes from personal rules whose target is one property. */
|
|
7430
|
+
function resolveEntityListUserFieldStylingClass(row, rules, fieldName) {
|
|
7431
|
+
return resolveEntityListUserStylingClass(row, rules, fieldName);
|
|
7432
|
+
}
|
|
7433
|
+
//#endregion
|
|
7434
|
+
//#region ----- Match -----
|
|
7435
|
+
function resolveEntityListUserStylingClass(row, rules, target) {
|
|
7436
|
+
const classes = [];
|
|
7437
|
+
for (const rule of rules) {
|
|
7438
|
+
if (rule.target !== target || !matchesUserStylingRule(row, rule)) {
|
|
7439
|
+
continue;
|
|
7440
|
+
}
|
|
7441
|
+
classes.push(rule.className);
|
|
7442
|
+
}
|
|
7443
|
+
return joinEntityListStylingClasses(...classes);
|
|
7444
|
+
}
|
|
7445
|
+
function matchesUserStylingRule(row, rule) {
|
|
7446
|
+
if (!rule.className.trim() || !isCompleteEntityListStylingCondition(rule.condition)) {
|
|
7447
|
+
return false;
|
|
7448
|
+
}
|
|
7449
|
+
try {
|
|
7450
|
+
const clause = rule.condition;
|
|
7451
|
+
if (clause.filters?.length) {
|
|
7452
|
+
const logic = clause.logic === 'or' ? 'or' : 'and';
|
|
7453
|
+
return applyFilterArray([row], clause.filters, logic).length > 0;
|
|
7454
|
+
}
|
|
7455
|
+
return applyFilterArray([row], [clause]).length > 0;
|
|
7456
|
+
}
|
|
7457
|
+
catch {
|
|
7458
|
+
return false;
|
|
7459
|
+
}
|
|
7460
|
+
}
|
|
7461
|
+
//#endregion
|
|
7462
|
+
|
|
7259
7463
|
/** Evaluates a compiled master-styling class expression against record (and optional field) data. */
|
|
7260
7464
|
async function resolveEntityMasterStylingClass(evaluator, expression, data, fieldName) {
|
|
7261
7465
|
if (!expression) {
|
|
@@ -7300,6 +7504,9 @@ class AXPEntityCardComponent {
|
|
|
7300
7504
|
...(ngDevMode ? [{ debugName: "row" }] : /* istanbul ignore next */ []));
|
|
7301
7505
|
this.fields = input([], /* @ts-ignore */
|
|
7302
7506
|
...(ngDevMode ? [{ debugName: "fields" }] : /* istanbul ignore next */ []));
|
|
7507
|
+
/** Personal highlight rules. Merged with `interfaces.master.styling`. */
|
|
7508
|
+
this.userStylingRules = input([], /* @ts-ignore */
|
|
7509
|
+
...(ngDevMode ? [{ debugName: "userStylingRules" }] : /* istanbul ignore next */ []));
|
|
7303
7510
|
this.variant = input('card', /* @ts-ignore */
|
|
7304
7511
|
...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
7305
7512
|
this.interactive = input(false, /* @ts-ignore */
|
|
@@ -7436,13 +7643,14 @@ class AXPEntityCardComponent {
|
|
|
7436
7643
|
const row = this.row();
|
|
7437
7644
|
const header = this.header();
|
|
7438
7645
|
const fields = this.fields();
|
|
7646
|
+
const userStylingRules = this.userStylingRules();
|
|
7439
7647
|
const badgeFields = this.headerBadgeFields().filter((field) => !this.isStatusBadgeField(field));
|
|
7440
7648
|
const loader = this.secondaryActionLoader();
|
|
7441
7649
|
untracked(() => {
|
|
7442
7650
|
void this.loadSecondaryActions(row, loader);
|
|
7443
7651
|
void this.resolveHeaderFields(row, header);
|
|
7444
7652
|
void this.resolveBadgeColors(row, badgeFields);
|
|
7445
|
-
void this.resolveStylingClasses(row, fields);
|
|
7653
|
+
void this.resolveStylingClasses(row, fields, userStylingRules);
|
|
7446
7654
|
});
|
|
7447
7655
|
});
|
|
7448
7656
|
}
|
|
@@ -7581,15 +7789,16 @@ class AXPEntityCardComponent {
|
|
|
7581
7789
|
}
|
|
7582
7790
|
//#endregion
|
|
7583
7791
|
//#region ----- Private Helpers -----
|
|
7584
|
-
async resolveStylingClasses(row, fields) {
|
|
7792
|
+
async resolveStylingClasses(row, fields, userStylingRules) {
|
|
7585
7793
|
const entity = this.entity();
|
|
7586
7794
|
const recordClass = await resolveEntityMasterRecordStylingClass(this.expressionEvaluator, entity, row);
|
|
7587
|
-
this.recordStylingClass.set(recordClass);
|
|
7795
|
+
this.recordStylingClass.set(joinEntityListStylingClasses(recordClass, resolveEntityListUserRecordStylingClass(row, userStylingRules)));
|
|
7588
7796
|
const fieldClasses = {};
|
|
7589
7797
|
await Promise.all(fields.map(async (field) => {
|
|
7590
7798
|
const fieldClass = await resolveEntityMasterFieldStylingClass(this.expressionEvaluator, entity, row, field.name);
|
|
7591
|
-
|
|
7592
|
-
|
|
7799
|
+
const merged = joinEntityListStylingClasses(fieldClass, resolveEntityListUserFieldStylingClass(row, userStylingRules, field.name));
|
|
7800
|
+
if (merged) {
|
|
7801
|
+
fieldClasses[field.name] = merged;
|
|
7593
7802
|
}
|
|
7594
7803
|
}));
|
|
7595
7804
|
this.fieldStylingClassByName.set(fieldClasses);
|
|
@@ -7770,7 +7979,7 @@ class AXPEntityCardComponent {
|
|
|
7770
7979
|
}
|
|
7771
7980
|
}
|
|
7772
7981
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPEntityCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7773
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPEntityCardComponent, isStandalone: true, selector: "axp-entity-card", inputs: { entity: { classPropertyName: "entity", publicName: "entity", isSignal: true, isRequired: true, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, interactive: { classPropertyName: "interactive", publicName: "interactive", isSignal: true, isRequired: false, transformFunction: null }, embedded: { classPropertyName: "embedded", publicName: "embedded", isSignal: true, isRequired: false, transformFunction: null }, elevated: { classPropertyName: "elevated", publicName: "elevated", isSignal: true, isRequired: false, transformFunction: null }, disableLookupPopover: { classPropertyName: "disableLookupPopover", publicName: "disableLookupPopover", isSignal: true, isRequired: false, transformFunction: null }, fillHost: { classPropertyName: "fillHost", publicName: "fillHost", isSignal: true, isRequired: false, transformFunction: null }, extraExpanded: { classPropertyName: "extraExpanded", publicName: "extraExpanded", isSignal: true, isRequired: false, transformFunction: null }, selected: { classPropertyName: "selected", publicName: "selected", isSignal: true, isRequired: false, transformFunction: null }, showNewBadge: { classPropertyName: "showNewBadge", publicName: "showNewBadge", isSignal: true, isRequired: false, transformFunction: null }, showSelection: { classPropertyName: "showSelection", publicName: "showSelection", isSignal: true, isRequired: false, transformFunction: null }, showClose: { classPropertyName: "showClose", publicName: "showClose", isSignal: true, isRequired: false, transformFunction: null }, primaryActions: { classPropertyName: "primaryActions", publicName: "primaryActions", isSignal: true, isRequired: false, transformFunction: null }, primaryActionLook: { classPropertyName: "primaryActionLook", publicName: "primaryActionLook", isSignal: true, isRequired: false, transformFunction: null }, secondaryActionLoader: { classPropertyName: "secondaryActionLoader", publicName: "secondaryActionLoader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { extraExpanded: "extraExpandedChange", selectionChange: "selectionChange", commandClick: "commandClick", closeClick: "closeClick" }, host: { properties: { "class.axp-entity-card-host--fill": "fillHost()", "class.axp-entity-card-host--elevated": "elevated()" } }, ngImport: i0, template: "<article\n class=\"axp-entity-card\"\n [ngClass]=\"recordStylingClass()\"\n [class.axp-entity-card--selected]=\"selected()\"\n [class.axp-entity-card--new]=\"showNewBadge()\"\n [class.axp-entity-card--row]=\"isRowLayout()\"\n [class.axp-entity-card--compact]=\"variant() === 'compact'\"\n [class.axp-entity-card--embedded]=\"embedded()\"\n [class.axp-entity-card--elevated]=\"elevated()\"\n [class.axp-entity-card--static]=\"!interactive()\"\n [class.axp-entity-card--with-body]=\"hasCardBody()\"\n [class.axp-entity-card--with-footer]=\"hasCardFooter()\"\n [class.axp-entity-card--expandable]=\"canShowMore()\"\n [class.axp-entity-card--expanded]=\"extraExpanded()\"\n [attr.role]=\"interactive() ? 'button' : undefined\"\n [attr.tabindex]=\"interactive() ? 0 : undefined\"\n [attr.aria-selected]=\"interactive() ? selected() : undefined\"\n (click)=\"onCardClick($event)\"\n (dblclick)=\"onCardDblClick($event)\"\n (keydown)=\"onCardKeydown($event)\"\n>\n <div class=\"axp-entity-card__content\">\n <!-- ----- Identity row: optional avatar, title, status, and actions ----- -->\n <div class=\"axp-entity-card__identity\">\n <div class=\"axp-entity-card__identity-main\">\n @if (showUserAvatar()) {\n <!-- ----- Person or user identity uses the user avatar ----- -->\n <axp-user-avatar class=\"axp-entity-card__avatar\" [size]=\"avatarSize()\" [userId]=\"userAvatarId()\" [displayName]=\"toDisplayName(titleText())\" [displayAvatar]=\"avatarSrc()\" [showPresence]=\"false\" [axpUserCard]=\"userAvatarId()\" />\n }\n <!--------------------------------------------------------------->\n @if (showIdentityImage()) {\n <!-- ----- Logo or company image for entities that store an image/logo ----- -->\n <div class=\"axp-entity-card__logo\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <img [src]=\"avatarSrc()\" [alt]=\"toDisplayName(titleText())\" />\n </div>\n }\n <!--------------------------------------------------------------->\n @if (identityQrField(); as field) {\n <!-- ----- QR widget occupies the identity visual slot when there is no avatar or logo ----- -->\n <div class=\"axp-entity-card__qr\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n\n <div class=\"axp-entity-card__identity-text\">\n <div class=\"axp-entity-card__title-row\">\n @if (iconClass(); as icon) {\n <!-- ----- Optional header icon from the card layout ----- -->\n <i [class]=\"icon + ' axp-entity-card__icon'\" aria-hidden=\"true\"></i>\n }\n\n <h3 class=\"axp-entity-card__title\">\n {{ titleText() | translate | async }}\n </h3>\n\n @if (showNewBadge()) {\n <!-- ----- New-row highlight badge ----- -->\n <ax-badge class=\"axp-entity-card__header-badge\" [text]=\"('@acorex:dataTable.rowHighlight.new' | translate | async) || ''\" color=\"success\" />\n }\n\n @for (field of headerBadgeFields(); track field.name) {\n <!--------------------------------------------------------------->\n @if (isStatusBadgeField(field)) {\n <!-- ----- Status widget rendered in the header ----- -->\n <div class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldHeaderBadgeNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n <!-- ----- Non-status field rendered as a simple badge ----- -->\n @else if (resolveBadgeText(field)) {\n <ax-badge class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\" [text]=\"resolveBadgeText(field)\" [color]=\"resolveBadgeColor(field)\" />\n }\n }\n </div>\n\n @if (descriptionText()) {\n <!-- ----- Optional description under the title ----- -->\n <p class=\"axp-entity-card__description\">\n {{ descriptionText() | translate | async }}\n </p>\n }\n\n @if (headerMetaFields().length) {\n <!-- ----- Unlabeled header extra (identifier or contact) ----- -->\n <div class=\"axp-entity-card__facts axp-entity-card__facts--inline\">\n @for (field of headerMetaFields(); track field.name) {\n <div class=\"axp-entity-card__fact\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n </div>\n }\n </div>\n </div>\n\n @if (hasIdentityActions()) {\n <!-- ----- Selection, overflow actions, or popover dismiss ----- -->\n <div class=\"axp-entity-card__identity-actions\">\n @if (showSelection()) {\n <!-- ----- Multi-select checkbox ----- -->\n <ax-check-box class=\"axp-entity-card__select-checkbox\" [value]=\"selected()\" (onValueChanged)=\"onSelectionCheckboxChange($event)\" (click)=\"onSelectionCheckboxClick($event)\" />\n }\n <!-- ----- Row actions menu when the card is not in selection mode ----- -->\n @else if (secondaryActions().length) {\n <ax-button [look]=\"'blank'\" [color]=\"'default'\" class=\"ax-sm\" (onClick)=\"stopClickPropagation($event)\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis\" aria-hidden=\"true\"></i>\n </ax-prefix>\n\n <ax-dropdown-panel #panel>\n <ax-button-item-list>\n @for (item of secondaryActions(); track $index) {\n @if (item.divided) {\n <!-- ----- Divider before this overflow action ----- -->\n <ax-divider />\n }\n <ax-button-item [text]=\"(item.title | translate | async)!\" [color]=\"item.color\" [disabled]=\"item.disabled\" (onClick)=\"onSecondaryActionClick(item, $event)\">\n @if (item.icon) {\n <!-- ----- Overflow action icon ----- -->\n <ax-prefix>\n <ax-icon icon=\"fa-light {{ item.icon }}\"></ax-icon>\n </ax-prefix>\n }\n </ax-button-item>\n }\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n }\n <!-- ----- Close when hosted as a lookup / detail popover ----- -->\n @if (showClose()) {\n <ax-button\n class=\"axp-entity-card__close ax-sm\"\n [look]=\"'blank'\"\n [color]=\"'default'\"\n [iconOnly]=\"true\"\n [attr.title]=\"'@general:actions.close.title' | translate | async\"\n [attr.aria-label]=\"'@general:actions.close.title' | translate | async\"\n (onClick)=\"onCloseClick($event)\"\n >\n <i class=\"fa-light fa-xmark\" aria-hidden=\"true\"></i>\n </ax-button>\n }\n </div>\n }\n </div>\n\n @if (hasLabeledBody()) {\n <!-- ----- Divider between unlabeled identity header and labeled body facts ----- -->\n <div class=\"axp-entity-card__divider\"></div>\n <div class=\"axp-entity-card__body\">\n <div class=\"axp-entity-card__fields\">\n @for (field of previewFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n <!--------------------------------------------------------------->\n @if (extraFields().length) {\n <!-- ----- Extra fields stay mounted; collapse hides them without a body fade ----- -->\n <div class=\"axp-entity-card__extra\" [class.axp-entity-card__extra--collapsed]=\"!extraExpanded()\">\n @for (field of extraFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n\n @if (showInlineMore()) {\n <!-- ----- Quiet More/Less under the fields when the card has no action footer ----- -->\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--inline\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n </div>\n\n @if (hasCardFooter()) {\n <!-- ----- One footer row: optional More on the left, primary actions on the right ----- -->\n <footer class=\"axp-entity-card__footer\">\n <!-- ----- More/Less shares the footer with the action button ----- -->\n @if (showFooterMore()) {\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--footer\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n <div class=\"axp-entity-card__footer-actions\">\n @for (action of primaryActions(); track $index) {\n <ax-button\n class=\"axp-entity-card__primary-action ax-sm\"\n [look]=\"primaryActionLook()\"\n [color]=\"action.color\"\n [disabled]=\"action.disabled\"\n [text]=\"(action.title | translate | async)!\"\n (onClick)=\"onPrimaryActionClick(action.name, $event)\"\n >\n @if (action.icon) {\n <!-- ----- Primary action icon ----- -->\n <ax-prefix>\n <i class=\"fa-light {{ action.icon }}\"></i>\n </ax-prefix>\n }\n </ax-button>\n }\n </div>\n </footer>\n }\n</article>\n", styles: ["@layer properties;:host{display:block;width:100%;min-width:0px}:host.axp-entity-card-host--fill{display:flex;width:100%;min-width:0;flex:1 1 auto;flex-direction:column}:host.axp-entity-card-host--elevated{border-radius:var(--radius-md, .375rem);box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-card{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));--axp-entity-card-border: rgb(var(--ax-sys-color-border-light-surface));--axp-entity-card-gutter: 1rem;position:relative;display:flex;width:100%;flex-direction:column;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / .05));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);transition-property:box-shadow;transition-timing-function:var(--tw-ease, var(--default-transition-timing-function, cubic-bezier(.4, 0, .2, 1)));transition-duration:var(--tw-duration, var(--default-transition-duration, .15s));background-color:var(--axp-entity-card-surface);border-color:var(--axp-entity-card-border)}.axp-entity-card:hover{--tw-shadow: 0 4px 6px -1px var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 2px 4px -2px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card.axp-entity-card--selected{border-color:rgba(var(--ax-sys-color-primary-500));--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);box-shadow:0 0 0 1px rgb(var(--ax-sys-color-primary-500) / .25),0 2px 6px #0000000f}.axp-entity-card.axp-entity-card--new{border-color:rgb(var(--ax-sys-color-border-success-surface));box-shadow:0 0 0 1px rgb(var(--ax-sys-color-success-500) / .2)}.axp-entity-card.primary{--axp-entity-card-surface: rgb(var(--ax-sys-color-primary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-primary-lightest-surface))}.axp-entity-card.secondary{--axp-entity-card-surface: rgb(var(--ax-sys-color-secondary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-secondary-lightest-surface))}.axp-entity-card.success{--axp-entity-card-surface: rgb(var(--ax-sys-color-success-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-success-lightest-surface))}.axp-entity-card.warning{--axp-entity-card-surface: rgb(var(--ax-sys-color-warning-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-warning-lightest-surface))}.axp-entity-card.danger{--axp-entity-card-surface: rgb(var(--ax-sys-color-danger-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-danger-lightest-surface))}.axp-entity-card.accent1{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent1-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent1-lightest-surface))}.axp-entity-card.accent2{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent2-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent2-lightest-surface))}.axp-entity-card.accent3{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent3-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent3-lightest-surface))}.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3{background-color:var(--axp-entity-card-surface)}:is(.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3) .axp-entity-card__footer{background-color:transparent}.axp-entity-card:not(.axp-entity-card--static){cursor:pointer}.axp-entity-card.axp-entity-card--static{cursor:default}.axp-entity-card.axp-entity-card--elevated{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));background-color:rgb(var(--ax-sys-color-lightest-surface));--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated .axp-entity-card__footer{background-color:rgb(var(--ax-sys-color-lightest-surface))}.axp-entity-card.axp-entity-card--embedded{border-radius:0;border-style:var(--tw-border-style);border-width:0px;--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);--axp-entity-card-surface: transparent;background-color:transparent}.axp-entity-card.axp-entity-card--embedded:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__identity{padding-inline:0px;padding-block:0px}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__fields{padding-inline:0px;padding-top:calc(var(--spacing, .25rem) * 2);padding-bottom:0}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__divider{margin-inline:0px}.axp-entity-card .axp-entity-card__identity{display:flex;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__identity-main{display:flex;min-width:0px;flex:1;align-items:flex-start;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__avatar{flex-shrink:0}.axp-entity-card .axp-entity-card__logo{flex-shrink:0;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-surface))}.axp-entity-card .axp-entity-card__logo img{width:100%;height:100%;object-fit:contain}.axp-entity-card .axp-entity-card__qr{display:flex;flex-shrink:0;align-items:center;justify-content:center;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__qr axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__identity-text{display:flex;min-width:0px;flex:1;flex-direction:column;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__title-row{display:flex;min-width:0px;flex-wrap:wrap;align-items:center;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__select-checkbox,.axp-entity-card .axp-entity-card__header-badge{flex-shrink:0}.axp-entity-card .axp-entity-card__identity-actions{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__close{margin-inline-end:calc(var(--spacing, .25rem) * -1);margin-top:calc(var(--spacing, .25rem) * -.5)}.axp-entity-card .axp-entity-card__content{position:relative;flex:1}.axp-entity-card .axp-entity-card__more{display:inline-flex;min-height:calc(var(--spacing, .25rem) * 8);flex-shrink:0;cursor:pointer;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding-inline:var(--spacing, .25rem);font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-font-weight: var(--font-weight-medium, 500);font-weight:var(--font-weight-medium, 500);color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__more span,.axp-entity-card .axp-entity-card__more i{pointer-events:none}.axp-entity-card .axp-entity-card__more i{font-size:10px;--tw-leading: 1;line-height:1}.axp-entity-card .axp-entity-card__more:hover,.axp-entity-card .axp-entity-card__more:focus-visible{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__more:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card .axp-entity-card__more--footer{margin-block:calc(var(--spacing, .25rem) * -2.5);margin-inline-start:calc(var(--spacing, .25rem) * -1);min-height:calc(var(--spacing, .25rem) * 10);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__more--inline{margin-inline:var(--axp-entity-card-gutter);margin-top:calc(var(--spacing, .25rem) * .5);margin-bottom:calc(var(--spacing, .25rem) * 2);padding-inline:var(--spacing, .25rem);padding-block:calc(var(--spacing, .25rem) * 2)}.axp-entity-card.axp-entity-card--expanded .axp-entity-card__more{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__title{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));--tw-leading: var(--leading-relaxed, 1.625);line-height:var(--leading-relaxed, 1.625);--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}.axp-entity-card .axp-entity-card__icon{flex-shrink:0;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__description{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);opacity:65%}.axp-entity-card .axp-entity-card__facts{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-bottom:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__facts--inline{flex-direction:row;flex-wrap:wrap;align-items:center;column-gap:calc(var(--spacing, .25rem) * 4);row-gap:var(--spacing, .25rem);padding-inline:0px;padding-block:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__fact{min-width:0px;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__fact axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__divider{margin-inline:var(--axp-entity-card-gutter);border-top:1px solid var(--axp-entity-card-border)}.axp-entity-card .axp-entity-card__body{position:relative;overflow:hidden}.axp-entity-card .axp-entity-card__extra{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__extra--collapsed{display:none}.axp-entity-card .axp-entity-card__fields{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3{width:auto;margin-inline:calc(-1 * var(--axp-entity-card-gutter));padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__field-row.primary{--axp-entity-styling-border: var(--ax-sys-color-border-primary-lightest-surface);background-color:rgb(var(--ax-sys-color-primary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-primary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__field-row.secondary{--axp-entity-styling-border: var(--ax-sys-color-border-secondary-lightest-surface);background-color:rgb(var(--ax-sys-color-secondary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-secondary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__field-row.success{--axp-entity-styling-border: var(--ax-sys-color-border-success-lightest-surface);background-color:rgb(var(--ax-sys-color-success-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-success-lightest-surface))}.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__field-row.warning{--axp-entity-styling-border: var(--ax-sys-color-border-warning-lightest-surface);background-color:rgb(var(--ax-sys-color-warning-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-warning-lightest-surface))}.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__field-row.danger{--axp-entity-styling-border: var(--ax-sys-color-border-danger-lightest-surface);background-color:rgb(var(--ax-sys-color-danger-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-danger-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__field-row.accent1{--axp-entity-styling-border: var(--ax-sys-color-border-accent1-lightest-surface);background-color:rgb(var(--ax-sys-color-accent1-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent1-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__field-row.accent2{--axp-entity-styling-border: var(--ax-sys-color-border-accent2-lightest-surface);background-color:rgb(var(--ax-sys-color-accent2-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent2-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.accent3,.axp-entity-card .axp-entity-card__field-row.accent3{--axp-entity-styling-border: var(--ax-sys-color-border-accent3-lightest-surface);background-color:rgb(var(--ax-sys-color-accent3-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent3-lightest-surface))}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__header-badge.accent3{border-radius:var(--radius-sm, .25rem);padding-inline:var(--spacing, .25rem)}.axp-entity-card .axp-entity-card__field-row{display:flex;width:100%;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__field-label{display:inline-flex;min-width:0px;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);text-align:start;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__field-value{margin-inline-start:auto;max-width:60%;min-width:0px;overflow:hidden;text-align:start;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);overflow-wrap:break-word;color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;width:100%;max-width:100%;min-width:0px;overflow:hidden;text-align:start;overflow-wrap:break-word}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell *{text-align:start}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell .flex{justify-content:flex-start}.axp-entity-card .axp-entity-card__field-value :is(.truncate,.whitespace-nowrap){max-width:100%;min-width:0px;overflow-wrap:break-word;white-space:normal;overflow:visible;text-overflow:unset}:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-label,:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-value{color:inherit}.axp-entity-card .axp-entity-card__field-icon{flex-shrink:0;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:var(--color-gray-400, oklch(70.7% .022 261.325))}.axp-entity-card .axp-entity-card__footer{margin-top:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 2);border-top-style:var(--tw-border-style);border-top-width:1px;padding-block:calc(var(--spacing, .25rem) * 2.5);padding-inline:var(--axp-entity-card-gutter);border-top-color:var(--axp-entity-card-border);background-color:var(--axp-entity-card-surface)}.axp-entity-card .axp-entity-card__footer-actions{margin-inline-start:auto;display:flex;min-width:0px;align-items:center;justify-content:flex-end;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__primary-action{min-width:0px}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact):not(.axp-entity-card--embedded) .axp-entity-card__identity{padding-block:calc(var(--spacing, .25rem) * 2.5)}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact) .axp-entity-card__title{font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)))}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact).axp-entity-card--expandable.axp-entity-card--expanded .axp-entity-card__identity{padding-bottom:calc(var(--spacing, .25rem) * 2.5)}:host.axp-entity-card-host--fill .axp-entity-card{display:flex;width:100%;min-height:0;flex:1 1 auto;flex-direction:column}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-outline-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@property --tw-leading{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000;--tw-outline-style: solid;--tw-font-weight: initial;--tw-leading: initial}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: AXBadgeModule }, { kind: "component", type: i2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: i1.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i1.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXCheckBoxModule }, { kind: "component", type: i4.AXCheckBoxComponent, selector: "ax-check-box", inputs: ["disabled", "tabIndex", "readonly", "color", "value", "name", "id", "isLoading", "indeterminate"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "component", type: i6.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "placement", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPUserAvatarComponent, selector: "axp-user-avatar", inputs: ["size", "userId", "showPresence", "displayName", "displayAvatar"] }, { kind: "directive", type: AXPUserCardDirective, selector: "[axpUserCard]", inputs: ["axpUserCard", "axpUserCardDisabled", "axpUserCardTrigger"] }, { kind: "component", type: AXPWidgetColumnCellComponent, selector: "axp-widget-column-cell", inputs: ["node", "rowData", "caption"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
7982
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPEntityCardComponent, isStandalone: true, selector: "axp-entity-card", inputs: { entity: { classPropertyName: "entity", publicName: "entity", isSignal: true, isRequired: true, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null }, userStylingRules: { classPropertyName: "userStylingRules", publicName: "userStylingRules", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, interactive: { classPropertyName: "interactive", publicName: "interactive", isSignal: true, isRequired: false, transformFunction: null }, embedded: { classPropertyName: "embedded", publicName: "embedded", isSignal: true, isRequired: false, transformFunction: null }, elevated: { classPropertyName: "elevated", publicName: "elevated", isSignal: true, isRequired: false, transformFunction: null }, disableLookupPopover: { classPropertyName: "disableLookupPopover", publicName: "disableLookupPopover", isSignal: true, isRequired: false, transformFunction: null }, fillHost: { classPropertyName: "fillHost", publicName: "fillHost", isSignal: true, isRequired: false, transformFunction: null }, extraExpanded: { classPropertyName: "extraExpanded", publicName: "extraExpanded", isSignal: true, isRequired: false, transformFunction: null }, selected: { classPropertyName: "selected", publicName: "selected", isSignal: true, isRequired: false, transformFunction: null }, showNewBadge: { classPropertyName: "showNewBadge", publicName: "showNewBadge", isSignal: true, isRequired: false, transformFunction: null }, showSelection: { classPropertyName: "showSelection", publicName: "showSelection", isSignal: true, isRequired: false, transformFunction: null }, showClose: { classPropertyName: "showClose", publicName: "showClose", isSignal: true, isRequired: false, transformFunction: null }, primaryActions: { classPropertyName: "primaryActions", publicName: "primaryActions", isSignal: true, isRequired: false, transformFunction: null }, primaryActionLook: { classPropertyName: "primaryActionLook", publicName: "primaryActionLook", isSignal: true, isRequired: false, transformFunction: null }, secondaryActionLoader: { classPropertyName: "secondaryActionLoader", publicName: "secondaryActionLoader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { extraExpanded: "extraExpandedChange", selectionChange: "selectionChange", commandClick: "commandClick", closeClick: "closeClick" }, host: { properties: { "class.axp-entity-card-host--fill": "fillHost()", "class.axp-entity-card-host--elevated": "elevated()" } }, ngImport: i0, template: "<article\n class=\"axp-entity-card\"\n [ngClass]=\"recordStylingClass()\"\n [class.axp-entity-card--selected]=\"selected()\"\n [class.axp-entity-card--new]=\"showNewBadge()\"\n [class.axp-entity-card--row]=\"isRowLayout()\"\n [class.axp-entity-card--compact]=\"variant() === 'compact'\"\n [class.axp-entity-card--embedded]=\"embedded()\"\n [class.axp-entity-card--elevated]=\"elevated()\"\n [class.axp-entity-card--static]=\"!interactive()\"\n [class.axp-entity-card--with-body]=\"hasCardBody()\"\n [class.axp-entity-card--with-footer]=\"hasCardFooter()\"\n [class.axp-entity-card--expandable]=\"canShowMore()\"\n [class.axp-entity-card--expanded]=\"extraExpanded()\"\n [attr.role]=\"interactive() ? 'button' : undefined\"\n [attr.tabindex]=\"interactive() ? 0 : undefined\"\n [attr.aria-selected]=\"interactive() ? selected() : undefined\"\n (click)=\"onCardClick($event)\"\n (dblclick)=\"onCardDblClick($event)\"\n (keydown)=\"onCardKeydown($event)\"\n>\n <div class=\"axp-entity-card__content\">\n <!-- ----- Identity row: optional avatar, title, status, and actions ----- -->\n <div class=\"axp-entity-card__identity\">\n <div class=\"axp-entity-card__identity-main\">\n @if (showUserAvatar()) {\n <!-- ----- Person or user identity uses the user avatar ----- -->\n <axp-user-avatar class=\"axp-entity-card__avatar\" [size]=\"avatarSize()\" [userId]=\"userAvatarId()\" [displayName]=\"toDisplayName(titleText())\" [displayAvatar]=\"avatarSrc()\" [showPresence]=\"false\" [axpUserCard]=\"userAvatarId()\" />\n }\n <!--------------------------------------------------------------->\n @if (showIdentityImage()) {\n <!-- ----- Logo or company image for entities that store an image/logo ----- -->\n <div class=\"axp-entity-card__logo\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <img [src]=\"avatarSrc()\" [alt]=\"toDisplayName(titleText())\" />\n </div>\n }\n <!--------------------------------------------------------------->\n @if (identityQrField(); as field) {\n <!-- ----- QR widget occupies the identity visual slot when there is no avatar or logo ----- -->\n <div class=\"axp-entity-card__qr\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n\n <div class=\"axp-entity-card__identity-text\">\n <div class=\"axp-entity-card__title-row\">\n @if (iconClass(); as icon) {\n <!-- ----- Optional header icon from the card layout ----- -->\n <i [class]=\"icon + ' axp-entity-card__icon'\" aria-hidden=\"true\"></i>\n }\n\n <h3 class=\"axp-entity-card__title\">\n {{ titleText() | translate | async }}\n </h3>\n\n @if (showNewBadge()) {\n <!-- ----- New-row highlight badge ----- -->\n <ax-badge class=\"axp-entity-card__header-badge\" [text]=\"('@acorex:dataTable.rowHighlight.new' | translate | async) || ''\" color=\"success\" />\n }\n\n @for (field of headerBadgeFields(); track field.name) {\n <!--------------------------------------------------------------->\n @if (isStatusBadgeField(field)) {\n <!-- ----- Status widget rendered in the header ----- -->\n <div class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldHeaderBadgeNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n <!-- ----- Non-status field rendered as a simple badge ----- -->\n @else if (resolveBadgeText(field)) {\n <ax-badge class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\" [text]=\"resolveBadgeText(field)\" [color]=\"resolveBadgeColor(field)\" />\n }\n }\n </div>\n\n @if (descriptionText()) {\n <!-- ----- Optional description under the title ----- -->\n <p class=\"axp-entity-card__description\">\n {{ descriptionText() | translate | async }}\n </p>\n }\n\n @if (headerMetaFields().length) {\n <!-- ----- Unlabeled header extra (identifier or contact) ----- -->\n <div class=\"axp-entity-card__facts axp-entity-card__facts--inline\">\n @for (field of headerMetaFields(); track field.name) {\n <div class=\"axp-entity-card__fact\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n </div>\n }\n </div>\n </div>\n\n @if (hasIdentityActions()) {\n <!-- ----- Selection, overflow actions, or popover dismiss ----- -->\n <div class=\"axp-entity-card__identity-actions\">\n @if (showSelection()) {\n <!-- ----- Multi-select checkbox ----- -->\n <ax-check-box class=\"axp-entity-card__select-checkbox\" [value]=\"selected()\" (onValueChanged)=\"onSelectionCheckboxChange($event)\" (click)=\"onSelectionCheckboxClick($event)\" />\n }\n <!-- ----- Row actions menu when the card is not in selection mode ----- -->\n @else if (secondaryActions().length) {\n <ax-button [look]=\"'blank'\" [color]=\"'default'\" class=\"ax-sm\" (onClick)=\"stopClickPropagation($event)\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis\" aria-hidden=\"true\"></i>\n </ax-prefix>\n\n <ax-dropdown-panel #panel>\n <ax-button-item-list>\n @for (item of secondaryActions(); track $index) {\n @if (item.divided) {\n <!-- ----- Divider before this overflow action ----- -->\n <ax-divider />\n }\n <ax-button-item [text]=\"(item.title | translate | async)!\" [color]=\"item.color\" [disabled]=\"item.disabled\" (onClick)=\"onSecondaryActionClick(item, $event)\">\n @if (item.icon) {\n <!-- ----- Overflow action icon ----- -->\n <ax-prefix>\n <ax-icon icon=\"fa-light {{ item.icon }}\"></ax-icon>\n </ax-prefix>\n }\n </ax-button-item>\n }\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n }\n <!-- ----- Close when hosted as a lookup / detail popover ----- -->\n @if (showClose()) {\n <ax-button\n class=\"axp-entity-card__close ax-sm\"\n [look]=\"'blank'\"\n [color]=\"'default'\"\n [iconOnly]=\"true\"\n [attr.title]=\"'@general:actions.close.title' | translate | async\"\n [attr.aria-label]=\"'@general:actions.close.title' | translate | async\"\n (onClick)=\"onCloseClick($event)\"\n >\n <i class=\"fa-light fa-xmark\" aria-hidden=\"true\"></i>\n </ax-button>\n }\n </div>\n }\n </div>\n\n @if (hasLabeledBody()) {\n <!-- ----- Divider between unlabeled identity header and labeled body facts ----- -->\n <div class=\"axp-entity-card__divider\"></div>\n <div class=\"axp-entity-card__body\">\n <div class=\"axp-entity-card__fields\">\n @for (field of previewFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n <!--------------------------------------------------------------->\n @if (extraFields().length) {\n <!-- ----- Extra fields stay mounted; collapse hides them without a body fade ----- -->\n <div class=\"axp-entity-card__extra\" [class.axp-entity-card__extra--collapsed]=\"!extraExpanded()\">\n @for (field of extraFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n\n @if (showInlineMore()) {\n <!-- ----- Quiet More/Less under the fields when the card has no action footer ----- -->\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--inline\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n </div>\n\n @if (hasCardFooter()) {\n <!-- ----- One footer row: optional More on the left, primary actions on the right ----- -->\n <footer class=\"axp-entity-card__footer\">\n <!-- ----- More/Less shares the footer with the action button ----- -->\n @if (showFooterMore()) {\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--footer\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n <div class=\"axp-entity-card__footer-actions\">\n @for (action of primaryActions(); track $index) {\n <ax-button\n class=\"axp-entity-card__primary-action ax-sm\"\n [look]=\"primaryActionLook()\"\n [color]=\"action.color\"\n [disabled]=\"action.disabled\"\n [text]=\"(action.title | translate | async)!\"\n (onClick)=\"onPrimaryActionClick(action.name, $event)\"\n >\n @if (action.icon) {\n <!-- ----- Primary action icon ----- -->\n <ax-prefix>\n <i class=\"fa-light {{ action.icon }}\"></i>\n </ax-prefix>\n }\n </ax-button>\n }\n </div>\n </footer>\n }\n</article>\n", styles: ["@layer properties;:host{display:block;width:100%;min-width:0px}:host.axp-entity-card-host--fill{display:flex;width:100%;min-width:0;flex:1 1 auto;flex-direction:column}:host.axp-entity-card-host--elevated{border-radius:var(--radius-md, .375rem);box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-card{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));--axp-entity-card-border: rgb(var(--ax-sys-color-border-light-surface));--axp-entity-card-gutter: 1rem;position:relative;display:flex;width:100%;flex-direction:column;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / .05));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);transition-property:box-shadow;transition-timing-function:var(--tw-ease, var(--default-transition-timing-function, cubic-bezier(.4, 0, .2, 1)));transition-duration:var(--tw-duration, var(--default-transition-duration, .15s));background-color:var(--axp-entity-card-surface);border-color:var(--axp-entity-card-border)}.axp-entity-card:hover{--tw-shadow: 0 4px 6px -1px var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 2px 4px -2px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card.axp-entity-card--selected{border-color:rgba(var(--ax-sys-color-primary-500));--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);box-shadow:0 0 0 1px rgb(var(--ax-sys-color-primary-500) / .25),0 2px 6px #0000000f}.axp-entity-card.axp-entity-card--new{border-color:rgb(var(--ax-sys-color-border-success-surface));box-shadow:0 0 0 1px rgb(var(--ax-sys-color-success-500) / .2)}.axp-entity-card.primary{--axp-entity-card-surface: rgb(var(--ax-sys-color-primary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-primary-lightest-surface))}.axp-entity-card.secondary{--axp-entity-card-surface: rgb(var(--ax-sys-color-secondary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-secondary-lightest-surface))}.axp-entity-card.success{--axp-entity-card-surface: rgb(var(--ax-sys-color-success-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-success-lightest-surface))}.axp-entity-card.warning{--axp-entity-card-surface: rgb(var(--ax-sys-color-warning-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-warning-lightest-surface))}.axp-entity-card.danger{--axp-entity-card-surface: rgb(var(--ax-sys-color-danger-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-danger-lightest-surface))}.axp-entity-card.accent1{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent1-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent1-lightest-surface))}.axp-entity-card.accent2{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent2-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent2-lightest-surface))}.axp-entity-card.accent3{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent3-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent3-lightest-surface))}.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3{background-color:var(--axp-entity-card-surface)}:is(.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3) .axp-entity-card__footer{background-color:transparent}.axp-entity-card:not(.axp-entity-card--static){cursor:pointer}.axp-entity-card.axp-entity-card--static{cursor:default}.axp-entity-card.axp-entity-card--elevated{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));background-color:rgb(var(--ax-sys-color-lightest-surface));--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated .axp-entity-card__footer{background-color:rgb(var(--ax-sys-color-lightest-surface))}.axp-entity-card.axp-entity-card--embedded{border-radius:0;border-style:var(--tw-border-style);border-width:0px;--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);--axp-entity-card-surface: transparent;background-color:transparent}.axp-entity-card.axp-entity-card--embedded:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__identity{padding-inline:0px;padding-block:0px}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__fields{padding-inline:0px;padding-top:calc(var(--spacing, .25rem) * 2);padding-bottom:0}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__divider{margin-inline:0px}.axp-entity-card .axp-entity-card__identity{display:flex;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__identity-main{display:flex;min-width:0px;flex:1;align-items:flex-start;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__avatar{flex-shrink:0}.axp-entity-card .axp-entity-card__logo{flex-shrink:0;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-surface))}.axp-entity-card .axp-entity-card__logo img{width:100%;height:100%;object-fit:contain}.axp-entity-card .axp-entity-card__qr{display:flex;flex-shrink:0;align-items:center;justify-content:center;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__qr axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__identity-text{display:flex;min-width:0px;flex:1;flex-direction:column;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__title-row{display:flex;min-width:0px;flex-wrap:wrap;align-items:center;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__select-checkbox,.axp-entity-card .axp-entity-card__header-badge{flex-shrink:0}.axp-entity-card .axp-entity-card__identity-actions{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__close{margin-inline-end:calc(var(--spacing, .25rem) * -1);margin-top:calc(var(--spacing, .25rem) * -.5)}.axp-entity-card .axp-entity-card__content{position:relative;flex:1}.axp-entity-card .axp-entity-card__more{display:inline-flex;min-height:calc(var(--spacing, .25rem) * 8);flex-shrink:0;cursor:pointer;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding-inline:var(--spacing, .25rem);font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-font-weight: var(--font-weight-medium, 500);font-weight:var(--font-weight-medium, 500);color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__more span,.axp-entity-card .axp-entity-card__more i{pointer-events:none}.axp-entity-card .axp-entity-card__more i{font-size:10px;--tw-leading: 1;line-height:1}.axp-entity-card .axp-entity-card__more:hover,.axp-entity-card .axp-entity-card__more:focus-visible{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__more:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card .axp-entity-card__more--footer{margin-block:calc(var(--spacing, .25rem) * -2.5);margin-inline-start:calc(var(--spacing, .25rem) * -1);min-height:calc(var(--spacing, .25rem) * 10);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__more--inline{margin-inline:var(--axp-entity-card-gutter);margin-top:calc(var(--spacing, .25rem) * .5);margin-bottom:calc(var(--spacing, .25rem) * 2);padding-inline:var(--spacing, .25rem);padding-block:calc(var(--spacing, .25rem) * 2)}.axp-entity-card.axp-entity-card--expanded .axp-entity-card__more{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__title{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));--tw-leading: var(--leading-relaxed, 1.625);line-height:var(--leading-relaxed, 1.625);--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}.axp-entity-card .axp-entity-card__icon{flex-shrink:0;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__description{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);opacity:65%}.axp-entity-card .axp-entity-card__facts{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-bottom:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__facts--inline{flex-direction:row;flex-wrap:wrap;align-items:center;column-gap:calc(var(--spacing, .25rem) * 4);row-gap:var(--spacing, .25rem);padding-inline:0px;padding-block:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__fact{min-width:0px;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__fact axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__divider{margin-inline:var(--axp-entity-card-gutter);border-top:1px solid var(--axp-entity-card-border)}.axp-entity-card .axp-entity-card__body{position:relative;overflow:hidden}.axp-entity-card .axp-entity-card__extra{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__extra--collapsed{display:none}.axp-entity-card .axp-entity-card__fields{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3{width:auto;margin-inline:calc(-1 * var(--axp-entity-card-gutter));padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__field-row.primary{--axp-entity-styling-border: var(--ax-sys-color-border-primary-lightest-surface);background-color:rgb(var(--ax-sys-color-primary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-primary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__field-row.secondary{--axp-entity-styling-border: var(--ax-sys-color-border-secondary-lightest-surface);background-color:rgb(var(--ax-sys-color-secondary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-secondary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__field-row.success{--axp-entity-styling-border: var(--ax-sys-color-border-success-lightest-surface);background-color:rgb(var(--ax-sys-color-success-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-success-lightest-surface))}.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__field-row.warning{--axp-entity-styling-border: var(--ax-sys-color-border-warning-lightest-surface);background-color:rgb(var(--ax-sys-color-warning-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-warning-lightest-surface))}.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__field-row.danger{--axp-entity-styling-border: var(--ax-sys-color-border-danger-lightest-surface);background-color:rgb(var(--ax-sys-color-danger-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-danger-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__field-row.accent1{--axp-entity-styling-border: var(--ax-sys-color-border-accent1-lightest-surface);background-color:rgb(var(--ax-sys-color-accent1-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent1-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__field-row.accent2{--axp-entity-styling-border: var(--ax-sys-color-border-accent2-lightest-surface);background-color:rgb(var(--ax-sys-color-accent2-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent2-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.accent3,.axp-entity-card .axp-entity-card__field-row.accent3{--axp-entity-styling-border: var(--ax-sys-color-border-accent3-lightest-surface);background-color:rgb(var(--ax-sys-color-accent3-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent3-lightest-surface))}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__header-badge.accent3{border-radius:var(--radius-sm, .25rem);padding-inline:var(--spacing, .25rem)}.axp-entity-card .axp-entity-card__field-row{display:flex;width:100%;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__field-label{display:inline-flex;min-width:0px;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);text-align:start;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__field-value{margin-inline-start:auto;max-width:60%;min-width:0px;overflow:hidden;text-align:start;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);overflow-wrap:break-word;color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;width:100%;max-width:100%;min-width:0px;overflow:hidden;text-align:start;overflow-wrap:break-word}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell *{text-align:start}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell .flex{justify-content:flex-start}.axp-entity-card .axp-entity-card__field-value :is(.truncate,.whitespace-nowrap){max-width:100%;min-width:0px;overflow-wrap:break-word;white-space:normal;overflow:visible;text-overflow:unset}:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-label,:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-value{color:inherit}.axp-entity-card .axp-entity-card__field-icon{flex-shrink:0;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:var(--color-gray-400, oklch(70.7% .022 261.325))}.axp-entity-card .axp-entity-card__footer{margin-top:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 2);border-top-style:var(--tw-border-style);border-top-width:1px;padding-block:calc(var(--spacing, .25rem) * 2.5);padding-inline:var(--axp-entity-card-gutter);border-top-color:var(--axp-entity-card-border);background-color:var(--axp-entity-card-surface)}.axp-entity-card .axp-entity-card__footer-actions{margin-inline-start:auto;display:flex;min-width:0px;align-items:center;justify-content:flex-end;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__primary-action{min-width:0px}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact):not(.axp-entity-card--embedded) .axp-entity-card__identity{padding-block:calc(var(--spacing, .25rem) * 2.5)}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact) .axp-entity-card__title{font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)))}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact).axp-entity-card--expandable.axp-entity-card--expanded .axp-entity-card__identity{padding-bottom:calc(var(--spacing, .25rem) * 2.5)}:host.axp-entity-card-host--fill .axp-entity-card{display:flex;width:100%;min-height:0;flex:1 1 auto;flex-direction:column}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-outline-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@property --tw-leading{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000;--tw-outline-style: solid;--tw-font-weight: initial;--tw-leading: initial}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: AXBadgeModule }, { kind: "component", type: i2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: i1.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i1.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXCheckBoxModule }, { kind: "component", type: i4.AXCheckBoxComponent, selector: "ax-check-box", inputs: ["disabled", "tabIndex", "readonly", "color", "value", "name", "id", "isLoading", "indeterminate"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "component", type: i6.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "placement", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPUserAvatarComponent, selector: "axp-user-avatar", inputs: ["size", "userId", "showPresence", "displayName", "displayAvatar"] }, { kind: "directive", type: AXPUserCardDirective, selector: "[axpUserCard]", inputs: ["axpUserCard", "axpUserCardDisabled", "axpUserCardTrigger"] }, { kind: "component", type: AXPWidgetColumnCellComponent, selector: "axp-widget-column-cell", inputs: ["node", "rowData", "caption"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
7774
7983
|
}
|
|
7775
7984
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPEntityCardComponent, decorators: [{
|
|
7776
7985
|
type: Component,
|
|
@@ -7789,7 +7998,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
7789
7998
|
AXPUserCardDirective,
|
|
7790
7999
|
AXPWidgetColumnCellComponent,
|
|
7791
8000
|
], template: "<article\n class=\"axp-entity-card\"\n [ngClass]=\"recordStylingClass()\"\n [class.axp-entity-card--selected]=\"selected()\"\n [class.axp-entity-card--new]=\"showNewBadge()\"\n [class.axp-entity-card--row]=\"isRowLayout()\"\n [class.axp-entity-card--compact]=\"variant() === 'compact'\"\n [class.axp-entity-card--embedded]=\"embedded()\"\n [class.axp-entity-card--elevated]=\"elevated()\"\n [class.axp-entity-card--static]=\"!interactive()\"\n [class.axp-entity-card--with-body]=\"hasCardBody()\"\n [class.axp-entity-card--with-footer]=\"hasCardFooter()\"\n [class.axp-entity-card--expandable]=\"canShowMore()\"\n [class.axp-entity-card--expanded]=\"extraExpanded()\"\n [attr.role]=\"interactive() ? 'button' : undefined\"\n [attr.tabindex]=\"interactive() ? 0 : undefined\"\n [attr.aria-selected]=\"interactive() ? selected() : undefined\"\n (click)=\"onCardClick($event)\"\n (dblclick)=\"onCardDblClick($event)\"\n (keydown)=\"onCardKeydown($event)\"\n>\n <div class=\"axp-entity-card__content\">\n <!-- ----- Identity row: optional avatar, title, status, and actions ----- -->\n <div class=\"axp-entity-card__identity\">\n <div class=\"axp-entity-card__identity-main\">\n @if (showUserAvatar()) {\n <!-- ----- Person or user identity uses the user avatar ----- -->\n <axp-user-avatar class=\"axp-entity-card__avatar\" [size]=\"avatarSize()\" [userId]=\"userAvatarId()\" [displayName]=\"toDisplayName(titleText())\" [displayAvatar]=\"avatarSrc()\" [showPresence]=\"false\" [axpUserCard]=\"userAvatarId()\" />\n }\n <!--------------------------------------------------------------->\n @if (showIdentityImage()) {\n <!-- ----- Logo or company image for entities that store an image/logo ----- -->\n <div class=\"axp-entity-card__logo\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <img [src]=\"avatarSrc()\" [alt]=\"toDisplayName(titleText())\" />\n </div>\n }\n <!--------------------------------------------------------------->\n @if (identityQrField(); as field) {\n <!-- ----- QR widget occupies the identity visual slot when there is no avatar or logo ----- -->\n <div class=\"axp-entity-card__qr\" [style.width.px]=\"avatarSize()\" [style.height.px]=\"avatarSize()\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n\n <div class=\"axp-entity-card__identity-text\">\n <div class=\"axp-entity-card__title-row\">\n @if (iconClass(); as icon) {\n <!-- ----- Optional header icon from the card layout ----- -->\n <i [class]=\"icon + ' axp-entity-card__icon'\" aria-hidden=\"true\"></i>\n }\n\n <h3 class=\"axp-entity-card__title\">\n {{ titleText() | translate | async }}\n </h3>\n\n @if (showNewBadge()) {\n <!-- ----- New-row highlight badge ----- -->\n <ax-badge class=\"axp-entity-card__header-badge\" [text]=\"('@acorex:dataTable.rowHighlight.new' | translate | async) || ''\" color=\"success\" />\n }\n\n @for (field of headerBadgeFields(); track field.name) {\n <!--------------------------------------------------------------->\n @if (isStatusBadgeField(field)) {\n <!-- ----- Status widget rendered in the header ----- -->\n <div class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldHeaderBadgeNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n <!-- ----- Non-status field rendered as a simple badge ----- -->\n @else if (resolveBadgeText(field)) {\n <ax-badge class=\"axp-entity-card__header-badge\" [ngClass]=\"fieldStylingClass(field.name)\" [text]=\"resolveBadgeText(field)\" [color]=\"resolveBadgeColor(field)\" />\n }\n }\n </div>\n\n @if (descriptionText()) {\n <!-- ----- Optional description under the title ----- -->\n <p class=\"axp-entity-card__description\">\n {{ descriptionText() | translate | async }}\n </p>\n }\n\n @if (headerMetaFields().length) {\n <!-- ----- Unlabeled header extra (identifier or contact) ----- -->\n <div class=\"axp-entity-card__facts axp-entity-card__facts--inline\">\n @for (field of headerMetaFields(); track field.name) {\n <div class=\"axp-entity-card__fact\" [ngClass]=\"fieldStylingClass(field.name)\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n }\n </div>\n }\n </div>\n </div>\n\n @if (hasIdentityActions()) {\n <!-- ----- Selection, overflow actions, or popover dismiss ----- -->\n <div class=\"axp-entity-card__identity-actions\">\n @if (showSelection()) {\n <!-- ----- Multi-select checkbox ----- -->\n <ax-check-box class=\"axp-entity-card__select-checkbox\" [value]=\"selected()\" (onValueChanged)=\"onSelectionCheckboxChange($event)\" (click)=\"onSelectionCheckboxClick($event)\" />\n }\n <!-- ----- Row actions menu when the card is not in selection mode ----- -->\n @else if (secondaryActions().length) {\n <ax-button [look]=\"'blank'\" [color]=\"'default'\" class=\"ax-sm\" (onClick)=\"stopClickPropagation($event)\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis\" aria-hidden=\"true\"></i>\n </ax-prefix>\n\n <ax-dropdown-panel #panel>\n <ax-button-item-list>\n @for (item of secondaryActions(); track $index) {\n @if (item.divided) {\n <!-- ----- Divider before this overflow action ----- -->\n <ax-divider />\n }\n <ax-button-item [text]=\"(item.title | translate | async)!\" [color]=\"item.color\" [disabled]=\"item.disabled\" (onClick)=\"onSecondaryActionClick(item, $event)\">\n @if (item.icon) {\n <!-- ----- Overflow action icon ----- -->\n <ax-prefix>\n <ax-icon icon=\"fa-light {{ item.icon }}\"></ax-icon>\n </ax-prefix>\n }\n </ax-button-item>\n }\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n }\n <!-- ----- Close when hosted as a lookup / detail popover ----- -->\n @if (showClose()) {\n <ax-button\n class=\"axp-entity-card__close ax-sm\"\n [look]=\"'blank'\"\n [color]=\"'default'\"\n [iconOnly]=\"true\"\n [attr.title]=\"'@general:actions.close.title' | translate | async\"\n [attr.aria-label]=\"'@general:actions.close.title' | translate | async\"\n (onClick)=\"onCloseClick($event)\"\n >\n <i class=\"fa-light fa-xmark\" aria-hidden=\"true\"></i>\n </ax-button>\n }\n </div>\n }\n </div>\n\n @if (hasLabeledBody()) {\n <!-- ----- Divider between unlabeled identity header and labeled body facts ----- -->\n <div class=\"axp-entity-card__divider\"></div>\n <div class=\"axp-entity-card__body\">\n <div class=\"axp-entity-card__fields\">\n @for (field of previewFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n <!--------------------------------------------------------------->\n @if (extraFields().length) {\n <!-- ----- Extra fields stay mounted; collapse hides them without a body fade ----- -->\n <div class=\"axp-entity-card__extra\" [class.axp-entity-card__extra--collapsed]=\"!extraExpanded()\">\n @for (field of extraFields(); track field.name) {\n <div class=\"axp-entity-card__field-row\" [ngClass]=\"fieldStylingClass(field.name)\">\n <span class=\"axp-entity-card__field-label\">\n @if (resolveFieldIcon(field); as icon) {\n <!-- ----- Field icon from lookup entity or widget definition ----- -->\n <i class=\"axp-entity-card__field-icon {{ icon }}\" aria-hidden=\"true\"></i>\n }\n {{ field.title | translate | async }}\n </span>\n <div class=\"axp-entity-card__field-value\">\n <axp-widget-column-cell [node]=\"fieldColumnNode(field)\" [rowData]=\"row()\" [caption]=\"field.title\" />\n </div>\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n\n @if (showInlineMore()) {\n <!-- ----- Quiet More/Less under the fields when the card has no action footer ----- -->\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--inline\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n </div>\n\n @if (hasCardFooter()) {\n <!-- ----- One footer row: optional More on the left, primary actions on the right ----- -->\n <footer class=\"axp-entity-card__footer\">\n <!-- ----- More/Less shares the footer with the action button ----- -->\n @if (showFooterMore()) {\n <button type=\"button\" class=\"axp-entity-card__more axp-entity-card__more--footer\" [attr.aria-expanded]=\"extraExpanded()\" (click)=\"onToggleExtra($event)\">\n <span>\n {{ (extraExpanded() ? '@general:terms.interface.less-card' : '@general:terms.interface.more-card') | translate | async }}\n </span>\n <i class=\"fa-light\" [class.fa-chevron-down]=\"!extraExpanded()\" [class.fa-chevron-up]=\"extraExpanded()\" aria-hidden=\"true\"></i>\n </button>\n }\n <div class=\"axp-entity-card__footer-actions\">\n @for (action of primaryActions(); track $index) {\n <ax-button\n class=\"axp-entity-card__primary-action ax-sm\"\n [look]=\"primaryActionLook()\"\n [color]=\"action.color\"\n [disabled]=\"action.disabled\"\n [text]=\"(action.title | translate | async)!\"\n (onClick)=\"onPrimaryActionClick(action.name, $event)\"\n >\n @if (action.icon) {\n <!-- ----- Primary action icon ----- -->\n <ax-prefix>\n <i class=\"fa-light {{ action.icon }}\"></i>\n </ax-prefix>\n }\n </ax-button>\n }\n </div>\n </footer>\n }\n</article>\n", styles: ["@layer properties;:host{display:block;width:100%;min-width:0px}:host.axp-entity-card-host--fill{display:flex;width:100%;min-width:0;flex:1 1 auto;flex-direction:column}:host.axp-entity-card-host--elevated{border-radius:var(--radius-md, .375rem);box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-card{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));--axp-entity-card-border: rgb(var(--ax-sys-color-border-light-surface));--axp-entity-card-gutter: 1rem;position:relative;display:flex;width:100%;flex-direction:column;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / .05));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);transition-property:box-shadow;transition-timing-function:var(--tw-ease, var(--default-transition-timing-function, cubic-bezier(.4, 0, .2, 1)));transition-duration:var(--tw-duration, var(--default-transition-duration, .15s));background-color:var(--axp-entity-card-surface);border-color:var(--axp-entity-card-border)}.axp-entity-card:hover{--tw-shadow: 0 4px 6px -1px var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 2px 4px -2px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card.axp-entity-card--selected{border-color:rgba(var(--ax-sys-color-primary-500));--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);box-shadow:0 0 0 1px rgb(var(--ax-sys-color-primary-500) / .25),0 2px 6px #0000000f}.axp-entity-card.axp-entity-card--new{border-color:rgb(var(--ax-sys-color-border-success-surface));box-shadow:0 0 0 1px rgb(var(--ax-sys-color-success-500) / .2)}.axp-entity-card.primary{--axp-entity-card-surface: rgb(var(--ax-sys-color-primary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-primary-lightest-surface))}.axp-entity-card.secondary{--axp-entity-card-surface: rgb(var(--ax-sys-color-secondary-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-secondary-lightest-surface))}.axp-entity-card.success{--axp-entity-card-surface: rgb(var(--ax-sys-color-success-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-success-lightest-surface))}.axp-entity-card.warning{--axp-entity-card-surface: rgb(var(--ax-sys-color-warning-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-warning-lightest-surface))}.axp-entity-card.danger{--axp-entity-card-surface: rgb(var(--ax-sys-color-danger-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-danger-lightest-surface))}.axp-entity-card.accent1{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent1-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent1-lightest-surface))}.axp-entity-card.accent2{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent2-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent2-lightest-surface))}.axp-entity-card.accent3{--axp-entity-card-surface: rgb(var(--ax-sys-color-accent3-50));--axp-entity-card-border: rgb(var(--ax-sys-color-border-accent3-lightest-surface))}.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3{background-color:var(--axp-entity-card-surface)}:is(.axp-entity-card.primary,.axp-entity-card.secondary,.axp-entity-card.success,.axp-entity-card.warning,.axp-entity-card.danger,.axp-entity-card.accent1,.axp-entity-card.accent2,.axp-entity-card.accent3) .axp-entity-card__footer{background-color:transparent}.axp-entity-card:not(.axp-entity-card--static){cursor:pointer}.axp-entity-card.axp-entity-card--static{cursor:default}.axp-entity-card.axp-entity-card--elevated{--axp-entity-card-surface: rgb(var(--ax-sys-color-lightest-surface));background-color:rgb(var(--ax-sys-color-lightest-surface));--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--elevated .axp-entity-card__footer{background-color:rgb(var(--ax-sys-color-lightest-surface))}.axp-entity-card.axp-entity-card--embedded{border-radius:0;border-style:var(--tw-border-style);border-width:0px;--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);--axp-entity-card-surface: transparent;background-color:transparent}.axp-entity-card.axp-entity-card--embedded:hover{--tw-shadow: 0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__identity{padding-inline:0px;padding-block:0px}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__fields{padding-inline:0px;padding-top:calc(var(--spacing, .25rem) * 2);padding-bottom:0}.axp-entity-card.axp-entity-card--embedded .axp-entity-card__divider{margin-inline:0px}.axp-entity-card .axp-entity-card__identity{display:flex;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__identity-main{display:flex;min-width:0px;flex:1;align-items:flex-start;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__avatar{flex-shrink:0}.axp-entity-card .axp-entity-card__logo{flex-shrink:0;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-surface))}.axp-entity-card .axp-entity-card__logo img{width:100%;height:100%;object-fit:contain}.axp-entity-card .axp-entity-card__qr{display:flex;flex-shrink:0;align-items:center;justify-content:center;overflow:hidden;border-radius:var(--radius-md, .375rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-light-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__qr axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__identity-text{display:flex;min-width:0px;flex:1;flex-direction:column;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__title-row{display:flex;min-width:0px;flex-wrap:wrap;align-items:center;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__select-checkbox,.axp-entity-card .axp-entity-card__header-badge{flex-shrink:0}.axp-entity-card .axp-entity-card__identity-actions{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__close{margin-inline-end:calc(var(--spacing, .25rem) * -1);margin-top:calc(var(--spacing, .25rem) * -.5)}.axp-entity-card .axp-entity-card__content{position:relative;flex:1}.axp-entity-card .axp-entity-card__more{display:inline-flex;min-height:calc(var(--spacing, .25rem) * 8);flex-shrink:0;cursor:pointer;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding-inline:var(--spacing, .25rem);font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-font-weight: var(--font-weight-medium, 500);font-weight:var(--font-weight-medium, 500);color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__more span,.axp-entity-card .axp-entity-card__more i{pointer-events:none}.axp-entity-card .axp-entity-card__more i{font-size:10px;--tw-leading: 1;line-height:1}.axp-entity-card .axp-entity-card__more:hover,.axp-entity-card .axp-entity-card__more:focus-visible{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__more:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px;outline-offset:2px;outline-color:rgba(var(--ax-sys-color-primary-500))}.axp-entity-card .axp-entity-card__more--footer{margin-block:calc(var(--spacing, .25rem) * -2.5);margin-inline-start:calc(var(--spacing, .25rem) * -1);min-height:calc(var(--spacing, .25rem) * 10);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__more--inline{margin-inline:var(--axp-entity-card-gutter);margin-top:calc(var(--spacing, .25rem) * .5);margin-bottom:calc(var(--spacing, .25rem) * 2);padding-inline:var(--spacing, .25rem);padding-block:calc(var(--spacing, .25rem) * 2)}.axp-entity-card.axp-entity-card--expanded .axp-entity-card__more{color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__title{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));--tw-leading: var(--leading-relaxed, 1.625);line-height:var(--leading-relaxed, 1.625);--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}.axp-entity-card .axp-entity-card__icon{flex-shrink:0;font-size:var(--text-base, 1rem);line-height:var(--tw-leading, var(--text-base--line-height, 1.5 ));color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__description{min-width:0px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);opacity:65%}.axp-entity-card .axp-entity-card__facts{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-bottom:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__facts--inline{flex-direction:row;flex-wrap:wrap;align-items:center;column-gap:calc(var(--spacing, .25rem) * 4);row-gap:var(--spacing, .25rem);padding-inline:0px;padding-block:calc(var(--spacing, .25rem) * .5)}.axp-entity-card .axp-entity-card__fact{min-width:0px;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));color:rgba(var(--ax-sys-color-on-lightest-surface))}.axp-entity-card .axp-entity-card__fact axp-widget-column-cell{display:block;max-width:100%}.axp-entity-card .axp-entity-card__divider{margin-inline:var(--axp-entity-card-gutter);border-top:1px solid var(--axp-entity-card-border)}.axp-entity-card .axp-entity-card__body{position:relative;overflow:hidden}.axp-entity-card .axp-entity-card__extra{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__extra--collapsed{display:none}.axp-entity-card .axp-entity-card__fields{display:flex;flex-direction:column;gap:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 3);padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3{width:auto;margin-inline:calc(-1 * var(--axp-entity-card-gutter));padding-inline:var(--axp-entity-card-gutter)}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__field-row.primary{--axp-entity-styling-border: var(--ax-sys-color-border-primary-lightest-surface);background-color:rgb(var(--ax-sys-color-primary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-primary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__field-row.secondary{--axp-entity-styling-border: var(--ax-sys-color-border-secondary-lightest-surface);background-color:rgb(var(--ax-sys-color-secondary-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-secondary-lightest-surface))}.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__field-row.success{--axp-entity-styling-border: var(--ax-sys-color-border-success-lightest-surface);background-color:rgb(var(--ax-sys-color-success-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-success-lightest-surface))}.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__field-row.warning{--axp-entity-styling-border: var(--ax-sys-color-border-warning-lightest-surface);background-color:rgb(var(--ax-sys-color-warning-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-warning-lightest-surface))}.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__field-row.danger{--axp-entity-styling-border: var(--ax-sys-color-border-danger-lightest-surface);background-color:rgb(var(--ax-sys-color-danger-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-danger-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__field-row.accent1{--axp-entity-styling-border: var(--ax-sys-color-border-accent1-lightest-surface);background-color:rgb(var(--ax-sys-color-accent1-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent1-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__field-row.accent2{--axp-entity-styling-border: var(--ax-sys-color-border-accent2-lightest-surface);background-color:rgb(var(--ax-sys-color-accent2-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent2-lightest-surface))}.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.accent3,.axp-entity-card .axp-entity-card__field-row.accent3{--axp-entity-styling-border: var(--ax-sys-color-border-accent3-lightest-surface);background-color:rgb(var(--ax-sys-color-accent3-100));box-shadow:inset 0 0 0 1px rgb(var(--axp-entity-styling-border) / .35);color:rgb(var(--ax-sys-color-on-accent3-lightest-surface))}.axp-entity-card .axp-entity-card__fact.primary,.axp-entity-card .axp-entity-card__fact.secondary,.axp-entity-card .axp-entity-card__fact.success,.axp-entity-card .axp-entity-card__fact.warning,.axp-entity-card .axp-entity-card__fact.danger,.axp-entity-card .axp-entity-card__fact.accent1,.axp-entity-card .axp-entity-card__fact.accent2,.axp-entity-card .axp-entity-card__fact.accent3,.axp-entity-card .axp-entity-card__header-badge.primary,.axp-entity-card .axp-entity-card__header-badge.secondary,.axp-entity-card .axp-entity-card__header-badge.success,.axp-entity-card .axp-entity-card__header-badge.warning,.axp-entity-card .axp-entity-card__header-badge.danger,.axp-entity-card .axp-entity-card__header-badge.accent1,.axp-entity-card .axp-entity-card__header-badge.accent2,.axp-entity-card .axp-entity-card__header-badge.accent3{border-radius:var(--radius-sm, .25rem);padding-inline:var(--spacing, .25rem)}.axp-entity-card .axp-entity-card__field-row{display:flex;width:100%;align-items:flex-start;justify-content:space-between;gap:calc(var(--spacing, .25rem) * 3)}.axp-entity-card .axp-entity-card__field-label{display:inline-flex;min-width:0px;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1.5);text-align:start;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);color:var(--color-gray-500, oklch(55.1% .027 264.364))}.axp-entity-card .axp-entity-card__field-value{margin-inline-start:auto;max-width:60%;min-width:0px;overflow:hidden;text-align:start;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-leading: var(--leading-snug, 1.375);line-height:var(--leading-snug, 1.375);--tw-font-weight: var(--font-weight-normal, 400);font-weight:var(--font-weight-normal, 400);overflow-wrap:break-word;color:rgba(var(--ax-sys-color-on-surface))}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;width:100%;max-width:100%;min-width:0px;overflow:hidden;text-align:start;overflow-wrap:break-word}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell *{text-align:start}.axp-entity-card .axp-entity-card__field-value axp-widget-column-cell .flex{justify-content:flex-start}.axp-entity-card .axp-entity-card__field-value :is(.truncate,.whitespace-nowrap){max-width:100%;min-width:0px;overflow-wrap:break-word;white-space:normal;overflow:visible;text-overflow:unset}:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-label,:is(.axp-entity-card .axp-entity-card__field-row.primary,.axp-entity-card .axp-entity-card__field-row.secondary,.axp-entity-card .axp-entity-card__field-row.success,.axp-entity-card .axp-entity-card__field-row.warning,.axp-entity-card .axp-entity-card__field-row.danger,.axp-entity-card .axp-entity-card__field-row.accent1,.axp-entity-card .axp-entity-card__field-row.accent2,.axp-entity-card .axp-entity-card__field-row.accent3) .axp-entity-card__field-value{color:inherit}.axp-entity-card .axp-entity-card__field-icon{flex-shrink:0;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:var(--color-gray-400, oklch(70.7% .022 261.325))}.axp-entity-card .axp-entity-card__footer{margin-top:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 2);border-top-style:var(--tw-border-style);border-top-width:1px;padding-block:calc(var(--spacing, .25rem) * 2.5);padding-inline:var(--axp-entity-card-gutter);border-top-color:var(--axp-entity-card-border);background-color:var(--axp-entity-card-surface)}.axp-entity-card .axp-entity-card__footer-actions{margin-inline-start:auto;display:flex;min-width:0px;align-items:center;justify-content:flex-end;gap:calc(var(--spacing, .25rem) * 2)}.axp-entity-card .axp-entity-card__primary-action{min-width:0px}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact):not(.axp-entity-card--embedded) .axp-entity-card__identity{padding-block:calc(var(--spacing, .25rem) * 2.5)}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact) .axp-entity-card__title{font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)))}:is(.axp-entity-card.axp-entity-card--row,.axp-entity-card.axp-entity-card--compact).axp-entity-card--expandable.axp-entity-card--expanded .axp-entity-card__identity{padding-bottom:calc(var(--spacing, .25rem) * 2.5)}:host.axp-entity-card-host--fill .axp-entity-card{display:flex;width:100%;min-height:0;flex:1 1 auto;flex-direction:column}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-outline-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@property --tw-leading{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000;--tw-outline-style: solid;--tw-font-weight: initial;--tw-leading: initial}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"] }]
|
|
7792
|
-
}], ctorParameters: () => [], propDecorators: { entity: [{ type: i0.Input, args: [{ isSignal: true, alias: "entity", required: true }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: true }] }], fields: [{ type: i0.Input, args: [{ isSignal: true, alias: "fields", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], embedded: [{ type: i0.Input, args: [{ isSignal: true, alias: "embedded", required: false }] }], elevated: [{ type: i0.Input, args: [{ isSignal: true, alias: "elevated", required: false }] }], disableLookupPopover: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableLookupPopover", required: false }] }], fillHost: [{ type: i0.Input, args: [{ isSignal: true, alias: "fillHost", required: false }] }], extraExpanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "extraExpanded", required: false }] }, { type: i0.Output, args: ["extraExpandedChange"] }], selected: [{ type: i0.Input, args: [{ isSignal: true, alias: "selected", required: false }] }], showNewBadge: [{ type: i0.Input, args: [{ isSignal: true, alias: "showNewBadge", required: false }] }], showSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSelection", required: false }] }], showClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "showClose", required: false }] }], primaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActions", required: false }] }], primaryActionLook: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActionLook", required: false }] }], secondaryActionLoader: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondaryActionLoader", required: false }] }], selectionChange: [{ type: i0.Output, args: ["selectionChange"] }], commandClick: [{ type: i0.Output, args: ["commandClick"] }], closeClick: [{ type: i0.Output, args: ["closeClick"] }] } });
|
|
8001
|
+
}], ctorParameters: () => [], propDecorators: { entity: [{ type: i0.Input, args: [{ isSignal: true, alias: "entity", required: true }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: true }] }], fields: [{ type: i0.Input, args: [{ isSignal: true, alias: "fields", required: false }] }], userStylingRules: [{ type: i0.Input, args: [{ isSignal: true, alias: "userStylingRules", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], embedded: [{ type: i0.Input, args: [{ isSignal: true, alias: "embedded", required: false }] }], elevated: [{ type: i0.Input, args: [{ isSignal: true, alias: "elevated", required: false }] }], disableLookupPopover: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableLookupPopover", required: false }] }], fillHost: [{ type: i0.Input, args: [{ isSignal: true, alias: "fillHost", required: false }] }], extraExpanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "extraExpanded", required: false }] }, { type: i0.Output, args: ["extraExpandedChange"] }], selected: [{ type: i0.Input, args: [{ isSignal: true, alias: "selected", required: false }] }], showNewBadge: [{ type: i0.Input, args: [{ isSignal: true, alias: "showNewBadge", required: false }] }], showSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSelection", required: false }] }], showClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "showClose", required: false }] }], primaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActions", required: false }] }], primaryActionLook: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActionLook", required: false }] }], secondaryActionLoader: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondaryActionLoader", required: false }] }], selectionChange: [{ type: i0.Output, args: ["selectionChange"] }], commandClick: [{ type: i0.Output, args: ["commandClick"] }], closeClick: [{ type: i0.Output, args: ["closeClick"] }] } });
|
|
7793
8002
|
|
|
7794
8003
|
class AXPEntityDetailPopoverComponent {
|
|
7795
8004
|
constructor() {
|
|
@@ -7913,15 +8122,17 @@ class AXPEntityDetailPopoverComponent {
|
|
|
7913
8122
|
}
|
|
7914
8123
|
async navigateToDetails() {
|
|
7915
8124
|
if (this.entityId()) {
|
|
7916
|
-
await this.commandService.execute('Entity:OpenDetails', {
|
|
8125
|
+
const result = await this.commandService.execute('Entity:OpenDetails', {
|
|
7917
8126
|
entity: this.entity(),
|
|
7918
8127
|
data: { id: this.entityId() },
|
|
7919
8128
|
});
|
|
7920
|
-
|
|
8129
|
+
if (result?.success) {
|
|
8130
|
+
this.requestClose()?.();
|
|
8131
|
+
}
|
|
7921
8132
|
}
|
|
7922
8133
|
}
|
|
7923
8134
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPEntityDetailPopoverComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7924
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPEntityDetailPopoverComponent, isStandalone: true, selector: "axp-entity-detail-popover", inputs: { entity: { classPropertyName: "entity", publicName: "entity", isSignal: true, isRequired: true, transformFunction: null }, entityId: { classPropertyName: "entityId", publicName: "entityId", isSignal: true, isRequired: true, transformFunction: null }, requestClose: { classPropertyName: "requestClose", publicName: "requestClose", isSignal: true, isRequired: false, transformFunction: null }, breadcrumb: { classPropertyName: "breadcrumb", publicName: "breadcrumb", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"axp-entity-detail-popover\">\n @if (breadcrumb()) {\n <!-- ----- Optional lookup breadcrumb above the shared entity card ----- -->\n <div class=\"text-xs text-neutral-500 mb-2\">{{ breadcrumb() }}</div>\n }\n @if (isLoadingDetails()) {\n <!-- ----- Loading placeholder while Entity:GetDetails is fetched ----- -->\n <div class=\"axp-entity-detail-popover__loading\">\n @if (canClose()) {\n <!-- ----- Dismiss while the lookup card is still loading ----- -->\n <ax-button\n class=\"axp-entity-detail-popover__close ax-sm\"\n [look]=\"'blank'\"\n [color]=\"'default'\"\n [iconOnly]=\"true\"\n [attr.title]=\"('@general:actions.close.title' | translate | async)\"\n [attr.aria-label]=\"('@general:actions.close.title' | translate | async)\"\n (onClick)=\"onClose()\"\n >\n <i class=\"fa-light fa-xmark\" aria-hidden=\"true\"></i>\n </ax-button>\n }\n <axp-entity-card-skeleton\n [fieldCount]=\"skeletonFieldCount()\"\n [badgeCount]=\"skeletonBadgeCount()\"\n [showContent]=\"true\"\n [showFooter]=\"true\"\n [showAvatar]=\"showSkeletonAvatar()\"\n [elevated]=\"true\"\n />\n </div>\n }\n <!-- ----- Same card chrome as the master list; Open Details uses the card footer ----- -->\n @else if (entityDefinition(); as definition) {\n <!--->\n <!-- ----- Entity card when row details have loaded ----- -->\n @if (entityData(); as row) {\n <axp-entity-card\n [entity]=\"definition\"\n [layout]=\"cardLayout()\"\n [row]=\"row\"\n [fields]=\"cardFields()\"\n variant=\"card\"\n [interactive]=\"false\"\n [elevated]=\"true\"\n [showClose]=\"canClose()\"\n primaryActionLook=\"solid\"\n [disableLookupPopover]=\"true\"\n [primaryActions]=\"openDetailsActions()\"\n (commandClick)=\"onCardCommandClick($event)\"\n (closeClick)=\"onClose()\"\n />\n }\n }\n</div>\n", styles: [":host{display:block;border-radius:var(--radius-md, .375rem);width:min(600px,calc(100vw - 2rem));background-color:rgb(var(--ax-sys-color-lightest-surface));box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-detail-popover__loading{position:relative}.axp-entity-detail-popover__close{position:absolute;z-index:20;inset-block-start:.75rem;inset-inline-end:1rem}.axp-entity-detail-popover-overlay,.axp-entity-detail-popover-overlay.ax-overlay-container,.axp-entity-detail-popover-overlay.ax-overlay-pane,.axp-entity-detail-popover-overlay .ax-overlay-pane,.axp-entity-detail-popover-overlay .overlay-pane{width:min(600px,calc(100vw - 2rem))!important;min-width:min(600px,calc(100vw - 2rem));overflow:visible!important;background:transparent!important;border:none!important;box-shadow:none!important;padding:0!important}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXSkeletonModule }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPEntityCardComponent, selector: "axp-entity-card", inputs: ["entity", "layout", "row", "fields", "variant", "interactive", "embedded", "elevated", "disableLookupPopover", "fillHost", "extraExpanded", "selected", "showNewBadge", "showSelection", "showClose", "primaryActions", "primaryActionLook", "secondaryActionLoader"], outputs: ["extraExpandedChange", "selectionChange", "commandClick", "closeClick"] }, { kind: "component", type: AXPEntityCardSkeletonComponent, selector: "axp-entity-card-skeleton", inputs: ["fieldCount", "badgeCount", "showFooter", "showHeaderMenu", "showContent", "rowLayout", "showAvatar", "fillHost", "embedded", "elevated"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
8135
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPEntityDetailPopoverComponent, isStandalone: true, selector: "axp-entity-detail-popover", inputs: { entity: { classPropertyName: "entity", publicName: "entity", isSignal: true, isRequired: true, transformFunction: null }, entityId: { classPropertyName: "entityId", publicName: "entityId", isSignal: true, isRequired: true, transformFunction: null }, requestClose: { classPropertyName: "requestClose", publicName: "requestClose", isSignal: true, isRequired: false, transformFunction: null }, breadcrumb: { classPropertyName: "breadcrumb", publicName: "breadcrumb", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"axp-entity-detail-popover\">\n @if (breadcrumb()) {\n <!-- ----- Optional lookup breadcrumb above the shared entity card ----- -->\n <div class=\"text-xs text-neutral-500 mb-2\">{{ breadcrumb() }}</div>\n }\n @if (isLoadingDetails()) {\n <!-- ----- Loading placeholder while Entity:GetDetails is fetched ----- -->\n <div class=\"axp-entity-detail-popover__loading\">\n @if (canClose()) {\n <!-- ----- Dismiss while the lookup card is still loading ----- -->\n <ax-button\n class=\"axp-entity-detail-popover__close ax-sm\"\n [look]=\"'blank'\"\n [color]=\"'default'\"\n [iconOnly]=\"true\"\n [attr.title]=\"('@general:actions.close.title' | translate | async)\"\n [attr.aria-label]=\"('@general:actions.close.title' | translate | async)\"\n (onClick)=\"onClose()\"\n >\n <i class=\"fa-light fa-xmark\" aria-hidden=\"true\"></i>\n </ax-button>\n }\n <axp-entity-card-skeleton\n [fieldCount]=\"skeletonFieldCount()\"\n [badgeCount]=\"skeletonBadgeCount()\"\n [showContent]=\"true\"\n [showFooter]=\"true\"\n [showAvatar]=\"showSkeletonAvatar()\"\n [elevated]=\"true\"\n />\n </div>\n }\n <!-- ----- Same card chrome as the master list; Open Details uses the card footer ----- -->\n @else if (entityDefinition(); as definition) {\n <!--->\n <!-- ----- Entity card when row details have loaded ----- -->\n @if (entityData(); as row) {\n <axp-entity-card\n [entity]=\"definition\"\n [layout]=\"cardLayout()\"\n [row]=\"row\"\n [fields]=\"cardFields()\"\n variant=\"card\"\n [interactive]=\"false\"\n [elevated]=\"true\"\n [showClose]=\"canClose()\"\n primaryActionLook=\"solid\"\n [disableLookupPopover]=\"true\"\n [primaryActions]=\"openDetailsActions()\"\n (commandClick)=\"onCardCommandClick($event)\"\n (closeClick)=\"onClose()\"\n />\n }\n }\n</div>\n", styles: [":host{display:block;border-radius:var(--radius-md, .375rem);width:min(600px,calc(100vw - 2rem));background-color:rgb(var(--ax-sys-color-lightest-surface));box-shadow:0 8px 16px #00000029,0 24px 48px #00000038,0 48px 96px #00000047}.axp-entity-detail-popover__loading{position:relative}.axp-entity-detail-popover__close{position:absolute;z-index:20;inset-block-start:.75rem;inset-inline-end:1rem}.axp-entity-detail-popover-overlay,.axp-entity-detail-popover-overlay.ax-overlay-container,.axp-entity-detail-popover-overlay.ax-overlay-pane,.axp-entity-detail-popover-overlay .ax-overlay-pane,.axp-entity-detail-popover-overlay .overlay-pane{width:min(600px,calc(100vw - 2rem))!important;min-width:min(600px,calc(100vw - 2rem));overflow:visible!important;background:transparent!important;border:none!important;box-shadow:none!important;padding:0!important}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXSkeletonModule }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPEntityCardComponent, selector: "axp-entity-card", inputs: ["entity", "layout", "row", "fields", "userStylingRules", "variant", "interactive", "embedded", "elevated", "disableLookupPopover", "fillHost", "extraExpanded", "selected", "showNewBadge", "showSelection", "showClose", "primaryActions", "primaryActionLook", "secondaryActionLoader"], outputs: ["extraExpandedChange", "selectionChange", "commandClick", "closeClick"] }, { kind: "component", type: AXPEntityCardSkeletonComponent, selector: "axp-entity-card-skeleton", inputs: ["fieldCount", "badgeCount", "showFooter", "showHeaderMenu", "showContent", "rowLayout", "showAvatar", "fillHost", "embedded", "elevated"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
7925
8136
|
}
|
|
7926
8137
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPEntityDetailPopoverComponent, decorators: [{
|
|
7927
8138
|
type: Component,
|
|
@@ -8624,6 +8835,7 @@ class AXPEntityDetailListViewModel {
|
|
|
8624
8835
|
this.commandService = this.injector.get(AXPCommandService);
|
|
8625
8836
|
this.filterOperatorMiddleware = this.injector.get(AXPFilterOperatorMiddlewareService);
|
|
8626
8837
|
this.expressionEvaluator = this.injector.get(AXPExpressionEvaluatorService);
|
|
8838
|
+
this.contextEvalFactory = this.injector.get(AXPContextEvalFactory);
|
|
8627
8839
|
this.queryExecutor = this.injector.get(AXPQueryExecutor);
|
|
8628
8840
|
this.settingsService = this.injector.get(AXPSettingsService);
|
|
8629
8841
|
this.cardFieldsResolver = this.injector.get(AXPEntityCardFieldsResolver);
|
|
@@ -8680,13 +8892,7 @@ class AXPEntityDetailListViewModel {
|
|
|
8680
8892
|
//****************** Visibility ******************//
|
|
8681
8893
|
this.hidden = computed(async () => {
|
|
8682
8894
|
if (typeof this.detailEntityConfig.hidden == 'string') {
|
|
8683
|
-
const scope =
|
|
8684
|
-
context: {
|
|
8685
|
-
eval: (path) => {
|
|
8686
|
-
return get(this.parent.data, path);
|
|
8687
|
-
},
|
|
8688
|
-
},
|
|
8689
|
-
};
|
|
8895
|
+
const scope = createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(this.parent.data));
|
|
8690
8896
|
return await this.expressionEvaluator.evaluate(this.detailEntityConfig.hidden, scope);
|
|
8691
8897
|
}
|
|
8692
8898
|
else {
|
|
@@ -8801,14 +9007,7 @@ class AXPEntityDetailListViewModel {
|
|
|
8801
9007
|
}, /* @ts-ignore */
|
|
8802
9008
|
...(ngDevMode ? [{ debugName: "columns" }] : /* istanbul ignore next */ []));
|
|
8803
9009
|
this.evaluateExpressions = async (actionData) => {
|
|
8804
|
-
const
|
|
8805
|
-
const scope = {
|
|
8806
|
-
context: {
|
|
8807
|
-
eval: (path) => {
|
|
8808
|
-
return get(parentData, path);
|
|
8809
|
-
},
|
|
8810
|
-
},
|
|
8811
|
-
};
|
|
9010
|
+
const scope = createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(this.parent.data));
|
|
8812
9011
|
return await this.expressionEvaluator.evaluate(actionData, scope);
|
|
8813
9012
|
};
|
|
8814
9013
|
void this.syncShowRowIndexColumnSetting();
|
|
@@ -9124,6 +9323,41 @@ function fireEntityLifecycleHook(hooks, key, payload) {
|
|
|
9124
9323
|
}
|
|
9125
9324
|
}
|
|
9126
9325
|
|
|
9326
|
+
//#region ----- Entity list column settings (configure APIs) -----
|
|
9327
|
+
/**
|
|
9328
|
+
* Product modules register column names whose persisted list prefs should be
|
|
9329
|
+
* dropped once when migrating to a newer {@link getEntityListColumnsSettingsVersion}.
|
|
9330
|
+
* Framework keeps empty defaults — no product column names here.
|
|
9331
|
+
*/
|
|
9332
|
+
let columnsSettingsVersion = 1;
|
|
9333
|
+
const migrateDropColumns = new Set();
|
|
9334
|
+
/** Raise the persisted columns-settings schema version (monotonic). */
|
|
9335
|
+
function configureEntityListColumnsSettingsVersion(version) {
|
|
9336
|
+
if (!Number.isFinite(version)) {
|
|
9337
|
+
return;
|
|
9338
|
+
}
|
|
9339
|
+
const next = Math.floor(version);
|
|
9340
|
+
if (next > columnsSettingsVersion) {
|
|
9341
|
+
columnsSettingsVersion = next;
|
|
9342
|
+
}
|
|
9343
|
+
}
|
|
9344
|
+
/** Register column names to strip from stale user list prefs during version migration. */
|
|
9345
|
+
function configureEntityListColumnsSettingsMigrateDrop(columnNames) {
|
|
9346
|
+
for (const name of columnNames) {
|
|
9347
|
+
const trimmed = String(name ?? '').trim();
|
|
9348
|
+
if (trimmed) {
|
|
9349
|
+
migrateDropColumns.add(trimmed);
|
|
9350
|
+
}
|
|
9351
|
+
}
|
|
9352
|
+
}
|
|
9353
|
+
function getEntityListColumnsSettingsVersion() {
|
|
9354
|
+
return columnsSettingsVersion;
|
|
9355
|
+
}
|
|
9356
|
+
function getEntityListColumnsSettingsMigrateDrop() {
|
|
9357
|
+
return migrateDropColumns;
|
|
9358
|
+
}
|
|
9359
|
+
//#endregion
|
|
9360
|
+
|
|
9127
9361
|
/**
|
|
9128
9362
|
* Resolves a stable row id from entity list row data.
|
|
9129
9363
|
*/
|
|
@@ -9201,6 +9435,15 @@ function normalizeEntityListPersistenceMode(value) {
|
|
|
9201
9435
|
function canPersistEntityListState(mode) {
|
|
9202
9436
|
return mode !== 'none';
|
|
9203
9437
|
}
|
|
9438
|
+
const ENTITY_LIST_STYLING_RULES_PATH = ['list', 'stylingRules'];
|
|
9439
|
+
/** Personal highlight rules live on the entity setting, not on one query view. */
|
|
9440
|
+
function entityListStylingRulesPath() {
|
|
9441
|
+
return ENTITY_LIST_STYLING_RULES_PATH;
|
|
9442
|
+
}
|
|
9443
|
+
/** Personal highlight rules for this entity. Shared by every view of the list. */
|
|
9444
|
+
function readPersistedEntityListStylingRules(setting) {
|
|
9445
|
+
return normalizeEntityListUserStylingRules(getNested(setting, [...ENTITY_LIST_STYLING_RULES_PATH]));
|
|
9446
|
+
}
|
|
9204
9447
|
/** `none` never reads list state from user settings. */
|
|
9205
9448
|
function shouldLoadEntityListStateFromStorage(mode) {
|
|
9206
9449
|
return mode !== 'none';
|
|
@@ -9210,6 +9453,55 @@ function shouldResetEntityListStateOnRouteEntry(mode) {
|
|
|
9210
9453
|
return mode === 'route';
|
|
9211
9454
|
}
|
|
9212
9455
|
const ENTITY_LIST_ROUTE_CONTEXT_SESSION_KEY = 'axp-entity-list-route-context';
|
|
9456
|
+
function entityListInstanceFilterPath(instanceId, viewName) {
|
|
9457
|
+
return ['list', 'instances', instanceId, 'views', viewName, 'filters'];
|
|
9458
|
+
}
|
|
9459
|
+
function entityListInstanceCurrentViewPath(instanceId) {
|
|
9460
|
+
return ['list', 'instances', instanceId, 'currentView'];
|
|
9461
|
+
}
|
|
9462
|
+
function readPersistedEntityListInstanceFilters(setting, instanceId, viewName) {
|
|
9463
|
+
const instanceFilters = getNested(setting, entityListInstanceFilterPath(instanceId, viewName));
|
|
9464
|
+
if (instanceFilters === null) {
|
|
9465
|
+
return [];
|
|
9466
|
+
}
|
|
9467
|
+
if (Array.isArray(instanceFilters)) {
|
|
9468
|
+
return instanceFilters;
|
|
9469
|
+
}
|
|
9470
|
+
if (instanceId === ENTITY_LIST_DEFAULT_INSTANCE_ID) {
|
|
9471
|
+
const legacy = getNested(setting, ['list', 'views', viewName, 'filters']);
|
|
9472
|
+
if (Array.isArray(legacy)) {
|
|
9473
|
+
return legacy;
|
|
9474
|
+
}
|
|
9475
|
+
}
|
|
9476
|
+
return undefined;
|
|
9477
|
+
}
|
|
9478
|
+
function readPersistedEntityListInstanceCurrentView(setting, instanceId) {
|
|
9479
|
+
const instanceView = getNested(setting, entityListInstanceCurrentViewPath(instanceId));
|
|
9480
|
+
if (typeof instanceView === 'string' && instanceView.trim()) {
|
|
9481
|
+
return instanceView;
|
|
9482
|
+
}
|
|
9483
|
+
if (instanceId === ENTITY_LIST_DEFAULT_INSTANCE_ID) {
|
|
9484
|
+
const legacy = getNested(setting, ['list', 'currentView']);
|
|
9485
|
+
if (typeof legacy === 'string' && legacy.trim()) {
|
|
9486
|
+
return legacy;
|
|
9487
|
+
}
|
|
9488
|
+
}
|
|
9489
|
+
return undefined;
|
|
9490
|
+
}
|
|
9491
|
+
/** View conditions first; persisted user filters overlay fields the view does not already own. */
|
|
9492
|
+
function mergeEntityListViewAndPersistedFilters(viewFilters, persisted) {
|
|
9493
|
+
return mergeQueryViewAndUserFilters(viewFilters, persisted);
|
|
9494
|
+
}
|
|
9495
|
+
function getNested(source, path) {
|
|
9496
|
+
let current = source;
|
|
9497
|
+
for (const key of path) {
|
|
9498
|
+
if (!current || typeof current !== 'object') {
|
|
9499
|
+
return undefined;
|
|
9500
|
+
}
|
|
9501
|
+
current = current[String(key)];
|
|
9502
|
+
}
|
|
9503
|
+
return current;
|
|
9504
|
+
}
|
|
9213
9505
|
|
|
9214
9506
|
class AXPEntityCreateViewSectionViewModel {
|
|
9215
9507
|
constructor(entity, section) {
|
|
@@ -9411,6 +9703,336 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
9411
9703
|
args: [{ providedIn: 'root' }]
|
|
9412
9704
|
}] });
|
|
9413
9705
|
|
|
9706
|
+
//#region ----- Imports -----
|
|
9707
|
+
//#endregion
|
|
9708
|
+
//#region ----- Constants -----
|
|
9709
|
+
const PREVIEW_TITLE_CAP = 8;
|
|
9710
|
+
const PREVIEW_TITLE_MAX_CHARS = 80;
|
|
9711
|
+
const SECRET_NAME_PATTERN = /password|secret|token|apikey|api_key|credential|privatekey|private_key/i;
|
|
9712
|
+
const FILTER_OPERATOR_TYPES = new Set([
|
|
9713
|
+
'equal',
|
|
9714
|
+
'isNull',
|
|
9715
|
+
'isEmpty',
|
|
9716
|
+
'lt',
|
|
9717
|
+
'lte',
|
|
9718
|
+
'gt',
|
|
9719
|
+
'gte',
|
|
9720
|
+
'startsWith',
|
|
9721
|
+
'endsWith',
|
|
9722
|
+
'contains',
|
|
9723
|
+
'in',
|
|
9724
|
+
]);
|
|
9725
|
+
const ENTITY_LIST_ACTIONS = [
|
|
9726
|
+
{
|
|
9727
|
+
id: 'set-view',
|
|
9728
|
+
title: 'Set list view',
|
|
9729
|
+
params: [{ name: 'viewName', required: true, description: 'View name from snapshot.views[].name (e.g. archive).' }],
|
|
9730
|
+
},
|
|
9731
|
+
{
|
|
9732
|
+
id: 'set-filter',
|
|
9733
|
+
title: 'Set filter',
|
|
9734
|
+
params: [
|
|
9735
|
+
{ name: 'field', required: true, description: 'Filter field from snapshot.filterFields[].field.' },
|
|
9736
|
+
{ name: 'operatorType', required: true, description: 'equal, contains, in, startsWith, …' },
|
|
9737
|
+
{ name: 'value', required: true, description: 'Filter value.' },
|
|
9738
|
+
],
|
|
9739
|
+
},
|
|
9740
|
+
{
|
|
9741
|
+
id: 'remove-filter',
|
|
9742
|
+
title: 'Remove filter',
|
|
9743
|
+
params: [{ name: 'field', required: true, description: 'Visible filter field to remove (not hidden view conditions).' }],
|
|
9744
|
+
},
|
|
9745
|
+
{
|
|
9746
|
+
id: 'clear-filters',
|
|
9747
|
+
title: 'Clear filters',
|
|
9748
|
+
params: [],
|
|
9749
|
+
},
|
|
9750
|
+
{
|
|
9751
|
+
id: 'set-search',
|
|
9752
|
+
title: 'Set list search',
|
|
9753
|
+
params: [{ name: 'text', required: false, description: 'Quick-search text. Empty string clears search.' }],
|
|
9754
|
+
},
|
|
9755
|
+
];
|
|
9756
|
+
//#endregion
|
|
9757
|
+
//#region ----- Snapshot -----
|
|
9758
|
+
function axpBuildEntityListPageContextSnapshot(vm, resolveTitle) {
|
|
9759
|
+
const entityInfo = getEntityInfo(vm.entityDef);
|
|
9760
|
+
const fullName = entityInfo.source;
|
|
9761
|
+
const currentView = vm.view();
|
|
9762
|
+
const filters = vm.filterQueries();
|
|
9763
|
+
const filterDefs = vm.filterDefinitions();
|
|
9764
|
+
const quickSearch = readQuickSearch(filters);
|
|
9765
|
+
const dataSource = vm.dataSource;
|
|
9766
|
+
const isLoading = dataSource.isLoading === true;
|
|
9767
|
+
const itemCount = dataSource.items?.length ?? 0;
|
|
9768
|
+
const status = isLoading ? 'loading' : itemCount === 0 ? 'empty' : 'ready';
|
|
9769
|
+
const filterFieldTitleByName = new Map();
|
|
9770
|
+
for (const def of filterDefs) {
|
|
9771
|
+
const field = def.field?.trim();
|
|
9772
|
+
if (!field) {
|
|
9773
|
+
continue;
|
|
9774
|
+
}
|
|
9775
|
+
filterFieldTitleByName.set(field, resolveTitle(def.title) || field);
|
|
9776
|
+
}
|
|
9777
|
+
const snapshotFilters = flattenQueryFilterUserGroups(filters)
|
|
9778
|
+
.queries.filter((f) => !isQuickSearchField(f.field))
|
|
9779
|
+
.map((f) => {
|
|
9780
|
+
const field = typeof f.field === 'string' ? f.field : '';
|
|
9781
|
+
const operatorType = typeof f.operator?.type === 'string' ? f.operator.type : undefined;
|
|
9782
|
+
return {
|
|
9783
|
+
field,
|
|
9784
|
+
operatorType,
|
|
9785
|
+
value: f.value,
|
|
9786
|
+
title: filterFieldTitleByName.get(field) ?? (typeof f.displayText === 'string' ? f.displayText : undefined),
|
|
9787
|
+
hidden: f.hidden === true,
|
|
9788
|
+
};
|
|
9789
|
+
})
|
|
9790
|
+
.filter((f) => f.field.length > 0);
|
|
9791
|
+
const columns = vm
|
|
9792
|
+
.columns()
|
|
9793
|
+
.filter((c) => c.visible)
|
|
9794
|
+
.map((c) => ({
|
|
9795
|
+
name: c.name,
|
|
9796
|
+
title: resolveTitle(c.title) || c.name,
|
|
9797
|
+
}));
|
|
9798
|
+
const selectedRecords = readSelectedRecords(vm, resolveTitle);
|
|
9799
|
+
const selectedIds = selectedRecords.map((row) => row.id);
|
|
9800
|
+
const sorts = vm
|
|
9801
|
+
.sortedFields()
|
|
9802
|
+
.filter((s) => s.dir)
|
|
9803
|
+
.map((s) => ({ field: s.name, dir: s.dir }));
|
|
9804
|
+
return {
|
|
9805
|
+
kind: 'entity-list',
|
|
9806
|
+
title: resolveTitle(vm.title()) || fullName,
|
|
9807
|
+
status,
|
|
9808
|
+
entity: {
|
|
9809
|
+
fullName,
|
|
9810
|
+
title: resolveTitle(vm.entityDef.formats.plural) || fullName,
|
|
9811
|
+
},
|
|
9812
|
+
view: {
|
|
9813
|
+
name: currentView.name,
|
|
9814
|
+
title: resolveTitle(currentView.title) || currentView.name,
|
|
9815
|
+
},
|
|
9816
|
+
views: vm.views().map((v) => ({
|
|
9817
|
+
name: v.name,
|
|
9818
|
+
title: resolveTitle(v.title) || v.name,
|
|
9819
|
+
})),
|
|
9820
|
+
filters: snapshotFilters,
|
|
9821
|
+
filterFields: filterDefs
|
|
9822
|
+
.map((def) => {
|
|
9823
|
+
const field = def.field?.trim();
|
|
9824
|
+
if (!field) {
|
|
9825
|
+
return null;
|
|
9826
|
+
}
|
|
9827
|
+
return { field, title: filterFieldTitleByName.get(field) ?? field };
|
|
9828
|
+
})
|
|
9829
|
+
.filter((row) => row != null),
|
|
9830
|
+
...(quickSearch ? { quickSearch } : {}),
|
|
9831
|
+
...(selectedIds.length ? { selectedIds } : {}),
|
|
9832
|
+
...(selectedRecords.length ? { selectedRecords } : {}),
|
|
9833
|
+
columns,
|
|
9834
|
+
previewTitles: buildPreviewTitles(vm, dataSource.items ?? []),
|
|
9835
|
+
appliedQuery: {
|
|
9836
|
+
skip: dataSource._query?.skip,
|
|
9837
|
+
take: dataSource._query?.take,
|
|
9838
|
+
...(sorts.length ? { sort: sorts } : {}),
|
|
9839
|
+
filter: snapshotFilters.filter((f) => f.hidden !== true),
|
|
9840
|
+
},
|
|
9841
|
+
actions: ENTITY_LIST_ACTIONS,
|
|
9842
|
+
};
|
|
9843
|
+
}
|
|
9844
|
+
//#endregion
|
|
9845
|
+
//#region ----- Run -----
|
|
9846
|
+
async function axpRunEntityListPageContextAction(vm, actionId, args, resolveTitle) {
|
|
9847
|
+
const result = await runEntityListAction(vm, actionId, args);
|
|
9848
|
+
return {
|
|
9849
|
+
...result,
|
|
9850
|
+
snapshot: axpBuildEntityListPageContextSnapshot(vm, resolveTitle),
|
|
9851
|
+
};
|
|
9852
|
+
}
|
|
9853
|
+
async function runEntityListAction(vm, actionId, args) {
|
|
9854
|
+
switch (actionId) {
|
|
9855
|
+
case 'set-view':
|
|
9856
|
+
return setViewAction(vm, args);
|
|
9857
|
+
case 'set-filter':
|
|
9858
|
+
return setFilterAction(vm, args);
|
|
9859
|
+
case 'remove-filter':
|
|
9860
|
+
return removeFilterAction(vm, args);
|
|
9861
|
+
case 'clear-filters':
|
|
9862
|
+
vm.resetFilters();
|
|
9863
|
+
await vm.applyFilterAndSort({ resetPagination: true });
|
|
9864
|
+
return { success: true };
|
|
9865
|
+
case 'set-search':
|
|
9866
|
+
return setSearchAction(vm, args);
|
|
9867
|
+
default:
|
|
9868
|
+
return { success: false, message: `Unknown page action "${actionId}".` };
|
|
9869
|
+
}
|
|
9870
|
+
}
|
|
9871
|
+
async function setViewAction(vm, args) {
|
|
9872
|
+
const viewName = readStringArg(args, 'viewName');
|
|
9873
|
+
if (!viewName) {
|
|
9874
|
+
return { success: false, message: 'set-view requires viewName.' };
|
|
9875
|
+
}
|
|
9876
|
+
const match = vm.views().find((v) => v.name === viewName);
|
|
9877
|
+
if (!match) {
|
|
9878
|
+
return { success: false, message: `View "${viewName}" is not on this list.` };
|
|
9879
|
+
}
|
|
9880
|
+
await vm.setView(viewName);
|
|
9881
|
+
await vm.applyFilterAndSort({ resetPagination: true });
|
|
9882
|
+
return { success: true };
|
|
9883
|
+
}
|
|
9884
|
+
async function setFilterAction(vm, args) {
|
|
9885
|
+
const field = readStringArg(args, 'field');
|
|
9886
|
+
const operatorType = (readStringArg(args, 'operatorType') || 'equal');
|
|
9887
|
+
if (!field) {
|
|
9888
|
+
return { success: false, message: 'set-filter requires field.' };
|
|
9889
|
+
}
|
|
9890
|
+
if (isQuickSearchField(field)) {
|
|
9891
|
+
return { success: false, message: 'Use set-search for list search, not set-filter.' };
|
|
9892
|
+
}
|
|
9893
|
+
if (!FILTER_OPERATOR_TYPES.has(operatorType)) {
|
|
9894
|
+
return { success: false, message: `Unsupported operatorType "${operatorType}".` };
|
|
9895
|
+
}
|
|
9896
|
+
if (!isKnownFilterField(vm, field)) {
|
|
9897
|
+
return { success: false, message: `Field "${field}" is not a filterable field on this list.` };
|
|
9898
|
+
}
|
|
9899
|
+
const value = args['value'];
|
|
9900
|
+
if (!operatorAllowsEmpty(operatorType) && isEmptyFilterValue(value)) {
|
|
9901
|
+
return { success: false, message: 'set-filter requires value.' };
|
|
9902
|
+
}
|
|
9903
|
+
const next = vm
|
|
9904
|
+
.filterQueries()
|
|
9905
|
+
.filter((f) => f.hidden === true || f.field !== field)
|
|
9906
|
+
.concat({
|
|
9907
|
+
field,
|
|
9908
|
+
operator: { type: operatorType },
|
|
9909
|
+
value,
|
|
9910
|
+
hidden: false,
|
|
9911
|
+
});
|
|
9912
|
+
vm.filterQueries.set(next);
|
|
9913
|
+
await vm.applyFilterAndSort({ resetPagination: true });
|
|
9914
|
+
return { success: true };
|
|
9915
|
+
}
|
|
9916
|
+
async function removeFilterAction(vm, args) {
|
|
9917
|
+
const field = readStringArg(args, 'field');
|
|
9918
|
+
if (!field) {
|
|
9919
|
+
return { success: false, message: 'remove-filter requires field.' };
|
|
9920
|
+
}
|
|
9921
|
+
const next = vm.filterQueries().filter((f) => {
|
|
9922
|
+
if (f.hidden === true) {
|
|
9923
|
+
return true;
|
|
9924
|
+
}
|
|
9925
|
+
if (isQuickSearchField(field) && isQuickSearchField(f.field)) {
|
|
9926
|
+
return false;
|
|
9927
|
+
}
|
|
9928
|
+
return f.field !== field;
|
|
9929
|
+
});
|
|
9930
|
+
vm.filterQueries.set(next);
|
|
9931
|
+
await vm.applyFilterAndSort({ resetPagination: true });
|
|
9932
|
+
return { success: true };
|
|
9933
|
+
}
|
|
9934
|
+
async function setSearchAction(vm, args) {
|
|
9935
|
+
const text = typeof args['text'] === 'string' ? args['text'].trim() : '';
|
|
9936
|
+
const { rootLogic, queries } = flattenQueryFilterUserGroups(vm.filterQueries());
|
|
9937
|
+
const withoutSearch = queries.filter((f) => !isQuickSearchField(f.field));
|
|
9938
|
+
const next = text.length === 0
|
|
9939
|
+
? withoutSearch
|
|
9940
|
+
: [
|
|
9941
|
+
...withoutSearch,
|
|
9942
|
+
{
|
|
9943
|
+
field: AXP_QUERY_QUICK_SEARCH_FIELD,
|
|
9944
|
+
operator: { type: 'contains' },
|
|
9945
|
+
value: text,
|
|
9946
|
+
hidden: false,
|
|
9947
|
+
displayText: 'All',
|
|
9948
|
+
},
|
|
9949
|
+
];
|
|
9950
|
+
vm.filterQueries.set(wrapQueryFilterRoot(next, rootLogic));
|
|
9951
|
+
await vm.applyFilterAndSort({ resetPagination: true });
|
|
9952
|
+
return { success: true };
|
|
9953
|
+
}
|
|
9954
|
+
//#endregion
|
|
9955
|
+
//#region ----- Helpers -----
|
|
9956
|
+
function isQuickSearchField(field) {
|
|
9957
|
+
return field === AXP_QUERY_QUICK_SEARCH_FIELD || field === 'all';
|
|
9958
|
+
}
|
|
9959
|
+
function readQuickSearch(filters) {
|
|
9960
|
+
const row = flattenQueryFilterUserGroups(filters).queries.find((f) => isQuickSearchField(f.field));
|
|
9961
|
+
const value = row?.value;
|
|
9962
|
+
return typeof value === 'string' && value.trim() ? value.trim() : undefined;
|
|
9963
|
+
}
|
|
9964
|
+
function readStringArg(args, key) {
|
|
9965
|
+
const value = args[key];
|
|
9966
|
+
return typeof value === 'string' ? value.trim() : '';
|
|
9967
|
+
}
|
|
9968
|
+
function isEmptyFilterValue(value) {
|
|
9969
|
+
if (value === undefined || value === null || value === '') {
|
|
9970
|
+
return true;
|
|
9971
|
+
}
|
|
9972
|
+
return Array.isArray(value) && value.length === 0;
|
|
9973
|
+
}
|
|
9974
|
+
function operatorAllowsEmpty(operatorType) {
|
|
9975
|
+
return operatorType === 'isNull' || operatorType === 'isEmpty';
|
|
9976
|
+
}
|
|
9977
|
+
function isKnownFilterField(vm, field) {
|
|
9978
|
+
if (vm.filterDefinitions().some((def) => def.field === field)) {
|
|
9979
|
+
return true;
|
|
9980
|
+
}
|
|
9981
|
+
return vm.entityDef.properties.some((property) => property.name === field);
|
|
9982
|
+
}
|
|
9983
|
+
function buildPreviewTitles(vm, items) {
|
|
9984
|
+
const path = resolvePreviewPath(vm);
|
|
9985
|
+
if (!path || SECRET_NAME_PATTERN.test(path)) {
|
|
9986
|
+
return [];
|
|
9987
|
+
}
|
|
9988
|
+
const titles = [];
|
|
9989
|
+
for (const item of items) {
|
|
9990
|
+
if (titles.length >= PREVIEW_TITLE_CAP) {
|
|
9991
|
+
break;
|
|
9992
|
+
}
|
|
9993
|
+
if (!item || typeof item !== 'object') {
|
|
9994
|
+
continue;
|
|
9995
|
+
}
|
|
9996
|
+
const raw = get(item, path);
|
|
9997
|
+
const text = typeof raw === 'string' ? raw.trim() : raw != null && typeof raw !== 'object' ? String(raw).trim() : '';
|
|
9998
|
+
if (!text) {
|
|
9999
|
+
continue;
|
|
10000
|
+
}
|
|
10001
|
+
titles.push(text.length > PREVIEW_TITLE_MAX_CHARS ? `${text.slice(0, PREVIEW_TITLE_MAX_CHARS)}…` : text);
|
|
10002
|
+
}
|
|
10003
|
+
return titles;
|
|
10004
|
+
}
|
|
10005
|
+
function readSelectedRecords(vm, resolveTitle) {
|
|
10006
|
+
const path = resolvePreviewPath(vm);
|
|
10007
|
+
const records = [];
|
|
10008
|
+
for (const row of vm.selectedItems()) {
|
|
10009
|
+
if (!row || typeof row !== 'object') {
|
|
10010
|
+
continue;
|
|
10011
|
+
}
|
|
10012
|
+
const rawId = row.id;
|
|
10013
|
+
const id = typeof rawId === 'string' ? rawId.trim() : typeof rawId === 'number' && Number.isFinite(rawId) ? String(rawId) : '';
|
|
10014
|
+
if (!id) {
|
|
10015
|
+
continue;
|
|
10016
|
+
}
|
|
10017
|
+
const rawTitle = path ? get(row, path) : undefined;
|
|
10018
|
+
const title = resolveTitle(rawTitle).trim() || id;
|
|
10019
|
+
records.push({ id, title });
|
|
10020
|
+
}
|
|
10021
|
+
return records;
|
|
10022
|
+
}
|
|
10023
|
+
function resolvePreviewPath(vm) {
|
|
10024
|
+
const names = new Set(vm.entityDef.properties.map((p) => p.name));
|
|
10025
|
+
if (names.has('title')) {
|
|
10026
|
+
return 'title';
|
|
10027
|
+
}
|
|
10028
|
+
if (names.has('name')) {
|
|
10029
|
+
return 'name';
|
|
10030
|
+
}
|
|
10031
|
+
const firstVisible = vm.columns().find((c) => c.visible && !SECRET_NAME_PATTERN.test(c.name));
|
|
10032
|
+
return firstVisible?.name;
|
|
10033
|
+
}
|
|
10034
|
+
//#endregion
|
|
10035
|
+
|
|
9414
10036
|
const ENTITY_MASTER_LIST_TRACE_NS = 'entity-master-list';
|
|
9415
10037
|
/**
|
|
9416
10038
|
* Emits entity master list diagnostics when tenant Debug Mode is enabled.
|
|
@@ -9448,6 +10070,8 @@ class AXPEntityMasterListViewQueryViewModel {
|
|
|
9448
10070
|
this.indexCol = this.view.indexCol;
|
|
9449
10071
|
this.pageSize = this.view.pageSize;
|
|
9450
10072
|
this.visible = this.view.visible;
|
|
10073
|
+
this.fixed = this.view.fixed;
|
|
10074
|
+
this.custom = this.view.custom === true;
|
|
9451
10075
|
}
|
|
9452
10076
|
}
|
|
9453
10077
|
class AXPEntityMasterListViewModel {
|
|
@@ -9530,24 +10154,20 @@ class AXPEntityMasterListViewModel {
|
|
|
9530
10154
|
}
|
|
9531
10155
|
//#endregion
|
|
9532
10156
|
createLogicExpressionScope(data) {
|
|
9533
|
-
return {
|
|
9534
|
-
context: {
|
|
9535
|
-
eval: (path) => get(data, path),
|
|
9536
|
-
},
|
|
10157
|
+
return createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(data), {
|
|
9537
10158
|
list: {
|
|
9538
10159
|
view: () => this.view().name,
|
|
9539
10160
|
views: () => this.views().map((v) => ({ name: v.name, title: v.title })),
|
|
9540
10161
|
},
|
|
9541
|
-
};
|
|
10162
|
+
});
|
|
9542
10163
|
}
|
|
9543
10164
|
createDisplayExpressionScope(data) {
|
|
9544
|
-
return {
|
|
9545
|
-
context: this.contextEvalFactory.createScope((data ?? {})),
|
|
10165
|
+
return createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(data), {
|
|
9546
10166
|
list: {
|
|
9547
10167
|
view: () => this.view().name,
|
|
9548
10168
|
views: () => this.views().map((v) => ({ name: v.name, title: v.title })),
|
|
9549
10169
|
},
|
|
9550
|
-
};
|
|
10170
|
+
});
|
|
9551
10171
|
}
|
|
9552
10172
|
/**
|
|
9553
10173
|
* Evaluates each view's `visible` expression and updates the filtered view list.
|
|
@@ -9586,16 +10206,20 @@ class AXPEntityMasterListViewModel {
|
|
|
9586
10206
|
return typeof resolved === 'string' && resolved.trim() !== '' ? resolved : title;
|
|
9587
10207
|
}
|
|
9588
10208
|
/**
|
|
9589
|
-
* Resolves the record CSS class from
|
|
10209
|
+
* Resolves the record CSS class from entity styling plus personal highlight rules.
|
|
9590
10210
|
*/
|
|
9591
10211
|
async resolveRecordStylingClass(rowData) {
|
|
9592
|
-
|
|
10212
|
+
const entityClass = await resolveEntityMasterRecordStylingClass(this.expressionEvaluator, this.entityDef, rowData);
|
|
10213
|
+
const userClass = resolveEntityListUserRecordStylingClass(rowData, this.userStylingRules());
|
|
10214
|
+
return joinEntityListStylingClasses(entityClass, userClass);
|
|
9593
10215
|
}
|
|
9594
10216
|
/**
|
|
9595
|
-
* Resolves the field CSS class from `interfaces.master.styling.fields
|
|
10217
|
+
* Resolves the field CSS class from `interfaces.master.styling.fields` plus personal rules.
|
|
9596
10218
|
*/
|
|
9597
10219
|
async resolveFieldStylingClass(rowData, fieldName) {
|
|
9598
|
-
|
|
10220
|
+
const entityClass = await resolveEntityMasterFieldStylingClass(this.expressionEvaluator, this.entityDef, rowData, fieldName);
|
|
10221
|
+
const userClass = resolveEntityListUserFieldStylingClass(rowData, this.userStylingRules(), fieldName);
|
|
10222
|
+
return joinEntityListStylingClasses(entityClass, userClass);
|
|
9599
10223
|
}
|
|
9600
10224
|
async resolveTriggerName(triggerName, data) {
|
|
9601
10225
|
if (!triggerName) {
|
|
@@ -9619,6 +10243,8 @@ class AXPEntityMasterListViewModel {
|
|
|
9619
10243
|
activeListLayout: this.activeListLayout(),
|
|
9620
10244
|
}));
|
|
9621
10245
|
await this.settings.ensureLoaded();
|
|
10246
|
+
await this.loadUserStylingRules();
|
|
10247
|
+
await this.loadCustomQueryViews();
|
|
9622
10248
|
await this.refreshVisibleViews();
|
|
9623
10249
|
const availableViews = this.views();
|
|
9624
10250
|
if (!availableViews.length) {
|
|
@@ -9630,12 +10256,11 @@ class AXPEntityMasterListViewModel {
|
|
|
9630
10256
|
}
|
|
9631
10257
|
else if (await this.shouldLoadPersistedListState()) {
|
|
9632
10258
|
const entitySetting = await this.settings.get(this.settingEntityKey);
|
|
9633
|
-
resolvedViewName = entitySetting
|
|
10259
|
+
resolvedViewName = readPersistedEntityListInstanceCurrentView(entitySetting, this.listInstanceId());
|
|
9634
10260
|
}
|
|
9635
10261
|
const currentViewName = this.view().name;
|
|
9636
10262
|
const currentViewUnavailable = !availableViews.some((v) => v.name === currentViewName);
|
|
9637
|
-
const targetView = availableViews.find((c) => c.name === resolvedViewName) ??
|
|
9638
|
-
(currentViewUnavailable ? availableViews[0] : this.view());
|
|
10263
|
+
const targetView = availableViews.find((c) => c.name === resolvedViewName) ?? (currentViewUnavailable ? availableViews[0] : this.view());
|
|
9639
10264
|
const viewChanged = targetView.name !== this.view().name;
|
|
9640
10265
|
// Columns start empty; bootstrap them on first setView even when the view name is unchanged
|
|
9641
10266
|
// (e.g. URL already has ?view=all matching the default view).
|
|
@@ -9688,6 +10313,11 @@ class AXPEntityMasterListViewModel {
|
|
|
9688
10313
|
this.lastAppliedFilterKey = null;
|
|
9689
10314
|
this.hasQueryParamsFilters = false; // Flag to prevent overriding queryParams filters
|
|
9690
10315
|
this.routeQueryContextKey = null;
|
|
10316
|
+
this.listInstanceId = signal(ENTITY_LIST_DEFAULT_INSTANCE_ID, /* @ts-ignore */
|
|
10317
|
+
...(ngDevMode ? [{ debugName: "listInstanceId" }] : /* istanbul ignore next */ []));
|
|
10318
|
+
/** Bumped when list-instance filters are re-seeded so the toolbar chips catch up. */
|
|
10319
|
+
this.listFilterSeedEpoch = signal(0, /* @ts-ignore */
|
|
10320
|
+
...(ngDevMode ? [{ debugName: "listFilterSeedEpoch" }] : /* istanbul ignore next */ []));
|
|
9691
10321
|
this.settingsUpdateChain = Promise.resolve();
|
|
9692
10322
|
this.initialListSettingsApplied = false;
|
|
9693
10323
|
/** Persisted expanded row ids for hierarchical lists (per view). */
|
|
@@ -9702,9 +10332,14 @@ class AXPEntityMasterListViewModel {
|
|
|
9702
10332
|
this.skipListPagingPersistence = false;
|
|
9703
10333
|
this.listPersistenceMode = null;
|
|
9704
10334
|
this.events$ = new Subject();
|
|
10335
|
+
/** Personal row/cell highlight rules for this entity. */
|
|
10336
|
+
this.userStylingRules = signal([], /* @ts-ignore */
|
|
10337
|
+
...(ngDevMode ? [{ debugName: "userStylingRules" }] : /* istanbul ignore next */ []));
|
|
9705
10338
|
//****************** Views ******************//
|
|
10339
|
+
this.customQueryViews = signal([], /* @ts-ignore */
|
|
10340
|
+
...(ngDevMode ? [{ debugName: "customQueryViews" }] : /* istanbul ignore next */ []));
|
|
9706
10341
|
this.allViews = computed(() => {
|
|
9707
|
-
const views = this.entityDef.interfaces?.master?.list?.views
|
|
10342
|
+
const views = mergeDefinitionAndCustomQueryViews(this.entityDef.interfaces?.master?.list?.views, this.customQueryViews());
|
|
9708
10343
|
return views.map((v) => {
|
|
9709
10344
|
return new AXPEntityMasterListViewQueryViewModel(this.entityDef, this, v);
|
|
9710
10345
|
});
|
|
@@ -9719,8 +10354,22 @@ class AXPEntityMasterListViewModel {
|
|
|
9719
10354
|
...(ngDevMode ? [{ debugName: "views" }] : /* istanbul ignore next */ []));
|
|
9720
10355
|
this.view = signal(this.allViews()[0], /* @ts-ignore */
|
|
9721
10356
|
...(ngDevMode ? [{ debugName: "view" }] : /* istanbul ignore next */ []));
|
|
10357
|
+
this.isActiveQueryViewDirty = computed(() => isQueryViewDirty({
|
|
10358
|
+
view: this.toQueryView(this.view()),
|
|
10359
|
+
persistableFilters: this.getPersistableFilterQueries(this.filterQueries()),
|
|
10360
|
+
currentSorts: this.currentQueryViewSorts(),
|
|
10361
|
+
currentColumns: this.currentQueryViewColumns(),
|
|
10362
|
+
defaultColumns: this.defaultQueryViewColumns(),
|
|
10363
|
+
}), /* @ts-ignore */
|
|
10364
|
+
...(ngDevMode ? [{ debugName: "isActiveQueryViewDirty" }] : /* istanbul ignore next */ []));
|
|
10365
|
+
this.isActiveQueryViewCustom = computed(() => isCustomQueryView(this.view()), /* @ts-ignore */
|
|
10366
|
+
...(ngDevMode ? [{ debugName: "isActiveQueryViewCustom" }] : /* istanbul ignore next */ []));
|
|
10367
|
+
this.canSaveActiveQueryView = computed(() => this.isActiveQueryViewDirty() && !this.isActiveQueryViewCustom(), /* @ts-ignore */
|
|
10368
|
+
...(ngDevMode ? [{ debugName: "canSaveActiveQueryView" }] : /* istanbul ignore next */ []));
|
|
9722
10369
|
this.showRowIndexColumnEnabled = signal(false, /* @ts-ignore */
|
|
9723
10370
|
...(ngDevMode ? [{ debugName: "showRowIndexColumnEnabled" }] : /* istanbul ignore next */ []));
|
|
10371
|
+
this.multiLevelHeadersEnabled = signal(false, /* @ts-ignore */
|
|
10372
|
+
...(ngDevMode ? [{ debugName: "multiLevelHeadersEnabled" }] : /* istanbul ignore next */ []));
|
|
9724
10373
|
/**
|
|
9725
10374
|
* Row index column: if the list view defines `indexCol` (true/false), that overrides the user setting;
|
|
9726
10375
|
* if `indexCol` is omitted, visibility follows {@link AXPCommonSettings.ShowRowIndexColumn}.
|
|
@@ -9737,6 +10386,12 @@ class AXPEntityMasterListViewModel {
|
|
|
9737
10386
|
/** Layouts enabled via table (always) and `interfaces.master.card.enabled`. */
|
|
9738
10387
|
this.enabledListLayouts = computed(() => resolveEnabledMasterListLayouts(this.entityDef.interfaces?.master?.card), /* @ts-ignore */
|
|
9739
10388
|
...(ngDevMode ? [{ debugName: "enabledListLayouts" }] : /* istanbul ignore next */ []));
|
|
10389
|
+
/** List filter editor mode from `interfaces.master.list.filterMode`. Default advanced while testing. */
|
|
10390
|
+
this.filterMode = computed(() => (this.entityDef.interfaces?.master?.list?.filterMode === 'normal' ? 'normal' : 'advanced'), /* @ts-ignore */
|
|
10391
|
+
...(ngDevMode ? [{ debugName: "filterMode" }] : /* istanbul ignore next */ []));
|
|
10392
|
+
/** Named sort recipes from `interfaces.master.list.sortPresets`. */
|
|
10393
|
+
this.sortPresets = computed(() => collectEntityListSortPresets(this.entityDef), /* @ts-ignore */
|
|
10394
|
+
...(ngDevMode ? [{ debugName: "sortPresets" }] : /* istanbul ignore next */ []));
|
|
9740
10395
|
/** True when the user can switch between multiple enabled layouts. */
|
|
9741
10396
|
this.canSwitchListLayout = computed(() => this.enabledListLayouts().length > 1, /* @ts-ignore */
|
|
9742
10397
|
...(ngDevMode ? [{ debugName: "canSwitchListLayout" }] : /* istanbul ignore next */ []));
|
|
@@ -9774,9 +10429,7 @@ class AXPEntityMasterListViewModel {
|
|
|
9774
10429
|
},
|
|
9775
10430
|
load: async (e) => {
|
|
9776
10431
|
resetPagingForTreeChildrenLoad(e, this.entityDef.parentKey);
|
|
9777
|
-
const listRequest = this.entityDef.parentKey != null
|
|
9778
|
-
? applyHierarchicalRootListFilter(e, this.entityDef.parentKey)
|
|
9779
|
-
: e;
|
|
10432
|
+
const listRequest = this.entityDef.parentKey != null ? applyHierarchicalRootListFilter(e, this.entityDef.parentKey) : e;
|
|
9780
10433
|
const fields = this.buildColumnQueryFields();
|
|
9781
10434
|
const requestWithFields = fields?.length ? { ...listRequest, fields } : listRequest;
|
|
9782
10435
|
const execute = this.entityDef.queries?.list?.execute;
|
|
@@ -9792,6 +10445,7 @@ class AXPEntityMasterListViewModel {
|
|
|
9792
10445
|
pageSize: this.view().pageSize || 10,
|
|
9793
10446
|
key: 'id',
|
|
9794
10447
|
});
|
|
10448
|
+
this.customQueryViewsLoaded = false;
|
|
9795
10449
|
this.selectedItems = signal([], /* @ts-ignore */
|
|
9796
10450
|
...(ngDevMode ? [{ debugName: "selectedItems" }] : /* istanbul ignore next */ []));
|
|
9797
10451
|
/**
|
|
@@ -9880,8 +10534,9 @@ class AXPEntityMasterListViewModel {
|
|
|
9880
10534
|
const { columns = [], properties } = this.entityDef;
|
|
9881
10535
|
// const visibleProperties = properties.filter(({ schema }) => schema?.visible !== false);
|
|
9882
10536
|
const propNames = new Set(properties.map(({ name }) => name));
|
|
9883
|
-
|
|
9884
|
-
|
|
10537
|
+
// Keep `options.visible: false` columns — they stay in the picker, off by default.
|
|
10538
|
+
return flattenEntityTableColumns(columns)
|
|
10539
|
+
.filter(({ name, showAs }) => propNames.has(name) || !!showAs)
|
|
9885
10540
|
.map((column) => {
|
|
9886
10541
|
const relatedProperty = this.resolveMergeDetailProperty(column.name);
|
|
9887
10542
|
const entityProperty = properties.find(({ name }) => name === column.name);
|
|
@@ -9914,6 +10569,8 @@ class AXPEntityMasterListViewModel {
|
|
|
9914
10569
|
};
|
|
9915
10570
|
this.columns = signal([], /* @ts-ignore */
|
|
9916
10571
|
...(ngDevMode ? [{ debugName: "columns" }] : /* istanbul ignore next */ []));
|
|
10572
|
+
this.columnTree = signal([], /* @ts-ignore */
|
|
10573
|
+
...(ngDevMode ? [{ debugName: "columnTree" }] : /* istanbul ignore next */ []));
|
|
9917
10574
|
this.allAvailableCardFields = () => {
|
|
9918
10575
|
return this.cardFieldsResolver.resolve(this.entityDef, this.cardLayout());
|
|
9919
10576
|
};
|
|
@@ -9959,13 +10616,16 @@ class AXPEntityMasterListViewModel {
|
|
|
9959
10616
|
});
|
|
9960
10617
|
this.sortedFields.set([]);
|
|
9961
10618
|
void this.syncShowRowIndexColumnSetting();
|
|
10619
|
+
void this.syncMultiLevelHeadersSetting();
|
|
9962
10620
|
void this.applyGlobalListDisplayMode();
|
|
9963
10621
|
this.settings.onLoaded.pipe(takeUntil(this.destroyed)).subscribe(() => {
|
|
9964
10622
|
void this.syncShowRowIndexColumnSetting();
|
|
10623
|
+
void this.syncMultiLevelHeadersSetting();
|
|
9965
10624
|
void this.applyGlobalListDisplayMode();
|
|
9966
10625
|
});
|
|
9967
10626
|
this.settings.onChanged.pipe(takeUntil(this.destroyed)).subscribe(() => {
|
|
9968
10627
|
void this.syncShowRowIndexColumnSetting();
|
|
10628
|
+
void this.syncMultiLevelHeadersSetting();
|
|
9969
10629
|
void this.applyGlobalListDisplayMode();
|
|
9970
10630
|
});
|
|
9971
10631
|
}
|
|
@@ -9979,6 +10639,28 @@ class AXPEntityMasterListViewModel {
|
|
|
9979
10639
|
this.showRowIndexColumnEnabled.set(false);
|
|
9980
10640
|
}
|
|
9981
10641
|
}
|
|
10642
|
+
async syncMultiLevelHeadersSetting() {
|
|
10643
|
+
try {
|
|
10644
|
+
const value = await this.settings.get(AXPCommonSettings.EntityMultiLevelHeaders);
|
|
10645
|
+
const enabled = value ?? false;
|
|
10646
|
+
if (this.multiLevelHeadersEnabled() !== enabled) {
|
|
10647
|
+
this.multiLevelHeadersEnabled.set(enabled);
|
|
10648
|
+
this.rebuildColumnTree();
|
|
10649
|
+
}
|
|
10650
|
+
else {
|
|
10651
|
+
this.multiLevelHeadersEnabled.set(enabled);
|
|
10652
|
+
}
|
|
10653
|
+
}
|
|
10654
|
+
catch {
|
|
10655
|
+
if (this.multiLevelHeadersEnabled()) {
|
|
10656
|
+
this.multiLevelHeadersEnabled.set(false);
|
|
10657
|
+
this.rebuildColumnTree();
|
|
10658
|
+
}
|
|
10659
|
+
else {
|
|
10660
|
+
this.multiLevelHeadersEnabled.set(false);
|
|
10661
|
+
}
|
|
10662
|
+
}
|
|
10663
|
+
}
|
|
9982
10664
|
/**
|
|
9983
10665
|
* Applies {@link AXPCommonSettings.EntityListPersistenceMode} for this list instance.
|
|
9984
10666
|
* Call once when the list view model is created (before loading list UI state).
|
|
@@ -10006,6 +10688,9 @@ class AXPEntityMasterListViewModel {
|
|
|
10006
10688
|
}
|
|
10007
10689
|
}
|
|
10008
10690
|
}
|
|
10691
|
+
setListInstanceId(instanceId) {
|
|
10692
|
+
this.listInstanceId.set(axpNormalizeEntityListInstanceId(instanceId));
|
|
10693
|
+
}
|
|
10009
10694
|
async getListPersistenceMode() {
|
|
10010
10695
|
if (this.listPersistenceMode != null) {
|
|
10011
10696
|
return this.listPersistenceMode;
|
|
@@ -10042,10 +10727,16 @@ class AXPEntityMasterListViewModel {
|
|
|
10042
10727
|
}
|
|
10043
10728
|
const listViewSetting = await this.settings.get(this.settingEntityKey);
|
|
10044
10729
|
if (listViewSetting) {
|
|
10045
|
-
const
|
|
10046
|
-
const
|
|
10047
|
-
|
|
10048
|
-
//
|
|
10730
|
+
const viewSetting = listViewSetting.list?.views?.[this.view().name];
|
|
10731
|
+
const columnsVersion = Number(viewSetting?.columnsVersion ?? 0);
|
|
10732
|
+
let columns = viewSetting?.columns;
|
|
10733
|
+
// Product modules register migrate-drop columns via configureEntityListColumnsSettingsMigrateDrop.
|
|
10734
|
+
const migrateDrop = getEntityListColumnsSettingsMigrateDrop();
|
|
10735
|
+
const settingsVersion = getEntityListColumnsSettingsVersion();
|
|
10736
|
+
if (columnsVersion < settingsVersion && Array.isArray(columns) && migrateDrop.size > 0) {
|
|
10737
|
+
columns = columns.filter((col) => !migrateDrop.has(String(col.name)));
|
|
10738
|
+
}
|
|
10739
|
+
const sorts = viewSetting?.sorts;
|
|
10049
10740
|
let columnVisibilityMap;
|
|
10050
10741
|
let columnWidthsMap;
|
|
10051
10742
|
if (columns) {
|
|
@@ -10055,17 +10746,16 @@ class AXPEntityMasterListViewModel {
|
|
|
10055
10746
|
this.loadListPagingFromViewSettings(listViewSetting);
|
|
10056
10747
|
if (columns && columnVisibilityMap && columnWidthsMap) {
|
|
10057
10748
|
this.columns.update((prev) => {
|
|
10058
|
-
const next =
|
|
10059
|
-
columns.findIndex((col) => col.name === (b.column?.options?.dataPath ?? b.name)));
|
|
10749
|
+
const next = this.mergePersistedColumnOrder(prev, columns.map((col) => String(col.name)));
|
|
10060
10750
|
for (const column of next) {
|
|
10061
10751
|
const columnKey = column.column?.options?.dataPath ?? column.name;
|
|
10062
10752
|
column.width = defaultTo(columnWidthsMap.get(columnKey), column.column?.options?.width);
|
|
10063
|
-
// Definition
|
|
10064
|
-
// Persisted
|
|
10065
|
-
const definitionVisible = column.visible === true;
|
|
10753
|
+
// Definition supplies the default (entity / view `visible`).
|
|
10754
|
+
// Persisted user choice overrides when present (including enabling a default-off column).
|
|
10066
10755
|
const persistedVisible = columnVisibilityMap.get(columnKey);
|
|
10067
|
-
|
|
10068
|
-
|
|
10756
|
+
if (persistedVisible !== undefined) {
|
|
10757
|
+
column.visible = persistedVisible !== false;
|
|
10758
|
+
}
|
|
10069
10759
|
}
|
|
10070
10760
|
return next;
|
|
10071
10761
|
});
|
|
@@ -10073,11 +10763,10 @@ class AXPEntityMasterListViewModel {
|
|
|
10073
10763
|
if (Array.isArray(sorts) && sorts.length) {
|
|
10074
10764
|
this.setActiveSortsFromQueries(sorts);
|
|
10075
10765
|
}
|
|
10076
|
-
|
|
10077
|
-
|
|
10078
|
-
|
|
10079
|
-
|
|
10080
|
-
// }
|
|
10766
|
+
if (!this.hasQueryParamsFilters) {
|
|
10767
|
+
const persistedFilters = readPersistedEntityListInstanceFilters(listViewSetting, this.listInstanceId(), this.view().name);
|
|
10768
|
+
this.filterQueries.set(mergeEntityListViewAndPersistedFilters(this.filterQueries(), persistedFilters));
|
|
10769
|
+
}
|
|
10081
10770
|
const expandedRowIds = listViewSetting.list?.views?.[this.view().name]?.expandedRowIds;
|
|
10082
10771
|
if (Array.isArray(expandedRowIds)) {
|
|
10083
10772
|
this.expandedRowIds.set(expandedRowIds.map((id) => String(id)).filter(Boolean));
|
|
@@ -10107,8 +10796,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10107
10796
|
this.loadListPagingFromViewSettings(entitySetting);
|
|
10108
10797
|
}
|
|
10109
10798
|
getResolvedListPaging() {
|
|
10110
|
-
return
|
|
10111
|
-
normalizeListPaging(undefined, this.view().pageSize || this.dataSource.config.pageSize || 10));
|
|
10799
|
+
return this.resolvedListPaging() ?? normalizeListPaging(undefined, this.view().pageSize || this.dataSource.config.pageSize || 10);
|
|
10112
10800
|
}
|
|
10113
10801
|
applyPagingToDataSourceWithoutLoad() {
|
|
10114
10802
|
applyDataSourcePagingWithoutLoad(this.dataSource, this.getResolvedListPaging());
|
|
@@ -10171,29 +10859,150 @@ class AXPEntityMasterListViewModel {
|
|
|
10171
10859
|
* User-applied filters to persist (excludes hidden view conditions and empty values).
|
|
10172
10860
|
*/
|
|
10173
10861
|
getPersistableFilterQueries(queries = this.filterQueries()) {
|
|
10174
|
-
return queries.filter((f) =>
|
|
10175
|
-
|
|
10176
|
-
|
|
10177
|
-
|
|
10178
|
-
|
|
10179
|
-
|
|
10180
|
-
|
|
10181
|
-
|
|
10182
|
-
|
|
10183
|
-
|
|
10862
|
+
return flattenQueryFilterUserGroups(queries).queries.filter((f) => isPersistableFilterQuery(f));
|
|
10863
|
+
}
|
|
10864
|
+
async createCustomQueryView(input) {
|
|
10865
|
+
const sourceViewName = this.view().name;
|
|
10866
|
+
const name = createCustomQueryViewName();
|
|
10867
|
+
const view = this.snapshotActiveQueryView(name, input.title, input.includeActiveView);
|
|
10868
|
+
await this.persistCustomQueryView(view, { activate: false, clearInstanceFilters: false });
|
|
10869
|
+
await this.resetViewInstanceOverlays(sourceViewName);
|
|
10870
|
+
return name;
|
|
10871
|
+
}
|
|
10872
|
+
async updateCustomQueryView(input) {
|
|
10873
|
+
const name = this.view().name;
|
|
10874
|
+
const view = this.snapshotActiveQueryView(name, input.title, true);
|
|
10875
|
+
await this.persistCustomQueryView(view, { activate: true, clearInstanceFilters: true });
|
|
10876
|
+
return name;
|
|
10877
|
+
}
|
|
10878
|
+
async deleteCustomQueryView(name) {
|
|
10879
|
+
const target = this.views().find((view) => view.name === name);
|
|
10880
|
+
if (!target || !isCustomQueryView(target)) {
|
|
10881
|
+
return this.view().name;
|
|
10882
|
+
}
|
|
10883
|
+
await this.enqueueSettingsUpdate((prev) => removePersistedCustomQueryView(prev, name));
|
|
10884
|
+
this.customQueryViews.update((views) => views.filter((view) => view.name !== name));
|
|
10885
|
+
await this.refreshVisibleViews();
|
|
10886
|
+
const remaining = this.views();
|
|
10887
|
+
if (this.view().name !== name) {
|
|
10888
|
+
return this.view().name;
|
|
10889
|
+
}
|
|
10890
|
+
return remaining[0]?.name ?? null;
|
|
10891
|
+
}
|
|
10892
|
+
async loadCustomQueryViews() {
|
|
10893
|
+
if (this.customQueryViewsLoaded) {
|
|
10894
|
+
return;
|
|
10895
|
+
}
|
|
10896
|
+
const setting = await this.settings.get(this.settingEntityKey);
|
|
10897
|
+
this.customQueryViews.set(readPersistedCustomQueryViews(setting));
|
|
10898
|
+
this.customQueryViewsLoaded = true;
|
|
10899
|
+
}
|
|
10900
|
+
async persistCustomQueryView(view, options) {
|
|
10901
|
+
await this.enqueueSettingsUpdate((prev) => upsertPersistedCustomQueryView(prev, view));
|
|
10902
|
+
this.customQueryViews.update((views) => {
|
|
10903
|
+
const index = views.findIndex((item) => item.name === view.name);
|
|
10904
|
+
return index >= 0 ? views.map((item, i) => (i === index ? view : item)) : [...views, view];
|
|
10905
|
+
});
|
|
10906
|
+
await this.refreshVisibleViews();
|
|
10907
|
+
if (options.activate) {
|
|
10908
|
+
const next = this.views().find((item) => item.name === view.name);
|
|
10909
|
+
if (next) {
|
|
10910
|
+
this.view.set(next);
|
|
10911
|
+
this.applyViewSorts();
|
|
10912
|
+
await this.applyViewColumns();
|
|
10913
|
+
await this.applyViewFilters();
|
|
10184
10914
|
}
|
|
10185
|
-
|
|
10186
|
-
|
|
10915
|
+
}
|
|
10916
|
+
if (options.clearInstanceFilters) {
|
|
10917
|
+
await this.saveSettings('filters', []);
|
|
10918
|
+
}
|
|
10919
|
+
}
|
|
10920
|
+
/** Clears user overlays so the source view returns to its definition defaults after Save View. */
|
|
10921
|
+
async resetViewInstanceOverlays(viewName) {
|
|
10922
|
+
if (!(await this.shouldPersistListState())) {
|
|
10923
|
+
return;
|
|
10924
|
+
}
|
|
10925
|
+
await this.enqueueSettingsUpdate((prev) => {
|
|
10926
|
+
const next = cloneDeep(prev ?? {});
|
|
10927
|
+
set(next, entityListInstanceFilterPath(this.listInstanceId(), viewName), []);
|
|
10928
|
+
set(next, ['list', 'views', viewName, 'filters'], []);
|
|
10929
|
+
const viewSetting = next?.list?.views?.[viewName];
|
|
10930
|
+
if (viewSetting && typeof viewSetting === 'object') {
|
|
10931
|
+
delete viewSetting['columns'];
|
|
10932
|
+
delete viewSetting['sorts'];
|
|
10187
10933
|
}
|
|
10188
|
-
return
|
|
10934
|
+
return next;
|
|
10189
10935
|
});
|
|
10190
10936
|
}
|
|
10937
|
+
snapshotActiveQueryView(name, title, includeActiveView) {
|
|
10938
|
+
return snapshotCustomQueryView({
|
|
10939
|
+
name,
|
|
10940
|
+
title,
|
|
10941
|
+
includeActiveView,
|
|
10942
|
+
activeView: this.toQueryView(this.view()),
|
|
10943
|
+
currentFilters: this.filterQueries(),
|
|
10944
|
+
currentSorts: this.currentQueryViewSorts(),
|
|
10945
|
+
currentColumns: this.currentQueryViewColumns(),
|
|
10946
|
+
});
|
|
10947
|
+
}
|
|
10948
|
+
toQueryView(view) {
|
|
10949
|
+
return {
|
|
10950
|
+
name: view.name,
|
|
10951
|
+
title: view.title,
|
|
10952
|
+
fixed: view.fixed,
|
|
10953
|
+
custom: view.custom,
|
|
10954
|
+
columns: view.columns,
|
|
10955
|
+
conditions: view.conditions,
|
|
10956
|
+
sorts: view.sorts,
|
|
10957
|
+
indexCol: view.indexCol,
|
|
10958
|
+
pageSize: view.pageSize,
|
|
10959
|
+
visible: view.visible,
|
|
10960
|
+
};
|
|
10961
|
+
}
|
|
10962
|
+
currentQueryViewSorts() {
|
|
10963
|
+
return this.sortedFields()
|
|
10964
|
+
.filter((sort) => sort.dir === 'asc' || sort.dir === 'desc')
|
|
10965
|
+
.map((sort) => ({ name: sort.name, dir: sort.dir }));
|
|
10966
|
+
}
|
|
10967
|
+
currentQueryViewColumns() {
|
|
10968
|
+
return this.columns().map((column) => ({
|
|
10969
|
+
name: column.column?.options?.dataPath ?? column.name,
|
|
10970
|
+
visible: isQueryViewColumnVisible(column.visible),
|
|
10971
|
+
width: column.width,
|
|
10972
|
+
}));
|
|
10973
|
+
}
|
|
10974
|
+
defaultQueryViewColumns() {
|
|
10975
|
+
return this.allAvailableColumns().map((column) => ({
|
|
10976
|
+
name: column.column?.options?.dataPath ?? column.name,
|
|
10977
|
+
visible: isQueryViewColumnVisible(column.visible),
|
|
10978
|
+
}));
|
|
10979
|
+
}
|
|
10191
10980
|
enqueueSettingsUpdate(updateFn) {
|
|
10192
10981
|
const run = () => this.settings.scope(AXPPlatformScope.User).update(this.settingEntityKey, updateFn);
|
|
10193
10982
|
const next = this.settingsUpdateChain.then(run);
|
|
10194
10983
|
this.settingsUpdateChain = next.catch(() => undefined);
|
|
10195
10984
|
return next;
|
|
10196
10985
|
}
|
|
10986
|
+
async loadUserStylingRules() {
|
|
10987
|
+
if (!(await this.shouldLoadPersistedListState())) {
|
|
10988
|
+
this.userStylingRules.set([]);
|
|
10989
|
+
return;
|
|
10990
|
+
}
|
|
10991
|
+
const setting = await this.settings.get(this.settingEntityKey);
|
|
10992
|
+
this.userStylingRules.set(readPersistedEntityListStylingRules(setting));
|
|
10993
|
+
}
|
|
10994
|
+
async saveUserStylingRules(rules) {
|
|
10995
|
+
const normalized = normalizeEntityListUserStylingRules(rules);
|
|
10996
|
+
this.userStylingRules.set(normalized);
|
|
10997
|
+
if (!(await this.shouldPersistListState())) {
|
|
10998
|
+
return;
|
|
10999
|
+
}
|
|
11000
|
+
await this.enqueueSettingsUpdate((prev) => {
|
|
11001
|
+
const next = cloneDeep(prev ?? {});
|
|
11002
|
+
set(next, [...entityListStylingRulesPath()], normalized);
|
|
11003
|
+
return next;
|
|
11004
|
+
});
|
|
11005
|
+
}
|
|
10197
11006
|
async saveSettings(changesType, data) {
|
|
10198
11007
|
if (!(await this.shouldPersistListState())) {
|
|
10199
11008
|
return;
|
|
@@ -10217,6 +11026,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10217
11026
|
width: c.name === field ? columnSizeData.width : c.width,
|
|
10218
11027
|
}));
|
|
10219
11028
|
set(newSettings, `list.views.${this.view().name}.columns`, updatedColumns);
|
|
11029
|
+
set(newSettings, `list.views.${this.view().name}.columnsVersion`, getEntityListColumnsSettingsVersion());
|
|
10220
11030
|
return newSettings;
|
|
10221
11031
|
});
|
|
10222
11032
|
break;
|
|
@@ -10230,18 +11040,17 @@ class AXPEntityMasterListViewModel {
|
|
|
10230
11040
|
visible: c.visible,
|
|
10231
11041
|
width: c.width,
|
|
10232
11042
|
})));
|
|
11043
|
+
set(newSettings, `list.views.${this.view().name}.columnsVersion`, getEntityListColumnsSettingsVersion());
|
|
10233
11044
|
return newSettings;
|
|
10234
11045
|
});
|
|
10235
11046
|
break;
|
|
10236
11047
|
}
|
|
10237
11048
|
case 'view':
|
|
10238
|
-
await this.enqueueSettingsUpdate((prev) =>
|
|
10239
|
-
...prev
|
|
10240
|
-
|
|
10241
|
-
|
|
10242
|
-
|
|
10243
|
-
},
|
|
10244
|
-
}));
|
|
11049
|
+
await this.enqueueSettingsUpdate((prev) => {
|
|
11050
|
+
const newSettings = { ...prev };
|
|
11051
|
+
set(newSettings, entityListInstanceCurrentViewPath(this.listInstanceId()), this.view().name);
|
|
11052
|
+
return newSettings;
|
|
11053
|
+
});
|
|
10245
11054
|
break;
|
|
10246
11055
|
case 'pageSize':
|
|
10247
11056
|
await this.enqueueSettingsUpdate((prev) => ({
|
|
@@ -10279,19 +11088,13 @@ class AXPEntityMasterListViewModel {
|
|
|
10279
11088
|
}));
|
|
10280
11089
|
break;
|
|
10281
11090
|
case 'filters':
|
|
10282
|
-
await this.enqueueSettingsUpdate((prev) =>
|
|
10283
|
-
|
|
10284
|
-
|
|
10285
|
-
|
|
10286
|
-
|
|
10287
|
-
|
|
10288
|
-
|
|
10289
|
-
...prev?.list?.views?.[this.view().name],
|
|
10290
|
-
filters: data,
|
|
10291
|
-
},
|
|
10292
|
-
},
|
|
10293
|
-
},
|
|
10294
|
-
}));
|
|
11091
|
+
await this.enqueueSettingsUpdate((prev) => {
|
|
11092
|
+
const newSettings = cloneDeep(prev ?? {});
|
|
11093
|
+
const nextFilters = Array.isArray(data) ? data : [];
|
|
11094
|
+
set(newSettings, entityListInstanceFilterPath(this.listInstanceId(), this.view().name), nextFilters);
|
|
11095
|
+
set(newSettings, ['list', 'views', this.view().name, 'filters'], nextFilters);
|
|
11096
|
+
return newSettings;
|
|
11097
|
+
});
|
|
10295
11098
|
break;
|
|
10296
11099
|
case 'sorts':
|
|
10297
11100
|
await this.enqueueSettingsUpdate((prev) => ({
|
|
@@ -10351,9 +11154,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10351
11154
|
async getPrimaryActions() {
|
|
10352
11155
|
const scope = this.createLogicExpressionScope(null);
|
|
10353
11156
|
const actions = await Promise.all(this.allActions()
|
|
10354
|
-
.filter((a) => a.priority == 'primary' &&
|
|
10355
|
-
((a.scope == AXPEntityCommandScope.Selected && this.hasSelectedItems()) ||
|
|
10356
|
-
(a.scope == AXPEntityCommandScope.TypeLevel && !this.hasSelectedItems())))
|
|
11157
|
+
.filter((a) => a.priority == 'primary' && ((a.scope == AXPEntityCommandScope.Selected && this.hasSelectedItems()) || (a.scope == AXPEntityCommandScope.TypeLevel && !this.hasSelectedItems())))
|
|
10357
11158
|
.map(async (a) => {
|
|
10358
11159
|
const isHidden = await this.expressionEvaluator.evaluate(a.hidden, scope);
|
|
10359
11160
|
if (isHidden)
|
|
@@ -10368,9 +11169,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10368
11169
|
async getSecondaryActions() {
|
|
10369
11170
|
const scope = this.createLogicExpressionScope(null);
|
|
10370
11171
|
const actions = await Promise.all(this.allActions()
|
|
10371
|
-
.filter((a) => a.priority == 'secondary' &&
|
|
10372
|
-
((a.scope == AXPEntityCommandScope.Selected && this.hasSelectedItems()) ||
|
|
10373
|
-
(a.scope == AXPEntityCommandScope.TypeLevel && !this.hasSelectedItems())))
|
|
11172
|
+
.filter((a) => a.priority == 'secondary' && ((a.scope == AXPEntityCommandScope.Selected && this.hasSelectedItems()) || (a.scope == AXPEntityCommandScope.TypeLevel && !this.hasSelectedItems())))
|
|
10374
11173
|
.map(async (a) => {
|
|
10375
11174
|
const isHidden = await this.expressionEvaluator.evaluate(a.hidden, scope);
|
|
10376
11175
|
if (isHidden)
|
|
@@ -10423,19 +11222,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10423
11222
|
});
|
|
10424
11223
|
return items;
|
|
10425
11224
|
}
|
|
10426
|
-
static { this.URL_FILTER_OPERATOR_TYPES = new Set([
|
|
10427
|
-
'equal',
|
|
10428
|
-
'isNull',
|
|
10429
|
-
'isEmpty',
|
|
10430
|
-
'lt',
|
|
10431
|
-
'lte',
|
|
10432
|
-
'gt',
|
|
10433
|
-
'gte',
|
|
10434
|
-
'startsWith',
|
|
10435
|
-
'endsWith',
|
|
10436
|
-
'contains',
|
|
10437
|
-
'in',
|
|
10438
|
-
]); }
|
|
11225
|
+
static { this.URL_FILTER_OPERATOR_TYPES = new Set(['equal', 'isNull', 'isEmpty', 'lt', 'lte', 'gt', 'gte', 'startsWith', 'endsWith', 'contains', 'in']); }
|
|
10439
11226
|
get properties() {
|
|
10440
11227
|
return this.entityDef.properties;
|
|
10441
11228
|
}
|
|
@@ -10483,13 +11270,37 @@ class AXPEntityMasterListViewModel {
|
|
|
10483
11270
|
}
|
|
10484
11271
|
toUrlFilterPayloadItems(queries) {
|
|
10485
11272
|
return queries
|
|
10486
|
-
.filter((f) =>
|
|
10487
|
-
|
|
10488
|
-
|
|
10489
|
-
|
|
10490
|
-
|
|
10491
|
-
|
|
10492
|
-
|
|
11273
|
+
.filter((f) => {
|
|
11274
|
+
if (f.filters?.length) {
|
|
11275
|
+
return f.filters.some((child) => isCompleteFilterCondition(child.operator?.type, child.value));
|
|
11276
|
+
}
|
|
11277
|
+
if (typeof f.field !== 'string' || f.field === '') {
|
|
11278
|
+
return false;
|
|
11279
|
+
}
|
|
11280
|
+
return isCompleteFilterCondition(f.operator?.type, f.value);
|
|
11281
|
+
})
|
|
11282
|
+
.map((f) => {
|
|
11283
|
+
if (f.filters?.length) {
|
|
11284
|
+
return {
|
|
11285
|
+
logic: f.logic ?? 'and',
|
|
11286
|
+
filters: f.filters.map((child) => ({
|
|
11287
|
+
field: child.field,
|
|
11288
|
+
operator: AXPEntityMasterListViewModel.coerceFilterOperatorFromUrl(child.operator),
|
|
11289
|
+
value: child.value,
|
|
11290
|
+
})),
|
|
11291
|
+
};
|
|
11292
|
+
}
|
|
11293
|
+
return {
|
|
11294
|
+
field: f.field,
|
|
11295
|
+
operator: AXPEntityMasterListViewModel.coerceFilterOperatorFromUrl(f.operator),
|
|
11296
|
+
value: f.value,
|
|
11297
|
+
};
|
|
11298
|
+
})
|
|
11299
|
+
.sort((a, b) => {
|
|
11300
|
+
const left = resolveFilterQueryIdentityField(a) ?? '';
|
|
11301
|
+
const right = resolveFilterQueryIdentityField(b) ?? '';
|
|
11302
|
+
return left.localeCompare(right);
|
|
11303
|
+
});
|
|
10493
11304
|
}
|
|
10494
11305
|
static coerceFilterOperatorFromUrl(op) {
|
|
10495
11306
|
if (op && typeof op === 'object' && op !== null && 'type' in op) {
|
|
@@ -10555,7 +11366,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10555
11366
|
}
|
|
10556
11367
|
/**
|
|
10557
11368
|
* Reacts to any route query param change while the list route is reused (`reuse: queryParamsChange`).
|
|
10558
|
-
* Handles known keys (`view`, `filters`) and re-evaluates view visibility for expression-driven params.
|
|
11369
|
+
* Handles known keys (`view`, `filters`, `list`) and re-evaluates view visibility for expression-driven params.
|
|
10559
11370
|
*
|
|
10560
11371
|
* Data reload is owned by {@link applyFilterAndSort} → `events$` when criteria change.
|
|
10561
11372
|
* `reloadList` stays false so callers do not issue a second `reloadListData` for the same transition.
|
|
@@ -10566,12 +11377,24 @@ class AXPEntityMasterListViewModel {
|
|
|
10566
11377
|
return { reloadList: false };
|
|
10567
11378
|
}
|
|
10568
11379
|
this.routeQueryContextKey = contextKey;
|
|
11380
|
+
const nextInstanceId = axpGetEntityListInstanceIdFromParamMap(queryParamMap);
|
|
11381
|
+
const instanceChanged = nextInstanceId !== this.listInstanceId();
|
|
11382
|
+
if (instanceChanged) {
|
|
11383
|
+
this.listInstanceId.set(nextInstanceId);
|
|
11384
|
+
this.hasQueryParamsFilters = false;
|
|
11385
|
+
}
|
|
10569
11386
|
const previousViewName = this.view().name;
|
|
10570
11387
|
await this.setView(queryParamMap.get('view'));
|
|
11388
|
+
if (instanceChanged) {
|
|
11389
|
+
this.applyViewFilters();
|
|
11390
|
+
this.applyViewSorts();
|
|
11391
|
+
await this.loadPersistedInstanceFilters();
|
|
11392
|
+
this.listFilterSeedEpoch.update((epoch) => epoch + 1);
|
|
11393
|
+
}
|
|
10571
11394
|
const filtersChanged = await this.syncFiltersFromRouteQueryParam(queryParamMap.get('filters'));
|
|
10572
11395
|
await this.refreshVisibleViews();
|
|
10573
11396
|
const viewChanged = this.view().name !== previousViewName;
|
|
10574
|
-
if (filtersChanged || viewChanged) {
|
|
11397
|
+
if (filtersChanged || viewChanged || instanceChanged) {
|
|
10575
11398
|
this.lastAppliedFilterKey = null;
|
|
10576
11399
|
this.lastAppliedSortKey = null;
|
|
10577
11400
|
// Keys were cleared to force apply; pass reset so URL view/filter changes still reset paging
|
|
@@ -10648,12 +11471,16 @@ class AXPEntityMasterListViewModel {
|
|
|
10648
11471
|
if (this.hasQueryParamsFilters) {
|
|
10649
11472
|
return;
|
|
10650
11473
|
}
|
|
10651
|
-
const
|
|
10652
|
-
|
|
10653
|
-
|
|
10654
|
-
|
|
10655
|
-
|
|
10656
|
-
|
|
11474
|
+
const view = this.toQueryView(this.view());
|
|
11475
|
+
this.filterQueries.set(withQueryViewFilterVisibility(view, queryViewConditionsToFilterQueries(view)));
|
|
11476
|
+
}
|
|
11477
|
+
async loadPersistedInstanceFilters() {
|
|
11478
|
+
if (this.hasQueryParamsFilters || !(await this.shouldLoadPersistedListState())) {
|
|
11479
|
+
return;
|
|
11480
|
+
}
|
|
11481
|
+
const setting = await this.settings.get(this.settingEntityKey);
|
|
11482
|
+
const persistedFilters = readPersistedEntityListInstanceFilters(setting, this.listInstanceId(), this.view().name);
|
|
11483
|
+
this.filterQueries.set(mergeEntityListViewAndPersistedFilters(this.filterQueries(), persistedFilters));
|
|
10657
11484
|
}
|
|
10658
11485
|
resetFilters() {
|
|
10659
11486
|
this.hasQueryParamsFilters = false; // Reset flag when user resets filters
|
|
@@ -10690,48 +11517,214 @@ class AXPEntityMasterListViewModel {
|
|
|
10690
11517
|
if (shouldResetPagination) {
|
|
10691
11518
|
this.resetListPagingSkip();
|
|
10692
11519
|
}
|
|
10693
|
-
this.dataSource.clearFilter();
|
|
10694
|
-
this.dataSource.sort(...sorts.map((s) => ({ dir: s.dir, field: s.name })));
|
|
10695
|
-
this.dataSource.filter(transformedFilter);
|
|
10696
|
-
traceEntityMasterList('viewmodel', 'applyFilterAndSort emitting refresh', () => ({
|
|
10697
|
-
entity: getEntityInfo(this.entityDef).source,
|
|
10698
|
-
viewName: this.view().name,
|
|
10699
|
-
activeListLayout: this.activeListLayout(),
|
|
10700
|
-
filtersChanged,
|
|
10701
|
-
resetPagination: shouldResetPagination,
|
|
10702
|
-
filterCount: filters.length,
|
|
10703
|
-
sortCount: sorts.length,
|
|
10704
|
-
dataSource: buildDataSourceTraceSnapshot(this.dataSource),
|
|
10705
|
-
}));
|
|
10706
|
-
this.events$.next({ action: 'refresh', meta: { resetPagination: shouldResetPagination } });
|
|
10707
|
-
const hooks = this.injector.get(AXPHookService);
|
|
10708
|
-
fireEntityLifecycleHook(hooks, AXPEntityLifecycleHookKeys.ListCriteriaApplied, {
|
|
10709
|
-
module: this.entityDef.module,
|
|
10710
|
-
entityName: this.entityDef.name,
|
|
10711
|
-
filterCount: filters.length,
|
|
10712
|
-
sortCount: sorts.length,
|
|
10713
|
-
viewName: this.view().name,
|
|
10714
|
-
kind: sortsChanged && !filtersChanged ? 'sort' : filters.some((f) => f.field === 'all' || f.field === AXP_QUERY_QUICK_SEARCH_FIELD) ? 'search' : 'filter',
|
|
10715
|
-
});
|
|
10716
|
-
}
|
|
10717
|
-
updateAppliedInlineFilterHighlightText(filters) {
|
|
10718
|
-
const quickFilter = filters.find((f) => f.field === 'all' || f.field === AXP_QUERY_QUICK_SEARCH_FIELD);
|
|
10719
|
-
const value = quickFilter?.value;
|
|
10720
|
-
this.inlineFilterHighlightText.set(typeof value === 'string' ? value.trim() : '');
|
|
11520
|
+
this.dataSource.clearFilter();
|
|
11521
|
+
this.dataSource.sort(...sorts.map((s) => ({ dir: s.dir, field: s.name })));
|
|
11522
|
+
this.dataSource.filter(transformedFilter);
|
|
11523
|
+
traceEntityMasterList('viewmodel', 'applyFilterAndSort emitting refresh', () => ({
|
|
11524
|
+
entity: getEntityInfo(this.entityDef).source,
|
|
11525
|
+
viewName: this.view().name,
|
|
11526
|
+
activeListLayout: this.activeListLayout(),
|
|
11527
|
+
filtersChanged,
|
|
11528
|
+
resetPagination: shouldResetPagination,
|
|
11529
|
+
filterCount: filters.length,
|
|
11530
|
+
sortCount: sorts.length,
|
|
11531
|
+
dataSource: buildDataSourceTraceSnapshot(this.dataSource),
|
|
11532
|
+
}));
|
|
11533
|
+
this.events$.next({ action: 'refresh', meta: { resetPagination: shouldResetPagination } });
|
|
11534
|
+
const hooks = this.injector.get(AXPHookService);
|
|
11535
|
+
fireEntityLifecycleHook(hooks, AXPEntityLifecycleHookKeys.ListCriteriaApplied, {
|
|
11536
|
+
module: this.entityDef.module,
|
|
11537
|
+
entityName: this.entityDef.name,
|
|
11538
|
+
filterCount: filters.length,
|
|
11539
|
+
sortCount: sorts.length,
|
|
11540
|
+
viewName: this.view().name,
|
|
11541
|
+
kind: sortsChanged && !filtersChanged ? 'sort' : filters.some((f) => f.field === 'all' || f.field === AXP_QUERY_QUICK_SEARCH_FIELD) ? 'search' : 'filter',
|
|
11542
|
+
});
|
|
11543
|
+
}
|
|
11544
|
+
updateAppliedInlineFilterHighlightText(filters) {
|
|
11545
|
+
const quickFilter = flattenQueryFilterUserGroups(filters).queries.find((f) => f.field === 'all' || f.field === AXP_QUERY_QUICK_SEARCH_FIELD);
|
|
11546
|
+
const value = quickFilter?.value;
|
|
11547
|
+
this.inlineFilterHighlightText.set(typeof value === 'string' ? value.trim() : '');
|
|
11548
|
+
}
|
|
11549
|
+
//****************** Columns ******************//
|
|
11550
|
+
resolveMergeDetailSource(columnName) {
|
|
11551
|
+
const parsed = parseDottedFieldPath(columnName);
|
|
11552
|
+
if (!parsed) {
|
|
11553
|
+
return null;
|
|
11554
|
+
}
|
|
11555
|
+
const { dataPath, propertyName } = parsed;
|
|
11556
|
+
const related = this.entityDef.relatedEntities?.find((entry) => entry.layout?.type === 'merge-detail' && entry.persistence?.dataPath?.trim() === dataPath);
|
|
11557
|
+
if (!related?.entity) {
|
|
11558
|
+
return null;
|
|
11559
|
+
}
|
|
11560
|
+
const relatedDef = this.getRegisteredEntity(related.entity);
|
|
11561
|
+
const property = relatedDef?.properties?.find((item) => item.name === propertyName);
|
|
11562
|
+
if (!relatedDef || !property) {
|
|
11563
|
+
return null;
|
|
11564
|
+
}
|
|
11565
|
+
return { entity: relatedDef, property };
|
|
11566
|
+
}
|
|
11567
|
+
resolveMergeDetailProperty(columnName) {
|
|
11568
|
+
return this.resolveMergeDetailSource(columnName)?.property ?? null;
|
|
11569
|
+
}
|
|
11570
|
+
resolveColumnSection(column) {
|
|
11571
|
+
const mergeSource = this.resolveMergeDetailSource(column.name);
|
|
11572
|
+
const groupId = mergeSource?.property.groupId ?? column.property.groupId;
|
|
11573
|
+
if (!groupId) {
|
|
11574
|
+
return null;
|
|
11575
|
+
}
|
|
11576
|
+
const groups = mergeSource?.entity.groups ?? this.entityDef.groups;
|
|
11577
|
+
const group = groups?.find((item) => item.id === groupId);
|
|
11578
|
+
const title = group?.title?.trim();
|
|
11579
|
+
if (!title) {
|
|
11580
|
+
return null;
|
|
11581
|
+
}
|
|
11582
|
+
return { id: groupId, title };
|
|
11583
|
+
}
|
|
11584
|
+
findInnermostAuthorBand(columns, columnName) {
|
|
11585
|
+
for (const column of columns) {
|
|
11586
|
+
if (!isEntityColumnBand(column)) {
|
|
11587
|
+
continue;
|
|
11588
|
+
}
|
|
11589
|
+
const leaves = flattenEntityTableColumns(column.children);
|
|
11590
|
+
if (!leaves.some((leaf) => leaf.name === columnName)) {
|
|
11591
|
+
continue;
|
|
11592
|
+
}
|
|
11593
|
+
const deeper = this.findInnermostAuthorBand(column.children ?? [], columnName);
|
|
11594
|
+
return deeper ?? column;
|
|
11595
|
+
}
|
|
11596
|
+
return null;
|
|
11597
|
+
}
|
|
11598
|
+
buildSectionBandedColumnTree(leafByName) {
|
|
11599
|
+
const bucketOrder = [];
|
|
11600
|
+
const buckets = new Map();
|
|
11601
|
+
for (const column of this.columns()) {
|
|
11602
|
+
const authorBand = this.findInnermostAuthorBand(this.entityDef.columns ?? [], column.name);
|
|
11603
|
+
if (authorBand) {
|
|
11604
|
+
const key = `author:${authorBand.name}`;
|
|
11605
|
+
if (!buckets.has(key)) {
|
|
11606
|
+
bucketOrder.push(key);
|
|
11607
|
+
buckets.set(key, authorBand);
|
|
11608
|
+
}
|
|
11609
|
+
continue;
|
|
11610
|
+
}
|
|
11611
|
+
const section = this.resolveColumnSection(column);
|
|
11612
|
+
if (section) {
|
|
11613
|
+
const key = `section:${section.id}`;
|
|
11614
|
+
const existing = buckets.get(key);
|
|
11615
|
+
if (existing && typeof existing === 'object' && 'kind' in existing && existing.kind === 'section') {
|
|
11616
|
+
existing.leafNames.push(column.name);
|
|
11617
|
+
}
|
|
11618
|
+
else if (!existing) {
|
|
11619
|
+
bucketOrder.push(key);
|
|
11620
|
+
buckets.set(key, { kind: 'section', id: section.id, title: section.title, leafNames: [column.name] });
|
|
11621
|
+
}
|
|
11622
|
+
continue;
|
|
11623
|
+
}
|
|
11624
|
+
bucketOrder.push(`singleton:${column.name}`);
|
|
11625
|
+
}
|
|
11626
|
+
const nodes = [];
|
|
11627
|
+
for (const key of bucketOrder) {
|
|
11628
|
+
const bucket = buckets.get(key);
|
|
11629
|
+
if (!bucket) {
|
|
11630
|
+
continue;
|
|
11631
|
+
}
|
|
11632
|
+
if (key.startsWith('author:')) {
|
|
11633
|
+
const band = bucket;
|
|
11634
|
+
nodes.push(...this.buildMasterListColumnTree([band], leafByName));
|
|
11635
|
+
continue;
|
|
11636
|
+
}
|
|
11637
|
+
if (key.startsWith('section:')) {
|
|
11638
|
+
const sectionBucket = bucket;
|
|
11639
|
+
const children = [];
|
|
11640
|
+
for (const leafName of sectionBucket.leafNames) {
|
|
11641
|
+
const leaf = leafByName.get(leafName);
|
|
11642
|
+
if (!leaf) {
|
|
11643
|
+
continue;
|
|
11644
|
+
}
|
|
11645
|
+
children.push({
|
|
11646
|
+
kind: 'leaf',
|
|
11647
|
+
column: leaf,
|
|
11648
|
+
visible: leaf.visible !== false,
|
|
11649
|
+
});
|
|
11650
|
+
}
|
|
11651
|
+
if (children.length === 0) {
|
|
11652
|
+
continue;
|
|
11653
|
+
}
|
|
11654
|
+
if (children.length === 1) {
|
|
11655
|
+
nodes.push(children[0]);
|
|
11656
|
+
continue;
|
|
11657
|
+
}
|
|
11658
|
+
nodes.push({
|
|
11659
|
+
kind: 'band',
|
|
11660
|
+
name: `axp-section-${sectionBucket.id}`,
|
|
11661
|
+
title: sectionBucket.title,
|
|
11662
|
+
visible: children.some((child) => child.visible),
|
|
11663
|
+
children,
|
|
11664
|
+
});
|
|
11665
|
+
continue;
|
|
11666
|
+
}
|
|
11667
|
+
if (key.startsWith('singleton:')) {
|
|
11668
|
+
const leafName = key.slice('singleton:'.length);
|
|
11669
|
+
const leaf = leafByName.get(leafName);
|
|
11670
|
+
if (!leaf) {
|
|
11671
|
+
continue;
|
|
11672
|
+
}
|
|
11673
|
+
nodes.push({
|
|
11674
|
+
kind: 'leaf',
|
|
11675
|
+
column: leaf,
|
|
11676
|
+
visible: leaf.visible !== false,
|
|
11677
|
+
});
|
|
11678
|
+
}
|
|
11679
|
+
}
|
|
11680
|
+
return nodes;
|
|
10721
11681
|
}
|
|
10722
|
-
|
|
10723
|
-
|
|
10724
|
-
|
|
10725
|
-
|
|
10726
|
-
|
|
11682
|
+
/**
|
|
11683
|
+
* Merges persisted column order onto the definition order.
|
|
11684
|
+
* Columns missing from saved prefs keep their definition-relative position.
|
|
11685
|
+
*/
|
|
11686
|
+
mergePersistedColumnOrder(definitionColumns, persistedNames) {
|
|
11687
|
+
const columnKey = (column) => column.column?.options?.dataPath ?? column.name;
|
|
11688
|
+
const byKey = new Map(definitionColumns.map((column) => [columnKey(column), column]));
|
|
11689
|
+
const result = [];
|
|
11690
|
+
const placed = new Set();
|
|
11691
|
+
for (const name of persistedNames) {
|
|
11692
|
+
const column = byKey.get(name);
|
|
11693
|
+
if (!column) {
|
|
11694
|
+
continue;
|
|
11695
|
+
}
|
|
11696
|
+
result.push(column);
|
|
11697
|
+
placed.add(name);
|
|
10727
11698
|
}
|
|
10728
|
-
|
|
10729
|
-
|
|
10730
|
-
|
|
10731
|
-
|
|
11699
|
+
for (let index = 0; index < definitionColumns.length; index++) {
|
|
11700
|
+
const column = definitionColumns[index];
|
|
11701
|
+
const key = columnKey(column);
|
|
11702
|
+
if (placed.has(key)) {
|
|
11703
|
+
continue;
|
|
11704
|
+
}
|
|
11705
|
+
let insertAt = result.length;
|
|
11706
|
+
for (let prev = index - 1; prev >= 0; prev--) {
|
|
11707
|
+
const prevKey = columnKey(definitionColumns[prev]);
|
|
11708
|
+
const prevIndex = result.findIndex((entry) => columnKey(entry) === prevKey);
|
|
11709
|
+
if (prevIndex !== -1) {
|
|
11710
|
+
insertAt = prevIndex + 1;
|
|
11711
|
+
break;
|
|
11712
|
+
}
|
|
11713
|
+
}
|
|
11714
|
+
if (insertAt === result.length) {
|
|
11715
|
+
for (let next = index + 1; next < definitionColumns.length; next++) {
|
|
11716
|
+
const nextKey = columnKey(definitionColumns[next]);
|
|
11717
|
+
const nextIndex = result.findIndex((entry) => columnKey(entry) === nextKey);
|
|
11718
|
+
if (nextIndex !== -1) {
|
|
11719
|
+
insertAt = nextIndex;
|
|
11720
|
+
break;
|
|
11721
|
+
}
|
|
11722
|
+
}
|
|
11723
|
+
}
|
|
11724
|
+
result.splice(insertAt, 0, column);
|
|
11725
|
+
placed.add(key);
|
|
10732
11726
|
}
|
|
10733
|
-
|
|
10734
|
-
return relatedDef?.properties?.find((property) => property.name === propertyName) ?? null;
|
|
11727
|
+
return result;
|
|
10735
11728
|
}
|
|
10736
11729
|
collectCardLayoutQueryFields() {
|
|
10737
11730
|
const card = this.cardLayout();
|
|
@@ -10754,8 +11747,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10754
11747
|
for (const path of collectEntityCardUserIdQueryFields(this.entityDef, card.header?.avatar ?? resolveEntityCardAvatarPath(this.entityDef, this.entityDef.columns))) {
|
|
10755
11748
|
add(path);
|
|
10756
11749
|
}
|
|
10757
|
-
const occupied = new Set([card.header?.title, card.header?.description, card.header?.avatar]
|
|
10758
|
-
.filter((name) => !!name && !name.includes('{{')));
|
|
11750
|
+
const occupied = new Set([card.header?.title, card.header?.description, card.header?.avatar].filter((name) => !!name && !name.includes('{{')));
|
|
10759
11751
|
for (const field of card.fields ?? []) {
|
|
10760
11752
|
add(field.name);
|
|
10761
11753
|
add(field.options?.dataPath);
|
|
@@ -10787,34 +11779,87 @@ class AXPEntityMasterListViewModel {
|
|
|
10787
11779
|
await this.applyViewColumns();
|
|
10788
11780
|
}
|
|
10789
11781
|
async onColumnsChanged(columns) {
|
|
11782
|
+
this.rebuildColumnTree();
|
|
10790
11783
|
this.saveSettings('columnOrders', columns);
|
|
10791
11784
|
}
|
|
10792
11785
|
/**
|
|
10793
11786
|
* Builds list columns for the active view:
|
|
10794
|
-
* - `view.columns`
|
|
10795
|
-
* - string
|
|
11787
|
+
* - empty `view.columns` → all entity list columns
|
|
11788
|
+
* - non-empty → whitelist (string or {@link AXPQueryColumn}); listed columns stay in the
|
|
11789
|
+
* picker even when `visible: false`
|
|
11790
|
+
* - entity `options.visible` / view column `visible` set the default switch state
|
|
10796
11791
|
*/
|
|
10797
11792
|
async applyViewColumns() {
|
|
10798
|
-
const
|
|
11793
|
+
const viewColumns = normalizeAXPQueryViewColumns(this.view().columns);
|
|
11794
|
+
const viewByName = new Map(viewColumns.map((column) => [column.name, column]));
|
|
11795
|
+
const whitelistActive = viewColumns.length > 0;
|
|
10799
11796
|
const scope = this.createLogicExpressionScope(null);
|
|
10800
|
-
const
|
|
10801
|
-
|
|
10802
|
-
|
|
10803
|
-
|
|
10804
|
-
const
|
|
10805
|
-
|
|
11797
|
+
const available = this.allAvailableColumns();
|
|
11798
|
+
const availableByName = new Map(available.map((column) => [column.name, column]));
|
|
11799
|
+
const source = whitelistActive ? viewColumns.map((viewColumn) => availableByName.get(viewColumn.name)).filter((column) => column != null) : available;
|
|
11800
|
+
const cloned = (await Promise.all(source.map(async (c) => {
|
|
11801
|
+
const entityColumn = findEntityTableColumnInTree(this.entityDef.columns, c.name);
|
|
11802
|
+
const viewColumn = viewByName.get(c.name);
|
|
11803
|
+
if (!entityColumn) {
|
|
11804
|
+
return null;
|
|
11805
|
+
}
|
|
11806
|
+
const columnDef = viewColumn?.width != null && String(viewColumn.width).trim() !== ''
|
|
11807
|
+
? {
|
|
11808
|
+
...entityColumn,
|
|
11809
|
+
options: {
|
|
11810
|
+
...entityColumn.options,
|
|
11811
|
+
width: String(viewColumn.width),
|
|
11812
|
+
},
|
|
11813
|
+
}
|
|
11814
|
+
: entityColumn;
|
|
11815
|
+
const col = new AXPEntityListViewColumnViewModel(c.property, columnDef);
|
|
11816
|
+
if (viewColumn) {
|
|
11817
|
+
col.visible = viewColumn.visible;
|
|
11818
|
+
}
|
|
11819
|
+
else {
|
|
11820
|
+
col.visible = await this.resolveColumnVisibleExpression(col.visible, scope);
|
|
11821
|
+
}
|
|
10806
11822
|
return col;
|
|
10807
|
-
}));
|
|
10808
|
-
|
|
10809
|
-
|
|
10810
|
-
|
|
10811
|
-
|
|
10812
|
-
|
|
10813
|
-
|
|
10814
|
-
|
|
11823
|
+
}))).filter((column) => column != null);
|
|
11824
|
+
this.columns.set(cloned);
|
|
11825
|
+
this.rebuildColumnTree();
|
|
11826
|
+
}
|
|
11827
|
+
rebuildColumnTree() {
|
|
11828
|
+
const leafByName = new Map(this.columns().map((column) => [column.name, column]));
|
|
11829
|
+
if (this.multiLevelHeadersEnabled()) {
|
|
11830
|
+
this.columnTree.set(this.buildSectionBandedColumnTree(leafByName));
|
|
11831
|
+
return;
|
|
11832
|
+
}
|
|
11833
|
+
this.columnTree.set(this.buildMasterListColumnTree(this.entityDef.columns ?? [], leafByName));
|
|
11834
|
+
}
|
|
11835
|
+
buildMasterListColumnTree(entityColumns, leafByName) {
|
|
11836
|
+
const nodes = [];
|
|
11837
|
+
for (const column of entityColumns) {
|
|
11838
|
+
if (isEntityColumnBand(column)) {
|
|
11839
|
+
const children = this.buildMasterListColumnTree(column.children ?? [], leafByName);
|
|
11840
|
+
if (children.length === 0) {
|
|
11841
|
+
continue;
|
|
11842
|
+
}
|
|
11843
|
+
nodes.push({
|
|
11844
|
+
kind: 'band',
|
|
11845
|
+
name: column.name,
|
|
11846
|
+
title: column.title ?? column.name,
|
|
11847
|
+
visible: children.some((child) => child.visible),
|
|
11848
|
+
children,
|
|
11849
|
+
});
|
|
11850
|
+
continue;
|
|
11851
|
+
}
|
|
11852
|
+
const leaf = leafByName.get(column.name);
|
|
11853
|
+
if (!leaf) {
|
|
11854
|
+
continue;
|
|
11855
|
+
}
|
|
11856
|
+
nodes.push({
|
|
11857
|
+
kind: 'leaf',
|
|
11858
|
+
column: leaf,
|
|
11859
|
+
visible: leaf.visible !== false,
|
|
10815
11860
|
});
|
|
10816
11861
|
}
|
|
10817
|
-
|
|
11862
|
+
return nodes;
|
|
10818
11863
|
}
|
|
10819
11864
|
/**
|
|
10820
11865
|
* Resolves column `options.visible` (boolean or expression) to a boolean for the current list scope.
|
|
@@ -10840,6 +11885,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10840
11885
|
const columns = [...this.columns()];
|
|
10841
11886
|
moveItemInArray(columns, event.previousIndex - 1, event.currentIndex - 1);
|
|
10842
11887
|
this.columns.set(columns);
|
|
11888
|
+
this.rebuildColumnTree();
|
|
10843
11889
|
this.saveSettings('columnOrders', columns);
|
|
10844
11890
|
}
|
|
10845
11891
|
//****************** Card fields ******************//
|
|
@@ -10886,9 +11932,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10886
11932
|
return null;
|
|
10887
11933
|
}
|
|
10888
11934
|
getRegisteredEntity(fullName) {
|
|
10889
|
-
return this.entityDefinitionRegistry
|
|
10890
|
-
.getAll()
|
|
10891
|
-
.find((entity) => `${entity.module}.${entity.name}` === fullName);
|
|
11935
|
+
return this.entityDefinitionRegistry.getAll().find((entity) => `${entity.module}.${entity.name}` === fullName);
|
|
10892
11936
|
}
|
|
10893
11937
|
resolveRelatedEntityProperty(fieldName) {
|
|
10894
11938
|
const relatedRef = this.findRelatedEntityForField(fieldName);
|
|
@@ -10936,8 +11980,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10936
11980
|
if (parentColumn?.options?.dataPath) {
|
|
10937
11981
|
return parentColumn.options.dataPath;
|
|
10938
11982
|
}
|
|
10939
|
-
const relatedDataPath = this.resolveRelatedEntityColumnDataPath(relatedEntityKey, fieldName) ??
|
|
10940
|
-
this.deriveDataPathFromLookupProperty(relatedProperty);
|
|
11983
|
+
const relatedDataPath = this.resolveRelatedEntityColumnDataPath(relatedEntityKey, fieldName) ?? this.deriveDataPathFromLookupProperty(relatedProperty);
|
|
10941
11984
|
if (!relatedDataPath) {
|
|
10942
11985
|
return undefined;
|
|
10943
11986
|
}
|
|
@@ -10947,9 +11990,7 @@ class AXPEntityMasterListViewModel {
|
|
|
10947
11990
|
if (!expose) {
|
|
10948
11991
|
continue;
|
|
10949
11992
|
}
|
|
10950
|
-
const match = expose.find((entry) => entry.target === relatedDataPath ||
|
|
10951
|
-
entry.target.endsWith(`.${relatedDataPath}`) ||
|
|
10952
|
-
(relatedLeaf != null && entry.source === relatedLeaf));
|
|
11993
|
+
const match = expose.find((entry) => entry.target === relatedDataPath || entry.target.endsWith(`.${relatedDataPath}`) || (relatedLeaf != null && entry.source === relatedLeaf));
|
|
10953
11994
|
if (match) {
|
|
10954
11995
|
return match.target;
|
|
10955
11996
|
}
|
|
@@ -11188,6 +12229,7 @@ const AXPEntityListViewModelResolver = async (route, state, service = inject(AXP
|
|
|
11188
12229
|
const entityName = route.paramMap.get('entity');
|
|
11189
12230
|
try {
|
|
11190
12231
|
const vm = await service.create(moduleName, entityName);
|
|
12232
|
+
vm.setListInstanceId(axpGetEntityListInstanceIdFromParamMap(route.queryParamMap));
|
|
11191
12233
|
const viewFromUrl = route.queryParamMap.get('view');
|
|
11192
12234
|
// TODO: Consolidate list init setView calls (resolver, toolbar, list-view queryParamSub / ngAfterViewInit).
|
|
11193
12235
|
await vm.setView(viewFromUrl);
|
|
@@ -11326,6 +12368,7 @@ class AXPEntityMasterSingleViewModel {
|
|
|
11326
12368
|
this.translateService = this.injector.get(AXTranslationService);
|
|
11327
12369
|
this.entityService = this.injector.get(AXPEntityService);
|
|
11328
12370
|
this.expressionEvaluator = this.injector.get(AXPExpressionEvaluatorService);
|
|
12371
|
+
this.contextEvalFactory = this.injector.get(AXPContextEvalFactory);
|
|
11329
12372
|
this.entityDefinitionRegistryService = this.injector.get(AXPEntityDefinitionRegistryService);
|
|
11330
12373
|
this._updateTrigger = signal(1, /* @ts-ignore */
|
|
11331
12374
|
...(ngDevMode ? [{ debugName: "_updateTrigger" }] : /* istanbul ignore next */ []));
|
|
@@ -11387,13 +12430,7 @@ class AXPEntityMasterSingleViewModel {
|
|
|
11387
12430
|
}, /* @ts-ignore */
|
|
11388
12431
|
...(ngDevMode ? [{ debugName: "beardcrumbs" }] : /* istanbul ignore next */ []));
|
|
11389
12432
|
this.evaluateExpressions = async (options, data) => {
|
|
11390
|
-
const scope =
|
|
11391
|
-
context: {
|
|
11392
|
-
eval: (path) => {
|
|
11393
|
-
return get(data, path);
|
|
11394
|
-
},
|
|
11395
|
-
},
|
|
11396
|
-
};
|
|
12433
|
+
const scope = createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(data));
|
|
11397
12434
|
return await this.expressionEvaluator.evaluate(options, scope);
|
|
11398
12435
|
};
|
|
11399
12436
|
this.relatedEntities = computed(async () => {
|
|
@@ -12762,7 +13799,7 @@ class AXMAttachmentsPageComponentProvider {
|
|
|
12762
13799
|
return [
|
|
12763
13800
|
{
|
|
12764
13801
|
key: ATTACHMENTS_PAGE_COMPONENT_KEY,
|
|
12765
|
-
loader: () => import('./acorex-platform-framework-client-layout-entity-attachments-page.component-
|
|
13802
|
+
loader: () => import('./acorex-platform-framework-client-layout-entity-attachments-page.component-Cx-n7ZuA.mjs').then((m) => m.AXMAttachmentsPageComponent),
|
|
12766
13803
|
},
|
|
12767
13804
|
];
|
|
12768
13805
|
}
|
|
@@ -13299,7 +14336,7 @@ class AXMGalleryPageComponentProvider {
|
|
|
13299
14336
|
return [
|
|
13300
14337
|
{
|
|
13301
14338
|
key: GALLERY_PAGE_COMPONENT_KEY,
|
|
13302
|
-
loader: () => import('./acorex-platform-framework-client-layout-entity-gallery-page.component-
|
|
14339
|
+
loader: () => import('./acorex-platform-framework-client-layout-entity-gallery-page.component-uTG2nFly.mjs').then((m) => m.AXMGalleryPageComponent),
|
|
13303
14340
|
},
|
|
13304
14341
|
];
|
|
13305
14342
|
}
|
|
@@ -17387,7 +18424,15 @@ function mapPropertyToWidgetColumn(property) {
|
|
|
17387
18424
|
* Merges with the entity's registered column definition so related-list overrides inherit showAs/dataPath.
|
|
17388
18425
|
*/
|
|
17389
18426
|
function mapEntityColumnToWidgetColumn(entity, column) {
|
|
17390
|
-
|
|
18427
|
+
if (isEntityColumnBand(column)) {
|
|
18428
|
+
return {
|
|
18429
|
+
name: column.name,
|
|
18430
|
+
title: column.title,
|
|
18431
|
+
visible: column.options?.visible !== false,
|
|
18432
|
+
children: (column.children ?? []).map((child) => mapEntityColumnToWidgetColumn(entity, child)),
|
|
18433
|
+
};
|
|
18434
|
+
}
|
|
18435
|
+
const registeredColumn = findEntityTableColumnInTree(entity.columns, column.name);
|
|
17391
18436
|
const columnDef = registeredColumn
|
|
17392
18437
|
? {
|
|
17393
18438
|
...registeredColumn,
|
|
@@ -17455,6 +18500,12 @@ function mapEntityColumnToWidgetColumn(entity, column) {
|
|
|
17455
18500
|
*/
|
|
17456
18501
|
function applyDataListColumnWidths(columns, columnWidthService) {
|
|
17457
18502
|
return columns.map((column) => {
|
|
18503
|
+
if (isDataListColumnBand(column)) {
|
|
18504
|
+
return {
|
|
18505
|
+
...column,
|
|
18506
|
+
children: applyDataListColumnWidths(column.children ?? [], columnWidthService),
|
|
18507
|
+
};
|
|
18508
|
+
}
|
|
17458
18509
|
const existingWidth = column.width ?? column.widget?.options?.width;
|
|
17459
18510
|
if (existingWidth) {
|
|
17460
18511
|
return existingWidth === column.width ? column : { ...column, width: String(existingWidth) };
|
|
@@ -17485,6 +18536,30 @@ function applyIncludeExclude(items, include = [], exclude = []) {
|
|
|
17485
18536
|
}
|
|
17486
18537
|
return result;
|
|
17487
18538
|
}
|
|
18539
|
+
/**
|
|
18540
|
+
* Applies include/exclude filters to leaf columns in a band tree; removes empty bands.
|
|
18541
|
+
*/
|
|
18542
|
+
function applyIncludeExcludeToDataListColumnTree(items, include = [], exclude = []) {
|
|
18543
|
+
const filterNode = (column) => {
|
|
18544
|
+
if (isDataListColumnBand(column)) {
|
|
18545
|
+
const children = (column.children ?? [])
|
|
18546
|
+
.map(filterNode)
|
|
18547
|
+
.filter((c) => c != null);
|
|
18548
|
+
if (children.length === 0) {
|
|
18549
|
+
return null;
|
|
18550
|
+
}
|
|
18551
|
+
return { ...column, children };
|
|
18552
|
+
}
|
|
18553
|
+
if (include.length > 0 && !include.includes(column.name)) {
|
|
18554
|
+
return null;
|
|
18555
|
+
}
|
|
18556
|
+
if (exclude.length > 0 && exclude.includes(column.name)) {
|
|
18557
|
+
return null;
|
|
18558
|
+
}
|
|
18559
|
+
return column;
|
|
18560
|
+
};
|
|
18561
|
+
return items.map(filterNode).filter((c) => c != null);
|
|
18562
|
+
}
|
|
17488
18563
|
/**
|
|
17489
18564
|
* Returns only visible (non-hidden) properties of an entity.
|
|
17490
18565
|
*/
|
|
@@ -17498,19 +18573,14 @@ class AXPEntityListTableService {
|
|
|
17498
18573
|
//#region ---- Services & Dependencies ----
|
|
17499
18574
|
this.commandService = inject(AXPCommandService);
|
|
17500
18575
|
this.expressionEvaluator = inject(AXPExpressionEvaluatorService);
|
|
18576
|
+
this.contextEvalFactory = inject(AXPContextEvalFactory);
|
|
17501
18577
|
this.settings = inject(AXPSettingsService);
|
|
17502
18578
|
this.columnWidthService = inject(AXPColumnWidthService);
|
|
17503
18579
|
this.evaluateExpressions = async (options, data) => {
|
|
17504
18580
|
if (!options) {
|
|
17505
18581
|
return {};
|
|
17506
18582
|
}
|
|
17507
|
-
const scope =
|
|
17508
|
-
context: {
|
|
17509
|
-
eval: (path) => {
|
|
17510
|
-
return get(data, path);
|
|
17511
|
-
},
|
|
17512
|
-
},
|
|
17513
|
-
};
|
|
18583
|
+
const scope = createCommandExpressionScope(this.contextEvalFactory, toExpressionRecord(data));
|
|
17514
18584
|
return await this.expressionEvaluator.evaluate(options, scope);
|
|
17515
18585
|
};
|
|
17516
18586
|
}
|
|
@@ -17536,7 +18606,7 @@ class AXPEntityListTableService {
|
|
|
17536
18606
|
}
|
|
17537
18607
|
const listOptions = {
|
|
17538
18608
|
// 📊 Data Source
|
|
17539
|
-
dataSource: this.createDataSource(entity),
|
|
18609
|
+
dataSource: this.createDataSource(entity, options),
|
|
17540
18610
|
// 📋 Columns from Properties
|
|
17541
18611
|
columns: this.createColumnsFromProperties(entity, options),
|
|
17542
18612
|
// 🎯 Row Commands from Actions
|
|
@@ -17567,7 +18637,7 @@ class AXPEntityListTableService {
|
|
|
17567
18637
|
/**
|
|
17568
18638
|
* Create DataSource for Entity
|
|
17569
18639
|
*/
|
|
17570
|
-
createDataSource(entity) {
|
|
18640
|
+
createDataSource(entity, options) {
|
|
17571
18641
|
return new AXDataSource({
|
|
17572
18642
|
byKey: (key) => {
|
|
17573
18643
|
const func = entity.queries?.byKey?.execute;
|
|
@@ -17581,7 +18651,7 @@ class AXPEntityListTableService {
|
|
|
17581
18651
|
resetPagingForTreeChildrenLoad(e, entity.parentKey);
|
|
17582
18652
|
return func(e);
|
|
17583
18653
|
},
|
|
17584
|
-
pageSize: entity.interfaces?.master?.list?.views?.[0]?.pageSize || 10,
|
|
18654
|
+
pageSize: options?.pageSize || entity.interfaces?.master?.list?.views?.[0]?.pageSize || 10,
|
|
17585
18655
|
key: 'id',
|
|
17586
18656
|
});
|
|
17587
18657
|
}
|
|
@@ -17602,7 +18672,7 @@ class AXPEntityListTableService {
|
|
|
17602
18672
|
else {
|
|
17603
18673
|
baseColumns = getVisibleProperties(entity).map((prop) => mapPropertyToWidgetColumn(prop));
|
|
17604
18674
|
}
|
|
17605
|
-
return applyDataListColumnWidths(
|
|
18675
|
+
return applyDataListColumnWidths(applyIncludeExcludeToDataListColumnTree(baseColumns, includeColumns, excludeColumns), this.columnWidthService);
|
|
17606
18676
|
}
|
|
17607
18677
|
/**
|
|
17608
18678
|
* Map EntityTableColumn to ListWidgetColumn
|
|
@@ -17746,6 +18816,7 @@ class AXPEntityListToolbarService {
|
|
|
17746
18816
|
filterDefinitions: this.mergeFilterDefinitions(baseFilters, options?.customFilterDefinitions),
|
|
17747
18817
|
columnDefinitions: this.createColumnDefinitions(entity, options),
|
|
17748
18818
|
sortDefinitions: await this.createSortDefinitions(entity),
|
|
18819
|
+
sortPresets: collectEntityListSortPresets(entity),
|
|
17749
18820
|
canFilter: true,
|
|
17750
18821
|
canColumns: true,
|
|
17751
18822
|
canSort: true,
|
|
@@ -17837,7 +18908,6 @@ class AXPEntityListToolbarService {
|
|
|
17837
18908
|
const includeColumns = options?.includeColumns || [];
|
|
17838
18909
|
const relatedTableColumns = options?.relatedTableColumns;
|
|
17839
18910
|
const visibleProperties = getVisibleProperties(entity);
|
|
17840
|
-
const visiblePropNames = new Set(visibleProperties.map(({ name }) => name));
|
|
17841
18911
|
let baseColumns;
|
|
17842
18912
|
if (relatedTableColumns?.length) {
|
|
17843
18913
|
baseColumns = relatedTableColumns.map((column) => {
|
|
@@ -17850,13 +18920,11 @@ class AXPEntityListToolbarService {
|
|
|
17850
18920
|
});
|
|
17851
18921
|
}
|
|
17852
18922
|
else if (columns.length > 0) {
|
|
17853
|
-
baseColumns = columns
|
|
17854
|
-
.
|
|
17855
|
-
.map((column) => {
|
|
17856
|
-
const property = visibleProperties.find(({ name }) => name === column.name);
|
|
18923
|
+
baseColumns = flattenEntityTableColumns(columns).map((column) => {
|
|
18924
|
+
const property = entity.properties.find(({ name }) => name === column.name) ?? visibleProperties.find(({ name }) => name === column.name);
|
|
17857
18925
|
return {
|
|
17858
18926
|
name: column.name,
|
|
17859
|
-
title: property?.title,
|
|
18927
|
+
title: column.title || property?.title || column.name,
|
|
17860
18928
|
visible: column?.options?.visible ?? true,
|
|
17861
18929
|
};
|
|
17862
18930
|
});
|
|
@@ -17962,6 +19030,20 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
17962
19030
|
...(ngDevMode ? [{ debugName: "showEntityActions" }] : /* istanbul ignore next */ []));
|
|
17963
19031
|
this.showToolbar = computed(() => this.options()['showToolbar'] ?? true, /* @ts-ignore */
|
|
17964
19032
|
...(ngDevMode ? [{ debugName: "showToolbar" }] : /* istanbul ignore next */ []));
|
|
19033
|
+
this.canViews = computed(() => this.options()['canViews'] !== false, /* @ts-ignore */
|
|
19034
|
+
...(ngDevMode ? [{ debugName: "canViews" }] : /* istanbul ignore next */ []));
|
|
19035
|
+
this.resolvedQueryViews = computed(() => {
|
|
19036
|
+
if (!this.canViews()) {
|
|
19037
|
+
return [];
|
|
19038
|
+
}
|
|
19039
|
+
const override = this.options()['views'];
|
|
19040
|
+
return resolveRelatedEntityListViews(override !== undefined ? { items: override } : undefined, this.entity()?.interfaces?.master?.list?.views);
|
|
19041
|
+
}, /* @ts-ignore */
|
|
19042
|
+
...(ngDevMode ? [{ debugName: "resolvedQueryViews" }] : /* istanbul ignore next */ []));
|
|
19043
|
+
this.showViews = computed(() => this.resolvedQueryViews().length > 0, /* @ts-ignore */
|
|
19044
|
+
...(ngDevMode ? [{ debugName: "showViews" }] : /* istanbul ignore next */ []));
|
|
19045
|
+
this.showListToolbar = computed(() => this.showToolbar() || this.showViews(), /* @ts-ignore */
|
|
19046
|
+
...(ngDevMode ? [{ debugName: "showListToolbar" }] : /* istanbul ignore next */ []));
|
|
17965
19047
|
//actions
|
|
17966
19048
|
this.allActions = computed(() => {
|
|
17967
19049
|
const originalList = this.entity()?.interfaces?.master?.list?.actions ?? [];
|
|
@@ -18701,6 +19783,7 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18701
19783
|
handleQueryChanges(queries, dataSource, listInstance, isMounted) {
|
|
18702
19784
|
const changeTracker = this.analyzeChanges(queries);
|
|
18703
19785
|
this.previousQueries = queries;
|
|
19786
|
+
this.applyViewPageSize(dataSource, queries, changeTracker);
|
|
18704
19787
|
this.applyDataSourceChanges(dataSource, queries, changeTracker, isMounted);
|
|
18705
19788
|
this.handleListRefresh(listInstance, changeTracker, isMounted);
|
|
18706
19789
|
this.handleColumnChanges(changeTracker);
|
|
@@ -18714,9 +19797,26 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18714
19797
|
isFilterChanged: changes.includes('filters'),
|
|
18715
19798
|
isSortChanged: changes.includes('sorts'),
|
|
18716
19799
|
isColumnsChanged: changes.includes('columns'),
|
|
19800
|
+
isViewChanged: changes.includes('view'),
|
|
18717
19801
|
hasAnyChange: changes.length > 0,
|
|
18718
19802
|
};
|
|
18719
19803
|
}
|
|
19804
|
+
applyViewPageSize(dataSource, queries, changeTracker) {
|
|
19805
|
+
if (!changeTracker.isViewChanged) {
|
|
19806
|
+
return;
|
|
19807
|
+
}
|
|
19808
|
+
const view = this.resolvedQueryViews().find((item) => item.name === queries.view);
|
|
19809
|
+
if (view?.pageSize && dataSource.config) {
|
|
19810
|
+
dataSource.config.pageSize = view.pageSize;
|
|
19811
|
+
}
|
|
19812
|
+
}
|
|
19813
|
+
resolveQueryViewsForEntity(entity) {
|
|
19814
|
+
if (this.options()['canViews'] === false) {
|
|
19815
|
+
return [];
|
|
19816
|
+
}
|
|
19817
|
+
const override = this.options()['views'];
|
|
19818
|
+
return resolveRelatedEntityListViews(override !== undefined ? { items: override } : undefined, entity.interfaces?.master?.list?.views);
|
|
19819
|
+
}
|
|
18720
19820
|
/**
|
|
18721
19821
|
* Maps toolbar sort queries ({ name, dir }) to AXDataSource sort options ({ field, dir }).
|
|
18722
19822
|
*/
|
|
@@ -18770,19 +19870,12 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18770
19870
|
// Current columns from list options
|
|
18771
19871
|
const currentColumns = (listInstance.options()['columns'] ||
|
|
18772
19872
|
[]);
|
|
18773
|
-
const
|
|
18774
|
-
|
|
18775
|
-
|
|
18776
|
-
|
|
18777
|
-
|
|
18778
|
-
|
|
18779
|
-
return null;
|
|
18780
|
-
}
|
|
18781
|
-
// Preserve all existing column config but update visibility
|
|
18782
|
-
return { ...base, visible: q.visible };
|
|
18783
|
-
})
|
|
18784
|
-
.filter((c) => c != null);
|
|
18785
|
-
// Apply updated columns to the list widget and refresh
|
|
19873
|
+
const visibilityByName = new Map(toolbarState.columns.map((q) => [
|
|
19874
|
+
q.name,
|
|
19875
|
+
q.visible !== false && q.visible !== 'false',
|
|
19876
|
+
]));
|
|
19877
|
+
const leafOrder = toolbarState.columns.map((q) => q.name);
|
|
19878
|
+
const updatedColumns = applyLeafVisibilityToDataListColumnTree(currentColumns, visibilityByName, leafOrder);
|
|
18786
19879
|
listInstance.setOptions({
|
|
18787
19880
|
columns: applyDataListColumnWidths(updatedColumns, this.columnWidthService),
|
|
18788
19881
|
});
|
|
@@ -18818,21 +19911,34 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18818
19911
|
this.settingsService.onChanged.pipe(takeUntil(this.destroyed)).subscribe(() => {
|
|
18819
19912
|
void this.applyGlobalListDisplayMode();
|
|
18820
19913
|
});
|
|
18821
|
-
const
|
|
19914
|
+
const convertOptions = {
|
|
18822
19915
|
excludeColumns: this.excludeColumns(),
|
|
18823
19916
|
includeColumns: this.includeColumns(),
|
|
18824
19917
|
relatedTableColumns: this.relatedTableColumns(),
|
|
18825
19918
|
customFilterDefinitions: this.customFilterDefinitions(),
|
|
18826
19919
|
excludeProperties: this.options()['excludeProperties'],
|
|
18827
19920
|
};
|
|
18828
|
-
const
|
|
19921
|
+
const queryViews = this.resolveQueryViewsForEntity(resolvedEntity);
|
|
19922
|
+
const initialView = queryViews[0];
|
|
19923
|
+
const listOptions = await this.entityListTableService.convertEntityToListOptions(resolvedEntity, { ...convertOptions, pageSize: initialView?.pageSize }, this.allActions());
|
|
18829
19924
|
if (this.isViewDestroyed) {
|
|
18830
19925
|
return;
|
|
18831
19926
|
}
|
|
18832
|
-
const toolbarOptions = await this.entityListToolbarService.convertEntityToolbarOptions(resolvedEntity,
|
|
19927
|
+
const toolbarOptions = await this.entityListToolbarService.convertEntityToolbarOptions(resolvedEntity, convertOptions);
|
|
18833
19928
|
if (this.isViewDestroyed) {
|
|
18834
19929
|
return;
|
|
18835
19930
|
}
|
|
19931
|
+
const showFilterToolbar = this.showToolbar();
|
|
19932
|
+
const toolbarWidgetOptions = {
|
|
19933
|
+
...toolbarOptions,
|
|
19934
|
+
canFilter: showFilterToolbar,
|
|
19935
|
+
canColumns: showFilterToolbar,
|
|
19936
|
+
canSort: showFilterToolbar,
|
|
19937
|
+
canViews: this.canViews() && queryViews.length > 0,
|
|
19938
|
+
views: queryViews,
|
|
19939
|
+
entitySettingKey: `${resolvedEntity.module}:${resolvedEntity.name}`,
|
|
19940
|
+
canListDisplay: showFilterToolbar,
|
|
19941
|
+
};
|
|
18836
19942
|
this.initListTimeoutId = setTimeout(() => {
|
|
18837
19943
|
this.initListTimeoutId = null;
|
|
18838
19944
|
if (this.isViewDestroyed) {
|
|
@@ -18851,18 +19957,30 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18851
19957
|
mode: 'view',
|
|
18852
19958
|
defaultValue: this.getValue()?.table,
|
|
18853
19959
|
});
|
|
18854
|
-
const
|
|
19960
|
+
const parentFilters = this.getMergedToolbarFilters();
|
|
19961
|
+
const viewFilters = initialView ? queryViewConditionsToFilterQueries(initialView) : [];
|
|
19962
|
+
const toolbarState = {
|
|
19963
|
+
view: initialView?.name,
|
|
19964
|
+
filters: initialView ? [...parentFilters, ...viewFilters] : parentFilters,
|
|
19965
|
+
sorts: initialView?.sorts ?? this.getValue()?.toolbar?.sorts,
|
|
19966
|
+
columns: initialView
|
|
19967
|
+
? applyQueryViewToColumnQueries(toolbarWidgetOptions.columnDefinitions, initialView)
|
|
19968
|
+
: this.getValue()?.toolbar?.columns,
|
|
19969
|
+
displayMode: this.listDisplayMode(),
|
|
19970
|
+
};
|
|
19971
|
+
this.setValue({
|
|
19972
|
+
...this.getValue(),
|
|
19973
|
+
toolbar: {
|
|
19974
|
+
...(this.getValue()?.toolbar ?? {}),
|
|
19975
|
+
...toolbarState,
|
|
19976
|
+
},
|
|
19977
|
+
});
|
|
18855
19978
|
this.toolbarNode.set({
|
|
18856
19979
|
type: AXPWidgetsCatalog.listToolbar,
|
|
18857
19980
|
path: `toolbar`,
|
|
18858
|
-
options:
|
|
19981
|
+
options: toolbarWidgetOptions,
|
|
18859
19982
|
mode: 'view',
|
|
18860
|
-
defaultValue:
|
|
18861
|
-
filters: mergedToolbarFilters,
|
|
18862
|
-
sorts: this.getValue()?.toolbar?.sorts,
|
|
18863
|
-
columns: this.getValue()?.toolbar?.columns,
|
|
18864
|
-
displayMode: this.listDisplayMode(),
|
|
18865
|
-
},
|
|
19983
|
+
defaultValue: toolbarState,
|
|
18866
19984
|
});
|
|
18867
19985
|
queueMicrotask(() => {
|
|
18868
19986
|
if (!this.isViewDestroyed) {
|
|
@@ -18993,7 +20111,7 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
18993
20111
|
</div>
|
|
18994
20112
|
}
|
|
18995
20113
|
<div class="flex min-h-0 h-full flex-col gap-2" [style.max-height]="maxHeight()">
|
|
18996
|
-
@if (toolbarNode() != null &&
|
|
20114
|
+
@if (toolbarNode() != null && showListToolbar()) {
|
|
18997
20115
|
<ng-container
|
|
18998
20116
|
#toolbar
|
|
18999
20117
|
axp-widget-renderer
|
|
@@ -19069,7 +20187,7 @@ class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
19069
20187
|
}
|
|
19070
20188
|
</div>
|
|
19071
20189
|
</div>
|
|
19072
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXPWidgetCoreModule }, { kind: "directive", type: i1$6.AXPWidgetRendererDirective, selector: "[axp-widget-renderer]", inputs: ["parentNode", "index", "mode", "node"], outputs: ["onOptionsChanged", "onValueChanged", "onLoad"], exportAs: ["widgetRenderer"] }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: i1.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i1.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "component", type: i6.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "placement", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPEntityCardComponent, selector: "axp-entity-card", inputs: ["entity", "layout", "row", "fields", "variant", "interactive", "embedded", "elevated", "disableLookupPopover", "fillHost", "extraExpanded", "selected", "showNewBadge", "showSelection", "showClose", "primaryActions", "primaryActionLook", "secondaryActionLoader"], outputs: ["extraExpandedChange", "selectionChange", "commandClick", "closeClick"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
20190
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXPWidgetCoreModule }, { kind: "directive", type: i1$6.AXPWidgetRendererDirective, selector: "[axp-widget-renderer]", inputs: ["parentNode", "index", "mode", "node"], outputs: ["onOptionsChanged", "onValueChanged", "onLoad"], exportAs: ["widgetRenderer"] }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: i1.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i1.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "component", type: i6.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "placement", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXPEntityCardComponent, selector: "axp-entity-card", inputs: ["entity", "layout", "row", "fields", "userStylingRules", "variant", "interactive", "embedded", "elevated", "disableLookupPopover", "fillHost", "extraExpanded", "selected", "showNewBadge", "showSelection", "showClose", "primaryActions", "primaryActionLook", "secondaryActionLoader"], outputs: ["extraExpandedChange", "selectionChange", "commandClick", "closeClick"] }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
19073
20191
|
}
|
|
19074
20192
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPEntityListWidgetViewComponent, decorators: [{
|
|
19075
20193
|
type: Component,
|
|
@@ -19154,7 +20272,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
19154
20272
|
</div>
|
|
19155
20273
|
}
|
|
19156
20274
|
<div class="flex min-h-0 h-full flex-col gap-2" [style.max-height]="maxHeight()">
|
|
19157
|
-
@if (toolbarNode() != null &&
|
|
20275
|
+
@if (toolbarNode() != null && showListToolbar()) {
|
|
19158
20276
|
<ng-container
|
|
19159
20277
|
#toolbar
|
|
19160
20278
|
axp-widget-renderer
|
|
@@ -19938,6 +21056,132 @@ function resolvePolymorphicRefTypePath(columnName, entityOption, expose) {
|
|
|
19938
21056
|
}
|
|
19939
21057
|
//#endregion
|
|
19940
21058
|
|
|
21059
|
+
//#region ----- Imports -----
|
|
21060
|
+
//#endregion
|
|
21061
|
+
//#region ----- Helpers -----
|
|
21062
|
+
function resolveLookupEntityCacheKey(entity) {
|
|
21063
|
+
if (typeof entity === 'string') {
|
|
21064
|
+
return entity.trim();
|
|
21065
|
+
}
|
|
21066
|
+
return `${entity.module}.${entity.name}`;
|
|
21067
|
+
}
|
|
21068
|
+
function normalizeLookupCacheId(id) {
|
|
21069
|
+
if (id == null || id === '') {
|
|
21070
|
+
return null;
|
|
21071
|
+
}
|
|
21072
|
+
return String(id);
|
|
21073
|
+
}
|
|
21074
|
+
//#endregion
|
|
21075
|
+
//#region ----- Service -----
|
|
21076
|
+
/**
|
|
21077
|
+
* Session-scoped GetById cache for lookup widgets.
|
|
21078
|
+
* Shared across edit/view/column instances so remounts and list cells reuse rows.
|
|
21079
|
+
*/
|
|
21080
|
+
class AXPLookupByKeyCacheService {
|
|
21081
|
+
//#endregion
|
|
21082
|
+
//#region ----- Lifecycle -----
|
|
21083
|
+
constructor() {
|
|
21084
|
+
//#region ----- Services & Dependencies -----
|
|
21085
|
+
this.sessionService = inject(AXPSessionService);
|
|
21086
|
+
//#endregion
|
|
21087
|
+
//#region ----- State -----
|
|
21088
|
+
this.rows = new Map();
|
|
21089
|
+
this.inflight = new Map();
|
|
21090
|
+
this.generation = 0;
|
|
21091
|
+
this.bindSessionReset(this.sessionService.tenant$.pipe(map((tenant) => tenant?.id ?? null), distinctUntilChanged()));
|
|
21092
|
+
this.bindSessionReset(this.sessionService.user$.pipe(map((user) => user?.id ?? null), distinctUntilChanged()));
|
|
21093
|
+
}
|
|
21094
|
+
//#endregion
|
|
21095
|
+
//#region ----- Public API -----
|
|
21096
|
+
remember(entityKey, id, row) {
|
|
21097
|
+
const cacheId = normalizeLookupCacheId(id);
|
|
21098
|
+
const key = entityKey.trim();
|
|
21099
|
+
if (!key || cacheId == null || row == null) {
|
|
21100
|
+
return;
|
|
21101
|
+
}
|
|
21102
|
+
let entityRows = this.rows.get(key);
|
|
21103
|
+
if (!entityRows) {
|
|
21104
|
+
entityRows = new Map();
|
|
21105
|
+
this.rows.set(key, entityRows);
|
|
21106
|
+
}
|
|
21107
|
+
entityRows.set(cacheId, row);
|
|
21108
|
+
}
|
|
21109
|
+
peek(entityKey, id) {
|
|
21110
|
+
const cacheId = normalizeLookupCacheId(id);
|
|
21111
|
+
if (cacheId == null) {
|
|
21112
|
+
return undefined;
|
|
21113
|
+
}
|
|
21114
|
+
return this.rows.get(entityKey.trim())?.get(cacheId);
|
|
21115
|
+
}
|
|
21116
|
+
async getOrFetch(entityKey, id, fetch) {
|
|
21117
|
+
const key = entityKey.trim();
|
|
21118
|
+
const cacheId = normalizeLookupCacheId(id);
|
|
21119
|
+
if (!key || cacheId == null) {
|
|
21120
|
+
return null;
|
|
21121
|
+
}
|
|
21122
|
+
const cached = this.rows.get(key)?.get(cacheId);
|
|
21123
|
+
if (cached !== undefined) {
|
|
21124
|
+
return cached;
|
|
21125
|
+
}
|
|
21126
|
+
const flightKey = `${key}:${cacheId}`;
|
|
21127
|
+
const pending = this.inflight.get(flightKey);
|
|
21128
|
+
if (pending) {
|
|
21129
|
+
return pending;
|
|
21130
|
+
}
|
|
21131
|
+
const generation = this.generation;
|
|
21132
|
+
const request = Promise.resolve()
|
|
21133
|
+
.then(() => fetch(id))
|
|
21134
|
+
.then((row) => {
|
|
21135
|
+
if (row != null && generation === this.generation) {
|
|
21136
|
+
this.remember(key, cacheId, row);
|
|
21137
|
+
return row;
|
|
21138
|
+
}
|
|
21139
|
+
return row ?? null;
|
|
21140
|
+
})
|
|
21141
|
+
.finally(() => {
|
|
21142
|
+
this.inflight.delete(flightKey);
|
|
21143
|
+
});
|
|
21144
|
+
this.inflight.set(flightKey, request);
|
|
21145
|
+
return request;
|
|
21146
|
+
}
|
|
21147
|
+
wrap(entityKey, fetch) {
|
|
21148
|
+
return (id) => this.getOrFetch(entityKey, id, fetch);
|
|
21149
|
+
}
|
|
21150
|
+
clear(entityKey) {
|
|
21151
|
+
this.generation += 1;
|
|
21152
|
+
if (entityKey?.trim()) {
|
|
21153
|
+
this.rows.delete(entityKey.trim());
|
|
21154
|
+
const prefix = `${entityKey.trim()}:`;
|
|
21155
|
+
for (const flightKey of [...this.inflight.keys()]) {
|
|
21156
|
+
if (flightKey.startsWith(prefix)) {
|
|
21157
|
+
this.inflight.delete(flightKey);
|
|
21158
|
+
}
|
|
21159
|
+
}
|
|
21160
|
+
return;
|
|
21161
|
+
}
|
|
21162
|
+
this.rows.clear();
|
|
21163
|
+
this.inflight.clear();
|
|
21164
|
+
}
|
|
21165
|
+
//#endregion
|
|
21166
|
+
//#region ----- Session -----
|
|
21167
|
+
bindSessionReset(source) {
|
|
21168
|
+
let initialized = false;
|
|
21169
|
+
source.subscribe(() => {
|
|
21170
|
+
if (!initialized) {
|
|
21171
|
+
initialized = true;
|
|
21172
|
+
return;
|
|
21173
|
+
}
|
|
21174
|
+
this.clear();
|
|
21175
|
+
});
|
|
21176
|
+
}
|
|
21177
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupByKeyCacheService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
21178
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupByKeyCacheService, providedIn: 'root' }); }
|
|
21179
|
+
}
|
|
21180
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupByKeyCacheService, decorators: [{
|
|
21181
|
+
type: Injectable,
|
|
21182
|
+
args: [{ providedIn: 'root' }]
|
|
21183
|
+
}], ctorParameters: () => [] });
|
|
21184
|
+
|
|
19941
21185
|
class AXPLookupWidgetViewComponent extends AXPValueWidgetComponent {
|
|
19942
21186
|
constructor() {
|
|
19943
21187
|
super(...arguments);
|
|
@@ -19946,6 +21190,7 @@ class AXPLookupWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
19946
21190
|
this.expressionEvaluator = inject(AXPExpressionEvaluatorService);
|
|
19947
21191
|
this.contextEvalFactory = inject(AXPContextEvalFactory);
|
|
19948
21192
|
this.entityResolver = inject(AXPEntityDefinitionRegistryService);
|
|
21193
|
+
this.lookupByKeyCache = inject(AXPLookupByKeyCacheService);
|
|
19949
21194
|
this.entity = computed(() => this.options()['entity'], /* @ts-ignore */
|
|
19950
21195
|
...(ngDevMode ? [{ debugName: "entity" }] : /* istanbul ignore next */ []));
|
|
19951
21196
|
this.multiple = computed(() => this.options()['multiple'], /* @ts-ignore */
|
|
@@ -19997,8 +21242,14 @@ class AXPLookupWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
19997
21242
|
const byKey = def?.queries?.byKey?.execute;
|
|
19998
21243
|
if (byKey) {
|
|
19999
21244
|
this.loading.set(true);
|
|
20000
|
-
const fetchedItem = await
|
|
21245
|
+
const fetchedItem = await this.lookupByKeyCache.getOrFetch(this.entity(), item, (id) => byKey(id));
|
|
20001
21246
|
this.loading.set(false);
|
|
21247
|
+
if (fetchedItem == null || typeof fetchedItem !== 'object') {
|
|
21248
|
+
return {
|
|
21249
|
+
id: item,
|
|
21250
|
+
text: item,
|
|
21251
|
+
};
|
|
21252
|
+
}
|
|
20002
21253
|
return {
|
|
20003
21254
|
id: fetchedItem[this.valueField()],
|
|
20004
21255
|
text: await this.getDisplayRaw(fetchedItem),
|
|
@@ -20516,6 +21767,7 @@ class AXPEntityDataSelectorService {
|
|
|
20516
21767
|
this.translationService = inject(AXTranslationService);
|
|
20517
21768
|
this.rowActionsService = inject(AXPEntityDataSelectorRowActionsService);
|
|
20518
21769
|
this.expressionEvaluator = inject(AXPExpressionEvaluatorService);
|
|
21770
|
+
this.lookupByKeyCache = inject(AXPLookupByKeyCacheService);
|
|
20519
21771
|
}
|
|
20520
21772
|
//#endregion
|
|
20521
21773
|
//#region ---- Public Methods ----
|
|
@@ -20662,10 +21914,14 @@ class AXPEntityDataSelectorService {
|
|
|
20662
21914
|
const { entity } = options;
|
|
20663
21915
|
const filters = options.filter?.value;
|
|
20664
21916
|
const parentFilters = options.filter?.parent;
|
|
21917
|
+
const entityKey = resolveLookupEntityCacheKey(entity);
|
|
20665
21918
|
return new AXDataSource({
|
|
20666
21919
|
byKey: (key) => {
|
|
20667
21920
|
const func = entity.queries?.byKey?.execute;
|
|
20668
|
-
|
|
21921
|
+
if (!func) {
|
|
21922
|
+
return Promise.resolve(null);
|
|
21923
|
+
}
|
|
21924
|
+
return this.lookupByKeyCache.getOrFetch(entityKey, key, (id) => func(id));
|
|
20669
21925
|
},
|
|
20670
21926
|
load: (e) => {
|
|
20671
21927
|
const func = entity.queries?.list?.execute;
|
|
@@ -21264,11 +22520,12 @@ function isLookupValueFieldPrimaryKey(entity, valueField) {
|
|
|
21264
22520
|
const normalized = valueField.trim() || 'id';
|
|
21265
22521
|
return normalized === resolveLookupEntityPrimaryKeyField(entity);
|
|
21266
22522
|
}
|
|
21267
|
-
function rememberFetchedLookupRow(map, key, row) {
|
|
22523
|
+
function rememberFetchedLookupRow(map, key, row, onRow) {
|
|
21268
22524
|
map.set(key, row);
|
|
21269
22525
|
if (key != null) {
|
|
21270
22526
|
map.set(String(key), row);
|
|
21271
22527
|
}
|
|
22528
|
+
onRow?.(key, row);
|
|
21272
22529
|
}
|
|
21273
22530
|
function readFetchedLookupRow(map, key) {
|
|
21274
22531
|
if (key == null) {
|
|
@@ -21298,7 +22555,7 @@ async function fetchLookupRowsByKeys(config) {
|
|
|
21298
22555
|
uniqueKeys.forEach((key, index) => {
|
|
21299
22556
|
const row = rows[index];
|
|
21300
22557
|
if (row != null) {
|
|
21301
|
-
rememberFetchedLookupRow(fetchedByKey, key, row);
|
|
22558
|
+
rememberFetchedLookupRow(fetchedByKey, key, row, config.onRow);
|
|
21302
22559
|
}
|
|
21303
22560
|
});
|
|
21304
22561
|
return fetchedByKey;
|
|
@@ -21309,7 +22566,7 @@ async function fetchLookupRowsByKeys(config) {
|
|
|
21309
22566
|
uniqueKeys.forEach((key, index) => {
|
|
21310
22567
|
const row = rows[index];
|
|
21311
22568
|
if (row != null) {
|
|
21312
|
-
rememberFetchedLookupRow(fetchedByKey, key, row);
|
|
22569
|
+
rememberFetchedLookupRow(fetchedByKey, key, row, config.onRow);
|
|
21313
22570
|
}
|
|
21314
22571
|
});
|
|
21315
22572
|
}
|
|
@@ -21332,7 +22589,7 @@ async function fetchLookupRowsByKeys(config) {
|
|
|
21332
22589
|
if (storedKey == null) {
|
|
21333
22590
|
continue;
|
|
21334
22591
|
}
|
|
21335
|
-
rememberFetchedLookupRow(fetchedByKey, storedKey, row);
|
|
22592
|
+
rememberFetchedLookupRow(fetchedByKey, storedKey, row, config.onRow);
|
|
21336
22593
|
}
|
|
21337
22594
|
return fetchedByKey;
|
|
21338
22595
|
}
|
|
@@ -21348,7 +22605,7 @@ function createLookupEntityDataSource(config) {
|
|
|
21348
22605
|
const valueField = config.valueField?.trim() || 'id';
|
|
21349
22606
|
return new AXDataSource({
|
|
21350
22607
|
byKey: async (key) => {
|
|
21351
|
-
const byKeyExecute = entity.queries?.byKey?.execute;
|
|
22608
|
+
const byKeyExecute = config.byKey ?? entity.queries?.byKey?.execute;
|
|
21352
22609
|
const listExecute = entity.queries?.list?.execute;
|
|
21353
22610
|
const fetchedByKey = await fetchLookupRowsByKeys({
|
|
21354
22611
|
entity,
|
|
@@ -21362,6 +22619,7 @@ function createLookupEntityDataSource(config) {
|
|
|
21362
22619
|
}
|
|
21363
22620
|
: undefined,
|
|
21364
22621
|
queryList: listExecute,
|
|
22622
|
+
onRow: config.onRow,
|
|
21365
22623
|
});
|
|
21366
22624
|
const row = readFetchedLookupRow(fetchedByKey, key);
|
|
21367
22625
|
if (row == null) {
|
|
@@ -21568,7 +22826,7 @@ function areLookupSelectionItemsHydrated(rawValue, items, options) {
|
|
|
21568
22826
|
}
|
|
21569
22827
|
//#endregion
|
|
21570
22828
|
|
|
21571
|
-
//#region
|
|
22829
|
+
//#region ---- Imports -----
|
|
21572
22830
|
//#endregion
|
|
21573
22831
|
//#region ----- Constants -----
|
|
21574
22832
|
const DEFAULT_LOOKUP_COLUMN_NAMES = ['title', 'displayName', 'name', 'code', 'description'];
|
|
@@ -21599,7 +22857,9 @@ function resolveEntityListRowTitleTemplate(entity) {
|
|
|
21599
22857
|
return entity.interfaces?.master?.single?.title ?? entity.formats?.searchResult?.title ?? entity.formats?.individual;
|
|
21600
22858
|
}
|
|
21601
22859
|
function resolveDefaultColumnNames(entity) {
|
|
21602
|
-
const fromEntity = (entity.columns
|
|
22860
|
+
const fromEntity = flattenEntityTableColumns(entity.columns)
|
|
22861
|
+
.map((column) => column.name?.trim())
|
|
22862
|
+
.filter((name) => !!name);
|
|
21603
22863
|
if (fromEntity.length) {
|
|
21604
22864
|
return fromEntity;
|
|
21605
22865
|
}
|
|
@@ -21610,7 +22870,7 @@ function resolveColumnsToProcess(entity, columnSpecs) {
|
|
|
21610
22870
|
const { columns: entityColumns = [], properties } = entity;
|
|
21611
22871
|
const visibleProperties = properties.filter(({ schema }) => schema?.visible !== false);
|
|
21612
22872
|
const visiblePropNames = new Set(visibleProperties.map(({ name }) => name));
|
|
21613
|
-
const filteredColumns = entityColumns.filter(({ name, showAs }) => visiblePropNames.has(name) || showAs);
|
|
22873
|
+
const filteredColumns = flattenEntityTableColumns(entityColumns).filter(({ name, showAs }) => visiblePropNames.has(name) || showAs);
|
|
21614
22874
|
if (columnSpecs.length === 0) {
|
|
21615
22875
|
return filteredColumns
|
|
21616
22876
|
.filter((column) => DEFAULT_LOOKUP_COLUMN_NAMES.includes(column.name))
|
|
@@ -22142,7 +23402,7 @@ class AXPLookupWidgetTablePanelComponent {
|
|
|
22142
23402
|
return Boolean(item[this.disabledField()]);
|
|
22143
23403
|
}
|
|
22144
23404
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupWidgetTablePanelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
22145
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPLookupWidgetTablePanelComponent, isStandalone: true, selector: "axp-lookup-widget-table-panel", inputs: { dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: true, isRequired: true, transformFunction: null }, columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: true, transformFunction: null }, valueField: { classPropertyName: "valueField", publicName: "valueField", isSignal: true, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: true, isRequired: false, transformFunction: null }, selectedValues: { classPropertyName: "selectedValues", publicName: "selectedValues", isSignal: true, isRequired: false, transformFunction: null }, parentField: { classPropertyName: "parentField", publicName: "parentField", isSignal: true, isRequired: false, transformFunction: null }, hasChildrenField: { classPropertyName: "hasChildrenField", publicName: "hasChildrenField", isSignal: true, isRequired: false, transformFunction: null }, itemHeight: { classPropertyName: "itemHeight", publicName: "itemHeight", isSignal: true, isRequired: false, transformFunction: null }, maxVisibleItems: { classPropertyName: "maxVisibleItems", publicName: "maxVisibleItems", isSignal: true, isRequired: false, transformFunction: null }, alternate: { classPropertyName: "alternate", publicName: "alternate", isSignal: true, isRequired: false, transformFunction: null }, highlightText: { classPropertyName: "highlightText", publicName: "highlightText", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { itemClick: "itemClick" }, host: { properties: { "class.ax-lookup-multi-column-tree": "!!parentField()", "style.height.px": "tableHeight()" }, classAttribute: "ax-lookup-multi-column block min-h-0" }, viewQueries: [{ propertyName: "tableRef", first: true, predicate: AXDataTableComponent, descendants: true, isSignal: true }], ngImport: i0, template: "<ax-data-table\n class=\"ax-lookup-multi-column-table\"\n look=\"minimal\"\n [dataSource]=\"parentField() ? dataSource() : tableDataSource\"\n [parentField]=\"parentField() ?? ''\"\n [hasChildrenField]=\"hasChildrenField()\"\n [itemHeight]=\"itemHeight()\"\n [alternative]=\"alternate()\"\n [highlightText]=\"highlightText()\"\n [loading]=\"loadingConfig()\"\n [paging]=\"false\"\n [showHeader]=\"true\"\n [fixedHeader]=\"true\"\n [showFooter]=\"false\"\n [allowReordering]=\"false\"\n [rowCssClass]=\"resolveRowCssClass\"\n (onRowClick)=\"handleRowClick($event)\"\n>\n @for (column of visibleColumns(); track column.name) {\n <axp-widget-column-renderer\n [expandHandler]=\"$index === 0 && !!parentField()\"\n [caption]=\"column.title\"\n [customWidth]=\"resolveColumnWidth(column)\"\n [node]=\"column.node\"\n ></axp-widget-column-renderer>\n }\n</ax-data-table>\n", dependencies: [{ kind: "ngmodule", type: AXDataTableModule }, { kind: "component", type: i1$7.AXDataTableComponent, selector: "ax-data-table", inputs: ["dataSource", "selectedRows", "parentField", "hasChildrenField", "rowDetailsTemplate", "rowCssClass", "cellCssClass", "highlightText", "look", "rowTemplate", "emptyTemplate", "noDataTemplate", "alternative", "showHeader", "fixedHeader", "showFooter", "fixedFooter", "itemHeight", "allowReordering", "paging", "fetchDataMode", "loading", "focusedRow"], outputs: ["selectedRowsChange", "focusedRowChange", "onRowClick", "onRowDbClick", "onColumnsOrderChanged", "onColumnSizeChanged", "onPageChanged"] }, { kind: "ngmodule", type: AXPWidgetCoreModule }, { kind: "component", type: i1$6.AXPWidgetColumnRendererComponent, selector: "axp-widget-column-renderer", inputs: ["caption", "customExpandIcon", "customCollapseIcon", "customWidth", "node", "footerTemplate", "expandHandler", "sortEnabled", "headerSortDirection", "headerSortPriority", "columnFixed", "cellTemplate", "headerTemplate"], outputs: ["sortToggle"] }, { kind: "ngmodule", type: AXTranslationModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
23405
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPLookupWidgetTablePanelComponent, isStandalone: true, selector: "axp-lookup-widget-table-panel", inputs: { dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: true, isRequired: true, transformFunction: null }, columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: true, transformFunction: null }, valueField: { classPropertyName: "valueField", publicName: "valueField", isSignal: true, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: true, isRequired: false, transformFunction: null }, selectedValues: { classPropertyName: "selectedValues", publicName: "selectedValues", isSignal: true, isRequired: false, transformFunction: null }, parentField: { classPropertyName: "parentField", publicName: "parentField", isSignal: true, isRequired: false, transformFunction: null }, hasChildrenField: { classPropertyName: "hasChildrenField", publicName: "hasChildrenField", isSignal: true, isRequired: false, transformFunction: null }, itemHeight: { classPropertyName: "itemHeight", publicName: "itemHeight", isSignal: true, isRequired: false, transformFunction: null }, maxVisibleItems: { classPropertyName: "maxVisibleItems", publicName: "maxVisibleItems", isSignal: true, isRequired: false, transformFunction: null }, alternate: { classPropertyName: "alternate", publicName: "alternate", isSignal: true, isRequired: false, transformFunction: null }, highlightText: { classPropertyName: "highlightText", publicName: "highlightText", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { itemClick: "itemClick" }, host: { properties: { "class.ax-lookup-multi-column-tree": "!!parentField()", "style.height.px": "tableHeight()" }, classAttribute: "ax-lookup-multi-column block min-h-0" }, viewQueries: [{ propertyName: "tableRef", first: true, predicate: AXDataTableComponent, descendants: true, isSignal: true }], ngImport: i0, template: "<ax-data-table\n class=\"ax-lookup-multi-column-table\"\n look=\"minimal\"\n [dataSource]=\"parentField() ? dataSource() : tableDataSource\"\n [parentField]=\"parentField() ?? ''\"\n [hasChildrenField]=\"hasChildrenField()\"\n [itemHeight]=\"itemHeight()\"\n [alternative]=\"alternate()\"\n [highlightText]=\"highlightText()\"\n [loading]=\"loadingConfig()\"\n [paging]=\"false\"\n [showHeader]=\"true\"\n [fixedHeader]=\"true\"\n [showFooter]=\"false\"\n [allowReordering]=\"false\"\n [rowCssClass]=\"resolveRowCssClass\"\n (onRowClick)=\"handleRowClick($event)\"\n>\n @for (column of visibleColumns(); track column.name) {\n <axp-widget-column-renderer\n [expandHandler]=\"$index === 0 && !!parentField()\"\n [caption]=\"column.title\"\n [customWidth]=\"resolveColumnWidth(column)\"\n [node]=\"column.node\"\n ></axp-widget-column-renderer>\n }\n</ax-data-table>\n", dependencies: [{ kind: "ngmodule", type: AXDataTableModule }, { kind: "component", type: i1$7.AXDataTableComponent, selector: "ax-data-table", inputs: ["dataSource", "selectedRows", "parentField", "hasChildrenField", "rowDetailsTemplate", "rowCssClass", "cellCssClass", "highlightText", "look", "rowTemplate", "emptyTemplate", "noDataTemplate", "alternative", "showHeader", "fixedHeader", "showFooter", "fixedFooter", "itemHeight", "allowReordering", "paging", "fetchDataMode", "loading", "focusedRow"], outputs: ["selectedRowsChange", "focusedRowChange", "onRowClick", "onRowDbClick", "onColumnsOrderChanged", "onColumnSizeChanged", "onPageChanged"] }, { kind: "ngmodule", type: AXPWidgetCoreModule }, { kind: "component", type: i1$6.AXPWidgetColumnRendererComponent, selector: "axp-widget-column-renderer", inputs: ["caption", "customExpandIcon", "customCollapseIcon", "customWidth", "columnKey", "node", "footerTemplate", "expandHandler", "sortEnabled", "headerSortDirection", "headerSortPriority", "columnFixed", "cellTemplate", "headerTemplate"], outputs: ["sortToggle"] }, { kind: "ngmodule", type: AXTranslationModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
22146
23406
|
}
|
|
22147
23407
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupWidgetTablePanelComponent, decorators: [{
|
|
22148
23408
|
type: Component,
|
|
@@ -22468,7 +23728,7 @@ class AXPLookupWidgetTableHostComponent extends NXValueComponent {
|
|
|
22468
23728
|
{ provide: AXComponent, useExisting: AXPLookupWidgetTableHostComponent },
|
|
22469
23729
|
{ provide: AXClearableComponent, useExisting: AXPLookupWidgetTableHostComponent },
|
|
22470
23730
|
{ provide: AXValuableComponent, useExisting: AXPLookupWidgetTableHostComponent },
|
|
22471
|
-
], viewQueries: [{ propertyName: "triggerSearchInput", first: true, predicate: ["triggerSearchInput"], descendants: true, isSignal: true }, { propertyName: "popoverRef", first: true, predicate: AXPopoverComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n #origin\n class=\"ax-editor-container ax-solid ax-default ax-lookup-trigger w-full\"\n [class.ax-state-disabled]=\"disabled()\"\n [class.ax-state-readonly]=\"readonly()\"\n (click)=\"onTriggerClick()\"\n>\n <div class=\"ax-lookup-value\">\n @if (showSelectedTemplate()) {\n <div class=\"ax-lookup-selected-content\" aria-hidden=\"true\">\n <ng-container\n [ngTemplateOutlet]=\"selectedTemplate()!\"\n [ngTemplateOutletContext]=\"{ $implicit: valueItems()[0] }\"\n />\n </div>\n }\n <input\n #triggerSearchInput\n type=\"text\"\n class=\"ax-input\"\n [class.ax-lookup-select-input]=\"!searchable()\"\n [class.ax-lookup-input-overlay]=\"showSelectedTemplate()\"\n [placeholder]=\"triggerSearchPlaceholder()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly() || !searchable()\"\n [attr.inputmode]=\"searchable() ? null : 'none'\"\n [value]=\"triggerInputValue()\"\n (input)=\"onTriggerSearchInput($any($event.target).value)\"\n (keydown)=\"onTriggerKeydown($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n\n @if (selectedValues().length > 0 && !disabled() && !readonly()) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n\n <button type=\"button\" class=\"ax-general-button-icon\" tabindex=\"-1\" [disabled]=\"disabled() || readonly()\">\n <span\n class=\"ax-icon\"\n [class.ax-icon-chevron-down]=\"!expanded()\"\n [class.ax-icon-chevron-up]=\"expanded()\"\n ></span>\n </button>\n\n <ng-content select=\"ax-validation-rule\"></ng-content>\n</div>\n\n<ax-popover\n [target]=\"origin\"\n [openOn]=\"'manual'\"\n [closeOn]=\"'clickOut'\"\n [placement]=\"'bottom-start'\"\n [width]=\"origin.offsetWidth + 'px'\"\n [disabled]=\"disabled() || readonly()\"\n (onClosed)=\"onPopoverClosed()\"\n>\n <div class=\"ax-lookup-popup\" (keydown.escape)=\"expanded.set(false)\">\n <axp-lookup-widget-table-panel\n [dataSource]=\"resolvedTableDataSource()\"\n [columns]=\"columns()\"\n [highlightText]=\"highlightQuery()\"\n [valueField]=\"valueField()\"\n [disabledField]=\"disabledField()\"\n [parentField]=\"parentField()\"\n [hasChildrenField]=\"hasChildrenField()\"\n [selectedValues]=\"selectedValues()\"\n (itemClick)=\"handleTableItemClick($event)\"\n ></axp-lookup-widget-table-panel>\n </div>\n</ax-popover>\n", styles: ["@layer properties;:host{display:block;width:100%}:host .ax-editor-container{justify-content:flex-start;gap:var(--spacing, .25rem)}:host .ax-lookup-trigger{cursor:pointer;-webkit-user-select:none;user-select:none}:host .ax-lookup-value{position:relative;display:flex;min-width:0px;flex:1;align-items:center;overflow:hidden}:host .ax-lookup-select-input{cursor:pointer;caret-color:transparent;-webkit-user-select:none;user-select:none}:host .ax-lookup-selected-content{pointer-events:none;position:relative;z-index:0;display:flex;min-width:0px;flex:1;align-items:center;overflow:hidden}:host .ax-lookup-input-overlay{position:absolute;inset:0;z-index:10;margin:0!important;height:100%;width:100%;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:0!important;color:transparent;caret-color:transparent}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "ngmodule", type: AXFormModule }, { kind: "component", type: AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "ngmodule", type: AXValidationModule }, { kind: "component", type: AXPLookupWidgetTablePanelComponent, selector: "axp-lookup-widget-table-panel", inputs: ["dataSource", "columns", "valueField", "disabledField", "selectedValues", "parentField", "hasChildrenField", "itemHeight", "maxVisibleItems", "alternate", "highlightText"], outputs: ["itemClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
23731
|
+
], viewQueries: [{ propertyName: "triggerSearchInput", first: true, predicate: ["triggerSearchInput"], descendants: true, isSignal: true }, { propertyName: "popoverRef", first: true, predicate: AXPopoverComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n #origin\n class=\"ax-editor-container ax-solid ax-default ax-lookup-trigger w-full\"\n [class.ax-state-disabled]=\"disabled()\"\n [class.ax-state-readonly]=\"readonly()\"\n (click)=\"onTriggerClick()\"\n>\n <div class=\"ax-lookup-value\">\n @if (showSelectedTemplate()) {\n <div class=\"ax-lookup-selected-content\" aria-hidden=\"true\">\n <ng-container\n [ngTemplateOutlet]=\"selectedTemplate()!\"\n [ngTemplateOutletContext]=\"{ $implicit: valueItems()[0] }\"\n />\n </div>\n }\n <input\n #triggerSearchInput\n type=\"text\"\n class=\"ax-input\"\n [class.ax-lookup-select-input]=\"!searchable()\"\n [class.ax-lookup-input-overlay]=\"showSelectedTemplate()\"\n [placeholder]=\"triggerSearchPlaceholder()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly() || !searchable()\"\n [attr.inputmode]=\"searchable() ? null : 'none'\"\n [value]=\"triggerInputValue()\"\n (input)=\"onTriggerSearchInput($any($event.target).value)\"\n (keydown)=\"onTriggerKeydown($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n\n @if (selectedValues().length > 0 && !disabled() && !readonly()) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n\n <button type=\"button\" class=\"ax-general-button-icon\" tabindex=\"-1\" [disabled]=\"disabled() || readonly()\">\n <span\n class=\"ax-icon\"\n [class.ax-icon-chevron-down]=\"!expanded()\"\n [class.ax-icon-chevron-up]=\"expanded()\"\n ></span>\n </button>\n\n <ng-content select=\"ax-validation-rule\"></ng-content>\n</div>\n\n<ax-popover\n [target]=\"origin\"\n [openOn]=\"'manual'\"\n [closeOn]=\"'clickOut'\"\n [placement]=\"'bottom-start'\"\n [width]=\"origin.offsetWidth + 'px'\"\n [disabled]=\"disabled() || readonly()\"\n (onClosed)=\"onPopoverClosed()\"\n>\n <div class=\"ax-lookup-popup\" (keydown.escape)=\"expanded.set(false)\">\n <axp-lookup-widget-table-panel\n [dataSource]=\"resolvedTableDataSource()\"\n [columns]=\"columns()\"\n [highlightText]=\"highlightQuery()\"\n [valueField]=\"valueField()\"\n [disabledField]=\"disabledField()\"\n [parentField]=\"parentField()\"\n [hasChildrenField]=\"hasChildrenField()\"\n [selectedValues]=\"selectedValues()\"\n (itemClick)=\"handleTableItemClick($event)\"\n ></axp-lookup-widget-table-panel>\n </div>\n</ax-popover>\n", styles: ["@layer properties;:host{display:block;width:100%}:host .ax-editor-container{justify-content:flex-start;gap:var(--spacing, .25rem)}:host .ax-lookup-trigger{cursor:pointer;-webkit-user-select:none;user-select:none}:host .ax-lookup-value{position:relative;display:flex;min-width:0px;flex:1;align-items:center;overflow:hidden}:host .ax-lookup-select-input{cursor:pointer;caret-color:transparent;-webkit-user-select:none;user-select:none}:host .ax-lookup-selected-content{pointer-events:none;position:relative;z-index:0;display:flex;min-width:0px;flex:1;align-items:center;overflow:hidden}:host .ax-lookup-input-overlay{position:absolute;inset:0;z-index:10;margin:0!important;height:100%;width:100%;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:0!important;color:transparent;caret-color:transparent}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "ngmodule", type: AXFormModule }, { kind: "component", type: AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "closeOnNavigation", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "ngmodule", type: AXValidationModule }, { kind: "component", type: AXPLookupWidgetTablePanelComponent, selector: "axp-lookup-widget-table-panel", inputs: ["dataSource", "columns", "valueField", "disabledField", "selectedValues", "parentField", "hasChildrenField", "itemHeight", "maxVisibleItems", "alternate", "highlightText"], outputs: ["itemClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
22472
23732
|
}
|
|
22473
23733
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupWidgetTableHostComponent, decorators: [{
|
|
22474
23734
|
type: Component,
|
|
@@ -22503,6 +23763,7 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22503
23763
|
this.contextEvalFactory = inject(AXPContextEvalFactory);
|
|
22504
23764
|
this.localeService = inject(AXLocaleService);
|
|
22505
23765
|
this.destroyRef = inject(DestroyRef);
|
|
23766
|
+
this.lookupByKeyCache = inject(AXPLookupByKeyCacheService);
|
|
22506
23767
|
//#endregion
|
|
22507
23768
|
//#region ----- View Children -----
|
|
22508
23769
|
this.lookup = viewChild(AXLookupComponent, /* @ts-ignore */
|
|
@@ -22530,6 +23791,7 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22530
23791
|
...(ngDevMode ? [{ debugName: "shouldFocus" }] : /* istanbul ignore next */ []));
|
|
22531
23792
|
/** Skips one {@link findByValue} pass after inline create when selection is already hydrated. */
|
|
22532
23793
|
this.skipFindByValueOnce = false;
|
|
23794
|
+
this.lastEditorLocaleKey = this.resolveEditorLocaleKey();
|
|
22533
23795
|
//#endregion
|
|
22534
23796
|
//#region ----- Computed Properties -----
|
|
22535
23797
|
this.expose = computed(() => this.options()['expose'], /* @ts-ignore */
|
|
@@ -22654,6 +23916,7 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22654
23916
|
if (!entity) {
|
|
22655
23917
|
return null;
|
|
22656
23918
|
}
|
|
23919
|
+
const entityKey = resolveLookupEntityCacheKey(entity);
|
|
22657
23920
|
return createLookupEntityDataSource({
|
|
22658
23921
|
entity,
|
|
22659
23922
|
displayField,
|
|
@@ -22662,6 +23925,11 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22662
23925
|
getCustomFilter: () => this.customFilter(),
|
|
22663
23926
|
transformFilter: (filter) => this.filterOperatorMiddleware.transformFilter(filter),
|
|
22664
23927
|
decorateItem: (item) => this.decorateLookupItem(item),
|
|
23928
|
+
byKey: this.lookupByKeyCache.wrap(entityKey, (id) => {
|
|
23929
|
+
const execute = entity.queries?.byKey?.execute;
|
|
23930
|
+
return execute ? execute(id) : Promise.resolve(null);
|
|
23931
|
+
}),
|
|
23932
|
+
onRow: (key, row) => this.lookupByKeyCache.remember(entityKey, key, row),
|
|
22665
23933
|
});
|
|
22666
23934
|
}, /* @ts-ignore */
|
|
22667
23935
|
...(ngDevMode ? [{ debugName: "entityDataSource" }] : /* istanbul ignore next */ []));
|
|
@@ -22731,7 +23999,14 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22731
23999
|
//#region ----- Lifecycle -----
|
|
22732
24000
|
this.editorLocaleChanged = merge$1(this.mlsResolver.langChanges$, this.localeService.profileChanged$)
|
|
22733
24001
|
.pipe(takeUntilDestroyed(this.destroyRef))
|
|
22734
|
-
.subscribe(() =>
|
|
24002
|
+
.subscribe(() => {
|
|
24003
|
+
const next = this.resolveEditorLocaleKey();
|
|
24004
|
+
if (next === this.lastEditorLocaleKey) {
|
|
24005
|
+
return;
|
|
24006
|
+
}
|
|
24007
|
+
this.lastEditorLocaleKey = next;
|
|
24008
|
+
this.rerenderEditor();
|
|
24009
|
+
});
|
|
22735
24010
|
this.#efEntity = effect(async () => {
|
|
22736
24011
|
const key = this.entity();
|
|
22737
24012
|
if (!key?.includes('.')) {
|
|
@@ -22936,14 +24211,16 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22936
24211
|
const existing = currentItems.find((item) => get(item, valueField) === id);
|
|
22937
24212
|
return existing == null || !isLookupItemHydrated(existing, hydration);
|
|
22938
24213
|
});
|
|
24214
|
+
const entityKey = this.entity();
|
|
22939
24215
|
const fetchedById = entityDef
|
|
22940
24216
|
? await fetchLookupRowsByKeys({
|
|
22941
24217
|
entity: entityDef,
|
|
22942
24218
|
valueField,
|
|
22943
24219
|
keys: idsToFetch,
|
|
22944
24220
|
getQueryFields: () => this.lookupQueryFields(),
|
|
22945
|
-
byKey: (id) => entityDataAccessor.byKey(id),
|
|
24221
|
+
byKey: this.lookupByKeyCache.wrap(entityKey, (id) => entityDataAccessor.byKey(id)),
|
|
22946
24222
|
queryList: (request) => entityDataAccessor.query(request),
|
|
24223
|
+
onRow: (key, row) => this.lookupByKeyCache.remember(entityKey, key, row),
|
|
22947
24224
|
})
|
|
22948
24225
|
: new Map();
|
|
22949
24226
|
const mergedItems = (await Promise.all(ids.map(async (id) => {
|
|
@@ -22977,6 +24254,11 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
22977
24254
|
filterMode: this.filterMode(),
|
|
22978
24255
|
};
|
|
22979
24256
|
}
|
|
24257
|
+
resolveEditorLocaleKey() {
|
|
24258
|
+
const lang = this.mlsResolver.getActiveLang() ?? '';
|
|
24259
|
+
const profile = this.localeService.activeProfile()?.localeInfo?.code ?? '';
|
|
24260
|
+
return `${lang}:${profile}`;
|
|
24261
|
+
}
|
|
22980
24262
|
rerenderEditor() {
|
|
22981
24263
|
this.localeEpoch.update((epoch) => epoch + 1);
|
|
22982
24264
|
this.editorKey.set(false);
|
|
@@ -23010,6 +24292,7 @@ class AXPLookupWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
23010
24292
|
return;
|
|
23011
24293
|
}
|
|
23012
24294
|
const decorated = await this.decorateLookupItem(createdItem);
|
|
24295
|
+
this.lookupByKeyCache.remember(this.entity(), newId, createdItem);
|
|
23013
24296
|
this.skipFindByValueOnce = true;
|
|
23014
24297
|
this.lookup()?.seedItems([decorated]);
|
|
23015
24298
|
if (this.multiple()) {
|
|
@@ -23239,6 +24522,7 @@ class AXPLookupWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
23239
24522
|
this.queryExecutor = inject(AXPQueryExecutor);
|
|
23240
24523
|
this.expressionEvaluator = inject(AXPExpressionEvaluatorService);
|
|
23241
24524
|
this.contextEvalFactory = inject(AXPContextEvalFactory);
|
|
24525
|
+
this.lookupByKeyCache = inject(AXPLookupByKeyCacheService);
|
|
23242
24526
|
//#endregion
|
|
23243
24527
|
//#region ---- View Children ----
|
|
23244
24528
|
this.moreButton = viewChild('moreButton', /* @ts-ignore */
|
|
@@ -23752,7 +25036,7 @@ class AXPLookupWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
23752
25036
|
this.resolveError.set(null);
|
|
23753
25037
|
try {
|
|
23754
25038
|
const accessor = this.entityService.withEntity(entityKey).data();
|
|
23755
|
-
const results = await Promise.all(ids.map((id) => accessor.byKey(
|
|
25039
|
+
const results = await Promise.all(ids.map((id) => this.lookupByKeyCache.getOrFetch(entityKey, id, (key) => accessor.byKey(key))));
|
|
23756
25040
|
this.resolvedPopoverItems.set(results.filter((item) => item != null));
|
|
23757
25041
|
this.resolveStatus.set('ready');
|
|
23758
25042
|
}
|
|
@@ -23858,7 +25142,7 @@ class AXPLookupWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
23858
25142
|
const requestId = ++this.hydrateRequestId;
|
|
23859
25143
|
try {
|
|
23860
25144
|
const accessor = this.entityService.withEntity(entityKey).data();
|
|
23861
|
-
const items = await Promise.all(ids.map((id) => accessor.byKey(
|
|
25145
|
+
const items = await Promise.all(ids.map((id) => this.lookupByKeyCache.getOrFetch(entityKey, id, (key) => accessor.byKey(key))));
|
|
23862
25146
|
if (requestId !== this.hydrateRequestId) {
|
|
23863
25147
|
return;
|
|
23864
25148
|
}
|
|
@@ -23996,7 +25280,7 @@ class AXPLookupWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
23996
25280
|
return /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(value) || /^\d+$/.test(value);
|
|
23997
25281
|
}
|
|
23998
25282
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupWidgetColumnComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
23999
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPLookupWidgetColumnComponent, isStandalone: true, selector: "ng-component", inputs: { rawValue: "rawValue", rowData: "rowData" }, viewQueries: [{ propertyName: "moreButton", first: true, predicate: ["moreButton"], descendants: true, isSignal: true }, { propertyName: "lazyTrigger", first: true, predicate: ["lazyTrigger"], descendants: true, isSignal: true }, { propertyName: "morePopover", first: true, predicate: ["morePopover"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (isHydratedStrategy()) {\n <div class=\"relative flex min-w-0 items-center gap-1\">\n @for (item of visibleItems(); track $index) {\n <span\n [class.cursor-pointer]=\"detailPopoverEnabled()\"\n [class.hover:text-primary]=\"detailPopoverEnabled()\"\n [class.hover:underline]=\"detailPopoverEnabled()\"\n (click)=\"handleItemClick($index, $event)\"\n >\n {{ getItemLabel($index) }}\n </span>\n @if ($index < visibleItems().length - 1) {\n <span class=\"text-muted\">\u2022</span>\n }\n } @empty {\n <span class=\"text-muted\">---</span>\n }\n @if (hasMoreItems()) {\n <span\n class=\"absolute end-0 flex h-full cursor-pointer items-center px-1 hover:primary-lighter-surface\"\n (click)=\"showMoreItems(); $event.stopPropagation()\"\n #moreButton\n >\n <i class=\"fa-light fa-ellipsis-vertical\"></i>\n </span>\n }\n </div>\n} @else {\n <div class=\"flex min-w-0 items-center gap-1\">\n @if (displayCount() > 0) {\n <span\n class=\"cursor-pointer text-primary hover:underline\"\n (click)=\"openLazyPopover(); $event.stopPropagation()\"\n #lazyTrigger\n >\n {{ summaryLabel() }}\n </span>\n } @else {\n <span class=\"text-muted\">---</span>\n }\n </div>\n}\n\n<ax-popover [openOn]=\"'manual'\" #morePopover (openChange)=\"onPopoverOpenChange($event)\">\n <div class=\"lightest-surface dark:dark-surface min-w-[280px] rounded-lg p-4 shadow-lg\">\n <div class=\"mb-4 border-b pb-2\">\n <h3 class=\"text-base font-semibold\">{{ popoverHeader() }}</h3>\n </div>\n\n @if (!isHydratedStrategy() && resolveStatus() === 'loading') {\n <div class=\"flex min-h-[120px] items-center justify-center\">\n <ax-loading></ax-loading>\n </div>\n } @else if (!isHydratedStrategy() && resolveStatus() === 'error') {\n <div class=\"text-danger text-sm\">{{ resolveError() }}</div>\n } @else {\n <div class=\"flex max-h-64 flex-col gap-3\">\n @for (item of popoverListItems(); track $index) {\n <span\n [class.cursor-pointer]=\"detailPopoverEnabled()\"\n [class.hover:text-primary]=\"detailPopoverEnabled()\"\n [class.hover:underline]=\"detailPopoverEnabled()\"\n (click)=\"handlePopoverItemClick($index, $event)\"\n >\n {{ getPopoverItemLabel($index) }}\n </span>\n } @empty {\n <span class=\"text-muted\">---</span>\n }\n </div>\n }\n </div>\n</ax-popover>\n", dependencies: [{ kind: "ngmodule", type: AXLoadingModule }, { kind: "component", type: i1$2.AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "ngmodule", type: AXPopoverModule }, { kind: "component", type: i1$1.AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
25283
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXPLookupWidgetColumnComponent, isStandalone: true, selector: "ng-component", inputs: { rawValue: "rawValue", rowData: "rowData" }, viewQueries: [{ propertyName: "moreButton", first: true, predicate: ["moreButton"], descendants: true, isSignal: true }, { propertyName: "lazyTrigger", first: true, predicate: ["lazyTrigger"], descendants: true, isSignal: true }, { propertyName: "morePopover", first: true, predicate: ["morePopover"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "@if (isHydratedStrategy()) {\n <div class=\"relative flex min-w-0 items-center gap-1\">\n @for (item of visibleItems(); track $index) {\n <span\n [class.cursor-pointer]=\"detailPopoverEnabled()\"\n [class.hover:text-primary]=\"detailPopoverEnabled()\"\n [class.hover:underline]=\"detailPopoverEnabled()\"\n (click)=\"handleItemClick($index, $event)\"\n >\n {{ getItemLabel($index) }}\n </span>\n @if ($index < visibleItems().length - 1) {\n <span class=\"text-muted\">\u2022</span>\n }\n } @empty {\n <span class=\"text-muted\">---</span>\n }\n @if (hasMoreItems()) {\n <span\n class=\"absolute end-0 flex h-full cursor-pointer items-center px-1 hover:primary-lighter-surface\"\n (click)=\"showMoreItems(); $event.stopPropagation()\"\n #moreButton\n >\n <i class=\"fa-light fa-ellipsis-vertical\"></i>\n </span>\n }\n </div>\n} @else {\n <div class=\"flex min-w-0 items-center gap-1\">\n @if (displayCount() > 0) {\n <span\n class=\"cursor-pointer text-primary hover:underline\"\n (click)=\"openLazyPopover(); $event.stopPropagation()\"\n #lazyTrigger\n >\n {{ summaryLabel() }}\n </span>\n } @else {\n <span class=\"text-muted\">---</span>\n }\n </div>\n}\n\n<ax-popover [openOn]=\"'manual'\" #morePopover (openChange)=\"onPopoverOpenChange($event)\">\n <div class=\"lightest-surface dark:dark-surface min-w-[280px] rounded-lg p-4 shadow-lg\">\n <div class=\"mb-4 border-b pb-2\">\n <h3 class=\"text-base font-semibold\">{{ popoverHeader() }}</h3>\n </div>\n\n @if (!isHydratedStrategy() && resolveStatus() === 'loading') {\n <div class=\"flex min-h-[120px] items-center justify-center\">\n <ax-loading></ax-loading>\n </div>\n } @else if (!isHydratedStrategy() && resolveStatus() === 'error') {\n <div class=\"text-danger text-sm\">{{ resolveError() }}</div>\n } @else {\n <div class=\"flex max-h-64 flex-col gap-3\">\n @for (item of popoverListItems(); track $index) {\n <span\n [class.cursor-pointer]=\"detailPopoverEnabled()\"\n [class.hover:text-primary]=\"detailPopoverEnabled()\"\n [class.hover:underline]=\"detailPopoverEnabled()\"\n (click)=\"handlePopoverItemClick($index, $event)\"\n >\n {{ getPopoverItemLabel($index) }}\n </span>\n } @empty {\n <span class=\"text-muted\">---</span>\n }\n </div>\n }\n </div>\n</ax-popover>\n", dependencies: [{ kind: "ngmodule", type: AXLoadingModule }, { kind: "component", type: i1$2.AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "ngmodule", type: AXPopoverModule }, { kind: "component", type: i1$1.AXPopoverComponent, selector: "ax-popover", inputs: ["width", "disablePanelClass", "visualContextScope", "disabled", "offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "closeOnScroll", "closeOnNavigation", "backdropClass", "panelClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
24000
25284
|
}
|
|
24001
25285
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPLookupWidgetColumnComponent, decorators: [{
|
|
24002
25286
|
type: Component,
|
|
@@ -24741,7 +26025,7 @@ class AXPMultiSourceSelectorComponent extends AXBasePageComponent {
|
|
|
24741
26025
|
></ax-button>
|
|
24742
26026
|
</ax-suffix>
|
|
24743
26027
|
</ax-footer>
|
|
24744
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXTabsModule }, { kind: "component", type: i2$1.AXTabsComponent, selector: "ax-tabs", inputs: ["look", "location", "reorderable", "reorderDelay", "fitParent", "minWidth", "content"], outputs: ["onActiveTabChanged", "onTabsReordered"] }, { kind: "component", type: i2$1.AXTabItemComponent, selector: "ax-tab-item", inputs: ["disabled", "text", "key", "headerTemplate", "active"], outputs: ["disabledChange", "onClick", "onBlur", "onFocus", "activeChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
26028
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i1.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXTabsModule }, { kind: "component", type: i2$1.AXTabsComponent, selector: "ax-tabs", inputs: ["look", "location", "reorderable", "reorderDelay", "renderMode", "stacked", "fitParent", "minWidth", "content"], outputs: ["onActiveTabChanged", "onTabsReordered"] }, { kind: "component", type: i2$1.AXTabItemComponent, selector: "ax-tab-item", inputs: ["disabled", "text", "key", "headerTemplate", "active"], outputs: ["disabledChange", "onClick", "onBlur", "onFocus", "activeChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "pipe", type: i1$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3$1.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
24745
26029
|
}
|
|
24746
26030
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXPMultiSourceSelectorComponent, decorators: [{
|
|
24747
26031
|
type: Component,
|
|
@@ -27883,6 +29167,7 @@ class AXPPageListConverter extends AXPBaseRelatedEntityConverter {
|
|
|
27883
29167
|
relatedTableColumns,
|
|
27884
29168
|
customFilterDefinitions: relatedEntity.customFilterDefinitions,
|
|
27885
29169
|
excludeProperties: relatedEntity.excludeProperties,
|
|
29170
|
+
...relatedEntityListViewWidgetOptions(relatedEntity),
|
|
27886
29171
|
},
|
|
27887
29172
|
},
|
|
27888
29173
|
],
|
|
@@ -28002,6 +29287,7 @@ class AXPTabListConverter extends AXPBaseRelatedEntityConverter {
|
|
|
28002
29287
|
relatedTableColumns,
|
|
28003
29288
|
customFilterDefinitions: relatedEntity.customFilterDefinitions,
|
|
28004
29289
|
excludeProperties: relatedEntity.excludeProperties,
|
|
29290
|
+
...relatedEntityListViewWidgetOptions(relatedEntity),
|
|
28005
29291
|
},
|
|
28006
29292
|
},
|
|
28007
29293
|
],
|
|
@@ -29307,9 +30593,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
29307
30593
|
* Use high numbers (990+) for columns that should appear at the end.
|
|
29308
30594
|
*/
|
|
29309
30595
|
const DEFAULT_COLUMN_ORDER = {
|
|
29310
|
-
// Identifier columns first
|
|
30596
|
+
// Identifier columns first (after profile band on Employee)
|
|
30597
|
+
profile: 0,
|
|
29311
30598
|
code: 1,
|
|
29312
|
-
employeeCode:
|
|
30599
|
+
employeeCode: 2,
|
|
29313
30600
|
// Common display columns
|
|
29314
30601
|
title: 3,
|
|
29315
30602
|
name: 4,
|
|
@@ -29338,6 +30625,7 @@ const DEFAULT_COLUMN_ORDER = {
|
|
|
29338
30625
|
attachments: 800,
|
|
29339
30626
|
//
|
|
29340
30627
|
statusId: 995,
|
|
30628
|
+
status: 995,
|
|
29341
30629
|
isArchived: 999,
|
|
29342
30630
|
isDisabled: 999,
|
|
29343
30631
|
};
|
|
@@ -29752,6 +31040,69 @@ const defaultCardLayoutMiddlewareProvider = {
|
|
|
29752
31040
|
};
|
|
29753
31041
|
//#endregion
|
|
29754
31042
|
|
|
31043
|
+
//#region ----- Default sort presets middleware -----
|
|
31044
|
+
/**
|
|
31045
|
+
* When an entity has a master list, fills missing Quick Presets from date/title fields.
|
|
31046
|
+
* Entity-authored `sortPresets` with the same `name` win.
|
|
31047
|
+
*/
|
|
31048
|
+
const defaultSortPresetsMiddleware = (context) => {
|
|
31049
|
+
if (!context.interfaces.master.list.get()) {
|
|
31050
|
+
return;
|
|
31051
|
+
}
|
|
31052
|
+
const inferred = inferEntityListSortPresets(context.entity);
|
|
31053
|
+
if (!inferred.length) {
|
|
31054
|
+
return;
|
|
31055
|
+
}
|
|
31056
|
+
context.interfaces.master.list.update((list) => {
|
|
31057
|
+
const existing = list?.sortPresets ?? [];
|
|
31058
|
+
const existingNames = new Set(existing.map((preset) => preset.name));
|
|
31059
|
+
const extras = inferred.filter((preset) => !existingNames.has(preset.name));
|
|
31060
|
+
if (!extras.length) {
|
|
31061
|
+
return list ?? { views: [] };
|
|
31062
|
+
}
|
|
31063
|
+
return {
|
|
31064
|
+
...list,
|
|
31065
|
+
views: list?.views ?? [],
|
|
31066
|
+
sortPresets: [...existing, ...extras],
|
|
31067
|
+
};
|
|
31068
|
+
});
|
|
31069
|
+
};
|
|
31070
|
+
//#endregion
|
|
31071
|
+
//#region ----- Provider registration -----
|
|
31072
|
+
const defaultSortPresetsMiddlewareProvider = {
|
|
31073
|
+
entityName: '*',
|
|
31074
|
+
modifier: defaultSortPresetsMiddleware,
|
|
31075
|
+
order: 500,
|
|
31076
|
+
};
|
|
31077
|
+
//#endregion
|
|
31078
|
+
|
|
31079
|
+
//#region ----- Query sort locale -----
|
|
31080
|
+
/**
|
|
31081
|
+
* Copies the active UI locale onto `params.locale` so server sort can resolve
|
|
31082
|
+
* multi-language fields for that language. Keeps an explicit locale already set.
|
|
31083
|
+
*/
|
|
31084
|
+
function stampQueryLocale(input, locale) {
|
|
31085
|
+
if (!isPlainObject(input)) {
|
|
31086
|
+
return input;
|
|
31087
|
+
}
|
|
31088
|
+
const record = input;
|
|
31089
|
+
const currentParams = isPlainObject(record['params'])
|
|
31090
|
+
? { ...record['params'] }
|
|
31091
|
+
: {};
|
|
31092
|
+
const existing = currentParams['locale'];
|
|
31093
|
+
if (typeof existing === 'string' && existing.trim()) {
|
|
31094
|
+
return input;
|
|
31095
|
+
}
|
|
31096
|
+
return {
|
|
31097
|
+
...record,
|
|
31098
|
+
params: {
|
|
31099
|
+
...currentParams,
|
|
31100
|
+
locale: locale.trim() || 'en-US',
|
|
31101
|
+
},
|
|
31102
|
+
};
|
|
31103
|
+
}
|
|
31104
|
+
//#endregion
|
|
31105
|
+
|
|
29755
31106
|
//#region ----- Imports -----
|
|
29756
31107
|
//#endregion
|
|
29757
31108
|
//#region ----- Helpers -----
|
|
@@ -29876,8 +31227,16 @@ function createEntityQueryBridge(op) {
|
|
|
29876
31227
|
return next(context);
|
|
29877
31228
|
}
|
|
29878
31229
|
const skipContext = inject(AXPEntityMiddlewareSkipContext);
|
|
31230
|
+
const translation = inject(AXTranslationService);
|
|
31231
|
+
const locale = translation.getActiveLang()?.trim() || 'en-US';
|
|
29879
31232
|
if (skipContext.isSkipped) {
|
|
29880
|
-
|
|
31233
|
+
if (op !== 'query') {
|
|
31234
|
+
return next(context);
|
|
31235
|
+
}
|
|
31236
|
+
return next({
|
|
31237
|
+
...context,
|
|
31238
|
+
input: stampQueryLocale(context.input, locale),
|
|
31239
|
+
});
|
|
29881
31240
|
}
|
|
29882
31241
|
const injector = inject(EnvironmentInjector);
|
|
29883
31242
|
const accessor = inject(AXPEntityRuntimeAccessorService);
|
|
@@ -29895,7 +31254,10 @@ function createEntityQueryBridge(op) {
|
|
|
29895
31254
|
const ctx = createEntityMiddlewareContext(op, entityName, accessor, {
|
|
29896
31255
|
request: input,
|
|
29897
31256
|
});
|
|
29898
|
-
await runEntityMiddlewarePipeline(allMiddlewares, ctx, async () => next({
|
|
31257
|
+
await runEntityMiddlewarePipeline(allMiddlewares, ctx, async () => next({
|
|
31258
|
+
key,
|
|
31259
|
+
input: stampQueryLocale(ctx.request ?? input, locale),
|
|
31260
|
+
}), injector);
|
|
29899
31261
|
return ctx.result;
|
|
29900
31262
|
};
|
|
29901
31263
|
}
|
|
@@ -30044,6 +31406,7 @@ const AXPCrudModifier = {
|
|
|
30044
31406
|
const parentKey = ctx.parentKey.get();
|
|
30045
31407
|
const request = parentKey != null ? applyHierarchicalRootListFilter(e, parentKey) : e;
|
|
30046
31408
|
const result = await queryService.fetch(ENTITY_QUERY_DEFAULT, { entity: entityKey, ...request });
|
|
31409
|
+
console.log('event', e);
|
|
30047
31410
|
if (result && !result.success) {
|
|
30048
31411
|
throw AXPRequestError.fromCommandResult(result);
|
|
30049
31412
|
}
|
|
@@ -30313,6 +31676,7 @@ function routesFacory() {
|
|
|
30313
31676
|
loadComponent: () => {
|
|
30314
31677
|
return config.viewers.master.details();
|
|
30315
31678
|
},
|
|
31679
|
+
canActivate: [AXPMenuRouteGuard],
|
|
30316
31680
|
canDeactivate: [axpDetailsViewCanDeactivateGuard],
|
|
30317
31681
|
data: { reuse: 'queryParamsChange' },
|
|
30318
31682
|
},
|
|
@@ -30432,6 +31796,11 @@ class AXPEntityModule {
|
|
|
30432
31796
|
useValue: defaultMultiLanguageMiddlewareProvider,
|
|
30433
31797
|
multi: true,
|
|
30434
31798
|
},
|
|
31799
|
+
{
|
|
31800
|
+
provide: AXP_ENTITY_MODIFIER,
|
|
31801
|
+
useValue: defaultSortPresetsMiddlewareProvider,
|
|
31802
|
+
multi: true,
|
|
31803
|
+
},
|
|
30435
31804
|
provideCommandSetups([
|
|
30436
31805
|
{
|
|
30437
31806
|
key: 'Entity:OpenDetails',
|
|
@@ -30459,7 +31828,7 @@ class AXPEntityModule {
|
|
|
30459
31828
|
},
|
|
30460
31829
|
{
|
|
30461
31830
|
key: 'Entity:Bulk',
|
|
30462
|
-
command: () => import('./acorex-platform-framework-client-layout-entity-bulk-entity.command-
|
|
31831
|
+
command: () => import('./acorex-platform-framework-client-layout-entity-bulk-entity.command-BONV249y.mjs').then((c) => c.AXPBulkEntityCommand),
|
|
30463
31832
|
},
|
|
30464
31833
|
{
|
|
30465
31834
|
key: 'Entity:OpenList',
|
|
@@ -30588,6 +31957,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
30588
31957
|
useValue: defaultMultiLanguageMiddlewareProvider,
|
|
30589
31958
|
multi: true,
|
|
30590
31959
|
},
|
|
31960
|
+
{
|
|
31961
|
+
provide: AXP_ENTITY_MODIFIER,
|
|
31962
|
+
useValue: defaultSortPresetsMiddlewareProvider,
|
|
31963
|
+
multi: true,
|
|
31964
|
+
},
|
|
30591
31965
|
provideCommandSetups([
|
|
30592
31966
|
{
|
|
30593
31967
|
key: 'Entity:OpenDetails',
|
|
@@ -30615,7 +31989,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
30615
31989
|
},
|
|
30616
31990
|
{
|
|
30617
31991
|
key: 'Entity:Bulk',
|
|
30618
|
-
command: () => import('./acorex-platform-framework-client-layout-entity-bulk-entity.command-
|
|
31992
|
+
command: () => import('./acorex-platform-framework-client-layout-entity-bulk-entity.command-BONV249y.mjs').then((c) => c.AXPBulkEntityCommand),
|
|
30619
31993
|
},
|
|
30620
31994
|
{
|
|
30621
31995
|
key: 'Entity:OpenList',
|
|
@@ -30940,5 +32314,5 @@ function detectEntityChanges(oldObj, newObj) {
|
|
|
30940
32314
|
* Generated bundle index. Do not edit.
|
|
30941
32315
|
*/
|
|
30942
32316
|
|
|
30943
|
-
export { AXPEntityListViewModelResolver as $, AXPEntityDefinitionRegistryService as A, AXPEntityCategoryWidgetViewComponent as B, AXPEntityCommandTriggerViewModel as C, AXPEntityCreateViewElementViewModel as D, AXPEntityCreateViewModelFactory as E, AXPEntityCreateViewSectionViewModel as F, AXPEntityDataProvider as G, AXPEntityDataProviderImpl as H, AXPEntityDataSelectorRowActionsService as I, AXPEntityDataSelectorService as J, AXPEntityDefinitionProviderWidget as K, AXPEntityDefinitionProviderWidgetEditComponent as L, AXPEntityDeletePerformService as M, AXPEntityDetailListViewModel as N, AXPEntityDetailPopoverComponent as O, AXPEntityDetailPopoverService as P, AXPEntityDetailViewModelFactory as Q, AXPEntityDetailViewModelResolver as R, AXPEntityEventDispatcherService as S, AXPEntityFormBuilderService as T, AXPEntityLifecycleHookKeys as U, AXPEntityListPersistenceModeDefault as V, AXPEntityListTableService as W, AXPEntityListToolbarService as X, AXPEntityListViewCardFieldViewModel as Y, AXPEntityListViewColumnViewModel as Z, AXPEntityListViewModelFactory as _, showOperationResultToast as a,
|
|
30944
|
-
//# sourceMappingURL=acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-
|
|
32317
|
+
export { AXPEntityListViewModelResolver as $, AXPEntityDefinitionRegistryService as A, AXPEntityCategoryWidgetViewComponent as B, AXPEntityCommandTriggerViewModel as C, AXPEntityCreateViewElementViewModel as D, AXPEntityCreateViewModelFactory as E, AXPEntityCreateViewSectionViewModel as F, AXPEntityDataProvider as G, AXPEntityDataProviderImpl as H, AXPEntityDataSelectorRowActionsService as I, AXPEntityDataSelectorService as J, AXPEntityDefinitionProviderWidget as K, AXPEntityDefinitionProviderWidgetEditComponent as L, AXPEntityDeletePerformService as M, AXPEntityDetailListViewModel as N, AXPEntityDetailPopoverComponent as O, AXPEntityDetailPopoverService as P, AXPEntityDetailViewModelFactory as Q, AXPEntityDetailViewModelResolver as R, AXPEntityEventDispatcherService as S, AXPEntityFormBuilderService as T, AXPEntityLifecycleHookKeys as U, AXPEntityListPersistenceModeDefault as V, AXPEntityListTableService as W, AXPEntityListToolbarService as X, AXPEntityListViewCardFieldViewModel as Y, AXPEntityListViewColumnViewModel as Z, AXPEntityListViewModelFactory as _, showOperationResultToast as a, AXP_CATEGORY_TREE_ROOT_TITLE_I18N_KEY as a$, AXPEntityListWidget as a0, AXPEntityListWidgetViewComponent as a1, AXPEntityMasterCreateViewModel as a2, AXPEntityMasterListCardSelectActionName as a3, AXPEntityMasterListViewModel as a4, AXPEntityMasterListViewQueryViewModel as a5, AXPEntityMasterSingleElementViewModel as a6, AXPEntityMasterSingleViewGroupViewModel as a7, AXPEntityMasterSingleViewModel as a8, AXPEntityMasterUpdateElementViewModel as a9, AXPLookupWidgetViewComponent as aA, AXPMiddlewareAbortError as aB, AXPMiddlewareEntityStorageService as aC, AXPMultiSourceDefinitionProviderContext as aD, AXPMultiSourceDefinitionProviderService as aE, AXPMultiSourceFederatedSearchService as aF, AXPMultiSourceSelectorComponent as aG, AXPMultiSourceSelectorService as aH, AXPMultiSourceSelectorWidget as aI, AXPMultiSourceSelectorWidgetColumnComponent as aJ, AXPMultiSourceSelectorWidgetEditComponent as aK, AXPMultiSourceSelectorWidgetViewComponent as aL, AXPMultiSourceType as aM, AXPOpenEntityDetailsCommand as aN, AXPOpenEntityListCommand as aO, AXPRelatedColumnEnrichmentService as aP, AXPRelatedColumnMetadataResolver as aQ, AXPSelectorStructureWidget as aR, AXPSelectorStructureWidgetColumnComponent as aS, AXPSelectorStructureWidgetEditComponent as aT, AXPSelectorStructureWidgetViewComponent as aU, AXPShowFileUploaderPopupCommand as aV, AXPTruncatedBreadcrumbComponent as aW, AXPUpdateEntityCommand as aX, AXPUpdateEntityStatusCommand as aY, AXPViewEntityDetailsCommand as aZ, AXP_APPEARANCE_SECTION_ORDER as a_, AXPEntityMasterUpdateViewModel as aa, AXPEntityMasterUpdateViewModelFactory as ab, AXPEntityMiddlewareSkipContext as ac, AXPEntityModule as ad, AXPEntityPreloadFiltersContainerComponent as ae, AXPEntityPreloadFiltersViewModel as af, AXPEntityPreloadFiltersViewModelResolver as ag, AXPEntityResolver as ah, AXPEntityRuntimeAccessorService as ai, AXPEntityService as aj, AXPEntityStorageService as ak, AXPEntityUpdateViewSectionViewModel as al, AXPFileListComponent as am, AXPFileUploaderLoadFilesQuery as an, AXPFileUploaderSaveFilesCommand as ao, AXPFileUploaderWidget as ap, AXPFileUploaderWidgetColumnComponent as aq, AXPFileUploaderWidgetEditComponent as ar, AXPFileUploaderWidgetService as as, AXPFileUploaderWidgetViewComponent as at, AXPGetEntityDetailsQuery as au, AXPLayoutOrderingConfigService as av, AXPLookupByKeyCacheService as aw, AXPLookupWidget as ax, AXPLookupWidgetColumnComponent as ay, AXPLookupWidgetEditComponent as az, buildSelectedIdsFilter as b, detectEntityChanges as b$, AXP_CLASSIFICATION_SECTION_ORDER as b0, AXP_CLIENT_LOCAL_DEFAULT_MAX_ITEMS as b1, AXP_CLIENT_LOCAL_PLUGIN_NAME as b2, AXP_DATA_SEEDER_TOKEN as b3, AXP_ENTITY_ACTION_PLUGIN as b4, AXP_ENTITY_CONFIG_TOKEN as b5, AXP_ENTITY_DEFINITION_LOADER as b6, AXP_ENTITY_MIDDLEWARE as b7, AXP_ENTITY_MODIFIER as b8, AXP_ENTITY_STORAGE_MIDDLEWARE as b9, axpUpdateEntityStatusCommandDefinition as bA, buildDataSourceTraceSnapshot as bB, canPersistEntityListState as bC, clientLocalPlugin as bD, cloneLayoutArrays as bE, columnOrderingMiddleware as bF, columnOrderingMiddlewareProvider as bG, columnWidthMiddleware as bH, columnWidthMiddlewareProvider as bI, committedAttachments as bJ, composeEntityMiddlewares as bK, composeEntityStorageMiddlewares as bL, computeEntityAggregates as bM, configureEntityListColumnsSettingsMigrateDrop as bN, configureEntityListColumnsSettingsVersion as bO, createColumnOrderingMiddlewareProvider as bP, createEntityCardDisplayScope as bQ, createEntityCardLogicScope as bR, createEntityMiddlewareContext as bS, createEntityStorageContext as bT, createLayoutOrderingMiddlewareProvider as bU, defaultCardLayoutMiddleware as bV, defaultCardLayoutMiddlewareProvider as bW, defaultMultiLanguageMiddleware as bX, defaultMultiLanguageMiddlewareProvider as bY, defaultSortPresetsMiddleware as bZ, defaultSortPresetsMiddlewareProvider as b_, AXP_MULTI_SOURCE_DEFINITION_PROVIDER as ba, DEFAULT_COLUMN_ORDER as bb, DEFAULT_PAIR_SPAN_RULES as bc, DEFAULT_PROPERTY_ORDER as bd, DEFAULT_SECTION_ORDER as be, ENTITY_FORM_ACTION_FIRST_STEP_CONTINUE as bf, ENTITY_LIST_LAYOUT_META as bg, ENTITY_LIST_ROUTE_CONTEXT_SESSION_KEY as bh, ENTITY_MASTER_LIST_TRACE_NS as bi, EntityBuilder as bj, EntityDataAccessor as bk, GALLERY_PAGE_COMPONENT_KEY as bl, TREE_CHILDREN_QUERY_TAKE as bm, actionExists as bn, applyDataSourcePagingWithoutLoad as bo, attachmentFieldCount as bp, attachmentNeedsHydration as bq, attachmentsPlugin as br, attachmentsSemanticallyEqual as bs, axpBuildEntityListPageContextSnapshot as bt, axpCreateEntityAiToolInputDefaults as bu, axpCreateEntityCommandDefinition as bv, axpDeleteEntityCommandDefinition as bw, axpOpenEntityListCommandDefinition as bx, axpRunEntityListPageContextAction as by, axpShowFileUploaderPopupCommandDefinition as bz, ATTACHMENTS_PAGE_COMPONENT_KEY as c, readPersistedEntityListInstanceCurrentView as c$, dispatchEntityModifiedSideEffects as c0, ensureHierarchicalRootFilter as c1, ensureLayoutPropertyView as c2, ensureLayoutSection as c3, ensureListActions as c4, entityCreateBridgeMiddleware as c5, entityDeleteBridgeMiddleware as c6, entityGetOneBridgeMiddleware as c7, entityListInstanceCurrentViewPath as c8, entityListInstanceFilterPath as c9, hydrateAttachmentFieldToFileList as cA, isAXPMiddlewareAbortError as cB, isAttachmentFieldPresentOnRow as cC, isAttachmentListEntry as cD, isAttachmentStorageRef as cE, isCategoryEntity as cF, isCategoryFilter as cG, isFileListItem as cH, isFileUploaderEditDialogAuto as cI, isLegacyEntityDataSelectorOptions as cJ, layoutOrderingMiddlewareFactory as cK, layoutOrderingMiddlewareProvider as cL, mapEntityStorageErrorToCommandResult as cM, mapLegacyEntityDataSelectorOptions as cN, mergeEntityListViewAndPersistedFilters as cO, normalizeEntityCardHeaderDisplayValue as cP, normalizeEntityDataSelectorColumnSpecs as cQ, normalizeEntityDataSelectorOptions as cR, normalizeEntityFieldToFileList as cS, normalizeEntityListPersistenceMode as cT, normalizeListPaging as cU, prefetchClientLocalRelated as cV, provideEntity as cW, provideEntityMiddlewareBridge as cX, provideEntityRealtimeHandlers as cY, provideEntityStorageMiddlewareBridge as cZ, provideLocalEntityCatalog as c_, entityListStylingRulesPath as ca, entityQueryBridgeMiddleware as cb, entityStorageCreateBridgeMiddleware as cc, entityStorageDeleteBridgeMiddleware as cd, entityStorageGetOneBridgeMiddleware as ce, entityStorageQueryBridgeMiddleware as cf, entityStorageUpdateBridgeMiddleware as cg, entityUpdateBridgeMiddleware as ch, eventDispatchMiddleware as ci, filterEntityMiddlewares as cj, filterEntityStorageMiddlewares as ck, filterSortEntityRows as cl, filterTouchesParentKey as cm, findEntityListRowDataInTree as cn, fingerprintAttachmentItem as co, fingerprintAttachments as cp, fireEntityLifecycleHook as cq, formatLookupItemDisplay as cr, formatLookupItemDisplayAsync as cs, galleryPlugin as ct, getDataSourcePageIndex as cu, getEntityListColumnsSettingsMigrateDrop as cv, getEntityListColumnsSettingsVersion as cw, getEntityListRowId as cx, getMasterInterfacePropertySortKey as cy, hasFileUploaderTitleOrDescriptionFields as cz, AXMEntityCrudService as d, readPersistedEntityListInstanceFilters as d0, readPersistedEntityListStylingRules as d1, resetPagingForTreeChildrenLoad as d2, resolveAttachmentFieldPath as d3, resolveEntityCardBadgeColorValue as d4, resolveEntityCardHeaderValue as d5, resolveEntityMasterFieldStylingClass as d6, resolveEntityMasterRecordStylingClass as d7, resolveEntityMasterStylingClass as d8, resolveEntityPluginDetailPageOrder as d9, resolveFileUploaderEditDialog as da, resolveFileUploaderEntityScope as db, resolveLookupDisplayField as dc, resolveLookupDisplayTemplate as dd, resolveLookupEntityCacheKey as de, resolveLookupEntityKey as df, resolveMasterInterfacePropertyOrder as dg, restoreEntityListExpandedRows as dh, runEntityMiddlewarePipeline as di, runEntityQuery as dj, runEntityStorageMiddlewarePipeline as dk, searchResultDescriptionMiddleware as dl, searchResultDescriptionMiddlewareProvider as dm, shouldLoadEntityListStateFromStorage as dn, shouldResetEntityListStateOnRouteEntry as dp, traceEntityMasterList as dq, AXMEntityCrudServiceImpl as e, AXPCategoryTreeService as f, AXPClientLocalPluginModule as g, AXPCreateEntityCommand as h, AXPDataSeederService as i, AXPDeleteEntityCommand as j, AXPDomainQueryEntityDefinitionLoader as k, AXPEditFileUploaderCommand as l, AXPEntityBulkPatchPerformService as m, newBulkExecutionId as n, AXPEntityCardComponent as o, persistedAttachments as p, AXPEntityCardFieldsResolver as q, resolveBulkFailureBody as r, settleAfterLoadingDialog as s, AXPEntityCardSelectActionName as t, AXPEntityCardSkeletonComponent as u, AXPEntityCategoryTreeSelectorComponent as v, watchBulkProgress as w, AXPEntityCategoryWidget as x, AXPEntityCategoryWidgetColumnComponent as y, AXPEntityCategoryWidgetEditComponent as z };
|
|
32318
|
+
//# sourceMappingURL=acorex-platform-framework-client-layout-entity-acorex-platform-framework-client-layout-entity-Dc_NpBx6.mjs.map
|