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(postcss-svgo): normalize SVG with escaped quote characters #1200

Merged
merged 3 commits into from Oct 19, 2021

Conversation

IronGeek
Copy link
Contributor

Fixes #1194

Signed-off-by: Jakka Prihatna <jprihatna@gmail.com>
@codecov-commenter
Copy link

codecov-commenter commented Sep 25, 2021

Codecov Report

Merging #1200 (354d331) into master (3a1410e) will increase coverage by 0.00%.
The diff coverage is 100.00%.

❗ Current head 354d331 differs from pull request most recent head 5e22295. Consider uploading reports for the commit 5e22295 to get more accurate results
Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1200   +/-   ##
=======================================
  Coverage   96.56%   96.57%           
=======================================
  Files         117      117           
  Lines        3644     3646    +2     
  Branches     1071     1071           
=======================================
+ Hits         3519     3521    +2     
  Misses        117      117           
  Partials        8        8           
Impacted Files Coverage Δ
packages/postcss-svgo/src/index.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3a1410e...5e22295. Read the comment docs.

Copy link
Collaborator

@ludofischer ludofischer left a comment

Choose a reason for hiding this comment

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

It does seem to fix this problem, but I wonder whether this is an issue with postcss-value-parser. Is css-value-parser supposed to return the escape characters? @alexander-akait any thoughts?

packages/postcss-svgo/src/index.js Show resolved Hide resolved
@alexander-akait
Copy link
Member

@ludofischer hm, look like something broken, ideally parser should return { string: "normalized-value", rawString: "real-value" } and we should use rawString... We can merge it here, but will be great to fix it in parser

@ludofischer
Copy link
Collaborator

Since we could not fix this in the parser in the last 18 days, I think I am going to merge this, so at least we've got the test cases.

@ludofischer ludofischer merged commit 4ef5e41 into cssnano:master Oct 19, 2021
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.

[Bug]: Cannot process data uri SVG with escaped quote characters
4 participants