Using Curly (“”) Quotes Does Not Invalidate Email Addresses
Describe the bug When invalidating email addresses in Form.io, addresses that use curly quotes (“”) are considered valid. See the difference between using straight vs curly quotes here.
Version/Branch Current version, however, the bug can be observed on the Form.io portal.
To Reproduce Steps to reproduce the behavior:
- Navigate to the Form.io portal.
- Enter the email address
just"not"[email protected]. As this is an invalid email address as per the RFC5322 it should be invalidated, and Form.io correctly does so.
- Now enter the email address
just“not”[email protected]using curly quotes, and Form.io will fail to invalidate it.
Expected behavior I haven't tested this against any other special characters but emails using curly quotes should still be invalidated as can be observed on many other platforms such as GitHub (verify on the Sign Up page)
This is probably due to the regex validation we currently use to validate email addresses in the email component, I believe this would be solved by simply modifying this test to include curly quotes as well. Would you be willing to submit a PR and a test for this?
I can try. I am not very experienced with Form.io and am a bit unsure about how I can test out my changes but let me see what I can do. It'll take me a few days to get to it.