@netgrif/components 6.3.2 → 6.3.3
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/esm2020/lib/data-fields/user-list-field/user-list-field.component.mjs +7 -3
- package/fesm2015/netgrif-components.mjs +5 -2
- package/fesm2015/netgrif-components.mjs.map +1 -1
- package/fesm2020/netgrif-components.mjs +5 -2
- package/fesm2020/netgrif-components.mjs.map +1 -1
- package/lib/data-fields/user-list-field/user-list-field.component.d.ts +1 -0
- package/package.json +2 -2
|
@@ -10,6 +10,7 @@ import * as i5 from "@angular/material/button";
|
|
|
10
10
|
import * as i6 from "@angular/material/icon";
|
|
11
11
|
import * as i7 from "@angular/common";
|
|
12
12
|
import * as i8 from "@angular/material/form-field";
|
|
13
|
+
import * as i9 from "@angular/material/tooltip";
|
|
13
14
|
export class UserListFieldComponent extends AbstractUserListFieldComponent {
|
|
14
15
|
constructor(sideMenuService, snackbar, translate, informAboutInvalidData) {
|
|
15
16
|
super(sideMenuService, snackbar, translate, informAboutInvalidData);
|
|
@@ -20,16 +21,19 @@ export class UserListFieldComponent extends AbstractUserListFieldComponent {
|
|
|
20
21
|
deleteUser(userId) {
|
|
21
22
|
this.removeAbstractUser(userId);
|
|
22
23
|
}
|
|
24
|
+
deleteAll() {
|
|
25
|
+
this.removeAll();
|
|
26
|
+
}
|
|
23
27
|
}
|
|
24
28
|
UserListFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: UserListFieldComponent, deps: [{ token: i1.SideMenuService }, { token: i1.SnackBarService }, { token: i2.TranslateService }, { token: NAE_INFORM_ABOUT_INVALID_DATA, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
25
|
-
UserListFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: UserListFieldComponent, selector: "nc-user-list-field", usesInheritance: true, ngImport: i0, template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"], components: [{ type: i3.DataFieldTemplateComponent, selector: "nc-data-field-template" }, { type: i4.RequiredLabelComponent, selector: "nc-required-label", inputs: ["isIn"] }, { type: i5.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.MatLabel, selector: "mat-label" }, { type: i7.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.MatError, selector: "mat-error", inputs: ["id"] }], pipes: { "translate": i2.TranslatePipe, "keyvalue": i7.KeyValuePipe } });
|
|
29
|
+
UserListFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: UserListFieldComponent, selector: "nc-user-list-field", usesInheritance: true, ngImport: i0, template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <button *ngIf='!formControl.disabled && dataField?.value?.userValues?.size > 0' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='warn'\n (click)='deleteAll()'\n [matTooltip]=\"'dataField.user.deleteAll' | translate\">\n <mat-icon>delete_outline</mat-icon>\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"], components: [{ type: i3.DataFieldTemplateComponent, selector: "nc-data-field-template" }, { type: i4.RequiredLabelComponent, selector: "nc-required-label", inputs: ["isIn"] }, { type: i5.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.MatLabel, selector: "mat-label" }, { type: i9.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i7.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.MatError, selector: "mat-error", inputs: ["id"] }], pipes: { "translate": i2.TranslatePipe, "keyvalue": i7.KeyValuePipe } });
|
|
26
30
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: UserListFieldComponent, decorators: [{
|
|
27
31
|
type: Component,
|
|
28
|
-
args: [{ selector: 'nc-user-list-field', template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"] }]
|
|
32
|
+
args: [{ selector: 'nc-user-list-field', template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <button *ngIf='!formControl.disabled && dataField?.value?.userValues?.size > 0' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='warn'\n (click)='deleteAll()'\n [matTooltip]=\"'dataField.user.deleteAll' | translate\">\n <mat-icon>delete_outline</mat-icon>\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"] }]
|
|
29
33
|
}], ctorParameters: function () { return [{ type: i1.SideMenuService }, { type: i1.SnackBarService }, { type: i2.TranslateService }, { type: undefined, decorators: [{
|
|
30
34
|
type: Optional
|
|
31
35
|
}, {
|
|
32
36
|
type: Inject,
|
|
33
37
|
args: [NAE_INFORM_ABOUT_INVALID_DATA]
|
|
34
38
|
}] }]; } });
|
|
35
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
39
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXNlci1saXN0LWZpZWxkLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25ldGdyaWYtY29tcG9uZW50cy9zcmMvbGliL2RhdGEtZmllbGRzL3VzZXItbGlzdC1maWVsZC91c2VyLWxpc3QtZmllbGQuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmV0Z3JpZi1jb21wb25lbnRzL3NyYy9saWIvZGF0YS1maWVsZHMvdXNlci1saXN0LWZpZWxkL3VzZXItbGlzdC1maWVsZC5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsU0FBUyxFQUFFLE1BQU0sRUFBRSxRQUFRLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFFNUQsT0FBTyxFQUNILDhCQUE4QixFQUM5Qiw2QkFBNkIsRUFHaEMsTUFBTSwwQkFBMEIsQ0FBQztBQUNsQyxPQUFPLEVBQUMsd0JBQXdCLEVBQUMsTUFBTSxrRkFBa0YsQ0FBQzs7Ozs7Ozs7Ozs7QUFPMUgsTUFBTSxPQUFPLHNCQUF1QixTQUFRLDhCQUE4QjtJQUV0RSxZQUFZLGV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gICAgICAgICAgICAgIHt7dXNlci52YWx1ZS5mdWxsTmFtZX19XG4gICAgICAgICAgICAgICAgPG1hdC1pY29uIChjbGljayk9J2RlbGV0ZVVzZXIodXNlci5rZXkpJyBjb2xvcj0nd2FybicgKm5nSWY9JyFmb3JtQ29udHJvbC5kaXNhYmxlZCc+Y2xvc2U8L21hdC1pY29uPlxuICAgICAgICAgICAgPC9idXR0b24+XG4gICAgICAgIDwvc3Bhbj5cbiAgICA8L3NwYW4+XG4gICAgPG1hdC1lcnJvciAqbmdJZj0nZGF0YUZpZWxkLmlzSW52YWxpZChmb3JtQ29udHJvbCknPnt7J2RhdGFGaWVsZC52YWxpZGF0aW9ucy5yZXF1aXJlZCcgfCB0cmFuc2xhdGV9fTwvbWF0LWVycm9yPlxuPC9uZy10ZW1wbGF0ZT5cbiJdfQ==
|
|
@@ -1680,12 +1680,15 @@ class UserListFieldComponent extends AbstractUserListFieldComponent {
|
|
|
1680
1680
|
deleteUser(userId) {
|
|
1681
1681
|
this.removeAbstractUser(userId);
|
|
1682
1682
|
}
|
|
1683
|
+
deleteAll() {
|
|
1684
|
+
this.removeAll();
|
|
1685
|
+
}
|
|
1683
1686
|
}
|
|
1684
1687
|
UserListFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: UserListFieldComponent, deps: [{ token: i1.SideMenuService }, { token: i1.SnackBarService }, { token: i2$1.TranslateService }, { token: NAE_INFORM_ABOUT_INVALID_DATA, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
1685
|
-
UserListFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: UserListFieldComponent, selector: "nc-user-list-field", usesInheritance: true, ngImport: i0, template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"], components: [{ type: DataFieldTemplateComponent, selector: "nc-data-field-template" }, { type: RequiredLabelComponent, selector: "nc-required-label", inputs: ["isIn"] }, { type: i6.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i5$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.MatLabel, selector: "mat-label" }, { type: i5$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5.MatError, selector: "mat-error", inputs: ["id"] }], pipes: { "translate": i2$1.TranslatePipe, "keyvalue": i5$2.KeyValuePipe } });
|
|
1688
|
+
UserListFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: UserListFieldComponent, selector: "nc-user-list-field", usesInheritance: true, ngImport: i0, template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <button *ngIf='!formControl.disabled && dataField?.value?.userValues?.size > 0' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='warn'\n (click)='deleteAll()'\n [matTooltip]=\"'dataField.user.deleteAll' | translate\">\n <mat-icon>delete_outline</mat-icon>\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"], components: [{ type: DataFieldTemplateComponent, selector: "nc-data-field-template" }, { type: RequiredLabelComponent, selector: "nc-required-label", inputs: ["isIn"] }, { type: i6.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i5$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.MatLabel, selector: "mat-label" }, { type: i15.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i5$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5.MatError, selector: "mat-error", inputs: ["id"] }], pipes: { "translate": i2$1.TranslatePipe, "keyvalue": i5$2.KeyValuePipe } });
|
|
1686
1689
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: UserListFieldComponent, decorators: [{
|
|
1687
1690
|
type: Component,
|
|
1688
|
-
args: [{ selector: 'nc-user-list-field', template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"] }]
|
|
1691
|
+
args: [{ selector: 'nc-user-list-field', template: "<nc-data-field-template *ngIf='!dataField.behavior.hidden'\n [dataField]='dataField'\n [dataFieldTemplate]='dataFieldTemplate'\n [offset]='taskOffset'>\n</nc-data-field-template>\n\n<ng-template #dataFieldTemplate let-showLargeLayout='showLargeLayout'>\n <mat-label class='netgrif-label' *ngIf='!showLargeLayout.value'>{{dataField.title}}\n <nc-required-label *ngIf='dataField.behavior.required' [isIn]='!dataField.disabled'></nc-required-label>\n <br>\n </mat-label>\n <button *ngIf='!formControl.disabled' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='primary'\n (click)='selectUser()'>\n <mat-icon>person_add</mat-icon>\n {{'dataField.user.selectUser' | translate}}\n </button>\n <button *ngIf='!formControl.disabled && dataField?.value?.userValues?.size > 0' mat-stroked-button class='user-list-item-margin'\n [disabled]='formControl.disabled'\n color='warn'\n (click)='deleteAll()'\n [matTooltip]=\"'dataField.user.deleteAll' | translate\">\n <mat-icon>delete_outline</mat-icon>\n </button>\n <span *ngIf='dataField?.value?.userValues?.size > 0'>\n <span *ngFor='let user of dataField.value.userValues | keyvalue' class='user-list-item-margin'>\n <button mat-stroked-button\n [disabled]='formControl.disabled'\n color='primary'>\n <mat-icon>how_to_reg</mat-icon>\n {{user.value.fullName}}\n <mat-icon (click)='deleteUser(user.key)' color='warn' *ngIf='!formControl.disabled'>close</mat-icon>\n </button>\n </span>\n </span>\n <mat-error *ngIf='dataField.isInvalid(formControl)'>{{'dataField.validations.required' | translate}}</mat-error>\n</ng-template>\n", styles: [".user-list-item-margin{margin:0 4px 4px}\n"] }]
|
|
1689
1692
|
}], ctorParameters: function () {
|
|
1690
1693
|
return [{ type: i1.SideMenuService }, { type: i1.SnackBarService }, { type: i2$1.TranslateService }, { type: undefined, decorators: [{
|
|
1691
1694
|
type: Optional
|