@c8y/ngx-components 1023.12.0 → 1023.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/datapoint-explorer/index.d.ts +78 -1
- package/datapoint-explorer/index.d.ts.map +1 -1
- package/datapoint-explorer/view/index.d.ts +150 -14
- package/datapoint-explorer/view/index.d.ts.map +1 -1
- package/echart/index.d.ts +12 -2
- package/echart/index.d.ts.map +1 -1
- package/echart/models/index.d.ts +12 -2
- package/echart/models/index.d.ts.map +1 -1
- package/fesm2022/c8y-ngx-components-alarms.mjs +2 -2
- package/fesm2022/c8y-ngx-components-alarms.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-datapoint-explorer-view.mjs +388 -64
- package/fesm2022/c8y-ngx-components-datapoint-explorer-view.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-datapoint-explorer.mjs +329 -4
- package/fesm2022/c8y-ngx-components-datapoint-explorer.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-echart-models.mjs +6 -1
- package/fesm2022/c8y-ngx-components-echart-models.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-echart.mjs +6 -1
- package/fesm2022/c8y-ngx-components-echart.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-global-context.mjs +4 -3
- package/fesm2022/c8y-ngx-components-global-context.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-graph.mjs +129 -17
- package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-graph.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components-widgets-implementations-info-gauge.mjs +4 -4
- package/fesm2022/c8y-ngx-components-widgets-implementations-info-gauge.mjs.map +1 -1
- package/fesm2022/c8y-ngx-components.mjs +16037 -15943
- package/fesm2022/c8y-ngx-components.mjs.map +1 -1
- package/global-context/index.d.ts.map +1 -1
- package/index.d.ts +9677 -9621
- package/index.d.ts.map +1 -1
- package/locales/de.po +26 -11
- package/locales/es.po +25 -10
- package/locales/fr.po +25 -10
- package/locales/ja_JP.po +22 -7
- package/locales/ko.po +24 -11
- package/locales/locales.pot +23 -8
- package/locales/nl.po +26 -10
- package/locales/pl.po +25 -10
- package/locales/pt_BR.po +25 -10
- package/locales/zh_CN.po +24 -9
- package/locales/zh_TW.po +26 -10
- package/package.json +1 -1
- package/widgets/implementations/datapoints-graph/index.d.ts +19 -5
- package/widgets/implementations/datapoints-graph/index.d.ts.map +1 -1
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
+
import { IManagedObject } from '@c8y/client';
|
|
4
|
+
import { DatapointsGraphWidgetConfig } from '@c8y/ngx-components/echart';
|
|
3
5
|
|
|
4
6
|
declare function canActivateDatapointExplorer(): Observable<boolean>;
|
|
5
7
|
declare class DatapointExplorerModule {
|
|
@@ -8,5 +10,80 @@ declare class DatapointExplorerModule {
|
|
|
8
10
|
static ɵinj: i0.ɵɵInjectorDeclaration<DatapointExplorerModule>;
|
|
9
11
|
}
|
|
10
12
|
|
|
11
|
-
|
|
13
|
+
interface DataExplorerUrlConfig {
|
|
14
|
+
datapoints?: BaseDatapointConfig[];
|
|
15
|
+
alarmsEventsConfigs?: BaseAlarmEventConfig[];
|
|
16
|
+
dateFrom?: Date | string | null;
|
|
17
|
+
dateTo?: Date | string | null;
|
|
18
|
+
[key: string]: any;
|
|
19
|
+
}
|
|
20
|
+
interface BaseDatapointConfig {
|
|
21
|
+
fragment: string;
|
|
22
|
+
series: string;
|
|
23
|
+
__target?: {
|
|
24
|
+
id?: string;
|
|
25
|
+
[key: string]: any;
|
|
26
|
+
};
|
|
27
|
+
__template?: string;
|
|
28
|
+
[key: string]: any;
|
|
29
|
+
}
|
|
30
|
+
interface BaseAlarmEventConfig {
|
|
31
|
+
timelineType: string;
|
|
32
|
+
label: string;
|
|
33
|
+
filters: {
|
|
34
|
+
type: string;
|
|
35
|
+
[key: string]: any;
|
|
36
|
+
};
|
|
37
|
+
__target?: {
|
|
38
|
+
id?: string;
|
|
39
|
+
[key: string]: any;
|
|
40
|
+
};
|
|
41
|
+
[key: string]: any;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
declare class DataExplorerService {
|
|
45
|
+
private readonly inventory;
|
|
46
|
+
private readonly contextDashboardService;
|
|
47
|
+
private readonly workspaceConfigurationService;
|
|
48
|
+
private readonly moChunkLoader;
|
|
49
|
+
private readonly datapointSyncService;
|
|
50
|
+
private readonly router;
|
|
51
|
+
private readonly maxNumberOfManagedObjectsPerRequest;
|
|
52
|
+
fetchReportDashboard(reportId: string): Promise<IManagedObject>;
|
|
53
|
+
fetchContextDashboard(dashboardId: string, contextAsset: IManagedObject): Promise<IManagedObject>;
|
|
54
|
+
loadManagedObjectsInChunks(uniqIds: string[]): Promise<{
|
|
55
|
+
result: IManagedObject[];
|
|
56
|
+
errors: any[];
|
|
57
|
+
}>;
|
|
58
|
+
/**
|
|
59
|
+
* Navigate to datapoint explorer with given config.
|
|
60
|
+
* The goal of this method is to navigate to the data explorer with a provided config from any other application.
|
|
61
|
+
* @param config Configuration to use
|
|
62
|
+
* @param label Label to be displayed for the configuration
|
|
63
|
+
* @param id ID for the configuration
|
|
64
|
+
*/
|
|
65
|
+
navigateToDataExplorer(config: DataExplorerUrlConfig, label: string, id: string): void;
|
|
66
|
+
/**
|
|
67
|
+
* Generate a URL for the datapoint explorer with the given config.
|
|
68
|
+
* The goal of this method is to generate a shareable link to the data explorer.
|
|
69
|
+
* @param config Configuration to use
|
|
70
|
+
* @param label Label to be displayed for the configuration
|
|
71
|
+
* @param id ID for the configuration
|
|
72
|
+
* @returns The generated URL
|
|
73
|
+
*/
|
|
74
|
+
getUrlForConfig(config: DataExplorerUrlConfig, label: string, id: string): string;
|
|
75
|
+
processAlarmEventConfigs(config: DatapointsGraphWidgetConfig): void;
|
|
76
|
+
processDatapoints(config: DatapointsGraphWidgetConfig): void;
|
|
77
|
+
/**
|
|
78
|
+
* Generates a color from a fixed palette based on the index.
|
|
79
|
+
* Used to assign colors to alarm/event configs in the UI.
|
|
80
|
+
*/
|
|
81
|
+
generateColor(index: number): string;
|
|
82
|
+
loadAndAssignManagedObjects(config: DatapointsGraphWidgetConfig, uniqueIds: string[]): Promise<void>;
|
|
83
|
+
private loadAChunkOfManagedObjects;
|
|
84
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DataExplorerService, never>;
|
|
85
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DataExplorerService>;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export { DataExplorerService, DatapointExplorerModule, canActivateDatapointExplorer };
|
|
12
89
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sources":["../../datapoint-explorer/datapoint-explorer.module.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../../datapoint-explorer/datapoint-explorer.module.ts","../../datapoint-explorer/view/datapoint-explorer.model.ts","../../datapoint-explorer/view/datapoint-explorer.service.ts"],"sourcesContent":[null,null,null],"names":[],"mappings":";;;;;AAYA;AAKA;;;;AAkDuC;;;ACvDrC;AACA;AACA;AACA;AAGA;AACD;;;;AAKC;;AAEE;;;AAIF;AACD;;;;AAMC;;AAEE;;AAGF;;AAEE;;AAEF;AACD;;AClCD;AAIE;AACA;AACA;AACA;AACA;AACA;AACA;;AAWM;AAUA;;;;AAUN;;;;;;AAMG;AACH;AAKA;;;;;;;AAOG;AACH;AAQA;AAWA;AAiBA;;;AAGG;AACH;AAMM;;;;AAuBP;;"}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { WritableSignal, ElementRef } from '@angular/core';
|
|
3
3
|
import { DatapointsGraphWidgetConfig } from '@c8y/ngx-components/echart';
|
|
4
|
+
import { TimeContext, TimeContextComponent } from '@c8y/ngx-components/time-context';
|
|
4
5
|
import { FormGroup } from '@angular/forms';
|
|
5
|
-
import { IIdentified, aggregationType } from '@c8y/client';
|
|
6
|
+
import { IIdentified, aggregationType, IManagedObject } from '@c8y/client';
|
|
6
7
|
import { DynamicComponentAlertAggregator } from '@c8y/ngx-components';
|
|
7
8
|
import { SelectedDatapoint } from '@c8y/ngx-components/alarm-event-selector';
|
|
8
9
|
import { KPIDetails, DatapointAttributesFormConfig } from '@c8y/ngx-components/datapoint-selector';
|
|
9
10
|
import { ExportConfig } from '@c8y/ngx-components/datapoints-export-selector';
|
|
10
11
|
import { DatapointsGraphWidgetConfig as DatapointsGraphWidgetConfig$1, AlarmDetailsExtended, EventDetailsExtended, DatapointsGraphKPIDetails, CHART_VIEW_CONTEXT, TimeContextProps, AlarmOrEventExtended } from '@c8y/ngx-components/echart/models';
|
|
11
12
|
import { Interval } from '@c8y/ngx-components/interval-picker';
|
|
12
|
-
import { TimeContext, TimeContextComponent } from '@c8y/ngx-components/time-context';
|
|
13
13
|
import { Observable } from 'rxjs';
|
|
14
14
|
|
|
15
15
|
declare class NameGeneratorService {
|
|
@@ -24,27 +24,118 @@ interface WorkspaceConfiguration {
|
|
|
24
24
|
config: DatapointsGraphWidgetConfig;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
+
interface Settings {
|
|
28
|
+
hideWorkspaceConfig?: boolean;
|
|
29
|
+
hideExportSelector?: boolean;
|
|
30
|
+
hideWidgetActions?: boolean;
|
|
31
|
+
timeContext?: TimeContext;
|
|
32
|
+
defaultConfigurationId?: string;
|
|
33
|
+
}
|
|
34
|
+
interface DataExplorerUrlConfig {
|
|
35
|
+
datapoints?: BaseDatapointConfig[];
|
|
36
|
+
alarmsEventsConfigs?: BaseAlarmEventConfig[];
|
|
37
|
+
dateFrom?: Date | string | null;
|
|
38
|
+
dateTo?: Date | string | null;
|
|
39
|
+
[key: string]: any;
|
|
40
|
+
}
|
|
41
|
+
interface BaseDatapointConfig {
|
|
42
|
+
fragment: string;
|
|
43
|
+
series: string;
|
|
44
|
+
__target?: {
|
|
45
|
+
id?: string;
|
|
46
|
+
[key: string]: any;
|
|
47
|
+
};
|
|
48
|
+
__template?: string;
|
|
49
|
+
[key: string]: any;
|
|
50
|
+
}
|
|
51
|
+
interface BaseAlarmEventConfig {
|
|
52
|
+
timelineType: string;
|
|
53
|
+
label: string;
|
|
54
|
+
filters: {
|
|
55
|
+
type: string;
|
|
56
|
+
[key: string]: any;
|
|
57
|
+
};
|
|
58
|
+
__target?: {
|
|
59
|
+
id?: string;
|
|
60
|
+
[key: string]: any;
|
|
61
|
+
};
|
|
62
|
+
[key: string]: any;
|
|
63
|
+
}
|
|
64
|
+
declare const DATA_EXPLORER_BASE_CONFIG: DatapointsGraphWidgetConfig;
|
|
65
|
+
declare const REVERSE_KEY_MAP: {
|
|
66
|
+
d: string;
|
|
67
|
+
a: string;
|
|
68
|
+
f: string;
|
|
69
|
+
s: string;
|
|
70
|
+
t: string;
|
|
71
|
+
m: string;
|
|
72
|
+
l: string;
|
|
73
|
+
r: string;
|
|
74
|
+
y: string;
|
|
75
|
+
df: string;
|
|
76
|
+
dt: string;
|
|
77
|
+
ac: string;
|
|
78
|
+
c: string;
|
|
79
|
+
i: string;
|
|
80
|
+
tp: string;
|
|
81
|
+
};
|
|
82
|
+
declare const KEY_MAP: {
|
|
83
|
+
[k: string]: string;
|
|
84
|
+
};
|
|
85
|
+
|
|
27
86
|
declare class WorkspaceConfigurationService {
|
|
28
87
|
private readonly baseKey;
|
|
29
88
|
private readonly baseDefaultKey;
|
|
30
89
|
contextIdSignal: WritableSignal<number | string | null>;
|
|
90
|
+
private readonly alertService;
|
|
31
91
|
get LOCAL_STORAGE_KEY(): string;
|
|
32
92
|
get LOCAL_STORAGE_DEFAULT_ID_KEY(): string;
|
|
93
|
+
/**
|
|
94
|
+
* Generates a full datapoint explorer link from a bare config
|
|
95
|
+
*/
|
|
96
|
+
generateExplorerLink(config: Partial<DatapointsGraphWidgetConfig> | DataExplorerUrlConfig, label: string, id: string): string;
|
|
97
|
+
/** Load workspace configs from localStorage */
|
|
33
98
|
getConfigurations(): WorkspaceConfiguration[];
|
|
34
99
|
getDefaultConfigurationId(): string | null;
|
|
100
|
+
/** Save workspace configs in localStorage */
|
|
35
101
|
saveConfigurations(configurations: WorkspaceConfiguration[], id: string): void;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @param urlConfig - configuration from the URL, either compressed string or already decoded object
|
|
105
|
+
* @returns
|
|
106
|
+
*/
|
|
107
|
+
getConfigurationFromUrl(urlConfig: DatapointsGraphWidgetConfig | string): DatapointsGraphWidgetConfig;
|
|
108
|
+
/**
|
|
109
|
+
* Encode a config for the URL:
|
|
110
|
+
* - Cleanup the __target objects to contain only name and id
|
|
111
|
+
* - Remove default values (diff from base)
|
|
112
|
+
* - Minify keys
|
|
113
|
+
* - Compress with lz-string
|
|
114
|
+
*/
|
|
115
|
+
encodeConfig(config: DatapointsGraphWidgetConfig): string;
|
|
116
|
+
/**
|
|
117
|
+
* Decode a config from the URL:
|
|
118
|
+
* - Decompress
|
|
119
|
+
* - Expand keys
|
|
120
|
+
* - Merge with base config
|
|
121
|
+
*/
|
|
122
|
+
decodeConfig(urlConfig: string): Partial<DatapointsGraphWidgetConfig>;
|
|
123
|
+
/** Minify keys recursively using KEY_MAP */
|
|
124
|
+
private minifyKeys;
|
|
125
|
+
/** Expand keys recursively using REVERSE_KEY_MAP */
|
|
126
|
+
private expandKeys;
|
|
127
|
+
/**
|
|
128
|
+
* Remove properties from `config` that match `base` so only changed values remain.
|
|
129
|
+
*/
|
|
130
|
+
private removeDefaults;
|
|
131
|
+
/**
|
|
132
|
+
* Cleans up __target objects to only keep id and name and remove the rest.
|
|
133
|
+
*/
|
|
134
|
+
private cleanUpTargetObject;
|
|
36
135
|
static ɵfac: i0.ɵɵFactoryDeclaration<WorkspaceConfigurationService, never>;
|
|
37
136
|
static ɵprov: i0.ɵɵInjectableDeclaration<WorkspaceConfigurationService>;
|
|
38
137
|
}
|
|
39
138
|
|
|
40
|
-
interface Settings {
|
|
41
|
-
hideWorkspaceConfig?: boolean;
|
|
42
|
-
hideExportSelector?: boolean;
|
|
43
|
-
hideWidgetActions?: boolean;
|
|
44
|
-
timeContext?: TimeContext;
|
|
45
|
-
defaultConfigurationId?: string;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
139
|
declare class DatapointExplorerComponent {
|
|
49
140
|
#private;
|
|
50
141
|
settings$: Observable<Settings>;
|
|
@@ -82,11 +173,11 @@ declare class DatapointExplorerComponent {
|
|
|
82
173
|
private readonly contextRouteService;
|
|
83
174
|
private readonly chartHelpersService;
|
|
84
175
|
private readonly gainsightService;
|
|
85
|
-
private readonly
|
|
176
|
+
private readonly datapointSyncService;
|
|
86
177
|
constructor();
|
|
87
178
|
ngOnInit(): void;
|
|
88
179
|
onTimeContextChange(timeProps: TimeContextProps): void;
|
|
89
|
-
onConfigurationChange(config: DatapointsGraphWidgetConfig$1): void
|
|
180
|
+
onConfigurationChange(config: DatapointsGraphWidgetConfig$1): Promise<void>;
|
|
90
181
|
onSliderZoom(timeProps: {
|
|
91
182
|
dateFrom: Date;
|
|
92
183
|
dateTo: Date;
|
|
@@ -100,6 +191,7 @@ declare class DatapointExplorerComponent {
|
|
|
100
191
|
createNewReportWithWidget(): Promise<void>;
|
|
101
192
|
sendAsWidgetToReport(): Promise<void>;
|
|
102
193
|
sendAsWidgetToDashboard(): Promise<void>;
|
|
194
|
+
private isActualDate;
|
|
103
195
|
private isAlarm;
|
|
104
196
|
private isEvent;
|
|
105
197
|
private hasActiveAlarms;
|
|
@@ -112,6 +204,50 @@ declare class DatapointExplorerComponent {
|
|
|
112
204
|
static ɵcmp: i0.ɵɵComponentDeclaration<DatapointExplorerComponent, "c8y-datapoint-explorer", never, {}, {}, never, never, true, never>;
|
|
113
205
|
}
|
|
114
206
|
|
|
115
|
-
|
|
116
|
-
|
|
207
|
+
declare class DataExplorerService {
|
|
208
|
+
private readonly inventory;
|
|
209
|
+
private readonly contextDashboardService;
|
|
210
|
+
private readonly workspaceConfigurationService;
|
|
211
|
+
private readonly moChunkLoader;
|
|
212
|
+
private readonly datapointSyncService;
|
|
213
|
+
private readonly router;
|
|
214
|
+
private readonly maxNumberOfManagedObjectsPerRequest;
|
|
215
|
+
fetchReportDashboard(reportId: string): Promise<IManagedObject>;
|
|
216
|
+
fetchContextDashboard(dashboardId: string, contextAsset: IManagedObject): Promise<IManagedObject>;
|
|
217
|
+
loadManagedObjectsInChunks(uniqIds: string[]): Promise<{
|
|
218
|
+
result: IManagedObject[];
|
|
219
|
+
errors: any[];
|
|
220
|
+
}>;
|
|
221
|
+
/**
|
|
222
|
+
* Navigate to datapoint explorer with given config.
|
|
223
|
+
* The goal of this method is to navigate to the data explorer with a provided config from any other application.
|
|
224
|
+
* @param config Configuration to use
|
|
225
|
+
* @param label Label to be displayed for the configuration
|
|
226
|
+
* @param id ID for the configuration
|
|
227
|
+
*/
|
|
228
|
+
navigateToDataExplorer(config: DataExplorerUrlConfig, label: string, id: string): void;
|
|
229
|
+
/**
|
|
230
|
+
* Generate a URL for the datapoint explorer with the given config.
|
|
231
|
+
* The goal of this method is to generate a shareable link to the data explorer.
|
|
232
|
+
* @param config Configuration to use
|
|
233
|
+
* @param label Label to be displayed for the configuration
|
|
234
|
+
* @param id ID for the configuration
|
|
235
|
+
* @returns The generated URL
|
|
236
|
+
*/
|
|
237
|
+
getUrlForConfig(config: DataExplorerUrlConfig, label: string, id: string): string;
|
|
238
|
+
processAlarmEventConfigs(config: DatapointsGraphWidgetConfig): void;
|
|
239
|
+
processDatapoints(config: DatapointsGraphWidgetConfig): void;
|
|
240
|
+
/**
|
|
241
|
+
* Generates a color from a fixed palette based on the index.
|
|
242
|
+
* Used to assign colors to alarm/event configs in the UI.
|
|
243
|
+
*/
|
|
244
|
+
generateColor(index: number): string;
|
|
245
|
+
loadAndAssignManagedObjects(config: DatapointsGraphWidgetConfig, uniqueIds: string[]): Promise<void>;
|
|
246
|
+
private loadAChunkOfManagedObjects;
|
|
247
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DataExplorerService, never>;
|
|
248
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DataExplorerService>;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
export { DATA_EXPLORER_BASE_CONFIG, DataExplorerService, DatapointExplorerComponent, KEY_MAP, NameGeneratorService, REVERSE_KEY_MAP, WorkspaceConfigurationService };
|
|
252
|
+
export type { BaseAlarmEventConfig, BaseDatapointConfig, DataExplorerUrlConfig, Settings, WorkspaceConfiguration };
|
|
117
253
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sources":["../../../datapoint-explorer/view/configuration/name-generator.service.ts","../../../datapoint-explorer/view/configuration/workspace-configuration.model.ts","../../../datapoint-explorer/view/configuration/workspace-configuration.service.ts","../../../datapoint-explorer/view/datapoint-explorer.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../../../datapoint-explorer/view/configuration/name-generator.service.ts","../../../datapoint-explorer/view/configuration/workspace-configuration.model.ts","../../../datapoint-explorer/view/datapoint-explorer.model.ts","../../../datapoint-explorer/view/configuration/workspace-configuration.service.ts","../../../datapoint-explorer/view/datapoint-explorer.component.ts","../../../datapoint-explorer/view/datapoint-explorer.service.ts"],"sourcesContent":[null,null,null,null,null,null],"names":[],"mappings":";;;;;;;;;;;;;;AAGA;AAIE;;;AAOD;;;;;;ACRA;;;;;;;;ACGA;;AAGC;AACA;AACA;AACA;AAGA;AACD;;;;AAKC;;AAEE;;;AAIF;AACD;;;;AAMC;;AAEE;;AAGF;;AAEE;;AAEF;AACD;AAED;AAsBA;;;;;;;;;;;;;;;;;AAkBA;;;;AC1EA;AAIE;AACA;;AAGA;;;AAYA;;AAEG;AACH;;;;;;AAyCA;;;;AAIG;AACH;AAYA;;;;;;AAMG;AACH;AAOA;;;;;AAKG;;;AAiBH;;AAeA;AAcA;;AAEG;AACH;AAcA;;AAEG;AACH;;;AAiCD;;ACrJD;;AA4BE;;;;;AAKA;;;AAGA;;;;AAIA;AACA;AACA;AACA;AACA;;;AAGE;;AAEA;;AAEF;AAIA;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAOA;AA8CA;;;;;AAkHwD;AAA2B;AAsDnF;AAMA;AAMA;AASA;AAIA;AAQM;AAuBA;AA8BA;AAmCN;AAOA;AAIA;AAIA;AAIA;AAUA;AAsBA;AAWA;AAUA;;;AAyBD;;AChjBD;AAIE;AACA;AACA;AACA;AACA;AACA;AACA;;AAWM;AAUA;;;;AAUN;;;;;;AAMG;AACH;AAKA;;;;;;;AAOG;AACH;AAQA;AAWA;AAiBA;;;AAGG;AACH;AAMM;;;;AAuBP;;;"}
|
package/echart/index.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ type DatapointsGraphWidgetConfig = {
|
|
|
21
21
|
aggregatedDatapoint?: DatapointsGraphKPIDetails;
|
|
22
22
|
alarmsEventsConfigs?: AlarmOrEventExtended[];
|
|
23
23
|
datapoints?: DatapointsGraphKPIDetails[] | null;
|
|
24
|
+
dataPointLegendDisplay?: string | null;
|
|
24
25
|
date?: DateTimeContext;
|
|
25
26
|
dateFrom?: Date | string | null;
|
|
26
27
|
dateTo?: Date | string | null;
|
|
@@ -86,6 +87,11 @@ type DpValuesItem = {
|
|
|
86
87
|
time: number;
|
|
87
88
|
values: DataPointValues[];
|
|
88
89
|
};
|
|
90
|
+
interface LegendDisplayOptionItem {
|
|
91
|
+
value: string;
|
|
92
|
+
label: string;
|
|
93
|
+
}
|
|
94
|
+
declare const LEGEND_DISPLAY_OPTIONS: LegendDisplayOptionItem[];
|
|
89
95
|
interface MarkPointData {
|
|
90
96
|
coord: [string, number | DataPointValues | null];
|
|
91
97
|
name: string;
|
|
@@ -161,6 +167,10 @@ declare const SEVERITY_LABELS: {
|
|
|
161
167
|
readonly WARNING: "WARNING";
|
|
162
168
|
};
|
|
163
169
|
type SeverityType = keyof typeof Severity;
|
|
170
|
+
interface SelectableDatapoint {
|
|
171
|
+
type: 'ALARM' | 'DATAPOINT' | 'EVENT';
|
|
172
|
+
original: KPIDetails | AlarmDetailsExtended | EventDetailsExtended;
|
|
173
|
+
}
|
|
164
174
|
|
|
165
175
|
/**
|
|
166
176
|
* @param typeOfSeries is used for formatter to distinguish between events/alarms series
|
|
@@ -361,6 +371,6 @@ declare class SelectAggregatedDatapointComponent implements OnChanges {
|
|
|
361
371
|
static ɵcmp: i0.ɵɵComponentDeclaration<SelectAggregatedDatapointComponent, "c8y-select-aggregated-datapoint", never, { "activeDatapoints": { "alias": "activeDatapoints"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, { "valueChange": "valueChange"; }, never, never, true, never>;
|
|
362
372
|
}
|
|
363
373
|
|
|
364
|
-
export { CHART_VIEW_CONTEXT, ChartAlarmsService, ChartEventsService, ChartHelpersService, ChartsComponent, DATE_SELECTION_EXTENDED, ICONS_MAP, PRODUCT_EXPERIENCE_DATA_EXPLORER_AND_GRAPH, REALTIME_TEXTS, SEVERITY_LABELS, SelectAggregatedDatapointComponent };
|
|
365
|
-
export type { AlarmDetailsExtended, AlarmOrEventExtended, CustomSeriesOptions, DatapointAxisType, DatapointChartRenderType, DatapointLineType, DatapointRealtimeMeasurements, DatapointsGraphKPIDetails, DatapointsGraphWidgetConfig, DatapointsGraphWidgetTimeProps, DateString, DpValuesItem, DpWithValues, EchartsCustomOptions, EchartsSeriesOptions, EventDetailsExtended, GraphDisplayOptions, MarkLineData, MarkPointData, MeasurementSeries, SeriesDatapointInfo, SeriesValue, SeverityType, TimeContextProps, YAxisOptions, customSeriesMarkLineData, customSeriesMarkPointData };
|
|
374
|
+
export { CHART_VIEW_CONTEXT, ChartAlarmsService, ChartEventsService, ChartHelpersService, ChartsComponent, DATE_SELECTION_EXTENDED, ICONS_MAP, LEGEND_DISPLAY_OPTIONS, PRODUCT_EXPERIENCE_DATA_EXPLORER_AND_GRAPH, REALTIME_TEXTS, SEVERITY_LABELS, SelectAggregatedDatapointComponent };
|
|
375
|
+
export type { AlarmDetailsExtended, AlarmOrEventExtended, CustomSeriesOptions, DatapointAxisType, DatapointChartRenderType, DatapointLineType, DatapointRealtimeMeasurements, DatapointsGraphKPIDetails, DatapointsGraphWidgetConfig, DatapointsGraphWidgetTimeProps, DateString, DpValuesItem, DpWithValues, EchartsCustomOptions, EchartsSeriesOptions, EventDetailsExtended, GraphDisplayOptions, LegendDisplayOptionItem, MarkLineData, MarkPointData, MeasurementSeries, SelectableDatapoint, SeriesDatapointInfo, SeriesValue, SeverityType, TimeContextProps, YAxisOptions, customSeriesMarkLineData, customSeriesMarkPointData };
|
|
366
376
|
//# sourceMappingURL=index.d.ts.map
|
package/echart/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sources":["../../echart/models/datapoints-graph-widget.model.ts","../../echart/models/chart.model.ts","../../echart/models/svg-icons.model.ts","../../echart/charts.component.ts","../../echart/services/chart-alarms.service.ts","../../echart/services/chart-events.service.ts","../../echart/services/chart-helpers.service.ts","../../echart/select-aggregated-datapoint/select-aggregated-datapoint.component.ts"],"sourcesContent":[null,null,null,null,null,null,null,null],"names":[],"mappings":";;;;;;;;;;;;;;AAmBM;;;;AAKA;AACJ;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;;;;AAKA;;AAEA;AACA;AACA;AACA;;;AAGA;;;;;;;;AASI;;;;;;;;;AASJ;;AAGI;;AAEJ;AACA;;AAGI;;;AAIN;;AAEG;;AAGG;AAIN;AACE;AACA;AACD;AAED;AACM;;AAEL;AAED;;;;AAIM
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../../echart/models/datapoints-graph-widget.model.ts","../../echart/models/chart.model.ts","../../echart/models/svg-icons.model.ts","../../echart/charts.component.ts","../../echart/services/chart-alarms.service.ts","../../echart/services/chart-events.service.ts","../../echart/services/chart-helpers.service.ts","../../echart/select-aggregated-datapoint/select-aggregated-datapoint.component.ts"],"sourcesContent":[null,null,null,null,null,null,null,null],"names":[],"mappings":";;;;;;;;;;;;;;AAmBM;;;;AAKA;AACJ;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;;;;AAKA;;AAEA;AACA;AACA;AACA;;;AAGA;;;;;;;;AASI;;;;;;;;;AASJ;;AAGI;;AAEJ;AACA;;AAGI;;;AAIN;;AAEG;;AAGG;AAIN;AACE;AACA;AACD;AAED;AACM;;AAEL;AAED;;;;AAIM;;;;;;;AAQL;AAED;;;;;AAUE;;;;;AAGD;;AAGC;;AAEA;;AAEE;;AAEF;;;AACD;;;;;;;AAQC;AACA;AACD;AAEK;AACA;AAEA;AAEA;AAEN;;;;AAKA;;;;;;;;;;;;;AAcM;AACA;AAEA;;;;AAKA;;;;;;;;;;AAWL;AAED;;;;;;;;AAUE;AACA;AACD;;ACzMD;;;;;;AAMG;AACH;AACE;;;;AAIA;;;AACD;;;AAIA;;;AAIA;AAEK;AACA;AACJ;AACE;AACD;AACF;;AAGC;AACA;AACD;AAED;AACE;AACA;AACA;AACD;;AC3CD;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACD;AAED;;;;;;;;;;;ACyDA;AA4BE;;AAEA;;;;;;;;;;;;AAYK;AACK;AAGA;AACA;AACA;AACA;AACA;AACA;;AAEV;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAyCA;;;;;AA8GuB;;;AAA4B;AAiDnD;AAOA;AAIA;AAgBA;AA6BA;AAWA;;;AAGG;AACH;AAcA;;;AAGG;AACH;AAmBA;AAeA;AA0BA;;AA8DA;;;AA0MA;AA6CA;AA0CA;AAkBA;AAWA;AAYA;;;AA6BD;;ACh4BD;AAEc;AAAQ;AAEpB;;;;;AAKG;AACG;;;AAqCP;;AC/CD;AAEc;AAAQ;AAEpB;;;;;AAKG;AACG;;;AAuBP;;AChCD;AAEE;;;;AAIG;;;;;;;;;;;AAcH;AAcA;;;AAGD;;ACtBD;;AAqBW;AACC;AAEV;;AAGA;;;AAiBA;;;AAgBD;;;"}
|
package/echart/models/index.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ type DatapointsGraphWidgetConfig = {
|
|
|
15
15
|
aggregatedDatapoint?: DatapointsGraphKPIDetails;
|
|
16
16
|
alarmsEventsConfigs?: AlarmOrEventExtended[];
|
|
17
17
|
datapoints?: DatapointsGraphKPIDetails[] | null;
|
|
18
|
+
dataPointLegendDisplay?: string | null;
|
|
18
19
|
date?: DateTimeContext;
|
|
19
20
|
dateFrom?: Date | string | null;
|
|
20
21
|
dateTo?: Date | string | null;
|
|
@@ -80,6 +81,11 @@ type DpValuesItem = {
|
|
|
80
81
|
time: number;
|
|
81
82
|
values: DataPointValues[];
|
|
82
83
|
};
|
|
84
|
+
interface LegendDisplayOptionItem {
|
|
85
|
+
value: string;
|
|
86
|
+
label: string;
|
|
87
|
+
}
|
|
88
|
+
declare const LEGEND_DISPLAY_OPTIONS: LegendDisplayOptionItem[];
|
|
83
89
|
interface MarkPointData {
|
|
84
90
|
coord: [string, number | DataPointValues | null];
|
|
85
91
|
name: string;
|
|
@@ -155,6 +161,10 @@ declare const SEVERITY_LABELS: {
|
|
|
155
161
|
readonly WARNING: "WARNING";
|
|
156
162
|
};
|
|
157
163
|
type SeverityType = keyof typeof Severity;
|
|
164
|
+
interface SelectableDatapoint {
|
|
165
|
+
type: 'ALARM' | 'DATAPOINT' | 'EVENT';
|
|
166
|
+
original: KPIDetails | AlarmDetailsExtended | EventDetailsExtended;
|
|
167
|
+
}
|
|
158
168
|
|
|
159
169
|
/**
|
|
160
170
|
* @param typeOfSeries is used for formatter to distinguish between events/alarms series
|
|
@@ -215,6 +225,6 @@ declare const ICONS_MAP: {
|
|
|
215
225
|
WARNING: ICONS;
|
|
216
226
|
};
|
|
217
227
|
|
|
218
|
-
export { CHART_VIEW_CONTEXT, DATE_SELECTION_EXTENDED, ICONS_MAP, PRODUCT_EXPERIENCE_DATA_EXPLORER_AND_GRAPH, REALTIME_TEXTS, SEVERITY_LABELS };
|
|
219
|
-
export type { AlarmDetailsExtended, AlarmOrEventExtended, CustomSeriesOptions, DatapointAxisType, DatapointChartRenderType, DatapointLineType, DatapointRealtimeMeasurements, DatapointsGraphKPIDetails, DatapointsGraphWidgetConfig, DatapointsGraphWidgetTimeProps, DateString, DpValuesItem, DpWithValues, EchartsCustomOptions, EchartsSeriesOptions, EventDetailsExtended, GraphDisplayOptions, MarkLineData, MarkPointData, MeasurementSeries, SeriesDatapointInfo, SeriesValue, SeverityType, TimeContextProps, YAxisOptions, customSeriesMarkLineData, customSeriesMarkPointData };
|
|
228
|
+
export { CHART_VIEW_CONTEXT, DATE_SELECTION_EXTENDED, ICONS_MAP, LEGEND_DISPLAY_OPTIONS, PRODUCT_EXPERIENCE_DATA_EXPLORER_AND_GRAPH, REALTIME_TEXTS, SEVERITY_LABELS };
|
|
229
|
+
export type { AlarmDetailsExtended, AlarmOrEventExtended, CustomSeriesOptions, DatapointAxisType, DatapointChartRenderType, DatapointLineType, DatapointRealtimeMeasurements, DatapointsGraphKPIDetails, DatapointsGraphWidgetConfig, DatapointsGraphWidgetTimeProps, DateString, DpValuesItem, DpWithValues, EchartsCustomOptions, EchartsSeriesOptions, EventDetailsExtended, GraphDisplayOptions, LegendDisplayOptionItem, MarkLineData, MarkPointData, MeasurementSeries, SelectableDatapoint, SeriesDatapointInfo, SeriesValue, SeverityType, TimeContextProps, YAxisOptions, customSeriesMarkLineData, customSeriesMarkPointData };
|
|
220
230
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sources":["../../../echart/models/datapoints-graph-widget.model.ts","../../../echart/models/chart.model.ts","../../../echart/models/svg-icons.model.ts"],"sourcesContent":[null,null,null],"names":[],"mappings":";;;;;;;;AAmBM;;;;AAKA;AACJ;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;;;;AAKA;;AAEA;AACA;AACA;AACA;;;AAGA;;;;;;;;AASI;;;;;;;;;AASJ;;AAGI;;AAEJ;AACA;;AAGI;;;AAIN;;AAEG;;AAGG;AAIN;AACE;AACA;AACD;AAED;AACM;;AAEL;AAED;;;;AAIM
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../../../echart/models/datapoints-graph-widget.model.ts","../../../echart/models/chart.model.ts","../../../echart/models/svg-icons.model.ts"],"sourcesContent":[null,null,null],"names":[],"mappings":";;;;;;;;AAmBM;;;;AAKA;AACJ;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;;;;AAKA;;AAEA;AACA;AACA;AACA;;;AAGA;;;;;;;;AASI;;;;;;;;;AASJ;;AAGI;;AAEJ;AACA;;AAGI;;;AAIN;;AAEG;;AAGG;AAIN;AACE;AACA;AACD;AAED;AACM;;AAEL;AAED;;;;AAIM;;;;;;;AAQL;AAED;;;;;AAUE;;;;;AAGD;;AAGC;;AAEA;;AAEE;;AAEF;;;AACD;;;;;;;AAQC;AACA;AACD;AAEK;AACA;AAEA;AAEA;AAEN;;;;AAKA;;;;;;;;;;;;;AAcM;AACA;AAEA;;;;AAKA;;;;;;;;;;AAWL;AAED;;;;;;;;AAUE;AACA;AACD;;ACzMD;;;;;;AAMG;AACH;AACE;;;;AAIA;;;AACD;;;AAIA;;;AAIA;AAEK;AACA;AACJ;AACE;AACD;AACF;;AAGC;AACA;AACD;AAED;AACE;AACA;AACA;AACD;;AC3CD;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACD;AAED;;;;;;;;;;;;"}
|
|
@@ -1527,7 +1527,7 @@ class AlarmsFilterComponent {
|
|
|
1527
1527
|
}
|
|
1528
1528
|
}
|
|
1529
1529
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: AlarmsFilterComponent, deps: [{ token: i1$2.FormBuilder }, { token: AlarmsViewService }, { token: i3.AlertService }, { token: i1.Router }, { token: i1.ActivatedRoute }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1530
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
1530
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.15", type: AlarmsFilterComponent, isStandalone: true, selector: "c8y-alarms-filter", inputs: { contextSourceId: "contextSourceId" }, outputs: { onFilterApplied: "onFilterApplied" }, viewQueries: [{ propertyName: "filtersDropdown", first: true, predicate: ["filtersDropdown"], descendants: true }], ngImport: i0, template: "<form\n class=\"d-flex a-i-center\"\n [formGroup]=\"formGroup\"\n>\n <div\n class=\"dropdown\"\n title=\"{{ 'Filter by severity' | translate }}\"\n container=\"body\"\n dropdown\n #filtersDropdown=\"bs-dropdown\"\n [cdkTrapFocus]=\"filtersDropdown.isOpen\"\n [insideClick]=\"true\"\n >\n <div class=\"input-group fit-w\">\n <div\n class=\"form-control d-flex a-i-center inner-scroll\"\n style=\"min-width: 104px; padding-top: 0; padding-bottom: 0\"\n >\n @if (chips.length !== severitiesList.length) {\n @for (chip of chips; track chip) {\n <span\n class=\"tag tag--info chip\"\n [attr.data-cy]=\"'c8y-alarms-filter--chip-' + chip\"\n >\n <button\n class=\"btn btn-xs btn-clean text-10\"\n title=\"{{ 'Remove' | translate }}\"\n type=\"button\"\n data-cy=\"c8y-alarms-filter--remove-chip\"\n c8yProductExperience\n [actionName]=\"PRODUCT_EXPERIENCE_ALARMS.EVENTS.ALARMS\"\n [actionData]=\"{\n component: PRODUCT_EXPERIENCE_ALARMS.COMPONENTS.ALARMS_FILTER,\n action: PRODUCT_EXPERIENCE_ALARMS.ACTIONS.REMOVE_CHIP_FILTER,\n filterValues: {\n severities: formGroup.value,\n showCleared: showCleared\n }\n }\"\n (click)=\"deselectChip(chip); $event.stopPropagation()\"\n >\n <i c8yIcon=\"times\"></i>\n </button>\n <i\n class=\"status stroked-icon icon-12\"\n [c8yIcon]=\"chip | AlarmSeverityToIcon\"\n [attr.data-cy]=\"'c8y-alarms-filter--icon-' + chip\"\n [ngClass]=\"chip | lowercase\"\n ></i>\n {{ SEVERITY_LABELS[chip] | translate }}\n </span>\n }\n } @else {\n <span\n class=\"text-truncate\"\n title=\"{{ 'All severities' | translate }}\"\n >\n {{ 'All severities' | translate }}\n </span>\n }\n </div>\n <div class=\"input-group-btn input-group-btn--last\">\n <button\n class=\"btn-default btn btn--caret\"\n title=\"{{ chips | AlarmSeveritiesToTitle }}\"\n data-cy=\"c8y-alarms-filter\"\n dropdownToggle\n (click)=\"resetForm()\"\n >\n <i class=\"caret\"></i>\n </button>\n </div>\n </div>\n <ul\n class=\"dropdown-menu dropdown-menu-action-bar\"\n *dropdownMenu\n >\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center sticky-top separator-bottom\">\n <label\n class=\"c8y-checkbox d-flex a-i-center\"\n [title]=\"'All' | translate\"\n >\n <input\n type=\"checkbox\"\n data-cy=\"c8y-alarms-filter--all\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"allChanged($event)\"\n [ngModel]=\"isEachCheckboxSelected$ | async\"\n [indeterminate]=\"isIndeterminate$ | async\"\n (click)=\"markSeveritiesAsTouched()\"\n />\n <span></span>\n <i\n class=\"status stroked-icon m-l-8 icon-20\"\n [c8yIcon]=\"'bell'\"\n ></i>\n <span class=\"m-l-8\">{{ 'All' | translate }}</span>\n </label>\n </li>\n @for (severity of severitiesList; track severity) {\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center\">\n <label\n class=\"c8y-checkbox d-flex a-i-center\"\n [title]=\"SEVERITY_LABELS[severity] | translate\"\n >\n <input\n type=\"checkbox\"\n [attr.data-cy]=\"'c8y-alarms-filter--' + severity\"\n [formControlName]=\"severity\"\n [value]=\"severity\"\n (click)=\"markSeveritiesAsTouched()\"\n />\n <span></span>\n <i\n class=\"status stroked-icon m-l-8 icon-20\"\n [c8yIcon]=\"severity | AlarmSeverityToIcon\"\n [ngClass]=\"severity | lowercase\"\n ></i>\n <span class=\"m-l-8\">{{ SEVERITY_LABELS[severity] | translate }}</span>\n </label>\n <!-- badge -->\n @if (alarmCounts[severity] || alarmCounts[severity] === 0) {\n <div class=\"badge badge-info m-l-auto\">\n @if (countLoading) {\n <i\n class=\"icon-spin\"\n [c8yIcon]=\"'circle-o-notch'\"\n ></i>\n }\n @if (!countLoading) {\n <span [attr.data-cy]=\"'c8y-alarms-filter--' + severity + '-badge'\">\n {{ alarmCounts[severity] < 99 ? alarmCounts[severity] : '99+' }}\n </span>\n }\n </div>\n }\n </li>\n }\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center separator-top\">\n <label\n class=\"c8y-switch\"\n [attr.aria-label]=\"'Show cleared alarms' | translate\"\n [attr.data-cy]=\"'c8y-alarms-filter--cleared'\"\n >\n <input\n type=\"checkbox\"\n #showClearedCheckbox\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"showCleared\"\n (click)=\"markSeveritiesAsTouched(); updateAlarmsCount(showClearedCheckbox.checked)\"\n />\n <span></span>\n <span\n class=\"text-truncate\"\n title=\"{{ 'Show cleared alarms' | translate }}\"\n >\n {{ 'Show cleared alarms' | translate }}\n </span>\n </label>\n </li>\n <li class=\"p-16 d-flex sticky-bottom separator-top\">\n <button\n class=\"btn btn-primary btn-sm flex-grow\"\n title=\"{{ 'Apply' | translate }}\"\n type=\"button\"\n data-cy=\"c8y-alarms-filter--apply\"\n c8yProductExperience\n [actionName]=\"PRODUCT_EXPERIENCE_ALARMS.EVENTS.ALARMS\"\n [actionData]=\"{\n component: PRODUCT_EXPERIENCE_ALARMS.COMPONENTS.ALARMS_FILTER,\n action: PRODUCT_EXPERIENCE_ALARMS.ACTIONS.APPLY_FILTER,\n filterValues: {\n severities: formGroup.value,\n showCleared: showCleared\n }\n }\"\n (click)=\"applyFilters(false); closeDropdown()\"\n [disabled]=\"shouldDisableApplyButton$ | async\"\n >\n {{ 'Apply' | translate }}\n </button>\n </li>\n </ul>\n </div>\n</form>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: BsDropdownDirective, selector: "[bsDropdown], [dropdown]", inputs: ["placement", "triggers", "container", "dropup", "autoClose", "isAnimated", "insideClick", "isDisabled", "isOpen"], outputs: ["isOpenChange", "onShown", "onHidden"], exportAs: ["bs-dropdown"] }, { kind: "directive", type: CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "directive", type: ProductExperienceDirective, selector: "[c8yProductExperience]", inputs: ["actionName", "actionData", "inherit", "suppressDataOverriding"] }, { kind: "directive", type: IconDirective, selector: "[c8yIcon]", inputs: ["c8yIcon"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: BsDropdownToggleDirective, selector: "[bsDropdownToggle],[dropdownToggle]", exportAs: ["bs-dropdown-toggle"] }, { kind: "directive", type: BsDropdownMenuDirective, selector: "[bsDropdownMenu],[dropdownMenu]", exportAs: ["bs-dropdown-menu"] }, { kind: "directive", type: RequiredInputPlaceholderDirective, selector: "input[required], input[formControlName]" }, { kind: "pipe", type: C8yTranslatePipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: LowerCasePipe, name: "lowercase" }, { kind: "pipe", type: AlarmSeverityToIconPipe, name: "AlarmSeverityToIcon" }, { kind: "pipe", type: AlarmSeveritiesToTitlePipe, name: "AlarmSeveritiesToTitle" }] }); }
|
|
1531
1531
|
}
|
|
1532
1532
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: AlarmsFilterComponent, decorators: [{
|
|
1533
1533
|
type: Component,
|
|
@@ -1549,7 +1549,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
|
|
|
1549
1549
|
LowerCasePipe,
|
|
1550
1550
|
AlarmSeverityToIconPipe,
|
|
1551
1551
|
AlarmSeveritiesToTitlePipe
|
|
1552
|
-
], template: "<form\n class=\"d-flex a-i-center\"\n [formGroup]=\"formGroup\"\n>\n <div\n class=\"dropdown\"\n title=\"{{ 'Filter by severity' | translate }}\"\n dropdown\n #filtersDropdown=\"bs-dropdown\"\n [cdkTrapFocus]=\"filtersDropdown.isOpen\"\n [insideClick]=\"true\"\n >\n <div class=\"input-group fit-w\">\n <div
|
|
1552
|
+
], template: "<form\n class=\"d-flex a-i-center\"\n [formGroup]=\"formGroup\"\n>\n <div\n class=\"dropdown\"\n title=\"{{ 'Filter by severity' | translate }}\"\n container=\"body\"\n dropdown\n #filtersDropdown=\"bs-dropdown\"\n [cdkTrapFocus]=\"filtersDropdown.isOpen\"\n [insideClick]=\"true\"\n >\n <div class=\"input-group fit-w\">\n <div\n class=\"form-control d-flex a-i-center inner-scroll\"\n style=\"min-width: 104px; padding-top: 0; padding-bottom: 0\"\n >\n @if (chips.length !== severitiesList.length) {\n @for (chip of chips; track chip) {\n <span\n class=\"tag tag--info chip\"\n [attr.data-cy]=\"'c8y-alarms-filter--chip-' + chip\"\n >\n <button\n class=\"btn btn-xs btn-clean text-10\"\n title=\"{{ 'Remove' | translate }}\"\n type=\"button\"\n data-cy=\"c8y-alarms-filter--remove-chip\"\n c8yProductExperience\n [actionName]=\"PRODUCT_EXPERIENCE_ALARMS.EVENTS.ALARMS\"\n [actionData]=\"{\n component: PRODUCT_EXPERIENCE_ALARMS.COMPONENTS.ALARMS_FILTER,\n action: PRODUCT_EXPERIENCE_ALARMS.ACTIONS.REMOVE_CHIP_FILTER,\n filterValues: {\n severities: formGroup.value,\n showCleared: showCleared\n }\n }\"\n (click)=\"deselectChip(chip); $event.stopPropagation()\"\n >\n <i c8yIcon=\"times\"></i>\n </button>\n <i\n class=\"status stroked-icon icon-12\"\n [c8yIcon]=\"chip | AlarmSeverityToIcon\"\n [attr.data-cy]=\"'c8y-alarms-filter--icon-' + chip\"\n [ngClass]=\"chip | lowercase\"\n ></i>\n {{ SEVERITY_LABELS[chip] | translate }}\n </span>\n }\n } @else {\n <span\n class=\"text-truncate\"\n title=\"{{ 'All severities' | translate }}\"\n >\n {{ 'All severities' | translate }}\n </span>\n }\n </div>\n <div class=\"input-group-btn input-group-btn--last\">\n <button\n class=\"btn-default btn btn--caret\"\n title=\"{{ chips | AlarmSeveritiesToTitle }}\"\n data-cy=\"c8y-alarms-filter\"\n dropdownToggle\n (click)=\"resetForm()\"\n >\n <i class=\"caret\"></i>\n </button>\n </div>\n </div>\n <ul\n class=\"dropdown-menu dropdown-menu-action-bar\"\n *dropdownMenu\n >\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center sticky-top separator-bottom\">\n <label\n class=\"c8y-checkbox d-flex a-i-center\"\n [title]=\"'All' | translate\"\n >\n <input\n type=\"checkbox\"\n data-cy=\"c8y-alarms-filter--all\"\n [ngModelOptions]=\"{ standalone: true }\"\n (ngModelChange)=\"allChanged($event)\"\n [ngModel]=\"isEachCheckboxSelected$ | async\"\n [indeterminate]=\"isIndeterminate$ | async\"\n (click)=\"markSeveritiesAsTouched()\"\n />\n <span></span>\n <i\n class=\"status stroked-icon m-l-8 icon-20\"\n [c8yIcon]=\"'bell'\"\n ></i>\n <span class=\"m-l-8\">{{ 'All' | translate }}</span>\n </label>\n </li>\n @for (severity of severitiesList; track severity) {\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center\">\n <label\n class=\"c8y-checkbox d-flex a-i-center\"\n [title]=\"SEVERITY_LABELS[severity] | translate\"\n >\n <input\n type=\"checkbox\"\n [attr.data-cy]=\"'c8y-alarms-filter--' + severity\"\n [formControlName]=\"severity\"\n [value]=\"severity\"\n (click)=\"markSeveritiesAsTouched()\"\n />\n <span></span>\n <i\n class=\"status stroked-icon m-l-8 icon-20\"\n [c8yIcon]=\"severity | AlarmSeverityToIcon\"\n [ngClass]=\"severity | lowercase\"\n ></i>\n <span class=\"m-l-8\">{{ SEVERITY_LABELS[severity] | translate }}</span>\n </label>\n <!-- badge -->\n @if (alarmCounts[severity] || alarmCounts[severity] === 0) {\n <div class=\"badge badge-info m-l-auto\">\n @if (countLoading) {\n <i\n class=\"icon-spin\"\n [c8yIcon]=\"'circle-o-notch'\"\n ></i>\n }\n @if (!countLoading) {\n <span [attr.data-cy]=\"'c8y-alarms-filter--' + severity + '-badge'\">\n {{ alarmCounts[severity] < 99 ? alarmCounts[severity] : '99+' }}\n </span>\n }\n </div>\n }\n </li>\n }\n <li class=\"p-l-16 p-r-16 p-t-4 p-b-4 d-flex a-i-center separator-top\">\n <label\n class=\"c8y-switch\"\n [attr.aria-label]=\"'Show cleared alarms' | translate\"\n [attr.data-cy]=\"'c8y-alarms-filter--cleared'\"\n >\n <input\n type=\"checkbox\"\n #showClearedCheckbox\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"showCleared\"\n (click)=\"markSeveritiesAsTouched(); updateAlarmsCount(showClearedCheckbox.checked)\"\n />\n <span></span>\n <span\n class=\"text-truncate\"\n title=\"{{ 'Show cleared alarms' | translate }}\"\n >\n {{ 'Show cleared alarms' | translate }}\n </span>\n </label>\n </li>\n <li class=\"p-16 d-flex sticky-bottom separator-top\">\n <button\n class=\"btn btn-primary btn-sm flex-grow\"\n title=\"{{ 'Apply' | translate }}\"\n type=\"button\"\n data-cy=\"c8y-alarms-filter--apply\"\n c8yProductExperience\n [actionName]=\"PRODUCT_EXPERIENCE_ALARMS.EVENTS.ALARMS\"\n [actionData]=\"{\n component: PRODUCT_EXPERIENCE_ALARMS.COMPONENTS.ALARMS_FILTER,\n action: PRODUCT_EXPERIENCE_ALARMS.ACTIONS.APPLY_FILTER,\n filterValues: {\n severities: formGroup.value,\n showCleared: showCleared\n }\n }\"\n (click)=\"applyFilters(false); closeDropdown()\"\n [disabled]=\"shouldDisableApplyButton$ | async\"\n >\n {{ 'Apply' | translate }}\n </button>\n </li>\n </ul>\n </div>\n</form>\n" }]
|
|
1553
1553
|
}], ctorParameters: () => [{ type: i1$2.FormBuilder }, { type: AlarmsViewService }, { type: i3.AlertService }, { type: i1.Router }, { type: i1.ActivatedRoute }], propDecorators: { contextSourceId: [{
|
|
1554
1554
|
type: Input
|
|
1555
1555
|
}], onFilterApplied: [{
|