@triangular/password-checker 14.0.0 → 20.0.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.
- package/README.md +1 -0
- package/fesm2022/triangular-password-checker.mjs +8 -8
- package/index.d.ts +34 -5
- package/package.json +3 -3
- package/lib/password-checker-lib.directive.d.ts +0 -15
- package/lib/password-checker-lib.module.d.ts +0 -10
- package/lib/password-checker.config.d.ts +0 -10
- package/public_api.d.ts +0 -2
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@ import { timer } from 'rxjs';
|
|
|
2
2
|
import { switchMap, map } from 'rxjs/operators';
|
|
3
3
|
import { NG_ASYNC_VALIDATORS } from '@angular/forms';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import { InjectionToken,
|
|
5
|
+
import { InjectionToken, Input, Optional, Inject, Directive, NgModule } from '@angular/core';
|
|
6
6
|
import * as i1 from '@angular/common/http';
|
|
7
7
|
import { provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
|
|
8
8
|
|
|
@@ -45,8 +45,8 @@ class PasswordCheckerLibDirective {
|
|
|
45
45
|
? { pwnedPasswordOccurrence: password.count }
|
|
46
46
|
: null));
|
|
47
47
|
}
|
|
48
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
49
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
48
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerLibDirective, deps: [{ token: i1.HttpClient }, { token: PasswordCheckerConfigValue, optional: true }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
49
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.0.0", type: PasswordCheckerLibDirective, isStandalone: true, selector: "[pwnedPasswordValidator][formControlName], [pwnedPasswordValidator][ngModel],[pwnedPasswordValidator][formControl]", inputs: { pwnedPasswordApi: "pwnedPasswordApi", pwnedPasswordMinimumOccurrenceForError: "pwnedPasswordMinimumOccurrenceForError", pwnedPasswordApiCallDebounceTime: "pwnedPasswordApiCallDebounceTime" }, providers: [
|
|
50
50
|
{
|
|
51
51
|
provide: NG_ASYNC_VALIDATORS,
|
|
52
52
|
useExisting: PasswordCheckerLibDirective,
|
|
@@ -54,7 +54,7 @@ class PasswordCheckerLibDirective {
|
|
|
54
54
|
},
|
|
55
55
|
], ngImport: i0 }); }
|
|
56
56
|
}
|
|
57
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
57
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerLibDirective, decorators: [{
|
|
58
58
|
type: Directive,
|
|
59
59
|
args: [{
|
|
60
60
|
// eslint-disable-next-line @angular-eslint/directive-selector
|
|
@@ -93,11 +93,11 @@ class PasswordCheckerModule {
|
|
|
93
93
|
]
|
|
94
94
|
};
|
|
95
95
|
}
|
|
96
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
97
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
98
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
96
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
97
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerModule, imports: [PasswordCheckerLibDirective], exports: [PasswordCheckerLibDirective] }); }
|
|
98
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerModule, providers: [provideHttpClient(withInterceptorsFromDi())] }); }
|
|
99
99
|
}
|
|
100
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
100
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.0", ngImport: i0, type: PasswordCheckerModule, decorators: [{
|
|
101
101
|
type: NgModule,
|
|
102
102
|
args: [{ declarations: [],
|
|
103
103
|
exports: [PasswordCheckerLibDirective], imports: [PasswordCheckerLibDirective], providers: [provideHttpClient(withInterceptorsFromDi())] }]
|
package/index.d.ts
CHANGED
|
@@ -1,5 +1,34 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { AsyncValidator, AbstractControl, ValidationErrors } from '@angular/forms';
|
|
3
|
+
import { HttpClient } from '@angular/common/http';
|
|
4
|
+
import * as i0 from '@angular/core';
|
|
5
|
+
import { ModuleWithProviders } from '@angular/core';
|
|
6
|
+
|
|
7
|
+
type Partial<T> = {
|
|
8
|
+
[P in keyof T]?: T[P];
|
|
9
|
+
};
|
|
10
|
+
interface PasswordCheckerConfig {
|
|
11
|
+
pwnedPasswordApi: string;
|
|
12
|
+
pwnedPasswordMinimumOccurrenceForError: number;
|
|
13
|
+
pwnedPasswordApiCallDebounceTime: number;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
declare class PasswordCheckerLibDirective implements AsyncValidator {
|
|
17
|
+
private http;
|
|
18
|
+
pwnedPasswordApi: string;
|
|
19
|
+
pwnedPasswordMinimumOccurrenceForError: number;
|
|
20
|
+
pwnedPasswordApiCallDebounceTime: number;
|
|
21
|
+
constructor(http: HttpClient, config: Partial<PasswordCheckerConfig>);
|
|
22
|
+
validate(control: AbstractControl): Observable<ValidationErrors | null>;
|
|
23
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PasswordCheckerLibDirective, [null, { optional: true; }]>;
|
|
24
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<PasswordCheckerLibDirective, "[pwnedPasswordValidator][formControlName], [pwnedPasswordValidator][ngModel],[pwnedPasswordValidator][formControl]", never, { "pwnedPasswordApi": { "alias": "pwnedPasswordApi"; "required": false; }; "pwnedPasswordMinimumOccurrenceForError": { "alias": "pwnedPasswordMinimumOccurrenceForError"; "required": false; }; "pwnedPasswordApiCallDebounceTime": { "alias": "pwnedPasswordApiCallDebounceTime"; "required": false; }; }, {}, never, never, true, never>;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
declare class PasswordCheckerModule {
|
|
28
|
+
static forRoot(config?: Partial<PasswordCheckerConfig>): ModuleWithProviders<PasswordCheckerModule>;
|
|
29
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PasswordCheckerModule, never>;
|
|
30
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<PasswordCheckerModule, never, [typeof PasswordCheckerLibDirective], [typeof PasswordCheckerLibDirective]>;
|
|
31
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<PasswordCheckerModule>;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export { PasswordCheckerLibDirective, PasswordCheckerModule };
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@triangular/password-checker",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "20.0.0",
|
|
4
4
|
"peerDependencies": {
|
|
5
|
-
"@angular/common": "^
|
|
6
|
-
"@angular/core": "^
|
|
5
|
+
"@angular/common": "^20.0.0",
|
|
6
|
+
"@angular/core": "^20.0.0"
|
|
7
7
|
},
|
|
8
8
|
"homepage": "https://password.akehir.com",
|
|
9
9
|
"license": "MIT",
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { Observable } from 'rxjs';
|
|
2
|
-
import { AbstractControl, AsyncValidator, ValidationErrors } from '@angular/forms';
|
|
3
|
-
import { HttpClient } from '@angular/common/http';
|
|
4
|
-
import { Partial, PasswordCheckerConfig } from './password-checker.config';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class PasswordCheckerLibDirective implements AsyncValidator {
|
|
7
|
-
private http;
|
|
8
|
-
pwnedPasswordApi: string;
|
|
9
|
-
pwnedPasswordMinimumOccurrenceForError: number;
|
|
10
|
-
pwnedPasswordApiCallDebounceTime: number;
|
|
11
|
-
constructor(http: HttpClient, config: Partial<PasswordCheckerConfig>);
|
|
12
|
-
validate(control: AbstractControl): Observable<ValidationErrors | null>;
|
|
13
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PasswordCheckerLibDirective, [null, { optional: true; }]>;
|
|
14
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<PasswordCheckerLibDirective, "[pwnedPasswordValidator][formControlName], [pwnedPasswordValidator][ngModel],[pwnedPasswordValidator][formControl]", never, { "pwnedPasswordApi": { "alias": "pwnedPasswordApi"; "required": false; }; "pwnedPasswordMinimumOccurrenceForError": { "alias": "pwnedPasswordMinimumOccurrenceForError"; "required": false; }; "pwnedPasswordApiCallDebounceTime": { "alias": "pwnedPasswordApiCallDebounceTime"; "required": false; }; }, {}, never, never, true, never>;
|
|
15
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { ModuleWithProviders } from '@angular/core';
|
|
2
|
-
import { Partial, PasswordCheckerConfig } from './password-checker.config';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
import * as i1 from "./password-checker-lib.directive";
|
|
5
|
-
export declare class PasswordCheckerModule {
|
|
6
|
-
static forRoot(config?: Partial<PasswordCheckerConfig>): ModuleWithProviders<PasswordCheckerModule>;
|
|
7
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PasswordCheckerModule, never>;
|
|
8
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<PasswordCheckerModule, never, [typeof i1.PasswordCheckerLibDirective], [typeof i1.PasswordCheckerLibDirective]>;
|
|
9
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<PasswordCheckerModule>;
|
|
10
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { InjectionToken } from '@angular/core';
|
|
2
|
-
export type Partial<T> = {
|
|
3
|
-
[P in keyof T]?: T[P];
|
|
4
|
-
};
|
|
5
|
-
export interface PasswordCheckerConfig {
|
|
6
|
-
pwnedPasswordApi: string;
|
|
7
|
-
pwnedPasswordMinimumOccurrenceForError: number;
|
|
8
|
-
pwnedPasswordApiCallDebounceTime: number;
|
|
9
|
-
}
|
|
10
|
-
export declare const PasswordCheckerConfigValue: InjectionToken<Partial<PasswordCheckerConfig>>;
|
package/public_api.d.ts
DELETED