@arsedizioni/ars-utils 18.1.56 → 18.1.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/ui.application/ui/dialogs/select-picture/select-picture-dialog.component.mjs +6 -6
- package/fesm2022/arsedizioni-ars-utils-ui.application.mjs +5 -5
- package/fesm2022/arsedizioni-ars-utils-ui.application.mjs.map +1 -1
- package/package.json +1 -1
- package/ui.application/ui/dialogs/select-picture/select-picture-dialog.component.d.ts +1 -1
package/esm2022/ui.application/ui/dialogs/select-picture/select-picture-dialog.component.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChangeDetectionStrategy, Component, EventEmitter, Output, inject } from '@angular/core';
|
|
1
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, Output, inject, signal } from '@angular/core';
|
|
2
2
|
import { MatDialogRef, MAT_DIALOG_DATA, MatDialogTitle, MatDialogContent, MatDialogActions, MatDialogClose } from '@angular/material/dialog';
|
|
3
3
|
import { SystemUtils } from '@arsedizioni/ars-utils/core';
|
|
4
4
|
import { SafeHtmlPipe } from '@arsedizioni/ars-utils/core';
|
|
@@ -17,7 +17,7 @@ export class SelectPictureDialogComponent {
|
|
|
17
17
|
this.dialogRef = inject((MatDialogRef));
|
|
18
18
|
this.dialogData = inject(MAT_DIALOG_DATA);
|
|
19
19
|
this.file = null;
|
|
20
|
-
this.filePreview = null;
|
|
20
|
+
this.filePreview = signal(null);
|
|
21
21
|
}
|
|
22
22
|
/**
|
|
23
23
|
* Update preview
|
|
@@ -28,7 +28,7 @@ export class SelectPictureDialogComponent {
|
|
|
28
28
|
this.file = e.target.files[0];
|
|
29
29
|
const reader = new FileReader();
|
|
30
30
|
reader.onload = (_e) => {
|
|
31
|
-
this.filePreview
|
|
31
|
+
this.filePreview.set(_e.target.result);
|
|
32
32
|
};
|
|
33
33
|
reader.readAsDataURL(e.target.files[0]);
|
|
34
34
|
}
|
|
@@ -50,13 +50,13 @@ export class SelectPictureDialogComponent {
|
|
|
50
50
|
}, 500);
|
|
51
51
|
}
|
|
52
52
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SelectPictureDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
53
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SelectPictureDialogComponent, isStandalone: true, selector: "ng-component", outputs: { done: "done" }, host: { attributes: { "Bind": SystemUtils.generateUUID() } }, ngImport: i0, template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"], dependencies: [{ 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: FlexModule }, { kind: "directive", type: i1.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i1.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { kind: "directive", type: i1.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { kind: "directive", type: i1.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1.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.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
53
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SelectPictureDialogComponent, isStandalone: true, selector: "ng-component", outputs: { done: "done" }, host: { attributes: { "Bind": SystemUtils.generateUUID() } }, ngImport: i0, template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview()\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"], dependencies: [{ 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: FlexModule }, { kind: "directive", type: i1.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i1.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { kind: "directive", type: i1.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { kind: "directive", type: i1.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1.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.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
54
54
|
}
|
|
55
55
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SelectPictureDialogComponent, decorators: [{
|
|
56
56
|
type: Component,
|
|
57
57
|
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [MatDialogTitle, MatDialogContent, FlexModule, MatButtonModule, MatCheckboxModule, FormsModule,
|
|
58
|
-
MatDialogActions, MatDialogClose, SafeHtmlPipe], template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"] }]
|
|
58
|
+
MatDialogActions, MatDialogClose, SafeHtmlPipe], template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview()\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"] }]
|
|
59
59
|
}], propDecorators: { done: [{
|
|
60
60
|
type: Output
|
|
61
61
|
}] } });
|
|
62
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
62
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2VsZWN0LXBpY3R1cmUtZGlhbG9nLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2Fycy11dGlscy91aS5hcHBsaWNhdGlvbi91aS9kaWFsb2dzL3NlbGVjdC1waWN0dXJlL3NlbGVjdC1waWN0dXJlLWRpYWxvZy5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9hcnMtdXRpbHMvdWkuYXBwbGljYXRpb24vdWkvZGlhbG9ncy9zZWxlY3QtcGljdHVyZS9zZWxlY3QtcGljdHVyZS1kaWFsb2cuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEs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ZmlsZVwiPnt7ZGlhbG9nRGF0YS5va0NhcHRpb259fTwvYnV0dG9uPlxyXG4gICAgPGJ1dHRvbiBtYXQtYnV0dG9uIG1hdC1kaWFsb2ctY2xvc2UgY2RrRm9jdXNJbml0aWFsIGNvbG9yPVwicHJpbWFyeVwiPkFubnVsbGE8L2J1dHRvbj5cclxuICA8L2Rpdj5cclxuPC9kaXY+Il19
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, Renderer2, ElementRef, Directive, Input, EventEmitter, Component, ChangeDetectionStrategy, Output, Injectable,
|
|
2
|
+
import { inject, Renderer2, ElementRef, Directive, Input, EventEmitter, Component, ChangeDetectionStrategy, Output, Injectable, signal, ViewChild, NgModule, input, Optional, Self, HostBinding, ChangeDetectorRef } from '@angular/core';
|
|
3
3
|
import * as i14 from '@angular/material/paginator';
|
|
4
4
|
import { MatPaginatorModule, MatPaginatorIntl } from '@angular/material/paginator';
|
|
5
5
|
import { DialogService, PaginatorIntl, UIService } from '@arsedizioni/ars-utils/ui';
|
|
@@ -512,7 +512,7 @@ class SelectPictureDialogComponent {
|
|
|
512
512
|
this.dialogRef = inject((MatDialogRef));
|
|
513
513
|
this.dialogData = inject(MAT_DIALOG_DATA);
|
|
514
514
|
this.file = null;
|
|
515
|
-
this.filePreview = null;
|
|
515
|
+
this.filePreview = signal(null);
|
|
516
516
|
}
|
|
517
517
|
/**
|
|
518
518
|
* Update preview
|
|
@@ -523,7 +523,7 @@ class SelectPictureDialogComponent {
|
|
|
523
523
|
this.file = e.target.files[0];
|
|
524
524
|
const reader = new FileReader();
|
|
525
525
|
reader.onload = (_e) => {
|
|
526
|
-
this.filePreview
|
|
526
|
+
this.filePreview.set(_e.target.result);
|
|
527
527
|
};
|
|
528
528
|
reader.readAsDataURL(e.target.files[0]);
|
|
529
529
|
}
|
|
@@ -545,12 +545,12 @@ class SelectPictureDialogComponent {
|
|
|
545
545
|
}, 500);
|
|
546
546
|
}
|
|
547
547
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SelectPictureDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
548
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SelectPictureDialogComponent, isStandalone: true, selector: "ng-component", outputs: { done: "done" }, host: { attributes: { "Bind": SystemUtils.generateUUID() } }, ngImport: i0, template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"], dependencies: [{ 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: FlexModule }, { kind: "directive", type: i1$1.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$1.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$1.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$1.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1$1.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: i6.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
548
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.3", type: SelectPictureDialogComponent, isStandalone: true, selector: "ng-component", outputs: { done: "done" }, host: { attributes: { "Bind": SystemUtils.generateUUID() } }, ngImport: i0, template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview()\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"], dependencies: [{ 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: FlexModule }, { kind: "directive", type: i1$1.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$1.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$1.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$1.FlexFillDirective, selector: "[fxFill], [fxFlexFill]" }, { kind: "directive", type: i1$1.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: i6.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "directive", type: MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
549
549
|
}
|
|
550
550
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: SelectPictureDialogComponent, decorators: [{
|
|
551
551
|
type: Component,
|
|
552
552
|
args: [{ host: { 'Bind': SystemUtils.generateUUID() }, standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [MatDialogTitle, MatDialogContent, FlexModule, MatButtonModule, MatCheckboxModule, FormsModule,
|
|
553
|
-
MatDialogActions, MatDialogClose, SafeHtmlPipe], template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"] }]
|
|
553
|
+
MatDialogActions, MatDialogClose, SafeHtmlPipe], template: "<h2 mat-dialog-title>{{dialogData.title}}</h2>\r\n@if (dialogData.description) {\r\n<div class=\"selectpicture-description\" [innerHtml]=\"dialogData.description | safeHtml\"></div>\r\n}\r\n<div mat-dialog-content>\r\n <div fxLayout=\"column\" fxLayoutGap=\"32px\" fxFill>\r\n <div fxFlex=\"*\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxFill>\r\n <input #_file type=\"file\" [hidden]=\"true\" accept=\"image/*\" (change)=\"update($event)\" />\r\n <button type=\"button\" mat-button color=\"primary\" (click)=\"_file.click()\">Seleziona file...</button>\r\n @if (file) {\r\n <div class=\"selectpicture-info\">\r\n <img [src]=\"filePreview()\" class=\"preview\"><br />\r\n <span class=\"small truncated\"><i>{{file.name}}</i></span>\r\n <div><span class=\"small truncated\">Dimensioni: <i>{{size(file.size)}}</i></span></div>\r\n </div>\r\n }\r\n </div>\r\n @if (dialogData.options) {\r\n <div>\r\n @for (o of dialogData.options; track $index; let i = $index) {\r\n <div>\r\n <mat-checkbox color=\"primary\" [(ngModel)]=\"o.value\" name=\"opt_{{i}}\">\r\n {{o.description}}\r\n </mat-checkbox>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n<div mat-dialog-actions>\r\n <div fxLayout=\"row\" fxLayoutAlign=\"end\" fxFill>\r\n <button mat-flat-button (click)=\"ok()\" color=\"primary\" [disabled]=\"!file\">{{dialogData.okCaption}}</button>\r\n <button mat-button mat-dialog-close cdkFocusInitial color=\"primary\">Annulla</button>\r\n </div>\r\n</div>", styles: [":root{--ars-dialog-info-ok: #388E3C;--ars-filterbox-filtered-background-color: #f9fbe7}.dialog-info{font-size:x-small;font-weight:700;text-align:right;padding:10px}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #388E3C)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #a80710)}.dialog-title{padding:0 24px}.section-title{font-size:large;font-weight:600;padding-top:10px;padding-bottom:8px}b{font-weight:700}.large{font-size:large!important}.small{font-size:small!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}.uppercase{text-transform:uppercase!important}.lowercase{text-transform:lowercase!important}.truncated{min-width:0}.truncated span,.truncated div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (prefers-color-scheme: dark){:root{--ars-dialog-info-ok: #4CAF50;--ars-filterbox-filtered-background-color: #c6c7b8}.dialog-info-green,.dialog-info-ok{color:var(--ars-dialog-info-ok, #4CAF50)}.dialog-info-red,.dialog-info-error{color:var(--mat-form-field-error-text-color, #ff5449)}b{font-weight:600}}.selectpicture-file{padding:20px;width:320px;border:5px dotted #eee}.selectpicture-info{width:100%;margin-top:30px;text-align:center}.selectpicture-info .preview{max-height:300px;max-width:300px}.selectpicture-description{padding:0 24px 24px}\n"] }]
|
|
554
554
|
}], propDecorators: { done: [{
|
|
555
555
|
type: Output
|
|
556
556
|
}] } });
|