Move address fieldnames to Identity constants
This commit is contained in:
parent
9e350e25ce
commit
ff6e63a335
|
@ -626,8 +626,7 @@ export default class AutofillService implements AutofillServiceInterface {
|
||||||
fillFields.email = f;
|
fillFields.email = f;
|
||||||
break;
|
break;
|
||||||
} else if (!fillFields.address && this.isFieldMatch(f[attr],
|
} else if (!fillFields.address && this.isFieldMatch(f[attr],
|
||||||
['address', 'street-address', 'addr', 'street', 'mailing-addr', 'billing-addr',
|
IdentityAutoFillConstants.AddressFieldNames, ['mailing-addr', 'billing-addr', 'mail-addr', 'bill-addr'])) {
|
||||||
'mail-addr', 'bill-addr'], ['mailing-addr', 'billing-addr', 'mail-addr', 'bill-addr'])) {
|
|
||||||
fillFields.address = f;
|
fillFields.address = f;
|
||||||
break;
|
break;
|
||||||
} else if (!fillFields.address1 && this.isFieldMatch(f[attr],
|
} else if (!fillFields.address1 && this.isFieldMatch(f[attr],
|
||||||
|
|
|
@ -229,6 +229,17 @@ export class IdentityAutoFillConstants {
|
||||||
|
|
||||||
static readonly EmailFieldNames: string[] = ["e-mail", "email-address"];
|
static readonly EmailFieldNames: string[] = ["e-mail", "email-address"];
|
||||||
|
|
||||||
|
static readonly AddressFieldNames: string[] = [
|
||||||
|
"address",
|
||||||
|
"street-address",
|
||||||
|
"addr",
|
||||||
|
"street",
|
||||||
|
"mailing-addr",
|
||||||
|
"billing-addr",
|
||||||
|
"mail-addr",
|
||||||
|
"bill-addr",
|
||||||
|
];
|
||||||
|
|
||||||
static readonly Address1FieldNames: string[] = [
|
static readonly Address1FieldNames: string[] = [
|
||||||
"address-1",
|
"address-1",
|
||||||
"address-line-1",
|
"address-line-1",
|
||||||
|
|
Loading…
Reference in New Issue