(str, prefix, colorFn)
| 73 | * @returns {string} indented string |
| 74 | */ |
| 75 | const indent = (str, prefix, colorFn) => { |
| 76 | if (str === "") return str; |
| 77 | prefix = currentIndent + prefix; |
| 78 | return ( |
| 79 | prefix + |
| 80 | str |
| 81 | .split("\n") |
| 82 | .map((line) => colorFn(line)) |
| 83 | .join(`\n${prefix}`) |
| 84 | ); |
| 85 | }; |
| 86 | |
| 87 | const clearStatusMessage = () => { |
| 88 | let lines = 0; |