mirror of
https://github.com/bitwarden/browser
synced 2025-01-28 20:19:49 +01:00
Move country fieldnames to Identity constants
This commit is contained in:
parent
4390989a88
commit
423ef40aa1
@ -655,8 +655,7 @@ export default class AutofillService implements AutofillServiceInterface {
|
||||
fillFields.state = f;
|
||||
break;
|
||||
} else if (!fillFields.country && this.isFieldMatch(f[attr],
|
||||
['country', 'country-code', 'country-name', 'address-country', 'address-country-name',
|
||||
'address-country-code'])) {
|
||||
IdentityAutoFillConstants.CountryFieldNames)) {
|
||||
fillFields.country = f;
|
||||
break;
|
||||
} else if (!fillFields.phone && this.isFieldMatch(f[attr],
|
||||
|
@ -279,6 +279,15 @@ export class IdentityAutoFillConstants {
|
||||
"address-province",
|
||||
];
|
||||
|
||||
static readonly CountryFieldNames: string[] = [
|
||||
"country",
|
||||
"country-code",
|
||||
"country-name",
|
||||
"address-country",
|
||||
"address-country-name",
|
||||
"address-country-code",
|
||||
];
|
||||
|
||||
static readonly IsoCountries: { [id: string]: string } = {
|
||||
afghanistan: "AF",
|
||||
"aland islands": "AX",
|
||||
|
Loading…
x
Reference in New Issue
Block a user