Problem/Motivation
When importing CSS files containing escaped quotes in the URL the whitespace compression in CSS aggregation no longer works.
Steps to reproduce
Include the following line at the top of a CSS file:
@import url(http://example.com/a\'\".css);
This is legal CSS, unquoted URLs are allowed as long as special characters are escaped, ref. https://developer.mozilla.org/en-US/docs/Web/CSS/url()#values
If you choose to write the URL without quotes, use a backslash () before any parentheses, whitespace characters, single quotes (') and double quotes (") that are part of the URL.
Proposed resolution
Adapt the regular expressions in CssOptimizer::processCss() to recognize this pattern.
Comments