
Product
Introducing Repository Access Permissions and Custom Roles
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.
@csstools/postcss-color-mix-variadic-function-arguments
Advanced tools
Mix any number of colors with the color-mix function in CSS
npm install @csstools/postcss-color-mix-variadic-function-arguments --save-dev
PostCSS Color Mix Variadic Function Arguments lets you use the color-mix() function with any number of arguments following the CSS Color 5 Specification.
.red {
color: color-mix(in srgb, red);
}
.grey {
color: color-mix(in srgb, red, lime, blue);
}
/* becomes */
.red {
color: rgb(255, 0, 0);
}
.grey {
color: rgb(85, 85, 85);
}
[!NOTE] We can not dynamically resolve
var()arguments incolor-mix(), only static values will work.
Add PostCSS Color Mix Variadic Function Arguments to your project:
npm install postcss @csstools/postcss-color-mix-variadic-function-arguments --save-dev
Use it as a PostCSS plugin:
const postcss = require('postcss');
const postcssColorMixVariadicFunctionArguments = require('@csstools/postcss-color-mix-variadic-function-arguments');
postcss([
postcssColorMixVariadicFunctionArguments(/* pluginOptions */)
]).process(YOUR_CSS /*, processOptions */);
The preserve option determines whether the original notation
is preserved. By default, it is not preserved.
postcssColorMixVariadicFunctionArguments({ preserve: true })
.red {
color: color-mix(in srgb, red);
}
.grey {
color: color-mix(in srgb, red, lime, blue);
}
/* becomes */
.red {
color: rgb(255, 0, 0);
color: color-mix(in srgb, red);
}
.grey {
color: rgb(85, 85, 85);
color: color-mix(in srgb, red, lime, blue);
}
FAQs
Mix any number of colors with the color-mix function in CSS
We found that @csstools/postcss-color-mix-variadic-function-arguments demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.

Product
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.

Product
Socket Firewall blocks malicious VS Code and Open VSX extensions before install, protecting developers from compromised editor marketplaces.