Move city fieldnames to Identity constants
This commit is contained in:
parent
6304964ad4
commit
61dbe5421f
|
@ -647,7 +647,7 @@ export default class AutofillService implements AutofillServiceInterface {
|
|||
fillFields.postalCode = f;
|
||||
break;
|
||||
} else if (!fillFields.city && this.isFieldMatch(f[attr],
|
||||
['city', 'town', 'address-level-2', 'address-city', 'address-town'])) {
|
||||
IdentityAutoFillConstants.CityFieldNames)) {
|
||||
fillFields.city = f;
|
||||
break;
|
||||
} else if (!fillFields.state && this.isFieldMatch(f[attr],
|
||||
|
|
|
@ -262,6 +262,14 @@ export class IdentityAutoFillConstants {
|
|||
"address-zip-code",
|
||||
];
|
||||
|
||||
static readonly CityFieldNames: string[] = [
|
||||
"city",
|
||||
"town",
|
||||
"address-level-2",
|
||||
"address-city",
|
||||
"address-town",
|
||||
];
|
||||
|
||||
static readonly IsoCountries: { [id: string]: string } = {
|
||||
afghanistan: "AF",
|
||||
"aland islands": "AX",
|
||||
|
|
Loading…
Reference in New Issue