zek 14.2.77 → 14.2.79

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.
@@ -12,5 +12,5 @@ export declare class ZekAlert {
12
12
  cssAlert: string;
13
13
  cssIcon: string;
14
14
  static ɵfac: i0.ɵɵFactoryDeclaration<ZekAlert, never>;
15
- static ɵcmp: i0.ɵɵComponentDeclaration<ZekAlert, "zek-alert", never, { "type": "type"; "title": "title"; }, {}, never, ["*"], false>;
15
+ static ɵcmp: i0.ɵɵComponentDeclaration<ZekAlert, "zek-alert", never, { "type": "type"; "showClose": "showClose"; "title": "title"; }, {}, never, ["*"], false>;
16
16
  }
@@ -0,0 +1,7 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class ZekFieldValidator {
3
+ field: any;
4
+ constructor();
5
+ static ɵfac: i0.ɵɵFactoryDeclaration<ZekFieldValidator, never>;
6
+ static ɵcmp: i0.ɵɵComponentDeclaration<ZekFieldValidator, "zek-field-validator, [zek-field-validator]", never, { "field": "field"; }, {}, never, never, false>;
7
+ }
@@ -1,2 +1,2 @@
1
1
  export * from './validator.module';
2
- export * from './field-validator.component';
2
+ export * from './field-validator';
@@ -1,9 +1,9 @@
1
1
  import * as i0 from "@angular/core";
2
- import * as i1 from "./field-validator.component";
2
+ import * as i1 from "./field-validator";
3
3
  import * as i2 from "@angular/common";
4
4
  import * as i3 from "@ngx-translate/core";
5
5
  export declare class ValidatorModule {
6
6
  static ɵfac: i0.ɵɵFactoryDeclaration<ValidatorModule, never>;
7
- static ɵmod: i0.ɵɵNgModuleDeclaration<ValidatorModule, [typeof i1.FieldValidatorComponent], [typeof i2.CommonModule, typeof i3.TranslateModule], [typeof i1.FieldValidatorComponent]>;
7
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ValidatorModule, [typeof i1.ZekFieldValidator], [typeof i2.CommonModule, typeof i3.TranslateModule], [typeof i1.ZekFieldValidator]>;
8
8
  static ɵinj: i0.ɵɵInjectorDeclaration<ValidatorModule>;
9
9
  }
@@ -16,7 +16,7 @@ export declare enum Color {
16
16
  Dark = 8
17
17
  }
18
18
  export declare class BootstrapHelper {
19
- static cssColor(color?: Color | null): "" | "bg-primary text-white" | "bg-secondary text-white" | "bg-success text-white" | "bg-danger text-white" | "bg-warning text-dark" | "bg-info text-dark" | "bg-dark text-white";
19
+ static cssColor(color?: Color | null): "" | "bg-primary text-white" | "bg-secondary text-white" | "bg-success text-white" | "bg-danger text-white" | "bg-warning text-dark" | "bg-info text-dark" | "bg-dark text-white";
20
20
  static cssIcon(type: ComponentType): string | null;
21
21
  static cssButton(type: ComponentType): string;
22
22
  static getAlertType(type?: string | null): AlertType | null;
@@ -19,3 +19,4 @@ export * from './string-helper';
19
19
  export * from './thenBy';
20
20
  export * from './time-helper';
21
21
  export * from './url-helper';
22
+ export * from './validation-helper';
@@ -0,0 +1,4 @@
1
+ export declare class ValidationHelper {
2
+ static readonly emailRegExp: RegExp;
3
+ static isValidEmail(email?: string | null): boolean;
4
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zek",
3
- "version": "14.2.77",
3
+ "version": "14.2.79",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^14.0.0",
6
6
  "@angular/core": "^14.0.0"
@@ -1,20 +0,0 @@
1
- import { Component, Input } from '@angular/core';
2
- import * as i0 from "@angular/core";
3
- import * as i1 from "@angular/common";
4
- import * as i2 from "@ngx-translate/core";
5
- export class FieldValidatorComponent {
6
- // @Input() field?: NgModel;
7
- constructor() {
8
- if (this.field)
9
- console.log(this.field.errors);
10
- }
11
- }
12
- FieldValidatorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FieldValidatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
13
- FieldValidatorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: FieldValidatorComponent, selector: "zek-field-validator, [zek-field-validator]", inputs: { field: "field" }, host: { properties: { "class": "\"invalid-tooltip\"" } }, ngImport: i0, template: "<ng-container *ngIf=\"field\">\r\n <ng-container *ngIf=\"field.invalid && (field.dirty || field.touched || field.formDirective?.submitted)\">\r\n <ng-container *ngIf=\"field.errors\">\r\n <ng-container *ngIf=\"field.errors.required\">{{ 'Validation.Required' | translate }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.minlength\">{{ 'Validation.MinLengthFormat' | translate:{ value: field.errors.minlength.requiredLength } }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.maxlength\">{{ 'Validation.MaxLengthFormat' | translate:{ value: field.errors.maxlength.requiredLength } }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.email\">{{ 'Validation.Pattern' | translate }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.pattern\">{{ 'Validation.Pattern' | translate }}</ng-container><!-- {{ field.errors.pattern.requiredPattern }} -->\r\n <ng-container *ngIf=\"field.errors.server\">{{field.errors.server}}</ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-container>", dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }] });
14
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: FieldValidatorComponent, decorators: [{
15
- type: Component,
16
- args: [{ selector: 'zek-field-validator, [zek-field-validator]', host: { '[class]': '"invalid-tooltip"' }, template: "<ng-container *ngIf=\"field\">\r\n <ng-container *ngIf=\"field.invalid && (field.dirty || field.touched || field.formDirective?.submitted)\">\r\n <ng-container *ngIf=\"field.errors\">\r\n <ng-container *ngIf=\"field.errors.required\">{{ 'Validation.Required' | translate }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.minlength\">{{ 'Validation.MinLengthFormat' | translate:{ value: field.errors.minlength.requiredLength } }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.maxlength\">{{ 'Validation.MaxLengthFormat' | translate:{ value: field.errors.maxlength.requiredLength } }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.email\">{{ 'Validation.Pattern' | translate }}</ng-container>\r\n <ng-container *ngIf=\"field.errors.pattern\">{{ 'Validation.Pattern' | translate }}</ng-container><!-- {{ field.errors.pattern.requiredPattern }} -->\r\n <ng-container *ngIf=\"field.errors.server\">{{field.errors.server}}</ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-container>" }]
17
- }], ctorParameters: function () { return []; }, propDecorators: { field: [{
18
- type: Input
19
- }] } });
20
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZmllbGQtdmFsaWRhdG9yLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3play9zcmMvbGliL21vZHVsZXMvdmFsaWRhdG9yL2ZpZWxkLXZhbGlkYXRvci5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy96ZWsvc3JjL2xpYi9tb2R1bGVzL3ZhbGlkYXRvci9maWVsZC12YWxpZGF0b3IuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBRSxLQUFLLEVBQUUsTUFBTSxlQUFlLENBQUM7Ozs7QUFPakQsTUFBTSxPQUFPLHVCQUF1QjtJQUVoQyw0QkFBNEI7SUFFNUI7UUFDSSxJQUFJLElBQUksQ0FBQyxLQUFLO1lBQ1YsT0FBTyxDQUFDLEdBQUcsQ0FBQyxJQUFJLENBQUMsS0FBSyxDQUFDLE1BQU0sQ0FBQyxDQUFDO0lBQ3ZDLENBQUM7O29IQVBRLHVCQUF1Qjt3R0FBdkIsdUJBQXVCLHdLQ1BwQyw2a0NBV2U7MkZESkYsdUJBQXVCO2tCQUxuQyxTQUFTO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GFpbmVyPiJdfQ==
@@ -1,7 +0,0 @@
1
- import * as i0 from "@angular/core";
2
- export declare class FieldValidatorComponent {
3
- field: any;
4
- constructor();
5
- static ɵfac: i0.ɵɵFactoryDeclaration<FieldValidatorComponent, never>;
6
- static ɵcmp: i0.ɵɵComponentDeclaration<FieldValidatorComponent, "zek-field-validator, [zek-field-validator]", never, { "field": "field"; }, {}, never, never, false>;
7
- }