diff --git a/cssmin.js b/cssmin.js index 9838dee..d4e6d4a 100755 --- a/cssmin.js +++ b/cssmin.js @@ -142,7 +142,8 @@ function cssmin(css, linebreakpos) { // Put the space back in some cases, to support stuff like // @media screen and (-webkit-min-device-pixel-ratio:0){ - css = css.replace(/\band\(/gi, "and ("); + // or @supports not (display: flex) + css = css.replace(/([^\B:])(and|not)\(/gi, "$1$2 ("); // Remove the spaces after the things that should not have spaces after them.