stringman
Version:
Stringman does string manipulation and other string operations. Do anything from lightening color codes to swapping email address in a string!
17 lines (16 loc) • 676 B
TypeScript
import { IHsl } from '../models/colors.model';
declare function rgbToHex(r: number | string, g: number | string, b: number | string): string;
declare function isHex(color: string): boolean;
declare function hexToRgb(hex: string): number[] | null;
declare function luminance(color: string, percent: number): string | null;
declare function hexToHsl(str: string): IHsl | null;
declare function rgbToHsl(r: number, g: number, b: number): IHsl | null;
declare const colors: {
hexToHsl: typeof hexToHsl;
hexToRgb: typeof hexToRgb;
isHex: typeof isHex;
luminance: typeof luminance;
rgbToHex: typeof rgbToHex;
rgbToHsl: typeof rgbToHsl;
};
export { colors };