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

    Function generatePalette

    • Generates a color palette based on the specified base color and options.

      Parameters

      • color: string | Color

        The input color to generate the palette from. Can be a Color object or a valid color string.

      • OptionaladjustContrast: boolean = true

        Indicates whether to adjust contrast for the generated palette to improve accessibility.

      • OptionalensureColorInAdjustment: boolean = true

        Determines whether to ensure the base color is passed unmodified during the contrast adjustment process.

      • Optionalfamily: "Tailwind v4" = 'Tailwind v4'

        The generator family to use for creating the palette. Defaults to 'Tailwind v4'.

      Returns ColorPalette

      • The generated color palette as a ColorPalette object.
      • Throws an error if the specified family is not recognized.