diff options
Diffstat (limited to 'screen')
-rw-r--r-- | screen/home.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/screen/home.ts b/screen/home.ts index 296fec2..097e0f7 100644 --- a/screen/home.ts +++ b/screen/home.ts @@ -23,7 +23,8 @@ export default { const termWidth = process.stdout.columns; let splitText = this.text.split("\n"); - splitText = splitText.map(t => t.replace(new RegExp(`([^]){${termWidth}}`, "g"),"$1\n")); + splitText = splitText.map(t => t.replace(new RegExp(`([^]{${termWidth}})`, "g"),"$1\n")); + this.screen.logs.push(JSON.stringify(splitText)) splitText = splitText.join("\n").split("\n") splitText = splitText.slice(-(termHeight - inputValueHeight)); |