pintor
Version:
Zero-dependency library for providing color functions for terminal text
18 lines (17 loc) • 580 B
TypeScript
import ansiStyles from './ansi-styles';
import { shouldEnableColors } from './color-support';
import type { AnsiStyle } from './ansi-styles';
interface ColorFunction {
(...args: Array<string | number | boolean>): string;
[key: string]: ColorFunction;
}
type ColorsObject = {
styles: Record<string, AnsiStyle>;
} & {
[K in keyof typeof ansiStyles]: ColorFunction;
};
declare const colors: ColorsObject;
export declare const supportsColor: typeof shouldEnableColors;
export declare const stdout: boolean;
export declare const stderr: boolean;
export default colors;