@masterteam/dashboard-builder 0.0.68 → 0.0.70

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.
@@ -4,6 +4,7 @@ import * as i1$1 from '@angular/common';
4
4
  import { CommonModule, DatePipe, isPlatformBrowser, DecimalPipe } from '@angular/common';
5
5
  import * as i1 from '@angular/forms';
6
6
  import { FormsModule, NG_VALUE_ACCESSOR, FormBuilder, Validators, ReactiveFormsModule, NG_VALIDATORS, FormRecord, FormControl, FormGroup } from '@angular/forms';
7
+ import { ActivatedRoute, Router } from '@angular/router';
7
8
  import { TranslocoService, TranslocoDirective } from '@jsverse/transloco';
8
9
  import * as i2$3 from 'angular-gridster2';
9
10
  import { DirTypes, GridsterModule } from 'angular-gridster2';
@@ -17,7 +18,6 @@ import { Subject, map, of, forkJoin, throwError, Observable, ReplaySubject, EMPT
17
18
  import { HttpClient, HttpContext, HttpHeaders, HttpParams } from '@angular/common/http';
18
19
  import { catchError, tap, shareReplay, share, mergeMap, takeUntil, retry, finalize, filter, map as map$1, distinctUntilChanged, switchMap, debounceTime as debounceTime$1 } from 'rxjs/operators';
19
20
  import { REQUEST_CONTEXT } from '@masterteam/components';
20
- import { ActivatedRoute, Router } from '@angular/router';
21
21
  import { TextField } from '@masterteam/components/text-field';
22
22
  import { CheckboxField } from '@masterteam/components/checkbox-field';
23
23
  import { ModalRef } from '@masterteam/components/dialog';
@@ -2325,7 +2325,9 @@ const CHART_CAPABILITIES = [
2325
2325
  id: 'chart-map-chart',
2326
2326
  name: 'Map Chart',
2327
2327
  icon: 'map.globe-01',
2328
- category: 'table',
2328
+ // Grouped under Charts, not Tables: `category` only drives the palette tab
2329
+ // and a map is not something a user looks for under "Tables" (issue #1248).
2330
+ category: 'chart',
2329
2331
  products: ['pplus', 'splus'],
2330
2332
  hasManageItem: true,
2331
2333
  defaultSize: { cols: 18, rows: 8 },
@@ -3527,6 +3529,44 @@ function normalizeBeforeRequest(serviceConfig) {
3527
3529
  return next;
3528
3530
  }
3529
3531
 
3532
+ /**
3533
+ * A boolean's two values are not modelled by the property-items API, so they
3534
+ * are synthesized locally instead of requesting them (issue #1237).
3535
+ */
3536
+ const CHECKBOX_VIEW_TYPES = new Set(['checkbox', 'boolean', 'bool']);
3537
+ /**
3538
+ * View types that definitively have no fixed value list. Requesting
3539
+ * `property-items/{key}` for one can only fail, so we skip the call.
3540
+ *
3541
+ * Deliberately a DENY-list: any view type not named here still goes to the API
3542
+ * exactly as before, so an unfamiliar (or newly added) list-bearing type keeps
3543
+ * working rather than silently losing its Values tab.
3544
+ */
3545
+ const NO_VALUE_LIST_VIEW_TYPES = new Set([
3546
+ 'text',
3547
+ 'longtext',
3548
+ 'title',
3549
+ 'number',
3550
+ 'float',
3551
+ 'decimal',
3552
+ 'currency',
3553
+ 'percentage',
3554
+ 'date',
3555
+ 'datetime',
3556
+ 'time',
3557
+ 'user',
3558
+ 'multiuser',
3559
+ 'attachment',
3560
+ 'location',
3561
+ 'formula',
3562
+ 'calculated',
3563
+ ]);
3564
+ /** Normalize a catalog viewType for comparison ("Request_Status" → "request_status"). */
3565
+ function normalizeViewType(value) {
3566
+ return String(value ?? '')
3567
+ .trim()
3568
+ .toLowerCase();
3569
+ }
3530
3570
  /**
3531
3571
  * Filter Value Field Component
3532
3572
  *
@@ -3535,6 +3575,7 @@ function normalizeBeforeRequest(serviceConfig) {
3535
3575
  */
3536
3576
  class FilterValueField {
3537
3577
  dashboardService = inject(DashboardBuilderService);
3578
+ transloco = inject(TranslocoService);
3538
3579
  popover;
3539
3580
  /** Label for the field */
3540
3581
  label = input('', ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
@@ -3674,11 +3715,14 @@ class FilterValueField {
3674
3715
  }
3675
3716
  });
3676
3717
  });
3677
- // Fetch the targeted property's selectable values (lookup/status) and
3678
- // surface them as the "Values" tab. Lazy + cached per key; properties with
3679
- // no fixed value list simply yield no tab.
3718
+ // Resolve the targeted property's selectable values into the "Values" tab.
3719
+ // Lazy + cached per key; properties with no fixed value list yield no tab.
3720
+ // Reads `propertyOptions()` so the view type is re-evaluated once module
3721
+ // metadata arrives (it is usually empty on the first pass).
3680
3722
  effect(() => {
3681
3723
  const key = this.propertyKey();
3724
+ this.propertyOptions();
3725
+ this.extraProperties();
3682
3726
  if (key)
3683
3727
  untracked(() => this.loadPropertyValues(key));
3684
3728
  });
@@ -3722,10 +3766,44 @@ class FilterValueField {
3722
3766
  buildExtraValuePath(propertyKey) {
3723
3767
  return `extraValues.${propertyKey.charAt(0).toLowerCase()}${propertyKey.slice(1)}.rawValue`;
3724
3768
  }
3725
- /** Lazily load a property's value list into the "Values" tab. */
3769
+ /**
3770
+ * Where a property's selectable values come from (issue #1237).
3771
+ *
3772
+ * - `checkbox` — a boolean has exactly two values and the backend does not
3773
+ * model them, so the list is synthesized locally. Asking
3774
+ * `property-items/{key}` for a Checkbox is what surfaced an error in the
3775
+ * picker.
3776
+ * - `none` — text, number, date, user, …: no fixed value list exists,
3777
+ * so no request is made at all (it could only ever fail).
3778
+ * - `remote` — everything else (lookup / status / phase-gate, and any view
3779
+ * type we do not recognise): fetch from the API, exactly as before.
3780
+ */
3781
+ resolvePropertyValueSource(propertyKey) {
3782
+ const viewType = normalizeViewType(this.findPropertyReference(propertyKey)?.viewType);
3783
+ if (!viewType)
3784
+ return 'remote';
3785
+ if (CHECKBOX_VIEW_TYPES.has(viewType))
3786
+ return 'checkbox';
3787
+ return NO_VALUE_LIST_VIEW_TYPES.has(viewType) ? 'none' : 'remote';
3788
+ }
3789
+ /** Lazily resolve a property's value list into the "Values" tab. */
3726
3790
  loadPropertyValues(propertyKey) {
3727
3791
  if (this.fetchedValueKeys.has(propertyKey))
3728
3792
  return;
3793
+ const source = this.resolvePropertyValueSource(propertyKey);
3794
+ if (source === 'none') {
3795
+ this.fetchedValueKeys.add(propertyKey);
3796
+ this.setPropertyValueOptions([]);
3797
+ return;
3798
+ }
3799
+ if (source === 'checkbox') {
3800
+ this.fetchedValueKeys.add(propertyKey);
3801
+ this.setPropertyValueOptions([
3802
+ { label: this.translateOrFallback('yes', 'Yes'), value: 'true' },
3803
+ { label: this.translateOrFallback('no', 'No'), value: 'false' },
3804
+ ]);
3805
+ return;
3806
+ }
3729
3807
  this.fetchedValueKeys.add(propertyKey);
3730
3808
  this.valuesLoading.set(true);
3731
3809
  this.dashboardService.getPropertyItems(propertyKey).subscribe({
@@ -3749,6 +3827,18 @@ class FilterValueField {
3749
3827
  },
3750
3828
  });
3751
3829
  }
3830
+ /** Publish the Values-tab options and re-derive which tabs are visible. */
3831
+ setPropertyValueOptions(values) {
3832
+ this.quickOptions.update((opts) => ({ ...opts, values }));
3833
+ this.valuesLoading.set(false);
3834
+ this.updateVisibleTabs();
3835
+ }
3836
+ /** Translate a `dashboardBuilder.*` key, falling back when it is missing. */
3837
+ translateOrFallback(key, fallback) {
3838
+ const path = `dashboardBuilder.${key}`;
3839
+ const translated = this.transloco.translate(path);
3840
+ return !translated || translated === path ? fallback : translated;
3841
+ }
3752
3842
  updateVisibleTabs() {
3753
3843
  const opts = this.quickOptions();
3754
3844
  // "Values" leads when present — picking a concrete value is the primary
@@ -22364,7 +22454,7 @@ class ActionService {
22364
22454
  dialogConfig?.clientConfig?.title?.['ar'] ||
22365
22455
  '';
22366
22456
  // Dynamically import DashboardDialogComponent to avoid circular dependency
22367
- import('./masterteam-dashboard-builder-dashboard-dialog.component-XUArffz3.mjs').then(({ DashboardDialogComponent }) => {
22457
+ import('./masterteam-dashboard-builder-dashboard-dialog.component-BKYVka5Y.mjs').then(({ DashboardDialogComponent }) => {
22368
22458
  // Open dialog using ModalService
22369
22459
  this.modalService.openModal(DashboardDialogComponent, 'dialog', {
22370
22460
  header: title,
@@ -24250,7 +24340,7 @@ class PageFilterSidebar {
24250
24340
  return typeof document !== 'undefined' && document.dir === 'rtl';
24251
24341
  }
24252
24342
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: PageFilterSidebar, deps: [], target: i0.ɵɵFactoryTarget.Component });
24253
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: PageFilterSidebar, isStandalone: true, selector: "mt-page-filter-sidebar", inputs: { filters: { classPropertyName: "filters", publicName: "filters", isSignal: true, isRequired: false, transformFunction: null }, initialValues: { classPropertyName: "initialValues", publicName: "initialValues", isSignal: true, isRequired: false, transformFunction: null }, reportId: { classPropertyName: "reportId", publicName: "reportId", isSignal: true, isRequired: false, transformFunction: null }, suppressedDefaultKeys: { classPropertyName: "suppressedDefaultKeys", publicName: "suppressedDefaultKeys", isSignal: true, isRequired: false, transformFunction: null }, showHeader: { classPropertyName: "showHeader", publicName: "showHeader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filtersApplied: "filtersApplied", filtersCleared: "filtersCleared", closeRequested: "closeRequested" }, ngImport: i0, template: "<div\r\n class=\"mt-page-filter-sidebar flex h-full min-h-0 flex-col\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\r\n>\r\n @if (showHeader()) {\r\n <header\r\n class=\"flex items-center gap-2 border-b border-surface-200 px-4 py-3\"\r\n >\r\n <mt-icon icon=\"general.filter-funnel-01\" class=\"text-primary-600\" />\r\n <h4 class=\"min-w-0 flex-1 text-sm font-semibold text-surface-700\">\r\n {{ t(\"filters\") }}\r\n </h4>\r\n <mt-button\r\n icon=\"general.x-close\"\r\n variant=\"text\"\r\n severity=\"secondary\"\r\n size=\"small\"\r\n [tooltip]=\"t('close')\"\r\n (click)=\"closeRequested.emit()\"\r\n />\r\n </header>\r\n }\r\n\r\n <div class=\"min-h-0 flex-1 overflow-y-auto px-4 py-4\" [formGroup]=\"form\">\r\n @for (field of filters(); track $index) {\r\n @if (field.type === \"section\") {\r\n <h5 class=\"mt-2 mb-2 text-xs font-semibold uppercase text-muted-color\">\r\n {{ label(field) }}\r\n </h5>\r\n } @else if (field.type === \"separator\") {\r\n <hr class=\"my-3 border-surface-200\" />\r\n } @else if (isInput(field)) {\r\n <div class=\"mb-3\">\r\n @switch (true) {\r\n @case (field.type === \"date\") {\r\n <mt-date-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [showClear]=\"true\"\r\n />\r\n }\r\n @case (field.type === \"user\") {\r\n <mt-user-search-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [apiUrl]=\"userApiUrl\"\r\n [isMultiple]=\"isMulti(field)\"\r\n />\r\n }\r\n @case (isMulti(field)) {\r\n <mt-multi-select-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [options]=\"optionsFor(field)\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"true\"\r\n [placeholder]=\"t('selectProperty')\"\r\n />\r\n }\r\n @default {\r\n <mt-select-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [options]=\"optionsFor(field)\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"true\"\r\n [showClear]=\"!field.configuration?.isRequird\"\r\n [placeholder]=\"t('selectProperty')\"\r\n />\r\n }\r\n }\r\n </div>\r\n }\r\n }\r\n\r\n @if (filters().length === 0) {\r\n <div class=\"py-8 text-center text-sm text-muted-color\">\r\n {{ t(\"noFiltersConfigured\") }}\r\n </div>\r\n }\r\n </div>\r\n\r\n <footer\r\n class=\"flex items-center justify-end gap-2 border-t border-surface-200 px-4 py-3\"\r\n >\r\n <mt-button\r\n [label]=\"t('clear')\"\r\n variant=\"outlined\"\r\n severity=\"secondary\"\r\n size=\"small\"\r\n (click)=\"clear()\"\r\n />\r\n <mt-button\r\n [label]=\"t('apply')\"\r\n icon=\"general.check\"\r\n size=\"small\"\r\n (click)=\"apply()\"\r\n />\r\n </footer>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }, { kind: "component", type: SelectField, selector: "mt-select-field", inputs: ["field", "hint", "label", "placeholder", "hasPlaceholderPrefix", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "clearAfterSelect", "required", "group", "size", "optionGroupLabel", "optionGroupChildren", "loading", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape", "markCurrentUser"], outputs: ["onChange"] }, { kind: "component", type: MultiSelectField, selector: "mt-multi-select-field", inputs: ["field", "label", "placeholder", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "display", "required", "maxSelectedLabels", "group", "virtualScroll", "virtualScrollItemSize", "optionGroupLabel", "optionGroupChildren", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape"], outputs: ["onChange"] }, { kind: "component", type: DateField, selector: "mt-date-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "showIcon", "showOnFocus", "showClear", "showTime", "minDate", "maxDate", "pInputs", "required"] }, { kind: "component", type: UserSearchField, selector: "mt-user-search-field", inputs: ["hint", "hideUnlinkedHint", "label", "placeholder", "class", "readonly", "required", "isMultiple", "apiUrl", "dataKey", "paramName", "context", "size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
24343
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: PageFilterSidebar, isStandalone: true, selector: "mt-page-filter-sidebar", inputs: { filters: { classPropertyName: "filters", publicName: "filters", isSignal: true, isRequired: false, transformFunction: null }, initialValues: { classPropertyName: "initialValues", publicName: "initialValues", isSignal: true, isRequired: false, transformFunction: null }, reportId: { classPropertyName: "reportId", publicName: "reportId", isSignal: true, isRequired: false, transformFunction: null }, suppressedDefaultKeys: { classPropertyName: "suppressedDefaultKeys", publicName: "suppressedDefaultKeys", isSignal: true, isRequired: false, transformFunction: null }, showHeader: { classPropertyName: "showHeader", publicName: "showHeader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filtersApplied: "filtersApplied", filtersCleared: "filtersCleared", closeRequested: "closeRequested" }, ngImport: i0, template: "<div\r\n class=\"mt-page-filter-sidebar flex h-full min-h-0 flex-col\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\r\n>\r\n @if (showHeader()) {\r\n <header\r\n class=\"flex items-center gap-2 border-b border-surface-200 px-4 py-3\"\r\n >\r\n <mt-icon icon=\"general.filter-funnel-01\" class=\"text-primary-600\" />\r\n <h4 class=\"min-w-0 flex-1 text-sm font-semibold text-surface-700\">\r\n {{ t(\"filters\") }}\r\n </h4>\r\n <mt-button\r\n icon=\"general.x-close\"\r\n variant=\"text\"\r\n severity=\"secondary\"\r\n size=\"small\"\r\n [tooltip]=\"t('close')\"\r\n (click)=\"closeRequested.emit()\"\r\n />\r\n </header>\r\n }\r\n\r\n <div class=\"min-h-0 flex-1 overflow-y-auto px-4 py-4\" [formGroup]=\"form\">\r\n @for (field of filters(); track $index) {\r\n @if (field.type === \"section\") {\r\n <h5 class=\"mt-2 mb-2 text-xs font-semibold uppercase text-muted-color\">\r\n {{ label(field) }}\r\n </h5>\r\n } @else if (field.type === \"separator\") {\r\n <hr class=\"my-3 border-surface-200\" />\r\n } @else if (isInput(field)) {\r\n <div class=\"mb-3\">\r\n @switch (true) {\r\n @case (field.type === \"date\") {\r\n <mt-date-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [showClear]=\"true\"\r\n />\r\n }\r\n @case (field.type === \"user\") {\r\n <mt-user-search-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [apiUrl]=\"userApiUrl\"\r\n [isMultiple]=\"isMulti(field)\"\r\n />\r\n }\r\n @case (isMulti(field)) {\r\n <mt-multi-select-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [options]=\"optionsFor(field)\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"true\"\r\n [placeholder]=\"t('selectProperty')\"\r\n />\r\n }\r\n @default {\r\n <mt-select-field\r\n [label]=\"label(field)\"\r\n [formControlName]=\"field.key\"\r\n [options]=\"optionsFor(field)\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"true\"\r\n [showClear]=\"!field.configuration?.isRequird\"\r\n [placeholder]=\"t('selectProperty')\"\r\n />\r\n }\r\n }\r\n </div>\r\n }\r\n }\r\n\r\n @if (filters().length === 0) {\r\n <div class=\"py-8 text-center text-sm text-muted-color\">\r\n {{ t(\"noFiltersConfigured\") }}\r\n </div>\r\n }\r\n </div>\r\n\r\n <footer\r\n class=\"flex items-center justify-end gap-2 border-t border-surface-200 px-4 py-3\"\r\n >\r\n <mt-button\r\n [label]=\"t('clear')\"\r\n variant=\"outlined\"\r\n severity=\"secondary\"\r\n size=\"small\"\r\n (click)=\"clear()\"\r\n />\r\n <mt-button\r\n [label]=\"t('apply')\"\r\n icon=\"general.check\"\r\n size=\"small\"\r\n (click)=\"apply()\"\r\n />\r\n </footer>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }, { kind: "component", type: SelectField, selector: "mt-select-field", inputs: ["field", "hint", "label", "placeholder", "hasPlaceholderPrefix", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "clearAfterSelect", "required", "group", "size", "optionGroupLabel", "optionGroupChildren", "loading", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape", "markCurrentUser"], outputs: ["onChange"] }, { kind: "component", type: MultiSelectField, selector: "mt-multi-select-field", inputs: ["field", "label", "placeholder", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "display", "required", "maxSelectedLabels", "group", "virtualScroll", "virtualScrollItemSize", "optionGroupLabel", "optionGroupChildren", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape"], outputs: ["onChange"] }, { kind: "component", type: DateField, selector: "mt-date-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "showIcon", "showOnFocus", "showClear", "showTime", "timeOnly", "minDate", "maxDate", "pInputs", "required"] }, { kind: "component", type: UserSearchField, selector: "mt-user-search-field", inputs: ["hint", "hideUnlinkedHint", "label", "placeholder", "class", "readonly", "required", "isMultiple", "apiUrl", "dataKey", "paramName", "minLength", "context", "size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
24254
24344
  }
24255
24345
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: PageFilterSidebar, decorators: [{
24256
24346
  type: Component,
@@ -25990,7 +26080,7 @@ const TIMELINE_ENTITY_VIEW_TYPE_MAP = {
25990
26080
  title: 'Text',
25991
26081
  longtext: 'LongText',
25992
26082
  float: 'Text',
25993
- time: 'Text',
26083
+ time: 'Time',
25994
26084
  date: 'Date',
25995
26085
  datetime: 'DateTime',
25996
26086
  user: 'User',
@@ -28599,7 +28689,7 @@ class TableCardComponent {
28599
28689
  this.onAction.emit({ type: 'clickOnHeader', data: {} });
28600
28690
  }
28601
28691
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: TableCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
28602
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: TableCardComponent, isStandalone: true, selector: "mt-table-card", inputs: { dashboardId: { classPropertyName: "dashboardId", publicName: "dashboardId", isSignal: true, isRequired: true, transformFunction: null }, inGroup: { classPropertyName: "inGroup", publicName: "inGroup", isSignal: true, isRequired: false, transformFunction: null }, hideHeader: { classPropertyName: "hideHeader", publicName: "hideHeader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onAction: "onAction" }, ngImport: i0, template: "<!--\n One legend definition, two possible hosts. `mt-card-content` only projects\n [topEnd] inside its header block, so when the header is hidden (dialog view)\n the legend has to be rendered in the body instead or it is dropped entirely.\n-->\n<ng-template #legendList>\n <div class=\"flex flex-wrap items-center gap-2\">\n @for (label of labels(); track label.key || $index) {\n <div class=\"flex items-center gap-1 text-xs\">\n <span\n class=\"w-2.5 h-2.5 rounded-full\"\n [style.backgroundColor]=\"getLegendColor(label)\"\n ></span>\n <span>{{ getLegendText(label) }}</span>\n </div>\n }\n </div>\n</ng-template>\n\n<mt-card-content\n [inGroup]=\"inGroup()\"\n [showHeader]=\"!hideHeader()\"\n [title]=\"title()\"\n [styleConfig]=\"\n configurationItem()?.clientConfig?.displayConfig?.['StyleConfig']\n \"\n [cardStyleConfig]=\"\n configurationItem()?.clientConfig?.configAsType?.['cardStyleConfig']\n \"\n [headerConfig]=\"\n configurationItem()?.clientConfig?.configAsType?.['headerCardConfig']\n \"\n [padding]=\"configurationItem()?.clientConfig?.configAsType?.['padding']\"\n (headerClick)=\"onHeaderClick()\"\n>\n <!-- Status Labels -->\n <ng-container topEnd>\n @if (hasLegend() && !hideHeader()) {\n <ng-container [ngTemplateOutlet]=\"legendList\" />\n }\n </ng-container>\n\n <ng-container body>\n <div\n class=\"table-wrapper h-full\"\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\n >\n <!-- Headerless (dialog) view: the header's top-end slot does not exist,\n so the legend is rendered above the table instead. -->\n @if (hasLegend() && hideHeader()) {\n <div class=\"mb-2 flex shrink-0 justify-end\">\n <ng-container [ngTemplateOutlet]=\"legendList\" />\n </div>\n }\n\n @if (loading()) {\n <div class=\"flex items-center justify-center h-32\">\n <i class=\"pi pi-spin pi-spinner text-2xl\"></i>\n </div>\n } @else if (hasData()) {\n <div\n class=\"table-scroll-container overflow-auto h-full\"\n (scroll)=\"onTableScroll($event)\"\n >\n <table class=\"w-full border-collapse text-sm\">\n <thead class=\"sticky top-0 z-10\" [hidden]=\"hideSubheader()\">\n <tr>\n <!-- Index column -->\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <th\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200\"\n [style.color]=\"tableStyleConfig()?.thTextColor\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.thBackgroundColor\n \"\n [style.fontWeight]=\"\n tableStyleConfig()?.thFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\n >\n #\n </th>\n }\n\n <!-- Data columns -->\n @for (column of visibleColumns(); track column.key) {\n <th\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200 whitespace-nowrap\"\n [style.minWidth]=\"column.width || 'auto'\"\n [style.color]=\"tableStyleConfig()?.thTextColor\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.thBackgroundColor\n \"\n [style.fontWeight]=\"\n tableStyleConfig()?.thFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\n [class.cursor-pointer]=\"!isPhaseGateColumn(column)\"\n (click)=\"onSort(column)\"\n >\n <div class=\"flex items-center gap-2\">\n <span>{{ column.label }}</span>\n @if (column.isSort) {\n <i\n class=\"text-xs\"\n [class]=\"\n column.isAsc\n ? 'pi pi-sort-amount-up'\n : 'pi pi-sort-amount-down'\n \"\n ></i>\n }\n </div>\n </th>\n }\n </tr>\n </thead>\n\n <tbody>\n <!-- Grouped Mode -->\n @if (isGrouped()) {\n @if (groupedVirtualTopSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"groupedVirtualTopSpacerHeightPx()\"\n ></td>\n </tr>\n }\n\n @for (item of visibleGroupedRows(); track item.trackId) {\n @if (item.kind === \"group\") {\n <tr class=\"dashboard-table-row\">\n <td\n [attr.colspan]=\"totalColumns()\"\n class=\"px-3 py-2 font-semibold\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.groupBackgroundColor || '#e4d1ac'\n \"\n [style.color]=\"tableStyleConfig()?.groupTextColor\"\n >\n <mt-entity-info\n [data]=\"{\n viewType: item.group.prop?.viewType,\n value: item.group.prop?.value,\n }\"\n [displayType]=\"'inTable'\"\n ></mt-entity-info>\n </td>\n </tr>\n } @else {\n <tr\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\n [class.cursor-pointer]=\"isRowClickable()\"\n [class.bg-surface-100]=\"\n tableStyleConfig()?.striped &&\n (item.rowIndex ?? 0) % 2 === 1\n \"\n (click)=\"onRowClick(item.row)\"\n >\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <td\n class=\"px-3 py-2 text-center border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n {{ (item.rowIndex ?? 0) + 1 }}\n </td>\n }\n\n @for (column of visibleColumns(); track column.key) {\n <td\n class=\"px-3 py-2 border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n @if (isPhaseGateColumn(column)) {\n @let phaseCell = getPhaseGateCell(item.row, column);\n <div\n class=\"min-w-36\"\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\n >\n <div class=\"flex items-center gap-2\">\n <span\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></span>\n <span class=\"font-medium truncate\">\n {{ getPhaseGateCellText(phaseCell) }}\n </span>\n </div>\n @if (getPhaseGatePercentage(phaseCell) !== null) {\n <div\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\n >\n <div\n class=\"h-full rounded-full\"\n [style.width.%]=\"\n getPhaseGatePercentage(phaseCell)\n \"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></div>\n </div>\n }\n </div>\n } @else {\n <mt-entity-info\n [data]=\"getCellData(item.row, column)\"\n [displayType]=\"'inTable'\"\n [extraInfoData]=\"tableStyleConfig()\"\n ></mt-entity-info>\n }\n </td>\n }\n </tr>\n }\n }\n\n @if (groupedVirtualBottomSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"groupedVirtualBottomSpacerHeightPx()\"\n ></td>\n </tr>\n }\n } @else {\n <!-- Non-Grouped Mode -->\n @if (flatVirtualTopSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"flatVirtualTopSpacerHeightPx()\"\n ></td>\n </tr>\n }\n\n @for (rowView of visibleTableRows(); track rowView.trackId) {\n <tr\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\n [class.cursor-pointer]=\"isRowClickable()\"\n [class.bg-surface-100]=\"\n tableStyleConfig()?.striped && rowView.rowIndex % 2 === 1\n \"\n (click)=\"onRowClick(rowView.row)\"\n >\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <td\n class=\"px-3 py-2 text-center border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n {{ rowView.rowIndex + 1 }}\n </td>\n }\n\n @for (column of visibleColumns(); track column.key) {\n <td\n class=\"px-3 py-2 border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n @if (isPhaseGateColumn(column)) {\n @let phaseCell =\n getPhaseGateCell(rowView.row, column);\n <div\n class=\"min-w-36\"\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\n >\n <div class=\"flex items-center gap-2\">\n <span\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></span>\n <span class=\"font-medium truncate\">\n {{ getPhaseGateCellText(phaseCell) }}\n </span>\n </div>\n @if (getPhaseGatePercentage(phaseCell) !== null) {\n <div\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\n >\n <div\n class=\"h-full rounded-full\"\n [style.width.%]=\"\n getPhaseGatePercentage(phaseCell)\n \"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></div>\n </div>\n }\n </div>\n } @else {\n <mt-entity-info\n [data]=\"getCellData(rowView.row, column)\"\n [displayType]=\"'inTable'\"\n [extraInfoData]=\"tableStyleConfig()\"\n ></mt-entity-info>\n }\n </td>\n }\n </tr>\n }\n\n @if (flatVirtualBottomSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"flatVirtualBottomSpacerHeightPx()\"\n ></td>\n </tr>\n }\n }\n </tbody>\n </table>\n </div>\n } @else {\n <!-- No Data -->\n <div\n class=\"flex flex-col items-center justify-center h-32 text-muted-color gap-2\"\n >\n <i class=\"pi pi-info-circle text-2xl\"></i>\n <span>{{ t(\"noData\") }}</span>\n </div>\n }\n </div>\n </ng-container>\n</mt-card-content>\n", styles: [":host{display:block;height:100%}.table-wrapper{display:flex;flex-direction:column}.table-scroll-container{flex:1;min-height:0}table{border-collapse:collapse}.dashboard-table-row{height:48px}.dashboard-table-spacer td{border:0;padding:0}th,td{text-align:start}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: CardContentComponent, selector: "mt-card-content", inputs: ["title", "inGroup", "groupHeader", "headerConfig", "styleConfig", "cardStyleConfig", "density", "padding", "showHeader", "headerClickable", "isNoTopEnd", "isChart", "titleEditable"], outputs: ["headerClick", "titleChange"] }, { kind: "component", type: EntityInfoComponent, selector: "mt-entity-info", inputs: ["data", "displayType", "extraInfoData", "limitWords", "customClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
28692
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: TableCardComponent, isStandalone: true, selector: "mt-table-card", inputs: { dashboardId: { classPropertyName: "dashboardId", publicName: "dashboardId", isSignal: true, isRequired: true, transformFunction: null }, inGroup: { classPropertyName: "inGroup", publicName: "inGroup", isSignal: true, isRequired: false, transformFunction: null }, hideHeader: { classPropertyName: "hideHeader", publicName: "hideHeader", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onAction: "onAction" }, ngImport: i0, template: "<!--\r\n One legend definition, two possible hosts. `mt-card-content` only projects\r\n [topEnd] inside its header block, so when the header is hidden (dialog view)\r\n the legend has to be rendered in the body instead or it is dropped entirely.\r\n-->\r\n<ng-template #legendList>\r\n <div class=\"flex flex-wrap items-center gap-2\">\r\n @for (label of labels(); track label.key || $index) {\r\n <div class=\"flex items-center gap-1 text-xs\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full\"\r\n [style.backgroundColor]=\"getLegendColor(label)\"\r\n ></span>\r\n <span>{{ getLegendText(label) }}</span>\r\n </div>\r\n }\r\n </div>\r\n</ng-template>\r\n\r\n<mt-card-content\r\n [inGroup]=\"inGroup()\"\r\n [showHeader]=\"!hideHeader()\"\r\n [title]=\"title()\"\r\n [styleConfig]=\"\r\n configurationItem()?.clientConfig?.displayConfig?.['StyleConfig']\r\n \"\r\n [cardStyleConfig]=\"\r\n configurationItem()?.clientConfig?.configAsType?.['cardStyleConfig']\r\n \"\r\n [headerConfig]=\"\r\n configurationItem()?.clientConfig?.configAsType?.['headerCardConfig']\r\n \"\r\n [padding]=\"configurationItem()?.clientConfig?.configAsType?.['padding']\"\r\n (headerClick)=\"onHeaderClick()\"\r\n>\r\n <!-- Status Labels -->\r\n <ng-container topEnd>\r\n @if (hasLegend() && !hideHeader()) {\r\n <ng-container [ngTemplateOutlet]=\"legendList\" />\r\n }\r\n </ng-container>\r\n\r\n <ng-container body>\r\n <div\r\n class=\"table-wrapper h-full\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\r\n >\r\n <!-- Headerless (dialog) view: the header's top-end slot does not exist,\r\n so the legend is rendered above the table instead. -->\r\n @if (hasLegend() && hideHeader()) {\r\n <div class=\"mb-2 flex shrink-0 justify-end\">\r\n <ng-container [ngTemplateOutlet]=\"legendList\" />\r\n </div>\r\n }\r\n\r\n @if (loading()) {\r\n <div class=\"flex items-center justify-center h-32\">\r\n <i class=\"pi pi-spin pi-spinner text-2xl\"></i>\r\n </div>\r\n } @else if (hasData()) {\r\n <div\r\n class=\"table-scroll-container overflow-auto h-full\"\r\n (scroll)=\"onTableScroll($event)\"\r\n >\r\n <table class=\"w-full border-collapse text-sm\">\r\n <thead class=\"sticky top-0 z-10\" [hidden]=\"hideSubheader()\">\r\n <tr>\r\n <!-- Index column -->\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <th\r\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200\"\r\n [style.color]=\"tableStyleConfig()?.thTextColor\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.thBackgroundColor\r\n \"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.thFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\r\n >\r\n #\r\n </th>\r\n }\r\n\r\n <!-- Data columns -->\r\n @for (column of visibleColumns(); track column.key) {\r\n <th\r\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200 whitespace-nowrap\"\r\n [style.minWidth]=\"column.width || 'auto'\"\r\n [style.color]=\"tableStyleConfig()?.thTextColor\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.thBackgroundColor\r\n \"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.thFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\r\n [class.cursor-pointer]=\"!isPhaseGateColumn(column)\"\r\n (click)=\"onSort(column)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ column.label }}</span>\r\n @if (column.isSort) {\r\n <i\r\n class=\"text-xs\"\r\n [class]=\"\r\n column.isAsc\r\n ? 'pi pi-sort-amount-up'\r\n : 'pi pi-sort-amount-down'\r\n \"\r\n ></i>\r\n }\r\n </div>\r\n </th>\r\n }\r\n </tr>\r\n </thead>\r\n\r\n <tbody>\r\n <!-- Grouped Mode -->\r\n @if (isGrouped()) {\r\n @if (groupedVirtualTopSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"groupedVirtualTopSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n\r\n @for (item of visibleGroupedRows(); track item.trackId) {\r\n @if (item.kind === \"group\") {\r\n <tr class=\"dashboard-table-row\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n class=\"px-3 py-2 font-semibold\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.groupBackgroundColor || '#e4d1ac'\r\n \"\r\n [style.color]=\"tableStyleConfig()?.groupTextColor\"\r\n >\r\n <mt-entity-info\r\n [data]=\"{\r\n viewType: item.group.prop?.viewType,\r\n value: item.group.prop?.value,\r\n }\"\r\n [displayType]=\"'inTable'\"\r\n ></mt-entity-info>\r\n </td>\r\n </tr>\r\n } @else {\r\n <tr\r\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\r\n [class.cursor-pointer]=\"isRowClickable()\"\r\n [class.bg-surface-100]=\"\r\n tableStyleConfig()?.striped &&\r\n (item.rowIndex ?? 0) % 2 === 1\r\n \"\r\n (click)=\"onRowClick(item.row)\"\r\n >\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <td\r\n class=\"px-3 py-2 text-center border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n {{ (item.rowIndex ?? 0) + 1 }}\r\n </td>\r\n }\r\n\r\n @for (column of visibleColumns(); track column.key) {\r\n <td\r\n class=\"px-3 py-2 border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n @if (isPhaseGateColumn(column)) {\r\n @let phaseCell = getPhaseGateCell(item.row, column);\r\n <div\r\n class=\"min-w-36\"\r\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></span>\r\n <span class=\"font-medium truncate\">\r\n {{ getPhaseGateCellText(phaseCell) }}\r\n </span>\r\n </div>\r\n @if (getPhaseGatePercentage(phaseCell) !== null) {\r\n <div\r\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\r\n >\r\n <div\r\n class=\"h-full rounded-full\"\r\n [style.width.%]=\"\r\n getPhaseGatePercentage(phaseCell)\r\n \"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></div>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <mt-entity-info\r\n [data]=\"getCellData(item.row, column)\"\r\n [displayType]=\"'inTable'\"\r\n [extraInfoData]=\"tableStyleConfig()\"\r\n ></mt-entity-info>\r\n }\r\n </td>\r\n }\r\n </tr>\r\n }\r\n }\r\n\r\n @if (groupedVirtualBottomSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"groupedVirtualBottomSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n } @else {\r\n <!-- Non-Grouped Mode -->\r\n @if (flatVirtualTopSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"flatVirtualTopSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n\r\n @for (rowView of visibleTableRows(); track rowView.trackId) {\r\n <tr\r\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\r\n [class.cursor-pointer]=\"isRowClickable()\"\r\n [class.bg-surface-100]=\"\r\n tableStyleConfig()?.striped && rowView.rowIndex % 2 === 1\r\n \"\r\n (click)=\"onRowClick(rowView.row)\"\r\n >\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <td\r\n class=\"px-3 py-2 text-center border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n {{ rowView.rowIndex + 1 }}\r\n </td>\r\n }\r\n\r\n @for (column of visibleColumns(); track column.key) {\r\n <td\r\n class=\"px-3 py-2 border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n @if (isPhaseGateColumn(column)) {\r\n @let phaseCell =\r\n getPhaseGateCell(rowView.row, column);\r\n <div\r\n class=\"min-w-36\"\r\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></span>\r\n <span class=\"font-medium truncate\">\r\n {{ getPhaseGateCellText(phaseCell) }}\r\n </span>\r\n </div>\r\n @if (getPhaseGatePercentage(phaseCell) !== null) {\r\n <div\r\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\r\n >\r\n <div\r\n class=\"h-full rounded-full\"\r\n [style.width.%]=\"\r\n getPhaseGatePercentage(phaseCell)\r\n \"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></div>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <mt-entity-info\r\n [data]=\"getCellData(rowView.row, column)\"\r\n [displayType]=\"'inTable'\"\r\n [extraInfoData]=\"tableStyleConfig()\"\r\n ></mt-entity-info>\r\n }\r\n </td>\r\n }\r\n </tr>\r\n }\r\n\r\n @if (flatVirtualBottomSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"flatVirtualBottomSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n }\r\n </tbody>\r\n </table>\r\n </div>\r\n } @else {\r\n <!-- No Data -->\r\n <div\r\n class=\"flex flex-col items-center justify-center h-32 text-muted-color gap-2\"\r\n >\r\n <i class=\"pi pi-info-circle text-2xl\"></i>\r\n <span>{{ t(\"noData\") }}</span>\r\n </div>\r\n }\r\n </div>\r\n </ng-container>\r\n</mt-card-content>\r\n", styles: [":host{display:block;height:100%}.table-wrapper{display:flex;flex-direction:column}.table-scroll-container{flex:1;min-height:0}table{border-collapse:collapse}.dashboard-table-row{height:48px}.dashboard-table-spacer td{border:0;padding:0}th,td{text-align:start}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: CardContentComponent, selector: "mt-card-content", inputs: ["title", "inGroup", "groupHeader", "headerConfig", "styleConfig", "cardStyleConfig", "density", "padding", "showHeader", "headerClickable", "isNoTopEnd", "isChart", "titleEditable"], outputs: ["headerClick", "titleChange"] }, { kind: "component", type: EntityInfoComponent, selector: "mt-entity-info", inputs: ["data", "displayType", "extraInfoData", "limitWords", "customClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
28603
28693
  }
28604
28694
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: TableCardComponent, decorators: [{
28605
28695
  type: Component,
@@ -28608,7 +28698,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
28608
28698
  TranslocoDirective,
28609
28699
  CardContentComponent,
28610
28700
  EntityInfoComponent,
28611
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--\n One legend definition, two possible hosts. `mt-card-content` only projects\n [topEnd] inside its header block, so when the header is hidden (dialog view)\n the legend has to be rendered in the body instead or it is dropped entirely.\n-->\n<ng-template #legendList>\n <div class=\"flex flex-wrap items-center gap-2\">\n @for (label of labels(); track label.key || $index) {\n <div class=\"flex items-center gap-1 text-xs\">\n <span\n class=\"w-2.5 h-2.5 rounded-full\"\n [style.backgroundColor]=\"getLegendColor(label)\"\n ></span>\n <span>{{ getLegendText(label) }}</span>\n </div>\n }\n </div>\n</ng-template>\n\n<mt-card-content\n [inGroup]=\"inGroup()\"\n [showHeader]=\"!hideHeader()\"\n [title]=\"title()\"\n [styleConfig]=\"\n configurationItem()?.clientConfig?.displayConfig?.['StyleConfig']\n \"\n [cardStyleConfig]=\"\n configurationItem()?.clientConfig?.configAsType?.['cardStyleConfig']\n \"\n [headerConfig]=\"\n configurationItem()?.clientConfig?.configAsType?.['headerCardConfig']\n \"\n [padding]=\"configurationItem()?.clientConfig?.configAsType?.['padding']\"\n (headerClick)=\"onHeaderClick()\"\n>\n <!-- Status Labels -->\n <ng-container topEnd>\n @if (hasLegend() && !hideHeader()) {\n <ng-container [ngTemplateOutlet]=\"legendList\" />\n }\n </ng-container>\n\n <ng-container body>\n <div\n class=\"table-wrapper h-full\"\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\n >\n <!-- Headerless (dialog) view: the header's top-end slot does not exist,\n so the legend is rendered above the table instead. -->\n @if (hasLegend() && hideHeader()) {\n <div class=\"mb-2 flex shrink-0 justify-end\">\n <ng-container [ngTemplateOutlet]=\"legendList\" />\n </div>\n }\n\n @if (loading()) {\n <div class=\"flex items-center justify-center h-32\">\n <i class=\"pi pi-spin pi-spinner text-2xl\"></i>\n </div>\n } @else if (hasData()) {\n <div\n class=\"table-scroll-container overflow-auto h-full\"\n (scroll)=\"onTableScroll($event)\"\n >\n <table class=\"w-full border-collapse text-sm\">\n <thead class=\"sticky top-0 z-10\" [hidden]=\"hideSubheader()\">\n <tr>\n <!-- Index column -->\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <th\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200\"\n [style.color]=\"tableStyleConfig()?.thTextColor\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.thBackgroundColor\n \"\n [style.fontWeight]=\"\n tableStyleConfig()?.thFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\n >\n #\n </th>\n }\n\n <!-- Data columns -->\n @for (column of visibleColumns(); track column.key) {\n <th\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200 whitespace-nowrap\"\n [style.minWidth]=\"column.width || 'auto'\"\n [style.color]=\"tableStyleConfig()?.thTextColor\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.thBackgroundColor\n \"\n [style.fontWeight]=\"\n tableStyleConfig()?.thFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\n [class.cursor-pointer]=\"!isPhaseGateColumn(column)\"\n (click)=\"onSort(column)\"\n >\n <div class=\"flex items-center gap-2\">\n <span>{{ column.label }}</span>\n @if (column.isSort) {\n <i\n class=\"text-xs\"\n [class]=\"\n column.isAsc\n ? 'pi pi-sort-amount-up'\n : 'pi pi-sort-amount-down'\n \"\n ></i>\n }\n </div>\n </th>\n }\n </tr>\n </thead>\n\n <tbody>\n <!-- Grouped Mode -->\n @if (isGrouped()) {\n @if (groupedVirtualTopSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"groupedVirtualTopSpacerHeightPx()\"\n ></td>\n </tr>\n }\n\n @for (item of visibleGroupedRows(); track item.trackId) {\n @if (item.kind === \"group\") {\n <tr class=\"dashboard-table-row\">\n <td\n [attr.colspan]=\"totalColumns()\"\n class=\"px-3 py-2 font-semibold\"\n [style.backgroundColor]=\"\n tableStyleConfig()?.groupBackgroundColor || '#e4d1ac'\n \"\n [style.color]=\"tableStyleConfig()?.groupTextColor\"\n >\n <mt-entity-info\n [data]=\"{\n viewType: item.group.prop?.viewType,\n value: item.group.prop?.value,\n }\"\n [displayType]=\"'inTable'\"\n ></mt-entity-info>\n </td>\n </tr>\n } @else {\n <tr\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\n [class.cursor-pointer]=\"isRowClickable()\"\n [class.bg-surface-100]=\"\n tableStyleConfig()?.striped &&\n (item.rowIndex ?? 0) % 2 === 1\n \"\n (click)=\"onRowClick(item.row)\"\n >\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <td\n class=\"px-3 py-2 text-center border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n {{ (item.rowIndex ?? 0) + 1 }}\n </td>\n }\n\n @for (column of visibleColumns(); track column.key) {\n <td\n class=\"px-3 py-2 border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n @if (isPhaseGateColumn(column)) {\n @let phaseCell = getPhaseGateCell(item.row, column);\n <div\n class=\"min-w-36\"\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\n >\n <div class=\"flex items-center gap-2\">\n <span\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></span>\n <span class=\"font-medium truncate\">\n {{ getPhaseGateCellText(phaseCell) }}\n </span>\n </div>\n @if (getPhaseGatePercentage(phaseCell) !== null) {\n <div\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\n >\n <div\n class=\"h-full rounded-full\"\n [style.width.%]=\"\n getPhaseGatePercentage(phaseCell)\n \"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></div>\n </div>\n }\n </div>\n } @else {\n <mt-entity-info\n [data]=\"getCellData(item.row, column)\"\n [displayType]=\"'inTable'\"\n [extraInfoData]=\"tableStyleConfig()\"\n ></mt-entity-info>\n }\n </td>\n }\n </tr>\n }\n }\n\n @if (groupedVirtualBottomSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"groupedVirtualBottomSpacerHeightPx()\"\n ></td>\n </tr>\n }\n } @else {\n <!-- Non-Grouped Mode -->\n @if (flatVirtualTopSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"flatVirtualTopSpacerHeightPx()\"\n ></td>\n </tr>\n }\n\n @for (rowView of visibleTableRows(); track rowView.trackId) {\n <tr\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\n [class.cursor-pointer]=\"isRowClickable()\"\n [class.bg-surface-100]=\"\n tableStyleConfig()?.striped && rowView.rowIndex % 2 === 1\n \"\n (click)=\"onRowClick(rowView.row)\"\n >\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\n <td\n class=\"px-3 py-2 text-center border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n {{ rowView.rowIndex + 1 }}\n </td>\n }\n\n @for (column of visibleColumns(); track column.key) {\n <td\n class=\"px-3 py-2 border-b border-surface-100\"\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\n [style.fontWeight]=\"\n tableStyleConfig()?.tdFontBold ? 'bold' : null\n \"\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\n >\n @if (isPhaseGateColumn(column)) {\n @let phaseCell =\n getPhaseGateCell(rowView.row, column);\n <div\n class=\"min-w-36\"\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\n >\n <div class=\"flex items-center gap-2\">\n <span\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></span>\n <span class=\"font-medium truncate\">\n {{ getPhaseGateCellText(phaseCell) }}\n </span>\n </div>\n @if (getPhaseGatePercentage(phaseCell) !== null) {\n <div\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\n >\n <div\n class=\"h-full rounded-full\"\n [style.width.%]=\"\n getPhaseGatePercentage(phaseCell)\n \"\n [style.backgroundColor]=\"\n getPhaseGateCellColor(phaseCell)\n \"\n ></div>\n </div>\n }\n </div>\n } @else {\n <mt-entity-info\n [data]=\"getCellData(rowView.row, column)\"\n [displayType]=\"'inTable'\"\n [extraInfoData]=\"tableStyleConfig()\"\n ></mt-entity-info>\n }\n </td>\n }\n </tr>\n }\n\n @if (flatVirtualBottomSpacerHeightPx() > 0) {\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\n <td\n [attr.colspan]=\"totalColumns()\"\n [style.height.px]=\"flatVirtualBottomSpacerHeightPx()\"\n ></td>\n </tr>\n }\n }\n </tbody>\n </table>\n </div>\n } @else {\n <!-- No Data -->\n <div\n class=\"flex flex-col items-center justify-center h-32 text-muted-color gap-2\"\n >\n <i class=\"pi pi-info-circle text-2xl\"></i>\n <span>{{ t(\"noData\") }}</span>\n </div>\n }\n </div>\n </ng-container>\n</mt-card-content>\n", styles: [":host{display:block;height:100%}.table-wrapper{display:flex;flex-direction:column}.table-scroll-container{flex:1;min-height:0}table{border-collapse:collapse}.dashboard-table-row{height:48px}.dashboard-table-spacer td{border:0;padding:0}th,td{text-align:start}\n"] }]
28701
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--\r\n One legend definition, two possible hosts. `mt-card-content` only projects\r\n [topEnd] inside its header block, so when the header is hidden (dialog view)\r\n the legend has to be rendered in the body instead or it is dropped entirely.\r\n-->\r\n<ng-template #legendList>\r\n <div class=\"flex flex-wrap items-center gap-2\">\r\n @for (label of labels(); track label.key || $index) {\r\n <div class=\"flex items-center gap-1 text-xs\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full\"\r\n [style.backgroundColor]=\"getLegendColor(label)\"\r\n ></span>\r\n <span>{{ getLegendText(label) }}</span>\r\n </div>\r\n }\r\n </div>\r\n</ng-template>\r\n\r\n<mt-card-content\r\n [inGroup]=\"inGroup()\"\r\n [showHeader]=\"!hideHeader()\"\r\n [title]=\"title()\"\r\n [styleConfig]=\"\r\n configurationItem()?.clientConfig?.displayConfig?.['StyleConfig']\r\n \"\r\n [cardStyleConfig]=\"\r\n configurationItem()?.clientConfig?.configAsType?.['cardStyleConfig']\r\n \"\r\n [headerConfig]=\"\r\n configurationItem()?.clientConfig?.configAsType?.['headerCardConfig']\r\n \"\r\n [padding]=\"configurationItem()?.clientConfig?.configAsType?.['padding']\"\r\n (headerClick)=\"onHeaderClick()\"\r\n>\r\n <!-- Status Labels -->\r\n <ng-container topEnd>\r\n @if (hasLegend() && !hideHeader()) {\r\n <ng-container [ngTemplateOutlet]=\"legendList\" />\r\n }\r\n </ng-container>\r\n\r\n <ng-container body>\r\n <div\r\n class=\"table-wrapper h-full\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder'\"\r\n >\r\n <!-- Headerless (dialog) view: the header's top-end slot does not exist,\r\n so the legend is rendered above the table instead. -->\r\n @if (hasLegend() && hideHeader()) {\r\n <div class=\"mb-2 flex shrink-0 justify-end\">\r\n <ng-container [ngTemplateOutlet]=\"legendList\" />\r\n </div>\r\n }\r\n\r\n @if (loading()) {\r\n <div class=\"flex items-center justify-center h-32\">\r\n <i class=\"pi pi-spin pi-spinner text-2xl\"></i>\r\n </div>\r\n } @else if (hasData()) {\r\n <div\r\n class=\"table-scroll-container overflow-auto h-full\"\r\n (scroll)=\"onTableScroll($event)\"\r\n >\r\n <table class=\"w-full border-collapse text-sm\">\r\n <thead class=\"sticky top-0 z-10\" [hidden]=\"hideSubheader()\">\r\n <tr>\r\n <!-- Index column -->\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <th\r\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200\"\r\n [style.color]=\"tableStyleConfig()?.thTextColor\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.thBackgroundColor\r\n \"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.thFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\r\n >\r\n #\r\n </th>\r\n }\r\n\r\n <!-- Data columns -->\r\n @for (column of visibleColumns(); track column.key) {\r\n <th\r\n class=\"px-3 py-2 text-left font-semibold bg-surface-100 border-b-2 border-surface-200 whitespace-nowrap\"\r\n [style.minWidth]=\"column.width || 'auto'\"\r\n [style.color]=\"tableStyleConfig()?.thTextColor\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.thBackgroundColor\r\n \"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.thFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.thFontSize\"\r\n [class.cursor-pointer]=\"!isPhaseGateColumn(column)\"\r\n (click)=\"onSort(column)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ column.label }}</span>\r\n @if (column.isSort) {\r\n <i\r\n class=\"text-xs\"\r\n [class]=\"\r\n column.isAsc\r\n ? 'pi pi-sort-amount-up'\r\n : 'pi pi-sort-amount-down'\r\n \"\r\n ></i>\r\n }\r\n </div>\r\n </th>\r\n }\r\n </tr>\r\n </thead>\r\n\r\n <tbody>\r\n <!-- Grouped Mode -->\r\n @if (isGrouped()) {\r\n @if (groupedVirtualTopSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"groupedVirtualTopSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n\r\n @for (item of visibleGroupedRows(); track item.trackId) {\r\n @if (item.kind === \"group\") {\r\n <tr class=\"dashboard-table-row\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n class=\"px-3 py-2 font-semibold\"\r\n [style.backgroundColor]=\"\r\n tableStyleConfig()?.groupBackgroundColor || '#e4d1ac'\r\n \"\r\n [style.color]=\"tableStyleConfig()?.groupTextColor\"\r\n >\r\n <mt-entity-info\r\n [data]=\"{\r\n viewType: item.group.prop?.viewType,\r\n value: item.group.prop?.value,\r\n }\"\r\n [displayType]=\"'inTable'\"\r\n ></mt-entity-info>\r\n </td>\r\n </tr>\r\n } @else {\r\n <tr\r\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\r\n [class.cursor-pointer]=\"isRowClickable()\"\r\n [class.bg-surface-100]=\"\r\n tableStyleConfig()?.striped &&\r\n (item.rowIndex ?? 0) % 2 === 1\r\n \"\r\n (click)=\"onRowClick(item.row)\"\r\n >\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <td\r\n class=\"px-3 py-2 text-center border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n {{ (item.rowIndex ?? 0) + 1 }}\r\n </td>\r\n }\r\n\r\n @for (column of visibleColumns(); track column.key) {\r\n <td\r\n class=\"px-3 py-2 border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n @if (isPhaseGateColumn(column)) {\r\n @let phaseCell = getPhaseGateCell(item.row, column);\r\n <div\r\n class=\"min-w-36\"\r\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></span>\r\n <span class=\"font-medium truncate\">\r\n {{ getPhaseGateCellText(phaseCell) }}\r\n </span>\r\n </div>\r\n @if (getPhaseGatePercentage(phaseCell) !== null) {\r\n <div\r\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\r\n >\r\n <div\r\n class=\"h-full rounded-full\"\r\n [style.width.%]=\"\r\n getPhaseGatePercentage(phaseCell)\r\n \"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></div>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <mt-entity-info\r\n [data]=\"getCellData(item.row, column)\"\r\n [displayType]=\"'inTable'\"\r\n [extraInfoData]=\"tableStyleConfig()\"\r\n ></mt-entity-info>\r\n }\r\n </td>\r\n }\r\n </tr>\r\n }\r\n }\r\n\r\n @if (groupedVirtualBottomSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"groupedVirtualBottomSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n } @else {\r\n <!-- Non-Grouped Mode -->\r\n @if (flatVirtualTopSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"flatVirtualTopSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n\r\n @for (rowView of visibleTableRows(); track rowView.trackId) {\r\n <tr\r\n class=\"dashboard-table-row hover:bg-surface-50 transition-colors\"\r\n [class.cursor-pointer]=\"isRowClickable()\"\r\n [class.bg-surface-100]=\"\r\n tableStyleConfig()?.striped && rowView.rowIndex % 2 === 1\r\n \"\r\n (click)=\"onRowClick(rowView.row)\"\r\n >\r\n @if (!tableStyleConfig()?.hideIndex && showIndex()) {\r\n <td\r\n class=\"px-3 py-2 text-center border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n {{ rowView.rowIndex + 1 }}\r\n </td>\r\n }\r\n\r\n @for (column of visibleColumns(); track column.key) {\r\n <td\r\n class=\"px-3 py-2 border-b border-surface-100\"\r\n [style.color]=\"tableStyleConfig()?.tdTextColor\"\r\n [style.fontWeight]=\"\r\n tableStyleConfig()?.tdFontBold ? 'bold' : null\r\n \"\r\n [style.fontSize.px]=\"tableStyleConfig()?.tdFontSize\"\r\n >\r\n @if (isPhaseGateColumn(column)) {\r\n @let phaseCell =\r\n getPhaseGateCell(rowView.row, column);\r\n <div\r\n class=\"min-w-36\"\r\n [title]=\"getPhaseGateCellTooltip(phaseCell)\"\r\n >\r\n <div class=\"flex items-center gap-2\">\r\n <span\r\n class=\"w-2.5 h-2.5 rounded-full flex-shrink-0\"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></span>\r\n <span class=\"font-medium truncate\">\r\n {{ getPhaseGateCellText(phaseCell) }}\r\n </span>\r\n </div>\r\n @if (getPhaseGatePercentage(phaseCell) !== null) {\r\n <div\r\n class=\"mt-1 h-1.5 overflow-hidden rounded-full bg-surface-200\"\r\n >\r\n <div\r\n class=\"h-full rounded-full\"\r\n [style.width.%]=\"\r\n getPhaseGatePercentage(phaseCell)\r\n \"\r\n [style.backgroundColor]=\"\r\n getPhaseGateCellColor(phaseCell)\r\n \"\r\n ></div>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <mt-entity-info\r\n [data]=\"getCellData(rowView.row, column)\"\r\n [displayType]=\"'inTable'\"\r\n [extraInfoData]=\"tableStyleConfig()\"\r\n ></mt-entity-info>\r\n }\r\n </td>\r\n }\r\n </tr>\r\n }\r\n\r\n @if (flatVirtualBottomSpacerHeightPx() > 0) {\r\n <tr class=\"dashboard-table-spacer\" aria-hidden=\"true\">\r\n <td\r\n [attr.colspan]=\"totalColumns()\"\r\n [style.height.px]=\"flatVirtualBottomSpacerHeightPx()\"\r\n ></td>\r\n </tr>\r\n }\r\n }\r\n </tbody>\r\n </table>\r\n </div>\r\n } @else {\r\n <!-- No Data -->\r\n <div\r\n class=\"flex flex-col items-center justify-center h-32 text-muted-color gap-2\"\r\n >\r\n <i class=\"pi pi-info-circle text-2xl\"></i>\r\n <span>{{ t(\"noData\") }}</span>\r\n </div>\r\n }\r\n </div>\r\n </ng-container>\r\n</mt-card-content>\r\n", styles: [":host{display:block;height:100%}.table-wrapper{display:flex;flex-direction:column}.table-scroll-container{flex:1;min-height:0}table{border-collapse:collapse}.dashboard-table-row{height:48px}.dashboard-table-spacer td{border:0;padding:0}th,td{text-align:start}\n"] }]
28612
28702
  }], propDecorators: { dashboardId: [{ type: i0.Input, args: [{ isSignal: true, alias: "dashboardId", required: true }] }], inGroup: [{ type: i0.Input, args: [{ isSignal: true, alias: "inGroup", required: false }] }], hideHeader: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideHeader", required: false }] }], onAction: [{ type: i0.Output, args: ["onAction"] }] } });
28613
28703
 
28614
28704
  /**
@@ -29382,6 +29472,7 @@ const VIEW_TYPE_MAP$1 = {
29382
29472
  longtext: 'LongText',
29383
29473
  date: 'Date',
29384
29474
  datetime: 'DateTime',
29475
+ time: 'Time',
29385
29476
  user: 'User',
29386
29477
  percentage: 'Percentage',
29387
29478
  currency: 'Currency',
@@ -29899,6 +29990,7 @@ const VIEW_TYPE_MAP = {
29899
29990
  longtext: 'LongText',
29900
29991
  date: 'Date',
29901
29992
  datetime: 'DateTime',
29993
+ time: 'Time',
29902
29994
  user: 'User',
29903
29995
  percentage: 'Percentage',
29904
29996
  currency: 'Currency',
@@ -32302,7 +32394,7 @@ class LegendOrderField {
32302
32394
  });
32303
32395
  }
32304
32396
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: LegendOrderField, deps: [], target: i0.ɵɵFactoryTarget.Component });
32305
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: LegendOrderField, isStandalone: true, selector: "mt-legend-order-field", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, colorOverrides: { classPropertyName: "colorOverrides", publicName: "colorOverrides", isSignal: true, isRequired: false, transformFunction: null }, reorderable: { classPropertyName: "reorderable", publicName: "reorderable", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", colorChange: "colorChange" }, ngImport: i0, template: "<div\n class=\"db-legend-order flex flex-col gap-2\"\n *transloco=\"let t; prefix: 'dashboardBuilder.styleStudio.messages'\"\n>\n @if (rows().length) {\n <div\n cdkDropList\n class=\"flex flex-col gap-2\"\n [cdkDropListDisabled]=\"!reorderable()\"\n (cdkDropListDropped)=\"drop($event)\"\n >\n @for (item of rows(); track item.key) {\n <div\n cdkDrag\n class=\"flex items-center gap-3 rounded-lg border border-surface-200 bg-surface-0 px-3 py-2\"\n [cdkDragDisabled]=\"!reorderable()\"\n >\n @if (reorderable()) {\n <span\n cdkDragHandle\n class=\"cursor-grab text-muted-color\"\n aria-hidden=\"true\"\n >\n <mt-icon icon=\"general.dots-grid\" class=\"text-base\" />\n </span>\n }\n <span\n class=\"min-w-0 flex-1 truncate text-sm text-color\"\n mtTruncateTooltip\n >\n {{ item.name }}\n </span>\n <div\n class=\"w-44 max-w-[55%] shrink-0\"\n role=\"group\"\n [attr.aria-label]=\"t('legendColorFor', { name: item.name })\"\n >\n <mt-color-picker-field\n [ngModel]=\"colorFor(item)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setColor(item, $event)\"\n />\n </div>\n </div>\n }\n </div>\n @if (reorderable()) {\n <div class=\"flex justify-end\">\n <mt-button\n [label]=\"t('resetOrder')\"\n icon=\"arrow.refresh-ccw-01\"\n severity=\"secondary\"\n variant=\"outlined\"\n size=\"small\"\n (onClick)=\"reset()\"\n />\n </div>\n }\n } @else {\n <p class=\"text-xs text-muted-color\">\n {{ t(\"noLegendEntries\") }}\n </p>\n }\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "ngmodule", type: DragDropModule }, { kind: "directive", type: i2$2.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep", "cdkDropListElementContainer", "cdkDropListHasAnchor"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i2$2.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i2$2.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: ColorPickerField, selector: "mt-color-picker-field", inputs: ["label", "appendTo", "placeholder", "class", "variant", "readonly", "pInputs", "required"], outputs: ["onChange"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }, { kind: "directive", type: TruncateTooltip, selector: "[mtTruncateTooltip]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
32397
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: LegendOrderField, isStandalone: true, selector: "mt-legend-order-field", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, colorOverrides: { classPropertyName: "colorOverrides", publicName: "colorOverrides", isSignal: true, isRequired: false, transformFunction: null }, reorderable: { classPropertyName: "reorderable", publicName: "reorderable", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", colorChange: "colorChange" }, ngImport: i0, template: "<div\r\n class=\"db-legend-order flex flex-col gap-2\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder.styleStudio.messages'\"\r\n>\r\n @if (rows().length) {\r\n <div\r\n cdkDropList\r\n class=\"flex flex-col gap-2\"\r\n [cdkDropListDisabled]=\"!reorderable()\"\r\n (cdkDropListDropped)=\"drop($event)\"\r\n >\r\n @for (item of rows(); track item.key) {\r\n <div\r\n cdkDrag\r\n class=\"flex items-center gap-3 rounded-lg border border-surface-200 bg-surface-0 px-3 py-2\"\r\n [cdkDragDisabled]=\"!reorderable()\"\r\n >\r\n @if (reorderable()) {\r\n <span\r\n cdkDragHandle\r\n class=\"cursor-grab text-muted-color\"\r\n aria-hidden=\"true\"\r\n >\r\n <mt-icon icon=\"general.dots-grid\" class=\"text-base\" />\r\n </span>\r\n }\r\n <span\r\n class=\"min-w-0 flex-1 truncate text-sm text-color\"\r\n mtTruncateTooltip\r\n >\r\n {{ item.name }}\r\n </span>\r\n <div\r\n class=\"w-44 max-w-[55%] shrink-0\"\r\n role=\"group\"\r\n [attr.aria-label]=\"t('legendColorFor', { name: item.name })\"\r\n >\r\n <mt-color-picker-field\r\n [ngModel]=\"colorFor(item)\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (ngModelChange)=\"setColor(item, $event)\"\r\n />\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n @if (reorderable()) {\r\n <div class=\"flex justify-end\">\r\n <mt-button\r\n [label]=\"t('resetOrder')\"\r\n icon=\"arrow.refresh-ccw-01\"\r\n severity=\"secondary\"\r\n variant=\"outlined\"\r\n size=\"small\"\r\n (onClick)=\"reset()\"\r\n />\r\n </div>\r\n }\r\n } @else {\r\n <p class=\"text-xs text-muted-color\">\r\n {{ t(\"noLegendEntries\") }}\r\n </p>\r\n }\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "ngmodule", type: DragDropModule }, { kind: "directive", type: i2$2.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep", "cdkDropListElementContainer", "cdkDropListHasAnchor"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i2$2.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i2$2.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: ColorPickerField, selector: "mt-color-picker-field", inputs: ["label", "appendTo", "placeholder", "class", "variant", "readonly", "pInputs", "required"], outputs: ["onChange"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }, { kind: "directive", type: TruncateTooltip, selector: "[mtTruncateTooltip]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
32306
32398
  }
32307
32399
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: LegendOrderField, decorators: [{
32308
32400
  type: Component,
@@ -32315,7 +32407,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
32315
32407
  ColorPickerField,
32316
32408
  Icon,
32317
32409
  TruncateTooltip,
32318
- ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div\n class=\"db-legend-order flex flex-col gap-2\"\n *transloco=\"let t; prefix: 'dashboardBuilder.styleStudio.messages'\"\n>\n @if (rows().length) {\n <div\n cdkDropList\n class=\"flex flex-col gap-2\"\n [cdkDropListDisabled]=\"!reorderable()\"\n (cdkDropListDropped)=\"drop($event)\"\n >\n @for (item of rows(); track item.key) {\n <div\n cdkDrag\n class=\"flex items-center gap-3 rounded-lg border border-surface-200 bg-surface-0 px-3 py-2\"\n [cdkDragDisabled]=\"!reorderable()\"\n >\n @if (reorderable()) {\n <span\n cdkDragHandle\n class=\"cursor-grab text-muted-color\"\n aria-hidden=\"true\"\n >\n <mt-icon icon=\"general.dots-grid\" class=\"text-base\" />\n </span>\n }\n <span\n class=\"min-w-0 flex-1 truncate text-sm text-color\"\n mtTruncateTooltip\n >\n {{ item.name }}\n </span>\n <div\n class=\"w-44 max-w-[55%] shrink-0\"\n role=\"group\"\n [attr.aria-label]=\"t('legendColorFor', { name: item.name })\"\n >\n <mt-color-picker-field\n [ngModel]=\"colorFor(item)\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"setColor(item, $event)\"\n />\n </div>\n </div>\n }\n </div>\n @if (reorderable()) {\n <div class=\"flex justify-end\">\n <mt-button\n [label]=\"t('resetOrder')\"\n icon=\"arrow.refresh-ccw-01\"\n severity=\"secondary\"\n variant=\"outlined\"\n size=\"small\"\n (onClick)=\"reset()\"\n />\n </div>\n }\n } @else {\n <p class=\"text-xs text-muted-color\">\n {{ t(\"noLegendEntries\") }}\n </p>\n }\n</div>\n" }]
32410
+ ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div\r\n class=\"db-legend-order flex flex-col gap-2\"\r\n *transloco=\"let t; prefix: 'dashboardBuilder.styleStudio.messages'\"\r\n>\r\n @if (rows().length) {\r\n <div\r\n cdkDropList\r\n class=\"flex flex-col gap-2\"\r\n [cdkDropListDisabled]=\"!reorderable()\"\r\n (cdkDropListDropped)=\"drop($event)\"\r\n >\r\n @for (item of rows(); track item.key) {\r\n <div\r\n cdkDrag\r\n class=\"flex items-center gap-3 rounded-lg border border-surface-200 bg-surface-0 px-3 py-2\"\r\n [cdkDragDisabled]=\"!reorderable()\"\r\n >\r\n @if (reorderable()) {\r\n <span\r\n cdkDragHandle\r\n class=\"cursor-grab text-muted-color\"\r\n aria-hidden=\"true\"\r\n >\r\n <mt-icon icon=\"general.dots-grid\" class=\"text-base\" />\r\n </span>\r\n }\r\n <span\r\n class=\"min-w-0 flex-1 truncate text-sm text-color\"\r\n mtTruncateTooltip\r\n >\r\n {{ item.name }}\r\n </span>\r\n <div\r\n class=\"w-44 max-w-[55%] shrink-0\"\r\n role=\"group\"\r\n [attr.aria-label]=\"t('legendColorFor', { name: item.name })\"\r\n >\r\n <mt-color-picker-field\r\n [ngModel]=\"colorFor(item)\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (ngModelChange)=\"setColor(item, $event)\"\r\n />\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n @if (reorderable()) {\r\n <div class=\"flex justify-end\">\r\n <mt-button\r\n [label]=\"t('resetOrder')\"\r\n icon=\"arrow.refresh-ccw-01\"\r\n severity=\"secondary\"\r\n variant=\"outlined\"\r\n size=\"small\"\r\n (onClick)=\"reset()\"\r\n />\r\n </div>\r\n }\r\n } @else {\r\n <p class=\"text-xs text-muted-color\">\r\n {{ t(\"noLegendEntries\") }}\r\n </p>\r\n }\r\n</div>\r\n" }]
32319
32411
  }], propDecorators: { items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: false }] }], colorOverrides: [{ type: i0.Input, args: [{ isSignal: true, alias: "colorOverrides", required: false }] }], reorderable: [{ type: i0.Input, args: [{ isSignal: true, alias: "reorderable", required: false }] }], valueChange: [{ type: i0.Output, args: ["valueChange"] }], colorChange: [{ type: i0.Output, args: ["colorChange"] }] } });
32320
32412
 
32321
32413
  const SHADOW_PRESET_PATH$1 = 'clientConfig.configAsType.cardStyleConfig.__shadowPreset';
@@ -32665,7 +32757,7 @@ class StyleField {
32665
32757
  this.patch.emit({ path: SHADOW_PRESET_PATH$1, value: key });
32666
32758
  }
32667
32759
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: StyleField, deps: [], target: i0.ɵɵFactoryTarget.Component });
32668
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: StyleField, isStandalone: true, selector: "mt-style-field", inputs: { field: { classPropertyName: "field", publicName: "field", isSignal: true, isRequired: true, transformFunction: null }, persisted: { classPropertyName: "persisted", publicName: "persisted", isSignal: true, isRequired: true, transformFunction: null }, capability: { classPropertyName: "capability", publicName: "capability", isSignal: true, isRequired: false, transformFunction: null }, legendItems: { classPropertyName: "legendItems", publicName: "legendItems", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { patch: "patch" }, ngImport: i0, template: "@let f = field();\n@switch (f.type) {\n @case (\"text\") {\n <mt-text-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"cssDimension\") {\n <mt-text-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? '16px'\"\n [formControl]=\"control\"\n />\n }\n @case (\"multilineText\") {\n <mt-textarea-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"number\") {\n <mt-number-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [min]=\"numberMin\"\n [max]=\"numberMax\"\n [formControl]=\"control\"\n />\n }\n @case (\"numberRange\") {\n <mt-slider-field\n [label]=\"f.label\"\n [min]=\"f.min ?? 0\"\n [max]=\"f.max ?? 100\"\n [step]=\"f.step ?? 1\"\n [unit]=\"f.unit ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"boolean\") {\n <mt-toggle-field\n [label]=\"f.label\"\n toggleShape=\"card\"\n [descriptionCard]=\"f.description ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"color\") {\n <mt-color-picker-field [label]=\"f.label\" [formControl]=\"control\" />\n }\n @case (\"select\") {\n <mt-select-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [options]=\"options()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [filter]=\"useFilter\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"multiselect\") {\n <mt-multi-select-field\n [label]=\"f.label\"\n [options]=\"options()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n display=\"chip\"\n [formControl]=\"control\"\n />\n }\n @case (\"iconPicker\") {\n <mt-icon-field [label]=\"f.label\" [formControl]=\"control\" />\n }\n @default {\n <!-- Composite + JSON types render their own label header -->\n <div class=\"db-style-field__composite flex flex-col gap-1.5\">\n <span class=\"text-sm font-medium text-color\">{{ f.label }}</span>\n @if (f.description) {\n <span class=\"text-xs text-muted-color\">{{ f.description }}</span>\n }\n @switch (f.type) {\n @case (\"segmented\") {\n <mt-segmented-field\n [options]=\"options()\"\n [value]=\"currentValue()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"palette\") {\n <mt-color-list-field\n [value]=\"readColors()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"colorList\") {\n <mt-color-list-field\n [value]=\"readColors()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"arrayBuilder\") {\n <mt-array-builder-field\n [value]=\"readArray()\"\n [itemFields]=\"f.itemFields ?? []\"\n [itemTitleKey]=\"f.itemTitleKey\"\n [addLabel]=\"addLabel('Add item')\"\n [maxItems]=\"f.maxItems\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"conditionBuilder\") {\n <mt-array-builder-field\n [value]=\"readArray()\"\n [itemFields]=\"conditionFields()\"\n [addLabel]=\"addLabel('Add rule')\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"keyValueMap\") {\n <mt-key-value-map-field\n [value]=\"readMapOrArray()\"\n [keys]=\"mapKeys()\"\n [valueFields]=\"f.valueFields ?? []\"\n [asArray]=\"f.asArray ?? false\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"legendOrder\") {\n <mt-legend-order-field\n [items]=\"legendItems()\"\n [colorOverrides]=\"readLegendColorOverrides()\"\n (valueChange)=\"emitValue($event)\"\n (colorChange)=\"onLegendColorChange($event)\"\n />\n }\n @case (\"entryColors\") {\n <!-- Colors only: no (valueChange), because there is no order to\n persist for this control's charts. -->\n <mt-legend-order-field\n [items]=\"legendItems()\"\n [colorOverrides]=\"readLegendColorOverrides()\"\n [reorderable]=\"false\"\n (colorChange)=\"onLegendColorChange($event)\"\n />\n }\n @case (\"json\") {\n <mt-textarea-field\n rows=\"8\"\n placeholder=\"{ }\"\n [formControl]=\"jsonControl\"\n />\n @if (jsonError()) {\n <span class=\"text-xs text-red-600\">{{ jsonError() }}</span>\n }\n }\n }\n </div>\n }\n}\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: TextField, selector: "mt-text-field", inputs: ["field", "hint", "label", "placeholder", "class", "type", "readonly", "pInputs", "required", "maxLength", "icon", "iconPosition"] }, { kind: "component", type: TextareaField, selector: "mt-textarea-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "noErrorStyle", "pInputs", "rows", "required", "maxLength"] }, { kind: "component", type: NumberField, selector: "mt-number-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "pInputs", "format", "useGrouping", "maxFractionDigits", "min", "max", "required"] }, { kind: "component", type: SliderField, selector: "mt-slider-field", inputs: ["field", "label", "class", "min", "max", "step", "hideNumber", "unit", "readonly", "required"] }, { kind: "component", type: ToggleField, selector: "mt-toggle-field", inputs: ["label", "inputId", "labelPosition", "placeholder", "readonly", "pInputs", "required", "toggleShape", "size", "icon", "descriptionCard"], outputs: ["onChange"] }, { kind: "component", type: SelectField, selector: "mt-select-field", inputs: ["field", "hint", "label", "placeholder", "hasPlaceholderPrefix", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "clearAfterSelect", "required", "group", "size", "optionGroupLabel", "optionGroupChildren", "loading", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape", "markCurrentUser"], outputs: ["onChange"] }, { kind: "component", type: MultiSelectField, selector: "mt-multi-select-field", inputs: ["field", "label", "placeholder", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "display", "required", "maxSelectedLabels", "group", "virtualScroll", "virtualScrollItemSize", "optionGroupLabel", "optionGroupChildren", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape"], outputs: ["onChange"] }, { kind: "component", type: ColorPickerField, selector: "mt-color-picker-field", inputs: ["label", "appendTo", "placeholder", "class", "variant", "readonly", "pInputs", "required"], outputs: ["onChange"] }, { kind: "component", type: IconField, selector: "mt-icon-field", inputs: ["label", "required"] }, { kind: "component", type: SegmentedField, selector: "mt-segmented-field", inputs: ["options", "value", "disabled", "ariaLabel"], outputs: ["valueChange"] }, { kind: "component", type: ColorListField, selector: "mt-color-list-field", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: ArrayBuilderField, selector: "mt-array-builder-field", inputs: ["value", "itemFields", "itemTitleKey", "addLabel", "maxItems"], outputs: ["valueChange"] }, { kind: "component", type: KeyValueMapField, selector: "mt-key-value-map-field", inputs: ["value", "keys", "valueFields", "asArray"], outputs: ["valueChange"] }, { kind: "component", type: LegendOrderField, selector: "mt-legend-order-field", inputs: ["items", "colorOverrides", "reorderable"], outputs: ["valueChange", "colorChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
32760
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: StyleField, isStandalone: true, selector: "mt-style-field", inputs: { field: { classPropertyName: "field", publicName: "field", isSignal: true, isRequired: true, transformFunction: null }, persisted: { classPropertyName: "persisted", publicName: "persisted", isSignal: true, isRequired: true, transformFunction: null }, capability: { classPropertyName: "capability", publicName: "capability", isSignal: true, isRequired: false, transformFunction: null }, legendItems: { classPropertyName: "legendItems", publicName: "legendItems", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { patch: "patch" }, ngImport: i0, template: "@let f = field();\r\n@switch (f.type) {\r\n @case (\"text\") {\r\n <mt-text-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"cssDimension\") {\r\n <mt-text-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? '16px'\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"multilineText\") {\r\n <mt-textarea-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"number\") {\r\n <mt-number-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [min]=\"numberMin\"\r\n [max]=\"numberMax\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"numberRange\") {\r\n <mt-slider-field\r\n [label]=\"f.label\"\r\n [min]=\"f.min ?? 0\"\r\n [max]=\"f.max ?? 100\"\r\n [step]=\"f.step ?? 1\"\r\n [unit]=\"f.unit ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"boolean\") {\r\n <mt-toggle-field\r\n [label]=\"f.label\"\r\n toggleShape=\"card\"\r\n [descriptionCard]=\"f.description ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"color\") {\r\n <mt-color-picker-field [label]=\"f.label\" [formControl]=\"control\" />\r\n }\r\n @case (\"select\") {\r\n <mt-select-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [options]=\"options()\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"useFilter\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"multiselect\") {\r\n <mt-multi-select-field\r\n [label]=\"f.label\"\r\n [options]=\"options()\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n display=\"chip\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"iconPicker\") {\r\n <mt-icon-field [label]=\"f.label\" [formControl]=\"control\" />\r\n }\r\n @default {\r\n <!-- Composite + JSON types render their own label header -->\r\n <div class=\"db-style-field__composite flex flex-col gap-1.5\">\r\n <span class=\"text-sm font-medium text-color\">{{ f.label }}</span>\r\n @if (f.description) {\r\n <span class=\"text-xs text-muted-color\">{{ f.description }}</span>\r\n }\r\n @switch (f.type) {\r\n @case (\"segmented\") {\r\n <mt-segmented-field\r\n [options]=\"options()\"\r\n [value]=\"currentValue()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"palette\") {\r\n <mt-color-list-field\r\n [value]=\"readColors()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"colorList\") {\r\n <mt-color-list-field\r\n [value]=\"readColors()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"arrayBuilder\") {\r\n <mt-array-builder-field\r\n [value]=\"readArray()\"\r\n [itemFields]=\"f.itemFields ?? []\"\r\n [itemTitleKey]=\"f.itemTitleKey\"\r\n [addLabel]=\"addLabel('Add item')\"\r\n [maxItems]=\"f.maxItems\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"conditionBuilder\") {\r\n <mt-array-builder-field\r\n [value]=\"readArray()\"\r\n [itemFields]=\"conditionFields()\"\r\n [addLabel]=\"addLabel('Add rule')\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"keyValueMap\") {\r\n <mt-key-value-map-field\r\n [value]=\"readMapOrArray()\"\r\n [keys]=\"mapKeys()\"\r\n [valueFields]=\"f.valueFields ?? []\"\r\n [asArray]=\"f.asArray ?? false\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"legendOrder\") {\r\n <mt-legend-order-field\r\n [items]=\"legendItems()\"\r\n [colorOverrides]=\"readLegendColorOverrides()\"\r\n (valueChange)=\"emitValue($event)\"\r\n (colorChange)=\"onLegendColorChange($event)\"\r\n />\r\n }\r\n @case (\"entryColors\") {\r\n <!-- Colors only: no (valueChange), because there is no order to\r\n persist for this control's charts. -->\r\n <mt-legend-order-field\r\n [items]=\"legendItems()\"\r\n [colorOverrides]=\"readLegendColorOverrides()\"\r\n [reorderable]=\"false\"\r\n (colorChange)=\"onLegendColorChange($event)\"\r\n />\r\n }\r\n @case (\"json\") {\r\n <mt-textarea-field\r\n rows=\"8\"\r\n placeholder=\"{ }\"\r\n [formControl]=\"jsonControl\"\r\n />\r\n @if (jsonError()) {\r\n <span class=\"text-xs text-red-600\">{{ jsonError() }}</span>\r\n }\r\n }\r\n }\r\n </div>\r\n }\r\n}\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: TextField, selector: "mt-text-field", inputs: ["field", "hint", "label", "placeholder", "class", "type", "readonly", "pInputs", "required", "maxLength", "icon", "iconPosition"] }, { kind: "component", type: TextareaField, selector: "mt-textarea-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "noErrorStyle", "pInputs", "rows", "required", "maxLength"] }, { kind: "component", type: NumberField, selector: "mt-number-field", inputs: ["field", "hint", "label", "placeholder", "class", "readonly", "pInputs", "format", "useGrouping", "maxFractionDigits", "min", "max", "required"] }, { kind: "component", type: SliderField, selector: "mt-slider-field", inputs: ["field", "label", "class", "min", "max", "step", "hideNumber", "unit", "readonly", "required"] }, { kind: "component", type: ToggleField, selector: "mt-toggle-field", inputs: ["label", "inputId", "labelPosition", "placeholder", "readonly", "pInputs", "required", "toggleShape", "size", "icon", "descriptionCard"], outputs: ["onChange"] }, { kind: "component", type: SelectField, selector: "mt-select-field", inputs: ["field", "hint", "label", "placeholder", "hasPlaceholderPrefix", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "clearAfterSelect", "required", "group", "size", "optionGroupLabel", "optionGroupChildren", "loading", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape", "markCurrentUser"], outputs: ["onChange"] }, { kind: "component", type: MultiSelectField, selector: "mt-multi-select-field", inputs: ["field", "label", "placeholder", "class", "readonly", "pInputs", "options", "optionValue", "optionLabel", "filter", "filterBy", "dataKey", "showClear", "display", "required", "maxSelectedLabels", "group", "virtualScroll", "virtualScrollItemSize", "optionGroupLabel", "optionGroupChildren", "optionIcon", "optionIconColor", "optionIconShape", "optionAvatarShape", "optionGroupIcon", "optionGroupIconColor", "optionGroupIconShape", "optionGroupAvatarShape"], outputs: ["onChange"] }, { kind: "component", type: ColorPickerField, selector: "mt-color-picker-field", inputs: ["label", "appendTo", "placeholder", "class", "variant", "readonly", "pInputs", "required"], outputs: ["onChange"] }, { kind: "component", type: IconField, selector: "mt-icon-field", inputs: ["label", "required"] }, { kind: "component", type: SegmentedField, selector: "mt-segmented-field", inputs: ["options", "value", "disabled", "ariaLabel"], outputs: ["valueChange"] }, { kind: "component", type: ColorListField, selector: "mt-color-list-field", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: ArrayBuilderField, selector: "mt-array-builder-field", inputs: ["value", "itemFields", "itemTitleKey", "addLabel", "maxItems"], outputs: ["valueChange"] }, { kind: "component", type: KeyValueMapField, selector: "mt-key-value-map-field", inputs: ["value", "keys", "valueFields", "asArray"], outputs: ["valueChange"] }, { kind: "component", type: LegendOrderField, selector: "mt-legend-order-field", inputs: ["items", "colorOverrides", "reorderable"], outputs: ["valueChange", "colorChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
32669
32761
  }
32670
32762
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: StyleField, decorators: [{
32671
32763
  type: Component,
@@ -32686,7 +32778,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
32686
32778
  ArrayBuilderField,
32687
32779
  KeyValueMapField,
32688
32780
  LegendOrderField,
32689
- ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "@let f = field();\n@switch (f.type) {\n @case (\"text\") {\n <mt-text-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"cssDimension\") {\n <mt-text-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? '16px'\"\n [formControl]=\"control\"\n />\n }\n @case (\"multilineText\") {\n <mt-textarea-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"number\") {\n <mt-number-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [min]=\"numberMin\"\n [max]=\"numberMax\"\n [formControl]=\"control\"\n />\n }\n @case (\"numberRange\") {\n <mt-slider-field\n [label]=\"f.label\"\n [min]=\"f.min ?? 0\"\n [max]=\"f.max ?? 100\"\n [step]=\"f.step ?? 1\"\n [unit]=\"f.unit ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"boolean\") {\n <mt-toggle-field\n [label]=\"f.label\"\n toggleShape=\"card\"\n [descriptionCard]=\"f.description ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"color\") {\n <mt-color-picker-field [label]=\"f.label\" [formControl]=\"control\" />\n }\n @case (\"select\") {\n <mt-select-field\n [label]=\"f.label\"\n [hint]=\"f.description\"\n [options]=\"options()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [filter]=\"useFilter\"\n [placeholder]=\"f.placeholder ?? ''\"\n [formControl]=\"control\"\n />\n }\n @case (\"multiselect\") {\n <mt-multi-select-field\n [label]=\"f.label\"\n [options]=\"options()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n display=\"chip\"\n [formControl]=\"control\"\n />\n }\n @case (\"iconPicker\") {\n <mt-icon-field [label]=\"f.label\" [formControl]=\"control\" />\n }\n @default {\n <!-- Composite + JSON types render their own label header -->\n <div class=\"db-style-field__composite flex flex-col gap-1.5\">\n <span class=\"text-sm font-medium text-color\">{{ f.label }}</span>\n @if (f.description) {\n <span class=\"text-xs text-muted-color\">{{ f.description }}</span>\n }\n @switch (f.type) {\n @case (\"segmented\") {\n <mt-segmented-field\n [options]=\"options()\"\n [value]=\"currentValue()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"palette\") {\n <mt-color-list-field\n [value]=\"readColors()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"colorList\") {\n <mt-color-list-field\n [value]=\"readColors()\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"arrayBuilder\") {\n <mt-array-builder-field\n [value]=\"readArray()\"\n [itemFields]=\"f.itemFields ?? []\"\n [itemTitleKey]=\"f.itemTitleKey\"\n [addLabel]=\"addLabel('Add item')\"\n [maxItems]=\"f.maxItems\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"conditionBuilder\") {\n <mt-array-builder-field\n [value]=\"readArray()\"\n [itemFields]=\"conditionFields()\"\n [addLabel]=\"addLabel('Add rule')\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"keyValueMap\") {\n <mt-key-value-map-field\n [value]=\"readMapOrArray()\"\n [keys]=\"mapKeys()\"\n [valueFields]=\"f.valueFields ?? []\"\n [asArray]=\"f.asArray ?? false\"\n (valueChange)=\"emitValue($event)\"\n />\n }\n @case (\"legendOrder\") {\n <mt-legend-order-field\n [items]=\"legendItems()\"\n [colorOverrides]=\"readLegendColorOverrides()\"\n (valueChange)=\"emitValue($event)\"\n (colorChange)=\"onLegendColorChange($event)\"\n />\n }\n @case (\"entryColors\") {\n <!-- Colors only: no (valueChange), because there is no order to\n persist for this control's charts. -->\n <mt-legend-order-field\n [items]=\"legendItems()\"\n [colorOverrides]=\"readLegendColorOverrides()\"\n [reorderable]=\"false\"\n (colorChange)=\"onLegendColorChange($event)\"\n />\n }\n @case (\"json\") {\n <mt-textarea-field\n rows=\"8\"\n placeholder=\"{ }\"\n [formControl]=\"jsonControl\"\n />\n @if (jsonError()) {\n <span class=\"text-xs text-red-600\">{{ jsonError() }}</span>\n }\n }\n }\n </div>\n }\n}\n" }]
32781
+ ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "@let f = field();\r\n@switch (f.type) {\r\n @case (\"text\") {\r\n <mt-text-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"cssDimension\") {\r\n <mt-text-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? '16px'\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"multilineText\") {\r\n <mt-textarea-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"number\") {\r\n <mt-number-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [min]=\"numberMin\"\r\n [max]=\"numberMax\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"numberRange\") {\r\n <mt-slider-field\r\n [label]=\"f.label\"\r\n [min]=\"f.min ?? 0\"\r\n [max]=\"f.max ?? 100\"\r\n [step]=\"f.step ?? 1\"\r\n [unit]=\"f.unit ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"boolean\") {\r\n <mt-toggle-field\r\n [label]=\"f.label\"\r\n toggleShape=\"card\"\r\n [descriptionCard]=\"f.description ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"color\") {\r\n <mt-color-picker-field [label]=\"f.label\" [formControl]=\"control\" />\r\n }\r\n @case (\"select\") {\r\n <mt-select-field\r\n [label]=\"f.label\"\r\n [hint]=\"f.description\"\r\n [options]=\"options()\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n [filter]=\"useFilter\"\r\n [placeholder]=\"f.placeholder ?? ''\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"multiselect\") {\r\n <mt-multi-select-field\r\n [label]=\"f.label\"\r\n [options]=\"options()\"\r\n optionLabel=\"label\"\r\n optionValue=\"value\"\r\n display=\"chip\"\r\n [formControl]=\"control\"\r\n />\r\n }\r\n @case (\"iconPicker\") {\r\n <mt-icon-field [label]=\"f.label\" [formControl]=\"control\" />\r\n }\r\n @default {\r\n <!-- Composite + JSON types render their own label header -->\r\n <div class=\"db-style-field__composite flex flex-col gap-1.5\">\r\n <span class=\"text-sm font-medium text-color\">{{ f.label }}</span>\r\n @if (f.description) {\r\n <span class=\"text-xs text-muted-color\">{{ f.description }}</span>\r\n }\r\n @switch (f.type) {\r\n @case (\"segmented\") {\r\n <mt-segmented-field\r\n [options]=\"options()\"\r\n [value]=\"currentValue()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"palette\") {\r\n <mt-color-list-field\r\n [value]=\"readColors()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"colorList\") {\r\n <mt-color-list-field\r\n [value]=\"readColors()\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"arrayBuilder\") {\r\n <mt-array-builder-field\r\n [value]=\"readArray()\"\r\n [itemFields]=\"f.itemFields ?? []\"\r\n [itemTitleKey]=\"f.itemTitleKey\"\r\n [addLabel]=\"addLabel('Add item')\"\r\n [maxItems]=\"f.maxItems\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"conditionBuilder\") {\r\n <mt-array-builder-field\r\n [value]=\"readArray()\"\r\n [itemFields]=\"conditionFields()\"\r\n [addLabel]=\"addLabel('Add rule')\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"keyValueMap\") {\r\n <mt-key-value-map-field\r\n [value]=\"readMapOrArray()\"\r\n [keys]=\"mapKeys()\"\r\n [valueFields]=\"f.valueFields ?? []\"\r\n [asArray]=\"f.asArray ?? false\"\r\n (valueChange)=\"emitValue($event)\"\r\n />\r\n }\r\n @case (\"legendOrder\") {\r\n <mt-legend-order-field\r\n [items]=\"legendItems()\"\r\n [colorOverrides]=\"readLegendColorOverrides()\"\r\n (valueChange)=\"emitValue($event)\"\r\n (colorChange)=\"onLegendColorChange($event)\"\r\n />\r\n }\r\n @case (\"entryColors\") {\r\n <!-- Colors only: no (valueChange), because there is no order to\r\n persist for this control's charts. -->\r\n <mt-legend-order-field\r\n [items]=\"legendItems()\"\r\n [colorOverrides]=\"readLegendColorOverrides()\"\r\n [reorderable]=\"false\"\r\n (colorChange)=\"onLegendColorChange($event)\"\r\n />\r\n }\r\n @case (\"json\") {\r\n <mt-textarea-field\r\n rows=\"8\"\r\n placeholder=\"{ }\"\r\n [formControl]=\"jsonControl\"\r\n />\r\n @if (jsonError()) {\r\n <span class=\"text-xs text-red-600\">{{ jsonError() }}</span>\r\n }\r\n }\r\n }\r\n </div>\r\n }\r\n}\r\n" }]
32690
32782
  }], ctorParameters: () => [], propDecorators: { field: [{ type: i0.Input, args: [{ isSignal: true, alias: "field", required: true }] }], persisted: [{ type: i0.Input, args: [{ isSignal: true, alias: "persisted", required: true }] }], capability: [{ type: i0.Input, args: [{ isSignal: true, alias: "capability", required: false }] }], legendItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "legendItems", required: false }] }], patch: [{ type: i0.Output, args: ["patch"] }] } });
32691
32783
 
32692
32784
  /**
@@ -41870,18 +41962,26 @@ class WidgetPaletteComponent {
41870
41962
  return t.products.includes(prod);
41871
41963
  });
41872
41964
  }, ...(ngDevMode ? [{ debugName: "filteredChartTypes" }] : /* istanbul ignore next */ []));
41873
- /** Widgets for active category */
41965
+ /**
41966
+ * Widgets shown in the grid.
41967
+ *
41968
+ * A search spans EVERY category; only an empty search falls back to the
41969
+ * active tab. Scoping the search to the active tab meant that a user who
41970
+ * opened the palette — which lands on **Layout**, a tab holding just Header
41971
+ * and Topbar — and typed a widget name into the prominent search box got
41972
+ * "No results" for a widget that exists one tab over (issue #1248: "i cant
41973
+ * find the map chart to use it").
41974
+ */
41874
41975
  widgets = computed(() => {
41875
- const search = this.searchTerm().toLowerCase();
41876
- const category = this.activeTab();
41877
- let filtered = this.filteredChartTypes().filter((t) => t.category === category);
41878
- // Filter by hideInList
41879
- filtered = filtered.filter((t) => !t.hideInList);
41976
+ const search = this.searchTerm().trim().toLowerCase();
41977
+ const available = this.filteredChartTypes().filter((t) => !t.hideInList);
41880
41978
  if (search) {
41881
- filtered = filtered.filter((w) => w.name.toLowerCase().includes(search));
41979
+ return available.filter((w) => w.name.toLowerCase().includes(search));
41882
41980
  }
41883
- return filtered;
41981
+ return available.filter((t) => t.category === this.activeTab());
41884
41982
  }, ...(ngDevMode ? [{ debugName: "widgets" }] : /* istanbul ignore next */ []));
41983
+ /** True while a search is narrowing across categories (tabs do not apply). */
41984
+ isSearching = computed(() => this.searchTerm().trim().length > 0, ...(ngDevMode ? [{ debugName: "isSearching" }] : /* istanbul ignore next */ []));
41885
41985
  /** Count of widgets per category (for badge display) */
41886
41986
  categoryCount = computed(() => {
41887
41987
  const types = this.filteredChartTypes().filter((t) => !t.hideInList);
@@ -41918,11 +42018,11 @@ class WidgetPaletteComponent {
41918
42018
  this.ref?.close(null);
41919
42019
  }
41920
42020
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: WidgetPaletteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
41921
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: WidgetPaletteComponent, isStandalone: true, selector: "mt-widget-palette", inputs: { product: { classPropertyName: "product", publicName: "product", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder'\">\r\n <!-- Content -->\r\n <div class=\"flex flex-col gap-4 p-4\" [class]=\"modal.contentClass\">\r\n <!-- Search -->\r\n <mt-text-field\r\n [placeholder]=\"t('widgetPalette.searchPlaceholder')\"\r\n [icon]=\"'general.search-lg'\"\r\n [(value)]=\"searchTerm\"\r\n />\r\n\r\n <!-- Category Tabs -->\r\n <mt-tabs\r\n [(active)]=\"activeTab\"\r\n [options]=\"tabOptions()\"\r\n size=\"small\"\r\n fluid\r\n />\r\n\r\n <!-- Widgets Grid -->\r\n <div class=\"flex-1 overflow-y-auto\">\r\n <div class=\"grid grid-cols-3 gap-3\">\r\n @for (widget of widgets(); track widget.id) {\r\n <div\r\n class=\"flex flex-col items-center justify-center gap-2 p-4 rounded-lg cursor-pointer border border-surface-200 bg-white select-none transition-all hover:border-primary-400 hover:shadow-md hover:bg-primary-50\"\r\n draggable=\"true\"\r\n (dragstart)=\"onDragStart($event, widget)\"\r\n (click)=\"onWidgetClick(widget)\"\r\n [title]=\"widget.name\"\r\n >\r\n <div\r\n class=\"w-10 h-10 flex items-center justify-center text-primary-500\"\r\n >\r\n <mt-icon [icon]=\"widget.icon\" class=\"text-2xl\" />\r\n </div>\r\n <span\r\n class=\"text-xs font-medium text-color text-center leading-tight\"\r\n >{{ widget.name }}</span\r\n >\r\n </div>\r\n }\r\n </div>\r\n\r\n @if (widgets().length === 0) {\r\n <div class=\"p-8 text-center text-muted-color\">\r\n <mt-icon icon=\"general.search-lg\" class=\"text-3xl mb-2\" />\r\n <p>{{ t(\"widgetPalette.noResults\") }}</p>\r\n </div>\r\n }\r\n </div>\r\n\r\n <!-- Hint -->\r\n <div\r\n class=\"text-xs text-muted-color text-center py-2 border-t border-surface-200\"\r\n >\r\n {{ t(\"widgetPalette.dragHint\") }}\r\n </div>\r\n </div>\r\n\r\n <!-- Footer -->\r\n <div [class]=\"modal.footerClass\">\r\n <mt-button [label]=\"t('cancel')\" variant=\"outlined\" (onClick)=\"close()\" />\r\n </div>\r\n</ng-container>\r\n", dependencies: [{ kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: TextField, selector: "mt-text-field", inputs: ["field", "hint", "label", "placeholder", "class", "type", "readonly", "pInputs", "required", "maxLength", "icon", "iconPosition"] }, { kind: "component", type: Tabs, selector: "mt-tabs", inputs: ["options", "optionLabel", "optionValue", "active", "mode", "moreLabel", "defaultIcon", "size", "fluid", "disabled", "searchThreshold"], outputs: ["activeChange", "onChange"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
42021
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: WidgetPaletteComponent, isStandalone: true, selector: "mt-widget-palette", inputs: { product: { classPropertyName: "product", publicName: "product", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder'\">\r\n <!-- Content -->\r\n <div class=\"flex flex-col gap-4 p-4\" [class]=\"modal.contentClass\">\r\n <!-- Search -->\r\n <mt-text-field\r\n [placeholder]=\"t('widgetPalette.searchPlaceholder')\"\r\n [icon]=\"'general.search-lg'\"\r\n [(value)]=\"searchTerm\"\r\n />\r\n\r\n <!-- Category Tabs \u2014 a search spans every category, so the tabs do not\r\n apply while one is active. -->\r\n @if (!isSearching()) {\r\n <mt-tabs\r\n [(active)]=\"activeTab\"\r\n [options]=\"tabOptions()\"\r\n size=\"small\"\r\n fluid\r\n />\r\n }\r\n\r\n <!-- Widgets Grid -->\r\n <div class=\"flex-1 overflow-y-auto\">\r\n <div class=\"grid grid-cols-3 gap-3\">\r\n @for (widget of widgets(); track widget.id) {\r\n <div\r\n class=\"flex flex-col items-center justify-center gap-2 p-4 rounded-lg cursor-pointer border border-surface-200 bg-white select-none transition-all hover:border-primary-400 hover:shadow-md hover:bg-primary-50\"\r\n draggable=\"true\"\r\n (dragstart)=\"onDragStart($event, widget)\"\r\n (click)=\"onWidgetClick(widget)\"\r\n [title]=\"widget.name\"\r\n >\r\n <div\r\n class=\"w-10 h-10 flex items-center justify-center text-primary-500\"\r\n >\r\n <mt-icon [icon]=\"widget.icon\" class=\"text-2xl\" />\r\n </div>\r\n <span\r\n class=\"text-xs font-medium text-color text-center leading-tight\"\r\n >{{ widget.name }}</span\r\n >\r\n </div>\r\n }\r\n </div>\r\n\r\n @if (widgets().length === 0) {\r\n <div class=\"p-8 text-center text-muted-color\">\r\n <mt-icon icon=\"general.search-lg\" class=\"text-3xl mb-2\" />\r\n <p>{{ t(\"widgetPalette.noResults\") }}</p>\r\n </div>\r\n }\r\n </div>\r\n\r\n <!-- Hint -->\r\n <div\r\n class=\"text-xs text-muted-color text-center py-2 border-t border-surface-200\"\r\n >\r\n {{ t(\"widgetPalette.dragHint\") }}\r\n </div>\r\n </div>\r\n\r\n <!-- Footer -->\r\n <div [class]=\"modal.footerClass\">\r\n <mt-button [label]=\"t('cancel')\" variant=\"outlined\" (onClick)=\"close()\" />\r\n </div>\r\n</ng-container>\r\n", dependencies: [{ kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: TextField, selector: "mt-text-field", inputs: ["field", "hint", "label", "placeholder", "class", "type", "readonly", "pInputs", "required", "maxLength", "icon", "iconPosition"] }, { kind: "component", type: Tabs, selector: "mt-tabs", inputs: ["options", "optionLabel", "optionValue", "active", "mode", "moreLabel", "defaultIcon", "size", "fluid", "disabled", "searchThreshold"], outputs: ["activeChange", "onChange"] }, { kind: "component", type: Icon, selector: "mt-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
41922
42022
  }
41923
42023
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: WidgetPaletteComponent, decorators: [{
41924
42024
  type: Component,
41925
- args: [{ selector: 'mt-widget-palette', standalone: true, imports: [TranslocoDirective, Button, TextField, Tabs, Icon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder'\">\r\n <!-- Content -->\r\n <div class=\"flex flex-col gap-4 p-4\" [class]=\"modal.contentClass\">\r\n <!-- Search -->\r\n <mt-text-field\r\n [placeholder]=\"t('widgetPalette.searchPlaceholder')\"\r\n [icon]=\"'general.search-lg'\"\r\n [(value)]=\"searchTerm\"\r\n />\r\n\r\n <!-- Category Tabs -->\r\n <mt-tabs\r\n [(active)]=\"activeTab\"\r\n [options]=\"tabOptions()\"\r\n size=\"small\"\r\n fluid\r\n />\r\n\r\n <!-- Widgets Grid -->\r\n <div class=\"flex-1 overflow-y-auto\">\r\n <div class=\"grid grid-cols-3 gap-3\">\r\n @for (widget of widgets(); track widget.id) {\r\n <div\r\n class=\"flex flex-col items-center justify-center gap-2 p-4 rounded-lg cursor-pointer border border-surface-200 bg-white select-none transition-all hover:border-primary-400 hover:shadow-md hover:bg-primary-50\"\r\n draggable=\"true\"\r\n (dragstart)=\"onDragStart($event, widget)\"\r\n (click)=\"onWidgetClick(widget)\"\r\n [title]=\"widget.name\"\r\n >\r\n <div\r\n class=\"w-10 h-10 flex items-center justify-center text-primary-500\"\r\n >\r\n <mt-icon [icon]=\"widget.icon\" class=\"text-2xl\" />\r\n </div>\r\n <span\r\n class=\"text-xs font-medium text-color text-center leading-tight\"\r\n >{{ widget.name }}</span\r\n >\r\n </div>\r\n }\r\n </div>\r\n\r\n @if (widgets().length === 0) {\r\n <div class=\"p-8 text-center text-muted-color\">\r\n <mt-icon icon=\"general.search-lg\" class=\"text-3xl mb-2\" />\r\n <p>{{ t(\"widgetPalette.noResults\") }}</p>\r\n </div>\r\n }\r\n </div>\r\n\r\n <!-- Hint -->\r\n <div\r\n class=\"text-xs text-muted-color text-center py-2 border-t border-surface-200\"\r\n >\r\n {{ t(\"widgetPalette.dragHint\") }}\r\n </div>\r\n </div>\r\n\r\n <!-- Footer -->\r\n <div [class]=\"modal.footerClass\">\r\n <mt-button [label]=\"t('cancel')\" variant=\"outlined\" (onClick)=\"close()\" />\r\n </div>\r\n</ng-container>\r\n" }]
42025
+ args: [{ selector: 'mt-widget-palette', standalone: true, imports: [TranslocoDirective, Button, TextField, Tabs, Icon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder'\">\r\n <!-- Content -->\r\n <div class=\"flex flex-col gap-4 p-4\" [class]=\"modal.contentClass\">\r\n <!-- Search -->\r\n <mt-text-field\r\n [placeholder]=\"t('widgetPalette.searchPlaceholder')\"\r\n [icon]=\"'general.search-lg'\"\r\n [(value)]=\"searchTerm\"\r\n />\r\n\r\n <!-- Category Tabs \u2014 a search spans every category, so the tabs do not\r\n apply while one is active. -->\r\n @if (!isSearching()) {\r\n <mt-tabs\r\n [(active)]=\"activeTab\"\r\n [options]=\"tabOptions()\"\r\n size=\"small\"\r\n fluid\r\n />\r\n }\r\n\r\n <!-- Widgets Grid -->\r\n <div class=\"flex-1 overflow-y-auto\">\r\n <div class=\"grid grid-cols-3 gap-3\">\r\n @for (widget of widgets(); track widget.id) {\r\n <div\r\n class=\"flex flex-col items-center justify-center gap-2 p-4 rounded-lg cursor-pointer border border-surface-200 bg-white select-none transition-all hover:border-primary-400 hover:shadow-md hover:bg-primary-50\"\r\n draggable=\"true\"\r\n (dragstart)=\"onDragStart($event, widget)\"\r\n (click)=\"onWidgetClick(widget)\"\r\n [title]=\"widget.name\"\r\n >\r\n <div\r\n class=\"w-10 h-10 flex items-center justify-center text-primary-500\"\r\n >\r\n <mt-icon [icon]=\"widget.icon\" class=\"text-2xl\" />\r\n </div>\r\n <span\r\n class=\"text-xs font-medium text-color text-center leading-tight\"\r\n >{{ widget.name }}</span\r\n >\r\n </div>\r\n }\r\n </div>\r\n\r\n @if (widgets().length === 0) {\r\n <div class=\"p-8 text-center text-muted-color\">\r\n <mt-icon icon=\"general.search-lg\" class=\"text-3xl mb-2\" />\r\n <p>{{ t(\"widgetPalette.noResults\") }}</p>\r\n </div>\r\n }\r\n </div>\r\n\r\n <!-- Hint -->\r\n <div\r\n class=\"text-xs text-muted-color text-center py-2 border-t border-surface-200\"\r\n >\r\n {{ t(\"widgetPalette.dragHint\") }}\r\n </div>\r\n </div>\r\n\r\n <!-- Footer -->\r\n <div [class]=\"modal.footerClass\">\r\n <mt-button [label]=\"t('cancel')\" variant=\"outlined\" (onClick)=\"close()\" />\r\n </div>\r\n</ng-container>\r\n" }]
41926
42026
  }], propDecorators: { product: [{ type: i0.Input, args: [{ isSignal: true, alias: "product", required: false }] }] } });
41927
42027
 
41928
42028
  /**
@@ -41944,6 +42044,7 @@ class DashboardBuilder {
41944
42044
  transloco = inject(TranslocoService);
41945
42045
  modalService = inject(ModalService);
41946
42046
  confirmationService = inject(ConfirmationService);
42047
+ route = inject(ActivatedRoute, { optional: true });
41947
42048
  // ============================================
41948
42049
  // Inputs
41949
42050
  // ============================================
@@ -42092,6 +42193,12 @@ class DashboardBuilder {
42092
42193
  lastExtraFiltersSignature = null;
42093
42194
  lastLoadedPageKey = null;
42094
42195
  lastStandaloneDashboardSignature = null;
42196
+ /**
42197
+ * Last geometry published per chart id, keyed by `serviceConfig.dashboardId`.
42198
+ * Gridster mutates the bound chart object in place, so this is the only way
42199
+ * to tell that a drag/resize actually moved something (issue #1192).
42200
+ */
42201
+ lastItemGeometry = new Map();
42095
42202
  // Undo history (issue #1192): deep-cloned whole-document snapshots.
42096
42203
  undoStack = [];
42097
42204
  HISTORY_LIMIT = 30;
@@ -42140,6 +42247,14 @@ class DashboardBuilder {
42140
42247
  // Lifecycle
42141
42248
  // ============================================
42142
42249
  ngOnInit() {
42250
+ // Publish our route so `ActionService.navigateToPage` can resolve a sibling
42251
+ // dashboard. Only the viewer used to do this, so inside the BUILDER the
42252
+ // service fell back to ActionService's own (ROOT) route and navigation
42253
+ // landed on the app root instead of the target dashboard (issues #1140 /
42254
+ // #1193 — the dialog case, where the item cannot see a routed injector).
42255
+ if (this.route) {
42256
+ this.dashboardService.setActivatedRoute(this.route);
42257
+ }
42143
42258
  this.setupEventListeners();
42144
42259
  // Warm the modules tree once when the dashboard opens. It is not
42145
42260
  // workspace-filtered, so every later "open datasource" hits this cache
@@ -42147,6 +42262,9 @@ class DashboardBuilder {
42147
42262
  this.prefetchModulesTree();
42148
42263
  }
42149
42264
  ngOnDestroy() {
42265
+ if (this.route && this.dashboardService.activatedRoute() === this.route) {
42266
+ this.dashboardService.setActivatedRoute(null);
42267
+ }
42150
42268
  this.subscription.unsubscribe();
42151
42269
  this.removeEventListeners();
42152
42270
  this.stopAutoScroll();
@@ -42201,6 +42319,7 @@ class DashboardBuilder {
42201
42319
  };
42202
42320
  // A fresh document loaded — start its edit history from scratch.
42203
42321
  this.resetHistory();
42322
+ this.resetItemGeometryTracking();
42204
42323
  this.pageConfig.set(normalizedReport);
42205
42324
  // Handle chartLinks format from new API
42206
42325
  if (report.chartLinks && report.chartLinks.length > 0) {
@@ -42275,12 +42394,23 @@ class DashboardBuilder {
42275
42394
  // ============================================
42276
42395
  // Save
42277
42396
  // ============================================
42397
+ /**
42398
+ * Persist the dashboard.
42399
+ *
42400
+ * An EXPLICIT save (the toolbar button — `silent` unset) is the commit point
42401
+ * for the undo history: once it succeeds the accumulated history is dropped
42402
+ * and Undo is disabled until the user edits again. Undo is a pre-save
42403
+ * operation, so it must never be able to reach across a deliberate save
42404
+ * (issue #1192). Internal auto-saves pass `silent: true` and deliberately
42405
+ * keep the history so an add/remove stays revertible.
42406
+ */
42278
42407
  saveDash(options = {}) {
42279
42408
  if (this.saving())
42280
42409
  return;
42281
42410
  if (this.standalone()) {
42282
42411
  this.emitDashboardDataChange();
42283
42412
  if (!options.silent) {
42413
+ this.commitSavedState();
42284
42414
  this.onSave.emit();
42285
42415
  }
42286
42416
  return;
@@ -42339,6 +42469,7 @@ class DashboardBuilder {
42339
42469
  if (linkRequests.length === 0) {
42340
42470
  this.saving.set(false);
42341
42471
  if (!options.silent) {
42472
+ this.commitSavedState();
42342
42473
  this.onSave.emit();
42343
42474
  }
42344
42475
  return;
@@ -42385,11 +42516,25 @@ class DashboardBuilder {
42385
42516
  }));
42386
42517
  this.dashboardService.setDialogItems(this.dialogs());
42387
42518
  if (!options.silent) {
42519
+ this.commitSavedState();
42388
42520
  this.onSave.emit();
42389
42521
  }
42390
42522
  },
42391
42523
  });
42392
42524
  }
42525
+ /**
42526
+ * Mark the current document as the saved baseline: drop the undo history so
42527
+ * Undo is disabled until the next edit (issue #1192 — undo is a *pre-save*
42528
+ * operation and must not reach back across a deliberate save).
42529
+ *
42530
+ * Runs after the link-id patch so the new baseline is captured from the
42531
+ * document the backend actually holds.
42532
+ */
42533
+ commitSavedState() {
42534
+ this.resetHistory();
42535
+ this.committedSnapshot = cloneDeep$1(this.buildDashboardDataSnapshot());
42536
+ this.committedSignature = this.historySignature(this.committedSnapshot);
42537
+ }
42393
42538
  /**
42394
42539
  * Persist the page-level filters through the dashboard (report) endpoint —
42395
42540
  * the canonical carrier of `dashboardConfig.filters`. In API-backed mode
@@ -42477,33 +42622,43 @@ class DashboardBuilder {
42477
42622
  onItemResize(item, itemComponent) {
42478
42623
  this.onItemChange(item, itemComponent);
42479
42624
  }
42625
+ /**
42626
+ * Gridster drag/resize committed (issue #1192).
42627
+ *
42628
+ * The template binds `[item]="chart"`, so Gridster owns and MUTATES the very
42629
+ * object that lives inside the `charts` signal. By the time this callback
42630
+ * runs, `chart.x/y/cols/rows` already hold the new geometry — which is why
42631
+ * the previous "did anything change?" guard compared the chart against
42632
+ * itself, always matched, and returned the array untouched. The signal never
42633
+ * notified, so neither the undo-history effect nor the standalone
42634
+ * `dashboardData` emit ever saw a move or a resize.
42635
+ *
42636
+ * We therefore track the last geometry we published per chart and compare
42637
+ * against THAT. When it differs we publish a new array reference (same item
42638
+ * objects, so Gridster's own `[item]` binding is left alone) purely to wake
42639
+ * the signal's consumers.
42640
+ */
42480
42641
  onItemChange(item, _itemComponent) {
42481
- this.charts.update((currentCharts) => {
42482
- const dashboardId = item.config?.serviceConfig?.dashboardId;
42483
- if (!dashboardId)
42484
- return currentCharts;
42485
- const chartToUpdate = currentCharts.find((c) => c.config?.serviceConfig?.dashboardId === dashboardId);
42486
- if (!chartToUpdate)
42487
- return currentCharts;
42488
- if (chartToUpdate.x === item.x &&
42489
- chartToUpdate.y === item.y &&
42490
- chartToUpdate.cols === item.cols &&
42491
- chartToUpdate.rows === item.rows) {
42492
- return currentCharts;
42493
- }
42494
- return currentCharts.map((chart) => {
42495
- if (chart.config?.serviceConfig?.dashboardId === dashboardId) {
42496
- return {
42497
- ...chart,
42498
- x: item.x,
42499
- y: item.y,
42500
- cols: item.cols,
42501
- rows: item.rows,
42502
- };
42503
- }
42504
- return chart;
42505
- });
42506
- });
42642
+ const dashboardId = item.config?.serviceConfig?.dashboardId;
42643
+ if (!dashboardId)
42644
+ return;
42645
+ const geometry = this.geometrySignature(item);
42646
+ if (this.lastItemGeometry.get(dashboardId) === geometry)
42647
+ return;
42648
+ this.lastItemGeometry.set(dashboardId, geometry);
42649
+ this.charts.update((currentCharts) => [...currentCharts]);
42650
+ }
42651
+ geometrySignature(item) {
42652
+ return `${item.x ?? 0}:${item.y ?? 0}:${item.cols ?? 1}:${item.rows ?? 1}`;
42653
+ }
42654
+ /**
42655
+ * Forget recorded geometries. Required whenever a whole new document replaces
42656
+ * the current one (load / standalone apply / undo restore), otherwise a stale
42657
+ * entry could make a later drag back to those exact coordinates look like a
42658
+ * no-op and get swallowed.
42659
+ */
42660
+ resetItemGeometryTracking() {
42661
+ this.lastItemGeometry.clear();
42507
42662
  }
42508
42663
  onContextMenu(event, item) {
42509
42664
  event.preventDefault();
@@ -44124,12 +44279,17 @@ class DashboardBuilder {
44124
44279
  this.canUndo.set(false);
44125
44280
  }
44126
44281
  /**
44127
- * Revert the most recent action, restoring the dashboard to its previous
44128
- * state, re-pushing the reverted config into every mounted widget, and
44129
- * persisting the reverted document. Persistence matters because most actions
44130
- * auto-save (`saveDash({ silent: true })`), so a local-only revert would be
44131
- * overwritten on the next reload — the undo has to roll the SAVED state back
44132
- * too (issue #1192).
44282
+ * Revert the most recent UNSAVED action (issue #1192).
44283
+ *
44284
+ * Undo is a pre-save operation: it restores the previous local state and
44285
+ * never writes to the backend. Pressing Save is the commit point — a
44286
+ * successful explicit save clears the history, after which Undo is disabled
44287
+ * until the user edits again.
44288
+ *
44289
+ * Ghost-link cleanup is the one exception to "never writes": when the revert
44290
+ * drops an item that a background auto-save had already linked, that link is
44291
+ * removed. Leaving it behind would resurrect the item on the next reload,
44292
+ * which is a bug in its own right rather than part of the undone state.
44133
44293
  */
44134
44294
  undo() {
44135
44295
  if (this.readonly())
@@ -44139,14 +44299,12 @@ class DashboardBuilder {
44139
44299
  this.flushPendingHistory();
44140
44300
  if (!this.undoStack.length)
44141
44301
  return;
44142
- // What is persisted right now, so we can reconcile the server below.
44143
44302
  const beforeItems = [...this.charts(), ...this.dialogs()];
44144
- const beforeFiltersSig = this.serializeFilters(this.filtersConfig());
44145
44303
  const previous = this.undoStack.pop();
44146
44304
  this.applyDashboardData(cloneDeep$1(previous));
44147
44305
  // Rebaseline to the ACTUAL restored document (applyDashboardData normalizes
44148
- // filters) so the history-capture effect treats this restore — and the
44149
- // persistence writes below — as a no-op rather than a fresh undoable change.
44306
+ // filters) so the history-capture effect treats this restore as a no-op
44307
+ // rather than a fresh undoable change.
44150
44308
  const restored = this.buildDashboardDataSnapshot();
44151
44309
  this.committedSnapshot = cloneDeep$1(restored);
44152
44310
  this.committedSignature = this.historySignature(restored);
@@ -44155,59 +44313,42 @@ class DashboardBuilder {
44155
44313
  this.undoStack.length = 0;
44156
44314
  this.canUndo.set(false);
44157
44315
  this.charts().forEach((chart) => this.reRenderItem(chart));
44316
+ // A reverted move/resize changes item geometry, so ask Gridster to lay the
44317
+ // grid out again rather than relying on per-item repositioning alone.
44318
+ this.gridsterContainer()?.updateGrid?.();
44158
44319
  const page = this.pageConfig();
44159
44320
  if (page)
44160
44321
  this.pageChange.emit(page);
44161
44322
  this.chartsChange.emit(this.charts());
44162
- // Standalone mode has no server; its `dashboardData` output already carries
44163
- // the reverted document via the emit effect.
44323
+ // Standalone mode has no backend links to clean up.
44164
44324
  if (this.standalone())
44165
44325
  return;
44166
- this.persistUndo(beforeItems, beforeFiltersSig, restored);
44326
+ this.unlinkItemsRemovedByUndo(beforeItems);
44167
44327
  }
44168
44328
  /**
44169
- * Roll the reverted document back to the server: unlink chart/dialog links
44170
- * the undo removed, re-save the restored charts/dialogs, and — only when they
44171
- * actually changed — rewrite the page filters. Each write is gated on a real
44172
- * diff so a layout/style undo doesn't rewrite filters and vice-versa.
44329
+ * Remove backend links for items the revert dropped.
44330
+ *
44331
+ * `saveDash` only ever upserts, so an already-linked item that is no longer
44332
+ * in the document would otherwise survive as an orphan and reappear on the
44333
+ * next load. This does NOT restore any other saved state — it only prevents
44334
+ * an item the user just undid from coming back.
44173
44335
  */
44174
- persistUndo(beforeItems, beforeFiltersSig, restored) {
44336
+ unlinkItemsRemovedByUndo(beforeItems) {
44175
44337
  const reportId = this.pageId();
44176
44338
  if (!reportId)
44177
44339
  return;
44178
- const currentItems = [...this.charts(), ...this.dialogs()];
44179
- const currentIds = new Set(currentItems
44340
+ const currentIds = new Set([...this.charts(), ...this.dialogs()]
44180
44341
  .map((it) => it.config?.serviceConfig?.dashboardId)
44181
44342
  .filter((v) => v != null));
44182
- // Unlink items that were persisted before but the undo removed.
44183
- const removed = beforeItems.filter((it) => it.chartComponentId != null &&
44184
- !currentIds.has(it.config?.serviceConfig?.dashboardId));
44185
- removed.forEach((it) => this.dashboardService
44343
+ beforeItems
44344
+ .filter((it) => it.chartComponentId != null &&
44345
+ !currentIds.has(it.config?.serviceConfig?.dashboardId))
44346
+ .forEach((it) => this.dashboardService
44186
44347
  .unlinkChart({
44187
44348
  reportId: Number(reportId),
44188
44349
  chartComponentId: it.chartComponentId,
44189
44350
  }, { silent: true })
44190
44351
  .subscribe({ next: () => { }, error: () => { } }));
44191
- // Re-save charts/dialogs when the item set / layout / config changed.
44192
- const itemsChanged = removed.length > 0 ||
44193
- this.serializeItems(currentItems) !== this.serializeItems(beforeItems);
44194
- if (itemsChanged) {
44195
- this.saveDash({ silent: true });
44196
- }
44197
- // Rewrite page filters only when they changed (updateReport is not silent,
44198
- // so gating avoids a spurious toast on every unrelated undo).
44199
- const afterFiltersSig = this.serializeFilters(restored.filters ?? []);
44200
- if (afterFiltersSig !== beforeFiltersSig) {
44201
- this.persistPageFilters();
44202
- }
44203
- }
44204
- /** Serialize page filters for change detection (normalized, order-stable). */
44205
- serializeFilters(filters) {
44206
- return JSON.stringify(this.normalizeFiltersConfig(filters));
44207
- }
44208
- /** Serialize items ignoring link ids so persistence metadata isn't compared. */
44209
- serializeItems(items) {
44210
- return JSON.stringify(items.map((it) => this.stripLinkIds(it)));
44211
44352
  }
44212
44353
  /**
44213
44354
  * Content signature of the whole document with link ids stripped, so a save
@@ -44298,6 +44439,9 @@ class DashboardBuilder {
44298
44439
  applyDashboardData(data) {
44299
44440
  const filters = data.filters ?? data.page?.dashboardConfig?.filters;
44300
44441
  this.applyingDashboardData = true;
44442
+ // The whole item set is being replaced (standalone apply or undo restore),
44443
+ // so previously recorded geometries no longer describe these charts.
44444
+ this.resetItemGeometryTracking();
44301
44445
  this.pageConfig.set(data.page ?? null);
44302
44446
  this.charts.set(data.charts ?? []);
44303
44447
  this.dialogs.set(data.dialogs ?? []);
@@ -44918,6 +45062,12 @@ class DashboardViewer {
44918
45062
  this.closeFiltersPanel();
44919
45063
  this.subscription.unsubscribe();
44920
45064
  this.storeService.updateQueryParams({});
45065
+ // The published route is a root-provided singleton. Leaving ours behind
45066
+ // made a later host (e.g. the builder) resolve `navigateToPage` relative to
45067
+ // a dead viewer route. Only retract it if it is still ours.
45068
+ if (this.route && this.dashboardService.activatedRoute() === this.route) {
45069
+ this.dashboardService.setActivatedRoute(null);
45070
+ }
44921
45071
  }
44922
45072
  setupSubscriptions() {
44923
45073
  // Publish our route so ActionService.navigateToPage can resolve sibling
@@ -45666,7 +45816,7 @@ class DashboardList {
45666
45816
  this.dashboards.reload();
45667
45817
  }
45668
45818
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: DashboardList, deps: [], target: i0.ɵɵFactoryTarget.Component });
45669
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: DashboardList, isStandalone: true, selector: "mt-dashboard-list", inputs: { isPage: { classPropertyName: "isPage", publicName: "isPage", isSignal: true, isRequired: false, transformFunction: null }, pageTitle: { classPropertyName: "pageTitle", publicName: "pageTitle", isSignal: true, isRequired: false, transformFunction: null }, baseRoute: { classPropertyName: "baseRoute", publicName: "baseRoute", isSignal: true, isRequired: false, transformFunction: null }, showCreateButton: { classPropertyName: "showCreateButton", publicName: "showCreateButton", isSignal: true, isRequired: false, transformFunction: null }, showViewButton: { classPropertyName: "showViewButton", publicName: "showViewButton", isSignal: true, isRequired: false, transformFunction: null }, showEditButton: { classPropertyName: "showEditButton", publicName: "showEditButton", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dashboardAction: "dashboardAction", dashboardCreated: "dashboardCreated" }, viewQueries: [{ propertyName: "nameTpl", first: true, predicate: ["nameTpl"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder.dashboard'\">\r\n <!-- Page mode -->\r\n @if (isPage()) {\r\n <mt-page [title]=\"pageTitle() || t('dashboards')\">\r\n <!-- Header actions -->\r\n <ng-template #headerEnd>\r\n @if (showCreateButton()) {\r\n <mt-button\r\n [label]=\"t('createDashboard')\"\r\n icon=\"general.plus\"\r\n (onClick)=\"openCreateModal()\"\r\n severity=\"primary\"\r\n size=\"small\"\r\n />\r\n }\r\n </ng-template>\r\n\r\n <!-- Content -->\r\n <ng-container *ngTemplateOutlet=\"tableContent\" />\r\n </mt-page>\r\n } @else {\r\n <!-- Non-page mode -->\r\n <div class=\"dashboard-list space-y-3\">\r\n <!-- Header -->\r\n <div class=\"flex justify-between items-center gap-4\">\r\n <h2 class=\"text-2xl font-semibold text-surface-900 dark:text-surface-0\">\r\n {{ t(\"dashboards\") }}\r\n </h2>\r\n\r\n @if (showCreateButton()) {\r\n <mt-button\r\n [label]=\"t('createDashboard')\"\r\n icon=\"general.plus\"\r\n (onClick)=\"openCreateModal()\"\r\n severity=\"primary\"\r\n />\r\n }\r\n </div>\r\n\r\n <!-- Content -->\r\n <ng-container *ngTemplateOutlet=\"tableContent\" />\r\n </div>\r\n }\r\n\r\n <!-- Reusable table content template -->\r\n <ng-template #tableContent>\r\n <!-- Custom cell templates -->\r\n <ng-template #nameTpl let-row>\r\n <span class=\"font-semibold text-surface-900 dark:text-surface-0\">\r\n {{ getDashboardName(row) }}\r\n </span>\r\n </ng-template>\r\n\r\n <!-- Dashboard Table -->\r\n <mt-table\r\n [data]=\"dashboardList()\"\r\n [columns]=\"tableColumns()\"\r\n [rowActions]=\"rowActions()\"\r\n [loading]=\"isLoading()\"\r\n [showFilters]=\"true\"\r\n [generalSearch]=\"true\"\r\n dataKey=\"id\"\r\n storageKey=\"dashboard-list-table\"\r\n (cellChange)=\"onToggleChange($event)\"\r\n />\r\n </ng-template>\r\n</ng-container>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: Table, selector: "mt-table", inputs: ["filters", "data", "columns", "rowActions", "size", "showGridlines", "stripedRows", "selectableRows", "clickableRows", "generalSearch", "lazyLocalSearch", "showFilters", "filterMode", "loading", "updating", "lazy", "lazyLocalSort", "lazyTotalRecords", "reorderableColumns", "reorderableRows", "dataKey", "storageKey", "storageMode", "persistStateExclude", "exportable", "printable", "groupable", "groupCountMap", "cellClickFilter", "freezeActions", "virtualScroll", "virtualScrollItemSize", "scrollHeight", "printTitle", "exportFilename", "actionShape", "rowActionsLoadingFn", "tableLayout", "noCard", "tabs", "tabsOptionLabel", "tabsOptionValue", "activeTab", "actions", "paginatorPosition", "alwaysShowPaginator", "rowsPerPageOptions", "pageSize", "currentPage", "first", "filterTerm", "groupBy"], outputs: ["selectionChange", "cellChange", "lazyLoad", "columnReorder", "rowReorder", "rowClick", "rowActionsRequested", "filtersChange", "activeTabChange", "onTabChange", "pageSizeChange", "currentPageChange", "firstChange", "filterTermChange", "groupByChange"] }, { kind: "component", type: Page, selector: "mt-page", inputs: ["backButton", "backButtonIcon", "avatarIcon", "avatarStyle", "avatarShape", "title", "tabs", "activeTab", "contentClass", "contentId"], outputs: ["backButtonClick", "tabChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
45819
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: DashboardList, isStandalone: true, selector: "mt-dashboard-list", inputs: { isPage: { classPropertyName: "isPage", publicName: "isPage", isSignal: true, isRequired: false, transformFunction: null }, pageTitle: { classPropertyName: "pageTitle", publicName: "pageTitle", isSignal: true, isRequired: false, transformFunction: null }, baseRoute: { classPropertyName: "baseRoute", publicName: "baseRoute", isSignal: true, isRequired: false, transformFunction: null }, showCreateButton: { classPropertyName: "showCreateButton", publicName: "showCreateButton", isSignal: true, isRequired: false, transformFunction: null }, showViewButton: { classPropertyName: "showViewButton", publicName: "showViewButton", isSignal: true, isRequired: false, transformFunction: null }, showEditButton: { classPropertyName: "showEditButton", publicName: "showEditButton", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dashboardAction: "dashboardAction", dashboardCreated: "dashboardCreated" }, viewQueries: [{ propertyName: "nameTpl", first: true, predicate: ["nameTpl"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-container *transloco=\"let t; prefix: 'dashboardBuilder.dashboard'\">\r\n <!-- Page mode -->\r\n @if (isPage()) {\r\n <mt-page [title]=\"pageTitle() || t('dashboards')\">\r\n <!-- Header actions -->\r\n <ng-template #headerEnd>\r\n @if (showCreateButton()) {\r\n <mt-button\r\n [label]=\"t('createDashboard')\"\r\n icon=\"general.plus\"\r\n (onClick)=\"openCreateModal()\"\r\n severity=\"primary\"\r\n size=\"small\"\r\n />\r\n }\r\n </ng-template>\r\n\r\n <!-- Content -->\r\n <ng-container *ngTemplateOutlet=\"tableContent\" />\r\n </mt-page>\r\n } @else {\r\n <!-- Non-page mode -->\r\n <div class=\"dashboard-list space-y-3\">\r\n <!-- Header -->\r\n <div class=\"flex justify-between items-center gap-4\">\r\n <h2 class=\"text-2xl font-semibold text-surface-900 dark:text-surface-0\">\r\n {{ t(\"dashboards\") }}\r\n </h2>\r\n\r\n @if (showCreateButton()) {\r\n <mt-button\r\n [label]=\"t('createDashboard')\"\r\n icon=\"general.plus\"\r\n (onClick)=\"openCreateModal()\"\r\n severity=\"primary\"\r\n />\r\n }\r\n </div>\r\n\r\n <!-- Content -->\r\n <ng-container *ngTemplateOutlet=\"tableContent\" />\r\n </div>\r\n }\r\n\r\n <!-- Reusable table content template -->\r\n <ng-template #tableContent>\r\n <!-- Custom cell templates -->\r\n <ng-template #nameTpl let-row>\r\n <span class=\"font-semibold text-surface-900 dark:text-surface-0\">\r\n {{ getDashboardName(row) }}\r\n </span>\r\n </ng-template>\r\n\r\n <!-- Dashboard Table -->\r\n <mt-table\r\n [data]=\"dashboardList()\"\r\n [columns]=\"tableColumns()\"\r\n [rowActions]=\"rowActions()\"\r\n [loading]=\"isLoading()\"\r\n [showFilters]=\"true\"\r\n [generalSearch]=\"true\"\r\n dataKey=\"id\"\r\n storageKey=\"dashboard-list-table\"\r\n (cellChange)=\"onToggleChange($event)\"\r\n />\r\n </ng-template>\r\n</ng-container>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: Table, selector: "mt-table", inputs: ["filters", "data", "columns", "rowActions", "size", "showGridlines", "stripedRows", "selectableRows", "clickableRows", "generalSearch", "lazyLocalSearch", "showFilters", "filterMode", "loading", "updating", "lazy", "lazyLocalSort", "lazyTotalRecords", "reorderableColumns", "reorderableRows", "dataKey", "storageKey", "storageMode", "persistStateExclude", "exportable", "printable", "groupable", "groupCountMap", "cellClickFilter", "freezeActions", "virtualScroll", "virtualScrollItemSize", "scrollHeight", "printTitle", "exportFilename", "actionShape", "rowActionsLoadingFn", "tableLayout", "noCard", "tabs", "tabsOptionLabel", "tabsOptionValue", "activeTab", "actions", "paginatorPosition", "alwaysShowPaginator", "rowsPerPageOptions", "pageSize", "currentPage", "first", "filterTerm", "groupBy", "sortField", "sortDirection"], outputs: ["selectionChange", "cellChange", "lazyLoad", "columnReorder", "rowReorder", "rowClick", "rowActionsRequested", "filtersChange", "activeTabChange", "onTabChange", "pageSizeChange", "currentPageChange", "firstChange", "filterTermChange", "groupByChange", "sortFieldChange", "sortDirectionChange"] }, { kind: "component", type: Page, selector: "mt-page", inputs: ["backButton", "backButtonIcon", "avatarIcon", "avatarStyle", "avatarShape", "title", "tabs", "activeTab", "contentClass", "contentId"], outputs: ["backButtonClick", "tabChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
45670
45820
  }
45671
45821
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: DashboardList, decorators: [{
45672
45822
  type: Component,
@@ -48686,4 +48836,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
48686
48836
  */
48687
48837
 
48688
48838
  export { RingGaugeChartHandler as $, StatisticCardComponent as A, TopbarCardComponent as B, CardContentComponent as C, DashboardItemStoreService as D, EChartComponent as E, FilterUtilsService as F, ChartDataService as G, HeaderCardComponent as H, BarChartHandler as I, PieChartHandler as J, StackBarChartHandler as K, LastHistoryLevelCardComponent as L, axisFormatters as M, groupDatesByYearAndMonth as N, GaugeChartHandler as O, PropertiesCardComponent as P, TableViewHandler as Q, OverviewCardHandler as R, StaticFiltersComponent as S, TableCardComponent as T, TimelineHandler as U, LineChartHandler as V, SnapshotHandler as W, ComparisonChartHandler as X, SplitterChartHandler as Y, LevelCardHandler as Z, MapChartHandler as _, DashboardItem as a, normalizeAggregateFunction as a$, SPlusChartHandler as a0, PhaseGateStepperHandler as a1, formatCurrency as a2, getCurrencySuffix as a3, formatPercentage as a4, formatNumber as a5, formatDate as a6, createAxisFormatter as a7, createTooltipFormatter as a8, formatAxisLabel as a9, ChartViewer as aA, StyleStudioDrawer as aB, StyleSettingsRenderer as aC, expandResetPatches as aD, StyleField as aE, SegmentedField as aF, ColorListField as aG, ArrayBuilderField as aH, KeyValueMapField as aI, LegendOrderField as aJ, ItemCardMenuComponent as aK, ChartFilterDrawer as aL, ItemContextToolbarComponent as aM, ItemConfigPopoverComponent as aN, GuidedConfigDialogComponent as aO, FilterChipsBarComponent as aP, FilterBuilderComponent as aQ, DatasourcePanelComponent as aR, SchemaControlRendererComponent as aS, FilterByGroupPipe as aT, GetChartActionsPipe as aU, CHART_CAPABILITIES as aV, getCapabilityById as aW, resolveCapability as aX, toBackendChartType as aY, normalizeChartTypeForRequest as aZ, normalizeFilterOperation as a_, formatWordsUnderBar as aa, formatXAxis as ab, handleFiltersForCustom as ac, handleFilterForCard as ad, handleFilterForSnapshot as ae, DashboardList as af, HTTPMethod as ag, DashboardBuilderService as ah, DashboardStoreService as ai, isManagePagesDeleteResult as aj, ManagePages as ak, ManageBreadcrumb as al, ManageFilterOnPage as am, DynamicFiltersConfig as an, ChartSettingsDrawer as ao, DisplaySettings as ap, DefaultControlUi as aq, PieControlUi as ar, BarControlUi as as, StackBarControlUi as at, ManageItem as au, CHART_TYPES as av, ManageItemService as aw, GeneralSettings as ax, DataSourceSettings as ay, ActionsSettings as az, DashboardBuilder as b, normalizeFilters as b0, selectorFromLegacy as b1, moduleIdFromSelector as b2, toBackendSourceLink as b3, toFormSourceLink as b4, normalizeOnLoad as b5, normalizeBeforeSave as b6, normalizeBeforeRequest as b7, CONFIG_DOMAINS as b8, domainsForCapability as b9, deepMerge$1 as bA, formatForEditor as bB, readByPath$1 as bC, setByPath as bD, applyControlPatchToPersisted as bE, applyControlPatchesToPersisted as bF, getControlSchema as bG, listControlSchemaIds as bH, listControlSchemas as bI, getFallbackControlSchema as bJ, flattenSchema as bK, resolveDisplayFields as bL, buildDisplayFieldPredicate as bM, bindingKey as bN, getBinding as bO, listBindings as bP, listBindingsForChart as bQ, readBoundValue as bR, ITEM_GUIDANCE_REGISTRY as bS, describeGuidance as bT, ItemGuidanceService as bU, findDomain as ba, POPOVER_TABS as bb, POPOVER_TAB_SPECS as bc, titleToUi as bd, applyTitleToPersisted as be, datasourceToUi as bf, fieldsToUi as bg, filtersToUi as bh, styleToUi as bi, applyStyleToPersisted as bj, layoutToUi as bk, applyLayoutToPersisted as bl, labelLegendFormatToUi as bm, applyLabelLegendFormatToPersisted as bn, behaviorToUi as bo, applyBehaviorToPersisted as bp, applyFilterChipsToPersisted as bq, persistedToUi as br, buildAssembly as bs, STYLE_PRESETS as bt, presetsForCapability as bu, findPreset as bv, validate as bw, hasBlockingIssues as bx, groupIssuesByDomain as by, parseAdvancedJson as bz, cloneDeep$1 as c, DashboardViewer as d, switchAllKeysSmall$1 as e, dynamicTextReplace as f, getNestedData as g, dynamicReorder as h, generalConfiguration as i, formatValue as j, getLocalizedTitle as k, sortChartData as l, addCommasToNumber as m, sortDataTableView as n, isMobilePlatform$1 as o, getColorFromConditions as p, CardFilterComponent as q, DynamicFiltersComponent as r, switchAllKeysToLower as s, CardInfoComponent as t, ChartCardComponent as u, EntityInfoComponent as v, normalizeDashboardCardEntityValue as w, EntityPreviewCardComponent as x, ListStatisticCardComponent as y, SkeletonCardComponent as z };
48689
- //# sourceMappingURL=masterteam-dashboard-builder-masterteam-dashboard-builder-B2u_ZfFj.mjs.map
48839
+ //# sourceMappingURL=masterteam-dashboard-builder-masterteam-dashboard-builder-DTbSru5t.mjs.map