@meshmakers/octo-meshboard 3.4.210 → 3.4.220

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meshmakers/octo-meshboard",
3
- "version": "3.4.210",
3
+ "version": "3.4.220",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^22.0.0",
6
6
  "@angular/core": "^22.0.0",
@@ -161,6 +161,28 @@ interface ProcessWidgetConfig extends WidgetConfig, ProcessWidgetSpecificConfig
161
161
  * Display name of the persistent query (for UI)
162
162
  */
163
163
  bindingQueryName?: string;
164
+ /**
165
+ * Query family of the bound persistent query: `'runtime'` or `'streamData'`.
166
+ * Derived from the query's `queryCkTypeId` when absent (one-time lookup by the
167
+ * executor). Persisted so a stream-data binding picks the correct executor
168
+ * without an extra round-trip — switching runtime ↔ stream-data is a config
169
+ * change, not a different widget.
170
+ */
171
+ bindingQueryFamily?: QueryFamily;
172
+ /**
173
+ * Stream-data opt-out: when `true`, the MeshBoard time filter is NOT bound to
174
+ * the bound query's `streamDataArgs.from/.to`, so the query's intrinsic time
175
+ * bounds win. Default (absent/`false`) auto-binds the active time filter.
176
+ * Ignored for runtime queries (they don't consume `streamDataArgs`).
177
+ */
178
+ bindingIgnoreTimeFilter?: boolean;
179
+ /**
180
+ * Asset-scope binding: the `id` of an entity selector whose selection scopes
181
+ * the bound stream-data query. The selector's resolved source rtIds are passed
182
+ * as `streamDataArgs.rtIds`, replacing the persisted scope at execution time.
183
+ * Ignored for runtime queries.
184
+ */
185
+ bindingEntitySelectorId?: string;
164
186
  /**
165
187
  * Field filters applied to the data binding query
166
188
  * Works with both runtimeEntity and persistentQuery modes
@@ -202,10 +224,27 @@ interface WidgetDataSource {
202
224
  */
203
225
  interface RuntimeEntityDataSource extends WidgetDataSource {
204
226
  type: 'runtimeEntity';
227
+ /**
228
+ * CK type of the entity. May contain a MeshBoard variable (e.g.
229
+ * `$mp_rtCkTypeId`) which is resolved against the active variables before the
230
+ * entity is fetched.
231
+ */
205
232
  ckTypeId?: string;
233
+ /**
234
+ * Runtime id of the entity. May contain a MeshBoard variable (e.g. `$mp_rtId`)
235
+ * which is resolved against the active variables before the entity is fetched.
236
+ */
206
237
  rtId?: string;
207
238
  attributePaths?: string[];
208
239
  includeAssociations?: boolean;
240
+ /**
241
+ * Entity-selector binding: the `id` of a MeshBoard entity selector whose
242
+ * current selection supplies this widget's entity. When set, the selector's
243
+ * `selectedRtId` and the picked entity's CK type (`$<id>_rtCkTypeId`) override
244
+ * `rtId`/`ckTypeId`, so the widget follows the asset picked at board level.
245
+ * Absent ⇒ the literal (optionally variable-bearing) `rtId`/`ckTypeId` win.
246
+ */
247
+ entitySelectorId?: string;
209
248
  }
210
249
  /**
211
250
  * Static data source for demo/testing or variable-based display
@@ -719,6 +758,48 @@ interface HeatmapWidgetConfig extends WidgetConfig {
719
758
  /** Field filters for data source */
720
759
  filters?: WidgetFilterConfig[];
721
760
  }
761
+ /**
762
+ * Query mode for a persistent-query cell source — how the single displayed value
763
+ * is derived from the query result. Mirrors the KPI/gauge widget query modes.
764
+ */
765
+ type PersistentQueryCellMode = 'simpleCount' | 'aggregation' | 'groupedAggregation';
766
+ /**
767
+ * A single-value data source backed by a persistent query (runtime OR stream-data).
768
+ *
769
+ * Used per-cell by aggregation-style widgets (stats-grid stat, summary-card tile)
770
+ * as an alternative to their built-in runtime aggregation source. Switching a cell
771
+ * between runtime and stream-data is a configuration change (the `queryFamily`
772
+ * discriminator picks the executor), not a different widget — mirroring how the
773
+ * KPI/gauge widgets consume {@link PersistentQueryDataSource}.
774
+ */
775
+ interface PersistentQueryCellSource {
776
+ /** The rtId of the persistent query to execute. */
777
+ queryRtId: string;
778
+ /** Display name of the query (for UI). */
779
+ queryName?: string;
780
+ /** Query family: 'runtime' or 'streamData'. Derived from the query's CK type when absent. */
781
+ queryFamily?: QueryFamily;
782
+ /**
783
+ * Stream-data opt-out: when `true`, the MeshBoard time filter is NOT bound to
784
+ * the query's `streamDataArgs.from/.to`. Ignored for runtime queries.
785
+ */
786
+ ignoreTimeFilter?: boolean;
787
+ /**
788
+ * Asset-scope binding: the `id` of an entity selector whose selection scopes the
789
+ * stream-data query via `streamDataArgs.rtIds`. Ignored for runtime queries.
790
+ */
791
+ entitySelectorId?: string;
792
+ /** How to reduce the query result to one value. */
793
+ queryMode: PersistentQueryCellMode;
794
+ /** Value column for `aggregation` / `groupedAggregation` modes. */
795
+ queryValueField?: string;
796
+ /** Category column for `groupedAggregation` mode. */
797
+ queryCategoryField?: string;
798
+ /** Category value to match for `groupedAggregation` mode. */
799
+ queryCategoryValue?: string;
800
+ /** Field filters applied to the query rows. */
801
+ filters?: WidgetFilterConfig[];
802
+ }
722
803
  /**
723
804
  * Color options for stat items
724
805
  */
@@ -729,8 +810,16 @@ type StatColor = 'mint' | 'cyan' | 'violet' | 'toffee' | 'lilac' | 'bubblegum' |
729
810
  interface StatItem {
730
811
  /** Display label */
731
812
  label: string;
732
- /** Reference to aggregation query ID */
813
+ /**
814
+ * Reference to the aggregation query ID in the widget's `AggregationDataSource`.
815
+ * Used when `persistentQuerySource` is absent (the default runtime aggregation).
816
+ */
733
817
  queryId: string;
818
+ /**
819
+ * Optional per-stat persistent-query source (runtime or stream-data). When set,
820
+ * it supersedes `queryId` / the aggregation source for this stat.
821
+ */
822
+ persistentQuerySource?: PersistentQueryCellSource;
734
823
  /** Color variant */
735
824
  color?: StatColor;
736
825
  /** Number format */
@@ -911,6 +1000,11 @@ interface SummaryCardTile {
911
1000
  attribute?: string;
912
1001
  filters?: WidgetFilterConfig[];
913
1002
  };
1003
+ /**
1004
+ * Fetch a single value from a persistent query (runtime or stream-data). When
1005
+ * set, it supersedes `entitySource` / `aggregationSource` for this tile.
1006
+ */
1007
+ persistentQuerySource?: PersistentQueryCellSource;
914
1008
  }
915
1009
  interface AlertBannerWidgetConfig extends WidgetConfig {
916
1010
  type: 'alertBanner';
@@ -996,6 +1090,22 @@ type TimeRangeType = 'year' | 'quarter' | 'month' | 'day' | 'relative' | 'custom
996
1090
  * Time units for relative time ranges
997
1091
  */
998
1092
  type RelativeTimeUnit = 'hours' | 'days' | 'weeks' | 'months';
1093
+ /**
1094
+ * Timezone basis the MeshBoard uses for BOTH the time-filter boundary
1095
+ * computation and the display of every datetime value across all widgets.
1096
+ *
1097
+ * - `'local'` (default): the browser's local timezone. "Year 2026" spans the
1098
+ * local calendar year and datetime cells render in local wall-clock time.
1099
+ * - `'utc'`: UTC. "Year 2026" spans the UTC calendar year and datetime cells
1100
+ * render in UTC.
1101
+ *
1102
+ * Keeping filter and display on the same basis avoids the boundary artifact
1103
+ * where a local-year filter selects rows whose UTC timestamps fall in the
1104
+ * neighbouring calendar year. Mirrors shared-ui's `TimeRangeZone`.
1105
+ */
1106
+ type MeshBoardTimeZoneMode = 'local' | 'utc';
1107
+ /** The board-level default timezone mode applied when none is persisted. */
1108
+ declare const DEFAULT_TIME_ZONE_MODE: MeshBoardTimeZoneMode;
999
1109
  /**
1000
1110
  * Quarter number (1-4)
1001
1111
  */
@@ -1128,6 +1238,11 @@ interface MeshBoardConfig {
1128
1238
  variables?: MeshBoardVariable[];
1129
1239
  /** Optional time filter configuration */
1130
1240
  timeFilter?: MeshBoardTimeFilterConfig;
1241
+ /**
1242
+ * Timezone basis for time-filter boundaries and datetime display across all
1243
+ * widgets. `undefined` ⇒ {@link DEFAULT_TIME_ZONE_MODE} (`'local'`).
1244
+ */
1245
+ timeZoneMode?: MeshBoardTimeZoneMode;
1131
1246
  /** Entity selector configurations for the toolbar */
1132
1247
  entitySelectors?: EntitySelectorConfig[];
1133
1248
  /**
@@ -1640,6 +1755,12 @@ declare class MeshBoardStateService {
1640
1755
  readonly widgets: _angular_core.Signal<AnyWidgetConfig[]>;
1641
1756
  readonly isModelAvailable: _angular_core.Signal<boolean | null>;
1642
1757
  readonly variableResolutionErrors: _angular_core.Signal<VariableResolutionError[]>;
1758
+ /**
1759
+ * The board's effective timezone mode (defaults to `'local'`). Drives both the
1760
+ * time-filter boundary computation and datetime display across all widgets.
1761
+ * Widgets read this to format timestamps consistently with the active filter.
1762
+ */
1763
+ readonly timeZoneMode: _angular_core.Signal<MeshBoardTimeZoneMode>;
1643
1764
  /** @deprecated Use meshBoardConfig instead */
1644
1765
  readonly dashboardConfig: _angular_core.Signal<MeshBoardConfig>;
1645
1766
  /** @deprecated Use persistedMeshBoardId instead */
@@ -1716,6 +1837,7 @@ declare class MeshBoardStateService {
1716
1837
  gap: number;
1717
1838
  variables?: MeshBoardVariable[];
1718
1839
  timeFilter?: MeshBoardTimeFilterConfig;
1840
+ timeZoneMode?: MeshBoardTimeZoneMode;
1719
1841
  entitySelectors?: EntitySelectorConfig[];
1720
1842
  autoRefreshSeconds?: number;
1721
1843
  }): void;
@@ -1731,6 +1853,7 @@ declare class MeshBoardStateService {
1731
1853
  gap: number;
1732
1854
  variables: MeshBoardVariable[];
1733
1855
  timeFilter?: MeshBoardTimeFilterConfig;
1856
+ timeZoneMode?: MeshBoardTimeZoneMode;
1734
1857
  entitySelectors?: EntitySelectorConfig[];
1735
1858
  autoRefreshSeconds?: number;
1736
1859
  };
@@ -1809,8 +1932,9 @@ declare class MeshBoardStateService {
1809
1932
  * Stream-data persistent queries consume this to bound their result set;
1810
1933
  * runtime queries ignore it.
1811
1934
  *
1812
- * IANA-timezone-aware bucket boundaries are tracked separately (AB#4190);
1813
- * this helper currently returns UTC boundaries derived from the picker.
1935
+ * Boundaries are resolved on the board's {@link timeZoneMode} basis (local by
1936
+ * default, or UTC), the same basis widgets format their datetime display on —
1937
+ * so the selected range and the displayed timestamps stay consistent.
1814
1938
  */
1815
1939
  resolveCurrentTimeRange(): TimeRange | null;
1816
1940
  /**
@@ -2447,19 +2571,17 @@ declare const DashboardGridService: typeof MeshBoardGridService;
2447
2571
  * without importing generated DTO types directly.
2448
2572
  *
2449
2573
  * Backend semantics (verified against StreamDataQueryDtoType.cs and
2450
- * StreamDataVariantExecutor.cs as of 2026-06-24):
2574
+ * StreamDataVariantExecutor.cs; `queryMode` override added in AB#4233):
2451
2575
  * - `from` / `to` / `limit` override the persisted query's intrinsic values
2452
2576
  * when set (`execOverride?.From ?? simple.From` pattern in the resolver).
2453
2577
  * - `interval` is currently ignored by every variant; the downsampling path
2454
2578
  * derives `(to - from) / limit` itself.
2455
- * - `queryMode` is **ignored on both persistent and transient dispatch** —
2456
- * the variant (Simple / Aggregation / GroupingAggregation / Downsampling)
2457
- * comes from the persisted entity's CK subtype or the transient query's
2458
- * GraphQL sub-connection URL. We still emit it because the schema declares
2459
- * `queryMode: QueryMode!` (NonNull); see backend cleanup issue.
2460
- *
2461
- * Don't pretend to override the mode from here — even if `queryMode: DOWNSAMPLING`
2462
- * is set on a `SimpleSdQuery`, the backend still runs the simple variant.
2579
+ * - `queryMode: DOWNSAMPLING` on a `SimpleSdQuery` (persisted) or the transient
2580
+ * `simple` sub-connection now drives the downsampling execution path: with a
2581
+ * full from/to/limit contract the backend reduces to `limit` buckets per series
2582
+ * (per-type reducers + group-by source rtId). Without all three it falls back
2583
+ * to raw rows. For the other variants the execution shape still comes from the
2584
+ * CK subtype / sub-connection; `queryMode` is a no-op there.
2463
2585
  */
2464
2586
  interface StreamDataExecutionArgs {
2465
2587
  from?: Date | null;
@@ -2467,8 +2589,9 @@ interface StreamDataExecutionArgs {
2467
2589
  interval?: number | null;
2468
2590
  limit?: number | null;
2469
2591
  /**
2470
- * Currently a no-op on the dispatch side; kept because the GraphQL input
2471
- * schema marks `queryMode` non-null. Defaults to `Default`.
2592
+ * `DOWNSAMPLING` switches a SimpleSdQuery / transient `simple` query to the
2593
+ * downsampling path (with from/to/limit); a no-op for the other variants.
2594
+ * Defaults to `Default` (raw rows).
2472
2595
  */
2473
2596
  queryMode?: QueryModeDto;
2474
2597
  /**
@@ -2610,6 +2733,8 @@ declare class AutoRefreshTimerService implements OnDestroy {
2610
2733
 
2611
2734
  declare class EntityCardWidgetComponent implements DashboardWidget<EntityCardWidgetConfig, RuntimeEntityData>, OnInit, OnChanges {
2612
2735
  private readonly dataService;
2736
+ private readonly stateService;
2737
+ private readonly variableService;
2613
2738
  config: EntityCardWidgetConfig;
2614
2739
  private readonly _isLoading;
2615
2740
  private readonly _data;
@@ -2635,18 +2760,47 @@ declare class EntityCardWidgetComponent implements DashboardWidget<EntityCardWid
2635
2760
  ngOnChanges(changes: SimpleChanges): void;
2636
2761
  refresh(): void;
2637
2762
  private loadData;
2763
+ /**
2764
+ * Message for the neutral empty state — shown when the widget IS configured
2765
+ * but no entity is currently resolved (e.g. a bound selector hasn't been
2766
+ * picked yet, or a variable is still unresolved). This is deliberately not the
2767
+ * red "not configured" placeholder, which would wrongly imply the widget needs
2768
+ * setup.
2769
+ */
2770
+ emptyMessage(): string;
2771
+ /**
2772
+ * Resolves the effective `{ rtId, ckTypeId }` to fetch from a runtime-entity
2773
+ * data source.
2774
+ *
2775
+ * - When `entitySelectorId` is set, the bound MeshBoard entity selector's
2776
+ * current `selectedRtId` and the picked entity's type
2777
+ * (`$<selectorId>_rtCkTypeId`, falling back to the selector's configured
2778
+ * `ckTypeId`) win — so the card follows the asset picked at board level.
2779
+ * - Otherwise the configured `rtId`/`ckTypeId` are resolved against the active
2780
+ * MeshBoard variables, allowing values like `$mp_rtId` / `$mp_rtCkTypeId`.
2781
+ */
2782
+ private resolveEntityRef;
2638
2783
  inferAttributeType(value: unknown): AttributeValueTypeDto;
2639
2784
  formatAttributeName(name: string): string;
2640
2785
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<EntityCardWidgetComponent, never>;
2641
2786
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<EntityCardWidgetComponent, "mm-entity-card-widget", never, { "config": { "alias": "config"; "required": false; }; }, {}, never, never, true, never>;
2642
2787
  }
2643
2788
 
2789
+ /** How the entity card resolves which entity to display. */
2790
+ type EntityCardBindingMode = 'fixed' | 'selector' | 'variable';
2644
2791
  /**
2645
- * Configuration result from the dialog
2792
+ * Configuration result from the dialog.
2793
+ *
2794
+ * - `fixed` mode → `ckTypeId`/`rtId` hold a concrete type + entity.
2795
+ * - `selector` mode → `entitySelectorId` names a board-level entity selector;
2796
+ * `ckTypeId`/`rtId` are empty (resolved live from the selection).
2797
+ * - `variable` mode → `ckTypeId`/`rtId` hold MeshBoard variables (e.g.
2798
+ * `$mp_rtCkTypeId` / `$mp_rtId`) resolved at render time.
2646
2799
  */
2647
2800
  interface EntityCardConfigResult {
2648
2801
  ckTypeId: string;
2649
2802
  rtId: string;
2803
+ entitySelectorId?: string;
2650
2804
  hideEmptyAttributes: boolean;
2651
2805
  }
2652
2806
  /**
@@ -2656,20 +2810,28 @@ interface EntityCardConfigResult {
2656
2810
  declare class EntityCardConfigDialogComponent implements OnInit {
2657
2811
  private readonly getEntitiesByCkTypeGQL;
2658
2812
  private readonly ckTypeSelectorService;
2813
+ private readonly stateService;
2659
2814
  private readonly windowRef;
2660
2815
  ckTypeSelectorInput?: CkTypeSelectorInputComponent;
2661
2816
  entitySelectorInput?: EntitySelectInputComponent;
2662
2817
  initialCkTypeId?: string;
2663
2818
  initialRtId?: string;
2819
+ initialEntitySelectorId?: string;
2664
2820
  initialHideEmptyAttributes: boolean;
2821
+ bindingMode: EntityCardBindingMode;
2665
2822
  selectedCkType: CkTypeSelectorItem | null;
2666
2823
  selectedEntity: RuntimeEntityItem$1 | null;
2667
2824
  entityDataSource?: RuntimeEntitySelectDataSource$1;
2668
2825
  entityDialogDataSource?: RuntimeEntityDialogDataSource$1;
2669
2826
  isLoadingInitial: boolean;
2670
2827
  hideEmptyAttributes: boolean;
2828
+ entitySelectorId: string;
2829
+ variableCkTypeId: string;
2830
+ variableRtId: string;
2831
+ get availableSelectors(): EntitySelectorConfig[];
2671
2832
  get isValid(): boolean;
2672
2833
  ngOnInit(): Promise<void>;
2834
+ private containsVariable;
2673
2835
  private loadInitialValues;
2674
2836
  private loadInitialEntity;
2675
2837
  onCkTypeSelected(ckType: CkTypeSelectorItem): void;
@@ -2679,7 +2841,7 @@ declare class EntityCardConfigDialogComponent implements OnInit {
2679
2841
  onSave(): void;
2680
2842
  onCancel(): void;
2681
2843
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<EntityCardConfigDialogComponent, never>;
2682
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<EntityCardConfigDialogComponent, "mm-entity-card-config-dialog", never, { "initialCkTypeId": { "alias": "initialCkTypeId"; "required": false; }; "initialRtId": { "alias": "initialRtId"; "required": false; }; "initialHideEmptyAttributes": { "alias": "initialHideEmptyAttributes"; "required": false; }; }, {}, never, never, true, never>;
2844
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<EntityCardConfigDialogComponent, "mm-entity-card-config-dialog", never, { "initialCkTypeId": { "alias": "initialCkTypeId"; "required": false; }; "initialRtId": { "alias": "initialRtId"; "required": false; }; "initialEntitySelectorId": { "alias": "initialEntitySelectorId"; "required": false; }; "initialHideEmptyAttributes": { "alias": "initialHideEmptyAttributes"; "required": false; }; }, {}, never, never, true, never>;
2683
2845
  }
2684
2846
 
2685
2847
  declare class KpiWidgetComponent implements DashboardWidget<KpiWidgetConfig, RuntimeEntityData>, OnInit, OnChanges {
@@ -2914,6 +3076,7 @@ interface TargetEntity {
2914
3076
  }
2915
3077
  declare class EntityAssociationsWidgetComponent implements DashboardWidget<EntityWithAssociationsWidgetConfig, RuntimeEntityData>, OnInit, OnChanges {
2916
3078
  private readonly dataService;
3079
+ private readonly stateService;
2917
3080
  config: EntityWithAssociationsWidgetConfig;
2918
3081
  protected readonly arrowRightIcon: _progress_kendo_svg_icons.SVGIcon;
2919
3082
  protected readonly arrowLeftIcon: _progress_kendo_svg_icons.SVGIcon;
@@ -3243,6 +3406,7 @@ declare class TableWidgetDataSourceDirective extends OctoGraphQlDataSource<Recor
3243
3406
  declare class TableWidgetComponent implements DashboardWidget<TableWidgetConfig, Record<string, unknown>[]>, OnChanges {
3244
3407
  config: TableWidgetConfig;
3245
3408
  dataSource?: TableWidgetDataSourceDirective;
3409
+ private readonly stateService;
3246
3410
  private readonly _isLoading;
3247
3411
  private readonly _data;
3248
3412
  private readonly _error;
@@ -4073,6 +4237,8 @@ declare class LineChartWidgetComponent implements DashboardWidget<LineChartWidge
4073
4237
  private formatDate;
4074
4238
  /**
4075
4239
  * Formats a date with time for display on the category axis.
4240
+ * Date and time parts are formatted separately (joined with a space) to keep
4241
+ * the compact axis label; both honor the board's timezone mode.
4076
4242
  */
4077
4243
  private formatDateTime;
4078
4244
  private sanitizeAxisName;
@@ -4259,7 +4425,6 @@ declare class HeatmapWidgetComponent implements DashboardWidget<HeatmapWidgetCon
4259
4425
  private assignColors;
4260
4426
  private aggregate;
4261
4427
  private parseDate;
4262
- private formatDateKey;
4263
4428
  private convertFiltersToDto;
4264
4429
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<HeatmapWidgetComponent, never>;
4265
4430
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<HeatmapWidgetComponent, "mm-heatmap-widget", never, { "config": { "alias": "config"; "required": false; }; }, {}, never, never, true, never>;
@@ -4378,6 +4543,9 @@ interface StatValue {
4378
4543
  }
4379
4544
  declare class StatsGridWidgetComponent implements OnInit, OnChanges {
4380
4545
  private readonly dataService;
4546
+ private readonly queryExecutor;
4547
+ private readonly stateService;
4548
+ private readonly variableService;
4381
4549
  config: StatsGridWidgetConfig;
4382
4550
  private readonly _isLoading;
4383
4551
  private readonly _error;
@@ -4394,6 +4562,14 @@ declare class StatsGridWidgetComponent implements OnInit, OnChanges {
4394
4562
  ngOnChanges(changes: SimpleChanges): void;
4395
4563
  refresh(): void;
4396
4564
  private loadData;
4565
+ /**
4566
+ * Resolves a single stat's value: a per-stat persistent query (runtime or
4567
+ * stream-data) when configured, otherwise the runtime aggregation result.
4568
+ */
4569
+ private resolveStatValue;
4570
+ private loadPersistentQueryValue;
4571
+ private buildStreamDataArgs;
4572
+ private convertFiltersToDto;
4397
4573
  private getColorClass;
4398
4574
  formatValue(stat: StatValue): string;
4399
4575
  get gridColumns(): number;
@@ -4407,6 +4583,7 @@ interface StatsGridConfigResult extends WidgetConfigResult {
4407
4583
  queries: AggregationQuery[];
4408
4584
  columns: number;
4409
4585
  }
4586
+ type StatSourceType = 'aggregation' | 'persistentQuery';
4410
4587
  interface ColorOption {
4411
4588
  value: StatColor;
4412
4589
  label: string;
@@ -4419,17 +4596,25 @@ interface CkTypeOption {
4419
4596
  interface EditableStat {
4420
4597
  id: string;
4421
4598
  label: string;
4599
+ sourceType: StatSourceType;
4422
4600
  ckTypeId: string;
4423
4601
  aggregation: AggregationType;
4602
+ persistentQuerySource?: PersistentQueryCellSource;
4424
4603
  color: StatColor;
4425
4604
  prefix?: string;
4426
4605
  suffix?: string;
4427
4606
  }
4428
4607
  declare class StatsGridConfigDialogComponent implements OnInit {
4429
4608
  private readonly windowRef;
4609
+ private readonly stateService;
4430
4610
  initialStats?: StatItem[];
4431
4611
  initialQueries?: AggregationQuery[];
4432
4612
  initialColumns?: number;
4613
+ entitySelectors: EntitySelectorConfig[];
4614
+ sourceTypeOptions: {
4615
+ value: StatSourceType;
4616
+ label: string;
4617
+ }[];
4433
4618
  colorOptions: ColorOption[];
4434
4619
  ckTypeOptions: CkTypeOption[];
4435
4620
  filteredCkTypeOptions: CkTypeOption[];
@@ -4914,6 +5099,9 @@ interface TileValue {
4914
5099
  declare class SummaryCardWidgetComponent implements DashboardWidget<SummaryCardWidgetConfig, TileValue[]>, OnInit, OnChanges {
4915
5100
  private readonly entityGQL;
4916
5101
  private readonly dataService;
5102
+ private readonly queryExecutor;
5103
+ private readonly stateService;
5104
+ private readonly variableService;
4917
5105
  config: SummaryCardWidgetConfig;
4918
5106
  private readonly _isLoading;
4919
5107
  private readonly _error;
@@ -4928,6 +5116,9 @@ declare class SummaryCardWidgetComponent implements DashboardWidget<SummaryCardW
4928
5116
  refresh(): void;
4929
5117
  private loadData;
4930
5118
  private fetchTileValue;
5119
+ private fetchPersistentQueryValue;
5120
+ private buildStreamDataArgs;
5121
+ private convertFiltersToDto;
4931
5122
  private fetchEntityAttributes;
4932
5123
  private formatValue;
4933
5124
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<SummaryCardWidgetComponent, never>;
@@ -4938,6 +5129,7 @@ interface SummaryCardConfigResult extends WidgetConfigResult {
4938
5129
  columns: number;
4939
5130
  tiles: SummaryCardTile[];
4940
5131
  }
5132
+ type TileSourceType = 'entity' | 'aggregation' | 'persistentQuery';
4941
5133
  interface EditableTile {
4942
5134
  id: string;
4943
5135
  label: string;
@@ -4945,24 +5137,27 @@ interface EditableTile {
4945
5137
  suffix: string;
4946
5138
  color: string;
4947
5139
  size: string;
4948
- sourceType: 'entity' | 'aggregation';
5140
+ sourceType: TileSourceType;
4949
5141
  rtId: string;
4950
5142
  ckTypeId: string;
4951
5143
  attributePath: string;
4952
5144
  aggregation: string;
4953
5145
  aggAttribute: string;
5146
+ persistentQuerySource?: PersistentQueryCellSource;
4954
5147
  }
4955
5148
  declare class SummaryCardConfigDialogComponent implements OnInit {
4956
5149
  private readonly windowRef;
5150
+ private readonly stateService;
4957
5151
  initialColumns?: number;
4958
5152
  initialTiles?: SummaryCardTile[];
5153
+ entitySelectors: EntitySelectorConfig[];
4959
5154
  form: {
4960
5155
  columns: number;
4961
5156
  tiles: EditableTile[];
4962
5157
  };
4963
5158
  colorOptions: string[];
4964
5159
  sizeOptions: string[];
4965
- sourceTypeOptions: string[];
5160
+ sourceTypeOptions: TileSourceType[];
4966
5161
  aggregationOptions: string[];
4967
5162
  get isValid(): boolean;
4968
5163
  ngOnInit(): void;
@@ -5032,6 +5227,7 @@ declare class AlertBannerConfigDialogComponent {
5032
5227
 
5033
5228
  declare class AlertListWidgetComponent implements DashboardWidget<AlertListWidgetConfig, AlertItem[]>, OnInit, OnChanges {
5034
5229
  private readonly getEntitiesByCkTypeGQL;
5230
+ private readonly stateService;
5035
5231
  config: AlertListWidgetConfig;
5036
5232
  private readonly _isLoading;
5037
5233
  private readonly _error;
@@ -5604,6 +5800,13 @@ declare class MeshBoardViewComponent implements OnInit, OnDestroy, HasUnsavedCha
5604
5800
  * URL params take precedence over stored selection to support page reload.
5605
5801
  */
5606
5802
  private initializeTimeFilterVariables;
5803
+ /**
5804
+ * Recomputes the active time-filter range from the current selection on the
5805
+ * board's (possibly just-changed) timezone mode and republishes the
5806
+ * `$timeRangeFrom`/`$timeRangeTo` variables. No-op when the filter is
5807
+ * disabled or no selection is active.
5808
+ */
5809
+ private reapplyTimeFilterRange;
5607
5810
  /**
5608
5811
  * Converts a TimeRangeSelection to a SharedTimeRangeSelection.
5609
5812
  */
@@ -5836,7 +6039,8 @@ declare class MeshBoardSettingsResult {
5836
6039
  rtWellKnownName?: string | undefined;
5837
6040
  entitySelectors?: EntitySelectorConfig[] | undefined;
5838
6041
  autoRefreshSeconds?: number | undefined;
5839
- constructor(name: string, description: string, columns: number, rowHeight: number, gap: number, variables: MeshBoardVariable[], timeFilter?: MeshBoardTimeFilterConfig | undefined, rtWellKnownName?: string | undefined, entitySelectors?: EntitySelectorConfig[] | undefined, autoRefreshSeconds?: number | undefined);
6042
+ timeZoneMode?: MeshBoardTimeZoneMode | undefined;
6043
+ constructor(name: string, description: string, columns: number, rowHeight: number, gap: number, variables: MeshBoardVariable[], timeFilter?: MeshBoardTimeFilterConfig | undefined, rtWellKnownName?: string | undefined, entitySelectors?: EntitySelectorConfig[] | undefined, autoRefreshSeconds?: number | undefined, timeZoneMode?: MeshBoardTimeZoneMode | undefined);
5840
6044
  }
5841
6045
  /**
5842
6046
  * Dialog for editing MeshBoard settings.
@@ -5862,6 +6066,11 @@ declare class MeshBoardSettingsDialogComponent {
5862
6066
  timeFilterEnabled: boolean;
5863
6067
  defaultSelection?: TimeRangeSelection;
5864
6068
  initialDefaultSelection?: TimeRangeSelection$1;
6069
+ /**
6070
+ * Timezone basis for time-filter boundaries and datetime display across all
6071
+ * widgets. Defaults to `'local'` (browser timezone).
6072
+ */
6073
+ timeZoneMode: MeshBoardTimeZoneMode;
5865
6074
  /** Static and time filter variable names for duplicate detection in entity selector editor */
5866
6075
  get staticVariableNames(): string[];
5867
6076
  get isValid(): boolean;
@@ -5877,6 +6086,7 @@ declare class MeshBoardSettingsDialogComponent {
5877
6086
  gap: number;
5878
6087
  variables?: MeshBoardVariable[];
5879
6088
  timeFilter?: MeshBoardTimeFilterConfig;
6089
+ timeZoneMode?: MeshBoardTimeZoneMode;
5880
6090
  entitySelectors?: EntitySelectorConfig[];
5881
6091
  autoRefreshSeconds?: number;
5882
6092
  }): void;
@@ -6075,5 +6285,5 @@ declare class MeshBoardManagerDialogComponent implements OnInit {
6075
6285
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<MeshBoardManagerDialogComponent, "mm-meshboard-manager-dialog", never, {}, {}, never, never, true, never>;
6076
6286
  }
6077
6287
 
6078
- export { AddWidgetDialogComponent, AiInsightsConfigDialogComponent, AiInsightsService, AiInsightsWidgetComponent, AlertBannerConfigDialogComponent, AlertBannerWidgetComponent, AlertListConfigDialogComponent, AlertListWidgetComponent, AssociationsConfigDialogComponent, AutoRefreshTimerService, BarChartConfigDialogComponent, BarChartWidgetComponent, DashboardDataService, DashboardGridService, EditModeStateService, EditWidgetDialogComponent, EntityAssociationsWidgetComponent, EntityCardConfigDialogComponent, EntityCardWidgetComponent, EntityDetailDialogComponent, EntitySelectorEditorComponent, EntitySelectorToolbarComponent, GaugeConfigDialogComponent, GaugeWidgetComponent, HeatmapConfigDialogComponent, HeatmapWidgetComponent, KpiConfigDialogComponent, KpiWidgetComponent, LineChartConfigDialogComponent, LineChartWidgetComponent, MESHBOARD_OPTIONS, MESHBOARD_TENANT_ID_PROVIDER, MarkdownConfigDialogComponent, MarkdownWidgetComponent, MeshBoardDataService, MeshBoardGridService, MeshBoardManagerDialogComponent, MeshBoardPersistenceService, MeshBoardSettingsDialogComponent, MeshBoardSettingsResult, MeshBoardStateService, MeshBoardViewComponent, PieChartConfigDialogComponent, PieChartWidgetComponent, QueryExecutorService, QuerySelectorComponent, RuntimeEntitySelectorComponent, ServiceHealthConfigDialogComponent, ServiceHealthWidgetComponent, StatsGridConfigDialogComponent, StatsGridWidgetComponent, StatusIndicatorConfigDialogComponent, StatusIndicatorWidgetComponent, StatusListConfigDialogComponent, StatusListWidgetComponent, SummaryCardConfigDialogComponent, SummaryCardWidgetComponent, TableConfigDialogComponent, TableWidgetComponent, TableWidgetDataSourceDirective, WidgetFactoryService, WidgetGroupComponent, WidgetGroupConfigDialogComponent, WidgetNotConfiguredComponent, WidgetRegistryService, classifyQuery, provideDefaultWidgets, provideMeshBoard, provideProcessWidget, provideWidgetRegistrations, queryFamily, registerDefaultWidgets, registerProcessWidget };
6079
- export type { AggregationDataSource, AggregationQuery, AggregationType, AiInsightsConfigResult, AiInsightsWidgetConfig, AlertBannerConfigResult, AlertBannerWidgetConfig, AlertListConfigResult, AlertListWidgetConfig, AnyWidgetConfig, AssociationsConfigResult, BarChartColorThreshold, BarChartConfigResult, BarChartSeries, BarChartType, BarChartWidgetConfig, BaseWidgetConfig, CategoryValueItem, ChartReferenceLine, CkQueryResult, CkQueryTarget, CkTypeAttributeInfo, ConfigDialogResult, ConfigResultApplier, ConstructionKitQueryDataSource, DashboardConfig, DashboardWidget, DataSource, DataSourceType, DiagramPropertyMapping, EntityAssociation, EntityAttribute, EntityCardConfigResult, EntityCardWidgetConfig, EntityListWidget, EntitySelectorAttributeMapping, EntitySelectorChildScope, EntitySelectorClearEvent, EntitySelectorConfig, EntitySelectorEvent, EntityWidget, EntityWithAssociationsWidgetConfig, GaugeConfigResult, GaugeRange, GaugeType, GaugeWidgetConfig, GridCell, GridPosition, GroupChildWidgetType, GroupedDataItem, HeatmapAggregation, HeatmapColorScheme, HeatmapConfigResult, HeatmapWidgetConfig, KpiConfigResult, KpiDataSourceType, KpiQueryMode, KpiWidgetConfig, LineChartConfigResult, LineChartType, LineChartWidgetConfig, MarkdownConfigResult, MarkdownTextAlign, MarkdownWidgetConfig, MeshBoardConfig, MeshBoardOptions, MeshBoardTimeFilterConfig, MeshBoardVariable, MeshBoardVariableSource, MeshBoardVariableType, ParentAssociationMode, PersistedDashboard, PersistedMeshBoard, PersistedWidget, PersistedWidgetData, PersistentQueryDataSource, PersistentQueryItem, PieChartConfigResult, PieChartType, PieChartWidgetConfig, ProcessWidgetConfig, Quarter, QueryCell, QueryClassification, QueryColumn, QueryColumnInfo, QueryColumnItem, QueryExecutionOptions, QueryExecutionResult, QueryFamily, QueryKind, QueryResultRow, RelativeTimeUnit, RepeaterDataItem, RepeaterQueryDataSource, RuntimeEntityData, RuntimeEntityDataSource, RuntimeEntitySelectorValue, ServiceCallDataSource, ServiceCallType, ServiceHealthConfigResult, ServiceHealthWidgetConfig, StatColor, StatItem, StaticDataSource, StatsGridConfigResult, StatsGridWidgetConfig, StatusIndicatorConfigResult, StatusIndicatorWidgetConfig, StatusListConfigResult, StatusListWidgetConfig, StreamDataExecutionArgs, SummaryCardConfigResult, SummaryCardTile, SummaryCardWidgetConfig, TableColumn, TableColumnStatusIconMapping, TableConfigResult, TableFilterConfig, TableSortConfig, TableWidgetConfig, TargetEntityWithAttributes, TimeRangePickerConfig, TimeRangeSelection, TimeRangeType, UpdateDashboardResult, VariableResolutionError, WidgetConfig, WidgetConfigDialog, WidgetConfigDialogSize, WidgetConfigResult, WidgetCreationOptions, WidgetDataSource, WidgetFilterConfig, WidgetGroupAttributeMappings, WidgetGroupChildTemplate, WidgetGroupConfig, WidgetGroupConfigResult, WidgetGroupLayout, WidgetPersistenceData, WidgetPositionUpdate, WidgetRegistration, WidgetType, WidgetZone };
6288
+ export { AddWidgetDialogComponent, AiInsightsConfigDialogComponent, AiInsightsService, AiInsightsWidgetComponent, AlertBannerConfigDialogComponent, AlertBannerWidgetComponent, AlertListConfigDialogComponent, AlertListWidgetComponent, AssociationsConfigDialogComponent, AutoRefreshTimerService, BarChartConfigDialogComponent, BarChartWidgetComponent, DEFAULT_TIME_ZONE_MODE, DashboardDataService, DashboardGridService, EditModeStateService, EditWidgetDialogComponent, EntityAssociationsWidgetComponent, EntityCardConfigDialogComponent, EntityCardWidgetComponent, EntityDetailDialogComponent, EntitySelectorEditorComponent, EntitySelectorToolbarComponent, GaugeConfigDialogComponent, GaugeWidgetComponent, HeatmapConfigDialogComponent, HeatmapWidgetComponent, KpiConfigDialogComponent, KpiWidgetComponent, LineChartConfigDialogComponent, LineChartWidgetComponent, MESHBOARD_OPTIONS, MESHBOARD_TENANT_ID_PROVIDER, MarkdownConfigDialogComponent, MarkdownWidgetComponent, MeshBoardDataService, MeshBoardGridService, MeshBoardManagerDialogComponent, MeshBoardPersistenceService, MeshBoardSettingsDialogComponent, MeshBoardSettingsResult, MeshBoardStateService, MeshBoardViewComponent, PieChartConfigDialogComponent, PieChartWidgetComponent, QueryExecutorService, QuerySelectorComponent, RuntimeEntitySelectorComponent, ServiceHealthConfigDialogComponent, ServiceHealthWidgetComponent, StatsGridConfigDialogComponent, StatsGridWidgetComponent, StatusIndicatorConfigDialogComponent, StatusIndicatorWidgetComponent, StatusListConfigDialogComponent, StatusListWidgetComponent, SummaryCardConfigDialogComponent, SummaryCardWidgetComponent, TableConfigDialogComponent, TableWidgetComponent, TableWidgetDataSourceDirective, WidgetFactoryService, WidgetGroupComponent, WidgetGroupConfigDialogComponent, WidgetNotConfiguredComponent, WidgetRegistryService, classifyQuery, provideDefaultWidgets, provideMeshBoard, provideProcessWidget, provideWidgetRegistrations, queryFamily, registerDefaultWidgets, registerProcessWidget };
6289
+ export type { AggregationDataSource, AggregationQuery, AggregationType, AiInsightsConfigResult, AiInsightsWidgetConfig, AlertBannerConfigResult, AlertBannerWidgetConfig, AlertListConfigResult, AlertListWidgetConfig, AnyWidgetConfig, AssociationsConfigResult, BarChartColorThreshold, BarChartConfigResult, BarChartSeries, BarChartType, BarChartWidgetConfig, BaseWidgetConfig, CategoryValueItem, ChartReferenceLine, CkQueryResult, CkQueryTarget, CkTypeAttributeInfo, ConfigDialogResult, ConfigResultApplier, ConstructionKitQueryDataSource, DashboardConfig, DashboardWidget, DataSource, DataSourceType, DiagramPropertyMapping, EntityAssociation, EntityAttribute, EntityCardConfigResult, EntityCardWidgetConfig, EntityListWidget, EntitySelectorAttributeMapping, EntitySelectorChildScope, EntitySelectorClearEvent, EntitySelectorConfig, EntitySelectorEvent, EntityWidget, EntityWithAssociationsWidgetConfig, GaugeConfigResult, GaugeRange, GaugeType, GaugeWidgetConfig, GridCell, GridPosition, GroupChildWidgetType, GroupedDataItem, HeatmapAggregation, HeatmapColorScheme, HeatmapConfigResult, HeatmapWidgetConfig, KpiConfigResult, KpiDataSourceType, KpiQueryMode, KpiWidgetConfig, LineChartConfigResult, LineChartType, LineChartWidgetConfig, MarkdownConfigResult, MarkdownTextAlign, MarkdownWidgetConfig, MeshBoardConfig, MeshBoardOptions, MeshBoardTimeFilterConfig, MeshBoardTimeZoneMode, MeshBoardVariable, MeshBoardVariableSource, MeshBoardVariableType, ParentAssociationMode, PersistedDashboard, PersistedMeshBoard, PersistedWidget, PersistedWidgetData, PersistentQueryCellMode, PersistentQueryCellSource, PersistentQueryDataSource, PersistentQueryItem, PieChartConfigResult, PieChartType, PieChartWidgetConfig, ProcessWidgetConfig, Quarter, QueryCell, QueryClassification, QueryColumn, QueryColumnInfo, QueryColumnItem, QueryExecutionOptions, QueryExecutionResult, QueryFamily, QueryKind, QueryResultRow, RelativeTimeUnit, RepeaterDataItem, RepeaterQueryDataSource, RuntimeEntityData, RuntimeEntityDataSource, RuntimeEntitySelectorValue, ServiceCallDataSource, ServiceCallType, ServiceHealthConfigResult, ServiceHealthWidgetConfig, StatColor, StatItem, StaticDataSource, StatsGridConfigResult, StatsGridWidgetConfig, StatusIndicatorConfigResult, StatusIndicatorWidgetConfig, StatusListConfigResult, StatusListWidgetConfig, StreamDataExecutionArgs, SummaryCardConfigResult, SummaryCardTile, SummaryCardWidgetConfig, TableColumn, TableColumnStatusIconMapping, TableConfigResult, TableFilterConfig, TableSortConfig, TableWidgetConfig, TargetEntityWithAttributes, TimeRangePickerConfig, TimeRangeSelection, TimeRangeType, UpdateDashboardResult, VariableResolutionError, WidgetConfig, WidgetConfigDialog, WidgetConfigDialogSize, WidgetConfigResult, WidgetCreationOptions, WidgetDataSource, WidgetFilterConfig, WidgetGroupAttributeMappings, WidgetGroupChildTemplate, WidgetGroupConfig, WidgetGroupConfigResult, WidgetGroupLayout, WidgetPersistenceData, WidgetPositionUpdate, WidgetRegistration, WidgetType, WidgetZone };