@3kles/kles-material-dynamicforms 21.0.2 → 21.1.0

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.
@@ -65,8 +65,6 @@ import { TextFieldModule } from '@angular/cdk/text-field';
65
65
  import * as i4$2 from 'ngx-mat-select-search';
66
66
  import { NgxMatSelectSearchModule } from 'ngx-mat-select-search';
67
67
  import { getMultipleValuesInSingleSelectionError } from '@angular/cdk/collections';
68
- import * as i5$1 from '@ngx-translate/core';
69
- import { TranslateModule } from '@ngx-translate/core';
70
68
  import * as i4$4 from '@3kles/kles-material-datepicker';
71
69
  import { KlesMaterialDatepickerModule } from '@3kles/kles-material-datepicker';
72
70
  import * as i1$2 from '@angular/cdk/clipboard';
@@ -217,6 +215,7 @@ class KlesFormUiControl extends KlesAbstractFormUiControl {
217
215
  icon: this.field.icon,
218
216
  iconSvg: this.field.iconSvg,
219
217
  appearance: this.field.appearance ?? 'fill',
218
+ buttonAppearance: this.field.buttonAppearance ?? 'text'
220
219
  });
221
220
  }
222
221
  }
@@ -308,7 +307,7 @@ class KlesFormClearComponent {
308
307
  }
309
308
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormClearComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
310
309
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: KlesFormClearComponent, isStandalone: true, selector: "kles-form-clear", ngImport: i0, template: `
311
- <button [disabled]="disabled()" mat-icon-button aria-label="Clear" type="button" (click)="clear($event)">
310
+ <button [disabled]="disabled()" matIconButton aria-label="Clear" type="button" (click)="clear($event)">
312
311
  <mat-icon>close</mat-icon>
313
312
  </button>
314
313
  `, isInline: true, dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }] }); }
@@ -318,7 +317,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
318
317
  args: [{
319
318
  selector: 'kles-form-clear',
320
319
  template: `
321
- <button [disabled]="disabled()" mat-icon-button aria-label="Clear" type="button" (click)="clear($event)">
320
+ <button [disabled]="disabled()" matIconButton aria-label="Clear" type="button" (click)="clear($event)">
322
321
  <mat-icon>close</mat-icon>
323
322
  </button>
324
323
  `,
@@ -1151,6 +1150,7 @@ class KlesFieldAbstract {
1151
1150
  this.color = computed(() => this.ui?.get(this.field.name)?.value()?.color, ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
1152
1151
  this.icon = computed(() => this.ui?.get(this.field.name)?.value()?.icon, ...(ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []));
1153
1152
  this.iconSvg = computed(() => this.ui?.get(this.field.name)?.value()?.iconSvg, ...(ngDevMode ? [{ debugName: "iconSvg" }] : /* istanbul ignore next */ []));
1153
+ this.buttonAppearance = computed(() => this.ui?.get(this.field.name)?.value()?.buttonAppearance, ...(ngDevMode ? [{ debugName: "buttonAppearance" }] : /* istanbul ignore next */ []));
1154
1154
  this.viewRef = inject(ViewContainerRef);
1155
1155
  this._onDestroy = new Subject();
1156
1156
  if (this.field.directive) {
@@ -2205,7 +2205,7 @@ let KlesFormListFieldComponent = class KlesFormListFieldComponent extends KlesFi
2205
2205
  <div [formGroup]="group" class="form-element">
2206
2206
  <div class="label">
2207
2207
  {{ field.label }}
2208
- <button mat-icon-button color="primary" (click)="addField()">
2208
+ <button matIconButton color="primary" (click)="addField()">
2209
2209
  <mat-icon>add</mat-icon>
2210
2210
  </button>
2211
2211
  </div>
@@ -2217,7 +2217,7 @@ let KlesFormListFieldComponent = class KlesFormListFieldComponent extends KlesFi
2217
2217
  <ng-container klesDynamicField [field]="subfield" [group]="subGroup" [siblingFields]="collections[idx]"> </ng-container>
2218
2218
  }
2219
2219
  @if (collections[idx]) {
2220
- <button mat-icon-button (click)="deleteField(idx)" color="primary">
2220
+ <button matIconButton (click)="deleteField(idx)" color="primary">
2221
2221
  <mat-icon>delete_outlined</mat-icon>
2222
2222
  </button>
2223
2223
  }
@@ -2250,7 +2250,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2250
2250
  <div [formGroup]="group" class="form-element">
2251
2251
  <div class="label">
2252
2252
  {{ field.label }}
2253
- <button mat-icon-button color="primary" (click)="addField()">
2253
+ <button matIconButton color="primary" (click)="addField()">
2254
2254
  <mat-icon>add</mat-icon>
2255
2255
  </button>
2256
2256
  </div>
@@ -2262,7 +2262,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2262
2262
  <ng-container klesDynamicField [field]="subfield" [group]="subGroup" [siblingFields]="collections[idx]"> </ng-container>
2263
2263
  }
2264
2264
  @if (collections[idx]) {
2265
- <button mat-icon-button (click)="deleteField(idx)" color="primary">
2265
+ <button matIconButton (click)="deleteField(idx)" color="primary">
2266
2266
  <mat-icon>delete_outlined</mat-icon>
2267
2267
  </button>
2268
2268
  }
@@ -2436,6 +2436,7 @@ class KlesButtonBase {
2436
2436
  this.disabled = false;
2437
2437
  this.classButton = '';
2438
2438
  this.value = {};
2439
+ this.buttonAppearance = 'text';
2439
2440
  this._type = 'button';
2440
2441
  this.onChange = () => { };
2441
2442
  this.onTouched = () => { };
@@ -2470,6 +2471,7 @@ class KlesButtonBase {
2470
2471
  this.disabled = (uiButton.disabled) ? uiButton.disabled : this.disabled;
2471
2472
  this.classButton = (uiButton.class) ? uiButton.class : this.classButton;
2472
2473
  this.type = (uiButton.type) ? uiButton.type : 'submit';
2474
+ this.buttonAppearance = (uiButton.buttonAppearance) ? uiButton.buttonAppearance : this.buttonAppearance;
2473
2475
  }
2474
2476
  this.value = value;
2475
2477
  }
@@ -2483,7 +2485,7 @@ class KlesButtonBase {
2483
2485
  this.disabled = isDisabled;
2484
2486
  }
2485
2487
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesButtonBase, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2486
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: KlesButtonBase, isStandalone: true, selector: "ng-component", inputs: { name: "name", label: "label", color: "color", icon: "icon", iconSvg: "iconSvg", disabled: "disabled", type: "type", classButton: "classButton", value: "value", tooltip: "tooltip" }, ngImport: i0, template: '', isInline: true }); }
2488
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: KlesButtonBase, isStandalone: true, selector: "ng-component", inputs: { name: "name", label: "label", color: "color", icon: "icon", iconSvg: "iconSvg", disabled: "disabled", type: "type", classButton: "classButton", value: "value", tooltip: "tooltip", buttonAppearance: "buttonAppearance" }, ngImport: i0, template: '', isInline: true }); }
2487
2489
  }
2488
2490
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesButtonBase, decorators: [{
2489
2491
  type: Component,
@@ -2512,54 +2514,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2512
2514
  type: Input
2513
2515
  }], tooltip: [{
2514
2516
  type: Input
2517
+ }], buttonAppearance: [{
2518
+ type: Input
2515
2519
  }] } });
2516
2520
 
2517
- var EnumButtonAttribute;
2518
- (function (EnumButtonAttribute) {
2519
- EnumButtonAttribute["mat-button"] = "mat-button";
2520
- EnumButtonAttribute["mat-flat-button"] = "mat-flat-button";
2521
- EnumButtonAttribute["mat-raised-button"] = "mat-raised-button";
2522
- EnumButtonAttribute["mat-stroked-button"] = "mat-stroked-button";
2523
- })(EnumButtonAttribute || (EnumButtonAttribute = {}));
2524
-
2525
- /*From angular material
2526
- https://github.com/angular/components/blob/17.0.x/src/material/button/button-base.ts#L40C1-L56C5
2527
- */
2528
- const HOST_SELECTOR_MDC_CLASS_PAIR = [
2529
- {
2530
- attribute: EnumButtonAttribute['mat-button'],
2531
- mdcClasses: ['mdc-button', 'mat-mdc-button'],
2532
- },
2533
- {
2534
- attribute: EnumButtonAttribute['mat-flat-button'],
2535
- mdcClasses: ['mdc-button', 'mdc-button--unelevated', 'mat-mdc-unelevated-button'],
2536
- },
2537
- {
2538
- attribute: EnumButtonAttribute['mat-raised-button'],
2539
- mdcClasses: ['mdc-button', 'mdc-button--raised', 'mat-mdc-raised-button'],
2540
- },
2541
- {
2542
- attribute: EnumButtonAttribute['mat-stroked-button'],
2543
- mdcClasses: ['mdc-button', 'mdc-button--outlined', 'mat-mdc-outlined-button'],
2544
- }
2545
- ];
2546
2521
  class KlesButtonComponent extends KlesButtonBase {
2547
- constructor() {
2548
- super(...arguments);
2549
- this.mdcClasses = signal(HOST_SELECTOR_MDC_CLASS_PAIR[0].mdcClasses, ...(ngDevMode ? [{ debugName: "mdcClasses" }] : /* istanbul ignore next */ []));
2550
- }
2551
- set attribute(attribute) {
2552
- this.mdcClasses.set(HOST_SELECTOR_MDC_CLASS_PAIR.find(selector => selector.attribute === attribute)?.mdcClasses || []);
2553
- }
2554
2522
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
2555
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.19", type: KlesButtonComponent, isStandalone: true, selector: "kles-button", inputs: { attribute: "attribute" }, providers: [
2523
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.19", type: KlesButtonComponent, isStandalone: true, selector: "kles-button", providers: [
2556
2524
  {
2557
2525
  provide: NG_VALUE_ACCESSOR,
2558
2526
  useExisting: forwardRef(() => KlesButtonComponent),
2559
2527
  multi: true
2560
2528
  }
2561
2529
  ], usesInheritance: true, ngImport: i0, template: `
2562
- <button mat-button [type]="type" [ngClass]="classButton || mdcClasses()" [color]="(color)?color:'primary'" [disabled]="disabled"
2530
+ <button [matButton]="buttonAppearance" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
2563
2531
  (click)="click($event)" [matTooltip]="tooltip">
2564
2532
  {{label}}
2565
2533
 
@@ -2578,7 +2546,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2578
2546
  args: [{
2579
2547
  selector: 'kles-button',
2580
2548
  template: `
2581
- <button mat-button [type]="type" [ngClass]="classButton || mdcClasses()" [color]="(color)?color:'primary'" [disabled]="disabled"
2549
+ <button [matButton]="buttonAppearance" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
2582
2550
  (click)="click($event)" [matTooltip]="tooltip">
2583
2551
  {{label}}
2584
2552
 
@@ -2601,9 +2569,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2601
2569
  standalone: true,
2602
2570
  imports: [CommonModule, ReactiveFormsModule, MatIcon, MatTooltip, MatButton]
2603
2571
  }]
2604
- }], propDecorators: { attribute: [{
2605
- type: Input
2606
- }] } });
2572
+ }] });
2607
2573
 
2608
2574
  class KlesFormButtonComponent extends KlesFieldAbstract {
2609
2575
  ngOnInit() {
@@ -2621,17 +2587,17 @@ class KlesFormButtonComponent extends KlesFieldAbstract {
2621
2587
  [name]="field.name"
2622
2588
  [label]="field.label"
2623
2589
  [color]="color()"
2624
- [attribute]="field.attribute"
2625
2590
  [icon]="icon()"
2626
2591
  [iconSvg]="iconSvg()"
2627
2592
  [value]="field.value"
2628
2593
  [formControlName]="field.name"
2629
2594
  [tooltip]="field.tooltip"
2630
2595
  [type]="field.buttonType"
2596
+ [buttonAppearance]="buttonAppearance()"
2631
2597
  >
2632
2598
  </kles-button>
2633
2599
  </div>
2634
- `, isInline: true, dependencies: [{ kind: "component", type: KlesButtonComponent, selector: "kles-button", inputs: ["attribute"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],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"] }] }); }
2600
+ `, isInline: true, dependencies: [{ kind: "component", type: KlesButtonComponent, selector: "kles-button" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],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"] }] }); }
2635
2601
  }
2636
2602
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormButtonComponent, decorators: [{
2637
2603
  type: Component,
@@ -2643,13 +2609,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
2643
2609
  [name]="field.name"
2644
2610
  [label]="field.label"
2645
2611
  [color]="color()"
2646
- [attribute]="field.attribute"
2647
2612
  [icon]="icon()"
2648
2613
  [iconSvg]="iconSvg()"
2649
2614
  [value]="field.value"
2650
2615
  [formControlName]="field.name"
2651
2616
  [tooltip]="field.tooltip"
2652
2617
  [type]="field.buttonType"
2618
+ [buttonAppearance]="buttonAppearance()"
2653
2619
  >
2654
2620
  </kles-button>
2655
2621
  </div>
@@ -2693,7 +2659,7 @@ class KlesButtonCheckerComponent extends KlesButtonBase {
2693
2659
  </span>
2694
2660
  }
2695
2661
  </span>
2696
- `, isInline: true, dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "component", type: KlesButtonComponent, selector: "kles-button", inputs: ["attribute"] }, { kind: "component", type: MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "directive", type: MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }] }); }
2662
+ `, isInline: true, dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "component", type: KlesButtonComponent, selector: "kles-button" }, { kind: "component", type: MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "directive", type: MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }] }); }
2697
2663
  }
2698
2664
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesButtonCheckerComponent, decorators: [{
2699
2665
  type: Component,
@@ -2860,7 +2826,7 @@ class KlesButtonFileComponent extends KlesButtonBase {
2860
2826
  [disabled]="disabled"
2861
2827
  [value]="value" (click)="click($event)">
2862
2828
  </kles-button>
2863
- `, isInline: true, dependencies: [{ kind: "component", type: KlesButtonComponent, selector: "kles-button", inputs: ["attribute"] }] }); }
2829
+ `, isInline: true, dependencies: [{ kind: "component", type: KlesButtonComponent, selector: "kles-button" }] }); }
2864
2830
  }
2865
2831
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesButtonFileComponent, decorators: [{
2866
2832
  type: Component,
@@ -3280,7 +3246,7 @@ class KlesFormInputClearableComponent extends KlesFormInputComponent {
3280
3246
  />
3281
3247
  }
3282
3248
  @if (!group.get(field.name).disabled) {
3283
- <button matSuffix mat-icon-button aria-label="Clear" type="button" (click)="group.controls[field.name].reset()">
3249
+ <button matSuffix matIconButton aria-label="Clear" type="button" (click)="group.controls[field.name].reset()">
3284
3250
  <mat-icon>close</mat-icon>
3285
3251
  </button>
3286
3252
  }
@@ -3357,7 +3323,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
3357
3323
  />
3358
3324
  }
3359
3325
  @if (!group.get(field.name).disabled) {
3360
- <button matSuffix mat-icon-button aria-label="Clear" type="button" (click)="group.controls[field.name].reset()">
3326
+ <button matSuffix matIconButton aria-label="Clear" type="button" (click)="group.controls[field.name].reset()">
3361
3327
  <mat-icon>close</mat-icon>
3362
3328
  </button>
3363
3329
  }
@@ -4940,7 +4906,7 @@ class KlesFabComponent extends KlesButtonBase {
4940
4906
  multi: true
4941
4907
  }
4942
4908
  ], usesInheritance: true, ngImport: i0, template: `
4943
- <button mat-fab [extended]="!!label" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
4909
+ <button matFab [extended]="!!label" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
4944
4910
  (click)="click($event)" [matTooltip]="tooltip">
4945
4911
  {{label}}
4946
4912
 
@@ -4959,7 +4925,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
4959
4925
  args: [{
4960
4926
  selector: 'kles-fab',
4961
4927
  template: `
4962
- <button mat-fab [extended]="!!label" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
4928
+ <button matFab [extended]="!!label" [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
4963
4929
  (click)="click($event)" [matTooltip]="tooltip">
4964
4930
  {{label}}
4965
4931
 
@@ -5036,7 +5002,7 @@ class KlesMiniFabComponent extends KlesButtonBase {
5036
5002
  multi: true
5037
5003
  }
5038
5004
  ], usesInheritance: true, ngImport: i0, template: `
5039
- <button mat-mini-fab extended [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
5005
+ <button matMiniFab [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
5040
5006
  (click)="click($event)" [matTooltip]="tooltip">
5041
5007
  {{label}}
5042
5008
 
@@ -5055,7 +5021,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5055
5021
  args: [{
5056
5022
  selector: 'kles-mini-fab',
5057
5023
  template: `
5058
- <button mat-mini-fab extended [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
5024
+ <button matMiniFab [type]="type" [ngClass]="classButton" [color]="(color)?color:'primary'" [disabled]="disabled"
5059
5025
  (click)="click($event)" [matTooltip]="tooltip">
5060
5026
  {{label}}
5061
5027
 
@@ -5132,7 +5098,7 @@ class KlesIconButtonComponent extends KlesButtonBase {
5132
5098
  multi: true,
5133
5099
  },
5134
5100
  ], usesInheritance: true, ngImport: i0, template: `
5135
- <button mat-icon-button [type]="type" [ngClass]="classButton" [color]="color ? color : 'primary'" [disabled]="disabled" (click)="click($event)" [matTooltip]="tooltip">
5101
+ <button matIconButton [type]="type" [ngClass]="classButton" [color]="color ? color : 'primary'" [disabled]="disabled" (click)="click($event)" [matTooltip]="tooltip">
5136
5102
  @if (icon) {
5137
5103
  <mat-icon>{{ icon }}</mat-icon>
5138
5104
  } @if (iconSvg) {
@@ -5146,7 +5112,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5146
5112
  args: [{
5147
5113
  selector: 'kles-icon-button',
5148
5114
  template: `
5149
- <button mat-icon-button [type]="type" [ngClass]="classButton" [color]="color ? color : 'primary'" [disabled]="disabled" (click)="click($event)" [matTooltip]="tooltip">
5115
+ <button matIconButton [type]="type" [ngClass]="classButton" [color]="color ? color : 'primary'" [disabled]="disabled" (click)="click($event)" [matTooltip]="tooltip">
5150
5116
  @if (icon) {
5151
5117
  <mat-icon>{{ icon }}</mat-icon>
5152
5118
  } @if (iconSvg) {
@@ -5275,7 +5241,7 @@ class KlesFormSelectionListSearchComponent extends KlesFieldAbstract {
5275
5241
  <mat-label>{{ field.label }}</mat-label>
5276
5242
  }
5277
5243
  <input matInput [placeholder]="field.placeholder" [formControl]="searchControl" />
5278
- <button matSuffix mat-icon-button aria-label="Clear" (click)="searchControl.reset(); $event.stopPropagation()">
5244
+ <button matSuffix matIconButton aria-label="Clear" (click)="searchControl.reset(); $event.stopPropagation()">
5279
5245
  <mat-icon>close</mat-icon>
5280
5246
  </button>
5281
5247
  </mat-form-field>
@@ -5317,7 +5283,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5317
5283
  <mat-label>{{ field.label }}</mat-label>
5318
5284
  }
5319
5285
  <input matInput [placeholder]="field.placeholder" [formControl]="searchControl" />
5320
- <button matSuffix mat-icon-button aria-label="Clear" (click)="searchControl.reset(); $event.stopPropagation()">
5286
+ <button matSuffix matIconButton aria-label="Clear" (click)="searchControl.reset(); $event.stopPropagation()">
5321
5287
  <mat-icon>close</mat-icon>
5322
5288
  </button>
5323
5289
  </mat-form-field>
@@ -5563,13 +5529,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5563
5529
  class KlesFormDateTimeComponent extends KlesFieldAbstract {
5564
5530
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormDateTimeComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
5565
5531
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.19", type: KlesFormDateTimeComponent, isStandalone: true, selector: "kles-form-datetimepicker", usesInheritance: true, ngImport: i0, template: `
5566
- <mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group" [appearance]="field.appearance">
5532
+ <mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="color()" [formGroup]="group" [appearance]="appearance()">
5567
5533
  @if (field.label) {
5568
5534
  <mat-label>{{ field.label }}</mat-label>
5569
5535
  }
5570
5536
 
5571
5537
  <input matInput matTooltip="{{ field.tooltip }}" [attr.id]="field.id" [ngClass]="field.ngClass" [matDatepicker]="picker" [formControlName]="field.name"
5572
- [placeholder]="field.placeholder | translate" [min]="field.min" [max]="field.max">
5538
+ [placeholder]="field.placeholder" [min]="field.min" [max]="field.max">
5573
5539
  <div matSuffix class="suffix">
5574
5540
  <mat-datepicker-toggle [for]="picker"></mat-datepicker-toggle>
5575
5541
  <ng-content></ng-content>
@@ -5583,18 +5549,18 @@ class KlesFormDateTimeComponent extends KlesFieldAbstract {
5583
5549
 
5584
5550
  <mat-error matErrorMessage [validations]="field.validations" [asyncValidations]="field.asyncValidations"></mat-error>
5585
5551
  </mat-form-field>
5586
- `, isInline: true, styles: ["mat-form-field{width:100%}\n", ".suffix{display:flex;flex-direction:row}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { 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],[formArray],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: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "directive", type: i3$2.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i3$2.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "component", type: MatErrorMessageDirective, selector: "[matErrorMessage]", inputs: ["validations", "asyncValidations"] }, { kind: "ngmodule", type: KlesMaterialDatepickerModule }, { kind: "component", type: i4$4.KlesMatDatepicker, selector: "kles-mat-datepicker", outputs: ["timeSelected"], exportAs: ["klesMatDatepicker"] }, { kind: "pipe", type: i5$1.TranslatePipe, name: "translate" }] }); }
5552
+ `, isInline: true, styles: ["mat-form-field{width:100%}\n", ".suffix{display:flex;flex-direction:row}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { 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],[formArray],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: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatLabel, selector: "mat-label" }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "directive", type: i3$2.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i3$2.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "component", type: MatErrorMessageDirective, selector: "[matErrorMessage]", inputs: ["validations", "asyncValidations"] }, { kind: "ngmodule", type: KlesMaterialDatepickerModule }, { kind: "component", type: i4$4.KlesMatDatepicker, selector: "kles-mat-datepicker", outputs: ["timeSelected"], exportAs: ["klesMatDatepicker"] }] }); }
5587
5553
  }
5588
5554
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormDateTimeComponent, decorators: [{
5589
5555
  type: Component,
5590
5556
  args: [{ selector: 'kles-form-datetimepicker', template: `
5591
- <mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="field.color" [formGroup]="group" [appearance]="field.appearance">
5557
+ <mat-form-field [subscriptSizing]="field.subscriptSizing" class="margin-top" [color]="color()" [formGroup]="group" [appearance]="appearance()">
5592
5558
  @if (field.label) {
5593
5559
  <mat-label>{{ field.label }}</mat-label>
5594
5560
  }
5595
5561
 
5596
5562
  <input matInput matTooltip="{{ field.tooltip }}" [attr.id]="field.id" [ngClass]="field.ngClass" [matDatepicker]="picker" [formControlName]="field.name"
5597
- [placeholder]="field.placeholder | translate" [min]="field.min" [max]="field.max">
5563
+ [placeholder]="field.placeholder" [min]="field.min" [max]="field.max">
5598
5564
  <div matSuffix class="suffix">
5599
5565
  <mat-datepicker-toggle [for]="picker"></mat-datepicker-toggle>
5600
5566
  <ng-content></ng-content>
@@ -5619,7 +5585,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5619
5585
  MatInput,
5620
5586
  MatTooltip,
5621
5587
  MatDatepickerModule,
5622
- TranslateModule,
5623
5588
  MatErrorMessageDirective,
5624
5589
  KlesMaterialDatepickerModule
5625
5590
  ], styles: ["mat-form-field{width:100%}\n", ".suffix{display:flex;flex-direction:row}\n"] }]
@@ -5645,7 +5610,7 @@ class KlesFormCopyComponent {
5645
5610
  }
5646
5611
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormCopyComponent, deps: [{ token: i1$2.Clipboard }], target: i0.ɵɵFactoryTarget.Component }); }
5647
5612
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: KlesFormCopyComponent, isStandalone: true, selector: "kles-form-copy", viewQueries: [{ propertyName: "tooltip", first: true, predicate: ["tooltip"], descendants: true }], ngImport: i0, template: `
5648
- <button #tooltip="matTooltip" mat-icon-button color="primary" type="button" (click)="copy($event)" [matTooltipDisabled]="true" [matTooltip]="tooltipText" matTooltipPosition="above">
5613
+ <button #tooltip="matTooltip" matIconButton color="primary" type="button" (click)="copy($event)" [matTooltipDisabled]="true" [matTooltip]="tooltipText" matTooltipPosition="above">
5649
5614
  <mat-icon>content_copy</mat-icon>
5650
5615
  </button>
5651
5616
  `, isInline: true, dependencies: [{ kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i2$2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4$3.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ClipboardModule }] }); }
@@ -5655,7 +5620,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5655
5620
  args: [{
5656
5621
  selector: 'kles-form-copy',
5657
5622
  template: `
5658
- <button #tooltip="matTooltip" mat-icon-button color="primary" type="button" (click)="copy($event)" [matTooltipDisabled]="true" [matTooltip]="tooltipText" matTooltipPosition="above">
5623
+ <button #tooltip="matTooltip" matIconButton color="primary" type="button" (click)="copy($event)" [matTooltipDisabled]="true" [matTooltip]="tooltipText" matTooltipPosition="above">
5659
5624
  <mat-icon>content_copy</mat-icon>
5660
5625
  </button>
5661
5626
  `,
@@ -5879,7 +5844,7 @@ class KlesFormPasswordVisibilityComponent {
5879
5844
  }
5880
5845
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.19", ngImport: i0, type: KlesFormPasswordVisibilityComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
5881
5846
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.19", type: KlesFormPasswordVisibilityComponent, isStandalone: true, selector: "kles-form-password-visibility", ngImport: i0, template: `
5882
- <button [disabled]="group?.get(field?.name).disabled" mat-icon-button aria-label="visibility" type="button" (click)="toggleVisibility($event)">
5847
+ <button [disabled]="group?.get(field?.name).disabled" matIconButton aria-label="visibility" type="button" (click)="toggleVisibility($event)">
5883
5848
  <mat-icon>{{ hide() ? 'visibility_off' : 'visibility' }}</mat-icon>
5884
5849
  </button>
5885
5850
  `, isInline: true, dependencies: [{ kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }] }); }
@@ -5889,7 +5854,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.19", ngImpo
5889
5854
  args: [{
5890
5855
  selector: 'kles-form-password-visibility',
5891
5856
  template: `
5892
- <button [disabled]="group?.get(field?.name).disabled" mat-icon-button aria-label="visibility" type="button" (click)="toggleVisibility($event)">
5857
+ <button [disabled]="group?.get(field?.name).disabled" matIconButton aria-label="visibility" type="button" (click)="toggleVisibility($event)">
5893
5858
  <mat-icon>{{ hide() ? 'visibility_off' : 'visibility' }}</mat-icon>
5894
5859
  </button>
5895
5860
  `,
@@ -5929,5 +5894,5 @@ function autocompleteStringValidator(validOptions, optional) {
5929
5894
  * Generated bundle index. Do not edit.
5930
5895
  */
5931
5896
 
5932
- export { AbstractUiState, ArrayFormatPipe, ArrayUiState, ControlUiState, EnumButtonAttribute, EnumType, FIELD, FIELD_NAME, FieldMapper, GROUP, GROUP_UI, GroupUiState, KlesAbstractFormControl, KlesAbstractFormUiControl, KlesButtonBase, KlesButtonCheckerComponent, KlesButtonComponent, KlesButtonFileComponent, KlesComponentDirective, KlesDynamicFieldDirective, KlesDynamicFormComponent, KlesDynamicFormIntl, KlesFabComponent, KlesFieldAbstract, KlesFileControlComponent, KlesFormArray, KlesFormArrayComponent, KlesFormBadgeComponent, KlesFormButtonCheckerComponent, KlesFormButtonComponent, KlesFormButtonFileComponent, KlesFormButtonToogleGroupComponent, KlesFormCheckboxComponent, KlesFormCheckboxIndeterminateComponent, KlesFormChipComponent, KlesFormClearComponent, KlesFormColorComponent, KlesFormControl, KlesFormCopyComponent, KlesFormDateComponent, KlesFormDateTimeComponent, KlesFormErrorStateMatcher, KlesFormFabComponent, KlesFormFileComponent, KlesFormGroup, KlesFormGroupComponent, KlesFormIconButtonComponent, KlesFormIconComponent, KlesFormInputClearableComponent, KlesFormInputComponent, KlesFormLabelComponent, KlesFormLineBreakComponent, KlesFormLinkComponent, KlesFormListFieldComponent, KlesFormMiniFabComponent, KlesFormPasswordVisibilityComponent, KlesFormRadioComponent, KlesFormRange, KlesFormRangeComponent, KlesFormSelectComponent, KlesFormSelectLazySearchComponent, KlesFormSelectSearchComponent, KlesFormSelectionListComponent, KlesFormSelectionListSearchComponent, KlesFormSlideToggleComponent, KlesFormTextComponent, KlesFormTextareaComponent, KlesFormUiArray, KlesFormUiControl, KlesFormUiGroup, KlesIconButtonComponent, KlesIndeterminateCheckboxComponent, KlesMaterialDynamicformsModule, KlesMiniFabComponent, KlesSelectionModel, KlesTransformPipe, MatErrorFormDirective, MatErrorMessageDirective, SIBLING_FIELDS, autocompleteObjectValidator, autocompleteStringValidator, componentMapper, isDestroyable, klesFieldControlFactory, klesFieldUiFactory };
5897
+ export { AbstractUiState, ArrayFormatPipe, ArrayUiState, ControlUiState, EnumType, FIELD, FIELD_NAME, FieldMapper, GROUP, GROUP_UI, GroupUiState, KlesAbstractFormControl, KlesAbstractFormUiControl, KlesButtonBase, KlesButtonCheckerComponent, KlesButtonComponent, KlesButtonFileComponent, KlesComponentDirective, KlesDynamicFieldDirective, KlesDynamicFormComponent, KlesDynamicFormIntl, KlesFabComponent, KlesFieldAbstract, KlesFileControlComponent, KlesFormArray, KlesFormArrayComponent, KlesFormBadgeComponent, KlesFormButtonCheckerComponent, KlesFormButtonComponent, KlesFormButtonFileComponent, KlesFormButtonToogleGroupComponent, KlesFormCheckboxComponent, KlesFormCheckboxIndeterminateComponent, KlesFormChipComponent, KlesFormClearComponent, KlesFormColorComponent, KlesFormControl, KlesFormCopyComponent, KlesFormDateComponent, KlesFormDateTimeComponent, KlesFormErrorStateMatcher, KlesFormFabComponent, KlesFormFileComponent, KlesFormGroup, KlesFormGroupComponent, KlesFormIconButtonComponent, KlesFormIconComponent, KlesFormInputClearableComponent, KlesFormInputComponent, KlesFormLabelComponent, KlesFormLineBreakComponent, KlesFormLinkComponent, KlesFormListFieldComponent, KlesFormMiniFabComponent, KlesFormPasswordVisibilityComponent, KlesFormRadioComponent, KlesFormRange, KlesFormRangeComponent, KlesFormSelectComponent, KlesFormSelectLazySearchComponent, KlesFormSelectSearchComponent, KlesFormSelectionListComponent, KlesFormSelectionListSearchComponent, KlesFormSlideToggleComponent, KlesFormTextComponent, KlesFormTextareaComponent, KlesFormUiArray, KlesFormUiControl, KlesFormUiGroup, KlesIconButtonComponent, KlesIndeterminateCheckboxComponent, KlesMaterialDynamicformsModule, KlesMiniFabComponent, KlesSelectionModel, KlesTransformPipe, MatErrorFormDirective, MatErrorMessageDirective, SIBLING_FIELDS, autocompleteObjectValidator, autocompleteStringValidator, componentMapper, isDestroyable, klesFieldControlFactory, klesFieldUiFactory };
5933
5898
  //# sourceMappingURL=3kles-kles-material-dynamicforms.mjs.map