-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Terminal.write() & console ANSI escape sequences #135
Comments
I think it's because MultiBar, which has its own Lines 67 to 70 in f4dc172
but when it spawns new GenericBars: Lines 42 to 43 in f4dc172
those each get their own cli-progress/lib/generic-bar.js Line 16 in f4dc172
|
the hard-trimming within regarding the terminal instances: you're right, that looks weak .. i'm not shure why i've didn't passed the "global" instance to the generic bars. i've to take a look into |
You're right, I think my original post is incorrect here. I think it's because the |
i've applied the fix which uses the same terminal instance for all bars |
Confirmed that this fixed my issue! Sorry for the slow feedback. |
I have a custom format function that makes heavy use of
chalk
coloring:https://github.com/emmercm/igir/blob/1ba176d54877dc01aafe13df2abe57ddd6fb2926/src/console/singleBarFormatted.ts#L30
(see the Asciicast in the project's readme for a video of how it renders)
The default formatter takes into account ANSI escape sequences by using
string-width
to calculate the true width of a string, but this is only for alignment.Terminal.write()
doesn't usestring-width
and instead trims all lines toprocess.stdout.columns
.The text was updated successfully, but these errors were encountered: