Skip to content

Commit

Permalink
Change the phone number regex (#497)
Browse files Browse the repository at this point in the history
  • Loading branch information
tudoramariei authored Jun 27, 2024
1 parent 98f7a78 commit c883919
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/src/common/helpers/format.helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const URL_REGEX =
/(https?:\/\/(?:www\.|(?!www))[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\.[^\s]{2,}|www\.?[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\.[^\s]{2,}|https:\/\/(?:www\.|(?!www))|[a-zA-Z0-9]+\.[^\s]{2,}|www\.[a-zA-Z0-9]+\.[^\s]{2,})|^$/;

export const PHONE_REGEX =
/^(\+4|)?(\s|\.|-)?(07[0-8]{1}[0-9]{1}|02[0-9]{2}|03[0-9]{2}){1}?(\s|\.|-)?([0-9]{3}(\s|\.|-|)){2}$/;
/^(\+4|)?(\s|\.|-)?(07[0-9]{2}|02[0-9]{2}|03[0-9]{2})(\s|\.|-)?([0-9]{3}(\s|\.|-|)){2}$/;
export const CUI_REGEX = /^(RO|)?[\d]*$/;
export const NAME_REGEX = /^(?!.*[ ]{2})[a-zA-Z-\săîâșțĂÎÂȘȚ]*$/;
export const ALPHANUMERIC_REGEX = /^(?!.*[ ]{2})[a-zA-Z\d-\s.#@%&()+/ăîâșțĂÎÂȘȚ,'"]*$/;
Expand Down

0 comments on commit c883919

Please sign in to comment.