php-autoprefixer icon indicating copy to clipboard operation
php-autoprefixer copied to clipboard

deleted colors

Open kubiqsk opened this issue 3 years ago • 7 comments

when there are expressions like background-color: rgba(var(--bs-primary-rgb), var(--bs-bg-opacity)) !important; or color: rgba(var(--bs-body-color-rgb), var(--bs-text-opacity)) !important; then it will complete delete them

kubiqsk avatar Jan 12 '22 14:01 kubiqsk

Okay, just had a look at this one. This is not an issue with this repo but an issue with the sabberworm repo that this repo uses.

there is a fix that will be in the latest release (not released yet): https://github.com/sabberworm/PHP-CSS-Parser/issues/257

Ruud68 avatar Jan 13 '22 08:01 Ruud68

I did output also compiled CSS before autoprefixing and it contains all needed expressions https://scss.kubiq.sk/style-unprefixed.css so i'm pretty sure, it's actually issue in here

kubiqsk avatar Jan 13 '22 10:01 kubiqsk

after that i just take this and

$autoprefixer = new Autoprefixer( $unprefixed_css );
$prefixed_css = $autoprefixer->compile();
file_put_contents( 'style.css', $prefixed_css );

and after that, there are no more these values https://scss.kubiq.sk/style.css

kubiqsk avatar Jan 13 '22 10:01 kubiqsk

he mean "PHP-CSS-Parser" repo, and not SCSS repo. @kubiqsk

padaliyajay avatar Jan 13 '22 10:01 padaliyajay

you're right! Sorry But it's more than 6 months old and they say it's solved in 8.3.1 (which is not officially released?)

kubiqsk avatar Jan 13 '22 10:01 kubiqsk

so yes, when I download ZIP of https://github.com/sabberworm/PHP-CSS-Parser and replace it in /vendor/sabberworm/php-css-parser/lib/Sabberworm/CSS/ then everything works

kubiqsk avatar Jan 13 '22 10:01 kubiqsk

I thing that the sabberworm repo is not yet made available (version 8.4), not sure what the status / delay is. While testing this I found also other issue reported here: https://github.com/sabberworm/PHP-CSS-Parser/issues/357 for BS5 css that is no issue, but when you apply codestyle and break long lines onto multiple lines then you might have an issue.

Ruud68 avatar Jan 13 '22 11:01 Ruud68