UNPKG

@thi.ng/color

Version:

Array-based color types, CSS parsing, conversions, transformations, declarative theme generation, gradients, presets

37 lines 988 B
import type { Color, TypedColor } from "./api.js"; /** * Color rotation. Rotates hue by given `theta` and writes result color into * `out`. * * @remarks * If `out` is null, the resulting will be written back into `src`. * * As with all hue-based color modes in this package, the hue is stored * normalized (in `[0,1]` interval) and NOT as degrees. The same goes for the * rotation angle `theta`. * * Only supported for hue based color modes: * * - hcy * - hsi * - hsl * - hsv * - lch * - oklch * * @param out * @param src * @param theta */ export declare const rotate: import("@thi.ng/defmulti").MultiFn3<Color | null, TypedColor<any>, number, Color>; /** * Syntax sugar for {@link rotate} with 180 degree rotation. * * @remarks * If `out` is null, the resulting color will be written back into `src`. * * @param out * @param src */ export declare const complementary: (out: Color | null, src: TypedColor<any>) => Color; //# sourceMappingURL=rotate.d.ts.map