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
Add ignoreFontFamilies option to font-family-no-missing-generic-family-keyword
#4656
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mattfelten Thank you for your pull request!
I now realise that the option should be called ignoreFontFamilies
as value
is ambiguous and does not take into account font families within the value of the font
shorthand property. Can you update the pull request to reflect this, please?
I've also requested a couple of other changes to bring the option in line with those in other rules.
lib/rules/font-family-no-missing-generic-family-keyword/__tests__/index.js
Outdated
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/__tests__/index.js
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/index.js
Outdated
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/index.js
Outdated
Show resolved
Hide resolved
font-family-no-missing-generic-family-keyword
font-family-no-missing-generic-family-keyword
@jeddy3 Thanks for the review. Just made the requested changes. Let me know if I can make this better any more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mattfelten Thanks for making the amends. It's looking good!
I've made two more, very minor, requests.
lib/rules/font-family-no-missing-generic-family-keyword/README.md
Outdated
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/index.js
Outdated
Show resolved
Hide resolved
@jeddy3 Thanks! Got those taken care of too |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mattfelten Thanks for making the changes so promptly. For some reason, I didn't get a notification so I'm only just looking now.
We'll make sure this gets into our next pending release.
Thanks again!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found some typos and suggest one on the rule document.
lib/rules/font-family-no-missing-generic-family-keyword/README.md
Outdated
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/README.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[suggestion] Is it reasonable to add test cases for regex?
lib/rules/font-family-no-missing-generic-family-keyword/__tests__/index.js
Outdated
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/__tests__/index.js
Show resolved
Hide resolved
lib/rules/font-family-no-missing-generic-family-keyword/__tests__/index.js
Show resolved
Hide resolved
Thanks @jeddy3 ! @ybiquitous I got your changes in. Thanks for looking! Lmk if I can improve anything else. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!👍
Changelog:
|
Closes #3288
Seems to work alright so far. Something I'm struggling with is how a font family name in quotes should be written. I couldn't tell if that works and I'm just writing the test poorly or this doesn't work with quoted names.