@masterteam/dashboard-builder 0.0.2 → 0.0.4

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.
@@ -703,7 +703,7 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
703
703
  /** Reference to chart settings drawer */
704
704
  private chartSettingsRef;
705
705
  readonly languageCode: _angular_core.Signal<string>;
706
- readonly direction: _angular_core.Signal<"rtl" | "ltr">;
706
+ readonly direction: _angular_core.Signal<"ltr" | "rtl">;
707
707
  readonly chartActionsContext: ChartActionsContext;
708
708
  readonly options: GridsterConfig;
709
709
  private subscription;
@@ -786,10 +786,10 @@ declare class DashboardBuilder implements OnInit, OnDestroy {
786
786
  * Dashboard Viewer Component
787
787
  *
788
788
  * A read-only component for viewing and displaying dashboard layouts.
789
- * Similar to pageBuilder-gridster but without editing capabilities.
789
+ * Uses a CSS Grid preview layout without editing capabilities.
790
790
  *
791
791
  * Features:
792
- * - Gridster-based layout display (read-only)
792
+ * - CSS Grid-based layout display
793
793
  * - Chart/widget rendering
794
794
  * - Group support with tab switching
795
795
  * - Filter sidebar integration
@@ -807,6 +807,8 @@ declare class DashboardViewer implements OnInit, OnDestroy {
807
807
  readonly backButton: _angular_core.InputSignal<boolean>;
808
808
  /** Dashboard/Page ID to load */
809
809
  readonly pageId: _angular_core.InputSignal<string | number | null>;
810
+ /** Unified dashboard payload for local/preview rendering */
811
+ readonly dashboardData: _angular_core.InputSignal<DashboardBuilderData | null>;
810
812
  /** Pre-loaded charts (optional - if provided, skips API call) */
811
813
  readonly chartsData: _angular_core.InputSignal<DashboardChartItem[]>;
812
814
  /** Pre-loaded dialogs (optional) */
@@ -824,24 +826,30 @@ declare class DashboardViewer implements OnInit, OnDestroy {
824
826
  chart: DashboardChartItem;
825
827
  event: Event;
826
828
  }>;
827
- readonly gridsterContainer: _angular_core.Signal<any>;
828
829
  readonly loading: _angular_core.WritableSignal<boolean>;
829
830
  readonly pageConfig: _angular_core.WritableSignal<_masterteam_dashboard_builder.Report | null>;
830
831
  readonly charts: _angular_core.WritableSignal<DashboardChartItem[]>;
831
832
  readonly dialogs: _angular_core.WritableSignal<DashboardDialogItem[]>;
832
833
  readonly filters: _angular_core.WritableSignal<any[]>;
833
834
  readonly languageCode: _angular_core.Signal<string>;
834
- readonly direction: _angular_core.Signal<"rtl" | "ltr">;
835
- readonly options: GridsterConfig;
835
+ readonly direction: _angular_core.Signal<"ltr" | "rtl">;
836
+ readonly hasRenderableContent: _angular_core.Signal<boolean>;
837
+ readonly visibleItems: _angular_core.Signal<DashboardChartItem[]>;
838
+ readonly layoutHeight: _angular_core.Signal<string>;
836
839
  private subscription;
840
+ private readonly rowHeight;
841
+ private readonly hasSplitPreloadedData;
842
+ private dashboardDataEffect;
837
843
  private chartsDataEffect;
838
844
  private dialogsDataEffect;
839
845
  private filtersDataEffect;
846
+ private preloadedInputsEffect;
847
+ private pageIdEffect;
840
848
  ngOnInit(): void;
841
849
  ngOnDestroy(): void;
842
850
  private setupSubscriptions;
843
- private loadPageIfNeeded;
844
851
  loadPage(id: string | number): void;
852
+ private applyDashboardData;
845
853
  reloadPage(): void;
846
854
  /**
847
855
  * Get the title for a group item
@@ -891,6 +899,14 @@ declare class DashboardViewer implements OnInit, OnDestroy {
891
899
  * Get chart type
892
900
  */
893
901
  getChartType(item: DashboardChartItem): string;
902
+ /**
903
+ * Get CSS grid column range for an item
904
+ */
905
+ getGridColumn(item: DashboardChartItem): string;
906
+ /**
907
+ * Get CSS grid row range for an item
908
+ */
909
+ getGridRow(item: DashboardChartItem): string;
894
910
  /**
895
911
  * Handle chart click
896
912
  */
@@ -900,7 +916,7 @@ declare class DashboardViewer implements OnInit, OnDestroy {
900
916
  */
901
917
  trackByDashboardId(_index: number, item: DashboardChartItem): string;
902
918
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<DashboardViewer, never>;
903
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<DashboardViewer, "mt-dashboard-viewer", never, { "isPage": { "alias": "isPage"; "required": false; "isSignal": true; }; "pageTitle": { "alias": "pageTitle"; "required": false; "isSignal": true; }; "backButton": { "alias": "backButton"; "required": false; "isSignal": true; }; "pageId": { "alias": "pageId"; "required": false; "isSignal": true; }; "chartsData": { "alias": "chartsData"; "required": false; "isSignal": true; }; "dialogsData": { "alias": "dialogsData"; "required": false; "isSignal": true; }; "filtersData": { "alias": "filtersData"; "required": false; "isSignal": true; }; "showFilters": { "alias": "showFilters"; "required": false; "isSignal": true; }; }, { "pageLoaded": "pageLoaded"; "onBack": "onBack"; "chartClick": "chartClick"; }, never, never, true, never>;
919
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DashboardViewer, "mt-dashboard-viewer", never, { "isPage": { "alias": "isPage"; "required": false; "isSignal": true; }; "pageTitle": { "alias": "pageTitle"; "required": false; "isSignal": true; }; "backButton": { "alias": "backButton"; "required": false; "isSignal": true; }; "pageId": { "alias": "pageId"; "required": false; "isSignal": true; }; "dashboardData": { "alias": "dashboardData"; "required": false; "isSignal": true; }; "chartsData": { "alias": "chartsData"; "required": false; "isSignal": true; }; "dialogsData": { "alias": "dialogsData"; "required": false; "isSignal": true; }; "filtersData": { "alias": "filtersData"; "required": false; "isSignal": true; }; "showFilters": { "alias": "showFilters"; "required": false; "isSignal": true; }; }, { "pageLoaded": "pageLoaded"; "onBack": "onBack"; "chartClick": "chartClick"; }, never, never, true, never>;
904
920
  }
905
921
 
906
922
  /**
@@ -1153,8 +1169,31 @@ interface FilterConfig {
1153
1169
  * Filter option
1154
1170
  */
1155
1171
  interface FilterOption {
1156
- label: string;
1172
+ key?: string;
1173
+ label: string | Record<string, string>;
1174
+ value: any;
1175
+ icon?: string;
1176
+ color?: string;
1177
+ }
1178
+ /**
1179
+ * Static filter configuration for button-group style filtering
1180
+ */
1181
+ interface StaticFilterConfig {
1182
+ show: boolean;
1183
+ filters: StaticFilterItem[];
1184
+ defaultIndex?: number;
1185
+ style?: 'buttons' | 'pills' | 'tabs';
1186
+ }
1187
+ /**
1188
+ * Static filter item
1189
+ */
1190
+ interface StaticFilterItem {
1191
+ key: string;
1157
1192
  value: any;
1193
+ label: {
1194
+ en: string;
1195
+ ar: string;
1196
+ };
1158
1197
  icon?: string;
1159
1198
  color?: string;
1160
1199
  }
@@ -1257,6 +1296,9 @@ interface HeaderCardConfig$1 {
1257
1296
  showHeader?: boolean;
1258
1297
  isHeaderHidden?: boolean;
1259
1298
  headerClickable?: boolean;
1299
+ isHeaderCentered?: boolean;
1300
+ headerFontSize?: number;
1301
+ headerColor?: string;
1260
1302
  icon?: string;
1261
1303
  iconColor?: string;
1262
1304
  titleColor?: string;
@@ -1274,6 +1316,10 @@ interface CardBorderStyleConfig {
1274
1316
  'background-color'?: string;
1275
1317
  'box-shadow'?: string;
1276
1318
  'border-radius'?: number;
1319
+ color?: string;
1320
+ 'font-size'?: string;
1321
+ iconColor?: string;
1322
+ iconBgColor?: string;
1277
1323
  }
1278
1324
  interface CardStyleConfig$1 {
1279
1325
  backgroundColor?: string;
@@ -1298,9 +1344,9 @@ declare class CardContentComponent {
1298
1344
  /** Card style configuration (background, shadows, border radius) */
1299
1345
  readonly cardStyleConfig: _angular_core.InputSignal<CardStyleConfig$1 | null>;
1300
1346
  /** Whether to show header */
1301
- readonly showHeaderInput: _angular_core.InputSignal<boolean>;
1347
+ readonly showHeader: _angular_core.InputSignal<boolean>;
1302
1348
  /** Whether header is clickable */
1303
- readonly headerClickableInput: _angular_core.InputSignal<boolean>;
1349
+ readonly headerClickable: _angular_core.InputSignal<boolean>;
1304
1350
  /** No top end content flag */
1305
1351
  readonly isNoTopEnd: _angular_core.InputSignal<boolean>;
1306
1352
  /** Whether this card contains a chart (disables horizontal scroll) */
@@ -1308,16 +1354,18 @@ declare class CardContentComponent {
1308
1354
  /** Header click event */
1309
1355
  readonly headerClick: _angular_core.OutputEmitterRef<void>;
1310
1356
  /** Computed show header */
1311
- readonly showHeader: _angular_core.Signal<boolean>;
1357
+ readonly showHeaderState: _angular_core.Signal<boolean>;
1312
1358
  /** Computed header clickable */
1313
- readonly headerClickable: _angular_core.Signal<boolean>;
1359
+ readonly headerClickableState: _angular_core.Signal<boolean>;
1360
+ /** Computed header row styles from StyleConfig (color, font-size passed through) */
1361
+ readonly headerRowStyles: _angular_core.Signal<Record<string, string> | null>;
1314
1362
  /** Computed card styles from StyleConfig and cardStyleConfig */
1315
1363
  readonly cardStyles: _angular_core.Signal<Record<string, string>>;
1316
1364
  /** Computed border radius style */
1317
1365
  readonly borderRadiusStyle: _angular_core.Signal<string>;
1318
1366
  onHeaderClick(): void;
1319
1367
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<CardContentComponent, never>;
1320
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<CardContentComponent, "db-card-content", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "headerConfig": { "alias": "headerConfig"; "required": false; "isSignal": true; }; "styleConfig": { "alias": "styleConfig"; "required": false; "isSignal": true; }; "cardStyleConfig": { "alias": "cardStyleConfig"; "required": false; "isSignal": true; }; "showHeaderInput": { "alias": "showHeader"; "required": false; "isSignal": true; }; "headerClickableInput": { "alias": "headerClickable"; "required": false; "isSignal": true; }; "isNoTopEnd": { "alias": "isNoTopEnd"; "required": false; "isSignal": true; }; "isChart": { "alias": "isChart"; "required": false; "isSignal": true; }; }, { "headerClick": "headerClick"; }, never, ["[topEnd]", "[body]", "[footer]"], true, never>;
1368
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<CardContentComponent, "mt-card-content", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "headerConfig": { "alias": "headerConfig"; "required": false; "isSignal": true; }; "styleConfig": { "alias": "styleConfig"; "required": false; "isSignal": true; }; "cardStyleConfig": { "alias": "cardStyleConfig"; "required": false; "isSignal": true; }; "showHeader": { "alias": "showHeader"; "required": false; "isSignal": true; }; "headerClickable": { "alias": "headerClickable"; "required": false; "isSignal": true; }; "isNoTopEnd": { "alias": "isNoTopEnd"; "required": false; "isSignal": true; }; "isChart": { "alias": "isChart"; "required": false; "isSignal": true; }; }, { "headerClick": "headerClick"; }, never, ["[topEnd]", "[body]", "[footer]"], true, never>;
1321
1369
  }
1322
1370
 
1323
1371
  declare class CardFilterComponent implements OnInit {
@@ -1339,9 +1387,9 @@ declare class CardFilterComponent implements OnInit {
1339
1387
  /** Language code */
1340
1388
  readonly langCode: _angular_core.Signal<string>;
1341
1389
  /** Filter type */
1342
- readonly filterType: _angular_core.Signal<"select" | "date" | "text" | "multiselect" | "multiSelect" | "daterange">;
1390
+ readonly filterType: _angular_core.Signal<"date" | "text" | "select" | "multiselect" | "multiSelect" | "daterange">;
1343
1391
  /** Filter options */
1344
- readonly options: _angular_core.Signal<FilterOption[]>;
1392
+ readonly options: _angular_core.Signal<_masterteam_dashboard_builder.FilterOption[]>;
1345
1393
  /** Placeholder text */
1346
1394
  readonly placeholder: _angular_core.Signal<string>;
1347
1395
  ngOnInit(): void;
@@ -1349,7 +1397,207 @@ declare class CardFilterComponent implements OnInit {
1349
1397
  onMultiFilterChange(values: any[]): void;
1350
1398
  onDateChange(): void;
1351
1399
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<CardFilterComponent, never>;
1352
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<CardFilterComponent, "db-card-filter", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
1400
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<CardFilterComponent, "mt-card-filter", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
1401
+ }
1402
+
1403
+ declare class StaticFiltersComponent implements OnInit {
1404
+ private readonly storeService;
1405
+ private readonly transloco;
1406
+ /** Static filter configuration */
1407
+ readonly config: _angular_core.InputSignal<StaticFilterConfig | null>;
1408
+ /** Dashboard ID for store updates */
1409
+ readonly dashboardId: _angular_core.InputSignal<string | number | undefined>;
1410
+ /** Filter change event */
1411
+ readonly filterChange: _angular_core.OutputEmitterRef<{
1412
+ key: string;
1413
+ value: any;
1414
+ }>;
1415
+ /** Currently active filter index */
1416
+ readonly activeIndex: _angular_core.WritableSignal<number>;
1417
+ /** Language code */
1418
+ readonly langCode: _angular_core.Signal<string>;
1419
+ /** Filter items */
1420
+ readonly filters: _angular_core.Signal<StaticFilterItem[]>;
1421
+ /**
1422
+ * Get localized label for filter
1423
+ */
1424
+ getLabel(filter: StaticFilterItem): string;
1425
+ /**
1426
+ * Handle filter button click
1427
+ */
1428
+ onFilterClick(filter: StaticFilterItem, index: number): void;
1429
+ /**
1430
+ * Initialize with default filter if configured
1431
+ */
1432
+ ngOnInit(): void;
1433
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<StaticFiltersComponent, never>;
1434
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<StaticFiltersComponent, "mt-static-filters", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
1435
+ }
1436
+
1437
+ /**
1438
+ * Filter Field Models
1439
+ *
1440
+ * Defines the structure for dynamic filter fields configuration
1441
+ * used in dashboard page filtering.
1442
+ */
1443
+ /** Localized text with English and Arabic translations */
1444
+ interface LocalizedText {
1445
+ en: string;
1446
+ ar: string;
1447
+ }
1448
+ /** Filter field types supported by the system */
1449
+ type FilterFieldType = 'dropdownTVService' | 'lookup' | 'status' | 'phaseGate' | 'user' | 'date' | 'section' | 'separator' | 'year' | 'month' | 'quarter' | 'checkbox' | 'schemaSettings' | 'schemaSettingsLeafs';
1450
+ /** Selection item for dropdown configuration */
1451
+ interface FilterSelectionItem {
1452
+ id: number;
1453
+ moduleType?: string;
1454
+ moduleId?: number;
1455
+ filters?: any[];
1456
+ modules?: any[];
1457
+ properties?: any[];
1458
+ }
1459
+ /** Filter field configuration details */
1460
+ interface FilterFieldConfiguration {
1461
+ payload?: {
1462
+ dashboardId: number;
1463
+ selection: FilterSelectionItem[];
1464
+ chartType: string;
1465
+ query: {
1466
+ selectedProperties: string[];
1467
+ };
1468
+ };
1469
+ lookupId?: number;
1470
+ schemaLevelId?: number;
1471
+ logId?: number;
1472
+ isRequird?: boolean;
1473
+ isMultiple?: boolean;
1474
+ checked?: boolean;
1475
+ minYear?: number;
1476
+ maxYear?: number;
1477
+ }
1478
+ /** Filter field definition */
1479
+ interface FilterField {
1480
+ key?: string;
1481
+ name?: LocalizedText;
1482
+ type: FilterFieldType;
1483
+ configuration?: FilterFieldConfiguration;
1484
+ }
1485
+ /** Filter field type option for dropdown */
1486
+ interface FilterFieldTypeOption {
1487
+ value: FilterFieldType;
1488
+ label: string;
1489
+ products: string[];
1490
+ }
1491
+ /**
1492
+ * Dynamic Filter Field
1493
+ *
1494
+ * An extended filter definition with options and loading state
1495
+ * for chart-level dynamic filtering.
1496
+ */
1497
+ interface DynamicFilterField extends FilterField {
1498
+ /** Options loaded from API */
1499
+ options?: DynamicFilterOption[];
1500
+ /** Loading state for async options */
1501
+ loading?: boolean;
1502
+ /** Currently selected value(s) */
1503
+ selectedValue?: any;
1504
+ }
1505
+ /**
1506
+ * Dynamic Filter Option
1507
+ *
1508
+ * A single option in a dynamic filter dropdown.
1509
+ */
1510
+ interface DynamicFilterOption {
1511
+ id: number | string;
1512
+ name: string | LocalizedText;
1513
+ value?: any;
1514
+ color?: string;
1515
+ icon?: string;
1516
+ }
1517
+
1518
+ declare class DynamicFiltersComponent implements OnInit {
1519
+ private readonly storeService;
1520
+ private readonly transloco;
1521
+ /** Dynamic filter fields configuration */
1522
+ readonly fields: _angular_core.InputSignal<DynamicFilterField[]>;
1523
+ /** Dashboard ID for store updates */
1524
+ readonly dashboardId: _angular_core.InputSignal<string | number | undefined>;
1525
+ /** Whether to show labels above filters */
1526
+ readonly showLabels: _angular_core.InputSignal<boolean>;
1527
+ /** Filter change event */
1528
+ readonly filterChange: _angular_core.OutputEmitterRef<{
1529
+ key: string;
1530
+ value: any;
1531
+ }>;
1532
+ /** All filters change event - emitted with all current values */
1533
+ readonly filtersChange: _angular_core.OutputEmitterRef<Record<string, any>>;
1534
+ /** Current filter values */
1535
+ private currentValues;
1536
+ /** Language code */
1537
+ readonly langCode: _angular_core.Signal<string>;
1538
+ /** Month options */
1539
+ readonly months: {
1540
+ value: number;
1541
+ labelEn: string;
1542
+ labelAr: string;
1543
+ }[];
1544
+ /** Quarter options */
1545
+ readonly quarters: {
1546
+ value: number;
1547
+ labelEn: string;
1548
+ labelAr: string;
1549
+ }[];
1550
+ ngOnInit(): void;
1551
+ /**
1552
+ * Get localized field label
1553
+ */
1554
+ getFieldLabel(field: DynamicFilterField): string;
1555
+ /**
1556
+ * Get localized option label
1557
+ */
1558
+ getOptionLabel(option: any): string;
1559
+ /**
1560
+ * Get selected value for a field
1561
+ */
1562
+ getSelectedValue(field: DynamicFilterField): any;
1563
+ /**
1564
+ * Get year options based on configuration
1565
+ */
1566
+ getYearOptions(field: DynamicFilterField): number[];
1567
+ /**
1568
+ * Handle field value change
1569
+ */
1570
+ onFieldChange(field: DynamicFilterField, value: any): void;
1571
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DynamicFiltersComponent, never>;
1572
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DynamicFiltersComponent, "mt-dynamic-filters", never, { "fields": { "alias": "fields"; "required": false; "isSignal": true; }; "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; "showLabels": { "alias": "showLabels"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; "filtersChange": "filtersChange"; }, never, never, true, never>;
1573
+ }
1574
+
1575
+ interface CardInfoConfig$1 {
1576
+ show?: boolean;
1577
+ type?: 'text' | 'html';
1578
+ value?: string | {
1579
+ html?: string;
1580
+ keys?: Array<{
1581
+ key: string;
1582
+ en?: string;
1583
+ ar?: string;
1584
+ }>;
1585
+ };
1586
+ }
1587
+ declare class CardInfoComponent {
1588
+ private readonly transloco;
1589
+ readonly cardInfo: _angular_core.InputSignal<CardInfoConfig$1 | null>;
1590
+ readonly showInfo: _angular_core.Signal<string | false | {
1591
+ html?: string;
1592
+ keys?: Array<{
1593
+ key: string;
1594
+ en?: string;
1595
+ ar?: string;
1596
+ }>;
1597
+ } | undefined>;
1598
+ readonly tooltipContent: _angular_core.Signal<string>;
1599
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<CardInfoComponent, never>;
1600
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<CardInfoComponent, "mt-card-info", never, { "cardInfo": { "alias": "cardInfo"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
1353
1601
  }
1354
1602
 
1355
1603
  declare class ChartCardComponent implements OnInit, OnDestroy {
@@ -1376,19 +1624,29 @@ declare class ChartCardComponent implements OnInit, OnDestroy {
1376
1624
  readonly title: _angular_core.Signal<string>;
1377
1625
  /** Show filter flag */
1378
1626
  readonly showFilter: _angular_core.Signal<any>;
1379
- /** Show top end section (filter or extra filters) */
1627
+ /** Show top end section (filter or extra filters or cardInfo or static/dynamic filters) */
1380
1628
  readonly showTopEnd: _angular_core.Signal<any>;
1629
+ /** Card info configuration */
1630
+ readonly cardInfoConfig: _angular_core.Signal<any>;
1381
1631
  /** Filter configuration */
1382
1632
  readonly filterConfig: _angular_core.Signal<{
1383
1633
  [key: string]: any;
1384
1634
  configs?: any[];
1385
1635
  } | undefined>;
1636
+ /** Static filter configuration */
1637
+ readonly staticFilterConfig: _angular_core.Signal<StaticFilterConfig | null>;
1638
+ /** Dynamic filter fields */
1639
+ readonly dynamicFilterFields: _angular_core.Signal<DynamicFilterField[]>;
1640
+ /** Show static filters */
1641
+ readonly showStaticFilters: _angular_core.Signal<boolean | undefined>;
1642
+ /** Show dynamic filters */
1643
+ readonly showDynamicFilters: _angular_core.Signal<boolean>;
1386
1644
  ngOnInit(): void;
1387
1645
  ngOnDestroy(): void;
1388
1646
  onChartClick(event: any): void;
1389
1647
  onHeaderClick(): void;
1390
1648
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<ChartCardComponent, never>;
1391
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChartCardComponent, "db-chart-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "isConfigMode": { "alias": "isConfigMode"; "required": false; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
1649
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChartCardComponent, "mt-chart-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "isConfigMode": { "alias": "isConfigMode"; "required": false; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
1392
1650
  }
1393
1651
 
1394
1652
  type EChartsType = any;
@@ -1490,7 +1748,7 @@ declare class EChartComponent implements OnInit, AfterViewInit, OnChanges, OnDes
1490
1748
  */
1491
1749
  getChartInstance(): EChartsType | null;
1492
1750
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<EChartComponent, never>;
1493
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<EChartComponent, "db-echart", never, { "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; "chartConfig": { "alias": "chartConfig"; "required": false; "isSignal": true; }; "configurationItem": { "alias": "configurationItem"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "headerHidden": { "alias": "headerHidden"; "required": false; "isSignal": true; }; }, { "chartClick": "chartClick"; }, never, never, true, never>;
1751
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<EChartComponent, "mt-echart", never, { "dashboardId": { "alias": "dashboardId"; "required": false; "isSignal": true; }; "chartConfig": { "alias": "chartConfig"; "required": false; "isSignal": true; }; "configurationItem": { "alias": "configurationItem"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; "headerHidden": { "alias": "headerHidden"; "required": false; "isSignal": true; }; }, { "chartClick": "chartClick"; }, never, never, true, never>;
1494
1752
  }
1495
1753
 
1496
1754
  interface EntityData {
@@ -1591,7 +1849,11 @@ declare class EntityPreviewCardComponent implements OnInit, OnDestroy {
1591
1849
  interface StatusItem {
1592
1850
  label: string;
1593
1851
  color: string;
1594
- shape?: 'circle' | 'square';
1852
+ shape?: 'circle' | 'square' | 'rectangul' | 'rhombic' | 'rect';
1853
+ borderColor?: string;
1854
+ borderBottomColor?: string;
1855
+ iconClass?: string;
1856
+ iconSize?: number;
1595
1857
  }
1596
1858
  declare class HeaderCardComponent implements OnInit, OnDestroy {
1597
1859
  private readonly storeService;
@@ -1649,7 +1911,7 @@ declare class HeaderCardComponent implements OnInit, OnDestroy {
1649
1911
  onArrowClick(): void;
1650
1912
  onClick(): void;
1651
1913
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<HeaderCardComponent, never>;
1652
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<HeaderCardComponent, "db-header-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
1914
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<HeaderCardComponent, "mt-header-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
1653
1915
  }
1654
1916
 
1655
1917
  interface LevelCardData$1 {
@@ -1747,7 +2009,7 @@ declare class ListStatisticCardComponent implements OnInit, OnDestroy {
1747
2009
  */
1748
2010
  doActions(event: any, type: string): void;
1749
2011
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<ListStatisticCardComponent, never>;
1750
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<ListStatisticCardComponent, "db-list-statistic-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
2012
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<ListStatisticCardComponent, "mt-list-statistic-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
1751
2013
  }
1752
2014
 
1753
2015
  interface SkeletonConfig {
@@ -1767,7 +2029,7 @@ declare class SkeletonCardComponent implements OnInit, OnDestroy {
1767
2029
  ngOnDestroy(): void;
1768
2030
  private getSkeletonsForComponent;
1769
2031
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<SkeletonCardComponent, never>;
1770
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<SkeletonCardComponent, "db-skeleton-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
2032
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<SkeletonCardComponent, "mt-skeleton-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
1771
2033
  }
1772
2034
 
1773
2035
  declare class StatisticCardComponent implements OnInit {
@@ -1918,7 +2180,7 @@ declare class TableCardComponent implements OnInit, OnDestroy {
1918
2180
  */
1919
2181
  onHeaderClick(): void;
1920
2182
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<TableCardComponent, never>;
1921
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<TableCardComponent, "db-table-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
2183
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<TableCardComponent, "mt-table-card", never, { "dashboardId": { "alias": "dashboardId"; "required": true; "isSignal": true; }; "inGroup": { "alias": "inGroup"; "required": false; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
1922
2184
  }
1923
2185
 
1924
2186
  declare class DashboardItemStoreService {
@@ -2130,15 +2392,16 @@ declare class ChartDataService {
2130
2392
  }
2131
2393
 
2132
2394
  declare class BarChartHandler {
2395
+ private readonly storeService;
2133
2396
  /**
2134
2397
  * handleBarChart - matches functionName from CHART_TYPES
2135
2398
  * Returns ECharts option directly (exactly like old BarChartService.handleBarChart)
2136
2399
  */
2137
2400
  handleBarChart(dataResponse: any, config: ItemConfig): any;
2138
2401
  /**
2139
- * Format X axis value
2402
+ * Format X axis value using the formatXAxis utility
2140
2403
  */
2141
- private formatXAxis;
2404
+ private formatXAxisValue;
2142
2405
  /**
2143
2406
  * Apply bar override configurations
2144
2407
  */
@@ -2147,6 +2410,11 @@ declare class BarChartHandler {
2147
2410
  * Build grouped bar chart
2148
2411
  */
2149
2412
  private buildGroupedBarChart;
2413
+ /**
2414
+ * handleEntityPreviewWithFormula - matches old entityPreviewWithFormula component
2415
+ * Transforms bar chart data into entity preview format (flat array of properties)
2416
+ */
2417
+ handleEntityPreviewWithFormula(dataResponse: any, config: ItemConfig): any;
2150
2418
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<BarChartHandler, never>;
2151
2419
  static ɵprov: _angular_core.ɵɵInjectableDeclaration<BarChartHandler>;
2152
2420
  }
@@ -2170,6 +2438,7 @@ declare class PieChartHandler {
2170
2438
  }
2171
2439
 
2172
2440
  declare class StackBarChartHandler {
2441
+ private readonly storeService;
2173
2442
  /**
2174
2443
  * Helper method to convert legend position based on language
2175
2444
  */
@@ -2244,7 +2513,7 @@ declare class OverviewCardHandler {
2244
2513
  * handleHeader - for header component
2245
2514
  * Extracts title from first value (same as old PropertiesService.handleHeader)
2246
2515
  */
2247
- handleHeader(data: any, config: ItemConfig): any;
2516
+ handleHeader(data: any, _config: ItemConfig): any;
2248
2517
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<OverviewCardHandler, never>;
2249
2518
  static ɵprov: _angular_core.ɵɵInjectableDeclaration<OverviewCardHandler>;
2250
2519
  }
@@ -2412,18 +2681,18 @@ declare class LevelCardHandler {
2412
2681
  * Returns data directly like old LevelCardService:
2413
2682
  * result?.map(data => data?.details?.map(...).sort(...))
2414
2683
  */
2415
- handlelevelCards(result: any, config: ItemConfig): any;
2684
+ handlelevelCards(result: any, _config: ItemConfig): any;
2416
2685
  /**
2417
2686
  * handlelevelCardsWithFilter - matches functionName from CHART_TYPES
2418
2687
  * Returns data directly like old LevelCardService:
2419
2688
  * [[{ data: levelProps }]]
2420
2689
  */
2421
- handlelevelCardsWithFilter(result: any, config: ItemConfig): any;
2690
+ handlelevelCardsWithFilter(result: any, _config: ItemConfig): any;
2422
2691
  /**
2423
2692
  * Handle grouped level cards (multiple selections)
2424
2693
  * Returns data directly
2425
2694
  */
2426
- handleGrouped(dataResponse: any[], config: ItemConfig): any;
2695
+ handleGrouped(dataResponse: any[], _config: ItemConfig): any;
2427
2696
  /**
2428
2697
  * Parse level cards from details array (standard API response)
2429
2698
  */
@@ -2660,10 +2929,32 @@ declare function createTooltipFormatter(config?: {
2660
2929
  }): (value: number) => string;
2661
2930
  /**
2662
2931
  * Format words with underscores for display
2932
+ * Matches old formatterWordsUnderBar from Formatters.ts
2663
2933
  * @param text - Text to format
2664
- * @param maxLength - Optional max length to truncate to
2934
+ * @param maxCharsPerLine - Max characters per line before wrapping
2935
+ * @param insideReport - When true, return full text with line breaks (no truncation)
2936
+ */
2937
+ declare function formatWordsUnderBar(text: string, maxCharsPerLine?: number, insideReport?: boolean): string;
2938
+ /**
2939
+ * Format X Axis Configuration
2940
+ */
2941
+ interface FormatXAxisConfig$1 {
2942
+ /** Format type: dateToMonth, month, date, custom */
2943
+ type?: 'dateToMonth' | 'month' | 'date' | 'custom';
2944
+ /** Use short month format (Jan vs January) */
2945
+ shortFormate?: boolean;
2946
+ /** Custom date format string (for 'date' type) */
2947
+ customDateFormat?: string;
2948
+ /** Custom text suffix (for 'custom' type) */
2949
+ customText?: string;
2950
+ }
2951
+ /**
2952
+ * Format X-axis value based on configuration
2953
+ * Matches old FormaterXAxis function from dashboardBuilder
2954
+ * @param value - The X-axis category value (typically a date string)
2955
+ * @param configFormat - Configuration object with type and format options
2665
2956
  */
2666
- declare function formatWordsUnderBar(text: string, maxLength?: number): string;
2957
+ declare function formatXAxis(value: string | Date, configFormat?: FormatXAxisConfig$1): string;
2667
2958
 
2668
2959
  /**
2669
2960
  * Chart Helpers
@@ -3040,7 +3331,10 @@ declare class DashboardStoreService {
3040
3331
  /** Language code */
3041
3332
  readonly languageCode: _angular_core.WritableSignal<string>;
3042
3333
  /** Direction */
3043
- readonly direction: _angular_core.WritableSignal<"rtl" | "ltr">;
3334
+ readonly direction: _angular_core.WritableSignal<"ltr" | "rtl">;
3335
+ /** Inside Report Viewer flag - controls text truncation in charts */
3336
+ private insideReportViewerSignal;
3337
+ readonly insideReportViewer: _angular_core.Signal<boolean>;
3044
3338
  /** Reload current page subject */
3045
3339
  private reloadCurrentPageSubject;
3046
3340
  readonly reloadCurrentPage$: rxjs.Observable<void>;
@@ -3056,6 +3350,11 @@ declare class DashboardStoreService {
3056
3350
  * Update stop actions flag
3057
3351
  */
3058
3352
  updateStopActions(value: boolean): void;
3353
+ /**
3354
+ * Set inside report viewer mode
3355
+ * When true, axis labels won't be truncated and custom legends may be skipped
3356
+ */
3357
+ setInsideReportViewer(value: boolean): void;
3059
3358
  /**
3060
3359
  * Update dynamic key in store
3061
3360
  */
@@ -3137,61 +3436,6 @@ declare class ManageBreadcrumb implements OnInit {
3137
3436
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<ManageBreadcrumb, "mt-manage-breadcrumb", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
3138
3437
  }
3139
3438
 
3140
- /**
3141
- * Filter Field Models
3142
- *
3143
- * Defines the structure for dynamic filter fields configuration
3144
- * used in dashboard page filtering.
3145
- */
3146
- /** Localized text with English and Arabic translations */
3147
- interface LocalizedText {
3148
- en: string;
3149
- ar: string;
3150
- }
3151
- /** Filter field types supported by the system */
3152
- type FilterFieldType = 'dropdownTVService' | 'lookup' | 'status' | 'phaseGate' | 'user' | 'date' | 'section' | 'separator' | 'year' | 'month' | 'quarter' | 'checkbox' | 'schemaSettings' | 'schemaSettingsLeafs';
3153
- /** Selection item for dropdown configuration */
3154
- interface FilterSelectionItem {
3155
- id: number;
3156
- moduleType?: string;
3157
- moduleId?: number;
3158
- filters?: any[];
3159
- modules?: any[];
3160
- properties?: any[];
3161
- }
3162
- /** Filter field configuration details */
3163
- interface FilterFieldConfiguration {
3164
- payload?: {
3165
- dashboardId: number;
3166
- selection: FilterSelectionItem[];
3167
- chartType: string;
3168
- query: {
3169
- selectedProperties: string[];
3170
- };
3171
- };
3172
- lookupId?: number;
3173
- schemaLevelId?: number;
3174
- logId?: number;
3175
- isRequird?: boolean;
3176
- isMultiple?: boolean;
3177
- checked?: boolean;
3178
- minYear?: number;
3179
- maxYear?: number;
3180
- }
3181
- /** Filter field definition */
3182
- interface FilterField {
3183
- key?: string;
3184
- name?: LocalizedText;
3185
- type: FilterFieldType;
3186
- configuration?: FilterFieldConfiguration;
3187
- }
3188
- /** Filter field type option for dropdown */
3189
- interface FilterFieldTypeOption {
3190
- value: FilterFieldType;
3191
- label: string;
3192
- products: string[];
3193
- }
3194
-
3195
3439
  /**
3196
3440
  * Manage Filter On Page Component
3197
3441
  *
@@ -3292,6 +3536,18 @@ declare class ChartSettingsDrawer {
3292
3536
  /** The chart item signal - reactive for proper change detection */
3293
3537
  readonly item: _angular_core.WritableSignal<DashboardChartItem | null>;
3294
3538
  constructor();
3539
+ /** Active tab: 'display' or 'chartControls' */
3540
+ readonly activeTab: _angular_core.WritableSignal<string>;
3541
+ /** Tab options - always show Display, show Chart Controls only when a chart control UI exists */
3542
+ readonly tabOptions: _angular_core.Signal<{
3543
+ label: string;
3544
+ value: string;
3545
+ icon: string;
3546
+ }[]>;
3547
+ /** Resolve ChartTypeConfig from CHART_TYPES based on item config */
3548
+ readonly resolvedChartType: _angular_core.Signal<ChartTypeConfig | null>;
3549
+ /** ItemConfig computed for DisplaySettings input */
3550
+ readonly itemConfig: _angular_core.Signal<ItemConfig | null>;
3295
3551
  /** Determine the type of manage UI to show */
3296
3552
  readonly manageType: _angular_core.Signal<QuickManageType>;
3297
3553
  /** Default config (full config for DefaultControlUi) */
@@ -3314,6 +3570,8 @@ declare class ChartSettingsDrawer {
3314
3570
  onStackBarConfigChange(config: any): void;
3315
3571
  /** Update snapshot bar chart config */
3316
3572
  onSnapshotBarConfigChange(config: any): void;
3573
+ /** Update client config from DisplaySettings */
3574
+ onClientConfigUpdate(partialClientConfig: Partial<ClientConfig>): void;
3317
3575
  /** Apply changes and close drawer */
3318
3576
  apply(): void;
3319
3577
  /** Close without changes */
@@ -3322,126 +3580,601 @@ declare class ChartSettingsDrawer {
3322
3580
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChartSettingsDrawer, "mt-chart-settings-drawer", never, {}, {}, never, never, true, never>;
3323
3581
  }
3324
3582
 
3325
- interface DefaultControlConfig {
3326
- title: string;
3327
- titleFontSize: number;
3328
- titleColor: string;
3329
- showSubtitle: boolean;
3330
- subtitle: string;
3331
- subtitleFontSize: number;
3332
- subtitleColor: string;
3333
- backgroundColor: string;
3334
- borderColor: string;
3335
- borderRadius: number;
3336
- padding: number;
3337
- }
3338
- declare class DefaultControlUi implements ControlValueAccessor {
3339
- readonly config: _angular_core.WritableSignal<DefaultControlConfig>;
3340
- readonly fontSizeOptions: {
3341
- label: string;
3342
- value: number;
3343
- }[];
3344
- private onChange;
3345
- private onTouched;
3346
- writeValue(value: DefaultControlConfig): void;
3347
- registerOnChange(fn: (value: DefaultControlConfig) => void): void;
3348
- registerOnTouched(fn: () => void): void;
3349
- updateConfig(partial: Partial<DefaultControlConfig>): void;
3350
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<DefaultControlUi, never>;
3351
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<DefaultControlUi, "mt-default-control-ui", never, {}, {}, never, never, true, never>;
3583
+ /** Shadow configuration */
3584
+ interface ShadowConfig {
3585
+ x: number;
3586
+ y: number;
3587
+ blur: number;
3588
+ spread: number;
3589
+ color: string;
3352
3590
  }
3353
-
3354
- /**
3355
- * Pie Chart Configuration - Matches old implementation exactly
3356
- */
3357
- interface PieControlConfig {
3358
- radius?: number;
3359
- thickness?: number;
3360
- padAngle?: number;
3591
+ /** Override label configuration */
3592
+ interface OverrideLabel {
3593
+ en: string;
3594
+ ar: string;
3595
+ }
3596
+ /** Card style configuration */
3597
+ interface CardStyleConfig {
3361
3598
  borderRadius?: number;
3362
- centerX?: number;
3363
- centerY?: number;
3364
- startAngle?: number;
3365
- endAngle?: number;
3366
- roseType?: boolean | 'radius' | 'area';
3367
- useEnhancedLegend?: boolean;
3368
- legendPosition?: 'left' | 'right' | 'top' | 'bottom';
3369
- legendVerticalAlign?: 'top' | 'middle' | 'bottom';
3370
- legendOrientation?: 'horizontal' | 'vertical';
3371
- legendType?: 'scroll' | 'plain';
3372
- legendFontSize?: number;
3373
- legendFontColor?: string;
3374
- legendIcon?: string;
3375
- labelFontSize?: number;
3376
- totalValueFontSize?: number;
3377
- labelFontColor?: string;
3378
- labelFormatter?: string;
3379
- tooltipTrigger?: 'item' | 'axis' | 'none';
3380
- labelPosition?: string;
3381
- showLabelLine?: boolean;
3382
- explode?: number;
3383
- animation?: boolean;
3384
- animationDuration?: number;
3385
- tooltipBackgroundColor?: string;
3386
- tooltipBorderColor?: string;
3387
- tooltipBorderWidth?: number;
3599
+ backgroundColor?: string;
3600
+ shadows?: ShadowConfig[];
3388
3601
  }
3389
- declare class PieControlUi implements ControlValueAccessor {
3390
- readonly config: _angular_core.WritableSignal<PieControlConfig>;
3391
- readonly roseTypeOptions: ({
3392
- label: string;
3393
- value: boolean;
3394
- } | {
3395
- label: string;
3396
- value: string;
3397
- })[];
3398
- readonly labelPositionOptions: {
3602
+ /** Header card configuration */
3603
+ interface HeaderCardConfig {
3604
+ isHeaderCentered?: boolean;
3605
+ isHeaderHidden?: boolean;
3606
+ headerColor?: string;
3607
+ headerFontSize?: number;
3608
+ }
3609
+ /** Label center configuration */
3610
+ interface LabelCenterConfig {
3611
+ hide?: boolean;
3612
+ text?: {
3613
+ en?: string;
3614
+ ar?: string;
3615
+ };
3616
+ }
3617
+ /** Sort data bars configuration */
3618
+ interface SortDataBarsConfig {
3619
+ enable?: boolean;
3620
+ sortBy?: string;
3621
+ order?: 'asc' | 'desc' | string;
3622
+ direction?: 'asc' | 'desc' | string;
3623
+ }
3624
+ /** Card info configuration */
3625
+ interface CardInfoConfig {
3626
+ show?: boolean;
3627
+ value?: any;
3628
+ type?: string;
3629
+ }
3630
+ /** Format configuration */
3631
+ interface FormatConfig {
3632
+ type?: string | null;
3633
+ showCurrency?: boolean;
3634
+ handleLang?: boolean;
3635
+ customText?: string | null;
3636
+ customDateFormat?: string | null;
3637
+ showCurrencyTooltip?: boolean;
3638
+ hideSuffixes?: boolean;
3639
+ }
3640
+ /** Table format configuration */
3641
+ interface TableFormatConfig {
3642
+ thTextColor?: string | null;
3643
+ thBackgroundColor?: string | null;
3644
+ tdTextColor?: string | null;
3645
+ groupBackgroundColor?: string | null;
3646
+ groupTextColor?: string | null;
3647
+ thFontBold?: boolean;
3648
+ tdFontBold?: boolean;
3649
+ thFontSize?: number | null;
3650
+ tdFontSize?: number | null;
3651
+ hideTableSubheader?: boolean;
3652
+ disableCurrencyFormat?: boolean;
3653
+ showPercentageAsProgressBar?: boolean;
3654
+ showPercentageStatus?: boolean;
3655
+ hiddenColumns?: string[];
3656
+ sortConfig?: {
3657
+ column: string;
3658
+ direction: 'asc' | 'desc';
3659
+ };
3660
+ }
3661
+ /** Color condition configuration */
3662
+ interface ColorCondition {
3663
+ color: string;
3664
+ type: 'equal' | 'greaterThan' | 'greaterThanOrEqual' | 'lessThan' | 'lessThanOrEqual' | 'between';
3665
+ value1?: number;
3666
+ value2?: number;
3667
+ labelEn?: string;
3668
+ labelAr?: string;
3669
+ }
3670
+ /** Color conditions by bar index */
3671
+ interface ColorConditionsByIndex {
3672
+ [key: number]: ColorCondition[];
3673
+ }
3674
+ /** Ring gauge configuration */
3675
+ interface RingGaugeConfig {
3676
+ centerProperty?: string;
3677
+ statusProperty?: string;
3678
+ hiddenProperties?: string[];
3679
+ }
3680
+ /** Order configuration */
3681
+ interface OrderConfig {
3682
+ order?: string[];
3683
+ operation?: string;
3684
+ orderBy?: string;
3685
+ }
3686
+ /** Card list configuration */
3687
+ interface CardListConfig {
3688
+ hideProperties?: string[];
3689
+ }
3690
+ /** Property translation entry */
3691
+ interface PropertyTranslation {
3692
+ ar: string;
3693
+ en: string;
3694
+ }
3695
+ /** Property translations map */
3696
+ interface PropertyTranslationsMap {
3697
+ [key: string]: PropertyTranslation;
3698
+ }
3699
+ /** Property color entry */
3700
+ interface PropertyColorEntry {
3701
+ selectedKey: string;
3702
+ }
3703
+ /** Property colors map */
3704
+ interface PropertyColorsMap {
3705
+ [key: string]: PropertyColorEntry;
3706
+ }
3707
+ /** Props config as index item */
3708
+ interface PropsConfigAsIndexItem {
3709
+ width?: string;
3710
+ colorAsProperty?: string;
3711
+ hidden?: boolean;
3712
+ border?: string[];
3713
+ }
3714
+ /** Format X-Axis configuration */
3715
+ interface FormatXAxisConfig {
3716
+ type?: string | null;
3717
+ shortFormate?: boolean;
3718
+ }
3719
+ /** Extra column from lookup configuration */
3720
+ interface ExtraColumnFromLookupConfig {
3721
+ extraCoulmnFromLookup?: boolean;
3722
+ lookupId?: number | null;
3723
+ groupedBy?: string | null;
3724
+ propKey?: string | null;
3725
+ }
3726
+ /** Timeline header colors config (single) */
3727
+ interface TimelineHeaderSingleConfig {
3728
+ bgColor?: string;
3729
+ color?: string;
3730
+ }
3731
+ /**
3732
+ * Display Settings Component
3733
+ *
3734
+ * Comprehensive visual/display configuration with chart-type-aware field visibility.
3735
+ * Shows only relevant settings based on the selected chart type.
3736
+ */
3737
+ declare class DisplaySettings {
3738
+ /** Current configuration */
3739
+ readonly config: _angular_core.InputSignal<ItemConfig | null>;
3740
+ /** Selected chart type */
3741
+ readonly chartType: _angular_core.InputSignal<ChartTypeConfig | null>;
3742
+ /** Available properties (for property-based configs) */
3743
+ readonly availableProperties: _angular_core.InputSignal<any[]>;
3744
+ /** Selected properties from query */
3745
+ readonly selectedProperties: _angular_core.InputSignal<string[]>;
3746
+ /** Available lookups for extra column from lookup */
3747
+ readonly lookups: _angular_core.InputSignal<any[]>;
3748
+ /** Emit client config changes */
3749
+ readonly clientConfigChange: _angular_core.OutputEmitterRef<Partial<ClientConfig>>;
3750
+ /** Color condition expansion state */
3751
+ readonly colorConditionExpanded: _angular_core.WritableSignal<Record<number, boolean>>;
3752
+ /** Property translations paste state */
3753
+ readonly showPropertyTranslationsPaste: _angular_core.WritableSignal<boolean>;
3754
+ readonly propertyTranslationsPasteText: _angular_core.WritableSignal<string>;
3755
+ readonly propertyTranslationsPasteError: _angular_core.WritableSignal<string>;
3756
+ /** Property colors paste state */
3757
+ readonly showPropertyColorsPaste: _angular_core.WritableSignal<boolean>;
3758
+ readonly propertyColorsPasteText: _angular_core.WritableSignal<string>;
3759
+ readonly propertyColorsPasteError: _angular_core.WritableSignal<string>;
3760
+ /**
3761
+ * Chart type to fields mapping
3762
+ * Each chart type maps to comma-separated list of visible fields
3763
+ */
3764
+ private readonly chartTypeFieldsMap;
3765
+ /** Computed fields to show based on chart type */
3766
+ readonly fieldsToShow: _angular_core.Signal<string>;
3767
+ /** Check if a field should be shown */
3768
+ shouldShowField(fieldName: string): boolean;
3769
+ /** Position options */
3770
+ readonly positionOptions: {
3399
3771
  label: string;
3400
3772
  value: string;
3401
3773
  }[];
3774
+ /** Legend position options */
3402
3775
  readonly legendPositionOptions: {
3403
3776
  label: string;
3404
3777
  value: string;
3405
3778
  }[];
3406
- readonly legendVerticalAlignOptions: {
3779
+ /** Legend icon type options */
3780
+ readonly legendIconOptions: {
3407
3781
  label: string;
3408
3782
  value: string;
3409
3783
  }[];
3410
- readonly legendOrientationOptions: {
3784
+ /** Label position options */
3785
+ readonly labelPositionOptions: {
3411
3786
  label: string;
3412
3787
  value: string;
3413
3788
  }[];
3414
- readonly legendTypeOptions: {
3789
+ /** Map options */
3790
+ readonly mapOptions: {
3415
3791
  label: string;
3416
3792
  value: string;
3417
3793
  }[];
3418
- readonly legendIconOptions: {
3794
+ /** Order type options */
3795
+ readonly orderTypeOptions: {
3419
3796
  label: string;
3420
3797
  value: string;
3421
3798
  }[];
3422
- readonly labelFormatterOptions: {
3799
+ /** Order operation options */
3800
+ readonly orderOperationOptions: {
3423
3801
  label: string;
3424
3802
  value: string;
3425
3803
  }[];
3426
- readonly tooltipTriggerOptions: {
3804
+ /** Border options for props config */
3805
+ readonly borderOptions: {
3427
3806
  label: string;
3428
3807
  value: string;
3429
3808
  }[];
3430
- readonly fontSizeOptions: {
3809
+ /** Color condition type options */
3810
+ readonly colorConditionTypeOptions: {
3431
3811
  label: string;
3432
- value: number;
3812
+ value: string;
3433
3813
  }[];
3434
- private onChange;
3435
- private onTouched;
3436
- writeValue(value: PieControlConfig): void;
3437
- registerOnChange(fn: (value: PieControlConfig) => void): void;
3438
- registerOnTouched(fn: () => void): void;
3439
- updateConfig(partial: Partial<PieControlConfig>): void;
3440
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<PieControlUi, never>;
3441
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<PieControlUi, "mt-pie-control-ui", never, {}, {}, never, never, true, never>;
3442
- }
3443
-
3444
- interface BarControlConfig {
3814
+ /** Format type options */
3815
+ readonly formatTypeOptions: ({
3816
+ label: string;
3817
+ value: null;
3818
+ } | {
3819
+ label: string;
3820
+ value: string;
3821
+ })[];
3822
+ /** Format X-Axis type options */
3823
+ readonly formatXAxisTypeOptions: ({
3824
+ label: string;
3825
+ value: null;
3826
+ } | {
3827
+ label: string;
3828
+ value: string;
3829
+ })[];
3830
+ /** Default color palette */
3831
+ readonly defaultColorPalette: string[];
3832
+ /** Current style config */
3833
+ readonly styleConfig: _angular_core.Signal<StyleConfig>;
3834
+ /** Current config as type */
3835
+ readonly configAsType: _angular_core.Signal<{
3836
+ [key: string]: any;
3837
+ icon?: string;
3838
+ breadcrumb?: any[];
3839
+ }>;
3840
+ /** Current card info */
3841
+ readonly cardInfo: _angular_core.Signal<CardInfoConfig>;
3842
+ /** Current header card config */
3843
+ readonly headerCardConfig: _angular_core.Signal<HeaderCardConfig>;
3844
+ /** Current card style config */
3845
+ readonly cardStyleConfig: _angular_core.Signal<CardStyleConfig>;
3846
+ /** Current label config */
3847
+ readonly labelConfig: _angular_core.Signal<{
3848
+ show?: boolean;
3849
+ showTotalInTop?: boolean;
3850
+ position?: string;
3851
+ }>;
3852
+ /** Current legend config */
3853
+ readonly legendConfig: _angular_core.Signal<{
3854
+ show?: boolean;
3855
+ position?: string;
3856
+ iconType?: string;
3857
+ }>;
3858
+ /** Current label center config */
3859
+ readonly labelCenterConfig: _angular_core.Signal<LabelCenterConfig>;
3860
+ /** Current sort data bars config */
3861
+ readonly sortDataBarsConfig: _angular_core.Signal<SortDataBarsConfig>;
3862
+ /** Current override labels */
3863
+ readonly overrideLabels: _angular_core.Signal<OverrideLabel[]>;
3864
+ /** Current default colors */
3865
+ readonly defaultColors: _angular_core.Signal<string[]>;
3866
+ /** Current order config */
3867
+ readonly orderConfig: _angular_core.Signal<any>;
3868
+ /** Current format config */
3869
+ readonly formatConfig: _angular_core.Signal<FormatConfig>;
3870
+ /** Current table format config */
3871
+ readonly tableFormatConfig: _angular_core.Signal<TableFormatConfig>;
3872
+ /** Current color by condition */
3873
+ readonly colorByCondition: _angular_core.Signal<ColorConditionsByIndex>;
3874
+ /** Current ring gauge config */
3875
+ readonly ringGaugeConfig: _angular_core.Signal<RingGaugeConfig>;
3876
+ /** Current card list config */
3877
+ readonly cardListConfig: _angular_core.Signal<CardListConfig>;
3878
+ /** Props config as index */
3879
+ readonly propsConfigAsIndex: _angular_core.Signal<PropsConfigAsIndexItem[]>;
3880
+ /** Property translations map */
3881
+ readonly propertyTranslations: _angular_core.Signal<PropertyTranslationsMap>;
3882
+ /** Property colors map */
3883
+ readonly propertyColors: _angular_core.Signal<PropertyColorsMap>;
3884
+ /** Format X-Axis config */
3885
+ readonly formatXAxisConfig: _angular_core.Signal<FormatXAxisConfig>;
3886
+ /** Table columns config (extra column from lookup) */
3887
+ readonly tableColumnsConfig: _angular_core.Signal<ExtraColumnFromLookupConfig>;
3888
+ /** Timeline header colors config (single object for old format) */
3889
+ readonly timelineHeaderColorsSingle: _angular_core.Signal<TimelineHeaderSingleConfig>;
3890
+ /** Toggle association */
3891
+ readonly toggleAssociation: _angular_core.Signal<boolean>;
3892
+ /** Selected properties resolved from input or config */
3893
+ readonly resolvedSelectedProperties: _angular_core.Signal<any[]>;
3894
+ /** Available properties resolved from input or selected properties */
3895
+ readonly resolvedAvailableProperties: _angular_core.Signal<any[]>;
3896
+ /** Available properties as options */
3897
+ readonly propertyOptions: _angular_core.Signal<{
3898
+ label: any;
3899
+ value: any;
3900
+ }[]>;
3901
+ /** Available translation options (exclude used) */
3902
+ readonly availableTranslationOptions: _angular_core.Signal<{
3903
+ label: any;
3904
+ value: any;
3905
+ }[]>;
3906
+ /** Available color options (exclude used) */
3907
+ readonly availableColorOptions: _angular_core.Signal<{
3908
+ label: any;
3909
+ value: any;
3910
+ }[]>;
3911
+ /** All property options (full list) */
3912
+ readonly allPropertyKeyOptions: _angular_core.Signal<{
3913
+ label: any;
3914
+ value: any;
3915
+ }[]>;
3916
+ /** Ring gauge hidden properties options */
3917
+ readonly ringGaugeHiddenOptions: _angular_core.Signal<{
3918
+ label: any;
3919
+ value: any;
3920
+ }[]>;
3921
+ /** Update style config property */
3922
+ updateStyleConfig(key: keyof StyleConfig | string, value: any): void;
3923
+ /** Update configAsType property */
3924
+ updateConfigAsType(key: string, value: any): void;
3925
+ /** Update nested configAsType property */
3926
+ updateNestedConfigAsType(parentKey: string, key: string, value: any): void;
3927
+ /** Update header card config */
3928
+ updateHeaderCardConfig(key: keyof HeaderCardConfig, value: any): void;
3929
+ /** Update legend settings */
3930
+ updateLegend(key: string, value: unknown): void;
3931
+ /** Update label settings */
3932
+ updateLabel(key: string, value: unknown): void;
3933
+ /** Update label center config */
3934
+ updateLabelCenterConfig(key: string, value: any): void;
3935
+ /** Update label center text */
3936
+ updateLabelCenterText(lang: 'en' | 'ar', value: string): void;
3937
+ /** Update card style config */
3938
+ updateCardStyleConfig(key: keyof CardStyleConfig, value: any): void;
3939
+ /** Update sort data bars config */
3940
+ updateSortDataBarsConfig(key: string, value: any): void;
3941
+ /** Update card info config */
3942
+ updateCardInfoConfig(key: string, value: any): void;
3943
+ /** Update border top visibility */
3944
+ updateBorderTopShow(show: boolean): void;
3945
+ /** Update border top color */
3946
+ updateBorderTopColor(color: string): void;
3947
+ /** Update map type */
3948
+ updateMapType(value: string): void;
3949
+ /** Add a new shadow */
3950
+ addShadow(): void;
3951
+ /** Remove a shadow */
3952
+ removeShadow(index: number): void;
3953
+ /** Update a shadow property */
3954
+ updateShadow(index: number, key: keyof ShadowConfig, value: any): void;
3955
+ /** Add override label */
3956
+ addOverrideLabel(): void;
3957
+ /** Remove override label */
3958
+ removeOverrideLabel(index: number): void;
3959
+ /** Update override label */
3960
+ updateOverrideLabel(index: number, lang: 'en' | 'ar', value: string): void;
3961
+ /** Add a default color */
3962
+ addDefaultColor(color: string): void;
3963
+ /** Remove a default color */
3964
+ removeDefaultColor(index: number): void;
3965
+ /** Update a default color */
3966
+ updateDefaultColor(index: number, color: string): void;
3967
+ trackByIndex(index: number): number;
3968
+ /** Update format config */
3969
+ updateFormatConfig(key: keyof FormatConfig, value: any): void;
3970
+ /** Update table format config */
3971
+ updateTableFormatConfig(key: keyof TableFormatConfig, value: any): void;
3972
+ /** Update table format sort config */
3973
+ updateTableFormatSortConfig(key: 'column' | 'direction', value: string): void;
3974
+ /** Reset table format to default */
3975
+ resetTableFormat(): void;
3976
+ /** Get color condition indexes */
3977
+ getColorConditionIndexes(): number[];
3978
+ /** Check if a bar index is expanded */
3979
+ isColorConditionExpanded(index: number): boolean;
3980
+ /** Toggle bar index expansion */
3981
+ toggleColorConditionExpanded(index: number): void;
3982
+ /** Add bar index for color conditions */
3983
+ addColorConditionIndex(): void;
3984
+ /** Remove bar index */
3985
+ removeColorConditionIndex(index: number): void;
3986
+ /** Add condition to bar index */
3987
+ addColorCondition(index: number): void;
3988
+ /** Remove condition from bar index */
3989
+ removeColorCondition(index: number, conditionIndex: number): void;
3990
+ /** Update color condition */
3991
+ updateColorCondition(index: number, conditionIndex: number, key: keyof ColorCondition, value: any): void;
3992
+ /** Update ring gauge config */
3993
+ updateRingGaugeConfig(key: keyof RingGaugeConfig, value: any): void;
3994
+ /** Update card list hide properties */
3995
+ updateCardListHideProperties(properties: string[]): void;
3996
+ /** Add props config item */
3997
+ addPropsConfigItem(): void;
3998
+ /** Remove props config item */
3999
+ removePropsConfigItem(index: number): void;
4000
+ /** Update props config item */
4001
+ updatePropsConfigItem(index: number, key: keyof PropsConfigAsIndexItem, value: any): void;
4002
+ /** Update order config field */
4003
+ updateOrderConfig(key: keyof OrderConfig, value: any): void;
4004
+ /** Add order item */
4005
+ addOrderItem(): void;
4006
+ /** Remove order item */
4007
+ removeOrderItem(index: number): void;
4008
+ /** Update order item */
4009
+ updateOrderItem(index: number, value: string): void;
4010
+ /** Move order item up */
4011
+ moveOrderItemUp(index: number): void;
4012
+ /** Move order item down */
4013
+ moveOrderItemDown(index: number): void;
4014
+ /** Get property translation keys */
4015
+ getPropertyTranslationKeys(): string[];
4016
+ /** Add property translation */
4017
+ addPropertyTranslation(propertyKey: string): void;
4018
+ /** Remove property translation */
4019
+ removePropertyTranslation(propertyKey: string): void;
4020
+ /** Update property translation */
4021
+ updatePropertyTranslation(propertyKey: string, lang: 'ar' | 'en', value: string): void;
4022
+ /** Get property color keys */
4023
+ getPropertyColorKeys(): string[];
4024
+ /** Add property color */
4025
+ addPropertyColor(propertyKey: string): void;
4026
+ /** Copy property translations */
4027
+ copyPropertyTranslations(): void;
4028
+ /** Toggle property translations paste area */
4029
+ togglePropertyTranslationsPaste(): void;
4030
+ /** Apply pasted property translations */
4031
+ applyPropertyTranslationsPaste(): void;
4032
+ /** Remove property color */
4033
+ removePropertyColor(propertyKey: string): void;
4034
+ /** Update property color */
4035
+ updatePropertyColor(propertyKey: string, selectedKey: string): void;
4036
+ /** Copy property colors */
4037
+ copyPropertyColors(): void;
4038
+ /** Toggle property colors paste area */
4039
+ togglePropertyColorsPaste(): void;
4040
+ /** Apply pasted property colors */
4041
+ applyPropertyColorsPaste(): void;
4042
+ /** Update format X-Axis config */
4043
+ updateFormatXAxisConfig(key: keyof FormatXAxisConfig, value: any): void;
4044
+ /** Update table columns config */
4045
+ updateTableColumnsConfig(key: keyof ExtraColumnFromLookupConfig, value: any): void;
4046
+ /** Update timeline header colors (single config) */
4047
+ updateTimelineHeaderColorSingle(key: 'bgColor' | 'color', value: string): void;
4048
+ /** Update toggle association */
4049
+ updateToggleAssociation(value: boolean): void;
4050
+ /** Selected property for adding translations */
4051
+ readonly selectedPropertyForTranslation: _angular_core.WritableSignal<string>;
4052
+ /** Selected property for adding colors */
4053
+ readonly selectedPropertyForColor: _angular_core.WritableSignal<string>;
4054
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DisplaySettings, never>;
4055
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DisplaySettings, "mt-display-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "chartType": { "alias": "chartType"; "required": false; "isSignal": true; }; "availableProperties": { "alias": "availableProperties"; "required": false; "isSignal": true; }; "selectedProperties": { "alias": "selectedProperties"; "required": false; "isSignal": true; }; "lookups": { "alias": "lookups"; "required": false; "isSignal": true; }; }, { "clientConfigChange": "clientConfigChange"; }, never, never, true, never>;
4056
+ }
4057
+
4058
+ interface DefaultControlConfig {
4059
+ title: string;
4060
+ titleFontSize: number;
4061
+ titleColor: string;
4062
+ showSubtitle: boolean;
4063
+ subtitle: string;
4064
+ subtitleFontSize: number;
4065
+ subtitleColor: string;
4066
+ backgroundColor: string;
4067
+ borderColor: string;
4068
+ borderRadius: number;
4069
+ padding: number;
4070
+ }
4071
+ declare class DefaultControlUi implements ControlValueAccessor {
4072
+ readonly config: _angular_core.WritableSignal<DefaultControlConfig>;
4073
+ readonly fontSizeOptions: {
4074
+ label: string;
4075
+ value: number;
4076
+ }[];
4077
+ private onChange;
4078
+ private onTouched;
4079
+ writeValue(value: DefaultControlConfig): void;
4080
+ registerOnChange(fn: (value: DefaultControlConfig) => void): void;
4081
+ registerOnTouched(fn: () => void): void;
4082
+ updateConfig(partial: Partial<DefaultControlConfig>): void;
4083
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DefaultControlUi, never>;
4084
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DefaultControlUi, "mt-default-control-ui", never, {}, {}, never, never, true, never>;
4085
+ }
4086
+
4087
+ /**
4088
+ * Pie Chart Configuration - Matches old implementation exactly
4089
+ */
4090
+ interface PieControlConfig {
4091
+ radius?: number;
4092
+ thickness?: number;
4093
+ padAngle?: number;
4094
+ borderRadius?: number;
4095
+ centerX?: number;
4096
+ centerY?: number;
4097
+ startAngle?: number;
4098
+ endAngle?: number;
4099
+ roseType?: boolean | 'radius' | 'area';
4100
+ useEnhancedLegend?: boolean;
4101
+ legendPosition?: 'left' | 'right' | 'top' | 'bottom';
4102
+ legendVerticalAlign?: 'top' | 'middle' | 'bottom';
4103
+ legendOrientation?: 'horizontal' | 'vertical';
4104
+ legendType?: 'scroll' | 'plain';
4105
+ legendFontSize?: number;
4106
+ legendFontColor?: string;
4107
+ legendIcon?: string;
4108
+ labelFontSize?: number;
4109
+ totalValueFontSize?: number;
4110
+ labelFontColor?: string;
4111
+ labelFormatter?: string;
4112
+ tooltipTrigger?: 'item' | 'axis' | 'none';
4113
+ labelPosition?: string;
4114
+ showLabelLine?: boolean;
4115
+ explode?: number;
4116
+ animation?: boolean;
4117
+ animationDuration?: number;
4118
+ tooltipBackgroundColor?: string;
4119
+ tooltipBorderColor?: string;
4120
+ tooltipBorderWidth?: number;
4121
+ }
4122
+ declare class PieControlUi implements ControlValueAccessor {
4123
+ readonly config: _angular_core.WritableSignal<PieControlConfig>;
4124
+ readonly roseTypeOptions: ({
4125
+ label: string;
4126
+ value: boolean;
4127
+ } | {
4128
+ label: string;
4129
+ value: string;
4130
+ })[];
4131
+ readonly labelPositionOptions: {
4132
+ label: string;
4133
+ value: string;
4134
+ }[];
4135
+ readonly legendPositionOptions: {
4136
+ label: string;
4137
+ value: string;
4138
+ }[];
4139
+ readonly legendVerticalAlignOptions: {
4140
+ label: string;
4141
+ value: string;
4142
+ }[];
4143
+ readonly legendOrientationOptions: {
4144
+ label: string;
4145
+ value: string;
4146
+ }[];
4147
+ readonly legendTypeOptions: {
4148
+ label: string;
4149
+ value: string;
4150
+ }[];
4151
+ readonly legendIconOptions: {
4152
+ label: string;
4153
+ value: string;
4154
+ }[];
4155
+ readonly labelFormatterOptions: {
4156
+ label: string;
4157
+ value: string;
4158
+ }[];
4159
+ readonly tooltipTriggerOptions: {
4160
+ label: string;
4161
+ value: string;
4162
+ }[];
4163
+ readonly fontSizeOptions: {
4164
+ label: string;
4165
+ value: number;
4166
+ }[];
4167
+ private onChange;
4168
+ private onTouched;
4169
+ writeValue(value: PieControlConfig): void;
4170
+ registerOnChange(fn: (value: PieControlConfig) => void): void;
4171
+ registerOnTouched(fn: () => void): void;
4172
+ updateConfig(partial: Partial<PieControlConfig>): void;
4173
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<PieControlUi, never>;
4174
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<PieControlUi, "mt-pie-control-ui", never, {}, {}, never, never, true, never>;
4175
+ }
4176
+
4177
+ interface BarControlConfig {
3445
4178
  barWidth?: number;
3446
4179
  barGap?: number;
3447
4180
  barCategoryGap?: number;
@@ -3540,926 +4273,449 @@ interface StackBarControlConfig {
3540
4273
  isStacked?: boolean;
3541
4274
  borderRadius?: string | number;
3542
4275
  }
3543
- declare class StackBarControlUi implements ControlValueAccessor {
3544
- readonly config: _angular_core.WritableSignal<StackBarControlConfig>;
3545
- readonly legendPositionYOptions: {
3546
- label: string;
3547
- value: string;
3548
- }[];
3549
- readonly legendPositionXOptions: {
3550
- label: string;
3551
- value: string;
3552
- }[];
3553
- readonly barTypeOptions: {
3554
- label: string;
3555
- value: string;
3556
- }[];
3557
- readonly yAxisFormatOptions: ({
3558
- label: string;
3559
- value: null;
3560
- } | {
3561
- label: string;
3562
- value: string;
3563
- })[];
3564
- readonly fontSizeOptions: {
3565
- label: string;
3566
- value: number;
3567
- }[];
3568
- private onChange;
3569
- private onTouched;
3570
- writeValue(value: StackBarControlConfig): void;
3571
- registerOnChange(fn: (value: StackBarControlConfig) => void): void;
3572
- registerOnTouched(fn: () => void): void;
3573
- updateConfig(partial: Partial<StackBarControlConfig>): void;
3574
- onYAxisFormatChange(formatType: string | null): void;
3575
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<StackBarControlUi, never>;
3576
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<StackBarControlUi, "mt-stack-bar-control-ui", never, {}, {}, never, never, true, never>;
3577
- }
3578
-
3579
- /**
3580
- * Manage Item Component (Drawer)
3581
- *
3582
- * Main drawer component for configuring chart/widget items.
3583
- * Uses tabs to organize different configuration sections.
3584
- * Provides ManageItemService for state sharing between child components.
3585
- */
3586
- declare class ManageItem implements OnInit {
3587
- private _dashboardService;
3588
- private _manageItemService;
3589
- private _dialogConfig;
3590
- readonly modal: ModalService;
3591
- ref: ModalRef<any> | null;
3592
- /** Input data from drawer - supports both input() and dialog data */
3593
- readonly data: _angular_core.InputSignal<{
3594
- chart?: DashboardChartItem;
3595
- isDialog?: boolean;
3596
- isNew?: boolean;
3597
- chartType?: ChartTypeConfig;
3598
- defaultSize?: {
3599
- cols: number;
3600
- rows: number;
3601
- };
3602
- } | null>;
3603
- /** Whether chart type is pre-selected (hides type selection) */
3604
- readonly hasPreselectedType: _angular_core.Signal<boolean>;
3605
- /** Tab options with translation keys */
3606
- readonly tabOptions: _angular_core.WritableSignal<{
3607
- label: string;
3608
- value: string;
3609
- icon: string;
3610
- }[]>;
3611
- /** Active tab */
3612
- readonly activeTab: _angular_core.WritableSignal<string>;
3613
- /** Chart configuration being edited - from service */
3614
- readonly config: _angular_core.Signal<ItemConfig | null>;
3615
- /** Chart type ID - from service */
3616
- readonly chartTypeId: _angular_core.Signal<string>;
3617
- /** Selected chart type info */
3618
- readonly selectedChartType: _angular_core.WritableSignal<ChartTypeConfig | null>;
3619
- /** Is this a dialog item */
3620
- readonly isDialog: _angular_core.Signal<any>;
3621
- /** Is this a new item */
3622
- readonly isNew: _angular_core.Signal<any>;
3623
- /** Saving state */
3624
- readonly saving: _angular_core.WritableSignal<boolean>;
3625
- /** Validation state */
3626
- readonly isValid: _angular_core.Signal<boolean>;
3627
- /** Initialize from dialog data effect */
3628
- private _initEffect;
3629
- ngOnInit(): void;
3630
- save(): void;
3631
- cancel(): void;
3632
- /** Update config from child components */
3633
- onConfigUpdate(partialConfig: Partial<ItemConfig>): void;
3634
- /** Update service config */
3635
- onServiceConfigUpdate(partialConfig: Partial<ItemConfig['serviceConfig']>): void;
3636
- /** Update client config */
3637
- onClientConfigUpdate(partialConfig: Partial<ItemConfig['clientConfig']>): void;
3638
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<ManageItem, never>;
3639
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<ManageItem, "mt-manage-item", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
3640
- }
3641
-
3642
- /**
3643
- * General Settings Component
3644
- *
3645
- * Handles general chart configuration:
3646
- * - Chart type selection (visual grid)
3647
- * - Title (English & Arabic)
3648
- * - Component name
3649
- */
3650
- declare class GeneralSettings {
3651
- private transloco;
3652
- /** Current configuration */
3653
- readonly config: _angular_core.InputSignal<ItemConfig | null>;
3654
- /** Is dialog item (hides chart type selection) */
3655
- readonly isDialog: _angular_core.InputSignal<boolean>;
3656
- /** Whether chart type is pre-selected (hides chart type selection) */
3657
- readonly hasPreselectedType: _angular_core.InputSignal<boolean>;
3658
- /** Emit config changes */
3659
- readonly configChange: _angular_core.OutputEmitterRef<Partial<ItemConfig>>;
3660
- /** Emit chart type selection */
3661
- readonly chartTypeChange: _angular_core.OutputEmitterRef<ChartTypeConfig>;
3662
- /** All available chart types */
3663
- readonly chartTypes: _angular_core.WritableSignal<ChartTypeConfig[]>;
3664
- /** Chart types filtered (not hidden) */
3665
- readonly chartTypesFiltered: _angular_core.Signal<ChartTypeConfig[]>;
3666
- /** Grouped chart types by category */
3667
- readonly chartTypesByCategory: _angular_core.Signal<{
3668
- card: ChartTypeConfig[];
3669
- chart: ChartTypeConfig[];
3670
- table: ChartTypeConfig[];
3671
- special: ChartTypeConfig[];
3672
- layout: ChartTypeConfig[];
3673
- }>;
3674
- /** Currently selected chart type */
3675
- readonly selectedChartType: _angular_core.Signal<ChartTypeConfig | null | undefined>;
3676
- /**
3677
- * Select a chart type
3678
- */
3679
- selectChartType(type: ChartTypeConfig): void;
3680
- /**
3681
- * Check if a chart type is selected
3682
- */
3683
- isTypeSelected(type: ChartTypeConfig): boolean;
3684
- /**
3685
- * Update title field
3686
- */
3687
- updateTitle(lang: 'en' | 'ar', value: string): void;
3688
- /**
3689
- * Update component name
3690
- */
3691
- updateComponentName(value: string): void;
3692
- /**
3693
- * Get category label
3694
- */
3695
- getCategoryLabel(category: string): string;
3696
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<GeneralSettings, never>;
3697
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<GeneralSettings, "mt-general-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "isDialog": { "alias": "isDialog"; "required": false; "isSignal": true; }; "hasPreselectedType": { "alias": "hasPreselectedType"; "required": false; "isSignal": true; }; }, { "configChange": "configChange"; "chartTypeChange": "chartTypeChange"; }, never, never, true, never>;
3698
- }
3699
-
3700
- /**
3701
- * Selection module info for linking - includes properties for each selection
3702
- */
3703
- interface SelectionModule {
3704
- selectionId: number;
3705
- selector: string;
3706
- moduleType: string;
3707
- moduleTypeName: string;
3708
- moduleName: string;
3709
- properties: IProperty[];
3710
- }
3711
-
3712
- /**
3713
- * Chart Query Series
3714
- */
3715
- interface ChartQuerySeries {
3716
- key: string;
3717
- color: string;
3718
- valueProperty: string | null;
3719
- aggregateFunction: string;
3720
- groupByProperties: string[];
3721
- autoStack: boolean;
3722
- stackProperties: string[];
3723
- autoStackByProperty: string | null;
3724
- filters: ChartQuerySeriesFilter[];
3725
- extraProperties: string[];
3726
- formula?: string;
3727
- showAdvancedSettings?: boolean;
3728
- barType?: 'bar' | 'line' | 'lineAccumulated';
3729
- }
3730
- /**
3731
- * Chart Query Series Filter
3732
- */
3733
- interface ChartQuerySeriesFilter {
3734
- propertyKey: string | null;
3735
- value: any;
3736
- operator: string;
3737
- }
3738
- /**
3739
- * Chart Query Configuration
3740
- */
3741
- interface ChartQuery {
3742
- categoryProperty: string;
3743
- series: ChartQuerySeries[];
3744
- }
3745
-
3746
- /** Properties grouped by module for select with [group]="true" */
3747
- interface PropertyGroup {
3748
- label: string;
3749
- items: IProperty[];
3750
- }
3751
- /**
3752
- * Aggregation Property Configuration
3753
- */
3754
- interface AggregationProperty {
3755
- propertyKey: string | null;
3756
- aggregateFunction: string;
3757
- alias?: string;
3758
- }
3759
- /**
3760
- * Table Query Configuration Value
3761
- */
3762
- interface TableQueryValue {
3763
- selectedProperties: string[];
3764
- AggregationProperties: AggregationProperty[];
3765
- lookupProperty: string;
3766
- PivotProperties: string[];
3767
- }
3768
- /**
3769
- * Table Query Component
3770
- *
3771
- * Handles query configuration for table/dialog chart types.
3772
- * Implements ControlValueAccessor for form integration.
3773
- */
3774
- declare class TableQuery implements ControlValueAccessor {
3775
- private fb;
3776
- /** Available properties (flat) */
3777
- readonly propertiesFlat: _angular_core.InputSignal<IProperty[]>;
3778
- /** Properties grouped by module for grouped select */
3779
- readonly propertiesGrouped: _angular_core.InputSignal<PropertyGroup[]>;
3780
- /** Whether to use grouped select (when multiple modules) */
3781
- readonly useGroupedSelect: _angular_core.Signal<boolean>;
3782
- /** Options config for multi-select */
3783
- readonly optionsConfig: _angular_core.Signal<{
3784
- optionValue: string;
3785
- optionLabel: string;
3786
- items: IProperty[];
3787
- }>;
3788
- /** Aggregate function options */
3789
- readonly aggregateFunctions: {
4276
+ declare class StackBarControlUi implements ControlValueAccessor {
4277
+ readonly config: _angular_core.WritableSignal<StackBarControlConfig>;
4278
+ readonly legendPositionYOptions: {
4279
+ label: string;
3790
4280
  value: string;
4281
+ }[];
4282
+ readonly legendPositionXOptions: {
3791
4283
  label: string;
4284
+ value: string;
4285
+ }[];
4286
+ readonly barTypeOptions: {
4287
+ label: string;
4288
+ value: string;
4289
+ }[];
4290
+ readonly yAxisFormatOptions: ({
4291
+ label: string;
4292
+ value: null;
4293
+ } | {
4294
+ label: string;
4295
+ value: string;
4296
+ })[];
4297
+ readonly fontSizeOptions: {
4298
+ label: string;
4299
+ value: number;
3792
4300
  }[];
3793
- /** Main form */
3794
- readonly queryForm: FormGroup<{
3795
- selectedProperties: _angular_forms.FormControl<string[] | null>;
3796
- AggregationProperties: FormArray<FormGroup<any>>;
3797
- lookupProperty: _angular_forms.FormControl<string | null>;
3798
- PivotProperties: _angular_forms.FormControl<string[] | null>;
3799
- }>;
3800
- /** Disabled state */
3801
- disabled: boolean;
3802
- /** ControlValueAccessor callbacks */
3803
4301
  private onChange;
3804
4302
  private onTouched;
3805
- constructor();
3806
- writeValue(value: TableQueryValue): void;
3807
- registerOnChange(fn: (value: TableQueryValue) => void): void;
4303
+ writeValue(value: StackBarControlConfig): void;
4304
+ registerOnChange(fn: (value: StackBarControlConfig) => void): void;
3808
4305
  registerOnTouched(fn: () => void): void;
3809
- setDisabledState(isDisabled: boolean): void;
3810
- validate(): ValidationErrors | null;
3811
- get aggregationArray(): FormArray;
3812
- createAggregationFormGroup(agg?: Partial<AggregationProperty>): FormGroup;
3813
- addAggregation(): void;
3814
- removeAggregation(index: number): void;
3815
- trackByIndex(index: number): number;
3816
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<TableQuery, never>;
3817
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<TableQuery, "mt-table-query", never, { "propertiesFlat": { "alias": "propertiesFlat"; "required": false; "isSignal": true; }; "propertiesGrouped": { "alias": "propertiesGrouped"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
4306
+ updateConfig(partial: Partial<StackBarControlConfig>): void;
4307
+ onYAxisFormatChange(formatType: string | null): void;
4308
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<StackBarControlUi, never>;
4309
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<StackBarControlUi, "mt-stack-bar-control-ui", never, {}, {}, never, never, true, never>;
3818
4310
  }
3819
4311
 
3820
- /** Module properties response */
3821
- interface ModuleProperties {
3822
- /** Module type (e.g., "Level") */
3823
- moduleName: string;
3824
- /** Display name for the specific selector (e.g., "Projects" for "Level:7") */
3825
- selectorName: string | null;
3826
- /** Full selector (e.g., "Level:7") */
3827
- selector: string;
3828
- moduleId?: number;
3829
- properties: IProperty[];
3830
- }
3831
- /**
3832
- * Query component type based on chart type and component name
3833
- */
3834
- type QueryComponentType = 'general' | 'table' | 'timeline' | 'timelineMultiLevel' | 'map' | 'splitter' | 'properties' | 'snapshot' | 'phaseGate' | 'repeater' | 'none';
3835
4312
  /**
3836
- * Data Source Settings Component
4313
+ * Manage Item Component (Drawer)
3837
4314
  *
3838
- * Comprehensive data source configuration:
3839
- * - Module/Data source selection via SelectionConfiguration
3840
- * - Source links for multiple selections via SourceLinkConfiguration
3841
- * - Query configuration based on chart type (GeneralQuery, TableQuery, etc.)
4315
+ * Main drawer component for configuring chart/widget items.
4316
+ * Uses tabs to organize different configuration sections.
4317
+ * Provides ManageItemService for state sharing between child components.
3842
4318
  */
3843
- declare class DataSourceSettings {
3844
- private dashboardService;
3845
- /** Current configuration */
3846
- readonly config: _angular_core.InputSignal<ItemConfig | null>;
3847
- /** Selected chart type */
3848
- readonly chartType: _angular_core.InputSignal<ChartTypeConfig | null>;
3849
- /** Emit service config changes */
3850
- readonly serviceConfigChange: _angular_core.OutputEmitterRef<Partial<ServiceConfig>>;
3851
- /** Properties grouped by module */
3852
- readonly modulesProperties: _angular_core.WritableSignal<ModuleProperties[]>;
3853
- /** Flattened properties list with grouping info */
3854
- readonly propertiesFlat: _angular_core.Signal<IPropertyWithGroup[]>;
3855
- /**
3856
- * Properties grouped for select field with [group]="true"
3857
- * Structure: [{ label: 'Projects', items: [{ name, key }, ...] }, ...]
3858
- * Uses selectorName for display (e.g., "Projects" instead of "Level")
3859
- */
3860
- readonly propertiesGrouped: _angular_core.Signal<{
3861
- label: string;
3862
- items: IProperty[];
3863
- }[]>;
3864
- /**
3865
- * Selection modules for source link configuration
3866
- * Built from selections with their loaded module info
3867
- */
3868
- readonly selectionModules: _angular_core.Signal<SelectionModule[]>;
3869
- /** Query component type based on chart type and component name */
3870
- readonly queryComponentType: _angular_core.Signal<QueryComponentType>;
3871
- /** Loading states */
3872
- readonly loadingProperties: _angular_core.WritableSignal<boolean>;
3873
- /** Tab state: 'selection' or 'customApi' */
3874
- readonly activeTab: _angular_core.WritableSignal<"selection" | "customApi">;
3875
- /** Tab options for display */
3876
- readonly tabOptions: {
3877
- id: string;
4319
+ declare class ManageItem implements OnInit {
4320
+ private _dashboardService;
4321
+ private _manageItemService;
4322
+ private _dialogConfig;
4323
+ readonly modal: ModalService;
4324
+ ref: ModalRef<any> | null;
4325
+ /** Input data from drawer - supports both input() and dialog data */
4326
+ readonly data: _angular_core.InputSignal<{
4327
+ chart?: DashboardChartItem;
4328
+ isDialog?: boolean;
4329
+ isNew?: boolean;
4330
+ chartType?: ChartTypeConfig;
4331
+ defaultSize?: {
4332
+ cols: number;
4333
+ rows: number;
4334
+ };
4335
+ } | null>;
4336
+ /** Whether chart type is pre-selected (hides type selection) */
4337
+ readonly hasPreselectedType: _angular_core.Signal<boolean>;
4338
+ /** Tab options with translation keys */
4339
+ readonly tabOptions: _angular_core.WritableSignal<{
3878
4340
  label: string;
3879
- }[];
3880
- /** Custom API configuration */
3881
- readonly customApi: _angular_core.WritableSignal<CustomApi | null>;
3882
- /** Internal selections state */
3883
- readonly selections: _angular_core.WritableSignal<ISelection[]>;
3884
- readonly sourceLinks: _angular_core.WritableSignal<SourceLink[]>;
3885
- readonly query: _angular_core.WritableSignal<any>;
3886
- readonly isNormalized: _angular_core.WritableSignal<boolean>;
3887
- readonly groupByMultiple: _angular_core.WritableSignal<string[]>;
3888
- /** Repeater dashboard selection */
3889
- readonly repeaterDashboardId: _angular_core.WritableSignal<number | null>;
3890
- readonly availableDashboards: _angular_core.WritableSignal<{
3891
- id: number;
3892
- name: string;
4341
+ value: string;
4342
+ icon: string;
3893
4343
  }[]>;
3894
- /** Show source links when multiple selections exist */
3895
- readonly showSourceLinks: _angular_core.Signal<boolean>;
3896
- /** Hide selection config for layout, snapshot, phaseGate types (they don't need data source selection) */
3897
- readonly hideSelectionConfig: _angular_core.Signal<boolean>;
3898
- /** Show groupByMultiple for table queries (non-report mode) */
3899
- readonly showGroupByMultiple: _angular_core.Signal<boolean>;
3900
- /**
3901
- * Derived signal: Extract module keys from selections for change detection
3902
- * Only changes when actual selectors change, not on every selection update
3903
- */
3904
- private readonly moduleKeysSignature;
3905
- /** Track last loaded module signature to prevent duplicate requests */
3906
- private lastLoadedSignature;
3907
- constructor();
3908
- /**
3909
- * Load properties for all selections using bulk API
3910
- * Single POST request to /metadata/modules/properties
3911
- * Enriches response with selectorName from tree data
3912
- */
3913
- loadPropertiesForSelections(selections: ISelection[]): void;
3914
- /**
3915
- * Handle selection changes
3916
- */
3917
- onSelectionsChange(selections: ISelection[]): void;
3918
- /**
3919
- * Handle module change - update selections, effect handles property loading
3920
- */
3921
- onModuleChange(event: {
3922
- selectionId: number;
3923
- selector: string;
3924
- selectorName?: string | null;
3925
- }): void;
3926
- /**
3927
- * Extract module type from selector (e.g., "Level:7" -> "Level")
3928
- */
3929
- private extractModuleTypeFromSelector;
3930
- /**
3931
- * Handle source links change
3932
- */
3933
- onSourceLinksChange(links: SourceLink[]): void;
3934
- /**
3935
- * Handle query change (general query)
3936
- */
3937
- onQueryChange(query: ChartQuery): void;
3938
- /**
3939
- * Handle table query change
3940
- */
3941
- onTableQueryChange(query: TableQuery): void;
3942
- /**
3943
- * Handle timeline query change
3944
- */
3945
- onTimelineQueryChange(query: any): void;
3946
- /**
3947
- * Handle map query change
3948
- */
3949
- onMapQueryChange(query: any): void;
3950
- /**
3951
- * Handle splitter query change
3952
- */
3953
- onSplitterQueryChange(query: any): void;
3954
- /**
3955
- * Handle properties query change
3956
- */
3957
- onPropertiesQueryChange(query: any): void;
3958
- /**
3959
- * Handle snapshot query change
3960
- */
3961
- onSnapshotQueryChange(query: any): void;
3962
- /**
3963
- * Handle groupByMultiple change
3964
- */
3965
- onGroupByMultipleChange(values: string[]): void;
4344
+ /** Active tab */
4345
+ readonly activeTab: _angular_core.WritableSignal<string>;
4346
+ /** Chart configuration being edited - from service */
4347
+ readonly config: _angular_core.Signal<ItemConfig | null>;
4348
+ /** Chart type ID - from service */
4349
+ readonly chartTypeId: _angular_core.Signal<string>;
4350
+ /** Selected chart type info */
4351
+ readonly selectedChartType: _angular_core.WritableSignal<ChartTypeConfig | null>;
4352
+ /** Is this a dialog item */
4353
+ readonly isDialog: _angular_core.Signal<any>;
4354
+ /** Is this a new item */
4355
+ readonly isNew: _angular_core.Signal<any>;
4356
+ /** Saving state */
4357
+ readonly saving: _angular_core.WritableSignal<boolean>;
4358
+ /** Validation state */
4359
+ readonly isValid: _angular_core.Signal<boolean>;
4360
+ ngOnInit(): void;
4361
+ save(): void;
4362
+ cancel(): void;
4363
+ /** Update config from child components */
4364
+ onConfigUpdate(partialConfig: Partial<ItemConfig>): void;
4365
+ /** Update service config */
4366
+ onServiceConfigUpdate(partialConfig: Partial<ItemConfig['serviceConfig']>): void;
4367
+ /** Update client config */
4368
+ onClientConfigUpdate(partialConfig: Partial<ItemConfig['clientConfig']>): void;
4369
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<ManageItem, never>;
4370
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<ManageItem, "mt-manage-item", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
4371
+ }
4372
+
4373
+ /**
4374
+ * General Settings Component
4375
+ *
4376
+ * Handles general chart configuration:
4377
+ * - Chart type selection (visual grid)
4378
+ * - Title (English & Arabic)
4379
+ * - Component name
4380
+ */
4381
+ declare class GeneralSettings {
4382
+ private transloco;
4383
+ /** Current configuration */
4384
+ readonly config: _angular_core.InputSignal<ItemConfig | null>;
4385
+ /** Is dialog item (hides chart type selection) */
4386
+ readonly isDialog: _angular_core.InputSignal<boolean>;
4387
+ /** Whether chart type is pre-selected (hides chart type selection) */
4388
+ readonly hasPreselectedType: _angular_core.InputSignal<boolean>;
4389
+ /** Emit config changes */
4390
+ readonly configChange: _angular_core.OutputEmitterRef<Partial<ItemConfig>>;
4391
+ /** Emit chart type selection */
4392
+ readonly chartTypeChange: _angular_core.OutputEmitterRef<ChartTypeConfig>;
4393
+ /** All available chart types */
4394
+ readonly chartTypes: _angular_core.WritableSignal<ChartTypeConfig[]>;
4395
+ /** Chart types filtered (not hidden) */
4396
+ readonly chartTypesFiltered: _angular_core.Signal<ChartTypeConfig[]>;
4397
+ /** Grouped chart types by category */
4398
+ readonly chartTypesByCategory: _angular_core.Signal<{
4399
+ card: ChartTypeConfig[];
4400
+ chart: ChartTypeConfig[];
4401
+ table: ChartTypeConfig[];
4402
+ special: ChartTypeConfig[];
4403
+ layout: ChartTypeConfig[];
4404
+ }>;
4405
+ /** Currently selected chart type */
4406
+ readonly selectedChartType: _angular_core.Signal<ChartTypeConfig | null | undefined>;
3966
4407
  /**
3967
- * Handle repeater dashboard selection
4408
+ * Select a chart type
3968
4409
  */
3969
- onRepeaterDashboardChange(dashboardId: number): void;
4410
+ selectChartType(type: ChartTypeConfig): void;
3970
4411
  /**
3971
- * Handle isNormalized change
4412
+ * Check if a chart type is selected
3972
4413
  */
3973
- onIsNormalizedChange(value: boolean): void;
4414
+ isTypeSelected(type: ChartTypeConfig): boolean;
3974
4415
  /**
3975
- * Handle tab change
4416
+ * Update title field
3976
4417
  */
3977
- onTabChange(tabId: string): void;
4418
+ updateTitle(lang: 'en' | 'ar', value: string): void;
3978
4419
  /**
3979
- * Handle custom API change
4420
+ * Update component name
3980
4421
  */
3981
- onCustomApiChange(customApi: CustomApi | null): void;
4422
+ updateComponentName(value: string): void;
3982
4423
  /**
3983
- * Get chart type id for query component
4424
+ * Get category label
3984
4425
  */
3985
- getChartTypeId(): string;
3986
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataSourceSettings, never>;
3987
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataSourceSettings, "mt-data-source-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "chartType": { "alias": "chartType"; "required": false; "isSignal": true; }; }, { "serviceConfigChange": "serviceConfigChange"; }, never, never, true, never>;
4426
+ getCategoryLabel(category: string): string;
4427
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<GeneralSettings, never>;
4428
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<GeneralSettings, "mt-general-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "isDialog": { "alias": "isDialog"; "required": false; "isSignal": true; }; "hasPreselectedType": { "alias": "hasPreselectedType"; "required": false; "isSignal": true; }; }, { "configChange": "configChange"; "chartTypeChange": "chartTypeChange"; }, never, never, true, never>;
3988
4429
  }
3989
4430
 
3990
- /** Shadow configuration */
3991
- interface ShadowConfig {
3992
- x: number;
3993
- y: number;
3994
- blur: number;
3995
- spread: number;
3996
- color: string;
3997
- }
3998
- /** Override label configuration */
3999
- interface OverrideLabel {
4000
- en: string;
4001
- ar: string;
4002
- }
4003
- /** Card style configuration */
4004
- interface CardStyleConfig {
4005
- borderRadius?: number;
4006
- backgroundColor?: string;
4007
- shadows?: ShadowConfig[];
4008
- }
4009
- /** Header card configuration */
4010
- interface HeaderCardConfig {
4011
- isHeaderCentered?: boolean;
4012
- isHeaderHidden?: boolean;
4013
- headerColor?: string;
4014
- headerFontSize?: number;
4015
- }
4016
- /** Label center configuration */
4017
- interface LabelCenterConfig {
4018
- hide?: boolean;
4019
- text?: {
4020
- en?: string;
4021
- ar?: string;
4022
- };
4023
- }
4024
- /** Sort data bars configuration */
4025
- interface SortDataBarsConfig {
4026
- enable?: boolean;
4027
- sortBy?: string;
4028
- order?: 'asc' | 'desc' | string;
4029
- direction?: 'asc' | 'desc' | string;
4030
- }
4031
- /** Card info configuration */
4032
- interface CardInfoConfig {
4033
- show?: boolean;
4034
- value?: any;
4035
- type?: string;
4036
- }
4037
- /** Format configuration */
4038
- interface FormatConfig {
4039
- type?: string | null;
4040
- showCurrency?: boolean;
4041
- handleLang?: boolean;
4042
- customText?: string | null;
4043
- customDateFormat?: string | null;
4044
- showCurrencyTooltip?: boolean;
4045
- hideSuffixes?: boolean;
4046
- }
4047
- /** Table format configuration */
4048
- interface TableFormatConfig {
4049
- thTextColor?: string | null;
4050
- thBackgroundColor?: string | null;
4051
- tdTextColor?: string | null;
4052
- groupBackgroundColor?: string | null;
4053
- groupTextColor?: string | null;
4054
- thFontBold?: boolean;
4055
- tdFontBold?: boolean;
4056
- thFontSize?: number | null;
4057
- tdFontSize?: number | null;
4058
- hideTableSubheader?: boolean;
4059
- disableCurrencyFormat?: boolean;
4060
- showPercentageAsProgressBar?: boolean;
4061
- showPercentageStatus?: boolean;
4062
- hiddenColumns?: string[];
4063
- sortConfig?: {
4064
- column: string;
4065
- direction: 'asc' | 'desc';
4066
- };
4431
+ /**
4432
+ * Selection module info for linking - includes properties for each selection
4433
+ */
4434
+ interface SelectionModule {
4435
+ selectionId: number;
4436
+ selector: string;
4437
+ moduleType: string;
4438
+ moduleTypeName: string;
4439
+ moduleName: string;
4440
+ properties: IProperty[];
4067
4441
  }
4068
- /** Color condition configuration */
4069
- interface ColorCondition {
4442
+
4443
+ /**
4444
+ * Chart Query Series
4445
+ */
4446
+ interface ChartQuerySeries {
4447
+ key: string;
4070
4448
  color: string;
4071
- type: 'equal' | 'greaterThan' | 'greaterThanOrEqual' | 'lessThan' | 'lessThanOrEqual' | 'between';
4072
- value1?: number;
4073
- value2?: number;
4074
- labelEn?: string;
4075
- labelAr?: string;
4076
- }
4077
- /** Color conditions by bar index */
4078
- interface ColorConditionsByIndex {
4079
- [key: number]: ColorCondition[];
4080
- }
4081
- /** Ring gauge configuration */
4082
- interface RingGaugeConfig {
4083
- centerProperty?: string;
4084
- statusProperty?: string;
4085
- hiddenProperties?: string[];
4086
- }
4087
- /** Order configuration */
4088
- interface OrderConfig {
4089
- order?: string[];
4090
- operation?: string;
4091
- orderBy?: string;
4092
- }
4093
- /** Card list configuration */
4094
- interface CardListConfig {
4095
- hideProperties?: string[];
4096
- }
4097
- /** Property translation entry */
4098
- interface PropertyTranslation {
4099
- ar: string;
4100
- en: string;
4449
+ valueProperty: string | null;
4450
+ aggregateFunction: string;
4451
+ groupByProperties: string[];
4452
+ autoStack: boolean;
4453
+ stackProperties: string[];
4454
+ autoStackByProperty: string | null;
4455
+ filters: ChartQuerySeriesFilter[];
4456
+ extraProperties: string[];
4457
+ formula?: string;
4458
+ showAdvancedSettings?: boolean;
4459
+ barType?: 'bar' | 'line' | 'lineAccumulated';
4101
4460
  }
4102
- /** Property translations map */
4103
- interface PropertyTranslationsMap {
4104
- [key: string]: PropertyTranslation;
4461
+ /**
4462
+ * Chart Query Series Filter
4463
+ */
4464
+ interface ChartQuerySeriesFilter {
4465
+ propertyKey: string | null;
4466
+ value: any;
4467
+ operator: string;
4105
4468
  }
4106
- /** Property color entry */
4107
- interface PropertyColorEntry {
4108
- selectedKey: string;
4469
+ /**
4470
+ * Chart Query Configuration
4471
+ */
4472
+ interface ChartQuery {
4473
+ categoryProperty: string;
4474
+ series: ChartQuerySeries[];
4109
4475
  }
4110
- /** Property colors map */
4111
- interface PropertyColorsMap {
4112
- [key: string]: PropertyColorEntry;
4476
+
4477
+ /** Properties grouped by module for select with [group]="true" */
4478
+ interface PropertyGroup {
4479
+ label: string;
4480
+ items: IProperty[];
4113
4481
  }
4114
- /** Props config as index item */
4115
- interface PropsConfigAsIndexItem {
4116
- width?: string;
4117
- colorAsProperty?: string;
4118
- hidden?: boolean;
4119
- border?: string[];
4482
+ /**
4483
+ * Aggregation Property Configuration
4484
+ */
4485
+ interface AggregationProperty {
4486
+ propertyKey: string | null;
4487
+ aggregateFunction: string;
4488
+ alias?: string;
4120
4489
  }
4121
- /** Format X-Axis configuration */
4122
- interface FormatXAxisConfig {
4123
- type?: string | null;
4124
- shortFormate?: boolean;
4490
+ /**
4491
+ * Table Query Configuration Value
4492
+ */
4493
+ interface TableQueryValue {
4494
+ selectedProperties: string[];
4495
+ AggregationProperties: AggregationProperty[];
4496
+ lookupProperty: string;
4497
+ PivotProperties: string[];
4125
4498
  }
4126
- /** Extra column from lookup configuration */
4127
- interface ExtraColumnFromLookupConfig {
4128
- extraCoulmnFromLookup?: boolean;
4129
- lookupId?: number | null;
4130
- groupedBy?: string | null;
4131
- propKey?: string | null;
4499
+ /**
4500
+ * Table Query Component
4501
+ *
4502
+ * Handles query configuration for table/dialog chart types.
4503
+ * Implements ControlValueAccessor for form integration.
4504
+ */
4505
+ declare class TableQuery implements ControlValueAccessor {
4506
+ private fb;
4507
+ /** Available properties (flat) */
4508
+ readonly propertiesFlat: _angular_core.InputSignal<IProperty[]>;
4509
+ /** Properties grouped by module for grouped select */
4510
+ readonly propertiesGrouped: _angular_core.InputSignal<PropertyGroup[]>;
4511
+ /** Whether to use grouped select (when multiple modules) */
4512
+ readonly useGroupedSelect: _angular_core.Signal<boolean>;
4513
+ /** Options config for multi-select */
4514
+ readonly optionsConfig: _angular_core.Signal<{
4515
+ optionValue: string;
4516
+ optionLabel: string;
4517
+ items: IProperty[];
4518
+ }>;
4519
+ /** Aggregate function options */
4520
+ readonly aggregateFunctions: {
4521
+ value: string;
4522
+ label: string;
4523
+ }[];
4524
+ /** Main form */
4525
+ readonly queryForm: FormGroup<{
4526
+ selectedProperties: _angular_forms.FormControl<string[] | null>;
4527
+ AggregationProperties: FormArray<FormGroup<any>>;
4528
+ lookupProperty: _angular_forms.FormControl<string | null>;
4529
+ PivotProperties: _angular_forms.FormControl<string[] | null>;
4530
+ }>;
4531
+ /** Disabled state */
4532
+ disabled: boolean;
4533
+ /** ControlValueAccessor callbacks */
4534
+ private onChange;
4535
+ private onTouched;
4536
+ constructor();
4537
+ writeValue(value: TableQueryValue): void;
4538
+ registerOnChange(fn: (value: TableQueryValue) => void): void;
4539
+ registerOnTouched(fn: () => void): void;
4540
+ setDisabledState(isDisabled: boolean): void;
4541
+ validate(): ValidationErrors | null;
4542
+ get aggregationArray(): FormArray;
4543
+ createAggregationFormGroup(agg?: Partial<AggregationProperty>): FormGroup;
4544
+ addAggregation(): void;
4545
+ removeAggregation(index: number): void;
4546
+ trackByIndex(index: number): number;
4547
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<TableQuery, never>;
4548
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<TableQuery, "mt-table-query", never, { "propertiesFlat": { "alias": "propertiesFlat"; "required": false; "isSignal": true; }; "propertiesGrouped": { "alias": "propertiesGrouped"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
4132
4549
  }
4133
- /** Timeline header colors config (single) */
4134
- interface TimelineHeaderSingleConfig {
4135
- bgColor?: string;
4136
- color?: string;
4550
+
4551
+ /** Module properties response */
4552
+ interface ModuleProperties {
4553
+ /** Module type (e.g., "Level") */
4554
+ moduleName: string;
4555
+ /** Display name for the specific selector (e.g., "Projects" for "Level:7") */
4556
+ selectorName: string | null;
4557
+ /** Full selector (e.g., "Level:7") */
4558
+ selector: string;
4559
+ moduleId?: number;
4560
+ properties: IProperty[];
4137
4561
  }
4138
4562
  /**
4139
- * Display Settings Component
4563
+ * Query component type based on chart type and component name
4564
+ */
4565
+ type QueryComponentType = 'general' | 'table' | 'timeline' | 'timelineMultiLevel' | 'map' | 'splitter' | 'properties' | 'snapshot' | 'phaseGate' | 'repeater' | 'none';
4566
+ /**
4567
+ * Data Source Settings Component
4140
4568
  *
4141
- * Comprehensive visual/display configuration with chart-type-aware field visibility.
4142
- * Shows only relevant settings based on the selected chart type.
4569
+ * Comprehensive data source configuration:
4570
+ * - Module/Data source selection via SelectionConfiguration
4571
+ * - Source links for multiple selections via SourceLinkConfiguration
4572
+ * - Query configuration based on chart type (GeneralQuery, TableQuery, etc.)
4143
4573
  */
4144
- declare class DisplaySettings {
4574
+ declare class DataSourceSettings {
4575
+ private dashboardService;
4145
4576
  /** Current configuration */
4146
4577
  readonly config: _angular_core.InputSignal<ItemConfig | null>;
4147
4578
  /** Selected chart type */
4148
4579
  readonly chartType: _angular_core.InputSignal<ChartTypeConfig | null>;
4149
- /** Available properties (for property-based configs) */
4150
- readonly availableProperties: _angular_core.InputSignal<any[]>;
4151
- /** Selected properties from query */
4152
- readonly selectedProperties: _angular_core.InputSignal<string[]>;
4153
- /** Available lookups for extra column from lookup */
4154
- readonly lookups: _angular_core.InputSignal<any[]>;
4155
- /** Emit client config changes */
4156
- readonly clientConfigChange: _angular_core.OutputEmitterRef<Partial<ClientConfig>>;
4157
- /** Color condition expansion state */
4158
- readonly colorConditionExpanded: _angular_core.WritableSignal<Record<number, boolean>>;
4159
- /** Property translations paste state */
4160
- readonly showPropertyTranslationsPaste: _angular_core.WritableSignal<boolean>;
4161
- readonly propertyTranslationsPasteText: _angular_core.WritableSignal<string>;
4162
- readonly propertyTranslationsPasteError: _angular_core.WritableSignal<string>;
4163
- /** Property colors paste state */
4164
- readonly showPropertyColorsPaste: _angular_core.WritableSignal<boolean>;
4165
- readonly propertyColorsPasteText: _angular_core.WritableSignal<string>;
4166
- readonly propertyColorsPasteError: _angular_core.WritableSignal<string>;
4580
+ /** Emit service config changes */
4581
+ readonly serviceConfigChange: _angular_core.OutputEmitterRef<Partial<ServiceConfig>>;
4582
+ /** Properties grouped by module */
4583
+ readonly modulesProperties: _angular_core.WritableSignal<ModuleProperties[]>;
4584
+ /** Flattened properties list with grouping info */
4585
+ readonly propertiesFlat: _angular_core.Signal<IPropertyWithGroup[]>;
4167
4586
  /**
4168
- * Chart type to fields mapping
4169
- * Each chart type maps to comma-separated list of visible fields
4587
+ * Properties grouped for select field with [group]="true"
4588
+ * Structure: [{ label: 'Projects', items: [{ name, key }, ...] }, ...]
4589
+ * Uses selectorName for display (e.g., "Projects" instead of "Level")
4170
4590
  */
4171
- private readonly chartTypeFieldsMap;
4172
- /** Computed fields to show based on chart type */
4173
- readonly fieldsToShow: _angular_core.Signal<string>;
4174
- /** Check if a field should be shown */
4175
- shouldShowField(fieldName: string): boolean;
4176
- /** Position options */
4177
- readonly positionOptions: {
4178
- label: string;
4179
- value: string;
4180
- }[];
4181
- /** Legend position options */
4182
- readonly legendPositionOptions: {
4183
- label: string;
4184
- value: string;
4185
- }[];
4186
- /** Legend icon type options */
4187
- readonly legendIconOptions: {
4188
- label: string;
4189
- value: string;
4190
- }[];
4191
- /** Label position options */
4192
- readonly labelPositionOptions: {
4193
- label: string;
4194
- value: string;
4195
- }[];
4196
- /** Map options */
4197
- readonly mapOptions: {
4198
- label: string;
4199
- value: string;
4200
- }[];
4201
- /** Order type options */
4202
- readonly orderTypeOptions: {
4203
- label: string;
4204
- value: string;
4205
- }[];
4206
- /** Order operation options */
4207
- readonly orderOperationOptions: {
4208
- label: string;
4209
- value: string;
4210
- }[];
4211
- /** Border options for props config */
4212
- readonly borderOptions: {
4213
- label: string;
4214
- value: string;
4215
- }[];
4216
- /** Color condition type options */
4217
- readonly colorConditionTypeOptions: {
4218
- label: string;
4219
- value: string;
4220
- }[];
4221
- /** Format type options */
4222
- readonly formatTypeOptions: ({
4223
- label: string;
4224
- value: null;
4225
- } | {
4226
- label: string;
4227
- value: string;
4228
- })[];
4229
- /** Format X-Axis type options */
4230
- readonly formatXAxisTypeOptions: ({
4231
- label: string;
4232
- value: null;
4233
- } | {
4591
+ readonly propertiesGrouped: _angular_core.Signal<{
4234
4592
  label: string;
4235
- value: string;
4236
- })[];
4237
- /** Default color palette */
4238
- readonly defaultColorPalette: string[];
4239
- /** Current style config */
4240
- readonly styleConfig: _angular_core.Signal<StyleConfig>;
4241
- /** Current config as type */
4242
- readonly configAsType: _angular_core.Signal<{
4243
- [key: string]: any;
4244
- icon?: string;
4245
- breadcrumb?: any[];
4246
- }>;
4247
- /** Current card info */
4248
- readonly cardInfo: _angular_core.Signal<CardInfoConfig>;
4249
- /** Current header card config */
4250
- readonly headerCardConfig: _angular_core.Signal<HeaderCardConfig>;
4251
- /** Current card style config */
4252
- readonly cardStyleConfig: _angular_core.Signal<CardStyleConfig>;
4253
- /** Current label config */
4254
- readonly labelConfig: _angular_core.Signal<{
4255
- show?: boolean;
4256
- showTotalInTop?: boolean;
4257
- position?: string;
4258
- }>;
4259
- /** Current legend config */
4260
- readonly legendConfig: _angular_core.Signal<{
4261
- show?: boolean;
4262
- position?: string;
4263
- iconType?: string;
4264
- }>;
4265
- /** Current label center config */
4266
- readonly labelCenterConfig: _angular_core.Signal<LabelCenterConfig>;
4267
- /** Current sort data bars config */
4268
- readonly sortDataBarsConfig: _angular_core.Signal<SortDataBarsConfig>;
4269
- /** Current override labels */
4270
- readonly overrideLabels: _angular_core.Signal<OverrideLabel[]>;
4271
- /** Current default colors */
4272
- readonly defaultColors: _angular_core.Signal<string[]>;
4273
- /** Current order config */
4274
- readonly orderConfig: _angular_core.Signal<any>;
4275
- /** Current format config */
4276
- readonly formatConfig: _angular_core.Signal<FormatConfig>;
4277
- /** Current table format config */
4278
- readonly tableFormatConfig: _angular_core.Signal<TableFormatConfig>;
4279
- /** Current color by condition */
4280
- readonly colorByCondition: _angular_core.Signal<ColorConditionsByIndex>;
4281
- /** Current ring gauge config */
4282
- readonly ringGaugeConfig: _angular_core.Signal<RingGaugeConfig>;
4283
- /** Current card list config */
4284
- readonly cardListConfig: _angular_core.Signal<CardListConfig>;
4285
- /** Props config as index */
4286
- readonly propsConfigAsIndex: _angular_core.Signal<PropsConfigAsIndexItem[]>;
4287
- /** Property translations map */
4288
- readonly propertyTranslations: _angular_core.Signal<PropertyTranslationsMap>;
4289
- /** Property colors map */
4290
- readonly propertyColors: _angular_core.Signal<PropertyColorsMap>;
4291
- /** Format X-Axis config */
4292
- readonly formatXAxisConfig: _angular_core.Signal<FormatXAxisConfig>;
4293
- /** Table columns config (extra column from lookup) */
4294
- readonly tableColumnsConfig: _angular_core.Signal<ExtraColumnFromLookupConfig>;
4295
- /** Timeline header colors config (single object for old format) */
4296
- readonly timelineHeaderColorsSingle: _angular_core.Signal<TimelineHeaderSingleConfig>;
4297
- /** Toggle association */
4298
- readonly toggleAssociation: _angular_core.Signal<boolean>;
4299
- /** Selected properties resolved from input or config */
4300
- readonly resolvedSelectedProperties: _angular_core.Signal<any[]>;
4301
- /** Available properties resolved from input or selected properties */
4302
- readonly resolvedAvailableProperties: _angular_core.Signal<any[]>;
4303
- /** Available properties as options */
4304
- readonly propertyOptions: _angular_core.Signal<{
4305
- label: any;
4306
- value: any;
4307
- }[]>;
4308
- /** Available translation options (exclude used) */
4309
- readonly availableTranslationOptions: _angular_core.Signal<{
4310
- label: any;
4311
- value: any;
4312
- }[]>;
4313
- /** Available color options (exclude used) */
4314
- readonly availableColorOptions: _angular_core.Signal<{
4315
- label: any;
4316
- value: any;
4317
- }[]>;
4318
- /** All property options (full list) */
4319
- readonly allPropertyKeyOptions: _angular_core.Signal<{
4320
- label: any;
4321
- value: any;
4593
+ items: IProperty[];
4322
4594
  }[]>;
4323
- /** Ring gauge hidden properties options */
4324
- readonly ringGaugeHiddenOptions: _angular_core.Signal<{
4325
- label: any;
4326
- value: any;
4595
+ /**
4596
+ * Selection modules for source link configuration
4597
+ * Built from selections with their loaded module info
4598
+ */
4599
+ readonly selectionModules: _angular_core.Signal<SelectionModule[]>;
4600
+ /** Query component type based on chart type and component name */
4601
+ readonly queryComponentType: _angular_core.Signal<QueryComponentType>;
4602
+ /** Loading states */
4603
+ readonly loadingProperties: _angular_core.WritableSignal<boolean>;
4604
+ /** Tab state: 'selection' or 'customApi' */
4605
+ readonly activeTab: _angular_core.WritableSignal<"selection" | "customApi">;
4606
+ /** Tab options for display */
4607
+ readonly tabOptions: {
4608
+ id: string;
4609
+ label: string;
4610
+ }[];
4611
+ /** Custom API configuration */
4612
+ readonly customApi: _angular_core.WritableSignal<CustomApi | null>;
4613
+ /** Internal selections state */
4614
+ readonly selections: _angular_core.WritableSignal<ISelection[]>;
4615
+ readonly sourceLinks: _angular_core.WritableSignal<SourceLink[]>;
4616
+ readonly query: _angular_core.WritableSignal<any>;
4617
+ readonly isNormalized: _angular_core.WritableSignal<boolean>;
4618
+ readonly groupByMultiple: _angular_core.WritableSignal<string[]>;
4619
+ /** Repeater dashboard selection */
4620
+ readonly repeaterDashboardId: _angular_core.WritableSignal<number | null>;
4621
+ readonly availableDashboards: _angular_core.WritableSignal<{
4622
+ id: number;
4623
+ name: string;
4327
4624
  }[]>;
4328
- /** Update style config property */
4329
- updateStyleConfig(key: keyof StyleConfig | string, value: any): void;
4330
- /** Update configAsType property */
4331
- updateConfigAsType(key: string, value: any): void;
4332
- /** Update nested configAsType property */
4333
- updateNestedConfigAsType(parentKey: string, key: string, value: any): void;
4334
- /** Update header card config */
4335
- updateHeaderCardConfig(key: keyof HeaderCardConfig, value: any): void;
4336
- /** Update legend settings */
4337
- updateLegend(key: string, value: unknown): void;
4338
- /** Update label settings */
4339
- updateLabel(key: string, value: unknown): void;
4340
- /** Update label center config */
4341
- updateLabelCenterConfig(key: string, value: any): void;
4342
- /** Update label center text */
4343
- updateLabelCenterText(lang: 'en' | 'ar', value: string): void;
4344
- /** Update card style config */
4345
- updateCardStyleConfig(key: keyof CardStyleConfig, value: any): void;
4346
- /** Update sort data bars config */
4347
- updateSortDataBarsConfig(key: string, value: any): void;
4348
- /** Update card info config */
4349
- updateCardInfoConfig(key: string, value: any): void;
4350
- /** Update border top visibility */
4351
- updateBorderTopShow(show: boolean): void;
4352
- /** Update border top color */
4353
- updateBorderTopColor(color: string): void;
4354
- /** Update map type */
4355
- updateMapType(value: string): void;
4356
- /** Add a new shadow */
4357
- addShadow(): void;
4358
- /** Remove a shadow */
4359
- removeShadow(index: number): void;
4360
- /** Update a shadow property */
4361
- updateShadow(index: number, key: keyof ShadowConfig, value: any): void;
4362
- /** Add override label */
4363
- addOverrideLabel(): void;
4364
- /** Remove override label */
4365
- removeOverrideLabel(index: number): void;
4366
- /** Update override label */
4367
- updateOverrideLabel(index: number, lang: 'en' | 'ar', value: string): void;
4368
- /** Add a default color */
4369
- addDefaultColor(color: string): void;
4370
- /** Remove a default color */
4371
- removeDefaultColor(index: number): void;
4372
- /** Update a default color */
4373
- updateDefaultColor(index: number, color: string): void;
4374
- trackByIndex(index: number): number;
4375
- /** Update format config */
4376
- updateFormatConfig(key: keyof FormatConfig, value: any): void;
4377
- /** Update table format config */
4378
- updateTableFormatConfig(key: keyof TableFormatConfig, value: any): void;
4379
- /** Update table format sort config */
4380
- updateTableFormatSortConfig(key: 'column' | 'direction', value: string): void;
4381
- /** Reset table format to default */
4382
- resetTableFormat(): void;
4383
- /** Get color condition indexes */
4384
- getColorConditionIndexes(): number[];
4385
- /** Check if a bar index is expanded */
4386
- isColorConditionExpanded(index: number): boolean;
4387
- /** Toggle bar index expansion */
4388
- toggleColorConditionExpanded(index: number): void;
4389
- /** Add bar index for color conditions */
4390
- addColorConditionIndex(): void;
4391
- /** Remove bar index */
4392
- removeColorConditionIndex(index: number): void;
4393
- /** Add condition to bar index */
4394
- addColorCondition(index: number): void;
4395
- /** Remove condition from bar index */
4396
- removeColorCondition(index: number, conditionIndex: number): void;
4397
- /** Update color condition */
4398
- updateColorCondition(index: number, conditionIndex: number, key: keyof ColorCondition, value: any): void;
4399
- /** Update ring gauge config */
4400
- updateRingGaugeConfig(key: keyof RingGaugeConfig, value: any): void;
4401
- /** Update card list hide properties */
4402
- updateCardListHideProperties(properties: string[]): void;
4403
- /** Add props config item */
4404
- addPropsConfigItem(): void;
4405
- /** Remove props config item */
4406
- removePropsConfigItem(index: number): void;
4407
- /** Update props config item */
4408
- updatePropsConfigItem(index: number, key: keyof PropsConfigAsIndexItem, value: any): void;
4409
- /** Update order config field */
4410
- updateOrderConfig(key: keyof OrderConfig, value: any): void;
4411
- /** Add order item */
4412
- addOrderItem(): void;
4413
- /** Remove order item */
4414
- removeOrderItem(index: number): void;
4415
- /** Update order item */
4416
- updateOrderItem(index: number, value: string): void;
4417
- /** Move order item up */
4418
- moveOrderItemUp(index: number): void;
4419
- /** Move order item down */
4420
- moveOrderItemDown(index: number): void;
4421
- /** Get property translation keys */
4422
- getPropertyTranslationKeys(): string[];
4423
- /** Add property translation */
4424
- addPropertyTranslation(propertyKey: string): void;
4425
- /** Remove property translation */
4426
- removePropertyTranslation(propertyKey: string): void;
4427
- /** Update property translation */
4428
- updatePropertyTranslation(propertyKey: string, lang: 'ar' | 'en', value: string): void;
4429
- /** Get property color keys */
4430
- getPropertyColorKeys(): string[];
4431
- /** Add property color */
4432
- addPropertyColor(propertyKey: string): void;
4433
- /** Copy property translations */
4434
- copyPropertyTranslations(): void;
4435
- /** Toggle property translations paste area */
4436
- togglePropertyTranslationsPaste(): void;
4437
- /** Apply pasted property translations */
4438
- applyPropertyTranslationsPaste(): void;
4439
- /** Remove property color */
4440
- removePropertyColor(propertyKey: string): void;
4441
- /** Update property color */
4442
- updatePropertyColor(propertyKey: string, selectedKey: string): void;
4443
- /** Copy property colors */
4444
- copyPropertyColors(): void;
4445
- /** Toggle property colors paste area */
4446
- togglePropertyColorsPaste(): void;
4447
- /** Apply pasted property colors */
4448
- applyPropertyColorsPaste(): void;
4449
- /** Update format X-Axis config */
4450
- updateFormatXAxisConfig(key: keyof FormatXAxisConfig, value: any): void;
4451
- /** Update table columns config */
4452
- updateTableColumnsConfig(key: keyof ExtraColumnFromLookupConfig, value: any): void;
4453
- /** Update timeline header colors (single config) */
4454
- updateTimelineHeaderColorSingle(key: 'bgColor' | 'color', value: string): void;
4455
- /** Update toggle association */
4456
- updateToggleAssociation(value: boolean): void;
4457
- /** Selected property for adding translations */
4458
- readonly selectedPropertyForTranslation: _angular_core.WritableSignal<string>;
4459
- /** Selected property for adding colors */
4460
- readonly selectedPropertyForColor: _angular_core.WritableSignal<string>;
4461
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<DisplaySettings, never>;
4462
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<DisplaySettings, "mt-display-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "chartType": { "alias": "chartType"; "required": false; "isSignal": true; }; "availableProperties": { "alias": "availableProperties"; "required": false; "isSignal": true; }; "selectedProperties": { "alias": "selectedProperties"; "required": false; "isSignal": true; }; "lookups": { "alias": "lookups"; "required": false; "isSignal": true; }; }, { "clientConfigChange": "clientConfigChange"; }, never, never, true, never>;
4625
+ /** Show source links when multiple selections exist */
4626
+ readonly showSourceLinks: _angular_core.Signal<boolean>;
4627
+ /** Hide selection config for layout, snapshot, phaseGate types (they don't need data source selection) */
4628
+ readonly hideSelectionConfig: _angular_core.Signal<boolean>;
4629
+ /** Show groupByMultiple for table queries (non-report mode) */
4630
+ readonly showGroupByMultiple: _angular_core.Signal<boolean>;
4631
+ /**
4632
+ * Derived signal: Extract module keys from selections for change detection
4633
+ * Only changes when actual selectors change, not on every selection update
4634
+ */
4635
+ private readonly moduleKeysSignature;
4636
+ /** Track last loaded module signature to prevent duplicate requests */
4637
+ private lastLoadedSignature;
4638
+ constructor();
4639
+ /**
4640
+ * Load properties for all selections using bulk API
4641
+ * Single POST request to /metadata/modules/properties
4642
+ * Enriches response with selectorName from tree data
4643
+ */
4644
+ loadPropertiesForSelections(selections: ISelection[]): void;
4645
+ /**
4646
+ * Handle selection changes
4647
+ */
4648
+ onSelectionsChange(selections: ISelection[]): void;
4649
+ /**
4650
+ * Handle module change - update selections, effect handles property loading
4651
+ */
4652
+ onModuleChange(event: {
4653
+ selectionId: number;
4654
+ selector: string;
4655
+ selectorName?: string | null;
4656
+ }): void;
4657
+ /**
4658
+ * Extract module type from selector (e.g., "Level:7" -> "Level")
4659
+ */
4660
+ private extractModuleTypeFromSelector;
4661
+ /**
4662
+ * Handle source links change
4663
+ */
4664
+ onSourceLinksChange(links: SourceLink[]): void;
4665
+ /**
4666
+ * Handle query change (general query)
4667
+ */
4668
+ onQueryChange(query: ChartQuery): void;
4669
+ /**
4670
+ * Handle table query change
4671
+ */
4672
+ onTableQueryChange(query: TableQuery): void;
4673
+ /**
4674
+ * Handle timeline query change
4675
+ */
4676
+ onTimelineQueryChange(query: any): void;
4677
+ /**
4678
+ * Handle map query change
4679
+ */
4680
+ onMapQueryChange(query: any): void;
4681
+ /**
4682
+ * Handle splitter query change
4683
+ */
4684
+ onSplitterQueryChange(query: any): void;
4685
+ /**
4686
+ * Handle properties query change
4687
+ */
4688
+ onPropertiesQueryChange(query: any): void;
4689
+ /**
4690
+ * Handle snapshot query change
4691
+ */
4692
+ onSnapshotQueryChange(query: any): void;
4693
+ /**
4694
+ * Handle groupByMultiple change
4695
+ */
4696
+ onGroupByMultipleChange(values: string[]): void;
4697
+ /**
4698
+ * Handle repeater dashboard selection
4699
+ */
4700
+ onRepeaterDashboardChange(dashboardId: number): void;
4701
+ /**
4702
+ * Handle isNormalized change
4703
+ */
4704
+ onIsNormalizedChange(value: boolean): void;
4705
+ /**
4706
+ * Handle tab change
4707
+ */
4708
+ onTabChange(tabId: string): void;
4709
+ /**
4710
+ * Handle custom API change
4711
+ */
4712
+ onCustomApiChange(customApi: CustomApi | null): void;
4713
+ /**
4714
+ * Get chart type id for query component
4715
+ */
4716
+ getChartTypeId(): string;
4717
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataSourceSettings, never>;
4718
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataSourceSettings, "mt-data-source-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "chartType": { "alias": "chartType"; "required": false; "isSignal": true; }; }, { "serviceConfigChange": "serviceConfigChange"; }, never, never, true, never>;
4463
4719
  }
4464
4720
 
4465
4721
  /** Action type option */
@@ -4573,10 +4829,6 @@ declare class ActionsSettings {
4573
4829
  /**
4574
4830
  * Track by action id for ngFor
4575
4831
  */
4576
- trackByActionId(_index: number, action: ActionConfig): string;
4577
- /**
4578
- * Track by index helper
4579
- */
4580
4832
  trackByIndex(index: number): number;
4581
4833
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<ActionsSettings, never>;
4582
4834
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<ActionsSettings, "mt-actions-settings", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; }, { "clientConfigChange": "clientConfigChange"; }, never, never, true, never>;
@@ -4630,5 +4882,5 @@ declare class GetChartActionsPipe implements PipeTransform {
4630
4882
  */
4631
4883
  declare function cloneDeep<T>(obj: T): T;
4632
4884
 
4633
- export { ActionsSettings, BarChartHandler, BarControlUi, CHART_TYPES, CardContentComponent, CardFilterComponent, ChartCardComponent, ChartDataService, ChartSettingsDrawer, ChartViewer, ComparisonChartHandler, DashboardBuilder, DashboardBuilderService, DashboardItem, DashboardItemStoreService, DashboardList, DashboardStoreService, DashboardViewer, DataSourceSettings, DefaultControlUi, DisplaySettings, DynamicFiltersConfig, EChartComponent, EntityInfoComponent, EntityPreviewCardComponent, FilterByGroupPipe, GaugeChartHandler, GeneralSettings, GetChartActionsPipe, HTTPMethod, HeaderCardComponent, LevelCardHandler, LevelCardListComponent, LineChartHandler, ListStatisticCardComponent, ManageBreadcrumb, ManageFilterOnPage, ManageItem, ManageItemService, ManagePages, MapChartHandler, OverviewCardHandler, PhaseGateStepperHandler, PieChartHandler, PieControlUi, RingGaugeChartHandler, SPlusChartHandler, SkeletonCardComponent, SnapshotHandler, SplitterChartHandler, StackBarChartHandler, StackBarControlUi, StatisticCardComponent, TableCardComponent, TableViewHandler, TimelineHandler, addCommasToNumber, axisFormatters, cloneDeep, createAxisFormatter, createTooltipFormatter, dynamicReorder, dynamicTextReplace, formatCurrency, formatDate, formatNumber, formatPercentage, formatValue, formatWordsUnderBar, generalConfiguration, getColorFromConditions, getLanguageCode, getLocalizedTitle, getNestedData, groupDatesByYearAndMonth, handleFilterForCard, handleFilterForSnapshot, handleFiltersForCustom, isMobilePlatform, sortChartData, sortDataTableView, switchAllKeysSmall, switchAllKeysToLower };
4634
- export type { ActionConfig, ApiResponse, BarChartData, BreadcrumbItem, BulkLinkChartRequest, BulkLinkChartResponse, BulkPropertiesRequest, BulkPropertiesResponse, BulkPropertiesResponseItem, BulkPropertyRequestItem, CardBorderStyleConfig, CardStyleConfig$1 as CardStyleConfig, ChartActionEvent, ChartActionsContext, ChartData, ChartDataHandled, ChartLabel, ChartLinkConfiguration, ChartTypeConfig, ClientConfig, ComponentType, CustomApi, DashboardBuilderData, DashboardChartItem, DashboardDialogItem, DashboardItemStore, DashboardListEvent, DashboardPage, DisplayConfig, EChartSeriesItem, ExcelSheet, FilterConfig, FilterOption, GroupedModuleOption, HandleAction, HeaderCardConfig$1 as HeaderCardConfig, IModule, IModuleType, IProperty, IPropertyWithGroup, ISelection, ItemConfig, LevelCardData, LevelCardProperty, LinkChartRequest, LocalizedName, ModuleItem, ModuleSelectOption, ModuleType, ModuleValue, ModulesTreeRequest, ModulesTreeResponse, PhaseGateProperty, PhaseGateStep, PieChartData, PropertiesResponse, PropertyItem$1 as PropertyItem, PropertyItemOption, PropertyItemsResponse, QuickManageType, Report, ReportChartLink, ReportDashboardConfig, ReportExcelConfig, ReportType, ReportUrl, RequestType, SelectionFilter, ServiceConfig, ServiceItem, SourceLink, StatisticCardData, StyleConfig, TableColumn$1 as TableColumn, TableViewData, TimelineData, TimelineItem, UnlinkChartRequest };
4885
+ export { ActionsSettings, BarChartHandler, BarControlUi, CHART_TYPES, CardContentComponent, CardFilterComponent, CardInfoComponent, ChartCardComponent, ChartDataService, ChartSettingsDrawer, ChartViewer, ComparisonChartHandler, DashboardBuilder, DashboardBuilderService, DashboardItem, DashboardItemStoreService, DashboardList, DashboardStoreService, DashboardViewer, DataSourceSettings, DefaultControlUi, DisplaySettings, DynamicFiltersComponent, DynamicFiltersConfig, EChartComponent, EntityInfoComponent, EntityPreviewCardComponent, FilterByGroupPipe, GaugeChartHandler, GeneralSettings, GetChartActionsPipe, HTTPMethod, HeaderCardComponent, LevelCardHandler, LevelCardListComponent, LineChartHandler, ListStatisticCardComponent, ManageBreadcrumb, ManageFilterOnPage, ManageItem, ManageItemService, ManagePages, MapChartHandler, OverviewCardHandler, PhaseGateStepperHandler, PieChartHandler, PieControlUi, RingGaugeChartHandler, SPlusChartHandler, SkeletonCardComponent, SnapshotHandler, SplitterChartHandler, StackBarChartHandler, StackBarControlUi, StaticFiltersComponent, StatisticCardComponent, TableCardComponent, TableViewHandler, TimelineHandler, addCommasToNumber, axisFormatters, cloneDeep, createAxisFormatter, createTooltipFormatter, dynamicReorder, dynamicTextReplace, formatCurrency, formatDate, formatNumber, formatPercentage, formatValue, formatWordsUnderBar, formatXAxis, generalConfiguration, getColorFromConditions, getLanguageCode, getLocalizedTitle, getNestedData, groupDatesByYearAndMonth, handleFilterForCard, handleFilterForSnapshot, handleFiltersForCustom, isMobilePlatform, sortChartData, sortDataTableView, switchAllKeysSmall, switchAllKeysToLower };
4886
+ export type { ActionConfig, ApiResponse, BarChartData, BreadcrumbItem, BulkLinkChartRequest, BulkLinkChartResponse, BulkPropertiesRequest, BulkPropertiesResponse, BulkPropertiesResponseItem, BulkPropertyRequestItem, CardBorderStyleConfig, CardInfoConfig$1 as CardInfoConfig, CardStyleConfig$1 as CardStyleConfig, ChartActionEvent, ChartActionsContext, ChartData, ChartDataHandled, ChartLabel, ChartLinkConfiguration, ChartTypeConfig, ClientConfig, ComponentType, CustomApi, DashboardBuilderData, DashboardChartItem, DashboardDialogItem, DashboardItemStore, DashboardListEvent, DashboardPage, DisplayConfig, EChartSeriesItem, ExcelSheet, FilterConfig, FilterOption, FormatXAxisConfig$1 as FormatXAxisConfig, GroupedModuleOption, HandleAction, HeaderCardConfig$1 as HeaderCardConfig, IModule, IModuleType, IProperty, IPropertyWithGroup, ISelection, ItemConfig, LevelCardData, LevelCardProperty, LinkChartRequest, LocalizedName, ModuleItem, ModuleSelectOption, ModuleType, ModuleValue, ModulesTreeRequest, ModulesTreeResponse, PhaseGateProperty, PhaseGateStep, PieChartData, PropertiesResponse, PropertyItem$1 as PropertyItem, PropertyItemOption, PropertyItemsResponse, QuickManageType, Report, ReportChartLink, ReportDashboardConfig, ReportExcelConfig, ReportType, ReportUrl, RequestType, SelectionFilter, ServiceConfig, ServiceItem, SourceLink, StaticFilterConfig, StaticFilterItem, StatisticCardData, StyleConfig, TableColumn$1 as TableColumn, TableViewData, TimelineData, TimelineItem, UnlinkChartRequest };