in src/ProgressBar.js [5:19]
function getColor(amount) {
const medColor = 'yellow'
if (amount === undefined) {
return 'white'
}
if (amount < 0.5) {
return tinycolor
.mix(tinycolor('lightsalmon'), tinycolor(medColor), amount * 100)
.toHexString()
}
return tinycolor
.mix(tinycolor(medColor), tinycolor('lime'), (amount - 0.5) * 100)
.toHexString()
}