Module: style
References
strConcat
Re-exports strConcat
indent
Re-exports indent
Type Aliases
AnsiColor
Ƭ AnsiColor: keyof typeof ansiColors
Defined in
StringStyle
Ƭ StringStyle: z.infer<typeof StringStyle>
Defined in
Variables
ansiStyles
• Const ansiStyles: Object
Type declaration
| Name | Type |
|---|---|
reset | string |
bold | string |
underline | string |
black | string |
Defined in
ansiColors
• Const ansiColors: Object
Type declaration
| Name | Type |
|---|---|
red | "\u001b[31m" |
green | "\u001b[32m" |
yellow | "\u001b[33m" |
blue | "\u001b[34m" |
magenta | "\u001b[35m" |
cyan | "\u001b[36m" |
white | "\u001b[37m" |
gray | "\u001b[90m" |
grey | "\u001b[90m" |
brightRed | "\u001b[91m" |
brightGreen | "\u001b[92m" |
brightYellow | "\u001b[93m" |
brightBlue | "\u001b[94m" |
brightMagenta | "\u001b[95m" |
brightCyan | "\u001b[96m" |
brightWhite | "\u001b[97m" |
Defined in
StringStyle
• Const StringStyle: ZodObject<{ bold: ZodOptional<ZodBoolean> ; underline: ZodOptional<ZodBoolean> ; color: ZodOptional<ZodEnum<{ red: "red" ; green: "green" ; yellow: "yellow" ; blue: "blue" ; magenta: "magenta" ; cyan: "cyan" ; white: "white" ; gray: "gray" ; grey: "grey" ; brightRed: "brightRed" ; brightGreen: "brightGreen" ; brightYellow: "brightYellow" ; brightBlue: "brightBlue" ; brightMagenta: "brightMagenta" ; brightCyan: "brightCyan" ; brightWhite: "brightWhite" }>> ; reset: ZodOptional<ZodDefault<ZodBoolean>> }, $strip>
Defined in
Functions
format
▸ format(string, style?): string
Parameters
| Name | Type |
|---|---|
string | string |
style | Object |
style.bold? | boolean |
style.underline? | boolean |
style.color? | $InferEnumOutput<{ red: "red" ; green: "green" ; yellow: "yellow" ; blue: "blue" ; magenta: "magenta" ; cyan: "cyan" ; white: "white" ; gray: "gray" ; grey: "grey" ; brightRed: "brightRed" ; brightGreen: "brightGreen" ; brightYellow: "brightYellow" ; brightBlue: "brightBlue" ; brightMagenta: "brightMagenta" ; brightCyan: "brightCyan" ; brightWhite: "brightWhite" }> |
style.reset? | boolean |
Returns
string
Defined in
stripStyle
▸ stripStyle(string): string
Parameters
| Name | Type |
|---|---|
string | string |
Returns
string