Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Color.of-css accepts invalid hex format #301

Open
zeptometer opened this issue Mar 3, 2024 · 0 comments
Open

Color.of-css accepts invalid hex format #301

zeptometer opened this issue Mar 3, 2024 · 0 comments

Comments

@zeptometer
Copy link
Collaborator

Current behavior

Color.of-css `invalid#000000` successfully returns a color value

Expected behavior

Should fail with panic

Note

This behavior is because the regex to extract rgb value is #(\h\h)(\h\h)(\h\h), which should be ^#(\h\h)(\h\h)(\h\h)$.

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

No branches or pull requests

1 participant