-
Notifications
You must be signed in to change notification settings - Fork 881
fix(site): fix terminal size when displaying alerts #12444
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
Conversation
A comment about testing, since we have the story now, maybe we can just output more than a screen's worth of text, since with the bug it would render differently than without it, so it should catch this issue. |
Or we output some ANSI sequence that writes text to the bottom of the screen. If it displays, we know it is fixed, if not then there is a bug. Or output the terminal size or something. |
@BrunoQuaresma for testing, maybe you can write an escape sequence to the terminal that will write something at the bottom? Edit: Actually, this is probably what Asher was suggesting 😄. For example, the following escape sequence would write to the bottom left and right corners of the terminal: ![]() Then you can test if the output is visible? |
…minal-alert-size
@mafredri @code-asher good suggestion, I didn't know there was a way to do that. I was just copying and pasting the websocket messages from the terminal. @mafredri how do you know how to do that? I would add it to my LinkedIn like "Languages: English, ANSI" |
@code-asher @mafredri just confirming your suggestion worked! 🙏 |
Haha, I will consider it 😉. TBH it was trial and error, I remembered that it was ~ This looks like a pretty solid intro if you're interested: https://gist.github.com/fnky/458719343aabd01cfb17a3a4f7296797#cursor-controls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect!
Merge activity
|
Before - The terminal size does not fit the available space so the bottom is hidden.
Screen.Recording.2024-03-06.at.15.44.50.mov
After - The terminal adjusts when there are alert changes.
working.mov
Unfortunately, I don't think there is a sane way to automate tests for this but open to suggestions.
Close #7914