angular-iban 18.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/LICENSE +1 -1
- package/README.md +3 -2
- package/fesm2022/angular-iban.mjs +12 -10
- package/fesm2022/angular-iban.mjs.map +1 -1
- package/index.d.ts +29 -5
- package/package.json +3 -5
- package/esm2022/angular-iban.mjs +0 -5
- package/esm2022/lib/angular-iban.module.mjs +0 -26
- package/esm2022/lib/directives/iban-validator.directive.mjs +0 -19
- package/esm2022/lib/pipes/iban-formatter.pipe.mjs +0 -20
- package/esm2022/lib/services/validator.service.mjs +0 -10
- package/esm2022/public-api.mjs +0 -8
- package/lib/angular-iban.module.d.ts +0 -8
- package/lib/directives/iban-validator.directive.d.ts +0 -9
- package/lib/pipes/iban-formatter.pipe.d.ts +0 -7
- package/lib/services/validator.service.d.ts +0 -4
- package/public-api.d.ts +0 -4
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -26,7 +26,8 @@ This library supports Angular 7+. Please check the Version compatibility below t
|
|
|
26
26
|
| 16.x | 16.x |
|
|
27
27
|
| 17.x | 17.x |
|
|
28
28
|
| 18.x | 18.x |
|
|
29
|
-
|
|
29
|
+
| 19.x | 19.x |
|
|
30
|
+
| 20.x | 20.x |
|
|
30
31
|
## Installation
|
|
31
32
|
|
|
32
33
|
npm:
|
|
@@ -193,6 +194,6 @@ Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`.
|
|
|
193
194
|
|
|
194
195
|
## License
|
|
195
196
|
|
|
196
|
-
Copyright (c) 2018 -
|
|
197
|
+
Copyright (c) 2018 - 2025 fundsaccess AG. Licensed under the MIT License (MIT)
|
|
197
198
|
|
|
198
199
|
|
|
@@ -16,14 +16,15 @@ class IbanValidatorDirective {
|
|
|
16
16
|
validate(c) {
|
|
17
17
|
return ValidatorService.validateIban(c);
|
|
18
18
|
}
|
|
19
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
20
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
19
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: IbanValidatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
20
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.0.3", type: IbanValidatorDirective, isStandalone: false, selector: "[ibanValidator]", providers: [{ provide: NG_VALIDATORS, useExisting: IbanValidatorDirective, multi: true }], ngImport: i0 }); }
|
|
21
21
|
}
|
|
22
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
22
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: IbanValidatorDirective, decorators: [{
|
|
23
23
|
type: Directive,
|
|
24
24
|
args: [{
|
|
25
25
|
selector: '[ibanValidator]',
|
|
26
26
|
providers: [{ provide: NG_VALIDATORS, useExisting: IbanValidatorDirective, multi: true }],
|
|
27
|
+
standalone: false
|
|
27
28
|
}]
|
|
28
29
|
}] });
|
|
29
30
|
|
|
@@ -34,24 +35,25 @@ class IbanFormatterPipe {
|
|
|
34
35
|
}
|
|
35
36
|
return value;
|
|
36
37
|
}
|
|
37
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
38
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "
|
|
38
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: IbanFormatterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
39
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.0.3", ngImport: i0, type: IbanFormatterPipe, isStandalone: false, name: "ibanFormatter" }); }
|
|
39
40
|
}
|
|
40
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
41
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: IbanFormatterPipe, decorators: [{
|
|
41
42
|
type: Pipe,
|
|
42
43
|
args: [{
|
|
43
44
|
name: 'ibanFormatter',
|
|
45
|
+
standalone: false
|
|
44
46
|
}]
|
|
45
47
|
}] });
|
|
46
48
|
|
|
47
49
|
class AngularIbanModule {
|
|
48
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
49
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
50
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: AngularIbanModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
51
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.0.3", ngImport: i0, type: AngularIbanModule, declarations: [IbanValidatorDirective,
|
|
50
52
|
IbanFormatterPipe], exports: [IbanValidatorDirective,
|
|
51
53
|
IbanFormatterPipe] }); }
|
|
52
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
54
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: AngularIbanModule }); }
|
|
53
55
|
}
|
|
54
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
56
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.3", ngImport: i0, type: AngularIbanModule, decorators: [{
|
|
55
57
|
type: NgModule,
|
|
56
58
|
args: [{
|
|
57
59
|
declarations: [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"angular-iban.mjs","sources":["../../../projects/angular-iban/src/lib/services/validator.service.ts","../../../projects/angular-iban/src/lib/directives/iban-validator.directive.ts","../../../projects/angular-iban/src/lib/pipes/iban-formatter.pipe.ts","../../../projects/angular-iban/src/lib/angular-iban.module.ts","../../../projects/angular-iban/src/public-api.ts","../../../projects/angular-iban/src/angular-iban.ts"],"sourcesContent":["import { AbstractControl, ValidationErrors } from '@angular/forms';\r\nimport * as IBAN from 'iban';\r\n\r\nexport class ValidatorService {\r\n static validateIban(c: AbstractControl): ValidationErrors {\r\n if (c.value && !IBAN.isValid(c.value)) {\r\n return { iban: { value: c.value } };\r\n }\r\n\r\n return null as any;\r\n }\r\n}\r\n","import { Directive } from '@angular/core';\r\nimport { NG_VALIDATORS, Validator, AbstractControl } from '@angular/forms';\r\nimport { ValidatorService } from '../services/validator.service';\r\n\r\n@Directive({\
|
|
1
|
+
{"version":3,"file":"angular-iban.mjs","sources":["../../../projects/angular-iban/src/lib/services/validator.service.ts","../../../projects/angular-iban/src/lib/directives/iban-validator.directive.ts","../../../projects/angular-iban/src/lib/pipes/iban-formatter.pipe.ts","../../../projects/angular-iban/src/lib/angular-iban.module.ts","../../../projects/angular-iban/src/public-api.ts","../../../projects/angular-iban/src/angular-iban.ts"],"sourcesContent":["import { AbstractControl, ValidationErrors } from '@angular/forms';\r\nimport * as IBAN from 'iban';\r\n\r\nexport class ValidatorService {\r\n static validateIban(c: AbstractControl): ValidationErrors {\r\n if (c.value && !IBAN.isValid(c.value)) {\r\n return { iban: { value: c.value } };\r\n }\r\n\r\n return null as any;\r\n }\r\n}\r\n","import { Directive } from '@angular/core';\r\nimport { NG_VALIDATORS, Validator, AbstractControl } from '@angular/forms';\r\nimport { ValidatorService } from '../services/validator.service';\r\n\r\n@Directive({\n selector: '[ibanValidator]',\n providers: [{ provide: NG_VALIDATORS, useExisting: IbanValidatorDirective, multi: true }],\n standalone: false\n})\r\nexport class IbanValidatorDirective implements Validator {\r\n validate(c: AbstractControl): { [key: string]: any } {\r\n return ValidatorService.validateIban(c);\r\n }\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core';\r\nimport * as IBAN from 'iban';\r\n\r\n@Pipe({\n name: 'ibanFormatter',\n standalone: false\n})\r\nexport class IbanFormatterPipe implements PipeTransform {\r\n transform(value: any, args?: any): any {\r\n if (IBAN.isValid(value)) {\r\n return IBAN.printFormat(value, ' ');\r\n }\r\n return value;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { IbanValidatorDirective } from './directives/iban-validator.directive';\r\nimport { IbanFormatterPipe } from './pipes/iban-formatter.pipe';\r\n\r\n@NgModule({\r\n declarations: [\r\n IbanValidatorDirective,\r\n IbanFormatterPipe,\r\n ],\r\n imports: [\r\n ],\r\n exports: [\r\n IbanValidatorDirective,\r\n IbanFormatterPipe,\r\n ],\r\n})\r\nexport class AngularIbanModule { }\r\n","/*\r\n * Public API Surface of angular-iban\r\n */\r\n\r\nexport * from './lib/angular-iban.module';\r\nexport * from './lib/services/validator.service';\r\nexport * from './lib/directives/iban-validator.directive';\r\nexport * from './lib/pipes/iban-formatter.pipe';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAGa,gBAAgB,CAAA;IAC3B,OAAO,YAAY,CAAC,CAAkB,EAAA;AACpC,QAAA,IAAI,CAAC,CAAC,KAAK,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE;YACrC,OAAO,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC,KAAK,EAAE,EAAE;;AAGrC,QAAA,OAAO,IAAW;;AAErB;;MCFY,sBAAsB,CAAA;AACjC,IAAA,QAAQ,CAAC,CAAkB,EAAA;AACzB,QAAA,OAAO,gBAAgB,CAAC,YAAY,CAAC,CAAC,CAAC;;8GAF9B,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAt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EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAjB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,iBAV1B,sBAAsB;AACtB,YAAA,iBAAiB,aAKjB,sBAAsB;YACtB,iBAAiB,CAAA,EAAA,CAAA,CAAA;+GAGR,iBAAiB,EAAA,CAAA,CAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAZ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,sBAAsB;wBACtB,iBAAiB;AAClB,qBAAA;AACD,oBAAA,OAAO,EAAE,EACR;AACD,oBAAA,OAAO,EAAE;wBACP,sBAAsB;wBACtB,iBAAiB;AAClB,qBAAA;AACF,iBAAA;;;ACfD;;AAEG;;ACFH;;AAEG;;;;"}
|
package/index.d.ts
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { PipeTransform } from '@angular/core';
|
|
3
|
+
import { Validator, AbstractControl, ValidationErrors } from '@angular/forms';
|
|
4
|
+
|
|
5
|
+
declare class IbanValidatorDirective implements Validator {
|
|
6
|
+
validate(c: AbstractControl): {
|
|
7
|
+
[key: string]: any;
|
|
8
|
+
};
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<IbanValidatorDirective, never>;
|
|
10
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<IbanValidatorDirective, "[ibanValidator]", never, {}, {}, never, never, false, never>;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
declare class IbanFormatterPipe implements PipeTransform {
|
|
14
|
+
transform(value: any, args?: any): any;
|
|
15
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<IbanFormatterPipe, never>;
|
|
16
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<IbanFormatterPipe, "ibanFormatter", false>;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
declare class AngularIbanModule {
|
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AngularIbanModule, never>;
|
|
21
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularIbanModule, [typeof IbanValidatorDirective, typeof IbanFormatterPipe], never, [typeof IbanValidatorDirective, typeof IbanFormatterPipe]>;
|
|
22
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AngularIbanModule>;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
declare class ValidatorService {
|
|
26
|
+
static validateIban(c: AbstractControl): ValidationErrors;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export { AngularIbanModule, IbanFormatterPipe, IbanValidatorDirective, ValidatorService };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "angular-iban",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "20.0.0",
|
|
4
4
|
"description": "Angular directives and pipes for IBAN",
|
|
5
5
|
"author": "fundsaccess AG",
|
|
6
6
|
"repository": {
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"typescript"
|
|
17
17
|
],
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@angular/common": "^
|
|
20
|
-
"@angular/core": "^
|
|
19
|
+
"@angular/common": "^20.x",
|
|
20
|
+
"@angular/core": "^20.x",
|
|
21
21
|
"iban": "0.0.14"
|
|
22
22
|
},
|
|
23
23
|
"license": "MIT",
|
|
@@ -32,8 +32,6 @@
|
|
|
32
32
|
},
|
|
33
33
|
".": {
|
|
34
34
|
"types": "./index.d.ts",
|
|
35
|
-
"esm2022": "./esm2022/angular-iban.mjs",
|
|
36
|
-
"esm": "./esm2022/angular-iban.mjs",
|
|
37
35
|
"default": "./fesm2022/angular-iban.mjs"
|
|
38
36
|
}
|
|
39
37
|
},
|
package/esm2022/angular-iban.mjs
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated bundle index. Do not edit.
|
|
3
|
-
*/
|
|
4
|
-
export * from './public-api';
|
|
5
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYW5ndWxhci1pYmFuLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vcHJvamVjdHMvYW5ndWxhci1pYmFuL3NyYy9hbmd1bGFyLWliYW4udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { NgModule } from '@angular/core';
|
|
2
|
-
import { IbanValidatorDirective } from './directives/iban-validator.directive';
|
|
3
|
-
import { IbanFormatterPipe } from './pipes/iban-formatter.pipe';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
export class AngularIbanModule {
|
|
6
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: AngularIbanModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
7
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.3", ngImport: i0, type: AngularIbanModule, declarations: [IbanValidatorDirective,
|
|
8
|
-
IbanFormatterPipe], exports: [IbanValidatorDirective,
|
|
9
|
-
IbanFormatterPipe] }); }
|
|
10
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: AngularIbanModule }); }
|
|
11
|
-
}
|
|
12
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: AngularIbanModule, decorators: [{
|
|
13
|
-
type: NgModule,
|
|
14
|
-
args: [{
|
|
15
|
-
declarations: [
|
|
16
|
-
IbanValidatorDirective,
|
|
17
|
-
IbanFormatterPipe,
|
|
18
|
-
],
|
|
19
|
-
imports: [],
|
|
20
|
-
exports: [
|
|
21
|
-
IbanValidatorDirective,
|
|
22
|
-
IbanFormatterPipe,
|
|
23
|
-
],
|
|
24
|
-
}]
|
|
25
|
-
}] });
|
|
26
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYW5ndWxhci1pYmFuLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL2FuZ3VsYXItaWJhbi9zcmMvbGliL2FuZ3VsYXItaWJhbi5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUN6QyxPQUFPLEVBQUUsc0JBQXNCLEVBQUUsTUFBTSx1Q0FBdUMsQ0FBQztBQUMvRSxPQUFPLEVBQUUsaUJBQWlCLEVBQUUsTUFBTSw2QkFBNkIsQ0FBQzs7QUFjaEUsTUFBTSxPQUFPLGlCQUFpQjs4R0FBakIsaUJBQWlCOytHQUFqQixpQkFBaUIsaUJBVjFCLHNCQUFzQjtZQUN0QixpQkFBaUIsYUFLakIsc0JBQXNCO1lBQ3RCLGlCQUFpQjsrR0FHUixpQkFBaUI7OzJGQUFqQixpQkFBaUI7a0JBWjdCLFFBQVE7bUJBQUM7b0JBQ1IsWUFBWSxFQUFFO3dCQUNaLHNCQUFzQjt3QkFDdEIsaUJBQWlCO3FCQUNsQjtvQkFDRCxPQUFPLEVBQUUsRUFDUjtvQkFDRCxPQUFPLEVBQUU7d0JBQ1Asc0JBQXNCO3dCQUN0QixpQkFBaUI7cUJBQ2xCO2lCQUNGIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgTmdNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9jb3JlJztcclxuaW1wb3J0IHsgSWJhblZhbGlkYXRvckRpcmVjdGl2ZSB9IGZyb20gJy4vZGlyZWN0aXZlcy9pYmFuLXZhbGlkYXRvci5kaXJlY3RpdmUnO1xyXG5pbXBvcnQgeyBJYmFuRm9ybWF0dGVyUGlwZSB9IGZyb20gJy4vcGlwZXMvaWJhbi1mb3JtYXR0ZXIucGlwZSc7XHJcblxyXG5ATmdNb2R1bGUoe1xyXG4gIGRlY2xhcmF0aW9uczogW1xyXG4gICAgSWJhblZhbGlkYXRvckRpcmVjdGl2ZSxcclxuICAgIEliYW5Gb3JtYXR0ZXJQaXBlLFxyXG4gIF0sXHJcbiAgaW1wb3J0czogW1xyXG4gIF0sXHJcbiAgZXhwb3J0czogW1xyXG4gICAgSWJhblZhbGlkYXRvckRpcmVjdGl2ZSxcclxuICAgIEliYW5Gb3JtYXR0ZXJQaXBlLFxyXG4gIF0sXHJcbn0pXHJcbmV4cG9ydCBjbGFzcyBBbmd1bGFySWJhbk1vZHVsZSB7IH1cclxuIl19
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { Directive } from '@angular/core';
|
|
2
|
-
import { NG_VALIDATORS } from '@angular/forms';
|
|
3
|
-
import { ValidatorService } from '../services/validator.service';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
export class IbanValidatorDirective {
|
|
6
|
-
validate(c) {
|
|
7
|
-
return ValidatorService.validateIban(c);
|
|
8
|
-
}
|
|
9
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: IbanValidatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
10
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.3", type: IbanValidatorDirective, selector: "[ibanValidator]", providers: [{ provide: NG_VALIDATORS, useExisting: IbanValidatorDirective, multi: true }], ngImport: i0 }); }
|
|
11
|
-
}
|
|
12
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: IbanValidatorDirective, decorators: [{
|
|
13
|
-
type: Directive,
|
|
14
|
-
args: [{
|
|
15
|
-
selector: '[ibanValidator]',
|
|
16
|
-
providers: [{ provide: NG_VALIDATORS, useExisting: IbanValidatorDirective, multi: true }],
|
|
17
|
-
}]
|
|
18
|
-
}] });
|
|
19
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaWJhbi12YWxpZGF0b3IuZGlyZWN0aXZlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvYW5ndWxhci1pYmFuL3NyYy9saWIvZGlyZWN0aXZlcy9pYmFuLXZhbGlkYXRvci5kaXJlY3RpdmUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUMxQyxPQUFPLEVBQUUsYUFBYSxFQUE4QixNQUFNLGdCQUFnQixDQUFDO0FBQzNFLE9BQU8sRUFBRSxnQkFBZ0IsRUFBRSxNQUFNLCtCQUErQixDQUFDOztBQU1qRSxNQUFNLE9BQU8sc0JBQXNCO0lBQ2pDLFFBQVEsQ0FBQyxDQUFrQjtRQUN6QixPQUFPLGdCQUFnQixDQUFDLFlBQVksQ0FBQyxDQUFDLENBQUMsQ0FBQztJQUMxQyxDQUFDOzhHQUhVLHNCQUFzQjtrR0FBdEIsc0JBQXNCL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 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as IBAN from 'iban';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export class IbanFormatterPipe {
|
|
5
|
-
transform(value, args) {
|
|
6
|
-
if (IBAN.isValid(value)) {
|
|
7
|
-
return IBAN.printFormat(value, ' ');
|
|
8
|
-
}
|
|
9
|
-
return value;
|
|
10
|
-
}
|
|
11
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: IbanFormatterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
12
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.0.3", ngImport: i0, type: IbanFormatterPipe, name: "ibanFormatter" }); }
|
|
13
|
-
}
|
|
14
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.3", ngImport: i0, type: IbanFormatterPipe, decorators: [{
|
|
15
|
-
type: Pipe,
|
|
16
|
-
args: [{
|
|
17
|
-
name: 'ibanFormatter',
|
|
18
|
-
}]
|
|
19
|
-
}] });
|
|
20
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaWJhbi1mb3JtYXR0ZXIucGlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2FuZ3VsYXItaWJhbi9zcmMvbGliL3BpcGVzL2liYW4tZm9ybWF0dGVyLnBpcGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLElBQUksRUFBaUIsTUFBTSxlQUFlLENBQUM7QUFDcEQsT0FBTyxLQUFLLElBQUksTUFBTSxNQUFNLENBQUM7O0FBSzdCLE1BQU0sT0FBTyxpQkFBaUI7SUFDNUIsU0FBUyxDQUFDLEtBQVUsRUFBRSxJQUFVO1FBQzlCLElBQUksSUFBSSxDQUFDLE9BQU8sQ0FBQyxLQUFLLENBQUMsRUFBRSxDQUFDO1lBQ3hCLE9BQU8sSUFBSSxDQUFDLFdBQVcsQ0FBQyxLQUFLLEVBQUUsR0FBRyxDQUFDLENBQUM7UUFDdEMsQ0FBQztRQUNELE9BQU8sS0FBSyxDQUFDO0lBQ2YsQ0FBQzs4R0FOVSxpQkFBaUI7NEdBQWpCLGlCQUFpQjs7MkZBQWpCLGlCQUFpQjtrQkFIN0IsSUFBSTttQkFBQztvQkFDSixJQUFJLEVBQUUsZUFBZTtpQkFDdEIiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBQaXBlLCBQaXBlVHJhbnNmb3JtIH0gZnJvbSAnQGFuZ3VsYXIvY29yZSc7XHJcbmltcG9ydCAqIGFzIElCQU4gZnJvbSAnaWJhbic7XHJcblxyXG5AUGlwZSh7XHJcbiAgbmFtZTogJ2liYW5Gb3JtYXR0ZXInLFxyXG59KVxyXG5leHBvcnQgY2xhc3MgSWJhbkZvcm1hdHRlclBpcGUgaW1wbGVtZW50cyBQaXBlVHJhbnNmb3JtIHtcclxuICB0cmFuc2Zvcm0odmFsdWU6IGFueSwgYXJncz86IGFueSk6IGFueSB7XHJcbiAgICBpZiAoSUJBTi5pc1ZhbGlkKHZhbHVlKSkge1xyXG4gICAgICByZXR1cm4gSUJBTi5wcmludEZvcm1hdCh2YWx1ZSwgJyAnKTtcclxuICAgIH1cclxuICAgIHJldHVybiB2YWx1ZTtcclxuICB9XHJcbn1cclxuIl19
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as IBAN from 'iban';
|
|
2
|
-
export class ValidatorService {
|
|
3
|
-
static validateIban(c) {
|
|
4
|
-
if (c.value && !IBAN.isValid(c.value)) {
|
|
5
|
-
return { iban: { value: c.value } };
|
|
6
|
-
}
|
|
7
|
-
return null;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=data:application/json;base64,ey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4gICAgcmV0dXJuIG51bGwgYXMgYW55O1xyXG4gIH1cclxufVxyXG4iXX0=
|
package/esm2022/public-api.mjs
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Public API Surface of angular-iban
|
|
3
|
-
*/
|
|
4
|
-
export * from './lib/angular-iban.module';
|
|
5
|
-
export * from './lib/services/validator.service';
|
|
6
|
-
export * from './lib/directives/iban-validator.directive';
|
|
7
|
-
export * from './lib/pipes/iban-formatter.pipe';
|
|
8
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL2FuZ3VsYXItaWJhbi9zcmMvcHVibGljLWFwaS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVILGNBQWMsMkJBQTJCLENBQUM7QUFDMUMsY0FBYyxrQ0FBa0MsQ0FBQztBQUNqRCxjQUFjLDJDQUEyQyxDQUFDO0FBQzFELGNBQWMsaUNBQWlDLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKlxyXG4gKiBQdWJsaWMgQVBJIFN1cmZhY2Ugb2YgYW5ndWxhci1pYmFuXHJcbiAqL1xyXG5cclxuZXhwb3J0ICogZnJvbSAnLi9saWIvYW5ndWxhci1pYmFuLm1vZHVsZSc7XHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL3NlcnZpY2VzL3ZhbGlkYXRvci5zZXJ2aWNlJztcclxuZXhwb3J0ICogZnJvbSAnLi9saWIvZGlyZWN0aXZlcy9pYmFuLXZhbGlkYXRvci5kaXJlY3RpdmUnO1xyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9waXBlcy9pYmFuLWZvcm1hdHRlci5waXBlJztcclxuIl19
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./directives/iban-validator.directive";
|
|
3
|
-
import * as i2 from "./pipes/iban-formatter.pipe";
|
|
4
|
-
export declare class AngularIbanModule {
|
|
5
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularIbanModule, never>;
|
|
6
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularIbanModule, [typeof i1.IbanValidatorDirective, typeof i2.IbanFormatterPipe], never, [typeof i1.IbanValidatorDirective, typeof i2.IbanFormatterPipe]>;
|
|
7
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<AngularIbanModule>;
|
|
8
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Validator, AbstractControl } from '@angular/forms';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class IbanValidatorDirective implements Validator {
|
|
4
|
-
validate(c: AbstractControl): {
|
|
5
|
-
[key: string]: any;
|
|
6
|
-
};
|
|
7
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<IbanValidatorDirective, never>;
|
|
8
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<IbanValidatorDirective, "[ibanValidator]", never, {}, {}, never, never, false, never>;
|
|
9
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { PipeTransform } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class IbanFormatterPipe implements PipeTransform {
|
|
4
|
-
transform(value: any, args?: any): any;
|
|
5
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<IbanFormatterPipe, never>;
|
|
6
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<IbanFormatterPipe, "ibanFormatter", false>;
|
|
7
|
-
}
|
package/public-api.d.ts
DELETED