@ng-formworks/material 15.5.2 → 15.5.6
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/widgets/material-input.component.mjs +18 -10
- package/fesm2015/ng-formworks-material.mjs +18 -9
- package/fesm2015/ng-formworks-material.mjs.map +1 -1
- package/fesm2020/ng-formworks-material.mjs +17 -9
- package/fesm2020/ng-formworks-material.mjs.map +1 -1
- package/lib/widgets/material-input.component.d.ts +1 -0
- package/package.json +3 -3
|
@@ -18,6 +18,10 @@ export class MaterialInputComponent {
|
|
|
18
18
|
this.boundControl = false;
|
|
19
19
|
this.autoCompleteList = [];
|
|
20
20
|
}
|
|
21
|
+
//needed as templates don't accept something like [attributes]="options?.['x-inputAttributes']"
|
|
22
|
+
get inputAttributes() {
|
|
23
|
+
return this.options?.['x-inputAttributes'];
|
|
24
|
+
}
|
|
21
25
|
ngOnInit() {
|
|
22
26
|
this.options = this.layoutNode.options || {};
|
|
23
27
|
this.jsf.initializeControl(this);
|
|
@@ -51,10 +55,10 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
51
55
|
[name]="controlName"
|
|
52
56
|
[placeholder]="options?.notitle ? options?.placeholder : options?.title"
|
|
53
57
|
[required]="options?.required"
|
|
54
|
-
[style.width]="'100%'"
|
|
55
58
|
[type]="layoutNode?.type"
|
|
56
|
-
(blur)="options.showErrors = true"
|
|
57
|
-
|
|
59
|
+
(blur)="options.showErrors = true"
|
|
60
|
+
[attributes]="inputAttributes">
|
|
61
|
+
<input #input matInput *ngIf="!boundControl"
|
|
58
62
|
[attr.aria-describedby]="'control' + layoutNode?._id + 'Status'"
|
|
59
63
|
[attr.list]="'control' + layoutNode?._id + 'Autocomplete'"
|
|
60
64
|
[attr.maxlength]="options?.maxLength"
|
|
@@ -70,7 +74,9 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
70
74
|
[type]="layoutNode?.type"
|
|
71
75
|
[value]="controlValue"
|
|
72
76
|
(input)="updateValue($event)"
|
|
73
|
-
(blur)="options.showErrors = true"
|
|
77
|
+
(blur)="options.showErrors = true"
|
|
78
|
+
[attributes]="inputAttributes"
|
|
79
|
+
>
|
|
74
80
|
<span matSuffix *ngIf="options?.suffix || options?.fieldAddonRight"
|
|
75
81
|
[innerHTML]="options?.suffix || options?.fieldAddonRight"></span>
|
|
76
82
|
<mat-hint *ngIf="options?.description && (!options?.showErrors || !options?.errorMessage)"
|
|
@@ -84,7 +90,7 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
84
90
|
</button>
|
|
85
91
|
</mat-form-field>
|
|
86
92
|
<mat-error *ngIf="options?.showErrors && options?.errorMessage"
|
|
87
|
-
[innerHTML]="options?.errorMessage"></mat-error>`, isInline: true, styles: ["mat-error{font-size:75%;margin-top:-1rem;margin-bottom:.5rem}::ng-deep json-schema-form mat-form-field .mat-mdc-form-field-wrapper .mat-form-field-flex .mat-form-field-infix{width:initial}input{width:100%}input[type=datetime-local]{width:120%}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i3.MinLengthValidator, selector: "[minlength][formControlName],[minlength][formControl],[minlength][ngModel]", inputs: ["minlength"] }, { kind: "directive", type: i3.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i3.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i4.MatAutocomplete, selector: "mat-autocomplete", inputs: ["disableRipple", "hideSingleSelectionIndicator"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i5.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "component", type: i6.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i7.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i7.MatLabel, selector: "mat-label" }, { kind: "directive", type: i7.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i7.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i7.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i7.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i8.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }] });
|
|
93
|
+
[innerHTML]="options?.errorMessage"></mat-error>`, isInline: true, styles: ["mat-error{font-size:75%;margin-top:-1rem;margin-bottom:.5rem}::ng-deep json-schema-form mat-form-field .mat-mdc-form-field-wrapper .mat-form-field-flex .mat-form-field-infix{width:initial}input{width:100%}input[type=datetime-local]{width:120%}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i3.MinLengthValidator, selector: "[minlength][formControlName],[minlength][formControl],[minlength][ngModel]", inputs: ["minlength"] }, { kind: "directive", type: i3.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i3.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i4.MatAutocomplete, selector: "mat-autocomplete", inputs: ["disableRipple", "hideSingleSelectionIndicator"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i5.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "component", type: i6.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i7.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i7.MatLabel, selector: "mat-label" }, { kind: "directive", type: i7.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i7.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i7.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i7.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i8.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: i1.ElementAttributeDirective, selector: "[attributes]", inputs: ["attributes"] }] });
|
|
88
94
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: MaterialInputComponent, decorators: [{
|
|
89
95
|
type: Component,
|
|
90
96
|
args: [{ selector: 'material-input-widget', template: `
|
|
@@ -108,10 +114,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
108
114
|
[name]="controlName"
|
|
109
115
|
[placeholder]="options?.notitle ? options?.placeholder : options?.title"
|
|
110
116
|
[required]="options?.required"
|
|
111
|
-
[style.width]="'100%'"
|
|
112
117
|
[type]="layoutNode?.type"
|
|
113
|
-
(blur)="options.showErrors = true"
|
|
114
|
-
|
|
118
|
+
(blur)="options.showErrors = true"
|
|
119
|
+
[attributes]="inputAttributes">
|
|
120
|
+
<input #input matInput *ngIf="!boundControl"
|
|
115
121
|
[attr.aria-describedby]="'control' + layoutNode?._id + 'Status'"
|
|
116
122
|
[attr.list]="'control' + layoutNode?._id + 'Autocomplete'"
|
|
117
123
|
[attr.maxlength]="options?.maxLength"
|
|
@@ -127,7 +133,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
127
133
|
[type]="layoutNode?.type"
|
|
128
134
|
[value]="controlValue"
|
|
129
135
|
(input)="updateValue($event)"
|
|
130
|
-
(blur)="options.showErrors = true"
|
|
136
|
+
(blur)="options.showErrors = true"
|
|
137
|
+
[attributes]="inputAttributes"
|
|
138
|
+
>
|
|
131
139
|
<span matSuffix *ngIf="options?.suffix || options?.fieldAddonRight"
|
|
132
140
|
[innerHTML]="options?.suffix || options?.fieldAddonRight"></span>
|
|
133
141
|
<mat-hint *ngIf="options?.description && (!options?.showErrors || !options?.errorMessage)"
|
|
@@ -157,4 +165,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
157
165
|
type: ViewChild,
|
|
158
166
|
args: ['input', {}]
|
|
159
167
|
}] } });
|
|
160
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
168
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWF0ZXJpYWwtaW5wdXQuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmctZm9ybXdvcmtzLW1hdGVyaWFsL3NyYy9saWIvd2lkZ2V0cy9tYXRlcmlhbC1pbnB1dC5jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBYyxNQUFNLEVBQUUsS0FBSyxFQUFVLFFBQVEsRUFBRSxTQUFTLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFFbEcsT0FBTyxFQUFFLDhC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fVxyXG59XHJcbiJdfQ==
|
|
@@ -1288,6 +1288,11 @@ class MaterialInputComponent {
|
|
|
1288
1288
|
this.boundControl = false;
|
|
1289
1289
|
this.autoCompleteList = [];
|
|
1290
1290
|
}
|
|
1291
|
+
//needed as templates don't accept something like [attributes]="options?.['x-inputAttributes']"
|
|
1292
|
+
get inputAttributes() {
|
|
1293
|
+
var _a;
|
|
1294
|
+
return (_a = this.options) === null || _a === void 0 ? void 0 : _a['x-inputAttributes'];
|
|
1295
|
+
}
|
|
1291
1296
|
ngOnInit() {
|
|
1292
1297
|
this.options = this.layoutNode.options || {};
|
|
1293
1298
|
this.jsf.initializeControl(this);
|
|
@@ -1321,10 +1326,10 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
1321
1326
|
[name]="controlName"
|
|
1322
1327
|
[placeholder]="options?.notitle ? options?.placeholder : options?.title"
|
|
1323
1328
|
[required]="options?.required"
|
|
1324
|
-
[style.width]="'100%'"
|
|
1325
1329
|
[type]="layoutNode?.type"
|
|
1326
|
-
(blur)="options.showErrors = true"
|
|
1327
|
-
|
|
1330
|
+
(blur)="options.showErrors = true"
|
|
1331
|
+
[attributes]="inputAttributes">
|
|
1332
|
+
<input #input matInput *ngIf="!boundControl"
|
|
1328
1333
|
[attr.aria-describedby]="'control' + layoutNode?._id + 'Status'"
|
|
1329
1334
|
[attr.list]="'control' + layoutNode?._id + 'Autocomplete'"
|
|
1330
1335
|
[attr.maxlength]="options?.maxLength"
|
|
@@ -1340,7 +1345,9 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
1340
1345
|
[type]="layoutNode?.type"
|
|
1341
1346
|
[value]="controlValue"
|
|
1342
1347
|
(input)="updateValue($event)"
|
|
1343
|
-
(blur)="options.showErrors = true"
|
|
1348
|
+
(blur)="options.showErrors = true"
|
|
1349
|
+
[attributes]="inputAttributes"
|
|
1350
|
+
>
|
|
1344
1351
|
<span matSuffix *ngIf="options?.suffix || options?.fieldAddonRight"
|
|
1345
1352
|
[innerHTML]="options?.suffix || options?.fieldAddonRight"></span>
|
|
1346
1353
|
<mat-hint *ngIf="options?.description && (!options?.showErrors || !options?.errorMessage)"
|
|
@@ -1354,7 +1361,7 @@ MaterialInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
|
|
|
1354
1361
|
</button>
|
|
1355
1362
|
</mat-form-field>
|
|
1356
1363
|
<mat-error *ngIf="options?.showErrors && options?.errorMessage"
|
|
1357
|
-
[innerHTML]="options?.errorMessage"></mat-error>`, isInline: true, styles: ["mat-error{font-size:75%;margin-top:-1rem;margin-bottom:.5rem}::ng-deep json-schema-form mat-form-field .mat-mdc-form-field-wrapper .mat-form-field-flex .mat-form-field-infix{width:initial}input{width:100%}input[type=datetime-local]{width:120%}\n"], dependencies: [{ kind: "directive", type: i2$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3$3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3$3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$3.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i3$3.MinLengthValidator, selector: "[minlength][formControlName],[minlength][formControl],[minlength][ngModel]", inputs: ["minlength"] }, { kind: "directive", type: i3$3.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i3$3.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i3$3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i4$4.MatAutocomplete, selector: "mat-autocomplete", inputs: ["disableRipple", "hideSingleSelectionIndicator"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i4$5.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "component", type: i3$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i5.MatLabel, selector: "mat-label" }, { kind: "directive", type: i5.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i5.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i5.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i5.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i4$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i5$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }] });
|
|
1364
|
+
[innerHTML]="options?.errorMessage"></mat-error>`, isInline: true, styles: ["mat-error{font-size:75%;margin-top:-1rem;margin-bottom:.5rem}::ng-deep json-schema-form mat-form-field .mat-mdc-form-field-wrapper .mat-form-field-flex .mat-form-field-infix{width:initial}input{width:100%}input[type=datetime-local]{width:120%}\n"], dependencies: [{ kind: "directive", type: i2$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3$3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3$3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$3.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i3$3.MinLengthValidator, selector: "[minlength][formControlName],[minlength][formControl],[minlength][ngModel]", inputs: ["minlength"] }, { kind: "directive", type: i3$3.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i3$3.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i3$3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i4$4.MatAutocomplete, selector: "mat-autocomplete", inputs: ["disableRipple", "hideSingleSelectionIndicator"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i4$5.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "component", type: i3$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i5.MatLabel, selector: "mat-label" }, { kind: "directive", type: i5.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i5.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i5.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i5.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i4$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i5$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: i1.ElementAttributeDirective, selector: "[attributes]", inputs: ["attributes"] }] });
|
|
1358
1365
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: MaterialInputComponent, decorators: [{
|
|
1359
1366
|
type: Component,
|
|
1360
1367
|
args: [{ selector: 'material-input-widget', template: `
|
|
@@ -1378,10 +1385,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
1378
1385
|
[name]="controlName"
|
|
1379
1386
|
[placeholder]="options?.notitle ? options?.placeholder : options?.title"
|
|
1380
1387
|
[required]="options?.required"
|
|
1381
|
-
[style.width]="'100%'"
|
|
1382
1388
|
[type]="layoutNode?.type"
|
|
1383
|
-
(blur)="options.showErrors = true"
|
|
1384
|
-
|
|
1389
|
+
(blur)="options.showErrors = true"
|
|
1390
|
+
[attributes]="inputAttributes">
|
|
1391
|
+
<input #input matInput *ngIf="!boundControl"
|
|
1385
1392
|
[attr.aria-describedby]="'control' + layoutNode?._id + 'Status'"
|
|
1386
1393
|
[attr.list]="'control' + layoutNode?._id + 'Autocomplete'"
|
|
1387
1394
|
[attr.maxlength]="options?.maxLength"
|
|
@@ -1397,7 +1404,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
1397
1404
|
[type]="layoutNode?.type"
|
|
1398
1405
|
[value]="controlValue"
|
|
1399
1406
|
(input)="updateValue($event)"
|
|
1400
|
-
(blur)="options.showErrors = true"
|
|
1407
|
+
(blur)="options.showErrors = true"
|
|
1408
|
+
[attributes]="inputAttributes"
|
|
1409
|
+
>
|
|
1401
1410
|
<span matSuffix *ngIf="options?.suffix || options?.fieldAddonRight"
|
|
1402
1411
|
[innerHTML]="options?.suffix || options?.fieldAddonRight"></span>
|
|
1403
1412
|
<mat-hint *ngIf="options?.description && (!options?.showErrors || !options?.errorMessage)"
|