@dragonspark/chroma-kit
    Preparing search index...

    Function lab

    • Creates a new Lab color object with the specified components.

      This is the primary factory function for creating Lab colors in the library. The created object includes methods for conversion to other color spaces and string representations.

      Parameters

      • l: number

        The lightness component (0-1, will be scaled to 0-100 in CSS output)

      • a: number

        The green-red component (negative values are green, positive values are red)

      • b: number

        The blue-yellow component (negative values are blue, positive values are yellow)

      • Optionalalpha: number

        The alpha (opacity) component (0-1), optional

      • Optionalilluminant: Illuminant

        The reference white point to use, defaults to D65

      Returns LabColor

      A new Lab color object