MCPcopy Create free account
hub / github.com/chartjs/Chart.js / transparentize

Function transparentize

docs/scripts/utils.js:122–125  ·  view source on GitHub ↗
(value, opacity)

Source from the content-addressed store, hash-verified

120}
121
122export function transparentize(value, opacity) {
123 var alpha = opacity === undefined ? 0.5 : 1 - opacity;
124 return colorLib(value).alpha(alpha).rgbString();
125}
126
127export const CHART_COLORS = {
128 red: 'rgb(255, 99, 132)',

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected