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

Minifier is removing percentage from 0 value #957

Closed
judowalker opened this issue Jul 13, 2017 · 4 comments
Closed

Minifier is removing percentage from 0 value #957

judowalker opened this issue Jul 13, 2017 · 4 comments
Labels
Milestone

Comments

@judowalker
Copy link

Removing the percentage from a 0 value can affect the way content is displayed and, therefore, should not removed.

I created a minimal working example which demonstrates this. This happens across browsers:
https://codepen.io/judowalker/pen/xrMxWj

@jakubpawlowicz
Copy link
Collaborator

You are right, it's a bug 👍 Do you use clean-css 4.x or 3.x?

@jakubpawlowicz jakubpawlowicz added this to the 4.1.7 milestone Jul 13, 2017
@judowalker
Copy link
Author

I'm actually using grunt-contrib-cssmin 2.1.0 which I think is using 4.x.

@jakubpawlowicz
Copy link
Collaborator

It does indeed. Fix is coming!

jakubpawlowicz added a commit that referenced this issue Jul 14, 2017
Why:

* Apparently `width` and `max-width` `0%` value cannot be turned into
  `0`, see: https://codepen.io/judowalker/pen/xrMxWj
jakubpawlowicz added a commit that referenced this issue Jul 14, 2017
Why:

* Apparently `width` and `max-width` `0%` value cannot be turned into
  `0`, see: https://codepen.io/judowalker/pen/xrMxWj
@jakubpawlowicz
Copy link
Collaborator

It's fixed in 4.1.7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants