-
-
Notifications
You must be signed in to change notification settings - Fork 39
CSS spec compliance: !IMPORTANT
is valid – should be case insensitive
#89
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
Comments
Fix should go here, should be a simple regex instead of straight string compare. |
I've fixed this for less mixins, but I think the issue should be migrated to shellscape/postcss edit: oops just noticed the related bug in that repo |
@shellscape I asked myself the same question when I saw #91 and tried it – but, no, this is still an issue. |
I've made the check for mixins case-insensitive, see related test: https://github.com/shellscape/postcss-less/pull/91/files#diff-d7e2ac4acbb2c79fd1039710696f1cefR139 the postcss bug postcss/postcss#1065 is also fixed, it landed in 6.0.11. Should we update |
* chore: fix linting errors * chore: de-esm * chore: de-esm, start move to ava * chore: move to circle * chore: gulp to npm scripts, housekeeping * chore: unfuck prev de-esm * test: get root tests passing * test: better integration tests * test: finish ava migration * chore: clean up package, add code coverage * chore(ci): fix lint script * test: ignore postcss-parser-tests until after 7.x update * chore(ci): add node 6 to circle config * fix: fixes #88, malformed filenames and missing semicolons in imports * fix: fixes #89, case insensitive !important * chore: keep the old parsers around for reference temporarily * refactor: leverage postcss 7.0 * refactor: enable mixins * chore: improve linting, fix variable parse, enable sanity check tests * chore: get stringifying working * chore: re-implement stringifying, update tests, remove old /lib * test: add test for #110 * test: add test for #108 * chore: implement interpolation, update tests * fix: fixes #102 and #86 * chore: code cleanup
LESS
a{k: v !IMPORTANT;}
JavaScript
Expected Behavior
The declaration should be parsed as:
Just like for
a{k: v !important;}
.Actual Behavior
The declaration is parsed as:
How can we reproduce the behavior?
Spec
CSS is actually mostly case insensitive. Here is the spec mentioning how
!important
should be parsed case insensitively: https://www.w3.org/TR/css-syntax-3/#consume-a-declarationRelated
postcss/postcss#1065
The text was updated successfully, but these errors were encountered: