diff --git a/palette-generator/Stylix/Palette.hs b/palette-generator/Stylix/Palette.hs index 6f06fea..2f1c3ad 100644 --- a/palette-generator/Stylix/Palette.hs +++ b/palette-generator/Stylix/Palette.hs @@ -12,7 +12,7 @@ import System.Random ( randomRIO ) -- Adjust value according to coefficients adjustValue :: Double -> Double-> Double -> Double -> Double -adjustValue v a b x = v*(a*x+b) +adjustValue v a b x = minimum [maximum [0.0, v*(a*x+b)], 100.0] -- | Extract the primary scale from a pallete. primary :: V.Vector a -> V.Vector a