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

CSS Calc() Functions Improperly Compressed According to Specifications #244

Open
own3mall opened this issue Mar 25, 2016 · 3 comments
Open

Comments

@own3mall
Copy link
Contributor

yuicompressor-2.4.8 incorrectly compresses calc() CSS functions by removing white space between operators. According to the spec, the operators must be surrounded by white space to work. If they are not, the CSS property will not apply.

https://developer.mozilla.org/en-US/docs/Web/CSS/calc

"The + and - operators must always be surrounded by whitespace."

Yui Compressor products the following:

transform:translate(calc(-100%+30px),100%)}

It should instead be:

transform:translate(calc(-100% + 30px),100%)}

Will this be fixed in the next version?

@own3mall
Copy link
Contributor Author

I think this issue is fixed in my branch.

https://github.com/own3mall/yuicompressor

@godchuanz
Copy link

Hi, do you have a built jar file for download, for the benefit of those of us without build tools?

@own3mall
Copy link
Contributor Author

Yes, here it is:

https://github.com/own3mall/yuicompressor/releases/tag/2.4.9

Hope it helps with any calc minification needed.

On Mon, Apr 11, 2016 at 2:11 AM, godchuanz notifications@github.com wrote:

Hi, do you have a built jar file for download, for the benefit of those of
us without build tools?


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
#244 (comment)

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

No branches or pull requests

2 participants