@3kles/kles-material-dynamicforms 17.4.1 → 17.4.2
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/lib/directive/dynamic-component.directive.mjs +3 -3
- package/esm2022/lib/directive/dynamic-field.directive.mjs +3 -3
- package/esm2022/lib/dynamic-form.component.mjs +3 -3
- package/esm2022/lib/fields/array.component.mjs +3 -3
- package/esm2022/lib/fields/badge.component.mjs +3 -3
- package/esm2022/lib/fields/button-fab.component.mjs +3 -3
- package/esm2022/lib/fields/button-form.component.mjs +3 -3
- package/esm2022/lib/fields/button-icon.component.mjs +3 -3
- package/esm2022/lib/fields/button-mini-fab.component.mjs +3 -3
- package/esm2022/lib/fields/button-toogle-group.component.mjs +4 -4
- package/esm2022/lib/fields/buttonchecker-form.component.mjs +3 -3
- package/esm2022/lib/fields/buttonfile-form.component.mjs +3 -3
- package/esm2022/lib/fields/checkbox.component.mjs +3 -3
- package/esm2022/lib/fields/chip.component.mjs +3 -3
- package/esm2022/lib/fields/clear.component.mjs +3 -3
- package/esm2022/lib/fields/color.component.mjs +59 -13
- package/esm2022/lib/fields/date-time.component.mjs +6 -6
- package/esm2022/lib/fields/date.component.mjs +6 -6
- package/esm2022/lib/fields/field.abstract.mjs +7 -4
- package/esm2022/lib/fields/group.component.mjs +3 -3
- package/esm2022/lib/fields/icon.component.mjs +3 -3
- package/esm2022/lib/fields/input.clearable.component.mjs +6 -6
- package/esm2022/lib/fields/input.component.mjs +8 -8
- package/esm2022/lib/fields/label.component.mjs +3 -3
- package/esm2022/lib/fields/line-break.component.mjs +3 -3
- package/esm2022/lib/fields/link.component.mjs +3 -3
- package/esm2022/lib/fields/list-field.component.mjs +3 -3
- package/esm2022/lib/fields/radio.component.mjs +3 -3
- package/esm2022/lib/fields/range.component.mjs +8 -8
- package/esm2022/lib/fields/select.component.mjs +8 -8
- package/esm2022/lib/fields/select.lazy-search.component.mjs +8 -8
- package/esm2022/lib/fields/select.search.component.mjs +6 -6
- package/esm2022/lib/fields/selection-list.component.mjs +3 -3
- package/esm2022/lib/fields/selection-list.search.component.mjs +11 -8
- package/esm2022/lib/fields/slide-toggle.component.mjs +3 -3
- package/esm2022/lib/fields/text.component.mjs +3 -3
- package/esm2022/lib/fields/textarea.component.mjs +8 -8
- package/esm2022/lib/forms/button-control-base.mjs +3 -3
- package/esm2022/lib/forms/button-control.component.mjs +3 -3
- package/esm2022/lib/forms/buttonchecker-control.component.mjs +3 -3
- package/esm2022/lib/forms/buttonfile-control.component.mjs +3 -3
- package/esm2022/lib/forms/fab-control.component.mjs +3 -3
- package/esm2022/lib/forms/icon-button-control.component.mjs +3 -3
- package/esm2022/lib/forms/mini-fab-control.component.mjs +3 -3
- package/esm2022/lib/interfaces/field.config.interface.mjs +1 -1
- package/esm2022/lib/kles-material-dynamicforms.module.mjs +4 -4
- package/esm2022/lib/matcher/form-error.matcher.mjs +3 -3
- package/esm2022/lib/modules/material.module.mjs +4 -4
- package/esm2022/lib/pipe/array.pipe.mjs +3 -3
- package/esm2022/lib/pipe/transform.pipe.mjs +3 -3
- package/fesm2022/3kles-kles-material-dynamicforms.mjs +243 -191
- package/fesm2022/3kles-kles-material-dynamicforms.mjs.map +1 -1
- package/lib/interfaces/field.config.interface.d.ts +8 -0
- package/package.json +1 -1
|
@@ -26,10 +26,10 @@ export class KlesComponentDirective {
|
|
|
26
26
|
this.componentRef.instance.value = this.value;
|
|
27
27
|
this.componentRef.instance.field = this.field;
|
|
28
28
|
}
|
|
29
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
30
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.
|
|
29
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesComponentDirective, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
30
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.1", type: KlesComponentDirective, selector: "[klesComponent]", inputs: { component: "component", value: "value", field: "field" }, usesOnChanges: true, ngImport: i0 }); }
|
|
31
31
|
}
|
|
32
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
32
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesComponentDirective, decorators: [{
|
|
33
33
|
type: Directive,
|
|
34
34
|
args: [{
|
|
35
35
|
selector: '[klesComponent]'
|
|
@@ -68,10 +68,10 @@ export class KlesDynamicFieldDirective {
|
|
|
68
68
|
component.instance.siblingFields = this.siblingFields;
|
|
69
69
|
return component;
|
|
70
70
|
}
|
|
71
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
72
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.
|
|
71
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesDynamicFieldDirective, deps: [{ token: i0.ViewContainerRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
72
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.1", type: KlesDynamicFieldDirective, selector: "[klesDynamicField]", inputs: { field: "field", group: "group", siblingFields: "siblingFields" }, usesOnChanges: true, ngImport: i0 }); }
|
|
73
73
|
}
|
|
74
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
74
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesDynamicFieldDirective, decorators: [{
|
|
75
75
|
type: Directive,
|
|
76
76
|
args: [{
|
|
77
77
|
selector: '[klesDynamicField]'
|
|
@@ -151,8 +151,8 @@ export class KlesDynamicFormComponent {
|
|
|
151
151
|
control.markAsTouched({ onlySelf: true });
|
|
152
152
|
});
|
|
153
153
|
}
|
|
154
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
155
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
154
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesDynamicFormComponent, deps: [{ token: i1.UntypedFormBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
155
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesDynamicFormComponent, selector: "app-kles-dynamic-form", inputs: { fields: "fields", validators: "validators", asyncValidators: "asyncValidators", direction: "direction" }, outputs: { submit: "submit", _onLoaded: "_onLoaded" }, exportAs: ["klesDynamicForm"], usesOnChanges: true, ngImport: i0, template: `
|
|
156
156
|
<form class="{{orientationClass}}" [formGroup]="form" (submit)="onSubmit($event)">
|
|
157
157
|
@for (field of fields; track field.name) {
|
|
158
158
|
@if (field.visible !== false) {
|
|
@@ -163,7 +163,7 @@ export class KlesDynamicFormComponent {
|
|
|
163
163
|
</form>
|
|
164
164
|
`, isInline: true, styles: [".dynamic-form-column{display:flex;flex-direction:column}\n", ".dynamic-form-column>*{width:100%}\n", ".dynamic-form-row{display:inline-flex;flex-wrap:wrap;gap:10px}\n", ".dynamic-form-row>*{width:100%}\n", ".dynamic-form-row-item{margin-right:10px}\n", ".dynamic-form-column-item{margin-bottom:10px}\n"], dependencies: [{ kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.KlesDynamicFieldDirective, selector: "[klesDynamicField]", inputs: ["field", "group", "siblingFields"] }] }); }
|
|
165
165
|
}
|
|
166
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
166
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesDynamicFormComponent, decorators: [{
|
|
167
167
|
type: Component,
|
|
168
168
|
args: [{ exportAs: 'klesDynamicForm', selector: 'app-kles-dynamic-form', template: `
|
|
169
169
|
<form class="{{orientationClass}}" [formGroup]="form" (submit)="onSubmit($event)">
|
|
@@ -17,8 +17,8 @@ let KlesFormArrayComponent = class KlesFormArrayComponent extends KlesFieldAbstr
|
|
|
17
17
|
ngOnDestroy() {
|
|
18
18
|
super.ngOnDestroy();
|
|
19
19
|
}
|
|
20
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
21
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
20
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormArrayComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
21
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormArrayComponent, selector: "kles-array", usesInheritance: true, ngImport: i0, template: `
|
|
22
22
|
<div [formGroup]="group" class="container" [ngClass]="{'container-column': field.direction ==='column'}">
|
|
23
23
|
<ng-container [formArrayName]="field.name">
|
|
24
24
|
@for (subGroup of formArray.controls; track subGroup.value._id) {
|
|
@@ -39,7 +39,7 @@ KlesFormArrayComponent = __decorate([
|
|
|
39
39
|
FieldMapper({ type: EnumType.array, factory: (field) => (new KlesFormArray(field).create()) })
|
|
40
40
|
], KlesFormArrayComponent);
|
|
41
41
|
export { KlesFormArrayComponent };
|
|
42
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
42
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormArrayComponent, decorators: [{
|
|
43
43
|
type: Component,
|
|
44
44
|
args: [{ selector: 'kles-array', template: `
|
|
45
45
|
<div [formGroup]="group" class="container" [ngClass]="{'container-column': field.direction ==='column'}">
|
|
@@ -14,8 +14,8 @@ let KlesFormBadgeComponent = class KlesFormBadgeComponent extends KlesFieldAbstr
|
|
|
14
14
|
ngOnDestroy() {
|
|
15
15
|
super.ngOnDestroy();
|
|
16
16
|
}
|
|
17
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
18
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
17
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormBadgeComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
18
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormBadgeComponent, selector: "kles-form-badge", usesInheritance: true, ngImport: i0, template: `
|
|
19
19
|
<span matTooltip="{{field.tooltip}}" [attr.id]="field.id" [ngClass]="field.ngClass"
|
|
20
20
|
matBadge="{{group.controls[field.name].value}}" matBadgeOverlap="false" matBadgeColor="{{field.color}}">
|
|
21
21
|
</span>
|
|
@@ -25,7 +25,7 @@ KlesFormBadgeComponent = __decorate([
|
|
|
25
25
|
FieldMapper({ type: EnumType.badge })
|
|
26
26
|
], KlesFormBadgeComponent);
|
|
27
27
|
export { KlesFormBadgeComponent };
|
|
28
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
28
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormBadgeComponent, decorators: [{
|
|
29
29
|
type: Component,
|
|
30
30
|
args: [{
|
|
31
31
|
selector: 'kles-form-badge',
|
|
@@ -10,8 +10,8 @@ export class KlesFormFabComponent extends KlesFieldAbstract {
|
|
|
10
10
|
ngOnDestroy() {
|
|
11
11
|
super.ngOnDestroy();
|
|
12
12
|
}
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
14
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormFabComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormFabComponent, selector: "kles-form-fab", usesInheritance: true, ngImport: i0, template: `
|
|
15
15
|
<div [formGroup]="group">
|
|
16
16
|
<kles-fab
|
|
17
17
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -27,7 +27,7 @@ export class KlesFormFabComponent extends KlesFieldAbstract {
|
|
|
27
27
|
</div>
|
|
28
28
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesFabComponent, selector: "kles-fab" }] }); }
|
|
29
29
|
}
|
|
30
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormFabComponent, decorators: [{
|
|
31
31
|
type: Component,
|
|
32
32
|
args: [{ selector: 'kles-form-fab', template: `
|
|
33
33
|
<div [formGroup]="group">
|
|
@@ -10,8 +10,8 @@ export class KlesFormButtonComponent extends KlesFieldAbstract {
|
|
|
10
10
|
ngOnDestroy() {
|
|
11
11
|
super.ngOnDestroy();
|
|
12
12
|
}
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
14
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormButtonComponent, selector: "kles-form-button", usesInheritance: true, ngImport: i0, template: `
|
|
15
15
|
<div [formGroup]="group">
|
|
16
16
|
<kles-button
|
|
17
17
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -28,7 +28,7 @@ export class KlesFormButtonComponent extends KlesFieldAbstract {
|
|
|
28
28
|
</div>
|
|
29
29
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesButtonComponent, selector: "kles-button", inputs: ["attribute"] }] }); }
|
|
30
30
|
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonComponent, decorators: [{
|
|
32
32
|
type: Component,
|
|
33
33
|
args: [{ selector: 'kles-form-button', template: `
|
|
34
34
|
<div [formGroup]="group">
|
|
@@ -10,8 +10,8 @@ export class KlesFormIconButtonComponent extends KlesFieldAbstract {
|
|
|
10
10
|
ngOnDestroy() {
|
|
11
11
|
super.ngOnDestroy();
|
|
12
12
|
}
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
14
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormIconButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormIconButtonComponent, selector: "kles-form-icon-button", usesInheritance: true, ngImport: i0, template: `
|
|
15
15
|
<div [formGroup]="group">
|
|
16
16
|
<kles-icon-button
|
|
17
17
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -27,7 +27,7 @@ export class KlesFormIconButtonComponent extends KlesFieldAbstract {
|
|
|
27
27
|
</div>
|
|
28
28
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesIconButtonComponent, selector: "kles-icon-button" }] }); }
|
|
29
29
|
}
|
|
30
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormIconButtonComponent, decorators: [{
|
|
31
31
|
type: Component,
|
|
32
32
|
args: [{ selector: 'kles-form-icon-button', template: `
|
|
33
33
|
<div [formGroup]="group">
|
|
@@ -10,8 +10,8 @@ export class KlesFormMiniFabComponent extends KlesFieldAbstract {
|
|
|
10
10
|
ngOnDestroy() {
|
|
11
11
|
super.ngOnDestroy();
|
|
12
12
|
}
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
14
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormMiniFabComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormMiniFabComponent, selector: "kles-form-mini-fab", usesInheritance: true, ngImport: i0, template: `
|
|
15
15
|
<div [formGroup]="group">
|
|
16
16
|
<kles-mini-fab
|
|
17
17
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -27,7 +27,7 @@ export class KlesFormMiniFabComponent extends KlesFieldAbstract {
|
|
|
27
27
|
</div>
|
|
28
28
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesMiniFabComponent, selector: "kles-mini-fab" }] }); }
|
|
29
29
|
}
|
|
30
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormMiniFabComponent, decorators: [{
|
|
31
31
|
type: Component,
|
|
32
32
|
args: [{ selector: 'kles-form-mini-fab', template: `
|
|
33
33
|
<div [formGroup]="group">
|
|
@@ -22,8 +22,8 @@ export class KlesFormButtonToogleGroupComponent extends KlesFieldAbstract {
|
|
|
22
22
|
ngOnDestroy() {
|
|
23
23
|
super.ngOnDestroy();
|
|
24
24
|
}
|
|
25
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
26
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
25
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonToogleGroupComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
26
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormButtonToogleGroupComponent, selector: "kles-form-button-toogle-group", usesInheritance: true, ngImport: i0, template: `
|
|
27
27
|
<div [formGroup]="group" class="form-element">
|
|
28
28
|
<mat-button-toggle-group [formControlName]="field.name" [multiple]="field.multiple" [attr.id]="field.id" [ngClass]="field.ngClass">
|
|
29
29
|
@for (item of options$ | async; track item) {
|
|
@@ -33,9 +33,9 @@ export class KlesFormButtonToogleGroupComponent extends KlesFieldAbstract {
|
|
|
33
33
|
}
|
|
34
34
|
</mat-button-toggle-group>
|
|
35
35
|
</div>
|
|
36
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i3.MatButtonToggleGroup, selector: "mat-button-toggle-group", inputs: ["appearance", "name", "vertical", "value", "multiple", "disabled"], outputs: ["valueChange", "change"], exportAs: ["matButtonToggleGroup"] }, { kind: "component", type: i3.MatButtonToggle, selector: "mat-button-toggle", inputs: ["aria-label", "aria-labelledby", "id", "name", "value", "tabIndex", "disableRipple", "appearance", "checked", "disabled"], outputs: ["change"], exportAs: ["matButtonToggle"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.KlesTransformPipe, name: "klesTransform" }] }); }
|
|
36
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i3.MatButtonToggleGroup, selector: "mat-button-toggle-group", inputs: ["appearance", "name", "vertical", "value", "multiple", "disabled", "hideSingleSelectionIndicator", "hideMultipleSelectionIndicator"], outputs: ["valueChange", "change"], exportAs: ["matButtonToggleGroup"] }, { kind: "component", type: i3.MatButtonToggle, selector: "mat-button-toggle", inputs: ["aria-label", "aria-labelledby", "id", "name", "value", "tabIndex", "disableRipple", "appearance", "checked", "disabled"], outputs: ["change"], exportAs: ["matButtonToggle"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.KlesTransformPipe, name: "klesTransform" }] }); }
|
|
37
37
|
}
|
|
38
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
38
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonToogleGroupComponent, decorators: [{
|
|
39
39
|
type: Component,
|
|
40
40
|
args: [{
|
|
41
41
|
selector: 'kles-form-button-toogle-group',
|
|
@@ -10,8 +10,8 @@ export class KlesFormButtonCheckerComponent extends KlesFieldAbstract {
|
|
|
10
10
|
ngOnDestroy() {
|
|
11
11
|
super.ngOnDestroy();
|
|
12
12
|
}
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
14
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
13
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonCheckerComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
14
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormButtonCheckerComponent, selector: "kles-form-button-checker", usesInheritance: true, ngImport: i0, template: `
|
|
15
15
|
<div [formGroup]="group">
|
|
16
16
|
<kles-button-checker
|
|
17
17
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -27,7 +27,7 @@ export class KlesFormButtonCheckerComponent extends KlesFieldAbstract {
|
|
|
27
27
|
</div>
|
|
28
28
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesButtonCheckerComponent, selector: "kles-button-checker" }] }); }
|
|
29
29
|
}
|
|
30
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonCheckerComponent, decorators: [{
|
|
31
31
|
type: Component,
|
|
32
32
|
args: [{ selector: 'kles-form-button-checker', template: `
|
|
33
33
|
<div [formGroup]="group">
|
|
@@ -11,8 +11,8 @@ export class KlesFormButtonFileComponent extends KlesFieldAbstract {
|
|
|
11
11
|
ngOnDestroy() {
|
|
12
12
|
super.ngOnDestroy();
|
|
13
13
|
}
|
|
14
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
15
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
14
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonFileComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
15
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormButtonFileComponent, selector: "kles-form-button-file", usesInheritance: true, ngImport: i0, template: `
|
|
16
16
|
<div [formGroup]="group">
|
|
17
17
|
<kles-button-file
|
|
18
18
|
[attr.id]="field.id" [classButton]="field.ngClass"
|
|
@@ -29,7 +29,7 @@ export class KlesFormButtonFileComponent extends KlesFieldAbstract {
|
|
|
29
29
|
</div>
|
|
30
30
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.KlesButtonFileComponent, selector: "kles-button-file", inputs: ["accept"] }] }); }
|
|
31
31
|
}
|
|
32
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
32
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormButtonFileComponent, decorators: [{
|
|
33
33
|
type: Component,
|
|
34
34
|
args: [{ selector: 'kles-form-button-file', template: `
|
|
35
35
|
<div [formGroup]="group">
|
|
@@ -15,8 +15,8 @@ let KlesFormCheckboxComponent = class KlesFormCheckboxComponent extends KlesFiel
|
|
|
15
15
|
ngOnDestroy() {
|
|
16
16
|
super.ngOnDestroy();
|
|
17
17
|
}
|
|
18
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
19
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
18
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormCheckboxComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
19
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormCheckboxComponent, selector: "kles-form-checkbox", usesInheritance: true, ngImport: i0, template: `
|
|
20
20
|
<div [formGroup]="group" >
|
|
21
21
|
<mat-checkbox matTooltip="{{field.tooltip}}" [attr.id]="field.id" [ngClass]="field.ngClass" [indeterminate]="field.indeterminate" [color]="field.color" [formControlName]="field.name">{{field.label | translate}}</mat-checkbox>
|
|
22
22
|
@for (validation of field.validations; track validation.name) {
|
|
@@ -40,7 +40,7 @@ KlesFormCheckboxComponent = __decorate([
|
|
|
40
40
|
FieldMapper({ type: EnumType.checkbox })
|
|
41
41
|
], KlesFormCheckboxComponent);
|
|
42
42
|
export { KlesFormCheckboxComponent };
|
|
43
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
43
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormCheckboxComponent, decorators: [{
|
|
44
44
|
type: Component,
|
|
45
45
|
args: [{ selector: 'kles-form-checkbox', template: `
|
|
46
46
|
<div [formGroup]="group" >
|
|
@@ -12,8 +12,8 @@ export class KlesFormChipComponent extends KlesFieldAbstract {
|
|
|
12
12
|
ngOnDestroy() {
|
|
13
13
|
super.ngOnDestroy();
|
|
14
14
|
}
|
|
15
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
16
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
15
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormChipComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
16
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormChipComponent, selector: "kles-form-chip", usesInheritance: true, ngImport: i0, template: `
|
|
17
17
|
<div [formGroup]="group">
|
|
18
18
|
<mat-chip-listbox>
|
|
19
19
|
<mat-chip-option [color]="field.color" matTooltip="{{field.tooltip}}" [attr.id]="field.id" selected [ngClass]="field.ngClass" [ngStyle]="field.ngStyle">
|
|
@@ -26,7 +26,7 @@ export class KlesFormChipComponent extends KlesFieldAbstract {
|
|
|
26
26
|
</div>
|
|
27
27
|
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i4.MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: i4.MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "directive", type: i5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: i6.KlesTransformPipe, name: "klesTransform" }] }); }
|
|
28
28
|
}
|
|
29
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
29
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormChipComponent, decorators: [{
|
|
30
30
|
type: Component,
|
|
31
31
|
args: [{ selector: "kles-form-chip", template: `
|
|
32
32
|
<div [formGroup]="group">
|
|
@@ -7,15 +7,15 @@ export class KlesFormClearComponent {
|
|
|
7
7
|
event.stopPropagation();
|
|
8
8
|
this.group.controls[this.field.name].reset();
|
|
9
9
|
}
|
|
10
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
11
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.
|
|
10
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormClearComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
11
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.1", type: KlesFormClearComponent, selector: "kles-form-clear", ngImport: i0, template: `
|
|
12
12
|
<button [disabled]="!group.get(field.name).value || group.get(field.name).disabled" mat-icon-button aria-label="Clear" type="button"
|
|
13
13
|
(click)="clear($event)">
|
|
14
14
|
<mat-icon>close</mat-icon>
|
|
15
15
|
</button>
|
|
16
16
|
`, isInline: true, dependencies: [{ kind: "component", type: i1.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }] }); }
|
|
17
17
|
}
|
|
18
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
18
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormClearComponent, decorators: [{
|
|
19
19
|
type: Component,
|
|
20
20
|
args: [{
|
|
21
21
|
selector: 'kles-form-clear',
|
|
@@ -9,7 +9,41 @@ import * as i5 from "@angular/material/tooltip";
|
|
|
9
9
|
import * as i6 from "ngx-color-picker";
|
|
10
10
|
import * as i7 from "@ngx-translate/core";
|
|
11
11
|
export class KlesFormColorComponent extends KlesFieldAbstract {
|
|
12
|
-
ngOnInit() {
|
|
12
|
+
ngOnInit() {
|
|
13
|
+
if (!this.field.colorOption) {
|
|
14
|
+
this.field.colorOption = {
|
|
15
|
+
position: 'auto',
|
|
16
|
+
mode: 'color',
|
|
17
|
+
format: 'auto',
|
|
18
|
+
positionOffset: '0%'
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
if (!this.field.colorOption.position) {
|
|
22
|
+
this.field.colorOption = {
|
|
23
|
+
...this.field.colorOption,
|
|
24
|
+
position: 'auto'
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
if (!this.field.colorOption.mode) {
|
|
28
|
+
this.field.colorOption = {
|
|
29
|
+
...this.field.colorOption,
|
|
30
|
+
mode: 'color'
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
if (!this.field.colorOption.format) {
|
|
34
|
+
this.field.colorOption = {
|
|
35
|
+
...this.field.colorOption,
|
|
36
|
+
format: 'auto'
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
if (!this.field.colorOption.positionOffset) {
|
|
40
|
+
this.field.colorOption = {
|
|
41
|
+
...this.field.colorOption,
|
|
42
|
+
positionOffset: '0%'
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
super.ngOnInit();
|
|
46
|
+
}
|
|
13
47
|
invertColor(hex, bw) {
|
|
14
48
|
if (hex.indexOf('#') === 0) {
|
|
15
49
|
hex = hex.slice(1);
|
|
@@ -39,13 +73,19 @@ export class KlesFormColorComponent extends KlesFieldAbstract {
|
|
|
39
73
|
ngOnDestroy() {
|
|
40
74
|
super.ngOnDestroy();
|
|
41
75
|
}
|
|
42
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
43
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
44
|
-
<mat-form-field [subscriptSizing]="field.subscriptSizing" [formGroup]="group" class="form-element"
|
|
76
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormColorComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
77
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormColorComponent, selector: "kles-form-color", usesInheritance: true, ngImport: i0, template: `
|
|
78
|
+
<mat-form-field [subscriptSizing]="field.subscriptSizing" [formGroup]="group" class="form-element"
|
|
79
|
+
[colorPicker]="group.get(field.name).value"
|
|
80
|
+
(colorPickerChange)="group.get(field.name).setValue($event)"
|
|
81
|
+
[cpPosition]="field.colorOption.position"
|
|
82
|
+
[cpColorMode]="field.colorOption.mode"
|
|
83
|
+
[cpOutputFormat]="field.colorOption.format"
|
|
84
|
+
[cpPositionOffset]="field.colorOption.positionOffset"
|
|
85
|
+
[appearance]="field.appearance"
|
|
86
|
+
>
|
|
45
87
|
<input matInput matTooltip="{{field.tooltip}}" [attr.id]="field.id" [ngClass]="field.ngClass" [placeholder]="field.placeholder | translate"
|
|
46
|
-
[colorPicker]="group.get(field.name).value"
|
|
47
88
|
[value]="group.get(field.name).value"
|
|
48
|
-
(colorPickerChange)="group.get(field.name).setValue($event)"
|
|
49
89
|
class="colorPicker"
|
|
50
90
|
[style.background]="group.get(field.name).value"
|
|
51
91
|
[style.color]="invertColor(group.get(field.name).value,true)"
|
|
@@ -56,7 +96,7 @@ export class KlesFormColorComponent extends KlesFieldAbstract {
|
|
|
56
96
|
<ng-content></ng-content>
|
|
57
97
|
</div>
|
|
58
98
|
}
|
|
59
|
-
|
|
99
|
+
|
|
60
100
|
@for (validation of field.validations; track validation.name) {
|
|
61
101
|
<ng-container ngProjectAs="mat-error">
|
|
62
102
|
@if (group.get(field.name).hasError(validation.name)) {
|
|
@@ -74,14 +114,20 @@ export class KlesFormColorComponent extends KlesFieldAbstract {
|
|
|
74
114
|
</mat-form-field>
|
|
75
115
|
`, isInline: true, styles: ["mat-form-field{width:100%}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i3.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: "component", type: i4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i4.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: i6.ColorPickerDirective, selector: "[colorPicker]", inputs: ["colorPicker", "cpWidth", "cpHeight", "cpToggle", "cpDisabled", "cpIgnoredElements", "cpFallbackColor", "cpColorMode", "cpCmykEnabled", "cpOutputFormat", "cpAlphaChannel", "cpDisableInput", "cpDialogDisplay", "cpSaveClickOutside", "cpCloseClickOutside", "cpUseRootViewContainer", "cpPosition", "cpPositionOffset", "cpPositionRelativeToArrow", "cpOKButton", "cpOKButtonText", "cpOKButtonClass", "cpCancelButton", "cpCancelButtonText", "cpCancelButtonClass", "cpEyeDropper", "cpPresetLabel", "cpPresetColors", "cpPresetColorsClass", "cpMaxPresetColorsLength", "cpPresetEmptyMessage", "cpPresetEmptyMessageClass", "cpAddColorButton", "cpAddColorButtonText", "cpAddColorButtonClass", "cpRemoveColorButtonClass", "cpArrowPosition", "cpExtraTemplate"], outputs: ["cpInputChange", "cpToggleChange", "cpSliderChange", "cpSliderDragEnd", "cpSliderDragStart", "colorPickerOpen", "colorPickerClose", "colorPickerCancel", "colorPickerSelect", "colorPickerChange", "cpCmykColorChange", "cpPresetColorsChange"], exportAs: ["ngxColorPicker"] }, { kind: "pipe", type: i7.TranslatePipe, name: "translate" }] }); }
|
|
76
116
|
}
|
|
77
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
117
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormColorComponent, decorators: [{
|
|
78
118
|
type: Component,
|
|
79
119
|
args: [{ selector: 'kles-form-color', template: `
|
|
80
|
-
<mat-form-field [subscriptSizing]="field.subscriptSizing" [formGroup]="group" class="form-element"
|
|
120
|
+
<mat-form-field [subscriptSizing]="field.subscriptSizing" [formGroup]="group" class="form-element"
|
|
121
|
+
[colorPicker]="group.get(field.name).value"
|
|
122
|
+
(colorPickerChange)="group.get(field.name).setValue($event)"
|
|
123
|
+
[cpPosition]="field.colorOption.position"
|
|
124
|
+
[cpColorMode]="field.colorOption.mode"
|
|
125
|
+
[cpOutputFormat]="field.colorOption.format"
|
|
126
|
+
[cpPositionOffset]="field.colorOption.positionOffset"
|
|
127
|
+
[appearance]="field.appearance"
|
|
128
|
+
>
|
|
81
129
|
<input matInput matTooltip="{{field.tooltip}}" [attr.id]="field.id" [ngClass]="field.ngClass" [placeholder]="field.placeholder | translate"
|
|
82
|
-
[colorPicker]="group.get(field.name).value"
|
|
83
130
|
[value]="group.get(field.name).value"
|
|
84
|
-
(colorPickerChange)="group.get(field.name).setValue($event)"
|
|
85
131
|
class="colorPicker"
|
|
86
132
|
[style.background]="group.get(field.name).value"
|
|
87
133
|
[style.color]="invertColor(group.get(field.name).value,true)"
|
|
@@ -92,7 +138,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImpor
|
|
|
92
138
|
<ng-content></ng-content>
|
|
93
139
|
</div>
|
|
94
140
|
}
|
|
95
|
-
|
|
141
|
+
|
|
96
142
|
@for (validation of field.validations; track validation.name) {
|
|
97
143
|
<ng-container ngProjectAs="mat-error">
|
|
98
144
|
@if (group.get(field.name).hasError(validation.name)) {
|
|
@@ -110,4 +156,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImpor
|
|
|
110
156
|
</mat-form-field>
|
|
111
157
|
`, styles: ["mat-form-field{width:100%}\n"] }]
|
|
112
158
|
}] });
|
|
113
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
159
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJm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CwgYncpOiBzdHJpbmcge1xuICAgIGlmIChoZXguaW5kZXhPZignIycpID09PSAwKSB7XG4gICAgICBoZXggPSBoZXguc2xpY2UoMSk7XG4gICAgfVxuICAgIC8vIGNvbnZlcnQgMy1kaWdpdCBoZXggdG8gNi1kaWdpdHMuXG4gICAgaWYgKGhleC5sZW5ndGggPT09IDMpIHtcbiAgICAgIGhleCA9IGhleFswXSArIGhleFswXSArIGhleFsxXSArIGhleFsxXSArIGhleFsyXSArIGhleFsyXTtcbiAgICB9XG4gICAgaWYgKGhleC5sZW5ndGggIT09IDYpIHtcbiAgICAgIHJldHVybiAnIzAwMDAwMCc7XG4gICAgfVxuICAgIGxldCByID0gcGFyc2VJbnQoaGV4LnNsaWNlKDAsIDIpLCAxNik7XG4gICAgbGV0IGcgPSBwYXJzZUludChoZXguc2xpY2UoMiwgNCksIDE2KTtcbiAgICBsZXQgYiA9IHBhcnNlSW50KGhleC5zbGljZSg0LCA2KSwgMTYpO1xuICAgIGlmIChidykge1xuICAgICAgcmV0dXJuIChyICogMC4yOTkgKyBnICogMC41ODcgKyBiICogMC4xMTQpID4gMTg2XG4gICAgICAgID8gJyMwMDAwMDAnXG4gICAgICAgIDogJyNGRkZGRkYnO1xuICAgIH1cbiAgICAvLyBpbnZlcnQgY29sb3IgY29tcG9uZW50c1xuICAgIGNvbnN0IHIxID0gKDI1NSAtIHIpLnRvU3RyaW5nKDE2KTtcbiAgICBjb25zdCBnMSA9ICgyNTUgLSBnKS50b1N0cmluZygxNik7XG4gICAgY29uc3QgYjEgPSAoMjU1IC0gYikudG9TdHJpbmcoMTYpO1xuICAgIC8vIHBhZCBlYWNoIHdpdGggemVyb3MgYW5kIHJldHVyblxuICAgIHJldHVybiBcIiNcIiArIHIxICsgZzEgKyBiMTtcbiAgfVxuXG4gIG5nT25EZXN0cm95KCk6IHZvaWQge1xuICAgIHN1cGVyLm5nT25EZXN0cm95KCk7XG4gIH1cbn1cbiJdfQ==
|
|
@@ -14,9 +14,9 @@ export class KlesFormDateTimeComponent extends KlesFieldAbstract {
|
|
|
14
14
|
ngOnDestroy() {
|
|
15
15
|
super.ngOnDestroy();
|
|
16
16
|
}
|
|
17
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
18
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.
|
|
19
|
-
<mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group">
|
|
17
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormDateTimeComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
18
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.3.1", type: KlesFormDateTimeComponent, selector: "kles-form-datetimepicker", usesInheritance: true, ngImport: i0, template: `
|
|
19
|
+
<mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group" [appearance]="field.appearance">
|
|
20
20
|
@if (field.label) {
|
|
21
21
|
<mat-label>{{field.label}}</mat-label>
|
|
22
22
|
}
|
|
@@ -48,10 +48,10 @@ export class KlesFormDateTimeComponent extends KlesFieldAbstract {
|
|
|
48
48
|
</mat-form-field>
|
|
49
49
|
`, isInline: true, styles: ["mat-form-field{width:100%}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i3.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: "component", type: i4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i4.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i4.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i5.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i5.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "directive", type: i6.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: i7.KlesMatDatepicker, selector: "kles-mat-datepicker", outputs: ["timeSelected"], exportAs: ["klesMatDatepicker"] }, { kind: "pipe", type: i8.TranslatePipe, name: "translate" }] }); }
|
|
50
50
|
}
|
|
51
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
51
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: KlesFormDateTimeComponent, decorators: [{
|
|
52
52
|
type: Component,
|
|
53
53
|
args: [{ selector: "kles-form-datetimepicker", template: `
|
|
54
|
-
<mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group">
|
|
54
|
+
<mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group" [appearance]="field.appearance">
|
|
55
55
|
@if (field.label) {
|
|
56
56
|
<mat-label>{{field.label}}</mat-label>
|
|
57
57
|
}
|
|
@@ -83,4 +83,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImpor
|
|
|
83
83
|
</mat-form-field>
|
|
84
84
|
`, styles: ["mat-form-field{width:100%}\n"] }]
|
|
85
85
|
}] });
|
|
86
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
86
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS10aW1lLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2tsZXMtbWF0ZXJpYWwtZHluYW1pY2Zvcm1zL3NyYy9saWIvZmllbGRzL2RhdGUtdGltZS5jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBcUIsTUFBTSxlQUFlLENBQUM7QUFDN0QsT0FBTyxFQUFFLGlCQUFpQixFQUFFLE1BQU0sa0JBQWtCLENBQUM7Ozs7Ozs7Ozs7QUFzQ3JELE1BQU0sT0FBTyx5QkFBMEIsU0FBUSxpQkFBaUI7SUFDNUQsUUFBUSxLQUFLLEtBQUssQ0FBQyxRQUFRLEVBQUUsQ0FBQyxDQUFD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ZmllbGQubmdDbGFzc1wiIFttYXREYXRlcGlja2VyXT1cInBpY2tlclwiIFtmb3JtQ29udHJvbE5hbWVdPVwiZmllbGQubmFtZVwiIFtwbGFjZWhvbGRlcl09XCJmaWVsZC5wbGFjZWhvbGRlciB8IHRyYW5zbGF0ZVwiXG4gICAgICAgIFttaW5dPVwiZmllbGQubWluXCIgW21heF09XCJmaWVsZC5tYXhcIj5cbiAgICAgICAgPGRpdiBtYXRTdWZmaXg+XG4gICAgICAgICAgICA8bWF0LWRhdGVwaWNrZXItdG9nZ2xlIFtmb3JdPVwicGlja2VyXCI+PC9tYXQtZGF0ZXBpY2tlci10b2dnbGU+XG4gICAgICAgICAgICA8bmctY29udGVudD48L25nLWNvbnRlbnQ+XG4gICAgICAgIDwvZGl2PlxuICAgICAgICA8a2xlcy1tYXQtZGF0ZXBpY2tlciAjcGlja2VyIFtoYXNCYWNrZHJvcF09XCJmYWxzZVwiPjwva2xlcy1tYXQtZGF0ZXBpY2tlcj5cbiAgICAgICAgQGlmIChmaWVsZC5oaW50KSB7XG4gICAgICAgICAgICA8bWF0LWhpbnQ+e3tmaWVsZC5oaW50fX08L21hdC1oaW50PlxuICAgICAgICB9XG5cbiAgICAgICAgQGZvciAodmFsaWRhdGlvbiBvZiBmaWVsZC52YWxpZGF0aW9uczsgdHJhY2sgdmFsaWRhdGlvbi5uYW1lKSB7XG4gICAgICAgICAgICA8bmctY29udGFpbmVyIG5nUHJvamVjdEFzPVwibWF0LWVycm9yXCI+XG4gICAgICAgICAgICAgICAgQGlmIChncm91cC5nZXQoZmllbGQubmFtZSkuaGFzRXJyb3IodmFsaWRhdGlvbi5uYW1lKSkge1xuICAgICAgICAgICAgICAgICAgICA8bWF0LWVycm9yPnt7dmFsaWRhdGlvbi5tZXNzYWdlIHwgdHJhbnNsYXRlfX08L21hdC1lcnJvcj5cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICA8L25nLWNvbnRhaW5lcj5cbiAgICAgICAgfVxuICAgICA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