Skip to content

31830 - Validate Optional Phone Number in ContactInfo if Provided#298

Merged
severinbeauvais merged 2 commits intobcgov:mainfrom
meawong:31830-Update-Phone-Number-Validation-for-ContactInfo-Component
Jan 22, 2026
Merged

31830 - Validate Optional Phone Number in ContactInfo if Provided#298
severinbeauvais merged 2 commits intobcgov:mainfrom
meawong:31830-Update-Phone-Number-Validation-for-ContactInfo-Component

Conversation

@meawong
Copy link
Collaborator

@meawong meawong commented Jan 21, 2026

Issue #: /bcgov/entity#31830

Description of changes:

  • Validate the format of the optional phone number if provided, still allows this field to be left blank (this aligns with the behaviour in create-ui for the optional phone number)
  • Discussed and approved by Jacqueline

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the business-filings-ui license (Apache 2.0).

@meawong meawong self-assigned this Jan 21, 2026
Copy link
Collaborator

@severinbeauvais severinbeauvais left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine.

Are there any unit tests that need to be added or could be updated?

Can you try to regenerate the Storybook files, please?
Ref: https://github.com/bcgov/bcrs-shared-components?tab=readme-ov-file#10-build-storybook-and-verify-your-component

@meawong
Copy link
Collaborator Author

meawong commented Jan 22, 2026

Also updated the error message as per Jacqueline's request.

Recording 2026-01-21 at 16 13 55

Copy link
Collaborator

@severinbeauvais severinbeauvais left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved. Stand by while I merge and then publish this change.

@severinbeauvais severinbeauvais merged commit da9b8b3 into bcgov:main Jan 22, 2026
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants