We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
After updating css-tree to latest alpha (20/22), declaration name in declaration in media query is missing in (svgo/inlineStyles plugin) tests, see this pared-down test case: https://github.com/strarsis/svgo/tree/test-css-tree-alpha20
$ git clone https://github.com/strarsis/svgo $ cd svgo $ git checkout test-css-tree-alpha20 $ yarn install $ npm test
Downgrading to older alpha (1.0.0-alpha18) resolves this issue, see the working branch: https://github.com/strarsis/svgo/tree/inlineStyles.
Related issue?: #39
The text was updated successfully, but these errors were encountered:
In your branch inlineStyles plugin does nothing https://github.com/strarsis/svgo/blob/test-css-tree-alpha20/plugins/inlineStyles.js
inlineStyles
Sorry, something went wrong.
@lahmatiy: Correct, the issue occurs by just installing css-tree recent alphas, apparently it also interfere with svgo internals.
@strarsis Since alpha20 Atrule.expression is always contain a AtruleExpression, so MediaQueryList lays one level deeper now. You need change line:
Atrule.expression
AtruleExpression
MediaQueryList
if (selector.atrule.expression.type === 'MediaQueryList') {
to
if (selector.atrule.expression && selector.atrule.expression.children.first().type === 'MediaQueryList') {
This fixed problem on my side.
@lahmatiy: Thanks! For whatever reason this also influenced svgo without the plugin.
No branches or pull requests
After updating css-tree to latest alpha (20/22),
declaration name in declaration in media query is missing in (svgo/inlineStyles plugin) tests,
see this pared-down test case: https://github.com/strarsis/svgo/tree/test-css-tree-alpha20
Downgrading to older alpha (1.0.0-alpha18) resolves this issue,
see the working branch: https://github.com/strarsis/svgo/tree/inlineStyles.
Related issue?: #39
The text was updated successfully, but these errors were encountered: