@arsedizioni/ars-utils 20.3.33 → 20.3.35

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.
@@ -135,10 +135,10 @@ class IndexTreeDataSource {
135
135
  update() {
136
136
  this.dataChange.next(this.data);
137
137
  }
138
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: IndexTreeDataSource, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
139
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: IndexTreeDataSource }); }
138
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: IndexTreeDataSource, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
139
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: IndexTreeDataSource }); }
140
140
  }
141
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: IndexTreeDataSource, decorators: [{
141
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: IndexTreeDataSource, decorators: [{
142
142
  type: Injectable
143
143
  }] });
144
144
  class HelpViewerComponent {
@@ -432,10 +432,10 @@ class HelpViewerComponent {
432
432
  let n = this.history().pop();
433
433
  this.getChapter(n.id, n.position + 1);
434
434
  }
435
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: HelpViewerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
436
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.0", type: HelpViewerComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() } }, providers: [IndexTreeDataSource], viewQueries: [{ propertyName: "indexPane", first: true, predicate: ["indexPane"], descendants: true, isSignal: true }], ngImport: i0, template: "<div class=\"helpviewer-fixed\">\r\n <div style=\"height:6px\">\r\n @if (busy()) {\r\n <mat-progress-bar z-index=\"11\" mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div class=\"dialog-header\">\r\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\r\n <div class=\"dialog-menu\">\r\n <button type=\"button\" mat-icon-button matTooltip=\"Mostra menu\" [attr.aria-label]=\"'Mostra indice'\"\r\n (click)=\"toggleIndexPane()\">\r\n <mat-icon>menu</mat-icon>\r\n </button>\r\n </div>\r\n <div fxFlex=\"*\">\r\n <h2 mat-dialog-title>Guida</h2>\r\n </div>\r\n <div fxFlex=\"100px\" fxLayoutAlign=\"end\" class=\"dialog-close\">\r\n @if (canGoBack()) {\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Indietro\" (click)=\"back()\">\r\n <mat-icon>arrow_back</mat-icon>\r\n </button>\r\n }\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Chiudi\" (click)=\"close()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n<mat-dialog-content id=\"helpviewer-scrollable\">\r\n <mat-drawer-container class=\"fill\">\r\n <mat-drawer #indexPane mode=\"side\" [autoFocus]=\"false\" class=\"drawer-small drawer-transparent\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div fxFlex=\"*\">\r\n <mat-tree [dataSource]=\"treeData\" [treeControl]=\"treeControl\" class=\"tree \" style=\"max-width:310px\">\r\n <mat-tree-node *matTreeNodeDef=\"let node\" matTreeNodeToggle matTreeNodePadding\r\n [matTreeNodePaddingIndent]=\"20\" class=\"tree-node tree-node-simple tree-node-style\"\r\n (click)=\"getChapter(node.id);\" [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button disabled class=\"small-icon-button\"></button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n <mat-tree-node *matTreeNodeDef=\"let node;when: hasChild\" matTreeNodePadding [matTreeNodePaddingIndent]=\"20\"\r\n class=\"tree-node tree-node-simple tree-node-style\"\r\n [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\" (click)=\"getChapter(node.id)\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button matTreeNodeToggle\r\n [attr.aria-label]=\"'Apri/chiudi ' + node.name\" class=\"small-icon-button\">\r\n <mat-icon class=\"mat-icon-rtl-mirror\">\r\n {{treeControl.isExpanded(node) ? 'expand_more' : 'chevron_right'}}\r\n </mat-icon>\r\n </button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n </mat-tree>\r\n </div>\r\n </div>\r\n </mat-drawer>\r\n <mat-drawer-content id=\"helpviewer-scroller\">\r\n <div style=\"padding: 0 24px;\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div class=\"fill\" (click)=\"gotoChapter($event)\" [innerHtml]=\"(page() ?? '') | safeHtml\"></div>\r\n </div>\r\n </div>\r\n </mat-drawer-content>\r\n </mat-drawer-container>\r\n</mat-dialog-content>", styles: [".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-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}.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.fill{min-width:100%!important;max-width:100%!important;width:100%!important;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}.smaller{font-size:smaller!important}.small{font-size:small!important;line-height:16px!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:14px!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-small .title-container{padding:20px 5px 20px 0}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding:14px 5px 20px 0}.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}}@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{font-weight:600}}.dialog-menu{margin-top:4px!important}.tree{overflow-x:hidden}.tree-node{min-height:36px!important;padding-right:12px;margin-right:0}.tree-node .small-icon-button{width:2rem!important;height:2rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.tree-node .small-icon-button .mat-mdc-button-touch-target{width:2rem!important;height:2rem!important}.tree-node:hover{cursor:pointer;background-color:var(--mat-menu-item-hover-state-layer-color, transparent);border-radius:24px}.tree-node-simple,.tree-node-simple>div{min-height:36px!important}.tree-node-activated,.tree-node-activated>div{min-height:36px!important;font-weight:700!important;color:var(--ars-color-accent, #7894ae)!important}a.help-link,.help-link>a{text-decoration:none;color:#2a91e0}.help-title-2,.help-title-1{font-weight:600!important}.help-word-hit{font-size:inherit;background-color:var(--ars-word-hit-background-color, yellow);padding:0 4px}.help-hint{margin:10px;padding:5px 20px;background-color:var(--ars-help-hint-background-color, lightgoldenrodyellow);border-radius:12px}.help-summary{margin:10px;padding:5px 20px;background-color:var(--ars-help-summary-background-color, lavender);border-radius:12px}.help-img{display:flex;align-items:center;justify-content:center;margin:10px}.help-img-200,.help-img-300,.help-img-400,.help-img-500,.help-img-700,.help-img-800{width:100%}.help-img-200{max-width:200px}.help-img-300{max-width:300px}.help-img-400{max-width:400px}.help-img-500{max-width:500px}.help-img-600{max-width:600px}.help-img-700{max-width:700px}.help-img-800{max-width:800px}.help-filter-box{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7);border-radius:12px;padding:6px;display:inline-block;margin:0 0 8px 10px}.mat-mdc-dialog-content{max-height:unset!important;padding:0!important}\n"], dependencies: [{ kind: "ngmodule", type: FlexLayoutModule }, { 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: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatProgressBarModule }, { kind: "component", type: i5.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "directive", type: MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i6.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i6.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i6.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "ngmodule", type: MatTreeModule }, { kind: "directive", type: i7.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { kind: "directive", type: i7.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { kind: "directive", type: i7.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { kind: "component", type: i7.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { kind: "directive", type: i7.MatTreeNode, selector: "mat-tree-node", inputs: ["tabIndex", "disabled"], outputs: ["activation", "expandedChange"], exportAs: ["matTreeNode"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
435
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HelpViewerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
436
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: HelpViewerComponent, isStandalone: true, selector: "ng-component", host: { attributes: { "Bind": SystemUtils.generateUUID() } }, providers: [IndexTreeDataSource], viewQueries: [{ propertyName: "indexPane", first: true, predicate: ["indexPane"], descendants: true, isSignal: true }], ngImport: i0, template: "<div class=\"helpviewer-fixed\">\r\n <div style=\"height:6px\">\r\n @if (busy()) {\r\n <mat-progress-bar z-index=\"11\" mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div class=\"dialog-header\">\r\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\r\n <div class=\"dialog-menu\">\r\n <button type=\"button\" mat-icon-button matTooltip=\"Mostra menu\" [attr.aria-label]=\"'Mostra indice'\"\r\n (click)=\"toggleIndexPane()\">\r\n <mat-icon>menu</mat-icon>\r\n </button>\r\n </div>\r\n <div fxFlex=\"*\">\r\n <h2 mat-dialog-title>Guida</h2>\r\n </div>\r\n <div fxFlex=\"100px\" fxLayoutAlign=\"end\" class=\"dialog-close\">\r\n @if (canGoBack()) {\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Indietro\" (click)=\"back()\">\r\n <mat-icon>arrow_back</mat-icon>\r\n </button>\r\n }\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Chiudi\" (click)=\"close()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n<mat-dialog-content id=\"helpviewer-scrollable\">\r\n <mat-drawer-container class=\"fill\">\r\n <mat-drawer #indexPane mode=\"side\" [autoFocus]=\"false\" class=\"drawer-small drawer-transparent\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div fxFlex=\"*\">\r\n <mat-tree [dataSource]=\"treeData\" [treeControl]=\"treeControl\" class=\"tree \" style=\"max-width:310px\">\r\n <mat-tree-node *matTreeNodeDef=\"let node\" matTreeNodeToggle matTreeNodePadding\r\n [matTreeNodePaddingIndent]=\"20\" class=\"tree-node tree-node-simple tree-node-style\"\r\n (click)=\"getChapter(node.id);\" [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button disabled class=\"small-icon-button\"></button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n <mat-tree-node *matTreeNodeDef=\"let node;when: hasChild\" matTreeNodePadding [matTreeNodePaddingIndent]=\"20\"\r\n class=\"tree-node tree-node-simple tree-node-style\"\r\n [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\" (click)=\"getChapter(node.id)\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button matTreeNodeToggle\r\n [attr.aria-label]=\"'Apri/chiudi ' + node.name\" class=\"small-icon-button\">\r\n <mat-icon class=\"mat-icon-rtl-mirror\">\r\n {{treeControl.isExpanded(node) ? 'expand_more' : 'chevron_right'}}\r\n </mat-icon>\r\n </button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n </mat-tree>\r\n </div>\r\n </div>\r\n </mat-drawer>\r\n <mat-drawer-content id=\"helpviewer-scroller\">\r\n <div style=\"padding: 0 24px;\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div class=\"fill\" (click)=\"gotoChapter($event)\" [innerHtml]=\"(page() ?? '') | safeHtml\"></div>\r\n </div>\r\n </div>\r\n </mat-drawer-content>\r\n </mat-drawer-container>\r\n</mat-dialog-content>", styles: [".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-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}.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.fill{min-width:100%!important;max-width:100%!important;width:100%!important;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}.smaller{font-size:smaller!important}.small{font-size:small!important;line-height:16px!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:14px!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-small .title-container{padding:20px 5px 20px 0}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding:14px 5px 20px 0}.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}}@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{font-weight:600}}.dialog-menu{margin-top:4px!important}.tree{overflow-x:hidden}.tree-node{min-height:36px!important;padding-right:12px;margin-right:0}.tree-node .small-icon-button{width:2rem!important;height:2rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.tree-node .small-icon-button .mat-mdc-button-touch-target{width:2rem!important;height:2rem!important}.tree-node:hover{cursor:pointer;background-color:var(--mat-menu-item-hover-state-layer-color, transparent);border-radius:24px}.tree-node-simple,.tree-node-simple>div{min-height:36px!important}.tree-node-activated,.tree-node-activated>div{min-height:36px!important;font-weight:700!important;color:var(--ars-color-accent, #7894ae)!important}a.help-link,.help-link>a{text-decoration:none;color:#2a91e0}.help-title-2,.help-title-1{font-weight:600!important}.help-word-hit{font-size:inherit;background-color:var(--ars-word-hit-background-color, yellow);padding:0 4px}.help-hint{margin:10px;padding:5px 20px;background-color:var(--ars-help-hint-background-color, lightgoldenrodyellow);border-radius:12px}.help-summary{margin:10px;padding:5px 20px;background-color:var(--ars-help-summary-background-color, lavender);border-radius:12px}.help-img{display:flex;align-items:center;justify-content:center;margin:10px}.help-img-200,.help-img-300,.help-img-400,.help-img-500,.help-img-700,.help-img-800{width:100%}.help-img-200{max-width:200px}.help-img-300{max-width:300px}.help-img-400{max-width:400px}.help-img-500{max-width:500px}.help-img-600{max-width:600px}.help-img-700{max-width:700px}.help-img-800{max-width:800px}.help-filter-box{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7);border-radius:12px;padding:6px;display:inline-block;margin:0 0 8px 10px}.mat-mdc-dialog-content{max-height:unset!important;padding:0!important}\n"], dependencies: [{ kind: "ngmodule", type: FlexLayoutModule }, { 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: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatProgressBarModule }, { kind: "component", type: i5.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "directive", type: MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i6.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i6.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i6.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "ngmodule", type: MatTreeModule }, { kind: "directive", type: i7.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { kind: "directive", type: i7.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { kind: "directive", type: i7.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { kind: "component", type: i7.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { kind: "directive", type: i7.MatTreeNode, selector: "mat-tree-node", inputs: ["tabIndex", "disabled"], outputs: ["activation", "expandedChange"], exportAs: ["matTreeNode"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
437
437
  }
438
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: HelpViewerComponent, decorators: [{
438
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HelpViewerComponent, decorators: [{
439
439
  type: Component,
440
440
  args: [{ host: { 'Bind': SystemUtils.generateUUID() }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [IndexTreeDataSource], standalone: true, imports: [FlexLayoutModule, MatButtonModule, MatTooltipModule, MatIconModule, MatProgressBarModule, MatDialogTitle, MatDialogContent,
441
441
  MatSidenavModule, MatTreeModule, SafeHtmlPipe], template: "<div class=\"helpviewer-fixed\">\r\n <div style=\"height:6px\">\r\n @if (busy()) {\r\n <mat-progress-bar z-index=\"11\" mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div class=\"dialog-header\">\r\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"10px\" fxFill>\r\n <div class=\"dialog-menu\">\r\n <button type=\"button\" mat-icon-button matTooltip=\"Mostra menu\" [attr.aria-label]=\"'Mostra indice'\"\r\n (click)=\"toggleIndexPane()\">\r\n <mat-icon>menu</mat-icon>\r\n </button>\r\n </div>\r\n <div fxFlex=\"*\">\r\n <h2 mat-dialog-title>Guida</h2>\r\n </div>\r\n <div fxFlex=\"100px\" fxLayoutAlign=\"end\" class=\"dialog-close\">\r\n @if (canGoBack()) {\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Indietro\" (click)=\"back()\">\r\n <mat-icon>arrow_back</mat-icon>\r\n </button>\r\n }\r\n <button fxFlexAlign=\"start\" type=\"button\" mat-icon-button matTooltip=\"Chiudi\" (click)=\"close()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n<mat-dialog-content id=\"helpviewer-scrollable\">\r\n <mat-drawer-container class=\"fill\">\r\n <mat-drawer #indexPane mode=\"side\" [autoFocus]=\"false\" class=\"drawer-small drawer-transparent\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div fxFlex=\"*\">\r\n <mat-tree [dataSource]=\"treeData\" [treeControl]=\"treeControl\" class=\"tree \" style=\"max-width:310px\">\r\n <mat-tree-node *matTreeNodeDef=\"let node\" matTreeNodeToggle matTreeNodePadding\r\n [matTreeNodePaddingIndent]=\"20\" class=\"tree-node tree-node-simple tree-node-style\"\r\n (click)=\"getChapter(node.id);\" [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button disabled class=\"small-icon-button\"></button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n <mat-tree-node *matTreeNodeDef=\"let node;when: hasChild\" matTreeNodePadding [matTreeNodePaddingIndent]=\"20\"\r\n class=\"tree-node tree-node-simple tree-node-style\"\r\n [class.tree-node-activated]=\"indexNode && indexNode.id === node.id\" (click)=\"getChapter(node.id)\"\r\n [disabled]=\"busy()\">\r\n <div fxLayout=\"row\" fxLayoutGap=\"10px\" fxFill class=\"small uppercase\">\r\n <button type=\"button\" fxFlexAlign=\"center\" mat-icon-button matTreeNodeToggle\r\n [attr.aria-label]=\"'Apri/chiudi ' + node.name\" class=\"small-icon-button\">\r\n <mat-icon class=\"mat-icon-rtl-mirror\">\r\n {{treeControl.isExpanded(node) ? 'expand_more' : 'chevron_right'}}\r\n </mat-icon>\r\n </button>\r\n <div fxFlex=\"*\" fxFlexAlign=\"center\">{{node.name}}</div>\r\n </div>\r\n </mat-tree-node>\r\n </mat-tree>\r\n </div>\r\n </div>\r\n </mat-drawer>\r\n <mat-drawer-content id=\"helpviewer-scroller\">\r\n <div style=\"padding: 0 24px;\">\r\n <div fxLayout=\"column\" fxFill>\r\n <div class=\"fill\" (click)=\"gotoChapter($event)\" [innerHtml]=\"(page() ?? '') | safeHtml\"></div>\r\n </div>\r\n </div>\r\n </mat-drawer-content>\r\n </mat-drawer-container>\r\n</mat-dialog-content>", styles: [".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-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}.wide{min-width:100%!important;max-width:100%!important;width:100%!important}.fill{min-width:100%!important;max-width:100%!important;width:100%!important;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}.smaller{font-size:smaller!important}.small{font-size:small!important;line-height:16px!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:14px!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-small .title-container{padding:20px 5px 20px 0}.drawer .title-container-with-loader,.drawer-small .title-container-with-loader{padding:14px 5px 20px 0}.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}}@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{font-weight:600}}.dialog-menu{margin-top:4px!important}.tree{overflow-x:hidden}.tree-node{min-height:36px!important;padding-right:12px;margin-right:0}.tree-node .small-icon-button{width:2rem!important;height:2rem!important;padding:0!important;display:inline-flex!important;align-items:center;justify-content:center}.tree-node .small-icon-button .mat-mdc-button-touch-target{width:2rem!important;height:2rem!important}.tree-node:hover{cursor:pointer;background-color:var(--mat-menu-item-hover-state-layer-color, transparent);border-radius:24px}.tree-node-simple,.tree-node-simple>div{min-height:36px!important}.tree-node-activated,.tree-node-activated>div{min-height:36px!important;font-weight:700!important;color:var(--ars-color-accent, #7894ae)!important}a.help-link,.help-link>a{text-decoration:none;color:#2a91e0}.help-title-2,.help-title-1{font-weight:600!important}.help-word-hit{font-size:inherit;background-color:var(--ars-word-hit-background-color, yellow);padding:0 4px}.help-hint{margin:10px;padding:5px 20px;background-color:var(--ars-help-hint-background-color, lightgoldenrodyellow);border-radius:12px}.help-summary{margin:10px;padding:5px 20px;background-color:var(--ars-help-summary-background-color, lavender);border-radius:12px}.help-img{display:flex;align-items:center;justify-content:center;margin:10px}.help-img-200,.help-img-300,.help-img-400,.help-img-500,.help-img-700,.help-img-800{width:100%}.help-img-200{max-width:200px}.help-img-300{max-width:300px}.help-img-400{max-width:400px}.help-img-500{max-width:500px}.help-img-600{max-width:600px}.help-img-700{max-width:700px}.help-img-800{max-width:800px}.help-filter-box{background-color:var(--ars-filterbox-filtered-background-color, #f9fbe7);border-radius:12px;padding:6px;display:inline-block;margin:0 0 8px 10px}.mat-mdc-dialog-content{max-height:unset!important;padding:0!important}\n"] }]
@@ -503,10 +503,10 @@ class HelpService {
503
503
  height: '100%'
504
504
  });
505
505
  }
506
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: HelpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
507
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: HelpService, providedIn: 'root' }); }
506
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HelpService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
507
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HelpService, providedIn: 'root' }); }
508
508
  }
509
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: HelpService, decorators: [{
509
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HelpService, decorators: [{
510
510
  type: Injectable,
511
511
  args: [{
512
512
  providedIn: 'root'
@@ -514,11 +514,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
514
514
  }] });
515
515
 
516
516
  class ArsHelpModule {
517
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsHelpModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
518
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.0", ngImport: i0, type: ArsHelpModule }); }
519
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsHelpModule }); }
517
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsHelpModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
518
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.1", ngImport: i0, type: ArsHelpModule }); }
519
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsHelpModule }); }
520
520
  }
521
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsHelpModule, decorators: [{
521
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsHelpModule, decorators: [{
522
522
  type: NgModule
523
523
  }] });
524
524
 
@@ -142,6 +142,7 @@ class SupportService {
142
142
  if (!tokenExpired || this.loggedIn()) {
143
143
  // Auto login
144
144
  this.loggedIn.set(true);
145
+ this.loggingIn.set(false);
145
146
  // Keep alive
146
147
  this.setKeepAlive();
147
148
  // Notify
@@ -248,8 +249,7 @@ class SupportService {
248
249
  : new HttpHeaders()
249
250
  .set("Authorization", oauthAccessToken ?? '')
250
251
  })
251
- .pipe(catchError(err => {
252
- this.loggingIn.set(false);
252
+ .pipe(finalize(() => this.loggingIn.set(false)), catchError(err => {
253
253
  return throwError(() => err);
254
254
  }), map((r) => {
255
255
  if (r.success) {
@@ -292,8 +292,7 @@ class SupportService {
292
292
  confirmIdentity(code, flags = SupportLoginFlags.None) {
293
293
  return this.httpClient
294
294
  .post(this._serviceUri + '/login/confirm/' + code + '/?flags=' + flags, {})
295
- .pipe(catchError((err) => {
296
- this.loggingIn.set(false);
295
+ .pipe(finalize(() => this.loggingIn.set(false)), catchError((err) => {
297
296
  return throwError(() => err);
298
297
  }), map((r) => {
299
298
  if (r.success) {
@@ -400,10 +399,10 @@ class SupportService {
400
399
  dowloadNotificationDocument(documentId) {
401
400
  return this.httpClient.get(this._serviceUri + '/documents/download/' + documentId, { responseType: 'blob' });
402
401
  }
403
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
404
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportService, providedIn: 'root' }); }
402
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
403
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportService, providedIn: 'root' }); }
405
404
  }
406
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportService, decorators: [{
405
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportService, decorators: [{
407
406
  type: Injectable,
408
407
  args: [{
409
408
  providedIn: 'root',
@@ -496,19 +495,19 @@ class SupportAuthInterceptor {
496
495
  }
497
496
  return request;
498
497
  }
499
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportAuthInterceptor, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
500
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportAuthInterceptor }); }
498
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportAuthInterceptor, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
499
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportAuthInterceptor }); }
501
500
  }
502
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: SupportAuthInterceptor, decorators: [{
501
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: SupportAuthInterceptor, decorators: [{
503
502
  type: Injectable
504
503
  }] });
505
504
 
506
505
  class ArsSupportCommonModule {
507
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsSupportCommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
508
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.0", ngImport: i0, type: ArsSupportCommonModule }); }
509
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsSupportCommonModule }); }
506
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsSupportCommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
507
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.1", ngImport: i0, type: ArsSupportCommonModule }); }
508
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsSupportCommonModule }); }
510
509
  }
511
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: ArsSupportCommonModule, decorators: [{
510
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: ArsSupportCommonModule, decorators: [{
512
511
  type: NgModule
513
512
  }] });
514
513
 
@@ -1 +1 @@
1
- {"version":3,"file":"arsedizioni-ars-utils-support.common.mjs","sources":["../../../projects/ars-utils/support.common/common/messages.ts","../../../projects/ars-utils/support.common/common/definitions.ts","../../../projects/ars-utils/support.common/common/services/support.service.ts","../../../projects/ars-utils/support.common/common/interceptors/auth.interceptor.ts","../../../projects/ars-utils/support.common/common/common.module.ts","../../../projects/ars-utils/support.common/public_api.ts","../../../projects/ars-utils/support.common/arsedizioni-ars-utils-support.common.ts"],"sourcesContent":["export const SupportMessages = {\r\n /**\r\n * Messages\r\n */\r\n // Error\r\n ERROR: '§support-error',\r\n\r\n // Login\r\n LOGIN_CHANGED: '§support-login-changed',\r\n LOGIN_COMPLETED: '§support-login-completed',\r\n LOGOUT_COMPLETED: '§support-logout-completed',\r\n LOGIN_PENDING: '§support-login-pending',\r\n LOGOUT: '§support-logout',\r\n\r\n // Notifications\r\n NOTIFICATION_READ: '§support-notification-read',\r\n};\r\n","import { LoginResult } from '@arsedizioni/ars-utils/core';\r\nimport { LoginOAuthType } from '@arsedizioni/ars-utils/ui.oauth';\r\n\r\nexport enum SupportServiceFlags {\r\n None = 0,\r\n NotifySystemErrors = 1,\r\n DisplayConnectionStateMessages = 1 << 1\r\n}\r\n\r\nexport interface SupportUserInfo {\r\n id: number;\r\n groups?: number;\r\n groupNames?: string;\r\n displayName?: string;\r\n dashboard?: string;\r\n sessionId?: string;\r\n email?: string;\r\n customerId?: number;\r\n companyName?: string;\r\n role: number;\r\n scopes?: string[];\r\n sla: number;\r\n isCommercial?: boolean;\r\n isAdministrator: boolean;\r\n isGuest: boolean;\r\n isUser: boolean;\r\n isOperator: boolean;\r\n isTemporary: boolean;\r\n}\r\n\r\nexport enum SupportLoginFlags {\r\n None = 0,\r\n RememberCredentials = 1,\r\n DisableMfa = 1 << 1,\r\n ExtendMfaValidity = 1 << 2,\r\n ExtendRememberCredentialsValidity = 1 << 3,\r\n}\r\n\r\nexport interface SupportLoginResult extends LoginResult<SupportUserInfo> {\r\n\r\n // Compatibilty\r\n token?: string;\r\n\r\n}\r\n\r\nexport interface SupportLoginInfo {\r\n context: SupportUserInfo;\r\n oauth?: LoginOAuthType;\r\n remember?: boolean;\r\n}\r\n\r\nexport interface SupportNotificationsSearchParams {\r\n any?: string;\r\n products?: number;\r\n productModules?: number;\r\n first?: number;\r\n count?: number;\r\n}\r\n\r\nexport interface SupportNotificationsSearchResult {\r\n interval?: string;\r\n items?: SupportNotificationInfo[];\r\n total?: number;\r\n}\r\n\r\nexport interface Notification {\r\n id: number;\r\n products: number;\r\n productModules?: number;\r\n publishingDate?: Date;\r\n title: string;\r\n text: string;\r\n state: number;\r\n created: Date;\r\n createdBy: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n productNames?: string;\r\n productModuleNames?: string;\r\n isPublished: boolean;\r\n isInternal: boolean;\r\n stateName: string;\r\n documents?: Document[];\r\n isRead: boolean;\r\n totalRead: number;\r\n}\r\n\r\nexport interface SupportDocumentInfo {\r\n id: number;\r\n origin?: number;\r\n ownerId?: number;\r\n name?: string;\r\n description?: string;\r\n size?: number;\r\n binaryId?: number;\r\n url?: string;\r\n customerId?: number;\r\n created?: Date;\r\n createdBy?: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n isBinary?: boolean;\r\n}\r\n\r\nexport interface SupportNotificationInfo {\r\n id: number;\r\n products?: number;\r\n productModules?: number;\r\n publishingDate?: Date;\r\n title: string;\r\n text: string;\r\n state: number;\r\n created: Date;\r\n createdBy: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n productNames?: string;\r\n productModuleNames?: string;\r\n isPublished: boolean;\r\n isInternal: boolean;\r\n stateName: string;\r\n documents?: Document[];\r\n isRead: boolean;\r\n totalRead: number;\r\n isMenuOpen?: boolean;\r\n isOver?: boolean;\r\n\r\n}\r\n\r\nexport interface SupportNotificationsMarkParams {\r\n ids: number[];\r\n unmark: boolean;\r\n}\r\n\r\nexport enum SupportProduct {\r\n None = 0,\r\n Clipper = 1,\r\n Evolution = 1 << 1,\r\n DGInfo = 1 << 2\r\n}\r\n\r\nexport enum SupportProductModule {\r\n None = 0,\r\n EvoFormazione = 1,\r\n EvoDPI = 1 << 1,\r\n EvoSorveglianzaSanitaria = 1 << 2,\r\n EvoRegistroEScadenzario = 1 << 3,\r\n EvoAttrezzatureEImpianti = 1 << 4,\r\n EvoMonitoraggio = 1 << 5,\r\n EvoBollettino = 1 << 6,\r\n DgiADR = 1 << 7,\r\n DgiRID = 1 << 8,\r\n DgiIMDG = 1 << 9,\r\n DgiCLP = 1 << 10,\r\n}\r\n","import { HttpClient, HttpHeaders } from '@angular/common/http';\r\nimport { Injectable, OnDestroy, inject, signal } from '@angular/core';\r\nimport { ApiResult, BroadcastMessageInfo, BroadcastService, SystemUtils } from '@arsedizioni/ars-utils/core';\r\nimport { EMPTY, of, Subscription, throwError } from 'rxjs';\r\nimport { catchError, finalize, map } from 'rxjs/operators';\r\nimport { SupportMessages } from '../messages';\r\nimport { SupportLoginFlags, SupportLoginInfo, SupportLoginResult, SupportNotificationInfo, SupportNotificationsMarkParams, SupportNotificationsSearchParams, SupportNotificationsSearchResult, SupportProduct, SupportProductModule, SupportServiceFlags } from '../definitions';\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class SupportService implements OnDestroy {\r\n\r\n\r\n private httpClient = inject(HttpClient);\r\n private broadcastService = inject(BroadcastService);\r\n private broadcastServiceSubscription?: Subscription;\r\n private _loginInfo?: SupportLoginInfo;\r\n get loginInfo(): SupportLoginInfo | undefined { return this._loginInfo };\r\n set loginInfo(value: SupportLoginInfo | undefined) {\r\n this._loginInfo = value;\r\n }\r\n\r\n private _serviceUri: string = \"https://support.arsedizioni.it\"\r\n get serviceUri(): string {\r\n return this._serviceUri;\r\n }\r\n private _flags: SupportServiceFlags = SupportServiceFlags.None;\r\n get flags(): SupportServiceFlags {\r\n return this._flags;\r\n }\r\n\r\n public products: SupportProduct = SupportProduct.None;\r\n public productModules: SupportProductModule = SupportProductModule.None;\r\n\r\n public readonly unreadNotifications = signal<number | undefined>(undefined);\r\n public readonly loggedIn = signal<boolean>(false);\r\n public readonly loggingIn = signal<boolean>(false);\r\n private keepAlive = 0;\r\n\r\n ngOnDestroy() {\r\n // Clean-up\r\n if (this.broadcastServiceSubscription) {\r\n this.broadcastServiceSubscription.unsubscribe();\r\n }\r\n // Stop keep alive\r\n this.removeKeepAlive();\r\n }\r\n\r\n /**\r\n * Initialize service\r\n * @param serviceUri : the service uri\r\n * @param products: the supported products\r\n * @param productModules: the supported product modules\r\n * @param flags: the service flags. Default is none.\r\n */\r\n initialize(\r\n serviceUri: string,\r\n products: SupportProduct = SupportProduct.None,\r\n productModules: SupportProductModule = SupportProductModule.None,\r\n flags: SupportServiceFlags = SupportServiceFlags.None) {\r\n\r\n // Create unique client id\r\n if (!localStorage.getItem('support_client_id')) {\r\n localStorage.setItem('support_client_id', SystemUtils.generateUUID());\r\n }\r\n\r\n // Initialize\r\n this._serviceUri = serviceUri;\r\n this._flags = flags;\r\n this.products = products;\r\n this.productModules = productModules;\r\n\r\n // React to message broadcasting\r\n if (!this.broadcastServiceSubscription) {\r\n this.broadcastServiceSubscription = this.broadcastService.getMessage().subscribe((message: BroadcastMessageInfo) => {\r\n if (message.id === SupportMessages.LOGIN_CHANGED) {\r\n this.login(message.data.email, message.data.oauth, message.data.oauthAccessToken,\r\n SupportLoginFlags.DisableMfa |\r\n SupportLoginFlags.RememberCredentials |\r\n SupportLoginFlags.ExtendRememberCredentialsValidity).subscribe({\r\n next: r => {\r\n if (r.success) {\r\n this.countUnreadNotifications();\r\n }\r\n }, error: () => { console.error(\"ARS Support non disponibile.\") } // Avoid unwanted errors on client);\r\n });\r\n } else if (message.id === SupportMessages.LOGOUT) {\r\n if (this.loggedIn()) {\r\n this.logout()\r\n .pipe(finalize(() => this.clear()))\r\n .subscribe();\r\n } else {\r\n this.clear();\r\n }\r\n } else if (message.id === SupportMessages.NOTIFICATION_READ) {\r\n this.countUnreadNotifications();\r\n }\r\n });\r\n }\r\n\r\n // Eveluate current session storage in case of page refresh (F5)\r\n const tokenExpirationDate = this.getTokenExpirationDate();\r\n const tokenExpired = !tokenExpirationDate || tokenExpirationDate.getTime() < Date.now();\r\n if (!tokenExpired || this.loggedIn()) {\r\n // Auto login\r\n this.loggedIn.set(true);\r\n // Keep alive\r\n this.setKeepAlive();\r\n // Notify \r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_COMPLETED);\r\n }\r\n }\r\n\r\n /**\r\n * Get access token expiration date\r\n */\r\n private getTokenExpirationDate(): Date | undefined {\r\n const token = this.getAuthToken();\r\n if (!token || token.length === 0) return undefined;\r\n // Parse json object from base64 encoded jwt token\r\n const jwtToken = JSON.parse(atob(token.split('.')[1]));\r\n // Set a timeout to refresh the token a minute before it expires\r\n return new Date(jwtToken.exp * 1000);\r\n }\r\n\r\n\r\n /**\r\n * Set keep alive\r\n */\r\n private setKeepAlive() {\r\n // Keep alive every 1 min\r\n if (this.keepAlive === 0) {\r\n this.keepAlive = window.setInterval(\r\n () => {\r\n this.ping();\r\n }, 1000 * 60 * 5);\r\n }\r\n }\r\n\r\n /**\r\n * Remove keep alive\r\n */\r\n private removeKeepAlive() {\r\n if (this.keepAlive > 0) {\r\n window.clearInterval(this.keepAlive);\r\n this.keepAlive = 0;\r\n }\r\n }\r\n\r\n /**\r\n * Ping\r\n */\r\n ping() {\r\n this.httpClient.get<ApiResult<number>>(\r\n this._serviceUri + '/ping?nocache=' + SystemUtils.generateUUID()\r\n )\r\n .pipe(catchError(() => { return EMPTY }))\r\n .subscribe();\r\n }\r\n\r\n /**\r\n * Set JWT token\r\n * @param value : the login result\r\n */\r\n private setToken(value: SupportLoginResult) {\r\n if (value.authToken ?? value.token) {\r\n sessionStorage.setItem('support_auth', value.authToken ?? value.token);\r\n }\r\n }\r\n\r\n\r\n /**\r\n * Return current JWT token\r\n */\r\n getAuthToken(): string | undefined {\r\n let token = sessionStorage.getItem('support_auth');\r\n if (token && token[0] === '\"') {\r\n return token.substring(1, token.length - 1);\r\n }\r\n return token;\r\n }\r\n\r\n\r\n /**\r\n * Store context\r\n */\r\n storeContext() {\r\n localStorage.setItem('support_context', JSON.stringify(this._loginInfo));\r\n }\r\n\r\n /**\r\n* Update context\r\n* @param result: the new context\r\n*/\r\n updateContext(result: SupportLoginResult) {\r\n if (!this._loginInfo) {\r\n this._loginInfo = {context: undefined};\r\n }\r\n this._loginInfo.context = result.context;\r\n this.setToken(result);\r\n this.storeContext();\r\n\r\n }\r\n\r\n /**\r\n* Perform login \r\n* @param email: the guest email\r\n* @param oauth: the optional open authentication supported\r\n* @param oauthAccessToken: the optional oauth2 access token\r\n* @returns: the login result\r\n*/\r\n login(email?: string,\r\n oauth?: number,\r\n oauthAccessToken?: string,\r\n flags: SupportLoginFlags | undefined = SupportLoginFlags.RememberCredentials) { \r\n if (!flags) {\r\n flags = SupportLoginFlags.RememberCredentials;\r\n }\r\n return this.httpClient\r\n .post<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/login',\r\n {\r\n clientId: localStorage.getItem(\"support_client_id\"),\r\n user: oauth > 0 ? undefined : email, \r\n oauth: oauth,\r\n flags: flags\r\n },\r\n {\r\n headers:\r\n !oauth\r\n ? new HttpHeaders()\r\n : new HttpHeaders()\r\n .set(\"Authorization\", oauthAccessToken ?? '')\r\n })\r\n .pipe(\r\n catchError(err => {\r\n this.loggingIn.set(false);\r\n return throwError(() => err);\r\n }),\r\n map((r: ApiResult<SupportLoginResult>) => {\r\n if (r.success) {\r\n if (!this._loginInfo) {\r\n this._loginInfo = {context: undefined}\r\n }\r\n this._loginInfo.oauth = oauth;\r\n this._loginInfo.remember = true;\r\n if (!oauth && r.value.requiresMfa) {\r\n // Notify login is pending\r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_PENDING, { flags: flags });\r\n } else {\r\n // Complete login\r\n this.completeLogin(r.value);\r\n }\r\n }\r\n return r;\r\n })\r\n );\r\n\r\n }\r\n\r\n /**\r\n * Complete login\r\n * @param result : the login result\r\n */\r\n private completeLogin(\r\n result: SupportLoginResult) {\r\n // Update context info \r\n this.updateContext(result);\r\n this.loggedIn.set(!result.context?.isTemporary);\r\n this.loggingIn.set(false);\r\n // Keep alive\r\n this.setKeepAlive();\r\n // Notify\r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_COMPLETED);\r\n }\r\n\r\n /**\r\n * Confirm MFA procedure\r\n * @param code: the confirm code\r\n * @param flags: the login flags\r\n */\r\n confirmIdentity(code: string, flags: number = SupportLoginFlags.None) {\r\n return this.httpClient\r\n .post<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/login/confirm/' + code + '/?flags=' + flags,\r\n {},\r\n )\r\n .pipe(\r\n catchError((err) => {\r\n this.loggingIn.set(false);\r\n return throwError(() => err);\r\n }),\r\n map((r: ApiResult<SupportLoginResult>) => {\r\n if (r.success) {\r\n // Complete login\r\n this.completeLogin(r.value);\r\n }\r\n return r;\r\n }),\r\n );\r\n }\r\n\r\n /**\r\n * Perform logout\r\n */\r\n logout() {\r\n return this.httpClient\r\n .post(this._serviceUri + '/logout', {}).pipe(\r\n finalize(() => {\r\n this.removeKeepAlive();\r\n this.clear();\r\n // Clean up\r\n localStorage.removeItem('support_context');\r\n }),\r\n catchError((_e) => {\r\n return of([]);\r\n }));\r\n\r\n }\r\n\r\n /**\r\n * Reset login refresh timer and logins state\r\n */\r\n reset() {\r\n // Clear login info\r\n this._loginInfo = undefined;\r\n this.loggedIn.set(false);\r\n // Notify\r\n this.broadcastService.sendMessage(SupportMessages.LOGOUT_COMPLETED);\r\n }\r\n\r\n /**\r\n * Clear login data\r\n */\r\n clear() {\r\n // Reset login\r\n this.reset();\r\n // Clear local storage\r\n sessionStorage.removeItem('support_auth');\r\n }\r\n\r\n /**\r\n * Perform token refresh\r\n */\r\n refresh() {\r\n return this.httpClient.get<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/refresh2'\r\n ).pipe(map((r: ApiResult<SupportLoginResult>) => {\r\n // Update token\r\n this.setToken(r.value);\r\n return r;\r\n }));\r\n }\r\n\r\n /**\r\n * Navigate to support service\r\n */\r\n open() {\r\n let uri = this.serviceUri ?? '';\r\n if (uri.endsWith('/api'))\r\n uri = uri.substring(0, uri.length - 4)\r\n window.open(uri);\r\n }\r\n\r\n\r\n ////\r\n // NOTIFICATIONS\r\n ////\r\n\r\n /**\r\n * Count unread notifications\r\n */\r\n countUnreadNotifications() {\r\n this.httpClient.get<ApiResult<number>>(\r\n this._serviceUri + '/notifications/count-unread/?products=' + (this.products ?? 0) + \"&modules=\" + (this.productModules ?? 0)\r\n ).subscribe((r: ApiResult<number>) => {\r\n if (r.success) {\r\n this.unreadNotifications.set(r.value > 0 ? r.value : undefined)\r\n }\r\n });\r\n }\r\n\r\n /**\r\n * Query notifications\r\n * @param params: query parameters\r\n */\r\n queryNotifications(params: SupportNotificationsSearchParams) {\r\n params.products = this.products ?? 0;\r\n params.productModules = this.productModules ?? 0;\r\n return this.httpClient.post<ApiResult<SupportNotificationsSearchResult>>(\r\n this._serviceUri + '/notifications',\r\n params\r\n );\r\n }\r\n\r\n /**\r\n * Retrieve a notification\r\n * @param id: the notification id\r\n */\r\n getNotification(id: number) {\r\n return this.httpClient.get<ApiResult<SupportNotificationInfo>>(\r\n this._serviceUri +\r\n '/notifications/' +\r\n id\r\n );\r\n }\r\n\r\n /**\r\n * Mark a group of notifications as read\r\n * @param ids: the array of notification's ids to set as read\r\n */\r\n markNotifications(params: SupportNotificationsMarkParams) {\r\n return this.httpClient.post<ApiResult<boolean>>(\r\n this._serviceUri + '/notifications/mark',\r\n params\r\n );\r\n }\r\n\r\n /**\r\n * Download a notification document\r\n * @param documentId : the notification document id\r\n */\r\n dowloadNotificationDocument(documentId: number) {\r\n return this.httpClient.get(\r\n this._serviceUri + '/documents/download/' + documentId,\r\n { responseType: 'blob' }\r\n );\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable, inject } from '@angular/core';\r\nimport { Observable, catchError, switchMap, throwError } from 'rxjs';\r\nimport { SupportService } from '../services/support.service';\r\nimport { BroadcastService, ErrorInfo } from '@arsedizioni/ars-utils/core';\r\nimport { SupportServiceFlags } from '../definitions';\r\nimport { SupportMessages } from '../messages';\r\n\r\n@Injectable()\r\nexport class SupportAuthInterceptor implements HttpInterceptor {\r\n\r\n private supportService = inject(SupportService);\r\n private broadcastService = inject(BroadcastService);\r\n private lastErrorTime: number = -1;\r\n\r\n intercept(\r\n request: HttpRequest<any>,\r\n next: HttpHandler\r\n ): Observable<HttpEvent<any>> {\r\n if (request.url.startsWith(this.supportService.serviceUri)) {\r\n request = request.clone({ withCredentials: true });\r\n return next.handle(this.addTokenToRequest(request))\r\n .pipe(\r\n catchError(error => {\r\n if (error.url.startsWith(this.supportService.serviceUri)) {\r\n if (\r\n error instanceof HttpErrorResponse &&\r\n !request.url.includes(\"/login\") &&\r\n error.status === 401\r\n ) {\r\n return this.handle401Error(request, next);\r\n }\r\n const errorStatus = parseInt(error.status ?? \"0\");\r\n if ((errorStatus > 0 && errorStatus < 500) || (this.supportService.flags & SupportServiceFlags.NotifySystemErrors) > 0) {\r\n const errorTime = new Date().getTime();\r\n if (errorTime - this.lastErrorTime > 5000) {\r\n this.lastErrorTime = errorTime;\r\n let message = \"\"\r\n switch (errorStatus) {\r\n case 0:\r\n message = \"In questo momento ARS Support non è disponibile. Riprova tra qualche minuto.\";\r\n break;\r\n case 403:\r\n message = \"Non hai i permessi necessari per eseguire l'operazione richiesta.\";\r\n break;\r\n default:\r\n message = (error.error?.message ?? error.message ?? \"Impossibile eseguire l'operazione richiesta.\").replaceAll(\"\\r\\n\", \"</p><p>\");\r\n break;\r\n }\r\n this.broadcastService.sendMessage(\r\n SupportMessages.ERROR,\r\n {\r\n invalidateSession: errorStatus === 405 || errorStatus === 410,\r\n message: message,\r\n title: \"Errore in ARS Support\",\r\n errorStatus: errorStatus,\r\n service: this.supportService.serviceUri\r\n } as ErrorInfo);\r\n }\r\n }\r\n }\r\n return throwError(() => error);\r\n }));\r\n }\r\n return next.handle(request);\r\n }\r\n\r\n /**\r\n * Handle 401 error\r\n * @param request : the request\r\n * @param next : the http handler\r\n */\r\n private handle401Error(request: HttpRequest<any>, next: HttpHandler) {\r\n if (this.supportService.loggedIn()) {\r\n return this.supportService.refresh().pipe(\r\n switchMap(() => {\r\n return next.handle(this.addTokenToRequest(request));\r\n }),\r\n catchError(error => {\r\n return throwError(() => error);\r\n })\r\n );\r\n }\r\n return next.handle(request);\r\n }\r\n\r\n /**\r\n * Add token to request\r\n * @param request : the request\r\n * @param token: the token or null to use curre3nt\r\n */\r\n private addTokenToRequest(\r\n request: HttpRequest<any>,\r\n token: string = null\r\n ): HttpRequest<any> {\r\n if (request.url.startsWith(this.supportService.serviceUri)) {\r\n if (this.supportService.loggedIn()) {\r\n if (!token) token = this.supportService.getAuthToken();\r\n if (token) {\r\n return request.clone({\r\n setHeaders: {\r\n Authorization: 'Bearer ' + token,\r\n 'ngsw-bypass': 'ngsw-bypass'\r\n },\r\n });\r\n }\r\n }\r\n }\r\n return request;\r\n }\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\n\r\n@NgModule()\r\nexport class ArsSupportCommonModule {}\r\n\r\n// Other exports\r\nexport * from './messages';\r\nexport * from './definitions';\r\nexport * from './interceptors/auth.interceptor';\r\nexport * from './services/support.service';\r\n","/*\r\n * Public API Surface of ars-utils\r\n */\r\nexport * from './common/common.module';\r\nexport * from './common/messages';\r\nexport * from './common/definitions';\r\nexport * from './common/services/support.service';\r\n\r\n\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["catchError"],"mappings":";;;;;;;AAAO,MAAM,eAAe,GAAG;AAC7B;;AAEG;;AAEH,IAAA,KAAK,EAAE,gBAAgB;;AAGvB,IAAA,aAAa,EAAE,wBAAwB;AACvC,IAAA,eAAe,EAAE,0BAA0B;AAC3C,IAAA,gBAAgB,EAAE,2BAA2B;AAC7C,IAAA,aAAa,EAAE,wBAAwB;AACvC,IAAA,MAAM,EAAE,iBAAiB;;AAGzB,IAAA,iBAAiB,EAAE,4BAA4B;;;ICZrC;AAAZ,CAAA,UAAY,mBAAmB,EAAA;AAC3B,IAAA,mBAAA,CAAA,mBAAA,CAAA,MAAA,CAAA,GAAA,CAAA,CAAA,GAAA,MAAQ;AACR,IAAA,mBAAA,CAAA,mBAAA,CAAA,oBAAA,CAAA,GAAA,CAAA,CAAA,GAAA,oBAAsB;AACtB,IAAA,mBAAA,CAAA,mBAAA,CAAA,gCAAA,CAAA,GAAA,CAAA,CAAA,GAAA,gCAAuC;AAC3C,CAAC,EAJW,mBAAmB,KAAnB,mBAAmB,GAAA,EAAA,CAAA,CAAA;IA2BnB;AAAZ,CAAA,UAAY,iBAAiB,EAAA;AACzB,IAAA,iBAAA,CAAA,iBAAA,CAAA,MAAA,CAAA,GAAA,CAAA,CAAA,GAAA,MAAQ;AACR,IAAA,iBAAA,CAAA,iBAAA,CAAA,qBAAA,CAAA,GAAA,CAAA,CAAA,GAAA,qBAAuB;AACvB,IAAA,iBAAA,CAAA,iBAAA,CAAA,YAAA,CAAA,GAAA,CAAA,CAAA,GAAA,YAAmB;AACnB,IAAA,iBAAA,CAAA,iBAAA,CAAA,mBAAA,CAAA,GAAA,CAAA,CAAA,GAAA,mBAA0B;AAC1B,IAAA,iBAAA,CA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IAAI,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,IAAI,CAAC,cAAc,CAAC,UAAU,CAAC,EAAE;AAC1D,YAAA,IAAI,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,EAAE;AAClC,gBAAA,IAAI,CAAC,KAAK;AAAE,oBAAA,KAAK,GAAG,IAAI,CAAC,cAAc,CAAC,YAAY,EAAE;gBACtD,IAAI,KAAK,EAAE;oBACT,OAAO,OAAO,CAAC,KAAK,CAAC;AACnB,wBAAA,UAAU,EAAE;4BACV,aAAa,EAAE,SAAS,GAAG,KAAK;AAChC,4BAAA,aAAa,EAAE;AAChB,yBAAA;AACF,qBAAA,CAAC;gBACJ;YACF;QACF;AACA,QAAA,OAAO,OAAO;IAChB;8GApGW,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;kHAAtB,sBAAsB,EAAA,CAAA,CAAA;;2FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBADlC;;;MCLY,sBAAsB,CAAA;8GAAtB,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAtB,sBAAsB,EAAA,CAAA,CAAA;+GAAtB,sBAAsB,EAAA,CAAA,CAAA;;2FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBADlC;;;ACFD;;AAEG;;ACFH;;AAEG;;;;"}
1
+ {"version":3,"file":"arsedizioni-ars-utils-support.common.mjs","sources":["../../../projects/ars-utils/support.common/common/messages.ts","../../../projects/ars-utils/support.common/common/definitions.ts","../../../projects/ars-utils/support.common/common/services/support.service.ts","../../../projects/ars-utils/support.common/common/interceptors/auth.interceptor.ts","../../../projects/ars-utils/support.common/common/common.module.ts","../../../projects/ars-utils/support.common/public_api.ts","../../../projects/ars-utils/support.common/arsedizioni-ars-utils-support.common.ts"],"sourcesContent":["export const SupportMessages = {\r\n /**\r\n * Messages\r\n */\r\n // Error\r\n ERROR: '§support-error',\r\n\r\n // Login\r\n LOGIN_CHANGED: '§support-login-changed',\r\n LOGIN_COMPLETED: '§support-login-completed',\r\n LOGOUT_COMPLETED: '§support-logout-completed',\r\n LOGIN_PENDING: '§support-login-pending',\r\n LOGOUT: '§support-logout',\r\n\r\n // Notifications\r\n NOTIFICATION_READ: '§support-notification-read',\r\n};\r\n","import { LoginResult } from '@arsedizioni/ars-utils/core';\r\nimport { LoginOAuthType } from '@arsedizioni/ars-utils/ui.oauth';\r\n\r\nexport enum SupportServiceFlags {\r\n None = 0,\r\n NotifySystemErrors = 1,\r\n DisplayConnectionStateMessages = 1 << 1\r\n}\r\n\r\nexport interface SupportUserInfo {\r\n id: number;\r\n groups?: number;\r\n groupNames?: string;\r\n displayName?: string;\r\n dashboard?: string;\r\n sessionId?: string;\r\n email?: string;\r\n customerId?: number;\r\n companyName?: string;\r\n role: number;\r\n scopes?: string[];\r\n sla: number;\r\n isCommercial?: boolean;\r\n isAdministrator: boolean;\r\n isGuest: boolean;\r\n isUser: boolean;\r\n isOperator: boolean;\r\n isTemporary: boolean;\r\n}\r\n\r\nexport enum SupportLoginFlags {\r\n None = 0,\r\n RememberCredentials = 1,\r\n DisableMfa = 1 << 1,\r\n ExtendMfaValidity = 1 << 2,\r\n ExtendRememberCredentialsValidity = 1 << 3,\r\n}\r\n\r\nexport interface SupportLoginResult extends LoginResult<SupportUserInfo> {\r\n\r\n // Compatibilty\r\n token?: string;\r\n\r\n}\r\n\r\nexport interface SupportLoginInfo {\r\n context: SupportUserInfo;\r\n oauth?: LoginOAuthType;\r\n remember?: boolean;\r\n}\r\n\r\nexport interface SupportNotificationsSearchParams {\r\n any?: string;\r\n products?: number;\r\n productModules?: number;\r\n first?: number;\r\n count?: number;\r\n}\r\n\r\nexport interface SupportNotificationsSearchResult {\r\n interval?: string;\r\n items?: SupportNotificationInfo[];\r\n total?: number;\r\n}\r\n\r\nexport interface Notification {\r\n id: number;\r\n products: number;\r\n productModules?: number;\r\n publishingDate?: Date;\r\n title: string;\r\n text: string;\r\n state: number;\r\n created: Date;\r\n createdBy: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n productNames?: string;\r\n productModuleNames?: string;\r\n isPublished: boolean;\r\n isInternal: boolean;\r\n stateName: string;\r\n documents?: Document[];\r\n isRead: boolean;\r\n totalRead: number;\r\n}\r\n\r\nexport interface SupportDocumentInfo {\r\n id: number;\r\n origin?: number;\r\n ownerId?: number;\r\n name?: string;\r\n description?: string;\r\n size?: number;\r\n binaryId?: number;\r\n url?: string;\r\n customerId?: number;\r\n created?: Date;\r\n createdBy?: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n isBinary?: boolean;\r\n}\r\n\r\nexport interface SupportNotificationInfo {\r\n id: number;\r\n products?: number;\r\n productModules?: number;\r\n publishingDate?: Date;\r\n title: string;\r\n text: string;\r\n state: number;\r\n created: Date;\r\n createdBy: string;\r\n lastUpdated?: Date;\r\n lastUpdatedBy?: string;\r\n productNames?: string;\r\n productModuleNames?: string;\r\n isPublished: boolean;\r\n isInternal: boolean;\r\n stateName: string;\r\n documents?: Document[];\r\n isRead: boolean;\r\n totalRead: number;\r\n isMenuOpen?: boolean;\r\n isOver?: boolean;\r\n\r\n}\r\n\r\nexport interface SupportNotificationsMarkParams {\r\n ids: number[];\r\n unmark: boolean;\r\n}\r\n\r\nexport enum SupportProduct {\r\n None = 0,\r\n Clipper = 1,\r\n Evolution = 1 << 1,\r\n DGInfo = 1 << 2\r\n}\r\n\r\nexport enum SupportProductModule {\r\n None = 0,\r\n EvoFormazione = 1,\r\n EvoDPI = 1 << 1,\r\n EvoSorveglianzaSanitaria = 1 << 2,\r\n EvoRegistroEScadenzario = 1 << 3,\r\n EvoAttrezzatureEImpianti = 1 << 4,\r\n EvoMonitoraggio = 1 << 5,\r\n EvoBollettino = 1 << 6,\r\n DgiADR = 1 << 7,\r\n DgiRID = 1 << 8,\r\n DgiIMDG = 1 << 9,\r\n DgiCLP = 1 << 10,\r\n}\r\n","import { HttpClient, HttpHeaders } from '@angular/common/http';\r\nimport { Injectable, OnDestroy, inject, signal } from '@angular/core';\r\nimport { ApiResult, BroadcastMessageInfo, BroadcastService, SystemUtils } from '@arsedizioni/ars-utils/core';\r\nimport { EMPTY, of, Subscription, throwError } from 'rxjs';\r\nimport { catchError, finalize, map } from 'rxjs/operators';\r\nimport { SupportMessages } from '../messages';\r\nimport { SupportLoginFlags, SupportLoginInfo, SupportLoginResult, SupportNotificationInfo, SupportNotificationsMarkParams, SupportNotificationsSearchParams, SupportNotificationsSearchResult, SupportProduct, SupportProductModule, SupportServiceFlags } from '../definitions';\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class SupportService implements OnDestroy {\r\n\r\n\r\n private httpClient = inject(HttpClient);\r\n private broadcastService = inject(BroadcastService);\r\n private broadcastServiceSubscription?: Subscription;\r\n private _loginInfo?: SupportLoginInfo;\r\n get loginInfo(): SupportLoginInfo | undefined { return this._loginInfo };\r\n set loginInfo(value: SupportLoginInfo | undefined) {\r\n this._loginInfo = value;\r\n }\r\n\r\n private _serviceUri: string = \"https://support.arsedizioni.it\"\r\n get serviceUri(): string {\r\n return this._serviceUri;\r\n }\r\n private _flags: SupportServiceFlags = SupportServiceFlags.None;\r\n get flags(): SupportServiceFlags {\r\n return this._flags;\r\n }\r\n\r\n public products: SupportProduct = SupportProduct.None;\r\n public productModules: SupportProductModule = SupportProductModule.None;\r\n\r\n public readonly unreadNotifications = signal<number | undefined>(undefined);\r\n public readonly loggedIn = signal<boolean>(false);\r\n public readonly loggingIn = signal<boolean>(false);\r\n private keepAlive = 0;\r\n\r\n ngOnDestroy() {\r\n // Clean-up\r\n if (this.broadcastServiceSubscription) {\r\n this.broadcastServiceSubscription.unsubscribe();\r\n }\r\n // Stop keep alive\r\n this.removeKeepAlive();\r\n }\r\n\r\n /**\r\n * Initialize service\r\n * @param serviceUri : the service uri\r\n * @param products: the supported products\r\n * @param productModules: the supported product modules\r\n * @param flags: the service flags. Default is none.\r\n */\r\n initialize(\r\n serviceUri: string,\r\n products: SupportProduct = SupportProduct.None,\r\n productModules: SupportProductModule = SupportProductModule.None,\r\n flags: SupportServiceFlags = SupportServiceFlags.None) {\r\n\r\n // Create unique client id\r\n if (!localStorage.getItem('support_client_id')) {\r\n localStorage.setItem('support_client_id', SystemUtils.generateUUID());\r\n }\r\n\r\n // Initialize\r\n this._serviceUri = serviceUri;\r\n this._flags = flags;\r\n this.products = products;\r\n this.productModules = productModules;\r\n\r\n // React to message broadcasting\r\n if (!this.broadcastServiceSubscription) {\r\n this.broadcastServiceSubscription = this.broadcastService.getMessage().subscribe((message: BroadcastMessageInfo) => {\r\n if (message.id === SupportMessages.LOGIN_CHANGED) {\r\n this.login(message.data.email, message.data.oauth, message.data.oauthAccessToken,\r\n SupportLoginFlags.DisableMfa |\r\n SupportLoginFlags.RememberCredentials |\r\n SupportLoginFlags.ExtendRememberCredentialsValidity).subscribe({\r\n next: r => {\r\n if (r.success) {\r\n this.countUnreadNotifications();\r\n }\r\n }, error: () => { console.error(\"ARS Support non disponibile.\") } // Avoid unwanted errors on client);\r\n });\r\n } else if (message.id === SupportMessages.LOGOUT) {\r\n if (this.loggedIn()) {\r\n this.logout()\r\n .pipe(finalize(() => this.clear()))\r\n .subscribe();\r\n } else {\r\n this.clear();\r\n }\r\n } else if (message.id === SupportMessages.NOTIFICATION_READ) {\r\n this.countUnreadNotifications();\r\n }\r\n });\r\n }\r\n\r\n // Eveluate current session storage in case of page refresh (F5)\r\n const tokenExpirationDate = this.getTokenExpirationDate();\r\n const tokenExpired = !tokenExpirationDate || tokenExpirationDate.getTime() < Date.now();\r\n if (!tokenExpired || this.loggedIn()) {\r\n // Auto login\r\n this.loggedIn.set(true);\r\n this.loggingIn.set(false);\r\n // Keep alive\r\n this.setKeepAlive();\r\n // Notify \r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_COMPLETED);\r\n }\r\n }\r\n\r\n /**\r\n * Get access token expiration date\r\n */\r\n private getTokenExpirationDate(): Date | undefined {\r\n const token = this.getAuthToken();\r\n if (!token || token.length === 0) return undefined;\r\n // Parse json object from base64 encoded jwt token\r\n const jwtToken = JSON.parse(atob(token.split('.')[1]));\r\n // Set a timeout to refresh the token a minute before it expires\r\n return new Date(jwtToken.exp * 1000);\r\n }\r\n\r\n\r\n /**\r\n * Set keep alive\r\n */\r\n private setKeepAlive() {\r\n // Keep alive every 1 min\r\n if (this.keepAlive === 0) {\r\n this.keepAlive = window.setInterval(\r\n () => {\r\n this.ping();\r\n }, 1000 * 60 * 5);\r\n }\r\n }\r\n\r\n /**\r\n * Remove keep alive\r\n */\r\n private removeKeepAlive() {\r\n if (this.keepAlive > 0) {\r\n window.clearInterval(this.keepAlive);\r\n this.keepAlive = 0;\r\n }\r\n }\r\n\r\n /**\r\n * Ping\r\n */\r\n ping() {\r\n this.httpClient.get<ApiResult<number>>(\r\n this._serviceUri + '/ping?nocache=' + SystemUtils.generateUUID()\r\n )\r\n .pipe(catchError(() => { return EMPTY }))\r\n .subscribe();\r\n }\r\n\r\n /**\r\n * Set JWT token\r\n * @param value : the login result\r\n */\r\n private setToken(value: SupportLoginResult) {\r\n if (value.authToken ?? value.token) {\r\n sessionStorage.setItem('support_auth', value.authToken ?? value.token);\r\n }\r\n }\r\n\r\n\r\n /**\r\n * Return current JWT token\r\n */\r\n getAuthToken(): string | undefined {\r\n let token = sessionStorage.getItem('support_auth');\r\n if (token && token[0] === '\"') {\r\n return token.substring(1, token.length - 1);\r\n }\r\n return token;\r\n }\r\n\r\n\r\n /**\r\n * Store context\r\n */\r\n storeContext() {\r\n localStorage.setItem('support_context', JSON.stringify(this._loginInfo));\r\n }\r\n\r\n /**\r\n* Update context\r\n* @param result: the new context\r\n*/\r\n updateContext(result: SupportLoginResult) {\r\n if (!this._loginInfo) {\r\n this._loginInfo = { context: undefined };\r\n }\r\n this._loginInfo.context = result.context;\r\n this.setToken(result);\r\n this.storeContext();\r\n\r\n }\r\n\r\n /**\r\n* Perform login \r\n* @param email: the guest email\r\n* @param oauth: the optional open authentication supported\r\n* @param oauthAccessToken: the optional oauth2 access token\r\n* @returns: the login result\r\n*/\r\n login(email?: string,\r\n oauth?: number,\r\n oauthAccessToken?: string,\r\n flags: SupportLoginFlags | undefined = SupportLoginFlags.RememberCredentials) {\r\n if (!flags) {\r\n flags = SupportLoginFlags.RememberCredentials;\r\n }\r\n return this.httpClient\r\n .post<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/login',\r\n {\r\n clientId: localStorage.getItem(\"support_client_id\"),\r\n user: oauth > 0 ? undefined : email,\r\n oauth: oauth,\r\n flags: flags\r\n },\r\n {\r\n headers:\r\n !oauth\r\n ? new HttpHeaders()\r\n : new HttpHeaders()\r\n .set(\"Authorization\", oauthAccessToken ?? '')\r\n })\r\n .pipe(\r\n finalize(() => this.loggingIn.set(false)),\r\n catchError(err => {\r\n return throwError(() => err);\r\n }),\r\n map((r: ApiResult<SupportLoginResult>) => {\r\n if (r.success) {\r\n if (!this._loginInfo) {\r\n this._loginInfo = { context: undefined }\r\n }\r\n this._loginInfo.oauth = oauth;\r\n this._loginInfo.remember = true;\r\n if (!oauth && r.value.requiresMfa) {\r\n // Notify login is pending\r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_PENDING, { flags: flags });\r\n } else {\r\n // Complete login\r\n this.completeLogin(r.value);\r\n }\r\n }\r\n return r;\r\n })\r\n );\r\n\r\n }\r\n\r\n /**\r\n * Complete login\r\n * @param result : the login result\r\n */\r\n private completeLogin(\r\n result: SupportLoginResult) {\r\n // Update context info \r\n this.updateContext(result);\r\n this.loggedIn.set(!result.context?.isTemporary);\r\n this.loggingIn.set(false);\r\n // Keep alive\r\n this.setKeepAlive();\r\n // Notify\r\n this.broadcastService.sendMessage(SupportMessages.LOGIN_COMPLETED);\r\n }\r\n\r\n /**\r\n * Confirm MFA procedure\r\n * @param code: the confirm code\r\n * @param flags: the login flags\r\n */\r\n confirmIdentity(code: string, flags: number = SupportLoginFlags.None) {\r\n return this.httpClient\r\n .post<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/login/confirm/' + code + '/?flags=' + flags,\r\n {},\r\n )\r\n .pipe(\r\n finalize(() => this.loggingIn.set(false)),\r\n catchError((err) => {\r\n return throwError(() => err);\r\n }),\r\n map((r: ApiResult<SupportLoginResult>) => {\r\n if (r.success) {\r\n // Complete login\r\n this.completeLogin(r.value);\r\n }\r\n return r;\r\n }),\r\n );\r\n }\r\n\r\n /**\r\n * Perform logout\r\n */\r\n logout() {\r\n return this.httpClient\r\n .post(this._serviceUri + '/logout', {}).pipe(\r\n finalize(() => {\r\n this.removeKeepAlive();\r\n this.clear();\r\n // Clean up\r\n localStorage.removeItem('support_context');\r\n }),\r\n catchError((_e) => {\r\n return of([]);\r\n }));\r\n\r\n }\r\n\r\n /**\r\n * Reset login refresh timer and logins state\r\n */\r\n reset() {\r\n // Clear login info\r\n this._loginInfo = undefined;\r\n this.loggedIn.set(false);\r\n // Notify\r\n this.broadcastService.sendMessage(SupportMessages.LOGOUT_COMPLETED);\r\n }\r\n\r\n /**\r\n * Clear login data\r\n */\r\n clear() {\r\n // Reset login\r\n this.reset();\r\n // Clear local storage\r\n sessionStorage.removeItem('support_auth');\r\n }\r\n\r\n /**\r\n * Perform token refresh\r\n */\r\n refresh() {\r\n return this.httpClient.get<ApiResult<SupportLoginResult>>(\r\n this._serviceUri + '/refresh2'\r\n ).pipe(map((r: ApiResult<SupportLoginResult>) => {\r\n // Update token\r\n this.setToken(r.value);\r\n return r;\r\n }));\r\n }\r\n\r\n /**\r\n * Navigate to support service\r\n */\r\n open() {\r\n let uri = this.serviceUri ?? '';\r\n if (uri.endsWith('/api'))\r\n uri = uri.substring(0, uri.length - 4)\r\n window.open(uri);\r\n }\r\n\r\n\r\n ////\r\n // NOTIFICATIONS\r\n ////\r\n\r\n /**\r\n * Count unread notifications\r\n */\r\n countUnreadNotifications() {\r\n this.httpClient.get<ApiResult<number>>(\r\n this._serviceUri + '/notifications/count-unread/?products=' + (this.products ?? 0) + \"&modules=\" + (this.productModules ?? 0)\r\n ).subscribe((r: ApiResult<number>) => {\r\n if (r.success) {\r\n this.unreadNotifications.set(r.value > 0 ? r.value : undefined)\r\n }\r\n });\r\n }\r\n\r\n /**\r\n * Query notifications\r\n * @param params: query parameters\r\n */\r\n queryNotifications(params: SupportNotificationsSearchParams) {\r\n params.products = this.products ?? 0;\r\n params.productModules = this.productModules ?? 0;\r\n return this.httpClient.post<ApiResult<SupportNotificationsSearchResult>>(\r\n this._serviceUri + '/notifications',\r\n params\r\n );\r\n }\r\n\r\n /**\r\n * Retrieve a notification\r\n * @param id: the notification id\r\n */\r\n getNotification(id: number) {\r\n return this.httpClient.get<ApiResult<SupportNotificationInfo>>(\r\n this._serviceUri +\r\n '/notifications/' +\r\n id\r\n );\r\n }\r\n\r\n /**\r\n * Mark a group of notifications as read\r\n * @param ids: the array of notification's ids to set as read\r\n */\r\n markNotifications(params: SupportNotificationsMarkParams) {\r\n return this.httpClient.post<ApiResult<boolean>>(\r\n this._serviceUri + '/notifications/mark',\r\n params\r\n );\r\n }\r\n\r\n /**\r\n * Download a notification document\r\n * @param documentId : the notification document id\r\n */\r\n dowloadNotificationDocument(documentId: number) {\r\n return this.httpClient.get(\r\n this._serviceUri + '/documents/download/' + documentId,\r\n { responseType: 'blob' }\r\n );\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable, inject } from '@angular/core';\r\nimport { Observable, catchError, switchMap, throwError } from 'rxjs';\r\nimport { SupportService } from '../services/support.service';\r\nimport { BroadcastService, ErrorInfo } from '@arsedizioni/ars-utils/core';\r\nimport { SupportServiceFlags } from '../definitions';\r\nimport { SupportMessages } from '../messages';\r\n\r\n@Injectable()\r\nexport class SupportAuthInterceptor implements HttpInterceptor {\r\n\r\n private supportService = inject(SupportService);\r\n private broadcastService = inject(BroadcastService);\r\n private lastErrorTime: number = -1;\r\n\r\n intercept(\r\n request: HttpRequest<any>,\r\n next: HttpHandler\r\n ): Observable<HttpEvent<any>> {\r\n if (request.url.startsWith(this.supportService.serviceUri)) {\r\n request = request.clone({ withCredentials: true });\r\n return next.handle(this.addTokenToRequest(request))\r\n .pipe(\r\n catchError(error => {\r\n if (error.url.startsWith(this.supportService.serviceUri)) {\r\n if (\r\n error instanceof HttpErrorResponse &&\r\n !request.url.includes(\"/login\") &&\r\n error.status === 401\r\n ) {\r\n return this.handle401Error(request, next);\r\n }\r\n const errorStatus = parseInt(error.status ?? \"0\");\r\n if ((errorStatus > 0 && errorStatus < 500) || (this.supportService.flags & SupportServiceFlags.NotifySystemErrors) > 0) {\r\n const errorTime = new Date().getTime();\r\n if (errorTime - this.lastErrorTime > 5000) {\r\n this.lastErrorTime = errorTime;\r\n let message = \"\"\r\n switch (errorStatus) {\r\n case 0:\r\n message = \"In questo momento ARS Support non è disponibile. Riprova tra qualche minuto.\";\r\n break;\r\n case 403:\r\n message = \"Non hai i permessi necessari per eseguire l'operazione richiesta.\";\r\n break;\r\n default:\r\n message = (error.error?.message ?? error.message ?? \"Impossibile eseguire l'operazione richiesta.\").replaceAll(\"\\r\\n\", \"</p><p>\");\r\n break;\r\n }\r\n this.broadcastService.sendMessage(\r\n SupportMessages.ERROR,\r\n {\r\n invalidateSession: errorStatus === 405 || errorStatus === 410,\r\n message: message,\r\n title: \"Errore in ARS Support\",\r\n errorStatus: errorStatus,\r\n service: this.supportService.serviceUri\r\n } as ErrorInfo);\r\n }\r\n }\r\n }\r\n return throwError(() => error);\r\n }));\r\n }\r\n return next.handle(request);\r\n }\r\n\r\n /**\r\n * Handle 401 error\r\n * @param request : the request\r\n * @param next : the http handler\r\n */\r\n private handle401Error(request: HttpRequest<any>, next: HttpHandler) {\r\n if (this.supportService.loggedIn()) {\r\n return this.supportService.refresh().pipe(\r\n switchMap(() => {\r\n return next.handle(this.addTokenToRequest(request));\r\n }),\r\n catchError(error => {\r\n return throwError(() => error);\r\n })\r\n );\r\n }\r\n return next.handle(request);\r\n }\r\n\r\n /**\r\n * Add token to request\r\n * @param request : the request\r\n * @param token: the token or null to use curre3nt\r\n */\r\n private addTokenToRequest(\r\n request: HttpRequest<any>,\r\n token: string = null\r\n ): HttpRequest<any> {\r\n if (request.url.startsWith(this.supportService.serviceUri)) {\r\n if (this.supportService.loggedIn()) {\r\n if (!token) token = this.supportService.getAuthToken();\r\n if (token) {\r\n return request.clone({\r\n setHeaders: {\r\n Authorization: 'Bearer ' + token,\r\n 'ngsw-bypass': 'ngsw-bypass'\r\n },\r\n });\r\n }\r\n }\r\n }\r\n return request;\r\n }\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\n\r\n@NgModule()\r\nexport class ArsSupportCommonModule {}\r\n\r\n// Other exports\r\nexport * from './messages';\r\nexport * from './definitions';\r\nexport * from './interceptors/auth.interceptor';\r\nexport * from './services/support.service';\r\n","/*\r\n * Public API Surface of ars-utils\r\n */\r\nexport * from './common/common.module';\r\nexport * from './common/messages';\r\nexport * from './common/definitions';\r\nexport * from './common/services/support.service';\r\n\r\n\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["catchError"],"mappings":";;;;;;;AAAO,MAAM,eAAe,GAAG;AAC7B;;AAEG;;AAEH,IAAA,KAAK,EAAE,gBAAgB;;AAGvB,IAAA,aAAa,EAAE,wBAAwB;AACvC,IAAA,eAAe,EAAE,0BAA0B;AAC3C,IAAA,gBAAgB,EAAE,2BAA2B;AAC7C,IAAA,aAAa,EAAE,wBAAwB;AACvC,IAAA,MAAM,EAAE,iBAAiB;;AAGzB,IAAA,iBAAiB,EAAE,4BAA4B;;;ICZrC;AAAZ,CAAA,UAAY,mBAAmB,EAAA;AAC3B,IAAA,mBAAA,CAAA,mBAAA,CAAA,MAAA,CAAA,GAAA,CAAA,CAAA,GAAA,MAAQ;AACR,IAAA,mBAAA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