const chroma = require("chroma-js"); const colors = { BASE_COLOR: chroma([186, 81, 0]), WARNING_COLOR: chroma([150, 30, 30]), ALERT_COLOR: chroma([250, 10, 10]), SAFE_COLOR: chroma([10, 220, 30]), BLUE: chroma([10, 20, 200]), }; function brightness(color, pct) { return chroma(color).set("hsv.v", pct / 100); } module.exports = { colors, brightness, };