chrv-components 1.11.20 → 1.11.22

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.
Binary file
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { inject, input, Component, Injectable, Directive, ElementRef, EventEmitter, output, viewChild, Input, Output, signal, HostListener, ContentChildren, ChangeDetectorRef, ChangeDetectionStrategy, PLATFORM_ID, computed, model, InjectionToken, ViewContainerRef, ViewChild, effect, Inject, ApplicationRef, EnvironmentInjector, createComponent, Injector } from '@angular/core';
2
+ import { inject, input, Component, Injectable, Directive, ElementRef, EventEmitter, output, viewChild, Input, Output, signal, HostListener, ContentChildren, ChangeDetectorRef, effect, ChangeDetectionStrategy, PLATFORM_ID, computed, model, InjectionToken, ViewContainerRef, ViewChild, Inject, ApplicationRef, EnvironmentInjector, createComponent, Injector } from '@angular/core';
3
3
  import * as i2$4 from '@angular/router';
4
4
  import { Router, RouterModule } from '@angular/router';
5
5
  import { MatButton, MatButtonModule } from '@angular/material/button';
@@ -9,8 +9,7 @@ import * as i3 from '@angular/material/tooltip';
9
9
  import { MatTooltipModule, MatTooltip } from '@angular/material/tooltip';
10
10
  import * as i1 from '@angular/common';
11
11
  import { CommonModule, AsyncPipe, DatePipe, DATE_PIPE_DEFAULT_OPTIONS, isPlatformBrowser, NgClass } from '@angular/common';
12
- import { MatDialogRef, MatDialogTitle, MatDialogContent, MatDialogActions, MAT_DIALOG_DATA, MatDialog } from '@angular/material/dialog';
13
- export * from '@angular/material/dialog';
12
+ import { MatDialogRef, MatDialogTitle, MatDialogContent, MatDialogActions, MAT_DIALOG_DATA } from '@angular/material/dialog';
14
13
  import * as i1$1 from '@angular/forms';
15
14
  import { NG_VALIDATORS, Validators, FormControl, NgControl, ReactiveFormsModule, FormsModule, FormBuilder } from '@angular/forms';
16
15
  import * as i2$2 from '@angular/material/autocomplete';
@@ -2525,6 +2524,9 @@ class ChrFormComponent {
2525
2524
  };
2526
2525
  if (this.controls().length > 0 && this.sections().length > 0)
2527
2526
  console.warn("You can't use both controls and sections in the same form");
2527
+ effect(() => {
2528
+ this.set(this.model());
2529
+ });
2528
2530
  }
2529
2531
  ngOnInit() {
2530
2532
  this.sections()
@@ -3796,45 +3798,6 @@ const inOutAnimation = (duration = 500) => trigger('inOutAnimation', [
3796
3798
  ]),
3797
3799
  ]);
3798
3800
 
3799
- class DialogService {
3800
- constructor() {
3801
- this.dialog = inject(MatDialog);
3802
- this.openDelete = (callback, ...elements) => {
3803
- const dialogRef = this.open(ChrDeleteModalComponent);
3804
- dialogRef.afterClosed().subscribe((result) => {
3805
- if (result == true)
3806
- callback?.(...elements);
3807
- });
3808
- };
3809
- this.openDefault = (config) => {
3810
- const cfg = {
3811
- ...config?.config,
3812
- data: {
3813
- ...config?.config?.data,
3814
- _config: {
3815
- title: config?.title,
3816
- text: config?.text,
3817
- close: config?.close,
3818
- actions: config?.actions,
3819
- },
3820
- },
3821
- };
3822
- const dialogRef = this.open(ChrDefaultModalComponent, cfg);
3823
- };
3824
- this.open = (component, options) => {
3825
- return this.dialog.open(component, options);
3826
- };
3827
- }
3828
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: DialogService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
3829
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: DialogService, providedIn: 'root' }); }
3830
- }
3831
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: DialogService, decorators: [{
3832
- type: Injectable,
3833
- args: [{
3834
- providedIn: 'root',
3835
- }]
3836
- }] });
3837
-
3838
3801
  const CHR_MODAL_DATA = new InjectionToken('CHR_MODAL_DATA', {
3839
3802
  providedIn: 'root',
3840
3803
  factory: () => null,
@@ -3982,5 +3945,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
3982
3945
  * Generated bundle index. Do not edit.
3983
3946
  */
3984
3947
 
3985
- export { Aligments, AutofocusDirective, BreadcrumbComponent, ButtonComponent, CHR_MODAL_DATA, CHR_MODAL_REF, CarouselComponent, ChrBaseInputComponent, ChrButtonComponent, ChrCheckboxComponent, ChrColorInputComponent, ChrDataTable, ChrDateInputComponent, ChrDatetimeInputComponent, ChrDefaultModalComponent, ChrDeleteModalComponent, ChrFileInputComponent, ChrFormComponent, ChrModalComponent, ChrNiceFileInputComponent, ChrPaginatorComponent, ChrSearchSelectComponent, ChrSearchbarComponent, ChrSeparatorComponent, ChrSpinnerComponent, ChrTableComponent, ChrTableHeaderCellComponent, ChrTagSelectComponent, ChrTextareaInputComponent, ChrToastComponent, ChrToggleInputComponent, Colors, CookiesService, DEFAULTLIVEUPDATEMESSAGE, DataService, DecimalValidatorDirective, DefaultLiveUpdateMessage, DialogService, FileService, HUBURL, InlineSvgComponent, LiveUpdateService, LiveUpdateStatus, LoaderService, MaxDateValidatorDirective, ModalService, SpinnerInterceptor, SyncValidatorToAsync, TabComponent, TabGroupComponent, TabToEnterHandlerDirective, TabToInputHandlerDirective, ToastService, TypeValidatorDirective, WaitAndStoreXsrfToken, XSRFCOOKIENAME, XSRFHEADERNAME, XsrfInterceptor, decimal, getAsyncValidators, getBackgroundColor, getBorderColor, getContrastBackgroundColor, getContrastBorderColor, getContrastTextColor, getSyncValidators, getTextColor, getValidators, inOutAnimation, maxDate, provideXsrfHttpClient, rotationAnimation, type };
3948
+ export { Aligments, AutofocusDirective, BreadcrumbComponent, ButtonComponent, CHR_MODAL_DATA, CHR_MODAL_REF, CarouselComponent, ChrBaseInputComponent, ChrButtonComponent, ChrCheckboxComponent, ChrColorInputComponent, ChrDataTable, ChrDateInputComponent, ChrDatetimeInputComponent, ChrDefaultModalComponent, ChrDeleteModalComponent, ChrFileInputComponent, ChrFormComponent, ChrModalComponent, ChrNiceFileInputComponent, ChrPaginatorComponent, ChrSearchSelectComponent, ChrSearchbarComponent, ChrSeparatorComponent, ChrSpinnerComponent, ChrTableComponent, ChrTableHeaderCellComponent, ChrTagSelectComponent, ChrTextareaInputComponent, ChrToastComponent, ChrToggleInputComponent, Colors, CookiesService, DEFAULTLIVEUPDATEMESSAGE, DataService, DecimalValidatorDirective, DefaultLiveUpdateMessage, FileService, HUBURL, InlineSvgComponent, LiveUpdateService, LiveUpdateStatus, LoaderService, MaxDateValidatorDirective, MaxFileSizeValidator, MaxLengthValidatorDirective, MinFileSizeValidator, MinLengthValidatorDirective, ModalService, RequiredValidatorDirective, SpinnerInterceptor, SyncValidatorToAsync, TabComponent, TabGroupComponent, TabToEnterHandlerDirective, TabToInputHandlerDirective, ToastService, TypeValidatorDirective, WaitAndStoreXsrfToken, XSRFCOOKIENAME, XSRFHEADERNAME, XsrfInterceptor, decimal, getAsyncValidators, getBackgroundColor, getBorderColor, getContrastBackgroundColor, getContrastBorderColor, getContrastTextColor, getSyncValidators, getTextColor, getValidators, inOutAnimation, maxDate, maxFileSize, maxLength, minFileSize, minLength, provideXsrfHttpClient, required, rotationAnimation, type };
3986
3949
  //# sourceMappingURL=chrv-components.mjs.map