@arsedizioni/ars-utils 18.1.62 → 18.1.64
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/core/definitions.d.ts +7 -7
- package/esm2022/clipper.ui/ui/browser-dialog/browser-dialog.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/document/document.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/last-15-days/last-15-days.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/references/references.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/search-dialog/search-dialog.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/search-facets/search-facets.component.mjs +3 -3
- package/esm2022/clipper.ui/ui/search-result-item/search-result-item.component.mjs +3 -3
- package/esm2022/core/definitions.mjs +1 -1
- package/esm2022/help/components/help-viewer/help-viewer.component.mjs +3 -3
- package/esm2022/support.common/common/interceptors/auth.interceptor.mjs +15 -15
- package/esm2022/support.common/common/services/support.service.mjs +30 -29
- package/esm2022/support.common/common/support.mjs +1 -1
- package/esm2022/support.ui/ui/notifications-browser/notification/notification.component.mjs +46 -51
- package/esm2022/support.ui/ui/notifications-browser/notifications-browser.component.mjs +73 -74
- package/esm2022/tinymce/full-screen-editor/full-screen-editor.component.mjs +24 -24
- package/esm2022/ui/ui/definitions.mjs +1 -1
- package/esm2022/ui/ui/dialogs/busy/busy-dialog.component.mjs +3 -3
- package/esm2022/ui/ui/dialogs/confirm/confirm-dialog.component.mjs +3 -3
- package/esm2022/ui/ui/dialogs/credentials/credentials-dialog.component.mjs +3 -3
- package/esm2022/ui/ui/dialogs/info/info-dialog.component.mjs +3 -3
- package/esm2022/ui/ui/dialogs/recover-password/recover-password-dialog.component.mjs +3 -3
- package/esm2022/ui/ui/dialogs/reset-password/reset-password-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/components/filter-bar/filter-bar.component.mjs +3 -3
- package/esm2022/ui.application/ui/definitions.mjs +1 -1
- package/esm2022/ui.application/ui/dialogs/prompt/prompt-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/prompt-date/prompt-date-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/prompt-time/prompt-time-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/select/select-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/select-file/select-file-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/select-picture/select-picture-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/select-tree/select-tree-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/dialogs/send-to/send-to-dialog.component.mjs +3 -3
- package/esm2022/ui.application/ui/filters.mjs +2 -1
- package/fesm2022/arsedizioni-ars-utils-clipper.ui.mjs +14 -14
- package/fesm2022/arsedizioni-ars-utils-clipper.ui.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-core.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-help.mjs +2 -2
- package/fesm2022/arsedizioni-ars-utils-help.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-support.common.mjs +41 -40
- package/fesm2022/arsedizioni-ars-utils-support.common.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-support.ui.mjs +108 -112
- package/fesm2022/arsedizioni-ars-utils-support.ui.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-tinymce.mjs +23 -23
- package/fesm2022/arsedizioni-ars-utils-tinymce.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-ui.application.mjs +19 -18
- package/fesm2022/arsedizioni-ars-utils-ui.application.mjs.map +1 -1
- package/fesm2022/arsedizioni-ars-utils-ui.mjs +12 -12
- package/fesm2022/arsedizioni-ars-utils-ui.mjs.map +1 -1
- package/package.json +7 -7
- package/styles/ui.scss +36 -4
- package/support.common/common/interceptors/auth.interceptor.d.ts +2 -5
- package/support.common/common/services/support.service.d.ts +4 -6
- package/support.common/common/support.d.ts +6 -6
- package/support.ui/ui/notifications-browser/notification/notification.component.d.ts +13 -12
- package/support.ui/ui/notifications-browser/notifications-browser.component.d.ts +19 -23
- package/tinymce/full-screen-editor/full-screen-editor.component.d.ts +11 -11
- package/ui/ui/definitions.d.ts +3 -3
- package/ui.application/ui/definitions.d.ts +10 -10
- package/ui.application/ui/dialogs/send-to/send-to-dialog.component.d.ts +5 -5
- package/ui.application/ui/filters.d.ts +17 -17
|
@@ -1,53 +1,55 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
3
|
-
import * as
|
|
2
|
+
import { inject, ChangeDetectorRef, signal, Component, ChangeDetectionStrategy, ViewChild } from '@angular/core';
|
|
3
|
+
import * as i5 from '@angular/material/menu';
|
|
4
4
|
import { MatMenuModule } from '@angular/material/menu';
|
|
5
|
-
import * as
|
|
5
|
+
import * as i13 from '@angular/material/paginator';
|
|
6
6
|
import { MatPaginatorModule } from '@angular/material/paginator';
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
7
|
+
import { ScreenService, BroadcastService, SystemUtils, SafeHtmlPipe, SelectableModel, FormatPipe } from '@arsedizioni/ars-utils/core';
|
|
8
|
+
import { SupportService, SupportMessages } from '@arsedizioni/ars-utils/support.common';
|
|
9
|
+
import { DialogService } from '@arsedizioni/ars-utils/ui';
|
|
10
|
+
import { Subject, fromEvent, takeUntil, debounceTime } from 'rxjs';
|
|
11
11
|
import { MAT_DIALOG_DATA, MatDialogTitle, MatDialogClose, MatDialogContent, MatDialogActions } from '@angular/material/dialog';
|
|
12
12
|
import { saveAs } from 'file-saver';
|
|
13
|
-
import * as
|
|
13
|
+
import * as i4 from '@angular/material/icon';
|
|
14
14
|
import { MatIconModule } from '@angular/material/icon';
|
|
15
|
-
import * as
|
|
15
|
+
import * as i3 from '@angular/material/tooltip';
|
|
16
16
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
17
|
-
import * as
|
|
17
|
+
import * as i2 from '@angular/material/button';
|
|
18
18
|
import { MatButtonModule } from '@angular/material/button';
|
|
19
|
-
import * as
|
|
19
|
+
import * as i1 from '@ngbracket/ngx-layout/flex';
|
|
20
20
|
import { FlexModule } from '@ngbracket/ngx-layout/flex';
|
|
21
|
-
import * as
|
|
22
|
-
import * as i15 from '@angular/material/checkbox';
|
|
21
|
+
import * as i12 from '@angular/material/checkbox';
|
|
23
22
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
24
|
-
import * as
|
|
23
|
+
import * as i11 from '@ngbracket/ngx-layout/extended';
|
|
25
24
|
import { ExtendedModule } from '@ngbracket/ngx-layout/extended';
|
|
26
|
-
import * as
|
|
25
|
+
import * as i10 from '@angular/material/divider';
|
|
27
26
|
import { MatDividerModule } from '@angular/material/divider';
|
|
28
|
-
import * as
|
|
27
|
+
import * as i9 from '@angular/material/badge';
|
|
29
28
|
import { MatBadgeModule } from '@angular/material/badge';
|
|
30
29
|
import { NgClass } from '@angular/common';
|
|
31
|
-
import * as
|
|
30
|
+
import * as i7 from '@angular/forms';
|
|
32
31
|
import { FormsModule } from '@angular/forms';
|
|
33
|
-
import * as
|
|
32
|
+
import * as i6 from '@angular/material/input';
|
|
34
33
|
import { MatInputModule } from '@angular/material/input';
|
|
35
|
-
import * as
|
|
34
|
+
import * as i5$1 from '@angular/material/form-field';
|
|
36
35
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
37
36
|
|
|
38
37
|
class SupportNotificationComponent {
|
|
39
|
-
|
|
40
|
-
this.
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
this
|
|
44
|
-
this
|
|
45
|
-
this
|
|
46
|
-
this
|
|
38
|
+
constructor() {
|
|
39
|
+
this.screenService = inject(ScreenService);
|
|
40
|
+
this.supportService = inject(SupportService);
|
|
41
|
+
this.changeDetector = inject(ChangeDetectorRef);
|
|
42
|
+
this.broadcastService = inject(BroadcastService);
|
|
43
|
+
this.dialogService = inject(DialogService);
|
|
44
|
+
this.dialogData = inject(MAT_DIALOG_DATA);
|
|
45
|
+
this.height = signal(null);
|
|
47
46
|
this.id = -1;
|
|
48
|
-
this.
|
|
47
|
+
this.item = null;
|
|
49
48
|
}
|
|
50
49
|
ngOnInit() {
|
|
50
|
+
if (this.dialogData) {
|
|
51
|
+
this.id = this.dialogData.id;
|
|
52
|
+
}
|
|
51
53
|
this.fetch();
|
|
52
54
|
}
|
|
53
55
|
ngAfterViewInit() {
|
|
@@ -57,41 +59,40 @@ class SupportNotificationComponent {
|
|
|
57
59
|
* Resize dialog
|
|
58
60
|
*/
|
|
59
61
|
resize() {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
this.height = h;
|
|
67
|
-
this.resize();
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
else {
|
|
62
|
+
let elem = document.getElementById('notification-scrollable');
|
|
63
|
+
if (elem) {
|
|
64
|
+
const h = this.dialogService.getCurrentDialogScrollableHeight(['support-notification-fixed'], window.innerHeight);
|
|
65
|
+
if (h != this.height()) {
|
|
66
|
+
elem.setAttribute('style', 'height:' + h + 'px !important;max-height:' + h + 'px !important');
|
|
67
|
+
this.height.set(h);
|
|
71
68
|
this.resize();
|
|
72
69
|
}
|
|
73
|
-
}
|
|
70
|
+
}
|
|
71
|
+
else {
|
|
72
|
+
this.resize();
|
|
73
|
+
}
|
|
74
74
|
}
|
|
75
75
|
/**
|
|
76
76
|
* Retrieve data
|
|
77
77
|
*/
|
|
78
78
|
fetch() {
|
|
79
|
-
if (!this
|
|
79
|
+
if (!this.supportService.loggedIn)
|
|
80
80
|
return;
|
|
81
|
-
this
|
|
82
|
-
this
|
|
81
|
+
this.dialogService.busy('Caricamento in corso...');
|
|
82
|
+
this.supportService.getNotification(this.id)
|
|
83
83
|
.subscribe({
|
|
84
84
|
next: (r) => {
|
|
85
85
|
if (!r.success) {
|
|
86
|
-
this
|
|
86
|
+
this.dialogService.error(r.message);
|
|
87
87
|
}
|
|
88
88
|
else {
|
|
89
89
|
this.item = r.value;
|
|
90
|
-
this
|
|
90
|
+
this.broadcastService.sendMessage(SupportMessages.NOTIFICATION_READ, this.item.id);
|
|
91
|
+
this.changeDetector.markForCheck();
|
|
91
92
|
}
|
|
92
93
|
},
|
|
93
94
|
complete: () => {
|
|
94
|
-
this
|
|
95
|
+
this.dialogService.clearBusy();
|
|
95
96
|
}
|
|
96
97
|
});
|
|
97
98
|
}
|
|
@@ -100,10 +101,10 @@ class SupportNotificationComponent {
|
|
|
100
101
|
* @param item : the document item
|
|
101
102
|
*/
|
|
102
103
|
downloadDocument(item) {
|
|
103
|
-
if (!this
|
|
104
|
+
if (!this.supportService.loggedIn)
|
|
104
105
|
return;
|
|
105
106
|
if (item.isBinary) {
|
|
106
|
-
this
|
|
107
|
+
this.supportService.dowloadNotificationDocument(item.id).subscribe({
|
|
107
108
|
next: (r) => {
|
|
108
109
|
saveAs(r);
|
|
109
110
|
},
|
|
@@ -112,55 +113,55 @@ class SupportNotificationComponent {
|
|
|
112
113
|
else
|
|
113
114
|
window.open(item.url, '_blank');
|
|
114
115
|
}
|
|
115
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationComponent, deps: [
|
|
116
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SupportNotificationComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() }
|
|
116
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
117
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SupportNotificationComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() } }, ngImport: i0, template: "<div class=\"support-notification-fixed\">\r\n <div class=\"support-notification-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>{{item?.title}}</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button color=\"primary\" matTooltip=\"Chiudi\"\r\n aria-label=\"Chiudi\" [mat-dialog-close]=\"true\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n<div mat-dialog-content id=\"notification-scrollable\">\r\n <div id=\"notification-scroller\">\r\n <div [innerHtml]=\"(item?.text ?? 'Caricamento in corso...') | safeHtml\"></div>\r\n </div>\r\n</div>\r\n<div mat-dialog-actions class=\"notification-fixed\">\r\n <div style=\"padding: 10px 0\">\r\n @if (item?.documents && item?.documents.length > 0) {\r\n <button type=\"button\" mat-button [attr.aria-label]=\"'Documenti scaricabili'\" [matMenuTriggerFor]=\"documentsMenu\"\r\n color=\"primary\">\r\n {{item?.documents.length}} @if (item?.documents.length === 1) {\r\n <span>Documento scaricabile</span>\r\n }\r\n @if (item?.documents.length !== 1) {\r\n <span>Documenti scaricabili</span>\r\n }\r\n <mat-icon class=\"icon-menu-drop-down\">arrow_drop_down</mat-icon>\r\n </button>\r\n }\r\n <mat-menu #documentsMenu=\"matMenu\">\r\n <ng-template matMenuContent>\r\n @for (doc of item?.documents; track doc) {\r\n <button mat-menu-item (click)=\"downloadDocument(doc)\">\r\n @if (doc.isBinary) {\r\n <mat-icon>attach_file</mat-icon>\r\n }\r\n @if (!doc.isBinary) {\r\n <mat-icon>link</mat-icon>\r\n }\r\n {{doc.name}}\r\n </button>\r\n }\r\n </ng-template>\r\n </mat-menu>\r\n </div>\r\n</div>", styles: [""], dependencies: [{ kind: "ngmodule", type: FlexModule }, { kind: "directive", type: i1.DefaultLayoutDirective, 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.DefaultLayoutGapDirective, 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.DefaultLayoutAlignDirective, 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.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1.DefaultFlexAlignDirective, 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.DefaultFlexDirective, 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: MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i5.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: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuContent, selector: "ng-template[matMenuContent]" }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
117
118
|
}
|
|
118
119
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationComponent, decorators: [{
|
|
119
120
|
type: Component,
|
|
120
|
-
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, imports: [FlexModule, MatDialogTitle, MatButtonModule, MatTooltipModule, MatDialogClose, MatIconModule, MatDialogContent,
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
args: [MAT_DIALOG_DATA]
|
|
124
|
-
}] }], propDecorators: { onResize: [{
|
|
125
|
-
type: HostListener,
|
|
126
|
-
args: ['window:resize', ['$event']]
|
|
127
|
-
}] } });
|
|
121
|
+
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [FlexModule, MatDialogTitle, MatButtonModule, MatTooltipModule, MatDialogClose, MatIconModule, MatDialogContent,
|
|
122
|
+
MatDialogActions, MatMenuModule, SafeHtmlPipe], template: "<div class=\"support-notification-fixed\">\r\n <div class=\"support-notification-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>{{item?.title}}</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button color=\"primary\" matTooltip=\"Chiudi\"\r\n aria-label=\"Chiudi\" [mat-dialog-close]=\"true\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n<div mat-dialog-content id=\"notification-scrollable\">\r\n <div id=\"notification-scroller\">\r\n <div [innerHtml]=\"(item?.text ?? 'Caricamento in corso...') | safeHtml\"></div>\r\n </div>\r\n</div>\r\n<div mat-dialog-actions class=\"notification-fixed\">\r\n <div style=\"padding: 10px 0\">\r\n @if (item?.documents && item?.documents.length > 0) {\r\n <button type=\"button\" mat-button [attr.aria-label]=\"'Documenti scaricabili'\" [matMenuTriggerFor]=\"documentsMenu\"\r\n color=\"primary\">\r\n {{item?.documents.length}} @if (item?.documents.length === 1) {\r\n <span>Documento scaricabile</span>\r\n }\r\n @if (item?.documents.length !== 1) {\r\n <span>Documenti scaricabili</span>\r\n }\r\n <mat-icon class=\"icon-menu-drop-down\">arrow_drop_down</mat-icon>\r\n </button>\r\n }\r\n <mat-menu #documentsMenu=\"matMenu\">\r\n <ng-template matMenuContent>\r\n @for (doc of item?.documents; track doc) {\r\n <button mat-menu-item (click)=\"downloadDocument(doc)\">\r\n @if (doc.isBinary) {\r\n <mat-icon>attach_file</mat-icon>\r\n }\r\n @if (!doc.isBinary) {\r\n <mat-icon>link</mat-icon>\r\n }\r\n {{doc.name}}\r\n </button>\r\n }\r\n </ng-template>\r\n </mat-menu>\r\n </div>\r\n</div>" }]
|
|
123
|
+
}] });
|
|
128
124
|
|
|
129
125
|
class SupportNotificationsBrowserComponent {
|
|
130
|
-
|
|
131
|
-
this.
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
this
|
|
135
|
-
this
|
|
136
|
-
this
|
|
137
|
-
this.$dialog = $dialog;
|
|
126
|
+
constructor() {
|
|
127
|
+
this.screenService = inject(ScreenService);
|
|
128
|
+
this.supportService = inject(SupportService);
|
|
129
|
+
this.broadcastService = inject(BroadcastService);
|
|
130
|
+
this.dialogService = inject(DialogService);
|
|
131
|
+
this.unsubscribe = new Subject();
|
|
132
|
+
this.height = signal(null);
|
|
138
133
|
this.selection = new SelectableModel(true, 'id');
|
|
139
134
|
this.searchParams = {
|
|
140
135
|
first: 0,
|
|
141
136
|
count: 25
|
|
142
137
|
};
|
|
143
138
|
this.total = null;
|
|
144
|
-
this.
|
|
139
|
+
this.items = null;
|
|
145
140
|
this.contextMenuPosition = { x: '0px', y: '0px' };
|
|
146
141
|
}
|
|
147
142
|
ngOnInit() {
|
|
143
|
+
// React to window size change
|
|
144
|
+
fromEvent(window, 'resize')
|
|
145
|
+
.pipe(takeUntil(this.unsubscribe), debounceTime(500))
|
|
146
|
+
.subscribe(() => {
|
|
147
|
+
// Update view
|
|
148
|
+
this.resize();
|
|
149
|
+
});
|
|
148
150
|
// React to message broadcasting
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
151
|
+
this.broadcastService.getMessage()
|
|
152
|
+
.pipe(takeUntil(this.unsubscribe))
|
|
153
|
+
.subscribe((message) => {
|
|
154
|
+
if (message.id === SupportMessages.NOTIFICATION_READ) {
|
|
155
|
+
const item = SystemUtils.arrayFindByKey(this.items, 'id', message.data);
|
|
156
|
+
if (item) {
|
|
157
|
+
item.isRead = true;
|
|
156
158
|
}
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
+
}
|
|
160
|
+
});
|
|
159
161
|
}
|
|
160
162
|
ngOnDestroy() {
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
this.messageWatcher.unsubscribe();
|
|
163
|
+
this.unsubscribe.next();
|
|
164
|
+
this.unsubscribe.complete();
|
|
164
165
|
}
|
|
165
166
|
ngAfterViewInit() {
|
|
166
167
|
this.find();
|
|
@@ -170,20 +171,18 @@ class SupportNotificationsBrowserComponent {
|
|
|
170
171
|
* Resize dialog
|
|
171
172
|
*/
|
|
172
173
|
resize() {
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
this.height = h;
|
|
180
|
-
this.resize();
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
else {
|
|
174
|
+
let elem = document.getElementById('notifications-browser-scrollable');
|
|
175
|
+
if (elem) {
|
|
176
|
+
const h = this.dialogService.getCurrentDialogScrollableHeight(['notifications-browser-fixed'], window.innerHeight);
|
|
177
|
+
if (h != this.height()) {
|
|
178
|
+
elem.setAttribute('style', 'height:' + h + 'px !important;max-height:' + h + 'px !important');
|
|
179
|
+
this.height.set(h);
|
|
184
180
|
this.resize();
|
|
185
181
|
}
|
|
186
|
-
}
|
|
182
|
+
}
|
|
183
|
+
else {
|
|
184
|
+
this.resize();
|
|
185
|
+
}
|
|
187
186
|
}
|
|
188
187
|
onContextMenu(event, item) {
|
|
189
188
|
event.preventDefault();
|
|
@@ -215,7 +214,7 @@ class SupportNotificationsBrowserComponent {
|
|
|
215
214
|
*/
|
|
216
215
|
getSeletectIds() {
|
|
217
216
|
if (this.selection.all.length > 50) {
|
|
218
|
-
this
|
|
217
|
+
this.dialogService.error('La selezione non può contenere più di 50 elementi.');
|
|
219
218
|
return null;
|
|
220
219
|
}
|
|
221
220
|
let ids = [];
|
|
@@ -239,14 +238,14 @@ class SupportNotificationsBrowserComponent {
|
|
|
239
238
|
* Retrieve data
|
|
240
239
|
*/
|
|
241
240
|
fetch() {
|
|
242
|
-
if (!this
|
|
241
|
+
if (!this.supportService.loggedIn)
|
|
243
242
|
return;
|
|
244
|
-
this
|
|
245
|
-
this
|
|
243
|
+
this.dialogService.busy('Caricamento in corso...');
|
|
244
|
+
this.supportService.queryNotifications(this.searchParams)
|
|
246
245
|
.subscribe({
|
|
247
246
|
next: (r) => {
|
|
248
247
|
if (!r.success) {
|
|
249
|
-
this
|
|
248
|
+
this.dialogService.error(r.message);
|
|
250
249
|
}
|
|
251
250
|
else {
|
|
252
251
|
this.items = r.value?.items ?? [];
|
|
@@ -255,7 +254,7 @@ class SupportNotificationsBrowserComponent {
|
|
|
255
254
|
}
|
|
256
255
|
},
|
|
257
256
|
complete: () => {
|
|
258
|
-
this
|
|
257
|
+
this.dialogService.clearBusy();
|
|
259
258
|
}
|
|
260
259
|
});
|
|
261
260
|
}
|
|
@@ -274,20 +273,20 @@ class SupportNotificationsBrowserComponent {
|
|
|
274
273
|
* @param unmark : true to set as unread or false to set as read
|
|
275
274
|
*/
|
|
276
275
|
mark(item = null, unmark = false) {
|
|
277
|
-
if (!this
|
|
276
|
+
if (!this.supportService.loggedIn)
|
|
278
277
|
return;
|
|
279
278
|
if (!item && !this.selection.all.length)
|
|
280
279
|
return;
|
|
281
280
|
const ids = item ? [item.id] : this.getSeletectIds();
|
|
282
|
-
this
|
|
283
|
-
this
|
|
281
|
+
this.dialogService.busy('Aggiornamento in corso...');
|
|
282
|
+
this.supportService.markNotifications({
|
|
284
283
|
ids: ids,
|
|
285
284
|
unmark: unmark
|
|
286
285
|
})
|
|
287
286
|
.subscribe({
|
|
288
287
|
next: (r) => {
|
|
289
288
|
if (!r.success) {
|
|
290
|
-
this
|
|
289
|
+
this.dialogService.error(r.message);
|
|
291
290
|
}
|
|
292
291
|
else {
|
|
293
292
|
ids.forEach((id) => {
|
|
@@ -297,11 +296,11 @@ class SupportNotificationsBrowserComponent {
|
|
|
297
296
|
}
|
|
298
297
|
});
|
|
299
298
|
this.selection.clear();
|
|
300
|
-
this
|
|
299
|
+
this.supportService.countUnreadNotifications();
|
|
301
300
|
}
|
|
302
301
|
},
|
|
303
302
|
complete: () => {
|
|
304
|
-
this
|
|
303
|
+
this.dialogService.clearBusy();
|
|
305
304
|
}
|
|
306
305
|
});
|
|
307
306
|
}
|
|
@@ -310,7 +309,7 @@ class SupportNotificationsBrowserComponent {
|
|
|
310
309
|
* @param item : the item to display
|
|
311
310
|
*/
|
|
312
311
|
show(item) {
|
|
313
|
-
this
|
|
312
|
+
this.dialogService.open(SupportNotificationComponent, {
|
|
314
313
|
ariaLabel: 'visualizza notifica',
|
|
315
314
|
autoFocus: false,
|
|
316
315
|
restoreFocus: false,
|
|
@@ -322,23 +321,20 @@ class SupportNotificationsBrowserComponent {
|
|
|
322
321
|
height: '99%'
|
|
323
322
|
});
|
|
324
323
|
}
|
|
325
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationsBrowserComponent, deps: [
|
|
326
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SupportNotificationsBrowserComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() }, listeners: { "window:resize": "onResize($event)" } }, viewQueries: [{ propertyName: "paginator", first: true, predicate: ["paginator"], descendants: true }, { propertyName: "contextMenu", first: true, predicate: ["contextMenuTrigger"], descendants: true }], ngImport: i0, template: "<div class=\"notifications-browser-fixed\">\r\n <div class=\"notifications-browser-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>Novit\u00E0 e informazioni</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button color=\"primary\" matTooltip=\"Chiudi\"\r\n aria-label=\"Chiudi\" [mat-dialog-close]=\"true\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n <div style=\"padding-left: 24px; padding-right: 24px;\">\r\n <div fxLayout=\"row wrap\" fxFill fxLayoutAlign=\"space-between\">\r\n <div fxFlex=\"200px\" fxFlexAlign=\"end\">\r\n <mat-form-field style=\"width:200px\" subscriptSizing=\"dynamic\" appearance=\"outline\">\r\n <mat-label>Cerca</mat-label>\r\n <input matInput #searchInput=\"matInput\" type=\"text\" [(ngModel)]=\"searchParams.any\" maxlength=\"200\"\r\n (keyup.Enter)=\"find()\" autofocus placeholder=\"Inserisci testo + INVIO...\" />\r\n @if (searchParams.any) {\r\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\r\n (click)=\"searchParams.any = ''\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n </div>\r\n <div fxFlex=\"*\" fxLayoutAlign=\"end\">\r\n <div fxFlexAlign=\"center\">\r\n @if (selection.hasValue()) {\r\n <button type=\"button\" mat-button matTooltip=\"Azioni da eseguire sugli elementi selezionati\"\r\n [attr.aria-label]=\"'Menu opzioni per elementi selezionati'\" [matMenuTriggerFor]=\"menuSelections\"\r\n color=\"primary\">\r\n <mat-icon aria-hidden=\"false\" [matBadge]=\"selection.all.length\"\r\n matBadgeColor=\"accent\">playlist_add_check</mat-icon>\r\n <mat-icon class=\"icon-menu-drop-down\">arrow_drop_down</mat-icon>\r\n </button>\r\n }\r\n <mat-menu #menuSelections=\"matMenu\">\r\n <button mat-menu-item (click)=\"selection.clear()\" [attr.aria-label]=\"'Deseleziona tutti'\">\r\n <mat-icon>clear</mat-icon>Deseleziona tutti\r\n </button>\r\n <mat-divider></mat-divider>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(null, true)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come da leggere\r\n </button>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come gi\u00E0 letto'\" (click)=\"mark(null)\">\r\n <mat-icon>flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n<div mat-dialog-content id=\"notifications-browser-scrollable\">\r\n <div id=\"notifications-browser-scroller\">\r\n @if (total === 0) {\r\n <div>\r\n <p class=\"item-greyed-2\" style=\"padding: 20px; text-align: center;\"><i>Nessun elemento da visualizzare.</i></p>\r\n </div>\r\n }\r\n @if (total > 0) {\r\n <div>\r\n @for (item of items; track trackById(i, item); let i = $index) {\r\n <div>\r\n <div class=\"news\" fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill (mouseenter)=\"item.isOver = true;\"\r\n (mouseleave)=\"item.isOver = false\"\r\n [ngClass]=\"{'item-selected': selection.isSelected(item.id), 'news-read': item.isRead}\"\r\n (contextmenu)=\"onContextMenu($event, item)\">\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if ($screen.isTouchable || item.isOver || selection.isSelected(item.id)) {\r\n <mat-checkbox color=\"primary\" (change)=\"$event ? selection.toggle(item, item.id) : null\"\r\n [checked]=\"selection.isSelected(item.id)\">\r\n </mat-checkbox>\r\n }\r\n </div>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\" (click)=\"show(item); $event.stopPropagation()\">\r\n <div class=\"item-greyed-1 uppercase\" style=\"font-size:12px\">\r\n {{ (item.publishingDate ?? item.created) | format:'D':'dd/MM/yyyy'}}</div>\r\n <div>{{item.title}}</div>\r\n <div class=\"item-primary uppercase\" style=\"font-size:10px; font-weight: 500;\">\r\n {{item.productNames}}\r\n @if (item.productModulesNames) {\r\n <span> | {{item.productModulesNames}}</span>\r\n }\r\n </div>\r\n </div>\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if (item.isOver || item.isMenuOpen || selection.isSelected(item.id)) {\r\n <button type=\"button\" mat-icon-button matTooltip=\"Menu\" [attr.aria-label]=\"'Menu opzioni'\"\r\n [matMenuTriggerFor]=\"contextMenu\" [matMenuTriggerData]=\"{item: item}\" (click)=\"item.isMenuOpen = true\">\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n <div #contextMenuTrigger=\"matMenuTrigger\" style=\"position: fixed\" [style.left]=\"contextMenuPosition.x\"\r\n [style.top]=\"contextMenuPosition.y\" [matMenuTriggerFor]=\"contextMenu\">\r\n </div>\r\n <mat-menu #contextMenu=\"matMenu\" (closed)=\"updateMenuButtonsVisibility()\">\r\n <ng-template matMenuContent let-item=\"item\">\r\n @if (item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(item, true)\">\r\n <mat-icon>flag</mat-icon>Segna come da leggere\r\n </button>\r\n }\r\n @if (!item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da gi\u00E0 letto'\" (click)=\"mark(item)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n }\r\n </ng-template>\r\n </mat-menu>\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions class=\"notifications-browser-fixed\">\r\n <div fxLayout=\"row wrap\" fxLayoutGap=\"10px\" fxLayoutAlign=\"space-between\" fxFill>\r\n <!-- legend -->\r\n <div fxFlex.lt-md=\"100\" class=\"legend-container\">\r\n <div class=\"legend\" style=\"background-color: orange;\"></div>\r\n da leggere\r\n </div>\r\n <div fxFlex.lt-md=\"100\" fxLayoutAlign=\"end\">\r\n <mat-paginator #paginator [hidePageSize]=\"true\" [length]=\"total\" [pageSize]=\"searchParams.count\"\r\n [showFirstLastButtons]=\"true\" (page)=\"fetchMore($event)\"></mat-paginator>\r\n </div>\r\n </div>\r\n</div>", styles: [".news{padding:8px 0;font-weight:500;border-bottom:1px solid #eee;border-left:4px solid orange}.news:hover{background-color:#fff8e1;cursor:pointer}.news-read{font-weight:400;border-left:4px solid transparent}\n"], dependencies: [{ kind: "ngmodule", type: FlexModule }, { kind: "directive", type: i4.DefaultLayoutDirective, 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: i4.DefaultLayoutGapDirective, 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: i4.DefaultLayoutAlignDirective, 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: i4.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i4.DefaultFlexAlignDirective, 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: i4.DefaultFlexDirective, 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: MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i5.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i5.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i6.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i7.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i8$1.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i8$1.MatLabel, selector: "mat-label" }, { kind: "directive", type: i8$1.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i10.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i10.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i10.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i10.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i8.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: i8.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i8.MatMenuContent, selector: "ng-template[matMenuContent]" }, { kind: "directive", type: i8.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: MatBadgeModule }, { kind: "directive", type: i12.MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i13.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "directive", type: MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ExtendedModule }, { kind: "directive", type: i14.DefaultClassDirective, selector: " [ngClass], [ngClass.xs], [ngClass.sm], [ngClass.md], [ngClass.lg], [ngClass.xl], [ngClass.lt-sm], [ngClass.lt-md], [ngClass.lt-lg], [ngClass.lt-xl], [ngClass.gt-xs], [ngClass.gt-sm], [ngClass.gt-md], [ngClass.gt-lg]", inputs: ["ngClass", "ngClass.xs", "ngClass.sm", "ngClass.md", "ngClass.lg", "ngClass.xl", "ngClass.lt-sm", "ngClass.lt-md", "ngClass.lt-lg", "ngClass.lt-xl", "ngClass.gt-xs", "ngClass.gt-sm", "ngClass.gt-md", "ngClass.gt-lg"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i15.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i16.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "pipe", type: FormatPipe, name: "format" }] }); }
|
|
324
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationsBrowserComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
325
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SupportNotificationsBrowserComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() } }, viewQueries: [{ propertyName: "paginator", first: true, predicate: ["paginator"], descendants: true }, { propertyName: "contextMenu", first: true, predicate: ["contextMenuTrigger"], descendants: true }], ngImport: i0, template: "<div class=\"notifications-browser-fixed\">\r\n <div class=\"notifications-browser-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>Novit\u00E0 e informazioni</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Chiudi\"\r\n aria-label=\"Chiudi\" [mat-dialog-close]=\"true\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n <div style=\"padding-left: 24px; padding-right: 24px;\">\r\n <div fxLayout=\"row wrap\" fxFill fxLayoutAlign=\"space-between\">\r\n <div fxFlex=\"200px\" fxFlexAlign=\"end\">\r\n <mat-form-field style=\"width:200px\" subscriptSizing=\"dynamic\" appearance=\"outline\">\r\n <mat-label>Cerca</mat-label>\r\n <input matInput #searchInput=\"matInput\" type=\"text\" [(ngModel)]=\"searchParams.any\" maxlength=\"200\"\r\n (keyup.Enter)=\"find()\" autofocus placeholder=\"Inserisci testo + INVIO...\" />\r\n @if (searchParams.any) {\r\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\r\n (click)=\"searchParams.any = ''\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n </div>\r\n <div fxFlex=\"*\" fxLayoutAlign=\"end\">\r\n <div fxFlexAlign=\"center\">\r\n @if (selection.hasValue()) {\r\n <button type=\"button\" mat-button matTooltip=\"Azioni da eseguire sugli elementi selezionati\"\r\n [attr.aria-label]=\"'Menu opzioni per elementi selezionati'\" [matMenuTriggerFor]=\"menuSelections\"\r\n color=\"primary\">\r\n <mat-icon aria-hidden=\"false\" [matBadge]=\"selection.all.length\"\r\n matBadgeColor=\"accent\">playlist_add_check</mat-icon>\r\n <mat-icon class=\"icon-menu-drop-down\">arrow_drop_down</mat-icon>\r\n </button>\r\n }\r\n <mat-menu #menuSelections=\"matMenu\">\r\n <button mat-menu-item (click)=\"selection.clear()\" [attr.aria-label]=\"'Deseleziona tutti'\">\r\n <mat-icon>clear</mat-icon>Deseleziona tutti\r\n </button>\r\n <mat-divider></mat-divider>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(null, true)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come da leggere\r\n </button>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come gi\u00E0 letto'\" (click)=\"mark(null)\">\r\n <mat-icon>flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n<div mat-dialog-content id=\"notifications-browser-scrollable\">\r\n <div id=\"notifications-browser-scroller\">\r\n @if (total === 0) {\r\n <div>\r\n <p class=\"message\"><i>Nessun elemento da visualizzare.</i></p>\r\n </div>\r\n }\r\n @if (total > 0) {\r\n <div>\r\n @for (item of items; track item.id; let i = $index) {\r\n <div>\r\n <div class=\"news\" fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill (mouseenter)=\"item.isOver = true;\"\r\n (mouseleave)=\"item.isOver = false\"\r\n [ngClass]=\"{'news-selected': selection.isSelected(item.id), \r\n 'news-read': item.isRead}\"\r\n (contextmenu)=\"onContextMenu($event, item)\">\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if (screenService.isTouchable || item.isOver || selection.isSelected(item.id)) {\r\n <mat-checkbox color=\"primary\" (change)=\"$event ? selection.toggle(item, item.id) : null\"\r\n [checked]=\"selection.isSelected(item.id)\">\r\n </mat-checkbox>\r\n }\r\n </div>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\" (click)=\"show(item); $event.stopPropagation()\">\r\n <div class=\"info-1 uppercase\">\r\n {{ (item.publishingDate ?? item.created) | format:'D':'dd/MM/yyyy'}}</div>\r\n <div>{{item.title}}</div>\r\n <div class=\"info-2 uppercase\">\r\n {{item.productNames}}\r\n @if (item.productModulesNames) {\r\n <span> | {{item.productModulesNames}}</span>\r\n }\r\n </div>\r\n </div>\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if (item.isOver || item.isMenuOpen || selection.isSelected(item.id)) {\r\n <button type=\"button\" mat-icon-button matTooltip=\"Menu\" [attr.aria-label]=\"'Menu opzioni'\"\r\n [matMenuTriggerFor]=\"contextMenu\" [matMenuTriggerData]=\"{item: item}\" (click)=\"item.isMenuOpen = true\">\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n <div #contextMenuTrigger=\"matMenuTrigger\" style=\"position: fixed\" [style.left]=\"contextMenuPosition.x\"\r\n [style.top]=\"contextMenuPosition.y\" [matMenuTriggerFor]=\"contextMenu\">\r\n </div>\r\n <mat-menu #contextMenu=\"matMenu\" (closed)=\"updateMenuButtonsVisibility()\">\r\n <ng-template matMenuContent let-item=\"item\">\r\n @if (item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(item, true)\">\r\n <mat-icon>flag</mat-icon>Segna come da leggere\r\n </button>\r\n }\r\n @if (!item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da gi\u00E0 letto'\" (click)=\"mark(item)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n }\r\n </ng-template>\r\n </mat-menu>\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions class=\"notifications-browser-fixed\">\r\n <div fxLayout=\"row wrap\" fxLayoutGap=\"10px\" fxLayoutAlign=\"space-between\" fxFill>\r\n <!-- legend -->\r\n <div fxFlex.lt-md=\"100\" class=\"legend-container\">\r\n <div class=\"legend unread-bg\"></div>\r\n da leggere\r\n </div>\r\n <div fxFlex.lt-md=\"100\" fxLayoutAlign=\"end\">\r\n <mat-paginator #paginator [hidePageSize]=\"true\" [length]=\"total\" [pageSize]=\"searchParams.count\"\r\n [showFirstLastButtons]=\"true\" (page)=\"fetchMore($event)\"></mat-paginator>\r\n </div>\r\n </div>\r\n</div>", styles: [".news{padding:8px 0;font-weight:500;border-bottom:1px solid var(--mat-divider-color);border-left:4px solid var(--ars-color-warning-low, #FFA000)}.news .info-1{font-size:small;color:var(--ars-color-accent, #7894ae)}.news .info-2{font-size:x-small;color:var(--ars-color-accent-low, #456179)}.news:hover{background-color:var(--mdc-list-list-item-hover-state-layer-color, #fff8e1);border-radius:24px}.news-read{font-weight:400;border-left:4px solid transparent}.news-selected{background-color:var(--mdc-list-list-item-focus-state-layer-color);opacity:var(--mdc-list-list-item-focus-state-layer-opacity);border-radius:0}.message{color:var(--ars-color-secondary, #4a635f);padding:20px;text-align:center}.unread-bg{background-color:var(--ars-color-warning-low, #FFA000)}.legend-container{display:flex;flex-direction:row;align-items:center;font-size:x-small;text-transform:uppercase;font-weight:500;margin-left:10px}.legend-container .legend{display:inline-block;height:8px;width:8px;margin-right:4px}.legend-container .next{margin-left:8px}\n"], dependencies: [{ kind: "ngmodule", type: FlexModule }, { kind: "directive", type: i1.DefaultLayoutDirective, 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.DefaultLayoutGapDirective, 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.DefaultLayoutAlignDirective, 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.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1.DefaultFlexAlignDirective, 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.DefaultFlexDirective, 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: MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i5$1.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i5$1.MatLabel, selector: "mat-label" }, { kind: "directive", type: i5$1.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i7.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i7.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i5.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: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuContent, selector: "ng-template[matMenuContent]" }, { kind: "directive", type: i5.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: MatBadgeModule }, { kind: "directive", type: i9.MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i10.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "directive", type: MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ExtendedModule }, { kind: "directive", type: i11.DefaultClassDirective, selector: " [ngClass], [ngClass.xs], [ngClass.sm], [ngClass.md], [ngClass.lg], [ngClass.xl], [ngClass.lt-sm], [ngClass.lt-md], [ngClass.lt-lg], [ngClass.lt-xl], [ngClass.gt-xs], [ngClass.gt-sm], [ngClass.gt-md], [ngClass.gt-lg]", inputs: ["ngClass", "ngClass.xs", "ngClass.sm", "ngClass.md", "ngClass.lg", "ngClass.xl", "ngClass.lt-sm", "ngClass.lt-md", "ngClass.lt-lg", "ngClass.lt-xl", "ngClass.gt-xs", "ngClass.gt-sm", "ngClass.gt-md", "ngClass.gt-lg"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i12.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i13.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "pipe", type: FormatPipe, name: "format" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
327
326
|
}
|
|
328
327
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SupportNotificationsBrowserComponent, decorators: [{
|
|
329
328
|
type: Component,
|
|
330
|
-
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, imports: [FlexModule, MatDialogTitle, MatButtonModule, MatTooltipModule, MatDialogClose,
|
|
329
|
+
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [FlexModule, MatDialogTitle, MatButtonModule, MatTooltipModule, MatDialogClose,
|
|
331
330
|
MatIconModule, MatFormFieldModule, MatInputModule, FormsModule, MatMenuModule, MatBadgeModule, MatDividerModule, MatDialogContent, NgClass, ExtendedModule, MatCheckboxModule, MatDialogActions,
|
|
332
|
-
MatPaginatorModule, FormatPipe, SupportNotificationComponent], template: "<div class=\"notifications-browser-fixed\">\r\n <div class=\"notifications-browser-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>Novit\u00E0 e informazioni</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button
|
|
333
|
-
}],
|
|
331
|
+
MatPaginatorModule, FormatPipe, SupportNotificationComponent], template: "<div class=\"notifications-browser-fixed\">\r\n <div class=\"notifications-browser-header\">\r\n <div fxLayout=\"row\" fxFill fxLayoutGap=\"10px\">\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">\r\n <h2 mat-dialog-title>Novit\u00E0 e informazioni</h2>\r\n </div>\r\n <div fxLayoutAlign=\"end\">\r\n <button fxFlexAlign=\"center\" type=\"button\" mat-icon-button matTooltip=\"Chiudi\"\r\n aria-label=\"Chiudi\" [mat-dialog-close]=\"true\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n <div style=\"padding-left: 24px; padding-right: 24px;\">\r\n <div fxLayout=\"row wrap\" fxFill fxLayoutAlign=\"space-between\">\r\n <div fxFlex=\"200px\" fxFlexAlign=\"end\">\r\n <mat-form-field style=\"width:200px\" subscriptSizing=\"dynamic\" appearance=\"outline\">\r\n <mat-label>Cerca</mat-label>\r\n <input matInput #searchInput=\"matInput\" type=\"text\" [(ngModel)]=\"searchParams.any\" maxlength=\"200\"\r\n (keyup.Enter)=\"find()\" autofocus placeholder=\"Inserisci testo + INVIO...\" />\r\n @if (searchParams.any) {\r\n <button type=\"button\" tabindex=\"-1\" matSuffix mat-icon-button aria-label=\"Pulisci\"\r\n (click)=\"searchParams.any = ''\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n }\r\n </mat-form-field>\r\n </div>\r\n <div fxFlex=\"*\" fxLayoutAlign=\"end\">\r\n <div fxFlexAlign=\"center\">\r\n @if (selection.hasValue()) {\r\n <button type=\"button\" mat-button matTooltip=\"Azioni da eseguire sugli elementi selezionati\"\r\n [attr.aria-label]=\"'Menu opzioni per elementi selezionati'\" [matMenuTriggerFor]=\"menuSelections\"\r\n color=\"primary\">\r\n <mat-icon aria-hidden=\"false\" [matBadge]=\"selection.all.length\"\r\n matBadgeColor=\"accent\">playlist_add_check</mat-icon>\r\n <mat-icon class=\"icon-menu-drop-down\">arrow_drop_down</mat-icon>\r\n </button>\r\n }\r\n <mat-menu #menuSelections=\"matMenu\">\r\n <button mat-menu-item (click)=\"selection.clear()\" [attr.aria-label]=\"'Deseleziona tutti'\">\r\n <mat-icon>clear</mat-icon>Deseleziona tutti\r\n </button>\r\n <mat-divider></mat-divider>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(null, true)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come da leggere\r\n </button>\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come gi\u00E0 letto'\" (click)=\"mark(null)\">\r\n <mat-icon>flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n<div mat-dialog-content id=\"notifications-browser-scrollable\">\r\n <div id=\"notifications-browser-scroller\">\r\n @if (total === 0) {\r\n <div>\r\n <p class=\"message\"><i>Nessun elemento da visualizzare.</i></p>\r\n </div>\r\n }\r\n @if (total > 0) {\r\n <div>\r\n @for (item of items; track item.id; let i = $index) {\r\n <div>\r\n <div class=\"news\" fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill (mouseenter)=\"item.isOver = true;\"\r\n (mouseleave)=\"item.isOver = false\"\r\n [ngClass]=\"{'news-selected': selection.isSelected(item.id), \r\n 'news-read': item.isRead}\"\r\n (contextmenu)=\"onContextMenu($event, item)\">\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if (screenService.isTouchable || item.isOver || selection.isSelected(item.id)) {\r\n <mat-checkbox color=\"primary\" (change)=\"$event ? selection.toggle(item, item.id) : null\"\r\n [checked]=\"selection.isSelected(item.id)\">\r\n </mat-checkbox>\r\n }\r\n </div>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\" (click)=\"show(item); $event.stopPropagation()\">\r\n <div class=\"info-1 uppercase\">\r\n {{ (item.publishingDate ?? item.created) | format:'D':'dd/MM/yyyy'}}</div>\r\n <div>{{item.title}}</div>\r\n <div class=\"info-2 uppercase\">\r\n {{item.productNames}}\r\n @if (item.productModulesNames) {\r\n <span> | {{item.productModulesNames}}</span>\r\n }\r\n </div>\r\n </div>\r\n <div fxFlex=\"50px\" fxFlexAlign=\"center\">\r\n @if (item.isOver || item.isMenuOpen || selection.isSelected(item.id)) {\r\n <button type=\"button\" mat-icon-button matTooltip=\"Menu\" [attr.aria-label]=\"'Menu opzioni'\"\r\n [matMenuTriggerFor]=\"contextMenu\" [matMenuTriggerData]=\"{item: item}\" (click)=\"item.isMenuOpen = true\">\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n <div #contextMenuTrigger=\"matMenuTrigger\" style=\"position: fixed\" [style.left]=\"contextMenuPosition.x\"\r\n [style.top]=\"contextMenuPosition.y\" [matMenuTriggerFor]=\"contextMenu\">\r\n </div>\r\n <mat-menu #contextMenu=\"matMenu\" (closed)=\"updateMenuButtonsVisibility()\">\r\n <ng-template matMenuContent let-item=\"item\">\r\n @if (item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da leggere'\" (click)=\"mark(item, true)\">\r\n <mat-icon>flag</mat-icon>Segna come da leggere\r\n </button>\r\n }\r\n @if (!item.isRead) {\r\n <button mat-menu-item [attr.aria-label]=\"'Segna come da gi\u00E0 letto'\" (click)=\"mark(item)\">\r\n <mat-icon>outlined_flag</mat-icon>Segna come gi\u00E0 letto\r\n </button>\r\n }\r\n </ng-template>\r\n </mat-menu>\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions class=\"notifications-browser-fixed\">\r\n <div fxLayout=\"row wrap\" fxLayoutGap=\"10px\" fxLayoutAlign=\"space-between\" fxFill>\r\n <!-- legend -->\r\n <div fxFlex.lt-md=\"100\" class=\"legend-container\">\r\n <div class=\"legend unread-bg\"></div>\r\n da leggere\r\n </div>\r\n <div fxFlex.lt-md=\"100\" fxLayoutAlign=\"end\">\r\n <mat-paginator #paginator [hidePageSize]=\"true\" [length]=\"total\" [pageSize]=\"searchParams.count\"\r\n [showFirstLastButtons]=\"true\" (page)=\"fetchMore($event)\"></mat-paginator>\r\n </div>\r\n </div>\r\n</div>", styles: [".news{padding:8px 0;font-weight:500;border-bottom:1px solid var(--mat-divider-color);border-left:4px solid var(--ars-color-warning-low, #FFA000)}.news .info-1{font-size:small;color:var(--ars-color-accent, #7894ae)}.news .info-2{font-size:x-small;color:var(--ars-color-accent-low, #456179)}.news:hover{background-color:var(--mdc-list-list-item-hover-state-layer-color, #fff8e1);border-radius:24px}.news-read{font-weight:400;border-left:4px solid transparent}.news-selected{background-color:var(--mdc-list-list-item-focus-state-layer-color);opacity:var(--mdc-list-list-item-focus-state-layer-opacity);border-radius:0}.message{color:var(--ars-color-secondary, #4a635f);padding:20px;text-align:center}.unread-bg{background-color:var(--ars-color-warning-low, #FFA000)}.legend-container{display:flex;flex-direction:row;align-items:center;font-size:x-small;text-transform:uppercase;font-weight:500;margin-left:10px}.legend-container .legend{display:inline-block;height:8px;width:8px;margin-right:4px}.legend-container .next{margin-left:8px}\n"] }]
|
|
332
|
+
}], propDecorators: { paginator: [{
|
|
334
333
|
type: ViewChild,
|
|
335
334
|
args: ['paginator']
|
|
336
335
|
}], contextMenu: [{
|
|
337
336
|
type: ViewChild,
|
|
338
337
|
args: ['contextMenuTrigger']
|
|
339
|
-
}], onResize: [{
|
|
340
|
-
type: HostListener,
|
|
341
|
-
args: ['window:resize', ['$event']]
|
|
342
338
|
}] } });
|
|
343
339
|
|
|
344
340
|
/*
|