@arsedizioni/ars-utils 22.6.85 → 22.6.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (79) hide show
  1. package/fesm2022/arsedizioni-ars-utils-clipper.common.mjs +3158 -3344
  2. package/fesm2022/arsedizioni-ars-utils-clipper.common.mjs.map +1 -1
  3. package/fesm2022/arsedizioni-ars-utils-clipper.ui.mjs +7616 -4772
  4. package/fesm2022/arsedizioni-ars-utils-clipper.ui.mjs.map +1 -1
  5. package/fesm2022/arsedizioni-ars-utils-core.date.mjs +321 -702
  6. package/fesm2022/arsedizioni-ars-utils-core.date.mjs.map +1 -1
  7. package/fesm2022/arsedizioni-ars-utils-core.markdown.mjs +445 -590
  8. package/fesm2022/arsedizioni-ars-utils-core.markdown.mjs.map +1 -1
  9. package/fesm2022/arsedizioni-ars-utils-core.mjs +1735 -2370
  10. package/fesm2022/arsedizioni-ars-utils-core.mjs.map +1 -1
  11. package/fesm2022/arsedizioni-ars-utils-core.validators.mjs +1280 -1470
  12. package/fesm2022/arsedizioni-ars-utils-core.validators.mjs.map +1 -1
  13. package/fesm2022/arsedizioni-ars-utils-evolution.common.mjs +1097 -1528
  14. package/fesm2022/arsedizioni-ars-utils-evolution.common.mjs.map +1 -1
  15. package/fesm2022/arsedizioni-ars-utils-support.common.mjs +198 -294
  16. package/fesm2022/arsedizioni-ars-utils-support.common.mjs.map +1 -1
  17. package/fesm2022/arsedizioni-ars-utils-ui.controls.date.mjs +115 -117
  18. package/fesm2022/arsedizioni-ars-utils-ui.controls.date.mjs.map +1 -1
  19. package/fesm2022/arsedizioni-ars-utils-ui.controls.mjs +1607 -613
  20. package/fesm2022/arsedizioni-ars-utils-ui.controls.mjs.map +1 -1
  21. package/fesm2022/arsedizioni-ars-utils-ui.controls.tree.mjs +840 -367
  22. package/fesm2022/arsedizioni-ars-utils-ui.controls.tree.mjs.map +1 -1
  23. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.auth.mjs +1634 -651
  24. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.auth.mjs.map +1 -1
  25. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.mjs +1255 -792
  26. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.mjs.map +1 -1
  27. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.prompt.mjs +1410 -357
  28. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.prompt.mjs.map +1 -1
  29. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.select.mjs +2401 -944
  30. package/fesm2022/arsedizioni-ars-utils-ui.dialogs.select.mjs.map +1 -1
  31. package/fesm2022/arsedizioni-ars-utils-ui.files.mjs +1553 -741
  32. package/fesm2022/arsedizioni-ars-utils-ui.files.mjs.map +1 -1
  33. package/fesm2022/arsedizioni-ars-utils-ui.filters.mjs +901 -430
  34. package/fesm2022/arsedizioni-ars-utils-ui.filters.mjs.map +1 -1
  35. package/fesm2022/arsedizioni-ars-utils-ui.help.mjs +737 -530
  36. package/fesm2022/arsedizioni-ars-utils-ui.help.mjs.map +1 -1
  37. package/fesm2022/arsedizioni-ars-utils-ui.mjs +6638 -1755
  38. package/fesm2022/arsedizioni-ars-utils-ui.mjs.map +1 -1
  39. package/fesm2022/arsedizioni-ars-utils-ui.navigation.mjs +1479 -1207
  40. package/fesm2022/arsedizioni-ars-utils-ui.navigation.mjs.map +1 -1
  41. package/fesm2022/arsedizioni-ars-utils-ui.notifications.mjs +1003 -270
  42. package/fesm2022/arsedizioni-ars-utils-ui.notifications.mjs.map +1 -1
  43. package/fesm2022/arsedizioni-ars-utils-ui.oauth.mjs +497 -278
  44. package/fesm2022/arsedizioni-ars-utils-ui.oauth.mjs.map +1 -1
  45. package/fesm2022/arsedizioni-ars-utils-ui.paginator.mjs +48 -52
  46. package/fesm2022/arsedizioni-ars-utils-ui.paginator.mjs.map +1 -1
  47. package/fesm2022/arsedizioni-ars-utils-ui.shell.mjs +464 -704
  48. package/fesm2022/arsedizioni-ars-utils-ui.shell.mjs.map +1 -1
  49. package/fesm2022/arsedizioni-ars-utils-ui.tinymce.mjs +724 -657
  50. package/fesm2022/arsedizioni-ars-utils-ui.tinymce.mjs.map +1 -1
  51. package/fesm2022/arsedizioni-ars-utils.mjs +3 -19
  52. package/fesm2022/arsedizioni-ars-utils.mjs.map +1 -1
  53. package/package.json +1 -1
  54. package/types/arsedizioni-ars-utils-clipper.common.d.ts +1151 -1163
  55. package/types/arsedizioni-ars-utils-clipper.ui.d.ts +1588 -1426
  56. package/types/arsedizioni-ars-utils-core.d.ts +1169 -1172
  57. package/types/arsedizioni-ars-utils-core.date.d.ts +204 -208
  58. package/types/arsedizioni-ars-utils-core.markdown.d.ts +128 -126
  59. package/types/arsedizioni-ars-utils-core.validators.d.ts +270 -236
  60. package/types/arsedizioni-ars-utils-evolution.common.d.ts +1054 -1067
  61. package/types/arsedizioni-ars-utils-support.common.d.ts +225 -234
  62. package/types/arsedizioni-ars-utils-ui.controls.d.ts +440 -278
  63. package/types/arsedizioni-ars-utils-ui.controls.date.d.ts +24 -28
  64. package/types/arsedizioni-ars-utils-ui.controls.tree.d.ts +172 -136
  65. package/types/arsedizioni-ars-utils-ui.d.ts +2035 -821
  66. package/types/arsedizioni-ars-utils-ui.dialogs.auth.d.ts +327 -322
  67. package/types/arsedizioni-ars-utils-ui.dialogs.d.ts +343 -347
  68. package/types/arsedizioni-ars-utils-ui.dialogs.prompt.d.ts +167 -167
  69. package/types/arsedizioni-ars-utils-ui.dialogs.select.d.ts +373 -367
  70. package/types/arsedizioni-ars-utils-ui.files.d.ts +335 -283
  71. package/types/arsedizioni-ars-utils-ui.filters.d.ts +232 -160
  72. package/types/arsedizioni-ars-utils-ui.help.d.ts +204 -211
  73. package/types/arsedizioni-ars-utils-ui.navigation.d.ts +811 -646
  74. package/types/arsedizioni-ars-utils-ui.notifications.d.ts +74 -78
  75. package/types/arsedizioni-ars-utils-ui.oauth.d.ts +102 -62
  76. package/types/arsedizioni-ars-utils-ui.paginator.d.ts +19 -22
  77. package/types/arsedizioni-ars-utils-ui.shell.d.ts +376 -382
  78. package/types/arsedizioni-ars-utils-ui.tinymce.d.ts +244 -231
  79. package/types/arsedizioni-ars-utils.d.ts +1 -3
@@ -1,433 +1,904 @@
1
- import * as i0 from '@angular/core';
2
- import { output, input, signal, computed, inject, ChangeDetectorRef, effect, ChangeDetectionStrategy, Component } from '@angular/core';
3
- import { form, maxLength, FormField } from '@angular/forms/signals';
4
- import * as i5 from '@angular/material/button';
5
- import { MatButtonModule } from '@angular/material/button';
6
- import * as i8 from '@angular/material/divider';
7
- import { MatDividerModule } from '@angular/material/divider';
8
- import * as i2 from '@angular/material/form-field';
9
- import { MatFormFieldModule } from '@angular/material/form-field';
10
- import * as i6 from '@angular/material/icon';
11
- import { MatIconModule } from '@angular/material/icon';
12
- import * as i3 from '@angular/material/input';
13
- import { MatInputModule } from '@angular/material/input';
14
- import * as i7 from '@angular/material/menu';
15
- import { MatMenuModule } from '@angular/material/menu';
16
- import * as i4 from '@angular/material/tooltip';
17
- import { MatTooltipModule } from '@angular/material/tooltip';
18
- import { SafeHtmlPipe } from '@arsedizioni/ars-utils/core';
19
- import * as i1 from '@arsedizioni/ars-utils/ui';
20
- import { FlexLayoutModule } from '@arsedizioni/ars-utils/ui';
21
-
22
- /** Constants identifying each filter group slot and text filter channels. */
1
+ import * as i0 from "@angular/core";
2
+ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, computed, effect, inject, input, output, signal } from "@angular/core";
3
+ import { FormField, form, maxLength } from "@angular/forms/signals";
4
+ import * as i5 from "@angular/material/button";
5
+ import { MatButtonModule } from "@angular/material/button";
6
+ import * as i8 from "@angular/material/divider";
7
+ import { MatDividerModule } from "@angular/material/divider";
8
+ import * as i2 from "@angular/material/form-field";
9
+ import { MatFormFieldModule } from "@angular/material/form-field";
10
+ import * as i6 from "@angular/material/icon";
11
+ import { MatIconModule } from "@angular/material/icon";
12
+ import * as i3 from "@angular/material/input";
13
+ import { MatInputModule } from "@angular/material/input";
14
+ import * as i7 from "@angular/material/menu";
15
+ import { MatMenuModule } from "@angular/material/menu";
16
+ import * as i4 from "@angular/material/tooltip";
17
+ import { MatTooltipModule } from "@angular/material/tooltip";
18
+ import { SafeHtmlPipe } from "@arsedizioni/ars-utils/core";
19
+ import * as i1 from "@arsedizioni/ars-utils/ui";
20
+ import { FlexLayoutModule } from "@arsedizioni/ars-utils/ui";
23
21
  const Filters = {
24
- FLT_1: 1,
25
- FLT_2: 2,
26
- FLT_3: 3,
27
- FLT_4: 4,
28
- FLT_5: 5,
29
- FLT_TEXT: 96,
30
- FLT_TEXT_1: 97,
31
- FLT_TEXT_2: 98,
32
- FLT_TEXT_3: 99
22
+ FLT_1: 1,
23
+ FLT_2: 2,
24
+ FLT_3: 3,
25
+ FLT_4: 4,
26
+ FLT_5: 5,
27
+ FLT_TEXT: 96,
28
+ FLT_TEXT_1: 97,
29
+ FLT_TEXT_2: 98,
30
+ FLT_TEXT_3: 99
33
31
  };
34
- /** Event payload emitted when an active filter changes. */
35
- class CurrentFilterChanged {
36
- }
37
- /** Holds the current state of all active filters for a filter-bar component. */
38
- class CurrentFilter {
39
- /**
40
- * Returns true if any filter slot or text field is currently active.
41
- * @returns Whether at least one filter is applied.
42
- */
43
- filtered() {
44
- return (this.flt1 != null ||
45
- this.flt2 != null ||
46
- this.flt3 != null ||
47
- this.flt4 != null ||
48
- this.flt5 != null ||
49
- !!this.text?.length ||
50
- !!this.text2?.length ||
51
- !!this.text3?.length);
52
- }
53
- }
54
- /** Holds the selected value and display state for a single typed filter slot. */
55
- class CurrentFilterItem {
56
- constructor() {
57
- this.enabled = true;
58
- }
59
- /**
60
- * Reset the filter to its empty state.
61
- */
62
- clear() {
63
- this.value = undefined;
64
- this.selectedTitle = undefined;
65
- }
66
- }
67
-
68
- class FilterBarComponent {
69
- constructor() {
70
- /** Emitted whenever any filter value changes. */
71
- this.changed = output();
72
- /** The list of filter groups to display. */
73
- this.filters = input(/* @ts-ignore */
74
- ...(ngDevMode ? [undefined, { debugName: "filters" }] : /* istanbul ignore next */ []));
75
- this.canFilterByText = input(false, /* @ts-ignore */
76
- ...(ngDevMode ? [{ debugName: "canFilterByText" }] : /* istanbul ignore next */ []));
77
- this.canFilterByText2 = input(false, /* @ts-ignore */
78
- ...(ngDevMode ? [{ debugName: "canFilterByText2" }] : /* istanbul ignore next */ []));
79
- this.canFilterByText3 = input(false, /* @ts-ignore */
80
- ...(ngDevMode ? [{ debugName: "canFilterByText3" }] : /* istanbul ignore next */ []));
81
- /** Initial text values for the search inputs — synced into the model signals on change. */
82
- this.initialText = input(undefined, /* @ts-ignore */
83
- ...(ngDevMode ? [{ debugName: "initialText" }] : /* istanbul ignore next */ []));
84
- this.initialText2 = input(undefined, /* @ts-ignore */
85
- ...(ngDevMode ? [{ debugName: "initialText2" }] : /* istanbul ignore next */ []));
86
- this.initialText3 = input(undefined, /* @ts-ignore */
87
- ...(ngDevMode ? [{ debugName: "initialText3" }] : /* istanbul ignore next */ []));
88
- this.textName = input("testo", /* @ts-ignore */
89
- ...(ngDevMode ? [{ debugName: "textName" }] : /* istanbul ignore next */ []));
90
- this.text2Name = input("...", /* @ts-ignore */
91
- ...(ngDevMode ? [{ debugName: "text2Name" }] : /* istanbul ignore next */ []));
92
- this.text3Name = input("...", /* @ts-ignore */
93
- ...(ngDevMode ? [{ debugName: "text3Name" }] : /* istanbul ignore next */ []));
94
- this.textLength = input(/* @ts-ignore */
95
- ...(ngDevMode ? [undefined, { debugName: "textLength" }] : /* istanbul ignore next */ []));
96
- this.text2Length = input(/* @ts-ignore */
97
- ...(ngDevMode ? [undefined, { debugName: "text2Length" }] : /* istanbul ignore next */ []));
98
- this.text3Length = input(/* @ts-ignore */
99
- ...(ngDevMode ? [undefined, { debugName: "text3Length" }] : /* istanbul ignore next */ []));
100
- this.showTextSearchButton = input(false, /* @ts-ignore */
101
- ...(ngDevMode ? [{ debugName: "showTextSearchButton" }] : /* istanbul ignore next */ []));
102
- this.appearance = input('outline', /* @ts-ignore */
103
- ...(ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []));
104
- /**
105
- * Text filter values. Empty is represented as '' (never undefined) because the
106
- * signals back the [formField] bindings; it is normalized to undefined when
107
- * committed to the CurrentFilter.
108
- */
109
- this.text = signal('', /* @ts-ignore */
110
- ...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
111
- this.text2 = signal('', /* @ts-ignore */
112
- ...(ngDevMode ? [{ debugName: "text2" }] : /* istanbul ignore next */ []));
113
- this.text3 = signal('', /* @ts-ignore */
114
- ...(ngDevMode ? [{ debugName: "text3" }] : /* istanbul ignore next */ []));
115
- /** Signal forms for the three text inputs (max 100 characters each). */
116
- this.textForm = form(this.text, p => maxLength(p, 100));
117
- this.text2Form = form(this.text2, p => maxLength(p, 100));
118
- this.text3Form = form(this.text3, p => maxLength(p, 100));
119
- /** Filter group for slot 1, derived reactively from the `filters` input. */
120
- this.flt1 = computed(() => this.filters()?.find(n => n.group === Filters.FLT_1), /* @ts-ignore */
121
- ...(ngDevMode ? [{ debugName: "flt1" }] : /* istanbul ignore next */ []));
122
- /** Filter group for slot 2, derived reactively from the `filters` input. */
123
- this.flt2 = computed(() => this.filters()?.find(n => n.group === Filters.FLT_2), /* @ts-ignore */
124
- ...(ngDevMode ? [{ debugName: "flt2" }] : /* istanbul ignore next */ []));
125
- /** Filter group for slot 3, derived reactively from the `filters` input. */
126
- this.flt3 = computed(() => this.filters()?.find(n => n.group === Filters.FLT_3), /* @ts-ignore */
127
- ...(ngDevMode ? [{ debugName: "flt3" }] : /* istanbul ignore next */ []));
128
- /** Filter group for slot 4, derived reactively from the `filters` input. */
129
- this.flt4 = computed(() => this.filters()?.find(n => n.group === Filters.FLT_4), /* @ts-ignore */
130
- ...(ngDevMode ? [{ debugName: "flt4" }] : /* istanbul ignore next */ []));
131
- /** Filter group for slot 5, derived reactively from the `filters` input. */
132
- this.flt5 = computed(() => this.filters()?.find(n => n.group === Filters.FLT_5), /* @ts-ignore */
133
- ...(ngDevMode ? [{ debugName: "flt5" }] : /* istanbul ignore next */ []));
134
- /** True when filter slot 1 has an action or item list. */
135
- this.canFilterByFlt1 = computed(() => {
136
- const g = this.flt1();
137
- return !!(g?.action || (g?.items && g.items.length > 0));
138
- }, /* @ts-ignore */
139
- ...(ngDevMode ? [{ debugName: "canFilterByFlt1" }] : /* istanbul ignore next */ []));
140
- /** True when filter slot 2 has an action or item list. */
141
- this.canFilterByFlt2 = computed(() => {
142
- const g = this.flt2();
143
- return !!(g?.action || (g?.items && g.items.length > 0));
144
- }, /* @ts-ignore */
145
- ...(ngDevMode ? [{ debugName: "canFilterByFlt2" }] : /* istanbul ignore next */ []));
146
- /** True when filter slot 3 has an action or item list. */
147
- this.canFilterByFlt3 = computed(() => {
148
- const g = this.flt3();
149
- return !!(g?.action || (g?.items && g.items.length > 0));
150
- }, /* @ts-ignore */
151
- ...(ngDevMode ? [{ debugName: "canFilterByFlt3" }] : /* istanbul ignore next */ []));
152
- /** True when filter slot 4 has an action or item list. */
153
- this.canFilterByFlt4 = computed(() => {
154
- const g = this.flt4();
155
- return !!(g?.action || (g?.items && g.items.length > 0));
156
- }, /* @ts-ignore */
157
- ...(ngDevMode ? [{ debugName: "canFilterByFlt4" }] : /* istanbul ignore next */ []));
158
- /** True when filter slot 5 has an action or item list. */
159
- this.canFilterByFlt5 = computed(() => {
160
- const g = this.flt5();
161
- return !!(g?.action || (g?.items && g.items.length > 0));
162
- }, /* @ts-ignore */
163
- ...(ngDevMode ? [{ debugName: "canFilterByFlt5" }] : /* istanbul ignore next */ []));
164
- this.currentFilter = new CurrentFilter();
165
- this.cdr = inject(ChangeDetectorRef);
166
- // Sync the initialText inputs into the model signals whenever they change
167
- effect(() => {
168
- this.text.set(this.initialText() ?? '');
169
- this.text2.set(this.initialText2() ?? '');
170
- this.text3.set(this.initialText3() ?? '');
171
- });
172
- }
173
- /**
174
- * No-op kept for API compatibility.
175
- * Filter groups are now computed reactively from the `filters()` input.
176
- */
177
- initializeFilters() { }
178
- /**
179
- * Applies the selected filter item to the current filter state and emits the change.
180
- * @param filter - The filter item to apply.
181
- */
182
- applyFilter(filter) {
183
- let changed = false;
184
- switch (filter.group) {
185
- case Filters.FLT_1:
186
- changed = this.currentFilter.flt1 !== filter.value;
187
- if (changed) {
188
- this.currentFilter.flt1 = filter.value;
189
- this.currentFilter.flt1Name = filter.titleSelected;
190
- }
191
- break;
192
- case Filters.FLT_2:
193
- changed = this.currentFilter.flt2 !== filter.value;
194
- if (changed) {
195
- this.currentFilter.flt2 = filter.value;
196
- this.currentFilter.flt2Name = filter.titleSelected;
197
- }
198
- break;
199
- case Filters.FLT_3:
200
- changed = this.currentFilter.flt3 !== filter.value;
201
- if (changed) {
202
- this.currentFilter.flt3 = filter.value;
203
- this.currentFilter.flt3Name = filter.titleSelected;
204
- }
205
- break;
206
- case Filters.FLT_4:
207
- changed = this.currentFilter.flt4 !== filter.value;
208
- if (changed) {
209
- this.currentFilter.flt4 = filter.value;
210
- this.currentFilter.flt4Name = filter.titleSelected;
211
- }
212
- break;
213
- case Filters.FLT_5:
214
- changed = this.currentFilter.flt5 !== filter.value;
215
- if (changed) {
216
- this.currentFilter.flt5 = filter.value;
217
- this.currentFilter.flt5Name = filter.titleSelected;
218
- }
219
- break;
220
- }
221
- if (changed) {
222
- this.cdr.markForCheck();
223
- this.changed.emit({ filter: this.currentFilter, group: filter.group });
224
- }
225
- }
226
- /**
227
- * Executes the action associated with a filter group, or clears the filter.
228
- * @param group - The filter group number.
229
- * @param clear - When `true`, clears the filter instead of triggering its action.
230
- */
231
- applyFilterAction(group, clear = false) {
232
- if (!clear) {
233
- const g = this.getFilterGroup(group);
234
- if (g?.action) {
235
- g.action(this, g);
236
- }
237
- }
238
- else {
239
- this.clearFilter(group);
240
- }
241
- }
242
- /** Commits the current text inputs to the filter state and emits the change. */
243
- applyTextFilter() {
244
- this.currentFilter.text = this.text() || undefined;
245
- this.currentFilter.text2 = this.text2() || undefined;
246
- this.currentFilter.text3 = this.text3() || undefined;
247
- this.changed.emit({
248
- filter: this.currentFilter,
249
- group: Filters.FLT_TEXT
250
- });
251
- }
252
- /**
253
- * Clears the active filter for the specified group and emits the change if it was set.
254
- * @param group - The filter group number to clear.
255
- */
256
- clearFilter(group) {
257
- let changed = false;
258
- switch (group) {
259
- case Filters.FLT_1:
260
- changed = this.currentFilter.flt1 != undefined;
261
- if (changed) {
262
- this.currentFilter.flt1 = undefined;
263
- this.currentFilter.flt1Name = undefined;
264
- }
265
- break;
266
- case Filters.FLT_2:
267
- changed = this.currentFilter.flt2 != undefined;
268
- if (changed) {
269
- this.currentFilter.flt2 = undefined;
270
- this.currentFilter.flt2Name = undefined;
271
- }
272
- break;
273
- case Filters.FLT_3:
274
- changed = this.currentFilter.flt3 != undefined;
275
- if (changed) {
276
- this.currentFilter.flt3 = undefined;
277
- this.currentFilter.flt3Name = undefined;
278
- }
279
- break;
280
- case Filters.FLT_4:
281
- changed = this.currentFilter.flt4 != undefined;
282
- if (changed) {
283
- this.currentFilter.flt4 = undefined;
284
- this.currentFilter.flt4Name = undefined;
285
- }
286
- break;
287
- case Filters.FLT_5:
288
- changed = this.currentFilter.flt5 != undefined;
289
- if (changed) {
290
- this.currentFilter.flt5 = undefined;
291
- this.currentFilter.flt5Name = undefined;
292
- }
293
- break;
294
- }
295
- if (changed) {
296
- this.cdr.markForCheck();
297
- this.changed.emit({ filter: this.currentFilter, group: group });
298
- }
299
- }
300
- /** Resets all active filters and text inputs, then emits the change. */
301
- clearAllFilters() {
302
- this.currentFilter.flt1 = undefined;
303
- this.currentFilter.flt1Name = undefined;
304
- this.currentFilter.flt2 = undefined;
305
- this.currentFilter.flt2Name = undefined;
306
- this.currentFilter.flt3 = undefined;
307
- this.currentFilter.flt3Name = undefined;
308
- this.currentFilter.flt4 = undefined;
309
- this.currentFilter.flt4Name = undefined;
310
- this.currentFilter.flt5 = undefined;
311
- this.currentFilter.flt5Name = undefined;
312
- this.currentFilter.text = undefined;
313
- this.currentFilter.text2 = undefined;
314
- this.currentFilter.text3 = undefined;
315
- this.text.set('');
316
- this.text2.set('');
317
- this.text3.set('');
318
- this.cdr.markForCheck();
319
- this.changed.emit({ filter: this.currentFilter, group: -1 });
320
- }
321
- /**
322
- * Returns `true` when more than one filter type is active, showing the "clear all" button.
323
- * @returns True when the clear-all button should be visible.
324
- */
325
- canClearAllFilters() {
326
- let count = 0;
327
- if (this.canFilterByText())
328
- count++;
329
- if (this.canFilterByText2())
330
- count++;
331
- if (this.canFilterByText3())
332
- count++;
333
- if (this.canFilterByFlt1())
334
- count++;
335
- if (this.canFilterByFlt2())
336
- count++;
337
- if (this.canFilterByFlt3())
338
- count++;
339
- if (this.canFilterByFlt4())
340
- count++;
341
- if (this.canFilterByFlt5())
342
- count++;
343
- return count > 1;
344
- }
345
- /**
346
- * Returns the filter group matching the given id, or `undefined` if not found.
347
- * @param id - The group id to look up.
348
- * @returns The matching `FilterGroup`, or `undefined`.
349
- */
350
- getFilterGroup(id) {
351
- return this.filters()?.find(n => n.group === id);
352
- }
353
- /** Synchronises the filter bar display with the values currently stored in `currentFilter`. */
354
- syncFilter() {
355
- let g = this.getFilterGroup(Filters.FLT_1);
356
- if (g?.items) {
357
- this.currentFilter.flt1Name = undefined;
358
- if (this.currentFilter.flt1) {
359
- const gi = g.items.find(n => n.value === this.currentFilter.flt1);
360
- if (gi)
361
- this.currentFilter.flt1Name = gi.titleSelected;
362
- else
363
- this.currentFilter.flt1 = undefined;
364
- }
365
- }
366
- g = this.getFilterGroup(Filters.FLT_2);
367
- if (g?.items) {
368
- this.currentFilter.flt2Name = undefined;
369
- if (this.currentFilter.flt2) {
370
- const gi = g.items.find(n => n.value === this.currentFilter.flt2);
371
- if (gi)
372
- this.currentFilter.flt2Name = gi.titleSelected;
373
- else
374
- this.currentFilter.flt2 = undefined;
375
- }
376
- }
377
- g = this.getFilterGroup(Filters.FLT_3);
378
- if (g?.items) {
379
- this.currentFilter.flt3Name = undefined;
380
- if (this.currentFilter.flt3) {
381
- const gi = g.items.find(n => n.value === this.currentFilter.flt3);
382
- if (gi)
383
- this.currentFilter.flt3Name = gi.titleSelected;
384
- else
385
- this.currentFilter.flt3 = undefined;
386
- }
387
- }
388
- g = this.getFilterGroup(Filters.FLT_4);
389
- if (g?.items) {
390
- this.currentFilter.flt4Name = undefined;
391
- if (this.currentFilter.flt4) {
392
- const gi = g.items.find(n => n.value === this.currentFilter.flt4);
393
- if (gi)
394
- this.currentFilter.flt4Name = gi.titleSelected;
395
- else
396
- this.currentFilter.flt4 = undefined;
397
- }
398
- }
399
- g = this.getFilterGroup(Filters.FLT_5);
400
- if (g?.items) {
401
- this.currentFilter.flt5Name = undefined;
402
- if (this.currentFilter.flt5) {
403
- const gi = g.items.find(n => n.value === this.currentFilter.flt5);
404
- if (gi)
405
- this.currentFilter.flt5Name = gi.titleSelected;
406
- else
407
- this.currentFilter.flt5 = undefined;
408
- }
409
- }
410
- this.text.set(this.currentFilter.text ?? '');
411
- this.text2.set(this.currentFilter.text2 ?? '');
412
- this.text3.set(this.currentFilter.text3 ?? '');
413
- this.cdr.markForCheck();
414
- }
415
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: FilterBarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
416
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: FilterBarComponent, isStandalone: true, selector: "filter-bar", inputs: { filters: { classPropertyName: "filters", publicName: "filters", isSignal: true, isRequired: false, transformFunction: null }, canFilterByText: { classPropertyName: "canFilterByText", publicName: "canFilterByText", isSignal: true, isRequired: false, transformFunction: null }, canFilterByText2: { classPropertyName: "canFilterByText2", publicName: "canFilterByText2", isSignal: true, isRequired: false, transformFunction: null }, canFilterByText3: { classPropertyName: "canFilterByText3", publicName: "canFilterByText3", isSignal: true, isRequired: false, transformFunction: null }, initialText: { classPropertyName: "initialText", publicName: "initialText", isSignal: true, isRequired: false, transformFunction: null }, initialText2: { classPropertyName: "initialText2", publicName: "initialText2", isSignal: true, isRequired: false, transformFunction: null }, initialText3: { classPropertyName: "initialText3", publicName: "initialText3", isSignal: true, isRequired: false, transformFunction: null }, textName: { classPropertyName: "textName", publicName: "textName", isSignal: true, isRequired: false, transformFunction: null }, text2Name: { classPropertyName: "text2Name", publicName: "text2Name", isSignal: true, isRequired: false, transformFunction: null }, text3Name: { classPropertyName: "text3Name", publicName: "text3Name", isSignal: true, isRequired: false, transformFunction: null }, textLength: { classPropertyName: "textLength", publicName: "textLength", isSignal: true, isRequired: false, transformFunction: null }, text2Length: { classPropertyName: "text2Length", publicName: "text2Length", isSignal: true, isRequired: false, transformFunction: null }, text3Length: { classPropertyName: "text3Length", publicName: "text3Length", isSignal: true, isRequired: false, transformFunction: null }, showTextSearchButton: { classPropertyName: "showTextSearchButton", publicName: "showTextSearchButton", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { changed: "changed" }, ngImport: i0, template: "<div fxLayout=\"row\" fxLayoutAlign=\"start center\" class=\"filterbox\"\n [class.filterbox-filtered]=\"currentFilter.filtered()\">\n <div fxFlex=\"*\" fxLayout=\"row wrap\" fxLayoutAlign=\"space-between\">\n @if (canFilterByText() || canFilterByText2() || canFilterByText3()) {\n <div fxFlex.lt-sm=\"100\" fxFlexAlign=\"center\">\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill style=\"padding:4px;\">\n @if (canFilterByText()) {\n <mat-form-field [style.width]=\"textLength() ?? '100%'\" [appearance]=\"appearance()\" subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{textName()}}...</mat-label>\n <input matInput [formField]=\"textForm\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n @if (showTextSearchButton()) {\n <button type=\"button\" matSuffix mat-icon-button aria-label=\"Trova\" (click)=\"applyTextFilter();\"\n matTooltip=\"Trova\">\n <mat-icon>search</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText2()) {\n <mat-form-field \n [style.width]=\"text2Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text2Name()}}...</mat-label>\n <input matInput [formField]=\"text2Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text2()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text2.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText3()) {\n <mat-form-field [style.width]=\"text3Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text3Name()}}...</mat-label>\n <input matInput [formField]=\"text3Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text3()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text3.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n </div>\n </div>\n }\n <div fxFlex.lt-sm=\"100\">\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\n @if (canFilterByFlt1() && flt1()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" \n (click)=\"applyFilterAction(1, false)\">\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt1) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(1, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt1() && flt1()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt1\"\n >\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt1=\"matMenu\">\n @for (f of flt1()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt1()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt2() && flt2()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" \n (click)=\"applyFilterAction(2, false)\">\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt2) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(2, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt2() && flt2()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt2\"\n >\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt2=\"matMenu\">\n @for (f of flt2()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt2()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt3() && flt3()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" \n (click)=\"applyFilterAction(3, false)\">\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt3) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(3, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt3() && flt3()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt3\"\n >\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt3=\"matMenu\">\n @for (f of flt3()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt3()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt4() && flt4()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" \n (click)=\"applyFilterAction(4, false)\">\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt4) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(4, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt4() && flt4()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt4\"\n >\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt4=\"matMenu\">\n @for (f of flt4()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt4()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt5() && flt5()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" \n (click)=\"applyFilterAction(5, false)\">\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt5) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(5, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt5() && flt5()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt5\"\n >\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt5=\"matMenu\">\n @for (f of flt5()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt5()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n </div>\n </div>\n </div>\n <div>\n @if (currentFilter.filtered() && canClearAllFilters()) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera tutti i filtri\" aria-label=\"Azzera tutti i filtri\"\n (click)=\"clearAllFilters()\">\n <mat-icon>filter_alt_off</mat-icon>\n </button>\n }\n </div>\n</div>\n", styles: [".fill,.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-header{padding-bottom:20px}.dialog-toolbar{padding:0 5px 0 24px;height:48px;min-height:48px}.dialog-close{margin-right:5px;margin-top:0}.dialog-menu{margin-left:10px;margin-top:10px}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}.center{text-align:center}.fill{min-height:100%!important;max-height:100%!important;height:100%!important}.scroll-auto{overflow:auto;height:100%}.scroll-hidden{overflow:hidden;height:100%}b{font-weight:700}.large{font-size:large!important;line-height:1.2!important}.smaller{font-size:smaller!important;line-height:1.2!important}.small{font-size:small!important;line-height:1.2!important}.small-icon-button{width:1.5rem!important;height:1.5rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.small-icon-button .mat-mdc-button-touch-target{width:1.5rem!important;height:1.5rem!important}.x-small{font-size:x-small!important;line-height:1.2!important}.bold{font-weight:700}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0;max-width:100%}@supports (-webkit-line-clamp: 2){.truncated{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@supports (-webkit-line-clamp: 2){.truncated span,.truncated div{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.clipped{min-width:0;max-width:100%}.clipped span,.clipped div{white-space:nowrap;overflow:hidden;text-overflow:clip}.accent{color:var(--ars-color-accent, #7894ae)!important}.primary{color:var(--ars-color-primary, #00a293)!important}.secondary{color:var(--ars-color-secondary, #4a635f)!important}.error{color:var(--ars-color-error, #ff5449)!important}.success{color:var(--ars-color-ok, #388E3C)!important}.warning{color:var(--ars-color-warning, #FFC107)!important}.text{color:var(--ars-color-text, #191c1b)!important}.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:10;background-color:var(--ars-color-overlay, rgba(255, 255, 255, .75))}.drawer-content{padding-top:10px}.drawer .title-container,.drawer .title-container-with-loader,.drawer-small .title-container,.drawer-small .title-container-with-loader{padding-right:5px;padding-bottom:20px;padding-left:0}.drawer .title-container,.drawer-small .title-container{padding-top:20px}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding-top:14px}.drawer .title,.drawer-small .title{font-size:19.2px!important;font-weight:600;padding-left:15px;min-width:150px;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.drawer .accordion-panel,.drawer-small .accordion-panel{background-color:transparent!important}.drawer .accordion-header,.drawer-small .accordion-header{padding-left:10px;padding-right:10px;border-radius:var(--mat-expansion-container-shape)}.drawer .mat-expansion-panel-body,.drawer-small .mat-expansion-panel-body{padding-left:10px!important;padding-right:10px!important;padding-bottom:20px!important}@media screen and (min-width:0px)and (max-width:430px){.drawer,.drawer-small{border-radius:0!important;min-width:100%!important;max-width:100%!important}}@media screen and (min-width:431px){.drawer{min-width:420px!important;max-width:420px!important}.drawer .title{min-width:200px}.drawer .mat-expansion-panel-body{padding-left:15px!important;padding-right:15px!important;padding-bottom:20px!important}.drawer-small{min-width:360px!important;max-width:360px!important}}.drawer-with-loader{padding-top:0!important}.drawer-transparent{background-color:transparent}.fade-in{animation:fadein .5s linear}@keyframes fadein{0%{opacity:0}to{opacity:1}}.bright{filter:brightness(.7)!important}@media(prefers-color-scheme:dark){.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b,.bold{font-weight:600}.bright{filter:brightness(1.5)!important}}.filterbox{border-radius:auto;background-color:transparent;padding:4px}.filterbox-button{max-width:200px;white-space:normal;text-align:center;display:-webkit-box;display:inline-block;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical;text-overflow:ellipsis}.filterbox-selected{font-weight:800!important}.filterbox-filtered{border-radius:12px;background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}@media(prefers-color-scheme:dark){.filterbox-filtered{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}}\n"], dependencies: [{ kind: "ngmodule", type: FlexLayoutModule }, { kind: "directive", type: i1.FxLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg] ", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i1.FxFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg] ", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }, { kind: "directive", type: i1.FxLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg] ", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { kind: "directive", type: i1.FxLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg] ", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { kind: "directive", type: i1.FxFlexAlignDirective, selector: " [fxFlexAlign], [fxFlexAlign.xs], [fxFlexAlign.sm], [fxFlexAlign.md], [fxFlexAlign.lg], [fxFlexAlign.xl], [fxFlexAlign.lt-sm], [fxFlexAlign.lt-md], [fxFlexAlign.lt-lg], [fxFlexAlign.lt-xl], [fxFlexAlign.gt-xs], [fxFlexAlign.gt-sm], [fxFlexAlign.gt-md], [fxFlexAlign.gt-lg] ", inputs: ["fxFlexAlign", "fxFlexAlign.xs", "fxFlexAlign.sm", "fxFlexAlign.md", "fxFlexAlign.lg", "fxFlexAlign.xl", "fxFlexAlign.lt-sm", "fxFlexAlign.lt-md", "fxFlexAlign.lt-lg", "fxFlexAlign.lt-xl", "fxFlexAlign.gt-xs", "fxFlexAlign.gt-sm", "fxFlexAlign.gt-md", "fxFlexAlign.gt-lg"] }, { kind: "directive", type: i1.FxFlexFillDirective, selector: " [fxFlexFill], [fxFill], [fxFlexFill.xs], [fxFlexFill.sm], [fxFlexFill.md], [fxFlexFill.lg], [fxFlexFill.xl], [fxFlexFill.lt-sm], [fxFlexFill.lt-md], [fxFlexFill.lt-lg], [fxFlexFill.lt-xl], [fxFlexFill.gt-xs], [fxFlexFill.gt-sm], [fxFlexFill.gt-md], [fxFlexFill.gt-lg] ", inputs: ["fxFlexFill", "fxFill", "fxFlexFill.xs", "fxFlexFill.sm", "fxFlexFill.md", "fxFlexFill.lg", "fxFlexFill.xl", "fxFlexFill.lt-sm", "fxFlexFill.lt-md", "fxFlexFill.lt-lg", "fxFlexFill.lt-xl", "fxFlexFill.gt-xs", "fxFlexFill.gt-sm", "fxFlexFill.gt-md", "fxFlexFill.gt-lg"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i2.MatLabel, selector: "mat-label" }, { kind: "directive", type: i2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i5.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: i5.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i7.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i7.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i7.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i8.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
417
- }
418
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: FilterBarComponent, decorators: [{
419
- type: Component,
420
- args: [{ selector: "filter-bar", standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [FlexLayoutModule, MatFormFieldModule, MatInputModule, FormField,
421
- MatTooltipModule, MatButtonModule, MatIconModule, MatMenuModule, MatDividerModule, SafeHtmlPipe], template: "<div fxLayout=\"row\" fxLayoutAlign=\"start center\" class=\"filterbox\"\n [class.filterbox-filtered]=\"currentFilter.filtered()\">\n <div fxFlex=\"*\" fxLayout=\"row wrap\" fxLayoutAlign=\"space-between\">\n @if (canFilterByText() || canFilterByText2() || canFilterByText3()) {\n <div fxFlex.lt-sm=\"100\" fxFlexAlign=\"center\">\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill style=\"padding:4px;\">\n @if (canFilterByText()) {\n <mat-form-field [style.width]=\"textLength() ?? '100%'\" [appearance]=\"appearance()\" subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{textName()}}...</mat-label>\n <input matInput [formField]=\"textForm\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n @if (showTextSearchButton()) {\n <button type=\"button\" matSuffix mat-icon-button aria-label=\"Trova\" (click)=\"applyTextFilter();\"\n matTooltip=\"Trova\">\n <mat-icon>search</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText2()) {\n <mat-form-field \n [style.width]=\"text2Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text2Name()}}...</mat-label>\n <input matInput [formField]=\"text2Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text2()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text2.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText3()) {\n <mat-form-field [style.width]=\"text3Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text3Name()}}...</mat-label>\n <input matInput [formField]=\"text3Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text3()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text3.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n </div>\n </div>\n }\n <div fxFlex.lt-sm=\"100\">\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\n @if (canFilterByFlt1() && flt1()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" \n (click)=\"applyFilterAction(1, false)\">\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt1) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(1, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt1() && flt1()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt1\"\n >\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt1=\"matMenu\">\n @for (f of flt1()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt1()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt2() && flt2()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" \n (click)=\"applyFilterAction(2, false)\">\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt2) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(2, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt2() && flt2()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt2\"\n >\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt2=\"matMenu\">\n @for (f of flt2()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt2()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt3() && flt3()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" \n (click)=\"applyFilterAction(3, false)\">\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt3) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(3, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt3() && flt3()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt3\"\n >\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt3=\"matMenu\">\n @for (f of flt3()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt3()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt4() && flt4()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" \n (click)=\"applyFilterAction(4, false)\">\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt4) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(4, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt4() && flt4()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt4\"\n >\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt4=\"matMenu\">\n @for (f of flt4()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt4()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt5() && flt5()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" \n (click)=\"applyFilterAction(5, false)\">\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt5) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(5, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt5() && flt5()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt5\"\n >\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt5=\"matMenu\">\n @for (f of flt5()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt5()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n </div>\n </div>\n </div>\n <div>\n @if (currentFilter.filtered() && canClearAllFilters()) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera tutti i filtri\" aria-label=\"Azzera tutti i filtri\"\n (click)=\"clearAllFilters()\">\n <mat-icon>filter_alt_off</mat-icon>\n </button>\n }\n </div>\n</div>\n", styles: [".fill,.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-header{padding-bottom:20px}.dialog-toolbar{padding:0 5px 0 24px;height:48px;min-height:48px}.dialog-close{margin-right:5px;margin-top:0}.dialog-menu{margin-left:10px;margin-top:10px}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}.center{text-align:center}.fill{min-height:100%!important;max-height:100%!important;height:100%!important}.scroll-auto{overflow:auto;height:100%}.scroll-hidden{overflow:hidden;height:100%}b{font-weight:700}.large{font-size:large!important;line-height:1.2!important}.smaller{font-size:smaller!important;line-height:1.2!important}.small{font-size:small!important;line-height:1.2!important}.small-icon-button{width:1.5rem!important;height:1.5rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.small-icon-button .mat-mdc-button-touch-target{width:1.5rem!important;height:1.5rem!important}.x-small{font-size:x-small!important;line-height:1.2!important}.bold{font-weight:700}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0;max-width:100%}@supports (-webkit-line-clamp: 2){.truncated{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@supports (-webkit-line-clamp: 2){.truncated span,.truncated div{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.clipped{min-width:0;max-width:100%}.clipped span,.clipped div{white-space:nowrap;overflow:hidden;text-overflow:clip}.accent{color:var(--ars-color-accent, #7894ae)!important}.primary{color:var(--ars-color-primary, #00a293)!important}.secondary{color:var(--ars-color-secondary, #4a635f)!important}.error{color:var(--ars-color-error, #ff5449)!important}.success{color:var(--ars-color-ok, #388E3C)!important}.warning{color:var(--ars-color-warning, #FFC107)!important}.text{color:var(--ars-color-text, #191c1b)!important}.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:10;background-color:var(--ars-color-overlay, rgba(255, 255, 255, .75))}.drawer-content{padding-top:10px}.drawer .title-container,.drawer .title-container-with-loader,.drawer-small .title-container,.drawer-small .title-container-with-loader{padding-right:5px;padding-bottom:20px;padding-left:0}.drawer .title-container,.drawer-small .title-container{padding-top:20px}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding-top:14px}.drawer .title,.drawer-small .title{font-size:19.2px!important;font-weight:600;padding-left:15px;min-width:150px;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.drawer .accordion-panel,.drawer-small .accordion-panel{background-color:transparent!important}.drawer .accordion-header,.drawer-small .accordion-header{padding-left:10px;padding-right:10px;border-radius:var(--mat-expansion-container-shape)}.drawer .mat-expansion-panel-body,.drawer-small .mat-expansion-panel-body{padding-left:10px!important;padding-right:10px!important;padding-bottom:20px!important}@media screen and (min-width:0px)and (max-width:430px){.drawer,.drawer-small{border-radius:0!important;min-width:100%!important;max-width:100%!important}}@media screen and (min-width:431px){.drawer{min-width:420px!important;max-width:420px!important}.drawer .title{min-width:200px}.drawer .mat-expansion-panel-body{padding-left:15px!important;padding-right:15px!important;padding-bottom:20px!important}.drawer-small{min-width:360px!important;max-width:360px!important}}.drawer-with-loader{padding-top:0!important}.drawer-transparent{background-color:transparent}.fade-in{animation:fadein .5s linear}@keyframes fadein{0%{opacity:0}to{opacity:1}}.bright{filter:brightness(.7)!important}@media(prefers-color-scheme:dark){.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b,.bold{font-weight:600}.bright{filter:brightness(1.5)!important}}.filterbox{border-radius:auto;background-color:transparent;padding:4px}.filterbox-button{max-width:200px;white-space:normal;text-align:center;display:-webkit-box;display:inline-block;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical;text-overflow:ellipsis}.filterbox-selected{font-weight:800!important}.filterbox-filtered{border-radius:12px;background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}@media(prefers-color-scheme:dark){.filterbox-filtered{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}}\n"] }]
422
- }], ctorParameters: () => [], propDecorators: { changed: [{ type: i0.Output, args: ["changed"] }], filters: [{ type: i0.Input, args: [{ isSignal: true, alias: "filters", required: false }] }], canFilterByText: [{ type: i0.Input, args: [{ isSignal: true, alias: "canFilterByText", required: false }] }], canFilterByText2: [{ type: i0.Input, args: [{ isSignal: true, alias: "canFilterByText2", required: false }] }], canFilterByText3: [{ type: i0.Input, args: [{ isSignal: true, alias: "canFilterByText3", required: false }] }], initialText: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialText", required: false }] }], initialText2: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialText2", required: false }] }], initialText3: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialText3", required: false }] }], textName: [{ type: i0.Input, args: [{ isSignal: true, alias: "textName", required: false }] }], text2Name: [{ type: i0.Input, args: [{ isSignal: true, alias: "text2Name", required: false }] }], text3Name: [{ type: i0.Input, args: [{ isSignal: true, alias: "text3Name", required: false }] }], textLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "textLength", required: false }] }], text2Length: [{ type: i0.Input, args: [{ isSignal: true, alias: "text2Length", required: false }] }], text3Length: [{ type: i0.Input, args: [{ isSignal: true, alias: "text3Length", required: false }] }], showTextSearchButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "showTextSearchButton", required: false }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }] } });
423
-
424
- /*
425
- * Public API Surface of @arsedizioni/ars-utils/ui.filters
426
- */
427
-
428
- /**
429
- * Generated bundle index. Do not edit.
430
- */
431
-
32
+ var CurrentFilterChanged = class {};
33
+ var CurrentFilter = class {
34
+ filtered() {
35
+ return this.flt1 != null || this.flt2 != null || this.flt3 != null || this.flt4 != null || this.flt5 != null || !!this.text?.length || !!this.text2?.length || !!this.text3?.length;
36
+ }
37
+ };
38
+ var CurrentFilterItem = class {
39
+ constructor() {
40
+ this.enabled = true;
41
+ }
42
+ clear() {
43
+ this.value = void 0;
44
+ this.selectedTitle = void 0;
45
+ }
46
+ };
47
+ var FilterBarComponent = class FilterBarComponent {
48
+ constructor() {
49
+ this.changed = output();
50
+ this.filters = input(...ngDevMode ? [void 0, { debugName: "filters" }] : /* istanbul ignore next */ []);
51
+ this.canFilterByText = input(false, ...ngDevMode ? [{ debugName: "canFilterByText" }] : /* istanbul ignore next */ []);
52
+ this.canFilterByText2 = input(false, ...ngDevMode ? [{ debugName: "canFilterByText2" }] : /* istanbul ignore next */ []);
53
+ this.canFilterByText3 = input(false, ...ngDevMode ? [{ debugName: "canFilterByText3" }] : /* istanbul ignore next */ []);
54
+ this.initialText = input(void 0, ...ngDevMode ? [{ debugName: "initialText" }] : /* istanbul ignore next */ []);
55
+ this.initialText2 = input(void 0, ...ngDevMode ? [{ debugName: "initialText2" }] : /* istanbul ignore next */ []);
56
+ this.initialText3 = input(void 0, ...ngDevMode ? [{ debugName: "initialText3" }] : /* istanbul ignore next */ []);
57
+ this.textName = input("testo", ...ngDevMode ? [{ debugName: "textName" }] : /* istanbul ignore next */ []);
58
+ this.text2Name = input("...", ...ngDevMode ? [{ debugName: "text2Name" }] : /* istanbul ignore next */ []);
59
+ this.text3Name = input("...", ...ngDevMode ? [{ debugName: "text3Name" }] : /* istanbul ignore next */ []);
60
+ this.textLength = input(...ngDevMode ? [void 0, { debugName: "textLength" }] : /* istanbul ignore next */ []);
61
+ this.text2Length = input(...ngDevMode ? [void 0, { debugName: "text2Length" }] : /* istanbul ignore next */ []);
62
+ this.text3Length = input(...ngDevMode ? [void 0, { debugName: "text3Length" }] : /* istanbul ignore next */ []);
63
+ this.showTextSearchButton = input(false, ...ngDevMode ? [{ debugName: "showTextSearchButton" }] : /* istanbul ignore next */ []);
64
+ this.appearance = input("outline", ...ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []);
65
+ this.text = signal("", ...ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []);
66
+ this.text2 = signal("", ...ngDevMode ? [{ debugName: "text2" }] : /* istanbul ignore next */ []);
67
+ this.text3 = signal("", ...ngDevMode ? [{ debugName: "text3" }] : /* istanbul ignore next */ []);
68
+ this.textForm = form(this.text, (p) => maxLength(p, 100));
69
+ this.text2Form = form(this.text2, (p) => maxLength(p, 100));
70
+ this.text3Form = form(this.text3, (p) => maxLength(p, 100));
71
+ this.flt1 = computed(() => this.filters()?.find((n) => n.group === Filters.FLT_1), ...ngDevMode ? [{ debugName: "flt1" }] : /* istanbul ignore next */ []);
72
+ this.flt2 = computed(() => this.filters()?.find((n) => n.group === Filters.FLT_2), ...ngDevMode ? [{ debugName: "flt2" }] : /* istanbul ignore next */ []);
73
+ this.flt3 = computed(() => this.filters()?.find((n) => n.group === Filters.FLT_3), ...ngDevMode ? [{ debugName: "flt3" }] : /* istanbul ignore next */ []);
74
+ this.flt4 = computed(() => this.filters()?.find((n) => n.group === Filters.FLT_4), ...ngDevMode ? [{ debugName: "flt4" }] : /* istanbul ignore next */ []);
75
+ this.flt5 = computed(() => this.filters()?.find((n) => n.group === Filters.FLT_5), ...ngDevMode ? [{ debugName: "flt5" }] : /* istanbul ignore next */ []);
76
+ this.canFilterByFlt1 = computed(() => {
77
+ const g = this.flt1();
78
+ return !!(g?.action || g?.items && g.items.length > 0);
79
+ }, ...ngDevMode ? [{ debugName: "canFilterByFlt1" }] : /* istanbul ignore next */ []);
80
+ this.canFilterByFlt2 = computed(() => {
81
+ const g = this.flt2();
82
+ return !!(g?.action || g?.items && g.items.length > 0);
83
+ }, ...ngDevMode ? [{ debugName: "canFilterByFlt2" }] : /* istanbul ignore next */ []);
84
+ this.canFilterByFlt3 = computed(() => {
85
+ const g = this.flt3();
86
+ return !!(g?.action || g?.items && g.items.length > 0);
87
+ }, ...ngDevMode ? [{ debugName: "canFilterByFlt3" }] : /* istanbul ignore next */ []);
88
+ this.canFilterByFlt4 = computed(() => {
89
+ const g = this.flt4();
90
+ return !!(g?.action || g?.items && g.items.length > 0);
91
+ }, ...ngDevMode ? [{ debugName: "canFilterByFlt4" }] : /* istanbul ignore next */ []);
92
+ this.canFilterByFlt5 = computed(() => {
93
+ const g = this.flt5();
94
+ return !!(g?.action || g?.items && g.items.length > 0);
95
+ }, ...ngDevMode ? [{ debugName: "canFilterByFlt5" }] : /* istanbul ignore next */ []);
96
+ this.currentFilter = new CurrentFilter();
97
+ this.cdr = inject(ChangeDetectorRef);
98
+ effect(() => {
99
+ this.text.set(this.initialText() ?? "");
100
+ this.text2.set(this.initialText2() ?? "");
101
+ this.text3.set(this.initialText3() ?? "");
102
+ });
103
+ }
104
+ initializeFilters() {}
105
+ applyFilter(filter) {
106
+ let changed = false;
107
+ switch (filter.group) {
108
+ case Filters.FLT_1:
109
+ changed = this.currentFilter.flt1 !== filter.value;
110
+ if (changed) {
111
+ this.currentFilter.flt1 = filter.value;
112
+ this.currentFilter.flt1Name = filter.titleSelected;
113
+ }
114
+ break;
115
+ case Filters.FLT_2:
116
+ changed = this.currentFilter.flt2 !== filter.value;
117
+ if (changed) {
118
+ this.currentFilter.flt2 = filter.value;
119
+ this.currentFilter.flt2Name = filter.titleSelected;
120
+ }
121
+ break;
122
+ case Filters.FLT_3:
123
+ changed = this.currentFilter.flt3 !== filter.value;
124
+ if (changed) {
125
+ this.currentFilter.flt3 = filter.value;
126
+ this.currentFilter.flt3Name = filter.titleSelected;
127
+ }
128
+ break;
129
+ case Filters.FLT_4:
130
+ changed = this.currentFilter.flt4 !== filter.value;
131
+ if (changed) {
132
+ this.currentFilter.flt4 = filter.value;
133
+ this.currentFilter.flt4Name = filter.titleSelected;
134
+ }
135
+ break;
136
+ case Filters.FLT_5:
137
+ changed = this.currentFilter.flt5 !== filter.value;
138
+ if (changed) {
139
+ this.currentFilter.flt5 = filter.value;
140
+ this.currentFilter.flt5Name = filter.titleSelected;
141
+ }
142
+ }
143
+ if (changed) {
144
+ this.cdr.markForCheck();
145
+ this.changed.emit({
146
+ filter: this.currentFilter,
147
+ group: filter.group
148
+ });
149
+ }
150
+ }
151
+ applyFilterAction(group, clear = false) {
152
+ if (!clear) {
153
+ const g = this.getFilterGroup(group);
154
+ if (g?.action) g.action(this, g);
155
+ } else this.clearFilter(group);
156
+ }
157
+ applyTextFilter() {
158
+ this.currentFilter.text = this.text() || void 0;
159
+ this.currentFilter.text2 = this.text2() || void 0;
160
+ this.currentFilter.text3 = this.text3() || void 0;
161
+ this.changed.emit({
162
+ filter: this.currentFilter,
163
+ group: Filters.FLT_TEXT
164
+ });
165
+ }
166
+ clearFilter(group) {
167
+ let changed = false;
168
+ switch (group) {
169
+ case Filters.FLT_1:
170
+ changed = this.currentFilter.flt1 != void 0;
171
+ if (changed) {
172
+ this.currentFilter.flt1 = void 0;
173
+ this.currentFilter.flt1Name = void 0;
174
+ }
175
+ break;
176
+ case Filters.FLT_2:
177
+ changed = this.currentFilter.flt2 != void 0;
178
+ if (changed) {
179
+ this.currentFilter.flt2 = void 0;
180
+ this.currentFilter.flt2Name = void 0;
181
+ }
182
+ break;
183
+ case Filters.FLT_3:
184
+ changed = this.currentFilter.flt3 != void 0;
185
+ if (changed) {
186
+ this.currentFilter.flt3 = void 0;
187
+ this.currentFilter.flt3Name = void 0;
188
+ }
189
+ break;
190
+ case Filters.FLT_4:
191
+ changed = this.currentFilter.flt4 != void 0;
192
+ if (changed) {
193
+ this.currentFilter.flt4 = void 0;
194
+ this.currentFilter.flt4Name = void 0;
195
+ }
196
+ break;
197
+ case Filters.FLT_5:
198
+ changed = this.currentFilter.flt5 != void 0;
199
+ if (changed) {
200
+ this.currentFilter.flt5 = void 0;
201
+ this.currentFilter.flt5Name = void 0;
202
+ }
203
+ }
204
+ if (changed) {
205
+ this.cdr.markForCheck();
206
+ this.changed.emit({
207
+ filter: this.currentFilter,
208
+ group
209
+ });
210
+ }
211
+ }
212
+ clearAllFilters() {
213
+ this.currentFilter.flt1 = void 0;
214
+ this.currentFilter.flt1Name = void 0;
215
+ this.currentFilter.flt2 = void 0;
216
+ this.currentFilter.flt2Name = void 0;
217
+ this.currentFilter.flt3 = void 0;
218
+ this.currentFilter.flt3Name = void 0;
219
+ this.currentFilter.flt4 = void 0;
220
+ this.currentFilter.flt4Name = void 0;
221
+ this.currentFilter.flt5 = void 0;
222
+ this.currentFilter.flt5Name = void 0;
223
+ this.currentFilter.text = void 0;
224
+ this.currentFilter.text2 = void 0;
225
+ this.currentFilter.text3 = void 0;
226
+ this.text.set("");
227
+ this.text2.set("");
228
+ this.text3.set("");
229
+ this.cdr.markForCheck();
230
+ this.changed.emit({
231
+ filter: this.currentFilter,
232
+ group: -1
233
+ });
234
+ }
235
+ canClearAllFilters() {
236
+ let count = 0;
237
+ if (this.canFilterByText()) count++;
238
+ if (this.canFilterByText2()) count++;
239
+ if (this.canFilterByText3()) count++;
240
+ if (this.canFilterByFlt1()) count++;
241
+ if (this.canFilterByFlt2()) count++;
242
+ if (this.canFilterByFlt3()) count++;
243
+ if (this.canFilterByFlt4()) count++;
244
+ if (this.canFilterByFlt5()) count++;
245
+ return count > 1;
246
+ }
247
+ getFilterGroup(id) {
248
+ return this.filters()?.find((n) => n.group === id);
249
+ }
250
+ syncFilter() {
251
+ let g = this.getFilterGroup(Filters.FLT_1);
252
+ if (g?.items) {
253
+ this.currentFilter.flt1Name = void 0;
254
+ if (this.currentFilter.flt1) {
255
+ const gi = g.items.find((n) => n.value === this.currentFilter.flt1);
256
+ if (gi) this.currentFilter.flt1Name = gi.titleSelected;
257
+ else this.currentFilter.flt1 = void 0;
258
+ }
259
+ }
260
+ g = this.getFilterGroup(Filters.FLT_2);
261
+ if (g?.items) {
262
+ this.currentFilter.flt2Name = void 0;
263
+ if (this.currentFilter.flt2) {
264
+ const gi = g.items.find((n) => n.value === this.currentFilter.flt2);
265
+ if (gi) this.currentFilter.flt2Name = gi.titleSelected;
266
+ else this.currentFilter.flt2 = void 0;
267
+ }
268
+ }
269
+ g = this.getFilterGroup(Filters.FLT_3);
270
+ if (g?.items) {
271
+ this.currentFilter.flt3Name = void 0;
272
+ if (this.currentFilter.flt3) {
273
+ const gi = g.items.find((n) => n.value === this.currentFilter.flt3);
274
+ if (gi) this.currentFilter.flt3Name = gi.titleSelected;
275
+ else this.currentFilter.flt3 = void 0;
276
+ }
277
+ }
278
+ g = this.getFilterGroup(Filters.FLT_4);
279
+ if (g?.items) {
280
+ this.currentFilter.flt4Name = void 0;
281
+ if (this.currentFilter.flt4) {
282
+ const gi = g.items.find((n) => n.value === this.currentFilter.flt4);
283
+ if (gi) this.currentFilter.flt4Name = gi.titleSelected;
284
+ else this.currentFilter.flt4 = void 0;
285
+ }
286
+ }
287
+ g = this.getFilterGroup(Filters.FLT_5);
288
+ if (g?.items) {
289
+ this.currentFilter.flt5Name = void 0;
290
+ if (this.currentFilter.flt5) {
291
+ const gi = g.items.find((n) => n.value === this.currentFilter.flt5);
292
+ if (gi) this.currentFilter.flt5Name = gi.titleSelected;
293
+ else this.currentFilter.flt5 = void 0;
294
+ }
295
+ }
296
+ this.text.set(this.currentFilter.text ?? "");
297
+ this.text2.set(this.currentFilter.text2 ?? "");
298
+ this.text3.set(this.currentFilter.text3 ?? "");
299
+ this.cdr.markForCheck();
300
+ }
301
+ static {
302
+ this.ɵfac = i0.ɵɵngDeclareFactory({
303
+ minVersion: "12.0.0",
304
+ version: "22.2.1",
305
+ ngImport: i0,
306
+ type: FilterBarComponent,
307
+ deps: [],
308
+ target: i0.ɵɵFactoryTarget.Component
309
+ });
310
+ }
311
+ static {
312
+ this.ɵcmp = i0.ɵɵngDeclareComponent({
313
+ minVersion: "17.0.0",
314
+ version: "22.2.1",
315
+ type: FilterBarComponent,
316
+ isStandalone: true,
317
+ selector: "filter-bar",
318
+ inputs: {
319
+ filters: {
320
+ classPropertyName: "filters",
321
+ publicName: "filters",
322
+ isSignal: true,
323
+ isRequired: false,
324
+ transformFunction: null
325
+ },
326
+ canFilterByText: {
327
+ classPropertyName: "canFilterByText",
328
+ publicName: "canFilterByText",
329
+ isSignal: true,
330
+ isRequired: false,
331
+ transformFunction: null
332
+ },
333
+ canFilterByText2: {
334
+ classPropertyName: "canFilterByText2",
335
+ publicName: "canFilterByText2",
336
+ isSignal: true,
337
+ isRequired: false,
338
+ transformFunction: null
339
+ },
340
+ canFilterByText3: {
341
+ classPropertyName: "canFilterByText3",
342
+ publicName: "canFilterByText3",
343
+ isSignal: true,
344
+ isRequired: false,
345
+ transformFunction: null
346
+ },
347
+ initialText: {
348
+ classPropertyName: "initialText",
349
+ publicName: "initialText",
350
+ isSignal: true,
351
+ isRequired: false,
352
+ transformFunction: null
353
+ },
354
+ initialText2: {
355
+ classPropertyName: "initialText2",
356
+ publicName: "initialText2",
357
+ isSignal: true,
358
+ isRequired: false,
359
+ transformFunction: null
360
+ },
361
+ initialText3: {
362
+ classPropertyName: "initialText3",
363
+ publicName: "initialText3",
364
+ isSignal: true,
365
+ isRequired: false,
366
+ transformFunction: null
367
+ },
368
+ textName: {
369
+ classPropertyName: "textName",
370
+ publicName: "textName",
371
+ isSignal: true,
372
+ isRequired: false,
373
+ transformFunction: null
374
+ },
375
+ text2Name: {
376
+ classPropertyName: "text2Name",
377
+ publicName: "text2Name",
378
+ isSignal: true,
379
+ isRequired: false,
380
+ transformFunction: null
381
+ },
382
+ text3Name: {
383
+ classPropertyName: "text3Name",
384
+ publicName: "text3Name",
385
+ isSignal: true,
386
+ isRequired: false,
387
+ transformFunction: null
388
+ },
389
+ textLength: {
390
+ classPropertyName: "textLength",
391
+ publicName: "textLength",
392
+ isSignal: true,
393
+ isRequired: false,
394
+ transformFunction: null
395
+ },
396
+ text2Length: {
397
+ classPropertyName: "text2Length",
398
+ publicName: "text2Length",
399
+ isSignal: true,
400
+ isRequired: false,
401
+ transformFunction: null
402
+ },
403
+ text3Length: {
404
+ classPropertyName: "text3Length",
405
+ publicName: "text3Length",
406
+ isSignal: true,
407
+ isRequired: false,
408
+ transformFunction: null
409
+ },
410
+ showTextSearchButton: {
411
+ classPropertyName: "showTextSearchButton",
412
+ publicName: "showTextSearchButton",
413
+ isSignal: true,
414
+ isRequired: false,
415
+ transformFunction: null
416
+ },
417
+ appearance: {
418
+ classPropertyName: "appearance",
419
+ publicName: "appearance",
420
+ isSignal: true,
421
+ isRequired: false,
422
+ transformFunction: null
423
+ }
424
+ },
425
+ outputs: { changed: "changed" },
426
+ ngImport: i0,
427
+ template: "<div fxLayout=\"row\" fxLayoutAlign=\"start center\" class=\"filterbox\"\n [class.filterbox-filtered]=\"currentFilter.filtered()\">\n <div fxFlex=\"*\" fxLayout=\"row wrap\" fxLayoutAlign=\"space-between\">\n @if (canFilterByText() || canFilterByText2() || canFilterByText3()) {\n <div fxFlex.lt-sm=\"100\" fxFlexAlign=\"center\">\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill style=\"padding:4px;\">\n @if (canFilterByText()) {\n <mat-form-field [style.width]=\"textLength() ?? '100%'\" [appearance]=\"appearance()\" subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{textName()}}...</mat-label>\n <input matInput [formField]=\"textForm\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n @if (showTextSearchButton()) {\n <button type=\"button\" matSuffix mat-icon-button aria-label=\"Trova\" (click)=\"applyTextFilter();\"\n matTooltip=\"Trova\">\n <mat-icon>search</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText2()) {\n <mat-form-field \n [style.width]=\"text2Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text2Name()}}...</mat-label>\n <input matInput [formField]=\"text2Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text2()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text2.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText3()) {\n <mat-form-field [style.width]=\"text3Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text3Name()}}...</mat-label>\n <input matInput [formField]=\"text3Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text3()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text3.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n </div>\n </div>\n }\n <div fxFlex.lt-sm=\"100\">\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\n @if (canFilterByFlt1() && flt1()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" \n (click)=\"applyFilterAction(1, false)\">\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt1) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(1, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt1() && flt1()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt1\"\n >\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt1=\"matMenu\">\n @for (f of flt1()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt1()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt2() && flt2()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" \n (click)=\"applyFilterAction(2, false)\">\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt2) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(2, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt2() && flt2()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt2\"\n >\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt2=\"matMenu\">\n @for (f of flt2()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt2()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt3() && flt3()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" \n (click)=\"applyFilterAction(3, false)\">\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt3) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(3, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt3() && flt3()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt3\"\n >\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt3=\"matMenu\">\n @for (f of flt3()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt3()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt4() && flt4()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" \n (click)=\"applyFilterAction(4, false)\">\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt4) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(4, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt4() && flt4()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt4\"\n >\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt4=\"matMenu\">\n @for (f of flt4()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt4()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt5() && flt5()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" \n (click)=\"applyFilterAction(5, false)\">\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt5) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(5, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt5() && flt5()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt5\"\n >\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt5=\"matMenu\">\n @for (f of flt5()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt5()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n </div>\n </div>\n </div>\n <div>\n @if (currentFilter.filtered() && canClearAllFilters()) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera tutti i filtri\" aria-label=\"Azzera tutti i filtri\"\n (click)=\"clearAllFilters()\">\n <mat-icon>filter_alt_off</mat-icon>\n </button>\n }\n </div>\n</div>\n",
428
+ styles: [".fill,.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-header{padding-bottom:20px}.dialog-toolbar{padding:0 5px 0 24px;height:48px;min-height:48px}.dialog-close{margin-right:5px;margin-top:0}.dialog-menu{margin-left:10px;margin-top:10px}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}.center{text-align:center}.fill{min-height:100%!important;max-height:100%!important;height:100%!important}.scroll-auto{overflow:auto;height:100%}.scroll-hidden{overflow:hidden;height:100%}b{font-weight:700}.large{font-size:large!important;line-height:1.2!important}.smaller{font-size:smaller!important;line-height:1.2!important}.small{font-size:small!important;line-height:1.2!important}.small-icon-button{width:1.5rem!important;height:1.5rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.small-icon-button .mat-mdc-button-touch-target{width:1.5rem!important;height:1.5rem!important}.x-small{font-size:x-small!important;line-height:1.2!important}.bold{font-weight:700}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0;max-width:100%}@supports (-webkit-line-clamp: 2){.truncated{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@supports (-webkit-line-clamp: 2){.truncated span,.truncated div{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.clipped{min-width:0;max-width:100%}.clipped span,.clipped div{white-space:nowrap;overflow:hidden;text-overflow:clip}.accent{color:var(--ars-color-accent, #7894ae)!important}.primary{color:var(--ars-color-primary, #00a293)!important}.secondary{color:var(--ars-color-secondary, #4a635f)!important}.error{color:var(--ars-color-error, #ff5449)!important}.success{color:var(--ars-color-ok, #388E3C)!important}.warning{color:var(--ars-color-warning, #FFC107)!important}.text{color:var(--ars-color-text, #191c1b)!important}.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:10;background-color:var(--ars-color-overlay, rgba(255, 255, 255, .75))}.drawer-content{padding-top:10px}.drawer .title-container,.drawer .title-container-with-loader,.drawer-small .title-container,.drawer-small .title-container-with-loader{padding-right:5px;padding-bottom:20px;padding-left:0}.drawer .title-container,.drawer-small .title-container{padding-top:20px}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding-top:14px}.drawer .title,.drawer-small .title{font-size:19.2px!important;font-weight:600;padding-left:15px;min-width:150px;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.drawer .accordion-panel,.drawer-small .accordion-panel{background-color:transparent!important}.drawer .accordion-header,.drawer-small .accordion-header{padding-left:10px;padding-right:10px;border-radius:var(--mat-expansion-container-shape)}.drawer .mat-expansion-panel-body,.drawer-small .mat-expansion-panel-body{padding-left:10px!important;padding-right:10px!important;padding-bottom:20px!important}@media screen and (min-width:0px)and (max-width:430px){.drawer,.drawer-small{border-radius:0!important;min-width:100%!important;max-width:100%!important}}@media screen and (min-width:431px){.drawer{min-width:420px!important;max-width:420px!important}.drawer .title{min-width:200px}.drawer .mat-expansion-panel-body{padding-left:15px!important;padding-right:15px!important;padding-bottom:20px!important}.drawer-small{min-width:360px!important;max-width:360px!important}}.drawer-with-loader{padding-top:0!important}.drawer-transparent{background-color:transparent}.fade-in{animation:fadein .5s linear}@keyframes fadein{0%{opacity:0}to{opacity:1}}.bright{filter:brightness(.7)!important}@media(prefers-color-scheme:dark){.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b,.bold{font-weight:600}.bright{filter:brightness(1.5)!important}}.filterbox{border-radius:auto;background-color:transparent;padding:4px}.filterbox-button{max-width:200px;white-space:normal;text-align:center;display:-webkit-box;display:inline-block;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical;text-overflow:ellipsis}.filterbox-selected{font-weight:800!important}.filterbox-filtered{border-radius:12px;background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}@media(prefers-color-scheme:dark){.filterbox-filtered{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}}\n"],
429
+ dependencies: [
430
+ {
431
+ kind: "ngmodule",
432
+ type: FlexLayoutModule
433
+ },
434
+ {
435
+ kind: "directive",
436
+ type: i1.FxLayoutDirective,
437
+ selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg] ",
438
+ inputs: [
439
+ "fxLayout",
440
+ "fxLayout.xs",
441
+ "fxLayout.sm",
442
+ "fxLayout.md",
443
+ "fxLayout.lg",
444
+ "fxLayout.xl",
445
+ "fxLayout.lt-sm",
446
+ "fxLayout.lt-md",
447
+ "fxLayout.lt-lg",
448
+ "fxLayout.lt-xl",
449
+ "fxLayout.gt-xs",
450
+ "fxLayout.gt-sm",
451
+ "fxLayout.gt-md",
452
+ "fxLayout.gt-lg"
453
+ ]
454
+ },
455
+ {
456
+ kind: "directive",
457
+ type: i1.FxFlexDirective,
458
+ selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg] ",
459
+ inputs: [
460
+ "fxFlex",
461
+ "fxFlex.xs",
462
+ "fxFlex.sm",
463
+ "fxFlex.md",
464
+ "fxFlex.lg",
465
+ "fxFlex.xl",
466
+ "fxFlex.lt-sm",
467
+ "fxFlex.lt-md",
468
+ "fxFlex.lt-lg",
469
+ "fxFlex.lt-xl",
470
+ "fxFlex.gt-xs",
471
+ "fxFlex.gt-sm",
472
+ "fxFlex.gt-md",
473
+ "fxFlex.gt-lg"
474
+ ]
475
+ },
476
+ {
477
+ kind: "directive",
478
+ type: i1.FxLayoutAlignDirective,
479
+ selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg] ",
480
+ inputs: [
481
+ "fxLayoutAlign",
482
+ "fxLayoutAlign.xs",
483
+ "fxLayoutAlign.sm",
484
+ "fxLayoutAlign.md",
485
+ "fxLayoutAlign.lg",
486
+ "fxLayoutAlign.xl",
487
+ "fxLayoutAlign.lt-sm",
488
+ "fxLayoutAlign.lt-md",
489
+ "fxLayoutAlign.lt-lg",
490
+ "fxLayoutAlign.lt-xl",
491
+ "fxLayoutAlign.gt-xs",
492
+ "fxLayoutAlign.gt-sm",
493
+ "fxLayoutAlign.gt-md",
494
+ "fxLayoutAlign.gt-lg"
495
+ ]
496
+ },
497
+ {
498
+ kind: "directive",
499
+ type: i1.FxLayoutGapDirective,
500
+ selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg] ",
501
+ inputs: [
502
+ "fxLayoutGap",
503
+ "fxLayoutGap.xs",
504
+ "fxLayoutGap.sm",
505
+ "fxLayoutGap.md",
506
+ "fxLayoutGap.lg",
507
+ "fxLayoutGap.xl",
508
+ "fxLayoutGap.lt-sm",
509
+ "fxLayoutGap.lt-md",
510
+ "fxLayoutGap.lt-lg",
511
+ "fxLayoutGap.lt-xl",
512
+ "fxLayoutGap.gt-xs",
513
+ "fxLayoutGap.gt-sm",
514
+ "fxLayoutGap.gt-md",
515
+ "fxLayoutGap.gt-lg"
516
+ ]
517
+ },
518
+ {
519
+ kind: "directive",
520
+ type: i1.FxFlexAlignDirective,
521
+ selector: " [fxFlexAlign], [fxFlexAlign.xs], [fxFlexAlign.sm], [fxFlexAlign.md], [fxFlexAlign.lg], [fxFlexAlign.xl], [fxFlexAlign.lt-sm], [fxFlexAlign.lt-md], [fxFlexAlign.lt-lg], [fxFlexAlign.lt-xl], [fxFlexAlign.gt-xs], [fxFlexAlign.gt-sm], [fxFlexAlign.gt-md], [fxFlexAlign.gt-lg] ",
522
+ inputs: [
523
+ "fxFlexAlign",
524
+ "fxFlexAlign.xs",
525
+ "fxFlexAlign.sm",
526
+ "fxFlexAlign.md",
527
+ "fxFlexAlign.lg",
528
+ "fxFlexAlign.xl",
529
+ "fxFlexAlign.lt-sm",
530
+ "fxFlexAlign.lt-md",
531
+ "fxFlexAlign.lt-lg",
532
+ "fxFlexAlign.lt-xl",
533
+ "fxFlexAlign.gt-xs",
534
+ "fxFlexAlign.gt-sm",
535
+ "fxFlexAlign.gt-md",
536
+ "fxFlexAlign.gt-lg"
537
+ ]
538
+ },
539
+ {
540
+ kind: "directive",
541
+ type: i1.FxFlexFillDirective,
542
+ selector: " [fxFlexFill], [fxFill], [fxFlexFill.xs], [fxFlexFill.sm], [fxFlexFill.md], [fxFlexFill.lg], [fxFlexFill.xl], [fxFlexFill.lt-sm], [fxFlexFill.lt-md], [fxFlexFill.lt-lg], [fxFlexFill.lt-xl], [fxFlexFill.gt-xs], [fxFlexFill.gt-sm], [fxFlexFill.gt-md], [fxFlexFill.gt-lg] ",
543
+ inputs: [
544
+ "fxFlexFill",
545
+ "fxFill",
546
+ "fxFlexFill.xs",
547
+ "fxFlexFill.sm",
548
+ "fxFlexFill.md",
549
+ "fxFlexFill.lg",
550
+ "fxFlexFill.xl",
551
+ "fxFlexFill.lt-sm",
552
+ "fxFlexFill.lt-md",
553
+ "fxFlexFill.lt-lg",
554
+ "fxFlexFill.lt-xl",
555
+ "fxFlexFill.gt-xs",
556
+ "fxFlexFill.gt-sm",
557
+ "fxFlexFill.gt-md",
558
+ "fxFlexFill.gt-lg"
559
+ ]
560
+ },
561
+ {
562
+ kind: "ngmodule",
563
+ type: MatFormFieldModule
564
+ },
565
+ {
566
+ kind: "component",
567
+ type: i2.MatFormField,
568
+ selector: "mat-form-field",
569
+ inputs: [
570
+ "hideRequiredMarker",
571
+ "color",
572
+ "floatLabel",
573
+ "appearance",
574
+ "subscriptSizing",
575
+ "hintLabel"
576
+ ],
577
+ exportAs: ["matFormField"]
578
+ },
579
+ {
580
+ kind: "directive",
581
+ type: i2.MatLabel,
582
+ selector: "mat-label"
583
+ },
584
+ {
585
+ kind: "directive",
586
+ type: i2.MatSuffix,
587
+ selector: "[matSuffix], [matIconSuffix], [matTextSuffix]",
588
+ inputs: ["matTextSuffix"]
589
+ },
590
+ {
591
+ kind: "ngmodule",
592
+ type: MatInputModule
593
+ },
594
+ {
595
+ kind: "directive",
596
+ type: i3.MatInput,
597
+ selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]",
598
+ inputs: [
599
+ "disabled",
600
+ "id",
601
+ "placeholder",
602
+ "name",
603
+ "required",
604
+ "type",
605
+ "errorStateMatcher",
606
+ "aria-describedby",
607
+ "value",
608
+ "readonly",
609
+ "disabledInteractive"
610
+ ],
611
+ exportAs: ["matInput"]
612
+ },
613
+ {
614
+ kind: "directive",
615
+ type: FormField,
616
+ selector: "[formField]",
617
+ inputs: ["formField"],
618
+ exportAs: ["formField"]
619
+ },
620
+ {
621
+ kind: "ngmodule",
622
+ type: MatTooltipModule
623
+ },
624
+ {
625
+ kind: "directive",
626
+ type: i4.MatTooltip,
627
+ selector: "[matTooltip]",
628
+ inputs: [
629
+ "matTooltipPosition",
630
+ "matTooltipPositionAtOrigin",
631
+ "matTooltipDisabled",
632
+ "matTooltipShowDelay",
633
+ "matTooltipHideDelay",
634
+ "matTooltipTouchGestures",
635
+ "matTooltip",
636
+ "matTooltipClass"
637
+ ],
638
+ exportAs: ["matTooltip"]
639
+ },
640
+ {
641
+ kind: "ngmodule",
642
+ type: MatButtonModule
643
+ },
644
+ {
645
+ kind: "component",
646
+ type: i5.MatButton,
647
+ selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ",
648
+ inputs: ["matButton"],
649
+ exportAs: ["matButton", "matAnchor"]
650
+ },
651
+ {
652
+ kind: "component",
653
+ type: i5.MatIconButton,
654
+ selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]",
655
+ exportAs: ["matButton", "matAnchor"]
656
+ },
657
+ {
658
+ kind: "ngmodule",
659
+ type: MatIconModule
660
+ },
661
+ {
662
+ kind: "component",
663
+ type: i6.MatIcon,
664
+ selector: "mat-icon",
665
+ inputs: [
666
+ "color",
667
+ "inline",
668
+ "svgIcon",
669
+ "fontSet",
670
+ "fontIcon"
671
+ ],
672
+ exportAs: ["matIcon"]
673
+ },
674
+ {
675
+ kind: "ngmodule",
676
+ type: MatMenuModule
677
+ },
678
+ {
679
+ kind: "component",
680
+ type: i7.MatMenu,
681
+ selector: "mat-menu",
682
+ inputs: [
683
+ "backdropClass",
684
+ "aria-label",
685
+ "aria-labelledby",
686
+ "aria-describedby",
687
+ "xPosition",
688
+ "yPosition",
689
+ "overlapTrigger",
690
+ "hasBackdrop",
691
+ "class",
692
+ "classList"
693
+ ],
694
+ outputs: ["closed", "close"],
695
+ exportAs: ["matMenu"]
696
+ },
697
+ {
698
+ kind: "component",
699
+ type: i7.MatMenuItem,
700
+ selector: "[mat-menu-item]",
701
+ inputs: [
702
+ "role",
703
+ "disabled",
704
+ "disabledInteractive",
705
+ "disableRipple"
706
+ ],
707
+ exportAs: ["matMenuItem"]
708
+ },
709
+ {
710
+ kind: "directive",
711
+ type: i7.MatMenuTrigger,
712
+ selector: "[mat-menu-trigger-for], [matMenuTriggerFor]",
713
+ inputs: [
714
+ "mat-menu-trigger-for",
715
+ "matMenuTriggerFor",
716
+ "matMenuTriggerData",
717
+ "matMenuTriggerRestoreFocus"
718
+ ],
719
+ outputs: [
720
+ "menuOpened",
721
+ "onMenuOpen",
722
+ "menuClosed",
723
+ "onMenuClose"
724
+ ],
725
+ exportAs: ["matMenuTrigger"]
726
+ },
727
+ {
728
+ kind: "ngmodule",
729
+ type: MatDividerModule
730
+ },
731
+ {
732
+ kind: "component",
733
+ type: i8.MatDivider,
734
+ selector: "mat-divider",
735
+ inputs: ["vertical", "inset"]
736
+ },
737
+ {
738
+ kind: "pipe",
739
+ type: SafeHtmlPipe,
740
+ name: "safeHtml"
741
+ }
742
+ ],
743
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
744
+ });
745
+ }
746
+ };
747
+ i0.ɵɵngDeclareClassMetadata({
748
+ minVersion: "12.0.0",
749
+ version: "22.2.1",
750
+ ngImport: i0,
751
+ type: FilterBarComponent,
752
+ decorators: [{
753
+ type: Component,
754
+ args: [{
755
+ selector: "filter-bar",
756
+ standalone: true,
757
+ changeDetection: ChangeDetectionStrategy.OnPush,
758
+ imports: [
759
+ FlexLayoutModule,
760
+ MatFormFieldModule,
761
+ MatInputModule,
762
+ FormField,
763
+ MatTooltipModule,
764
+ MatButtonModule,
765
+ MatIconModule,
766
+ MatMenuModule,
767
+ MatDividerModule,
768
+ SafeHtmlPipe
769
+ ],
770
+ template: "<div fxLayout=\"row\" fxLayoutAlign=\"start center\" class=\"filterbox\"\n [class.filterbox-filtered]=\"currentFilter.filtered()\">\n <div fxFlex=\"*\" fxLayout=\"row wrap\" fxLayoutAlign=\"space-between\">\n @if (canFilterByText() || canFilterByText2() || canFilterByText3()) {\n <div fxFlex.lt-sm=\"100\" fxFlexAlign=\"center\">\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill style=\"padding:4px;\">\n @if (canFilterByText()) {\n <mat-form-field [style.width]=\"textLength() ?? '100%'\" [appearance]=\"appearance()\" subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{textName()}}...</mat-label>\n <input matInput [formField]=\"textForm\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n @if (showTextSearchButton()) {\n <button type=\"button\" matSuffix mat-icon-button aria-label=\"Trova\" (click)=\"applyTextFilter();\"\n matTooltip=\"Trova\">\n <mat-icon>search</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText2()) {\n <mat-form-field \n [style.width]=\"text2Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text2Name()}}...</mat-label>\n <input matInput [formField]=\"text2Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text2()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text2.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n @if (canFilterByText3()) {\n <mat-form-field [style.width]=\"text3Length() ?? '100%'\" [appearance]=\"appearance()\"\n subscriptSizing=\"dynamic\">\n <mat-label>Cerca per {{text3Name()}}...</mat-label>\n <input matInput [formField]=\"text3Form\"\n (keyup.enter)=\"applyTextFilter()\" matTooltip=\"Premi INVIO per avviare la ricerca\">\n @if (text3()) {\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\n (click)=\"text3.set(''); applyTextFilter();\" matTooltip=\"Azzera\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </mat-form-field>\n }\n </div>\n </div>\n }\n <div fxFlex.lt-sm=\"100\">\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\n @if (canFilterByFlt1() && flt1()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" \n (click)=\"applyFilterAction(1, false)\">\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt1) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(1, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt1() && flt1()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\"\n [attr.aria-label]=\"flt1()!.tooltip || 'Filtra per ' + flt1()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt1\"\n >\n &nbsp;\n @if (!currentFilter.flt1) {\n <span>{{flt1()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt1Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt1=\"matMenu\">\n @for (f of flt1()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt1()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt2() && flt2()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" \n (click)=\"applyFilterAction(2, false)\">\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt2) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(2, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt2() && flt2()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\"\n [attr.aria-label]=\"flt2()!.tooltip || 'Filtra per ' + flt2()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt2\"\n >\n &nbsp;\n @if (!currentFilter.flt2) {\n <span>{{flt2()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt2Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt2=\"matMenu\">\n @for (f of flt2()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt2()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt3() && flt3()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" \n (click)=\"applyFilterAction(3, false)\">\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt3) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(3, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt3() && flt3()?.items) {\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\"\n [attr.aria-label]=\"flt3()!.tooltip || 'Filtra per ' + flt3()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt3\"\n >\n &nbsp;\n @if (!currentFilter.flt3) {\n <span>{{flt3()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt3Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt3=\"matMenu\">\n @for (f of flt3()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt3()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt4() && flt4()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" \n (click)=\"applyFilterAction(4, false)\">\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt4) {\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(4, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt4() && flt4()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\"\n [attr.aria-label]=\"flt4()!.tooltip || 'Filtra per ' + flt4()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt4\"\n >\n &nbsp;\n @if (!currentFilter.flt4) {\n <span>{{flt4()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt4Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt4=\"matMenu\">\n @for (f of flt4()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt4()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n\n @if (canFilterByFlt5() && flt5()?.action) {\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <button type=\"button\" class=\"filterbox-button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" \n (click)=\"applyFilterAction(5, false)\">\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n </button>\n @if (currentFilter.flt5) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera\" aria-label=\"Azzera\"\n (click)=\"applyFilterAction(5, true);\" class=\"small-icon-button\">\n <mat-icon>clear</mat-icon>\n </button>\n }\n </div>\n } @else if (canFilterByFlt5() && flt5()?.items) {\n <button fxFlexAlign=\"center\" class=\"filterbox-button\" type=\"button\" mat-button [matTooltip]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\"\n [attr.aria-label]=\"flt5()!.tooltip || 'Filtra per ' + flt5()!.title\" [matMenuTriggerFor]=\"menuApplyFilterFlt5\"\n >\n &nbsp;\n @if (!currentFilter.flt5) {\n <span>{{flt5()!.title}}</span>\n } @else {\n <span class=\"filterbox-selected\" [innerHtml]=\"currentFilter.flt5Name | safeHtml\"></span>\n }\n <mat-icon class=\"icon-menu-drop-down\">expand_more</mat-icon>\n <mat-menu #menuApplyFilterFlt5=\"matMenu\">\n @for (f of flt5()!.items; track $index) {\n @if (f.divider) {\n <mat-divider></mat-divider>\n }\n <button mat-menu-item (click)=\"applyFilter(f)\" [attr.aria-label]=\"f.description\" style=\"min-width: 200px\">\n <span [innerHTML]=\"f.title | safeHtml\"></span>\n </button>\n }\n <mat-divider></mat-divider>\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill>\n <div fxLayoutAlign=\"end\" style=\"width: 100%; min-width: 200px; padding: 4px 4px 0 4px;\">\n <button type=\"button\" mat-button (click)=\"clearFilter(flt5()!.items![0].group)\"\n aria-label=\"Azzera\">\n <mat-icon style=\"font-size:18px; height: 18px; width:18px;\">clear</mat-icon> Azzera\n </button>\n </div>\n </div>\n </mat-menu>\n </button>\n }\n </div>\n </div>\n </div>\n <div>\n @if (currentFilter.filtered() && canClearAllFilters()) {\n <button type=\"button\" mat-icon-button matTooltip=\"Azzera tutti i filtri\" aria-label=\"Azzera tutti i filtri\"\n (click)=\"clearAllFilters()\">\n <mat-icon>filter_alt_off</mat-icon>\n </button>\n }\n </div>\n</div>\n",
771
+ styles: [".fill,.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-header{padding-bottom:20px}.dialog-toolbar{padding:0 5px 0 24px;height:48px;min-height:48px}.dialog-close{margin-right:5px;margin-top:0}.dialog-menu{margin-left:10px;margin-top:10px}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}.center{text-align:center}.fill{min-height:100%!important;max-height:100%!important;height:100%!important}.scroll-auto{overflow:auto;height:100%}.scroll-hidden{overflow:hidden;height:100%}b{font-weight:700}.large{font-size:large!important;line-height:1.2!important}.smaller{font-size:smaller!important;line-height:1.2!important}.small{font-size:small!important;line-height:1.2!important}.small-icon-button{width:1.5rem!important;height:1.5rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.small-icon-button .mat-mdc-button-touch-target{width:1.5rem!important;height:1.5rem!important}.x-small{font-size:x-small!important;line-height:1.2!important}.bold{font-weight:700}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0;max-width:100%}@supports (-webkit-line-clamp: 2){.truncated{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@supports (-webkit-line-clamp: 2){.truncated span,.truncated div{overflow:hidden;text-overflow:ellipsis;white-space:initial;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.clipped{min-width:0;max-width:100%}.clipped span,.clipped div{white-space:nowrap;overflow:hidden;text-overflow:clip}.accent{color:var(--ars-color-accent, #7894ae)!important}.primary{color:var(--ars-color-primary, #00a293)!important}.secondary{color:var(--ars-color-secondary, #4a635f)!important}.error{color:var(--ars-color-error, #ff5449)!important}.success{color:var(--ars-color-ok, #388E3C)!important}.warning{color:var(--ars-color-warning, #FFC107)!important}.text{color:var(--ars-color-text, #191c1b)!important}.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:10;background-color:var(--ars-color-overlay, rgba(255, 255, 255, .75))}.drawer-content{padding-top:10px}.drawer .title-container,.drawer .title-container-with-loader,.drawer-small .title-container,.drawer-small .title-container-with-loader{padding-right:5px;padding-bottom:20px;padding-left:0}.drawer .title-container,.drawer-small .title-container{padding-top:20px}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding-top:14px}.drawer .title,.drawer-small .title{font-size:19.2px!important;font-weight:600;padding-left:15px;min-width:150px;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.drawer .accordion-panel,.drawer-small .accordion-panel{background-color:transparent!important}.drawer .accordion-header,.drawer-small .accordion-header{padding-left:10px;padding-right:10px;border-radius:var(--mat-expansion-container-shape)}.drawer .mat-expansion-panel-body,.drawer-small .mat-expansion-panel-body{padding-left:10px!important;padding-right:10px!important;padding-bottom:20px!important}@media screen and (min-width:0px)and (max-width:430px){.drawer,.drawer-small{border-radius:0!important;min-width:100%!important;max-width:100%!important}}@media screen and (min-width:431px){.drawer{min-width:420px!important;max-width:420px!important}.drawer .title{min-width:200px}.drawer .mat-expansion-panel-body{padding-left:15px!important;padding-right:15px!important;padding-bottom:20px!important}.drawer-small{min-width:360px!important;max-width:360px!important}}.drawer-with-loader{padding-top:0!important}.drawer-transparent{background-color:transparent}.fade-in{animation:fadein .5s linear}@keyframes fadein{0%{opacity:0}to{opacity:1}}.bright{filter:brightness(.7)!important}@media(prefers-color-scheme:dark){.dialog-info-green,.dialog-info-ok{color:var(--ars-color-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b,.bold{font-weight:600}.bright{filter:brightness(1.5)!important}}.filterbox{border-radius:auto;background-color:transparent;padding:4px}.filterbox-button{max-width:200px;white-space:normal;text-align:center;display:-webkit-box;display:inline-block;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical;text-overflow:ellipsis}.filterbox-selected{font-weight:800!important}.filterbox-filtered{border-radius:12px;background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}@media(prefers-color-scheme:dark){.filterbox-filtered{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7)}}\n"]
772
+ }]
773
+ }],
774
+ ctorParameters: () => [],
775
+ propDecorators: {
776
+ changed: [{
777
+ type: i0.Output,
778
+ args: ["changed"]
779
+ }],
780
+ filters: [{
781
+ type: i0.Input,
782
+ args: [{
783
+ isSignal: true,
784
+ alias: "filters",
785
+ required: false
786
+ }]
787
+ }],
788
+ canFilterByText: [{
789
+ type: i0.Input,
790
+ args: [{
791
+ isSignal: true,
792
+ alias: "canFilterByText",
793
+ required: false
794
+ }]
795
+ }],
796
+ canFilterByText2: [{
797
+ type: i0.Input,
798
+ args: [{
799
+ isSignal: true,
800
+ alias: "canFilterByText2",
801
+ required: false
802
+ }]
803
+ }],
804
+ canFilterByText3: [{
805
+ type: i0.Input,
806
+ args: [{
807
+ isSignal: true,
808
+ alias: "canFilterByText3",
809
+ required: false
810
+ }]
811
+ }],
812
+ initialText: [{
813
+ type: i0.Input,
814
+ args: [{
815
+ isSignal: true,
816
+ alias: "initialText",
817
+ required: false
818
+ }]
819
+ }],
820
+ initialText2: [{
821
+ type: i0.Input,
822
+ args: [{
823
+ isSignal: true,
824
+ alias: "initialText2",
825
+ required: false
826
+ }]
827
+ }],
828
+ initialText3: [{
829
+ type: i0.Input,
830
+ args: [{
831
+ isSignal: true,
832
+ alias: "initialText3",
833
+ required: false
834
+ }]
835
+ }],
836
+ textName: [{
837
+ type: i0.Input,
838
+ args: [{
839
+ isSignal: true,
840
+ alias: "textName",
841
+ required: false
842
+ }]
843
+ }],
844
+ text2Name: [{
845
+ type: i0.Input,
846
+ args: [{
847
+ isSignal: true,
848
+ alias: "text2Name",
849
+ required: false
850
+ }]
851
+ }],
852
+ text3Name: [{
853
+ type: i0.Input,
854
+ args: [{
855
+ isSignal: true,
856
+ alias: "text3Name",
857
+ required: false
858
+ }]
859
+ }],
860
+ textLength: [{
861
+ type: i0.Input,
862
+ args: [{
863
+ isSignal: true,
864
+ alias: "textLength",
865
+ required: false
866
+ }]
867
+ }],
868
+ text2Length: [{
869
+ type: i0.Input,
870
+ args: [{
871
+ isSignal: true,
872
+ alias: "text2Length",
873
+ required: false
874
+ }]
875
+ }],
876
+ text3Length: [{
877
+ type: i0.Input,
878
+ args: [{
879
+ isSignal: true,
880
+ alias: "text3Length",
881
+ required: false
882
+ }]
883
+ }],
884
+ showTextSearchButton: [{
885
+ type: i0.Input,
886
+ args: [{
887
+ isSignal: true,
888
+ alias: "showTextSearchButton",
889
+ required: false
890
+ }]
891
+ }],
892
+ appearance: [{
893
+ type: i0.Input,
894
+ args: [{
895
+ isSignal: true,
896
+ alias: "appearance",
897
+ required: false
898
+ }]
899
+ }]
900
+ }
901
+ });
432
902
  export { CurrentFilter, CurrentFilterChanged, CurrentFilterItem, FilterBarComponent, Filters };
433
- //# sourceMappingURL=arsedizioni-ars-utils-ui.filters.mjs.map
903
+
904
+ //# sourceMappingURL=arsedizioni-ars-utils-ui.filters.mjs.map