MoOx / postcss-cssnext

`postcss-cssnext` has been deprecated in favor of `postcss-preset-env`.
https://moox.io/blog/deprecating-cssnext/
MIT License
5.3k stars 189 forks source link

Using variable in rgba is not interpolated correctly #440

Closed pherrymason closed 6 years ago

pherrymason commented 6 years ago

Having a hexadecimal color defined in a variable:

:root {
   --color: #001f3f;
}

and using it with rgba does not give me the expected result:

.style {
    background: rgba(var(--color), .5);
}

The output I get is:

.style {
     background: rgba(#001f3f, .5);
}
nolimit-developers commented 6 years ago

@raulferras solution is combine with https://github.com/postcss/postcss-color-function

pherrymason commented 6 years ago

Will try, thanks!