alpha method

Dimension alpha(
  1. Node color
)

Extracts the alpha channel of a color object.

Parameters: color - a color object. Returns: float 0-1 Example: alpha(rgba(10, 20, 30, 0.5)) Output: 0.5

Implementation

Dimension alpha(Node color) => Dimension(toHSL(color).a);