Skip to main content

Module: style

References

strConcat

Re-exports strConcat


indent

Re-exports indent

Type Aliases

StringStyle

Ƭ StringStyle: Object

Type declaration

NameType
bold?boolean
underline?boolean
color?"red" | "green" | "yellow" | "blue" | "magenta" | "cyan" | "white" | "gray" | "grey" | "brightRed" | "brightGreen" | "brightYellow" | "brightBlue" | "brightMagenta" | "brightCyan" | "brightWhite"
reset?boolean

Defined in

src/style.ts:31

src/style.ts:38

Variables

ansiStyles

Const ansiStyles: Object

Type declaration

NameType
resetstring
boldstring
underlinestring
blackstring

Defined in

src/style.ts:5


ansiColors

Const ansiColors: Object

Type declaration

NameType
redstring
greenstring
yellowstring
bluestring
magentastring
cyanstring
whitestring
graystring
greystring
brightRedstring
brightGreenstring
brightYellowstring
brightBluestring
brightMagentastring
brightCyanstring
brightWhitestring

Defined in

src/style.ts:12


StringStyle

Const StringStyle: ZodObject<StringStyle>

Defined in

src/style.ts:31

src/style.ts:38

Functions

format

format(string, style?): string

Parameters

NameType
stringstring
styleObject
style.bold?boolean
style.underline?boolean
style.color?"red" | "green" | "yellow" | "blue" | "magenta" | "cyan" | "white" | "gray" | "grey" | "brightRed" | "brightGreen" | "brightYellow" | "brightBlue" | "brightMagenta" | "brightCyan" | "brightWhite"
style.reset?boolean

Returns

string

Defined in

src/style.ts:40


stripStyle

stripStyle(string): string

Parameters

NameType
stringstring

Returns

string

Defined in

src/style.ts:49