From 2201b078d5a50b674920efcf086bf40d6403878d Mon Sep 17 00:00:00 2001 From: Benjamin Palko Date: Mon, 30 Dec 2024 23:47:51 -0500 Subject: [PATCH] allow region code --- src/lib/regex/phone.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/regex/phone.ts b/src/lib/regex/phone.ts index 116afc4..ff0ad0c 100644 --- a/src/lib/regex/phone.ts +++ b/src/lib/regex/phone.ts @@ -1 +1 @@ -export const PhoneRegex = /^(1-)?\d{3}-?\d{3}-?\d{4}$/; \ No newline at end of file +export const PhoneRegex = /^\+?\d?(\d{3}\d{3}\d{4}|\d{3}-\d{3}-\d{4})$/; \ No newline at end of file