@acorex/platform 21.0.0-next.0 → 21.0.0-next.2

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.
Files changed (69) hide show
  1. package/auth/index.d.ts +238 -92
  2. package/common/index.d.ts +42 -606
  3. package/core/index.d.ts +432 -574
  4. package/fesm2022/acorex-platform-auth.mjs +200 -153
  5. package/fesm2022/acorex-platform-auth.mjs.map +1 -1
  6. package/fesm2022/acorex-platform-common.mjs +112 -1009
  7. package/fesm2022/acorex-platform-common.mjs.map +1 -1
  8. package/fesm2022/acorex-platform-core.mjs +416 -694
  9. package/fesm2022/acorex-platform-core.mjs.map +1 -1
  10. package/fesm2022/acorex-platform-domain.mjs +11 -54
  11. package/fesm2022/acorex-platform-domain.mjs.map +1 -1
  12. package/fesm2022/acorex-platform-layout-builder.mjs +272 -414
  13. package/fesm2022/acorex-platform-layout-builder.mjs.map +1 -1
  14. package/fesm2022/acorex-platform-layout-components.mjs +3105 -2064
  15. package/fesm2022/acorex-platform-layout-components.mjs.map +1 -1
  16. package/fesm2022/acorex-platform-layout-designer.mjs +7 -7
  17. package/fesm2022/acorex-platform-layout-designer.mjs.map +1 -1
  18. package/fesm2022/acorex-platform-layout-entity.mjs +648 -756
  19. package/fesm2022/acorex-platform-layout-entity.mjs.map +1 -1
  20. package/fesm2022/acorex-platform-layout-views.mjs +4 -4
  21. package/fesm2022/acorex-platform-layout-views.mjs.map +1 -1
  22. package/fesm2022/acorex-platform-layout-widget-core.mjs +174 -248
  23. package/fesm2022/acorex-platform-layout-widget-core.mjs.map +1 -1
  24. package/fesm2022/acorex-platform-layout-widgets-extra-properties-schema-widget-edit.component-fhhZOWul.mjs +50 -0
  25. package/fesm2022/acorex-platform-layout-widgets-extra-properties-schema-widget-edit.component-fhhZOWul.mjs.map +1 -0
  26. package/fesm2022/acorex-platform-layout-widgets-extra-properties-schema-widget-view.component-C3Qbs0fz.mjs +42 -0
  27. package/fesm2022/acorex-platform-layout-widgets-extra-properties-schema-widget-view.component-C3Qbs0fz.mjs.map +1 -0
  28. package/fesm2022/acorex-platform-layout-widgets-extra-properties-values-widget-edit.component-CngQBUlN.mjs +55 -0
  29. package/fesm2022/acorex-platform-layout-widgets-extra-properties-values-widget-edit.component-CngQBUlN.mjs.map +1 -0
  30. package/fesm2022/acorex-platform-layout-widgets-extra-properties-values-widget-view.component-DSNo9e4W.mjs +50 -0
  31. package/fesm2022/acorex-platform-layout-widgets-extra-properties-values-widget-view.component-DSNo9e4W.mjs.map +1 -0
  32. package/fesm2022/acorex-platform-layout-widgets-extra-properties-widget-edit.component-CL0CwEHX.mjs +48 -0
  33. package/fesm2022/acorex-platform-layout-widgets-extra-properties-widget-edit.component-CL0CwEHX.mjs.map +1 -0
  34. package/fesm2022/acorex-platform-layout-widgets-extra-properties-widget-view.component-B6Fi0xTw.mjs +42 -0
  35. package/fesm2022/acorex-platform-layout-widgets-extra-properties-widget-view.component-B6Fi0xTw.mjs.map +1 -0
  36. package/fesm2022/{acorex-platform-layout-widgets-file-list-popup.component-CxrsI6Hn.mjs → acorex-platform-layout-widgets-file-list-popup.component-D0y-9nE5.mjs} +2 -2
  37. package/fesm2022/acorex-platform-layout-widgets-file-list-popup.component-D0y-9nE5.mjs.map +1 -0
  38. package/fesm2022/{acorex-platform-layout-widgets-tabular-data-edit-popup.component-Ck7-wpT2.mjs → acorex-platform-layout-widgets-tabular-data-edit-popup.component-m8rHZP8L.mjs} +2 -2
  39. package/fesm2022/acorex-platform-layout-widgets-tabular-data-edit-popup.component-m8rHZP8L.mjs.map +1 -0
  40. package/fesm2022/acorex-platform-layout-widgets.mjs +974 -2994
  41. package/fesm2022/acorex-platform-layout-widgets.mjs.map +1 -1
  42. package/fesm2022/{acorex-platform-themes-default-entity-master-create-view.component-VIGuU5M4.mjs → acorex-platform-themes-default-entity-master-create-view.component-mARj77Mr.mjs} +5 -26
  43. package/fesm2022/acorex-platform-themes-default-entity-master-create-view.component-mARj77Mr.mjs.map +1 -0
  44. package/fesm2022/{acorex-platform-themes-default-entity-master-list-view.component-DyDa_hyd.mjs → acorex-platform-themes-default-entity-master-list-view.component-Cym8pq0v.mjs} +5 -4
  45. package/fesm2022/acorex-platform-themes-default-entity-master-list-view.component-Cym8pq0v.mjs.map +1 -0
  46. package/fesm2022/acorex-platform-themes-default-entity-master-modify-view.component-BTA6h7Xd.mjs +101 -0
  47. package/fesm2022/acorex-platform-themes-default-entity-master-modify-view.component-BTA6h7Xd.mjs.map +1 -0
  48. package/fesm2022/{acorex-platform-themes-default-entity-master-single-view.component-eMBby9k4.mjs → acorex-platform-themes-default-entity-master-single-view.component-B_P0a5KW.mjs} +3 -3
  49. package/fesm2022/acorex-platform-themes-default-entity-master-single-view.component-B_P0a5KW.mjs.map +1 -0
  50. package/fesm2022/acorex-platform-themes-default.mjs +30 -166
  51. package/fesm2022/acorex-platform-themes-default.mjs.map +1 -1
  52. package/fesm2022/acorex-platform-themes-shared.mjs +27 -27
  53. package/fesm2022/acorex-platform-themes-shared.mjs.map +1 -1
  54. package/layout/builder/index.d.ts +1 -4
  55. package/layout/components/index.d.ts +327 -405
  56. package/layout/designer/index.d.ts +3 -3
  57. package/layout/entity/index.d.ts +108 -163
  58. package/layout/widget-core/index.d.ts +49 -39
  59. package/layout/widgets/index.d.ts +54 -368
  60. package/package.json +1 -1
  61. package/themes/default/index.d.ts +2 -15
  62. package/themes/shared/index.d.ts +10 -10
  63. package/fesm2022/acorex-platform-layout-widgets-file-list-popup.component-CxrsI6Hn.mjs.map +0 -1
  64. package/fesm2022/acorex-platform-layout-widgets-tabular-data-edit-popup.component-Ck7-wpT2.mjs.map +0 -1
  65. package/fesm2022/acorex-platform-themes-default-entity-master-create-view.component-VIGuU5M4.mjs.map +0 -1
  66. package/fesm2022/acorex-platform-themes-default-entity-master-list-view.component-DyDa_hyd.mjs.map +0 -1
  67. package/fesm2022/acorex-platform-themes-default-entity-master-modify-view.component-Ua3ZA5hk.mjs +0 -101
  68. package/fesm2022/acorex-platform-themes-default-entity-master-modify-view.component-Ua3ZA5hk.mjs.map +0 -1
  69. package/fesm2022/acorex-platform-themes-default-entity-master-single-view.component-eMBby9k4.mjs.map +0 -1
@@ -4,8 +4,8 @@ import { kebabCase, merge, sortBy, cloneDeep, get, omit } from 'lodash-es';
4
4
  import { Router, ROUTES, RouterModule } from '@angular/router';
5
5
  import { AXPSessionService, AXPSessionStatus } from '@acorex/platform/auth';
6
6
  import { Subject, distinctUntilChanged, merge as merge$1 } from 'rxjs';
7
- import * as i1 from '@acorex/platform/core';
8
- import { AXPModuleProviderRegistry, AXPPlatformScope, AXPBroadcastEventService, objectKeyValueTransforms, AXPSystemActionType, AXP_MODULE_PROVIDER_INITIALIZER, AXPAppStartUpProvider, AXP_EXPRESSION_EVALUATOR_SCOPE_PROVIDER, AXPModuleManifestRegistry } from '@acorex/platform/core';
7
+ import * as i1$1 from '@acorex/platform/core';
8
+ import { AXPPlatformScope, AXPBroadcastEventService, objectKeyValueTransforms, AXPComponentLogoConfig, AXPImageUrlLogoConfig, AXPSystemActionType, AXPAppStartUpProvider, AXP_EXPRESSION_EVALUATOR_SCOPE_PROVIDER } from '@acorex/platform/core';
9
9
  import { AXTranslationService } from '@acorex/core/translation';
10
10
  import { AXPWidgetsCatalog } from '@acorex/platform/layout/widget-core';
11
11
  import { AXPopupModule, AXPopupService } from '@acorex/components/popup';
@@ -13,7 +13,14 @@ import { AXToastService, AXToastModule } from '@acorex/components/toast';
13
13
  import { AXDateTimeModule } from '@acorex/core/date-time';
14
14
  import * as i3 from '@acorex/platform/workflow';
15
15
  import { AXPWorkflowService, createWorkFlowEvent, AXPWorkflowAction, AXPWorkflowError, AXPWorkflowModule } from '@acorex/platform/workflow';
16
- import { AXPCommandExecutor, AXPCommandService } from '@acorex/platform/runtime';
16
+ import * as i4 from '@acorex/components/decorators';
17
+ import { AXDecoratorModule } from '@acorex/components/decorators';
18
+ import * as i2 from '@acorex/components/image';
19
+ import { AXImageModule } from '@acorex/components/image';
20
+ import { AXPlatform } from '@acorex/core/platform';
21
+ import * as i1 from '@angular/common';
22
+ import { CommonModule } from '@angular/common';
23
+ import { AXPCommandExecutor } from '@acorex/platform/runtime';
17
24
  import { signalStore, withState, withMethods, patchState, withHooks } from '@ngrx/signals';
18
25
  import { AXFormatService } from '@acorex/core/format';
19
26
  import { AXDialogService } from '@acorex/components/dialog';
@@ -22,15 +29,13 @@ import { AXButtonModule } from '@acorex/components/button';
22
29
  import { AXCheckBoxModule } from '@acorex/components/check-box';
23
30
  import * as i6 from '@acorex/components/color-box';
24
31
  import { AXColorBoxModule } from '@acorex/components/color-box';
25
- import * as i4 from '@acorex/components/decorators';
26
- import { AXDecoratorModule } from '@acorex/components/decorators';
27
32
  import * as i3$1 from '@acorex/components/label';
28
33
  import { AXLabelModule } from '@acorex/components/label';
29
- import * as i2 from '@acorex/components/number-box';
34
+ import * as i2$1 from '@acorex/components/number-box';
30
35
  import { AXNumberBoxModule } from '@acorex/components/number-box';
31
36
  import { AXBasePageComponent } from '@acorex/components/page';
32
37
  import { AXTextBoxModule } from '@acorex/components/text-box';
33
- import * as i1$1 from '@angular/forms';
38
+ import * as i1$2 from '@angular/forms';
34
39
  import { FormsModule } from '@angular/forms';
35
40
 
36
41
  const AXP_APP_VERSION_PROVIDER = new InjectionToken('AXP_APP_VERSION_PROVIDER', {
@@ -128,24 +133,24 @@ function createAllQueryView(params = {
128
133
  });
129
134
  }
130
135
 
131
- const EQ_OPER = { name: 'equal', title: '@general:terms.operators.equal', hasValue: true };
132
- const NOT_EQ_OPER = { name: 'notEqual', title: '@general:terms.operators.not-equal', hasValue: true };
133
- const GT_OPER = { name: 'greaterThan', title: '@general:terms.operators.greater-than', hasValue: true };
134
- const LT_OPER = { name: 'lessThan', title: '@general:terms.operators.less-than', hasValue: true };
136
+ const EQ_OPER = { name: 'equal', title: 'Equal', hasValue: true };
137
+ const NOT_EQ_OPER = { name: 'notEqual', title: 'Not Equal', hasValue: true };
138
+ const GT_OPER = { name: 'greaterThan', title: 'Greater Than', hasValue: true };
139
+ const LT_OPER = { name: 'lessThan', title: 'Less Than', hasValue: true };
135
140
  const GTE_OPER = {
136
141
  name: 'greaterThanOrEqual',
137
- title: '@general:terms.operators.greater-than-or-equal',
142
+ title: 'Greater Than or Equal',
138
143
  hasValue: true,
139
144
  };
140
- const LTE_OPER = { name: 'lessThanOrEqual', title: '@general:terms.operators.less-than-or-equal', hasValue: true };
141
- const CONTAINS_OPER = { name: 'contains', title: '@general:terms.operators.contains', hasValue: true };
142
- const NOT_CONTAINS_OPER = { name: 'notContains', title: '@general:terms.operators.not-contains', hasValue: true };
143
- const IN_OPER = { name: 'in', title: '@general:terms.operators.in', hasValue: true };
144
- const STARTS_WITH_OPER = { name: 'startsWith', title: '@general:terms.operators.starts-with', hasValue: true };
145
- const ENDS_WITH_OPER = { name: 'endsWith', title: '@general:terms.operators.ends-with', hasValue: true };
146
- const IS_EMPTY_OPER = { name: 'isEmpty', title: '@general:terms.operators.is-empty', hasValue: false };
147
- const IS_NOT_EMPTY_OPER = { name: 'isNotEmpty', title: '@general:terms.operators.is-not-empty', hasValue: false };
148
- const BETWEEN_OPER = { name: 'between', title: '@general:terms.operators.between', hasValue: true };
145
+ const LTE_OPER = { name: 'lessThanOrEqual', title: 'Less Than or Equal', hasValue: true };
146
+ const CONTAINS_OPER = { name: 'contains', title: 'Contains', hasValue: true };
147
+ const NOT_CONTAINS_OPER = { name: 'notContains', title: 'Does Not Contain', hasValue: true };
148
+ const IN_OPER = { name: 'in', title: 'In', hasValue: true };
149
+ const STARTS_WITH_OPER = { name: 'startsWith', title: 'Starts With', hasValue: true };
150
+ const ENDS_WITH_OPER = { name: 'endsWith', title: 'Ends With', hasValue: true };
151
+ const IS_EMPTY_OPER = { name: 'isEmpty', title: 'Is Empty', hasValue: false };
152
+ const IS_NOT_EMPTY_OPER = { name: 'isNotEmpty', title: 'Is Not Empty', hasValue: false };
153
+ const BETWEEN_OPER = { name: 'between', title: 'Between', hasValue: true };
149
154
  const STRING_OPERATORS = [
150
155
  EQ_OPER,
151
156
  NOT_EQ_OPER,
@@ -322,7 +327,6 @@ const AXP_SETTING_DEFINITION_PROVIDER = new InjectionToken('AXP_SETTING_DEFINITI
322
327
  class AXPSettingDefinitionProviderService {
323
328
  constructor() {
324
329
  this.providers = inject(AXP_SETTING_DEFINITION_PROVIDER, { optional: true });
325
- this.providerRegistry = inject(AXPModuleProviderRegistry);
326
330
  this.cache = null;
327
331
  }
328
332
  async load() {
@@ -330,7 +334,6 @@ class AXPSettingDefinitionProviderService {
330
334
  return;
331
335
  }
332
336
  const context = new AXPSettingDefinitionProviderContext();
333
- // Load providers from DI tokens (backward compatibility)
334
337
  if (Array.isArray(this.providers)) {
335
338
  for (const provider of this.providers) {
336
339
  if (provider instanceof Promise) {
@@ -344,11 +347,6 @@ class AXPSettingDefinitionProviderService {
344
347
  }
345
348
  }
346
349
  }
347
- // Load providers from registry (manifest-based, conditionally loaded)
348
- const registryProviders = this.providerRegistry.getSettingProviders();
349
- for (const provider of registryProviders) {
350
- await provider.provide(context);
351
- }
352
350
  this.cache = context.getGroups();
353
351
  }
354
352
  async reload() {
@@ -558,7 +556,7 @@ class AXPSettingValueProviderDefault {
558
556
  }
559
557
  }
560
558
 
561
- class AXPSettingsService {
559
+ class AXPSettingService {
562
560
  constructor() {
563
561
  this.providers = inject(AXP_SETTING_VALUE_PROVIDER);
564
562
  this.injector = inject(Injector);
@@ -678,10 +676,10 @@ class AXPSettingsService {
678
676
  this.onChanged.next(event);
679
677
  this.eventService.publish('AXPSettingChangedEvent', event);
680
678
  }
681
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
682
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingsService, providedIn: 'root' }); }
679
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
680
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingService, providedIn: 'root' }); }
683
681
  }
684
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingsService, decorators: [{
682
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPSettingService, decorators: [{
685
683
  type: Injectable,
686
684
  args: [{
687
685
  providedIn: 'root',
@@ -737,38 +735,9 @@ class ScopedSettingService {
737
735
  }
738
736
  }
739
737
 
740
- /**
741
- * Regional settings keys for date, time, and locale formatting.
742
- * These keys are used by platform widgets and components to access regional settings.
743
- * The actual setting definitions and providers are implemented in the locale-management module.
744
- */
745
- var AXPRegionalSetting;
746
- (function (AXPRegionalSetting) {
747
- AXPRegionalSetting["LocaleProfile"] = "LocaleManagement:Setting:Regional.LocaleProfile";
748
- AXPRegionalSetting["TimeZone"] = "LocaleManagement:Setting:Regional.TimeZone";
749
- AXPRegionalSetting["Language"] = "LocaleManagement:Setting:Regional.Language";
750
- AXPRegionalSetting["Country"] = "LocaleManagement:Setting:Regional.Country";
751
- AXPRegionalSetting["Calendar"] = "LocaleManagement:Setting:Regional.Calendar";
752
- AXPRegionalSetting["FirstDayOfWeek"] = "LocaleManagement:Setting:Regional.FirstDayOfWeek";
753
- AXPRegionalSetting["WeekendDays"] = "LocaleManagement:Setting:Regional.WeekendDays";
754
- AXPRegionalSetting["ShortDate"] = "LocaleManagement:Setting:Regional.ShortDate";
755
- AXPRegionalSetting["MediumDate"] = "LocaleManagement:Setting:Regional.MediumDate";
756
- AXPRegionalSetting["LongDate"] = "LocaleManagement:Setting:Regional.LongDate";
757
- AXPRegionalSetting["ShortTime"] = "LocaleManagement:Setting:Regional.ShortTime";
758
- AXPRegionalSetting["MediumTime"] = "LocaleManagement:Setting:Regional.MediumTime";
759
- AXPRegionalSetting["LongTime"] = "LocaleManagement:Setting:Regional.LongTime";
760
- AXPRegionalSetting["MeasurementUnits"] = "LocaleManagement:Setting:Regional.MeasurementUnits";
761
- AXPRegionalSetting["TemperatureUnits"] = "LocaleManagement:Setting:Regional.TemperatureUnits";
762
- AXPRegionalSetting["DistanceUnits"] = "LocaleManagement:Setting:Regional.DistanceUnits";
763
- AXPRegionalSetting["WeightUnits"] = "LocaleManagement:Setting:Regional.WeightUnits";
764
- AXPRegionalSetting["VolumeUnits"] = "LocaleManagement:Setting:Regional.VolumeUnits";
765
- AXPRegionalSetting["SpeedUnits"] = "LocaleManagement:Setting:Regional.SpeedUnits";
766
- AXPRegionalSetting["AreaUnits"] = "LocaleManagement:Setting:Regional.AreaUnits";
767
- })(AXPRegionalSetting || (AXPRegionalSetting = {}));
768
-
769
738
  var AXPHomePageSettings;
770
739
  (function (AXPHomePageSettings) {
771
- AXPHomePageSettings["UserHomePath"] = "Common:Setting:Startup.HomePage";
740
+ AXPHomePageSettings["UserHomePath"] = "general:startup:home-page";
772
741
  })(AXPHomePageSettings || (AXPHomePageSettings = {}));
773
742
 
774
743
  class AXPHomePageService {
@@ -779,7 +748,7 @@ class AXPHomePageService {
779
748
  this.defaultHomePageKey = inject(AXP_HOME_PAGE_DEFAULT_KEY, { optional: true }) ?? 'home';
780
749
  this.userHomePageKey = null;
781
750
  this.candidates = inject(AXP_HOME_PAGES, { optional: true }) ?? [];
782
- this.settingsService = inject(AXPSettingsService);
751
+ this.settingsService = inject(AXPSettingService);
783
752
  this.sessionService = inject(AXPSessionService);
784
753
  this.injector = inject(Injector);
785
754
  this.originalConfig = null;
@@ -1112,61 +1081,43 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
1112
1081
  args: [{ providedIn: 'root' }]
1113
1082
  }], ctorParameters: () => [{ type: i0.Injector }, { type: AXPErrorHandlerRegistryService }] });
1114
1083
 
1115
- const AXP_TOKEN_DEFINITION_PROVIDER = new InjectionToken('AXP_TOKEN_DEFINITION_PROVIDER', {
1084
+ const AXP_GLOBAL_VARIABLE_DEFINITION_PROVIDER = new InjectionToken('AXP_GLOBAL_VARIABLE_DEFINITION_PROVIDER', {
1116
1085
  factory: () => [],
1117
1086
  });
1118
1087
 
1119
1088
  //#region ---- Imports ----
1120
1089
  //#endregion
1121
- class AXPTokenDefinitionService {
1090
+ class AXPGlobalVariableDefinitionService {
1122
1091
  constructor() {
1123
1092
  //#region ---- Providers & Caches ----
1124
- this.definitionProviders = inject(AXP_TOKEN_DEFINITION_PROVIDER, { optional: true }) || [];
1093
+ this.definitionProviders = inject(AXP_GLOBAL_VARIABLE_DEFINITION_PROVIDER, { optional: true }) || [];
1125
1094
  /** Cache for definitions by name. */
1126
1095
  this.definitionsByName = new Map();
1127
1096
  }
1128
1097
  //#endregion
1129
1098
  //#region ---- Public API ----
1130
1099
  /**
1131
- * Returns a token definition by its name.
1100
+ * Returns a report definition by its id.
1132
1101
  * First checks the cache, then queries all providers if not found.
1133
- * @param name The token name.
1134
- * @returns The token definition if found, undefined otherwise.
1102
+ * @param name The global variable name.
1103
+ * @returns The global variable definition if found, undefined otherwise.
1135
1104
  */
1136
- async getDefinition(name) {
1105
+ async getByName(name) {
1137
1106
  // Check cache first
1138
1107
  if (this.definitionsByName.has(name)) {
1139
1108
  return this.definitionsByName.get(name);
1140
1109
  }
1141
- // Not in cache, query providers
1142
- // Resolve all providers (some may be promises, some may be arrays)
1110
+ // Not in cache, query providers (each provider is itself a global variable definition)
1143
1111
  const resolvedProviders = await Promise.all(this.definitionProviders);
1144
- // Flatten the array - some providers may be arrays of providers (e.g., dynamic token providers)
1145
- const flattenedProviders = [];
1146
- for (const provider of resolvedProviders) {
1147
- if (Array.isArray(provider)) {
1148
- // If provider is an array, add all items
1149
- flattenedProviders.push(...provider);
1150
- }
1151
- else if (provider) {
1152
- // If provider is a single provider, add it
1153
- flattenedProviders.push(provider);
1154
- }
1155
- }
1156
- const match = flattenedProviders.find(def => def?.name === name);
1112
+ const match = resolvedProviders.find(def => def?.name === name);
1157
1113
  if (match) {
1158
1114
  this.definitionsByName.set(name, match);
1159
1115
  return match;
1160
1116
  }
1161
1117
  return undefined;
1162
1118
  }
1163
- /**
1164
- * Gets the resolved value of a token by its name.
1165
- * @param name The token name.
1166
- * @returns The resolved token value, or undefined if the token is not found.
1167
- */
1168
- async getValue(name) {
1169
- const definition = await this.getDefinition(name);
1119
+ async execute(name) {
1120
+ const definition = await this.getByName(name);
1170
1121
  if (definition) {
1171
1122
  return await definition.execute();
1172
1123
  }
@@ -1178,24 +1129,24 @@ class AXPTokenDefinitionService {
1178
1129
  clearDefinitionsCache() {
1179
1130
  this.definitionsByName.clear();
1180
1131
  }
1181
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPTokenDefinitionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1182
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPTokenDefinitionService, providedIn: 'root' }); }
1132
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPGlobalVariableDefinitionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1133
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPGlobalVariableDefinitionService, providedIn: 'root' }); }
1183
1134
  }
1184
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPTokenDefinitionService, decorators: [{
1135
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPGlobalVariableDefinitionService, decorators: [{
1185
1136
  type: Injectable,
1186
1137
  args: [{
1187
1138
  providedIn: 'root',
1188
1139
  }]
1189
1140
  }] });
1190
1141
 
1191
- class AXPTokenEvaluatorScopeProvider {
1142
+ class AXPGlobalVariableEvaluatorScopeProvider {
1192
1143
  constructor() {
1193
- this.tokenService = inject(AXPTokenDefinitionService);
1144
+ this.globalVariableService = inject(AXPGlobalVariableDefinitionService);
1194
1145
  }
1195
1146
  async provide(context) {
1196
- context.addScope('tokens', {
1197
- get: async (name) => {
1198
- return await this.tokenService.getValue(name);
1147
+ context.addScope('variables', {
1148
+ execute: async (name) => {
1149
+ return await this.globalVariableService.execute(name);
1199
1150
  }
1200
1151
  });
1201
1152
  }
@@ -1305,6 +1256,46 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
1305
1256
  type: Input
1306
1257
  }] } });
1307
1258
 
1259
+ class AXPLogoComponent {
1260
+ constructor() {
1261
+ this.platform = inject(AXPlatform);
1262
+ }
1263
+ ngOnInit() {
1264
+ this.setLogoType();
1265
+ this.platform.themeMode$.subscribe(() => {
1266
+ this.setLogoTheme();
1267
+ });
1268
+ }
1269
+ ngOnChanges() {
1270
+ this.setLogoTheme();
1271
+ }
1272
+ setLogoType() {
1273
+ switch (true) {
1274
+ case this.source instanceof AXPImageUrlLogoConfig:
1275
+ this.logoType = 'url';
1276
+ break;
1277
+ case this.source instanceof AXPComponentLogoConfig:
1278
+ this.logoType = 'component';
1279
+ break;
1280
+ default:
1281
+ break;
1282
+ }
1283
+ }
1284
+ setLogoTheme() {
1285
+ if (this.source && this.source.dark && this.source.light) {
1286
+ this.source = this.platform.isDark() ? this.source.dark : this.source.light;
1287
+ }
1288
+ }
1289
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPLogoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1290
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.12", type: AXPLogoComponent, isStandalone: true, selector: "axp-logo", inputs: { source: "source" }, host: { classAttribute: "ax-flex ax-justify-center" }, usesOnChanges: true, ngImport: i0, template: "@switch (logoType) { @case ('url') {\n<ax-image [width]=\"source.width\" [height]=\"source.height\" [src]=\"source.url\"></ax-image>\n} @case ('component') {\n<ng-container *ngComponentOutlet=\"source.component\"></ng-container>\n} }\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"], exportAs: ["ngComponentOutlet"] }, { kind: "ngmodule", type: AXImageModule }, { kind: "component", type: i2.AXImageComponent, selector: "ax-image", inputs: ["width", "height", "overlayMode", "src", "alt", "priority", "lazy"], outputs: ["onLoad", "onError"] }, { kind: "ngmodule", type: AXDecoratorModule }] }); }
1291
+ }
1292
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPLogoComponent, decorators: [{
1293
+ type: Component,
1294
+ args: [{ selector: 'axp-logo', imports: [CommonModule, AXImageModule, AXDecoratorModule], host: { class: 'ax-flex ax-justify-center' }, template: "@switch (logoType) { @case ('url') {\n<ax-image [width]=\"source.width\" [height]=\"source.height\" [src]=\"source.url\"></ax-image>\n} @case ('component') {\n<ng-container *ngComponentOutlet=\"source.component\"></ng-container>\n} }\n" }]
1295
+ }], propDecorators: { source: [{
1296
+ type: Input
1297
+ }] } });
1298
+
1308
1299
  //#region ---- Menu Context Builder ----
1309
1300
  /**
1310
1301
  * Creates a rich context for menu manipulation
@@ -1636,12 +1627,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
1636
1627
  }] });
1637
1628
 
1638
1629
  const AXP_MENU_PROVIDER = new InjectionToken('AXP_MENU_PROVIDER');
1639
- //TODO: check performance of this service
1640
1630
  class AXPMenuProviderService {
1641
1631
  constructor() {
1642
1632
  //#region ---- Dependencies ----
1643
1633
  this.providers = inject(AXP_MENU_PROVIDER, { optional: true });
1644
- this.providerRegistry = inject(AXPModuleProviderRegistry);
1645
1634
  this.middlewareRegistry = inject(AXPMenuMiddlewareRegistry);
1646
1635
  //#endregion
1647
1636
  //#region ---- State ----
@@ -1669,17 +1658,11 @@ class AXPMenuProviderService {
1669
1658
  }
1670
1659
  const items = [];
1671
1660
  const context = this.createMenuProviderContext(items);
1672
- // Load providers from DI tokens (backward compatibility)
1673
1661
  if (Array.isArray(this.providers)) {
1674
1662
  for (const provider of this.providers) {
1675
1663
  await provider.provide(context);
1676
1664
  }
1677
1665
  }
1678
- // Load providers from registry (manifest-based, conditionally loaded)
1679
- const registryProviders = this.providerRegistry.getMenuProviders();
1680
- for (const provider of registryProviders) {
1681
- await provider.provide(context);
1682
- }
1683
1666
  // Apply pending operations
1684
1667
  this.applyPendingOperations(items);
1685
1668
  // Sort items by priority
@@ -1699,17 +1682,11 @@ class AXPMenuProviderService {
1699
1682
  async rawItems() {
1700
1683
  const items = [];
1701
1684
  const context = this.createMenuProviderContext(items);
1702
- // Load providers from DI tokens (backward compatibility)
1703
1685
  if (Array.isArray(this.providers)) {
1704
1686
  for (const provider of this.providers) {
1705
1687
  await provider.provide(context);
1706
1688
  }
1707
1689
  }
1708
- // Load providers from registry (manifest-based, conditionally loaded)
1709
- const registryProviders = this.providerRegistry.getMenuProviders();
1710
- for (const provider of registryProviders) {
1711
- await provider.provide(context);
1712
- }
1713
1690
  // Apply pending operations
1714
1691
  this.applyPendingOperations(items);
1715
1692
  // Sort items by priority
@@ -1755,29 +1732,10 @@ class AXPMenuProviderService {
1755
1732
  createMenuProviderContext(items) {
1756
1733
  return {
1757
1734
  addItems: (newItems) => {
1758
- for (const newItem of newItems) {
1759
- if (newItem.name) {
1760
- const existingItem = this.findItemByName(items, newItem.name);
1761
- if (existingItem) {
1762
- // Update existing item, merging properties
1763
- this.mergeMenuItem(existingItem, newItem);
1764
- }
1765
- else {
1766
- // Add new item if it doesn't exist
1767
- items.push(newItem);
1768
- }
1769
- }
1770
- else {
1771
- // Add item without name (no way to check for duplicates)
1772
- items.push(newItem);
1773
- }
1774
- }
1735
+ items.push(...newItems);
1775
1736
  },
1776
1737
  find: (target) => {
1777
- const foundItemInfo = this.findItemWithParent(items, target);
1778
- const exists = foundItemInfo.foundItem !== null;
1779
1738
  return {
1780
- exists,
1781
1739
  insert: (newItems, position) => {
1782
1740
  this.pendingInserts.push({ target, newItems, position });
1783
1741
  },
@@ -1803,48 +1761,13 @@ class AXPMenuProviderService {
1803
1761
  items.push(...newItems);
1804
1762
  }
1805
1763
  else {
1806
- if (position === 'inside') {
1807
- if (!foundItem.children) {
1808
- foundItem.children = [];
1809
- }
1810
- // Check for duplicates by name and merge or add
1811
- for (const newItem of newItems) {
1812
- if (newItem.name) {
1813
- const existingChild = this.findItemByName(foundItem.children, newItem.name);
1814
- if (existingChild) {
1815
- this.mergeMenuItem(existingChild, newItem);
1816
- }
1817
- else {
1818
- foundItem.children.push(newItem);
1819
- }
1820
- }
1821
- else {
1822
- foundItem.children.push(newItem);
1823
- }
1824
- }
1764
+ if (position == 'inside') {
1765
+ foundItem.children?.push(...newItems);
1825
1766
  }
1826
1767
  else {
1827
- // For 'before' and 'after', check for duplicates in parent items
1828
- const itemsToInsert = [];
1829
- for (const newItem of newItems) {
1830
- if (newItem.name) {
1831
- const existingItem = this.findItemByName(parentItems, newItem.name);
1832
- if (existingItem) {
1833
- this.mergeMenuItem(existingItem, newItem);
1834
- }
1835
- else {
1836
- itemsToInsert.push(newItem);
1837
- }
1838
- }
1839
- else {
1840
- itemsToInsert.push(newItem);
1841
- }
1842
- }
1843
- if (itemsToInsert.length > 0) {
1844
- const index = parentItems.indexOf(foundItem);
1845
- const insertPosition = position === 'before' ? index : index + 1;
1846
- parentItems.splice(insertPosition, 0, ...itemsToInsert);
1847
- }
1768
+ const index = parentItems.indexOf(foundItem);
1769
+ const insertPosition = position === 'before' ? index : index + 1;
1770
+ parentItems.splice(insertPosition, 0, ...newItems);
1848
1771
  }
1849
1772
  }
1850
1773
  }
@@ -1879,21 +1802,7 @@ class AXPMenuProviderService {
1879
1802
  if (!foundItem.children) {
1880
1803
  foundItem.children = [];
1881
1804
  }
1882
- // Check for duplicates by name and merge or add
1883
- for (const newItem of newItems) {
1884
- if (newItem.name) {
1885
- const existingChild = this.findItemByName(foundItem.children, newItem.name);
1886
- if (existingChild) {
1887
- this.mergeMenuItem(existingChild, newItem);
1888
- }
1889
- else {
1890
- foundItem.children.push(newItem);
1891
- }
1892
- }
1893
- else {
1894
- foundItem.children.push(newItem);
1895
- }
1896
- }
1805
+ foundItem.children.push(...newItems);
1897
1806
  }
1898
1807
  }
1899
1808
  // Clear pending operations after applying them
@@ -1916,70 +1825,6 @@ class AXPMenuProviderService {
1916
1825
  }
1917
1826
  return { foundItem: null, parentItems: items };
1918
1827
  }
1919
- /**
1920
- * Find menu item by name in the items tree (recursive search)
1921
- */
1922
- findItemByName(items, name) {
1923
- for (const item of items) {
1924
- if (item.name === name) {
1925
- return item;
1926
- }
1927
- if (item.children) {
1928
- const found = this.findItemByName(item.children, name);
1929
- if (found) {
1930
- return found;
1931
- }
1932
- }
1933
- }
1934
- return null;
1935
- }
1936
- /**
1937
- * Merge new item properties into existing item, handling children merge
1938
- */
1939
- mergeMenuItem(existingItem, newItem) {
1940
- // Merge top-level properties (newItem properties override existing only if defined)
1941
- if (newItem.text !== undefined)
1942
- existingItem.text = newItem.text;
1943
- if (newItem.description !== undefined)
1944
- existingItem.description = newItem.description;
1945
- if (newItem.icon !== undefined)
1946
- existingItem.icon = newItem.icon;
1947
- if (newItem.path !== undefined)
1948
- existingItem.path = newItem.path;
1949
- if (newItem.priority !== undefined)
1950
- existingItem.priority = newItem.priority;
1951
- if (newItem.type !== undefined)
1952
- existingItem.type = newItem.type;
1953
- if (newItem.command !== undefined)
1954
- existingItem.command = newItem.command;
1955
- if (newItem.badgeKey !== undefined)
1956
- existingItem.badgeKey = newItem.badgeKey;
1957
- if (newItem.data !== undefined)
1958
- existingItem.data = newItem.data;
1959
- if (newItem.policy !== undefined)
1960
- existingItem.policy = newItem.policy;
1961
- // Merge children if both have children
1962
- if (newItem.children && newItem.children.length > 0) {
1963
- if (!existingItem.children) {
1964
- existingItem.children = [];
1965
- }
1966
- // For each child in newItem, check if it exists by name and merge or add
1967
- for (const newChild of newItem.children) {
1968
- if (newChild.name) {
1969
- const existingChild = this.findItemByName(existingItem.children, newChild.name);
1970
- if (existingChild) {
1971
- this.mergeMenuItem(existingChild, newChild);
1972
- }
1973
- else {
1974
- existingItem.children.push(newChild);
1975
- }
1976
- }
1977
- else {
1978
- existingItem.children.push(newChild);
1979
- }
1980
- }
1981
- }
1982
- }
1983
1828
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPMenuProviderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1984
1829
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPMenuProviderService, providedIn: 'root' }); }
1985
1830
  }
@@ -2206,105 +2051,6 @@ withMethods((store, router = inject(Router), workflow = inject(AXPWorkflowServic
2206
2051
  };
2207
2052
  }));
2208
2053
 
2209
- /**
2210
- * Service for checking menu item visibility based on permissions, features, and children.
2211
- * This service helps filter out empty menu items that have no visible children.
2212
- */
2213
- class AXPMenuVisibilityService {
2214
- constructor() {
2215
- this.sessionService = inject(AXPSessionService);
2216
- }
2217
- /**
2218
- * Checks if a menu item should be visible based on permissions and features.
2219
- */
2220
- isItemVisible(item) {
2221
- const policy = item.policy;
2222
- if (!policy) {
2223
- return true; // No policy means visible
2224
- }
2225
- // Check permissions
2226
- if (policy.permissions && policy.permissions.length > 0) {
2227
- const permissionKeys = Array.isArray(policy.permissions) ? policy.permissions : [policy.permissions];
2228
- if (!this.sessionService.authorize(...permissionKeys)) {
2229
- return false;
2230
- }
2231
- }
2232
- // Check features
2233
- if (policy.features && policy.features.length > 0) {
2234
- const featureKeys = Array.isArray(policy.features) ? policy.features : [policy.features];
2235
- if (!this.sessionService.isFeatureEnabled(...featureKeys)) {
2236
- return false;
2237
- }
2238
- }
2239
- return true;
2240
- }
2241
- /**
2242
- * Recursively checks if a menu item has any visible children.
2243
- * @param item The menu item to check
2244
- * @param getRouterLink Optional function to check if an item has a router link
2245
- */
2246
- hasVisibleChildren(item, getRouterLink) {
2247
- if (!item.children || item.children.length === 0) {
2248
- return false;
2249
- }
2250
- return item.children.some((child) => {
2251
- // Check if child itself is visible
2252
- if (!this.isItemVisible(child)) {
2253
- return false;
2254
- }
2255
- // If child has a routerLink, it's visible
2256
- if (getRouterLink && getRouterLink(child)) {
2257
- return true;
2258
- }
2259
- // If child has visible children, it's visible
2260
- if (this.hasVisibleChildren(child, getRouterLink)) {
2261
- return true;
2262
- }
2263
- // For items without routerLink, check if they have a command (non-empty menu items)
2264
- if (child.command) {
2265
- return true;
2266
- }
2267
- return false;
2268
- });
2269
- }
2270
- /**
2271
- * Determines if a menu item should be rendered.
2272
- * A menu item should be rendered if:
2273
- * 1. It has a routerLink, OR
2274
- * 2. It has visible children, OR
2275
- * 3. It has a command (for non-router navigation)
2276
- *
2277
- * @param item The menu item to check
2278
- * @param getRouterLink Optional function to check if an item has a router link
2279
- */
2280
- shouldRenderMenuItem(item, getRouterLink) {
2281
- // Check if item itself is visible (permissions/features)
2282
- if (!this.isItemVisible(item)) {
2283
- return false;
2284
- }
2285
- // If it has a routerLink, render it
2286
- if (getRouterLink && getRouterLink(item)) {
2287
- return true;
2288
- }
2289
- // If it has visible children, render it
2290
- if (this.hasVisibleChildren(item, getRouterLink)) {
2291
- return true;
2292
- }
2293
- // If it has a command (for non-router navigation), render it
2294
- if (item.command) {
2295
- return true;
2296
- }
2297
- // Otherwise, don't render empty menu items
2298
- return false;
2299
- }
2300
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPMenuVisibilityService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
2301
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPMenuVisibilityService, providedIn: 'root' }); }
2302
- }
2303
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPMenuVisibilityService, decorators: [{
2304
- type: Injectable,
2305
- args: [{ providedIn: 'root' }]
2306
- }] });
2307
-
2308
2054
  class AXPMenuSearchDefinitionProvider {
2309
2055
  async provide(context) {
2310
2056
  context.addDefinition('menu', 'Menu', 'menu', 'fa-thin fa-bars', 2, {
@@ -2499,7 +2245,6 @@ const AXP_SEARCH_DEFINITION_PROVIDER = new InjectionToken('AXP_SEARCH_DEFINITION
2499
2245
  class AXPSearchDefinitionProviderService {
2500
2246
  constructor() {
2501
2247
  this.providers = inject(AXP_SEARCH_DEFINITION_PROVIDER, { optional: true });
2502
- this.providerRegistry = inject(AXPModuleProviderRegistry);
2503
2248
  this.cache = null;
2504
2249
  }
2505
2250
  async load() {
@@ -2507,14 +2252,11 @@ class AXPSearchDefinitionProviderService {
2507
2252
  return;
2508
2253
  }
2509
2254
  const context = new AXPSearchDefinitionProviderContext();
2510
- // Load providers from DI tokens (backward compatibility)
2511
2255
  if (Array.isArray(this.providers)) {
2512
2256
  for (const provider of this.providers) {
2513
2257
  await provider.provide(context);
2514
2258
  }
2515
2259
  }
2516
- // Note: Search definition providers are different from search command providers
2517
- // Search command providers are handled separately in search.service.ts
2518
2260
  this.cache = context.getDefinitions();
2519
2261
  }
2520
2262
  async getListAsync() {
@@ -2562,7 +2304,6 @@ const AXP_SEARCH_PROVIDER = new InjectionToken('AXP_SEARCH_PROVIDER');
2562
2304
  class AXPSearchService {
2563
2305
  constructor() {
2564
2306
  this.providers = inject(AXP_SEARCH_PROVIDER, { optional: true });
2565
- this.providerRegistry = inject(AXPModuleProviderRegistry);
2566
2307
  this.definitionService = inject(AXPSearchDefinitionProviderService);
2567
2308
  this.formatService = inject(AXFormatService);
2568
2309
  }
@@ -2571,24 +2312,11 @@ class AXPSearchService {
2571
2312
  if (this.definitionService.getList().length == 0) {
2572
2313
  await this.definitionService.getListAsync();
2573
2314
  }
2574
- // Collect providers from both DI tokens and registry
2575
- const allProviders = [];
2576
- // Load from DI tokens (backward compatibility)
2577
- if (Array.isArray(this.providers)) {
2578
- allProviders.push(...this.providers);
2579
- }
2580
- else if (this.providers) {
2581
- allProviders.push(this.providers);
2582
- }
2583
- // Load from registry (manifest-based, conditionally loaded)
2584
- // Note: Registry stores AXPSearchCommandProvider which implements AXPSearchProvider
2585
- const registryProviders = this.providerRegistry.getSearchProviders();
2586
- allProviders.push(...registryProviders);
2587
- if (allProviders.length === 0) {
2588
- throw new Error('No search providers available');
2315
+ if (!this.providers || (this.providers?.length || 0) === 0) {
2316
+ throw new Error('No search providers available'); // No providers available
2589
2317
  }
2590
2318
  const mergeData = [];
2591
- const promises = allProviders.map((provider) => provider.search(text));
2319
+ const promises = this.providers.map((provider) => provider.search(text));
2592
2320
  const results = await Promise.all(promises);
2593
2321
  for (const resultArray of results) {
2594
2322
  for (const result of resultArray) {
@@ -2654,8 +2382,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
2654
2382
 
2655
2383
  var AXPCommonSettings;
2656
2384
  (function (AXPCommonSettings) {
2657
- AXPCommonSettings["EnableOperationToasts"] = "Common:Setting:Notifications.EnableOperationToasts";
2658
- AXPCommonSettings["EntityFilterApplyMode"] = "Common:Setting:Entity.FilterApplyMode";
2385
+ AXPCommonSettings["EnableOperationToasts"] = "general:notifications:enable-operation-toasts";
2386
+ AXPCommonSettings["EntityFilterApplyMode"] = "general:entity:filter-apply-mode";
2659
2387
  })(AXPCommonSettings || (AXPCommonSettings = {}));
2660
2388
 
2661
2389
  //TODO Loading, Redirect, Drawer, Show toast
@@ -2710,10 +2438,10 @@ class AXPToastAction extends AXPWorkflowAction {
2710
2438
  super(...arguments);
2711
2439
  this.toastService = inject(AXToastService);
2712
2440
  this.translationService = inject(AXTranslationService);
2713
- this.settingsService = inject(AXPSettingsService);
2441
+ this.settingService = inject(AXPSettingService);
2714
2442
  }
2715
2443
  async execute(context) {
2716
- const showResult = await this.settingsService.get(AXPCommonSettings.EnableOperationToasts);
2444
+ const showResult = await this.settingService.get(AXPCommonSettings.EnableOperationToasts);
2717
2445
  if (showResult) {
2718
2446
  this.toastService.show({
2719
2447
  color: this.color,
@@ -2849,13 +2577,10 @@ class AXPCommonModule {
2849
2577
  /**
2850
2578
  * @ignore
2851
2579
  */
2852
- constructor(instances, appInitService, settingsService, manifestInitializer, injector) {
2580
+ constructor(instances, appInitService, settingsService) {
2853
2581
  instances.forEach((f) => {
2854
2582
  f();
2855
2583
  });
2856
- appInitService.registerTask(manifestInitializer.createStartupTask());
2857
- const moduleProviderInitializer = injector.get(AXP_MODULE_PROVIDER_INITIALIZER);
2858
- appInitService.registerTask(moduleProviderInitializer.createRequiredModulesTask());
2859
2584
  appInitService.registerTask({
2860
2585
  name: 'Settings',
2861
2586
  statusText: 'Loading Settings ...',
@@ -2864,9 +2589,8 @@ class AXPCommonModule {
2864
2589
  await settingsService.load();
2865
2590
  },
2866
2591
  });
2867
- appInitService.registerTask(moduleProviderInitializer.createStartupTask());
2868
2592
  }
2869
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPCommonModule, deps: [{ token: 'AXPCommonModuleFactory' }, { token: i1.AXPAppStartUpService }, { token: AXPSettingsService }, { token: i1.AXPModuleManifestInitializer }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.NgModule }); }
2593
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPCommonModule, deps: [{ token: 'AXPCommonModuleFactory' }, { token: i1$1.AXPAppStartUpService }, { token: AXPSettingService }], target: i0.ɵɵFactoryTarget.NgModule }); }
2870
2594
  static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.12", ngImport: i0, type: AXPCommonModule, imports: [i3.AXPWorkflowModule, AXPopupModule,
2871
2595
  AXDateTimeModule,
2872
2596
  AXToastModule], exports: [RouterModule] }); }
@@ -2896,7 +2620,7 @@ class AXPCommonModule {
2896
2620
  },
2897
2621
  {
2898
2622
  provide: AXP_EXPRESSION_EVALUATOR_SCOPE_PROVIDER,
2899
- useClass: AXPTokenEvaluatorScopeProvider,
2623
+ useClass: AXPGlobalVariableEvaluatorScopeProvider,
2900
2624
  multi: true,
2901
2625
  },
2902
2626
  {
@@ -2969,7 +2693,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
2969
2693
  },
2970
2694
  {
2971
2695
  provide: AXP_EXPRESSION_EVALUATOR_SCOPE_PROVIDER,
2972
- useClass: AXPTokenEvaluatorScopeProvider,
2696
+ useClass: AXPGlobalVariableEvaluatorScopeProvider,
2973
2697
  multi: true,
2974
2698
  },
2975
2699
  {
@@ -2986,7 +2710,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
2986
2710
  }], ctorParameters: () => [{ type: undefined, decorators: [{
2987
2711
  type: Inject,
2988
2712
  args: ['AXPCommonModuleFactory']
2989
- }] }, { type: i1.AXPAppStartUpService }, { type: AXPSettingsService }, { type: i1.AXPModuleManifestInitializer }, { type: i0.Injector }] });
2713
+ }] }, { type: i1$1.AXPAppStartUpService }, { type: AXPSettingService }] });
2990
2714
 
2991
2715
  const ENVIRONMENT = new InjectionToken('ENVIRONMENT');
2992
2716
  const AXP_PLATFORM_CONFIG_TOKEN = new InjectionToken('AXP_PLATFORM_CONFIG_TOKEN', {
@@ -3058,510 +2782,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
3058
2782
  type: Injectable
3059
2783
  }] });
3060
2784
 
3061
- /**
3062
- * Status Definition Types
3063
- * Defines the structure for status definitions and their transitions
3064
- */
3065
- /**
3066
- * Abstract class for status providers
3067
- * Similar to AXPTaskBadgeProvider pattern
3068
- */
3069
- class AXPStatusProvider {
3070
- }
3071
- //#endregion
3072
-
3073
- //#region ---- Injection Token ----
3074
- /**
3075
- * Injection token for status providers
3076
- * Use with multi: true to register multiple providers
3077
- */
3078
- const AXP_STATUS_PROVIDERS = new InjectionToken('AXP_STATUS_PROVIDERS');
3079
- //#endregion
3080
- //#region ---- Provider Service ----
3081
- /**
3082
- * Service for managing status definitions from multiple providers
3083
- * Similar to AXPTaskBadgeService pattern - no cache, direct access
3084
- *
3085
- * @example
3086
- * ```typescript
3087
- * // In a module providers array:
3088
- * {
3089
- * provide: AXP_STATUS_PROVIDERS,
3090
- * useClass: TaskStatusProvider,
3091
- * multi: true,
3092
- * }
3093
- *
3094
- * // Example provider implementation:
3095
- * export class TaskStatusProvider extends AXPStatusProvider {
3096
- * readonly key = 'task-management.status';
3097
- * readonly statuses = [
3098
- * { name: 'todo', title: 'To Do', color: '#6b7280', icon: 'fa-light fa-circle', isInitial: true },
3099
- * { name: 'in-progress', title: 'In Progress', color: '#3b82f6', icon: 'fa-light fa-play' },
3100
- * { name: 'done', title: 'Done', color: '#10b981', icon: 'fa-light fa-check-circle', isFinal: true },
3101
- * ];
3102
- * readonly transitions = [
3103
- * { from: 'todo', to: 'in-progress', title: 'Start', condition: '{{user.canEdit}}' },
3104
- * { from: 'in-progress', to: 'done', title: 'Complete' },
3105
- * ];
3106
- * readonly defaultStatus = 'todo';
3107
- * }
3108
- *
3109
- * // Later, get the status:
3110
- * const status = statusService.getStatus('task-management.status');
3111
- * if (status) {
3112
- * console.log('Statuses:', status.statuses);
3113
- * console.log('Transitions:', status.transitions);
3114
- * }
3115
- * ```
3116
- */
3117
- class AXPStatusDefinitionProviderService {
3118
- //#endregion
3119
- //#region ---- Constructor ----
3120
- constructor() {
3121
- //#region ---- Dependencies ----
3122
- this.providers = inject(AXP_STATUS_PROVIDERS, { optional: true }) ?? [];
3123
- this.commandService = inject(AXPCommandService);
3124
- //#endregion
3125
- //#region ---- State ----
3126
- this.statusMap = new Map();
3127
- // Register all providers in constructor (like badge service)
3128
- for (const provider of this.providers) {
3129
- if (this.statusMap.has(provider.key)) {
3130
- console.warn(`Status with key "${provider.key}" already exists. Overwriting with new status.`);
3131
- }
3132
- this.statusMap.set(provider.key, provider);
3133
- }
3134
- }
3135
- //#endregion
3136
- //#region ---- Public API ----
3137
- /**
3138
- * Get a status provider by key
3139
- * Direct access from Map (no lazy load, no cache)
3140
- *
3141
- * @param key - Status key (e.g., 'task-management.status')
3142
- * @returns Status provider with all statuses and transitions, or undefined if not found
3143
- *
3144
- * @example
3145
- * ```typescript
3146
- * const status = statusService.getStatus('task-management.status');
3147
- * if (status) {
3148
- * console.log('Statuses:', status.statuses);
3149
- * console.log('Transitions:', status.transitions);
3150
- * }
3151
- * ```
3152
- */
3153
- getStatus(key) {
3154
- return this.statusMap.get(key);
3155
- }
3156
- /**
3157
- * Execute a status transition workflow action
3158
- * Uses transition.command if provided, otherwise defaults to Entity:UpdateStatus
3159
- * Validates the transition is allowed before executing
3160
- *
3161
- * @param definitionKey - Status definition key
3162
- * @param transition - The transition to execute
3163
- * @param context - Context data for the command (must include entity name and id/ids)
3164
- * @returns Promise that resolves when the command execution completes
3165
- *
3166
- * @example
3167
- * ```typescript
3168
- * await statusService.executeTransition(
3169
- * 'task-management.status',
3170
- * { from: 'todo', to: 'in-progress' },
3171
- * { entity: 'TaskManagement.Task', id: '123', ...entityData }
3172
- * );
3173
- * ```
3174
- */
3175
- async executeTransition(definitionKey, transition, context) {
3176
- const provider = this.getStatus(definitionKey);
3177
- if (!provider) {
3178
- throw new Error(`Status provider with key "${definitionKey}" not found.`);
3179
- }
3180
- // Validate transition is allowed
3181
- if (!this.isValidTransition(provider, transition.from, transition.to)) {
3182
- throw new Error(`Invalid transition from "${transition.from}" to "${transition.to}"`);
3183
- }
3184
- // Determine which command to use
3185
- let commandName;
3186
- let commandOptions;
3187
- if (transition.command) {
3188
- // Use transition's explicit command
3189
- commandName = transition.command.name;
3190
- commandOptions = {
3191
- ...(transition.command.options ?? {}),
3192
- ...context,
3193
- };
3194
- }
3195
- else {
3196
- // Use default Entity:UpdateStatus command
3197
- const entity = context['entityName'] ?? context['__meta__']?.config?.name;
3198
- if (!entity) {
3199
- throw new Error('Entity name is required in context when using default status update command');
3200
- }
3201
- const id = context['id'];
3202
- const ids = context['ids'];
3203
- if (!id && !ids) {
3204
- throw new Error('Either id or ids must be provided in context');
3205
- }
3206
- commandName = 'Entity:UpdateStatus';
3207
- commandOptions = {
3208
- entity,
3209
- status: transition.to,
3210
- statusField: context['statusField'] ?? 'statusId',
3211
- ...(id ? { id } : {}),
3212
- ...(ids ? { ids } : {}),
3213
- };
3214
- }
3215
- // Execute the command
3216
- const result = await this.commandService.execute(commandName, commandOptions);
3217
- if (!result?.success) {
3218
- throw new Error(result?.message?.text || 'Failed to execute status transition command');
3219
- }
3220
- }
3221
- /**
3222
- * Validate if a transition is allowed
3223
- * Checks if the transition exists in the provider's transitions list
3224
- */
3225
- isValidTransition(provider, from, to) {
3226
- return provider.transitions.some((transition) => transition.from === from && transition.to === to);
3227
- }
3228
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPStatusDefinitionProviderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
3229
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPStatusDefinitionProviderService, providedIn: 'root' }); }
3230
- }
3231
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPStatusDefinitionProviderService, decorators: [{
3232
- type: Injectable,
3233
- args: [{ providedIn: 'root' }]
3234
- }], ctorParameters: () => [] });
3235
-
3236
- /**
3237
- * Standard system status types
3238
- * These are the predefined status values used across the platform
3239
- */
3240
- var AXPSystemStatusType;
3241
- (function (AXPSystemStatusType) {
3242
- AXPSystemStatusType["Todo"] = "todo";
3243
- AXPSystemStatusType["InProgress"] = "in-progress";
3244
- AXPSystemStatusType["InReview"] = "in-review";
3245
- AXPSystemStatusType["Open"] = "open";
3246
- AXPSystemStatusType["Closed"] = "closed";
3247
- AXPSystemStatusType["Blocked"] = "blocked";
3248
- AXPSystemStatusType["Done"] = "done";
3249
- AXPSystemStatusType["Cancelled"] = "cancelled";
3250
- AXPSystemStatusType["Draft"] = "draft";
3251
- AXPSystemStatusType["PendingReview"] = "pending-review";
3252
- AXPSystemStatusType["Approved"] = "approved";
3253
- AXPSystemStatusType["Published"] = "published";
3254
- AXPSystemStatusType["Archived"] = "archived";
3255
- AXPSystemStatusType["Rejected"] = "rejected";
3256
- AXPSystemStatusType["Active"] = "active";
3257
- AXPSystemStatusType["Inactive"] = "inactive";
3258
- AXPSystemStatusType["Pending"] = "pending";
3259
- AXPSystemStatusType["Completed"] = "completed";
3260
- AXPSystemStatusType["Suspended"] = "suspended";
3261
- AXPSystemStatusType["Failed"] = "failed";
3262
- AXPSystemStatusType["Review"] = "review";
3263
- AXPSystemStatusType["Expired"] = "expired";
3264
- })(AXPSystemStatusType || (AXPSystemStatusType = {}));
3265
- const i18n = (key) => `@general:statuses.${key}`;
3266
- /**
3267
- * Standard system status definitions
3268
- * Provides consistent status definitions across the platform
3269
- * Uses AXPStatusDefinition interface from status-definition.types.ts
3270
- */
3271
- const AXPSystemStatuses = Object.freeze({
3272
- Open: {
3273
- name: AXPSystemStatusType.Open,
3274
- title: i18n('open.title'),
3275
- icon: 'fa-light fa-circle',
3276
- color: 'secondary',
3277
- description: i18n('open.description'),
3278
- order: 1,
3279
- isInitial: true,
3280
- isFinal: false,
3281
- },
3282
- Closed: {
3283
- name: AXPSystemStatusType.Closed,
3284
- title: i18n('closed.title'),
3285
- icon: 'fa-light fa-circle',
3286
- color: 'danger',
3287
- description: i18n('closed.description'),
3288
- order: 2,
3289
- isInitial: false,
3290
- isFinal: true,
3291
- },
3292
- Todo: {
3293
- name: AXPSystemStatusType.Todo,
3294
- title: i18n('todo.title'),
3295
- icon: 'fa-light fa-circle',
3296
- color: 'secondary',
3297
- description: i18n('todo.description'),
3298
- order: 1,
3299
- isInitial: true,
3300
- isFinal: false,
3301
- },
3302
- InProgress: {
3303
- name: AXPSystemStatusType.InProgress,
3304
- title: i18n('in-progress.title'),
3305
- icon: 'fa-light fa-play',
3306
- color: 'info',
3307
- description: i18n('in-progress.description'),
3308
- order: 2,
3309
- isInitial: false,
3310
- isFinal: false,
3311
- },
3312
- InReview: {
3313
- name: AXPSystemStatusType.InReview,
3314
- title: i18n('in-review.title'),
3315
- icon: 'fa-light fa-eye',
3316
- color: 'info',
3317
- description: i18n('in-review.description'),
3318
- order: 3,
3319
- isInitial: false,
3320
- isFinal: false,
3321
- },
3322
- Blocked: {
3323
- name: AXPSystemStatusType.Blocked,
3324
- title: i18n('blocked.title'),
3325
- icon: 'fa-light fa-ban',
3326
- color: 'danger',
3327
- description: i18n('blocked.description'),
3328
- order: 4,
3329
- isInitial: false,
3330
- isFinal: false,
3331
- },
3332
- Done: {
3333
- name: AXPSystemStatusType.Done,
3334
- title: i18n('done.title'),
3335
- icon: 'fa-light fa-check-circle',
3336
- color: 'success',
3337
- description: i18n('done.description'),
3338
- order: 5,
3339
- isInitial: false,
3340
- isFinal: true,
3341
- },
3342
- Cancelled: {
3343
- name: AXPSystemStatusType.Cancelled,
3344
- title: i18n('cancelled.title'),
3345
- icon: 'fa-light fa-times-circle',
3346
- color: 'neutral',
3347
- description: i18n('cancelled.description'),
3348
- order: 6,
3349
- isInitial: false,
3350
- isFinal: true,
3351
- },
3352
- Draft: {
3353
- name: AXPSystemStatusType.Draft,
3354
- title: i18n('draft.title'),
3355
- icon: 'fa-light fa-file-pen',
3356
- color: 'neutral',
3357
- description: i18n('draft.description'),
3358
- order: 1,
3359
- isInitial: true,
3360
- isFinal: false,
3361
- },
3362
- PendingReview: {
3363
- name: AXPSystemStatusType.PendingReview,
3364
- title: i18n('pending-review.title'),
3365
- icon: 'fa-light fa-clock',
3366
- color: 'warning',
3367
- description: i18n('pending-review.description'),
3368
- order: 2,
3369
- isInitial: false,
3370
- isFinal: false,
3371
- },
3372
- Approved: {
3373
- name: AXPSystemStatusType.Approved,
3374
- title: i18n('approved.title'),
3375
- icon: 'fa-light fa-check-circle',
3376
- color: 'success',
3377
- description: i18n('approved.description'),
3378
- order: 3,
3379
- isInitial: false,
3380
- isFinal: false,
3381
- },
3382
- Published: {
3383
- name: AXPSystemStatusType.Published,
3384
- title: i18n('published.title'),
3385
- icon: 'fa-light fa-globe',
3386
- color: 'primary',
3387
- description: i18n('published.description'),
3388
- order: 4,
3389
- isInitial: false,
3390
- isFinal: false,
3391
- },
3392
- Archived: {
3393
- name: AXPSystemStatusType.Archived,
3394
- title: i18n('archived.title'),
3395
- icon: 'fa-light fa-archive',
3396
- color: 'danger',
3397
- description: i18n('archived.description'),
3398
- order: 5,
3399
- isInitial: false,
3400
- isFinal: true,
3401
- },
3402
- Rejected: {
3403
- name: AXPSystemStatusType.Rejected,
3404
- title: i18n('rejected.title'),
3405
- icon: 'fa-light fa-times-circle',
3406
- color: 'danger',
3407
- description: i18n('rejected.description'),
3408
- order: 6,
3409
- isInitial: false,
3410
- isFinal: true,
3411
- },
3412
- Active: {
3413
- name: AXPSystemStatusType.Active,
3414
- title: i18n('active.title'),
3415
- icon: 'fa-light fa-check-circle',
3416
- color: 'success',
3417
- description: i18n('active.description'),
3418
- order: 1,
3419
- isInitial: false,
3420
- isFinal: false,
3421
- },
3422
- Inactive: {
3423
- name: AXPSystemStatusType.Inactive,
3424
- title: i18n('inactive.title'),
3425
- icon: 'fa-light fa-circle',
3426
- color: 'secondary',
3427
- description: i18n('inactive.description'),
3428
- order: 2,
3429
- isInitial: false,
3430
- isFinal: false,
3431
- },
3432
- Pending: {
3433
- name: AXPSystemStatusType.Pending,
3434
- title: i18n('pending.title'),
3435
- icon: 'fa-light fa-clock',
3436
- color: 'warning',
3437
- description: i18n('pending.description'),
3438
- order: 1,
3439
- isInitial: true,
3440
- isFinal: false,
3441
- },
3442
- Completed: {
3443
- name: AXPSystemStatusType.Completed,
3444
- title: i18n('completed.title'),
3445
- icon: 'fa-light fa-check-circle',
3446
- color: 'success',
3447
- description: i18n('completed.description'),
3448
- order: 10,
3449
- isInitial: false,
3450
- isFinal: true,
3451
- },
3452
- Suspended: {
3453
- name: AXPSystemStatusType.Suspended,
3454
- title: i18n('suspended.title'),
3455
- icon: 'fa-light fa-pause-circle',
3456
- color: 'neutral',
3457
- description: i18n('suspended.description'),
3458
- order: 5,
3459
- isInitial: false,
3460
- isFinal: false,
3461
- },
3462
- Failed: {
3463
- name: AXPSystemStatusType.Failed,
3464
- title: i18n('failed.title'),
3465
- icon: 'fa-light fa-xmark-circle',
3466
- color: 'danger',
3467
- description: i18n('failed.description'),
3468
- order: 10,
3469
- isInitial: false,
3470
- isFinal: true,
3471
- },
3472
- Review: {
3473
- name: AXPSystemStatusType.Review,
3474
- title: i18n('review.title'),
3475
- icon: 'fa-light fa-eye',
3476
- color: 'info',
3477
- description: i18n('review.description'),
3478
- order: 3,
3479
- },
3480
- Expired: {
3481
- name: AXPSystemStatusType.Expired,
3482
- title: i18n('expired.title'),
3483
- icon: 'fa-light fa-clock',
3484
- color: 'danger',
3485
- description: i18n('expired.description'),
3486
- order: 10,
3487
- isInitial: false,
3488
- isFinal: true,
3489
- },
3490
- });
3491
- /**
3492
- * Get system status definition by type
3493
- * @param type - Status type
3494
- * @returns System status definition or undefined
3495
- */
3496
- function getSystemStatus(type) {
3497
- return Object.values(AXPSystemStatuses).find(status => status.name === type);
3498
- }
3499
- /**
3500
- * Resolves the visual appearance (color and icon) for status
3501
- * using the system statuses from the core module.
3502
- * @param statusType - Status type string
3503
- * @returns Color and icon for the status
3504
- */
3505
- function resolveStatusLook(statusType) {
3506
- // Try to get system status first
3507
- const systemStatusType = statusType;
3508
- if (systemStatusType) {
3509
- const systemStatus = getSystemStatus(systemStatusType);
3510
- if (systemStatus) {
3511
- // Convert hex color to semantic color type if needed
3512
- // For now, return as-is and let the UI handle it
3513
- return {
3514
- color: systemStatus.color,
3515
- icon: systemStatus.icon || ''
3516
- };
3517
- }
3518
- }
3519
- // Fallback for unknown statuses
3520
- return {
3521
- color: 'secondary',
3522
- icon: ''
3523
- };
3524
- }
3525
- /**
3526
- * Resolves the complete status information (title, description, icon, color) for a status
3527
- * using the system statuses from the core module.
3528
- * @param statusType - Status type string
3529
- * @returns Complete status information as AXPStatusDefinition
3530
- */
3531
- function getStatusInfo(statusType) {
3532
- const systemStatusType = statusType;
3533
- if (systemStatusType) {
3534
- const systemStatus = getSystemStatus(systemStatusType);
3535
- if (systemStatus) {
3536
- return systemStatus;
3537
- }
3538
- }
3539
- // Fallback for unknown statuses
3540
- return {
3541
- name: statusType,
3542
- title: statusType,
3543
- description: `Status: ${statusType}`,
3544
- icon: '',
3545
- color: 'secondary'
3546
- };
3547
- }
3548
- /**
3549
- * Get system status definition directly (no conversion needed since it's already AXPStatusDefinition)
3550
- * @param statusType - Status type
3551
- * @param overrides - Optional overrides for the status definition
3552
- * @returns AXPStatusDefinition
3553
- */
3554
- function systemStatusToDefinition(statusType, overrides) {
3555
- const systemStatus = getSystemStatus(statusType);
3556
- if (!systemStatus) {
3557
- throw new Error(`System status ${statusType} not found`);
3558
- }
3559
- return {
3560
- ...systemStatus,
3561
- ...overrides,
3562
- };
3563
- }
3564
-
3565
2785
  class AXPClipBoardService {
3566
2786
  constructor() {
3567
2787
  this.toast = inject(AXToastService);
@@ -3585,123 +2805,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
3585
2805
  }]
3586
2806
  }] });
3587
2807
 
3588
- //#region ---- Imports ----
3589
- //#endregion
3590
- //#region ---- Debug Service ----
3591
- /**
3592
- * Service for debugging user access information.
3593
- * Displays loaded modules, features, and permissions for the current user.
3594
- */
3595
- class AXPDebugService {
3596
- constructor() {
3597
- //#region ---- Services & Dependencies ----
3598
- this.sessionService = inject(AXPSessionService);
3599
- this.manifestRegistry = inject(AXPModuleManifestRegistry);
3600
- }
3601
- //#endregion
3602
- //#region ---- Public Methods ----
3603
- /**
3604
- * Display all loaded modules, features, and permissions for the current user.
3605
- */
3606
- async displayUserAccessInfo() {
3607
- try {
3608
- // Ensure registry is initialized
3609
- await this.manifestRegistry.initialize();
3610
- // Get all registered modules
3611
- const allManifests = this.manifestRegistry.getAll();
3612
- // Get all feature definitions
3613
- const allFeatures = this.manifestRegistry.getAllFeatureDefinitions();
3614
- // Get current user permissions
3615
- const userPermissions = this.sessionService.permissions;
3616
- const user = this.sessionService.user;
3617
- console.group('🔐 User Access Information');
3618
- console.log(`User: ${user?.name || user?.title || 'Unknown'} (${user?.id || 'N/A'})`);
3619
- console.log('');
3620
- if (allManifests.length === 0) {
3621
- console.log('No modules loaded');
3622
- console.groupEnd();
3623
- return;
3624
- }
3625
- // Group features by module
3626
- const featuresByModule = new Map();
3627
- allFeatures.forEach((feature) => {
3628
- const moduleName = feature.module;
3629
- if (!featuresByModule.has(moduleName)) {
3630
- featuresByModule.set(moduleName, []);
3631
- }
3632
- featuresByModule.get(moduleName).push(feature);
3633
- });
3634
- // Group permissions by module (if they follow ModuleName:PermissionKey pattern)
3635
- const permissionsByModule = new Map();
3636
- const ungroupedPermissions = [];
3637
- userPermissions.forEach((permission) => {
3638
- const parts = permission.split(':');
3639
- if (parts.length >= 2) {
3640
- const moduleName = parts[0];
3641
- if (!permissionsByModule.has(moduleName)) {
3642
- permissionsByModule.set(moduleName, []);
3643
- }
3644
- permissionsByModule.get(moduleName).push(permission);
3645
- }
3646
- else {
3647
- ungroupedPermissions.push(permission);
3648
- }
3649
- });
3650
- // Display modules in tree format
3651
- allManifests.forEach((manifest) => {
3652
- const moduleName = manifest.name;
3653
- const moduleFeatures = featuresByModule.get(moduleName) || [];
3654
- const modulePermissions = permissionsByModule.get(moduleName) || [];
3655
- console.group(`📦 ${moduleName}`);
3656
- // Display Features
3657
- if (moduleFeatures.length > 0) {
3658
- console.log(' --- Features:');
3659
- moduleFeatures.forEach((feature) => {
3660
- console.log(` • ${feature.name}`);
3661
- });
3662
- }
3663
- else {
3664
- console.log(' --- Features: (none)');
3665
- }
3666
- // Display Permissions
3667
- if (modulePermissions.length > 0) {
3668
- console.log(' --- Permissions:');
3669
- modulePermissions.forEach((permission) => {
3670
- console.log(` • ${permission}`);
3671
- });
3672
- }
3673
- else {
3674
- console.log(' --- Permissions: (none)');
3675
- }
3676
- console.groupEnd();
3677
- });
3678
- // Display ungrouped permissions if any
3679
- if (ungroupedPermissions.length > 0) {
3680
- console.group('📁 Other Permissions');
3681
- ungroupedPermissions.forEach((permission) => {
3682
- console.log(` • ${permission}`);
3683
- });
3684
- console.groupEnd();
3685
- }
3686
- // Summary
3687
- console.log('');
3688
- console.log(`Summary: ${allManifests.length} modules, ${allFeatures.length} features, ${userPermissions.length} permissions`);
3689
- console.groupEnd();
3690
- }
3691
- catch (error) {
3692
- console.error('[AXPDebugService] Failed to display user access info:', error);
3693
- }
3694
- }
3695
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPDebugService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
3696
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPDebugService, providedIn: 'root' }); }
3697
- }
3698
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPDebugService, decorators: [{
3699
- type: Injectable,
3700
- args: [{
3701
- providedIn: 'root',
3702
- }]
3703
- }] });
3704
-
3705
2808
  class AXMOrgChartPrintPage extends AXBasePageComponent {
3706
2809
  constructor() {
3707
2810
  super(...arguments);
@@ -3800,7 +2903,7 @@ class AXMOrgChartPrintPage extends AXBasePageComponent {
3800
2903
  <ax-icon class="fa-solid fa-print"> </ax-icon>
3801
2904
  </ax-button>
3802
2905
  </ax-suffix>
3803
- </ax-footer>`, isInline: true, dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: AXCheckBoxModule }, { kind: "ngmodule", type: AXNumberBoxModule }, { kind: "component", type: i2.AXNumberBoxComponent, selector: "ax-number-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "value", "state", "name", "id", "look", "minValue", "maxValue", "showSpinButtons", "thousandsSeparator", "decimals", "changeOnScroll", "step"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange", "onKeyDown", "onKeyUp", "onKeyPress", "thousandsSeparatorChange"] }, { kind: "ngmodule", type: AXTextBoxModule }, { kind: "ngmodule", type: AXLabelModule }, { kind: "component", type: i3$1.AXLabelComponent, selector: "ax-label", inputs: ["required", "for"], outputs: ["requiredChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i4.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i4.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: AXButtonModule }, { kind: "component", type: i5.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXColorBoxModule }, { kind: "component", type: i6.AXColorBoxComponent, selector: "ax-color-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "value", "state", "name", "id", "look", "showBadge", "showValue", "showClearButton", "showIcon"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange", "onOpened", "onClosed"] }] }); }
2906
+ </ax-footer>`, isInline: true, dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: AXCheckBoxModule }, { kind: "ngmodule", type: AXNumberBoxModule }, { kind: "component", type: i2$1.AXNumberBoxComponent, selector: "ax-number-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "value", "state", "name", "id", "look", "minValue", "maxValue", "showSpinButtons", "thousandsSeparator", "decimals", "changeOnScroll", "step"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange", "onKeyDown", "onKeyUp", "onKeyPress", "thousandsSeparatorChange"] }, { kind: "ngmodule", type: AXTextBoxModule }, { kind: "ngmodule", type: AXLabelModule }, { kind: "component", type: i3$1.AXLabelComponent, selector: "ax-label", inputs: ["required", "for"], outputs: ["requiredChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i4.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i4.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: AXButtonModule }, { kind: "component", type: i5.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "ngmodule", type: AXColorBoxModule }, { kind: "component", type: i6.AXColorBoxComponent, selector: "ax-color-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "value", "state", "name", "id", "look", "showBadge", "showValue", "showClearButton", "showIcon"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange", "onOpened", "onClosed"] }] }); }
3804
2907
  }
3805
2908
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXMOrgChartPrintPage, decorators: [{
3806
2909
  type: Component,
@@ -3966,5 +3069,5 @@ class AXPVersioningService {
3966
3069
  * Generated bundle index. Do not edit.
3967
3070
  */
3968
3071
 
3969
- export { ALL_DEFAULT_OPERATORS, AXMWorkflowErrorHandler, AXPAppVersionService, AXPCleanNestedFilters, AXPClipBoardService, AXPCommonModule, AXPCommonSettings, AXPCustomOperatorService, AXPCustomOperatorServiceImpl, AXPDataProvider, AXPDebugService, AXPDialogConfirmAction, AXPEntityCommandScope, AXPEntityQueryType, AXPErrorHandlerRegistryService, AXPExportService, AXPFileStorageService, AXPFileStorageStatus, AXPFileTypeProviderService, AXPFilterOperatorMiddlewareService, AXPFilterOperatorMiddlewareServiceImpl, AXPFooterTextSlotComponent, AXPGlobalErrorHandler, AXPHomePageModule, AXPHomePageService, AXPLockService, AXPMenuMiddlewareRegistry, AXPMenuProviderService, AXPMenuSearchDefinitionProvider, AXPMenuSearchProvider, AXPMenuService, AXPMenuVisibilityService, AXPNavBarSlotComponent, AXPNavigateWorkflow, AXPPlatformDefaultConfigs, AXPRedirectEvent, AXPRefreshEvent, AXPRegionalSetting, AXPRelationshipCardinality, AXPRelationshipKind, AXPReloadAction, AXPReloadEvent, AXPSearchCommandProvider, AXPSearchDefinitionActionBuilder, AXPSearchDefinitionBuilder, AXPSearchDefinitionProviderContext, AXPSearchDefinitionProviderService, AXPSearchService, AXPSettingDefaultValuesAggregatorService, AXPSettingDefinitionGroupBuilder, AXPSettingDefinitionProviderContext, AXPSettingDefinitionProviderService, AXPSettingDefinitionSectionBuilder, AXPSettingsService, AXPStatusDefinitionProviderService, AXPStatusProvider, AXPStickyDirective, AXPSystemStatusType, AXPSystemStatuses, AXPToastAction, AXPTokenDefinitionService, AXPTokenEvaluatorScopeProvider, AXPVersioningService, AXPWorkflowNavigateAction, AXPWorkflowRouterNavigateAction, AXP_APP_VERSION_PROVIDER, AXP_FILE_TYPE_INFO_PROVIDER, AXP_HOME_PAGES, AXP_HOME_PAGE_DEFAULT_KEY, AXP_MENU_MIDDLEWARE, AXP_MENU_PROVIDER, AXP_PLATFORM_CONFIG_TOKEN, AXP_ROOT_CONFIG_TOKEN, AXP_SEARCH_DEFINITION_PROVIDER, AXP_SEARCH_PROVIDER, AXP_SETTING_DEFAULT_VALUES_PROVIDERS, AXP_SETTING_DEFINITION_PROVIDER, AXP_SETTING_VALUE_PROVIDER, AXP_STATUS_PROVIDERS, AXP_TOKEN_DEFINITION_PROVIDER, AXVChangeType, BETWEEN_OPER, BOOLEAN_OPERATORS, CONTAINS_OPER, DATE_OPERATORS, ENDS_WITH_OPER, ENVIRONMENT, EQ_OPER, GTE_OPER, GT_OPER, IN_OPER, IS_EMPTY_OPER, IS_NOT_EMPTY_OPER, LTE_OPER, LT_OPER, NOT_CONTAINS_OPER, NOT_EQ_OPER, NUMBER_OPERATORS, STARTS_WITH_OPER, STRING_OPERATORS, configPlatform, createAllQueryView, createMenuContext, createMenuMiddleware, createQueryView, getEntityInfo, getStatusInfo, getSystemStatus, provideDynamicHomePage, provideMenuMiddleware, resolveStatusLook, systemStatusToDefinition };
3072
+ export { ALL_DEFAULT_OPERATORS, AXMWorkflowErrorHandler, AXPAppVersionService, AXPCleanNestedFilters, AXPClipBoardService, AXPCommonModule, AXPCommonSettings, AXPCustomOperatorService, AXPCustomOperatorServiceImpl, AXPDataProvider, AXPDialogConfirmAction, AXPEntityCommandScope, AXPEntityQueryType, AXPErrorHandlerRegistryService, AXPExportService, AXPFileStorageService, AXPFileStorageStatus, AXPFileTypeProviderService, AXPFilterOperatorMiddlewareService, AXPFilterOperatorMiddlewareServiceImpl, AXPFooterTextSlotComponent, AXPGlobalErrorHandler, AXPGlobalVariableDefinitionService, AXPGlobalVariableEvaluatorScopeProvider, AXPHomePageModule, AXPHomePageService, AXPLockService, AXPLogoComponent, AXPMenuMiddlewareRegistry, AXPMenuProviderService, AXPMenuSearchDefinitionProvider, AXPMenuSearchProvider, AXPMenuService, AXPNavBarSlotComponent, AXPNavigateWorkflow, AXPPlatformDefaultConfigs, AXPRedirectEvent, AXPRefreshEvent, AXPRelationshipCardinality, AXPRelationshipKind, AXPReloadAction, AXPReloadEvent, AXPSearchCommandProvider, AXPSearchDefinitionActionBuilder, AXPSearchDefinitionBuilder, AXPSearchDefinitionProviderContext, AXPSearchDefinitionProviderService, AXPSearchService, AXPSettingDefaultValuesAggregatorService, AXPSettingDefinitionGroupBuilder, AXPSettingDefinitionProviderContext, AXPSettingDefinitionProviderService, AXPSettingDefinitionSectionBuilder, AXPSettingService, AXPStickyDirective, AXPToastAction, AXPVersioningService, AXPWorkflowNavigateAction, AXPWorkflowRouterNavigateAction, AXP_APP_VERSION_PROVIDER, AXP_FILE_TYPE_INFO_PROVIDER, AXP_GLOBAL_VARIABLE_DEFINITION_PROVIDER, AXP_HOME_PAGES, AXP_HOME_PAGE_DEFAULT_KEY, AXP_MENU_MIDDLEWARE, AXP_MENU_PROVIDER, AXP_PLATFORM_CONFIG_TOKEN, AXP_ROOT_CONFIG_TOKEN, AXP_SEARCH_DEFINITION_PROVIDER, AXP_SEARCH_PROVIDER, AXP_SETTING_DEFAULT_VALUES_PROVIDERS, AXP_SETTING_DEFINITION_PROVIDER, AXP_SETTING_VALUE_PROVIDER, AXVChangeType, BETWEEN_OPER, BOOLEAN_OPERATORS, CONTAINS_OPER, DATE_OPERATORS, ENDS_WITH_OPER, ENVIRONMENT, EQ_OPER, GTE_OPER, GT_OPER, IN_OPER, IS_EMPTY_OPER, IS_NOT_EMPTY_OPER, LTE_OPER, LT_OPER, NOT_CONTAINS_OPER, NOT_EQ_OPER, NUMBER_OPERATORS, STARTS_WITH_OPER, STRING_OPERATORS, configPlatform, createAllQueryView, createMenuContext, createMenuMiddleware, createQueryView, getEntityInfo, provideDynamicHomePage, provideMenuMiddleware };
3970
3073
  //# sourceMappingURL=acorex-platform-common.mjs.map