(
m: string | { m: string; width: number } = "",
second = "",
examples: string[] = [],
)
| 12 | export const heading = (m = "") => p(white(bold(m))) |
| 13 | |
| 14 | export const command = ( |
| 15 | m: string | { m: string; width: number } = "", |
| 16 | second = "", |
| 17 | examples: string[] = [], |
| 18 | ) => { |
| 19 | m = typeof m === "string" ? m : m.m + " ".repeat(m.width - m.m.length) |
| 20 | p(white(m) + " " + gray(second)) |
| 21 | const indent = m.length + 2 |
| 22 | if (examples) { |
| 23 | examples.forEach((ex) => p(gray(" ".repeat(indent) + white(ex)))) |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | export const direction = (m = "") => p(red(m)) |
| 28 |
no test coverage detected