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

Fix #1267 no support to #RRGGBBAA CSS 4 hex color #1269

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

perenciolo
Copy link

What do the changes you have made achieve?
Fix no support to #RRGGBBAA CSS 4 hex color on sass lint files
Have you included relevant documentation
https://drafts.csswg.org/css-color/#hex-notation
Which issues does this resolve?
#1267
<DCO 1.1 Signed-off-by: Gustavo Perenciolo contategustavoh@gmail.com>

return true;
}
return false;
return /^([a-f0-9]{8}|[a-f0-9]{6}|[a-f0-9]{4}|[a-f0-9]{3})$/i.test(str);

Choose a reason for hiding this comment

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

Suggested change
return /^([a-f0-9]{8}|[a-f0-9]{6}|[a-f0-9]{4}|[a-f0-9]{3})$/i.test(str);
return /^([A-Fa-f0-9]{8}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{4}|[A-Fa-f0-9]{3})$/i.test(str);

Your pattern did not match against hex values containing uppercase letters.

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.

None yet

2 participants