Functions to mix color.
Use the Elm Core Color type to create your colors and this library to mix them.
This library is modeled off of the LESSCSS color functions. See their documentation for general descriptions of each color operation.
While elm-css do not use Color
internally (see issue 76).
You can use Color.Mixing
with a small helper, like:
import Color.Mixing exposing (..)
import Color exposing (Color)
import Css
cssColor : Color -> Css.Color
cssColor color =
let
{ red, green, blue, alpha } =
Color.toRgb color
in
Css.rgba red green blue alpha