function createColor(color, alpha) {
    return alpha >= 1
        ? color
        : Color(color)
              .alpha(alpha)
              .hsl()
              .string();
}
function createColor(color, alpha) {
    return alpha >= 1
        ? color
        : Color(color)
              .alpha(alpha)
              .hsl()
              .string();
}
function createColor ( color , alpha ) { return alpha >= 1 ? color : Color ( color ) . alpha ( alpha ) . hsl ( ) . string ( ) ; }
Creates a HEX or HSLA() color based on the given alpha.

@param {string} color
@param {number} alpha

@return {string}
Creates a HEX or HSLA () color based on the given alpha .