You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This has been reported in the forum and I am seeing the same behavior.
It seems that for any rgba CSS value e.g. rgba(000, 000, 000, 0.7); and also if a color value is set to transparent the minifier outputs invalid hexadecimal numbers that fail W3C validation.
I have tested minifying the same CSS file with online version of the minifier and I can confirm that the KeepCSS2 flag fixes the invalid HEX color codes.
Also please note that this is a flag for the CSS minifier and it cannot be added to the existing list with the HTML minifier flags. This flag needs a new list for the CSS minifier.
The text was updated successfully, but these errors were encountered:
The flag KeepCSS2 does not convert rgba values to invalid HEX. It keeps them as is. I tested with the online converter I posted about above and noticed that it is in the Minifier's Docs.
I am not going to re-open that issue.
If you feel that the default behavior of the CSS minifier should change feel free to open an issue upstream yourself.
Already spent more time on this than I should.
Also if you feel that this flag should not be added to Hugo feel free to close this issue.
This has been reported in the forum and I am seeing the same behavior.
It seems that for any
rgba
CSS value e.g.rgba(000, 000, 000, 0.7);
and also if a color value is set totransparent
the minifier outputs invalid hexadecimal numbers that fail W3C validation.Originally due to lack of time I opened tdewolff/minify#237
However there is already the
KeepCSS2
flag that addresses this problem as stated in the minifier's documentation over here: https://github.com/tdewolff/minify#cssI have tested minifying the same CSS file with online version of the minifier and I can confirm that the
KeepCSS2
flag fixes the invalid HEX color codes.Also please note that this is a flag for the CSS minifier and it cannot be added to the existing list with the HTML minifier flags. This flag needs a new list for the CSS minifier.
The text was updated successfully, but these errors were encountered: