-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Add customisation options to prevent inline completer resizing aggressively #16507
Add customisation options to prevent inline completer resizing aggressively #16507
Conversation
This fixes the issue caused by the increased number of lines in the placeholder due to the use of `max-width: 0`; the `max-width: 0` was used to prevent the placeholder from expanding in width (due to the necessity of using `display: inline-block` to animate font size reduction effectively; instead the lines placeholder is now rendered with a single character in each line which preserves the functionality but frees use from both issues.
to prevent randomly selecting the ghost text/line spacer in another cell. Also fixes waitForTimeout being called out of sequence.
timeout customization, and min height across suggestions
Thanks for making a pull request to jupyterlab! |
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.
Thanks @krassowski
@meeseeksdev please backport to 4.2.x |
Owee, I'm MrMeeseeks, Look at me. There seem to be a conflict, please backport manually. Here are approximate instructions:
And apply the correct labels and milestones. Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon! Remember to remove the If these instructions are inaccurate, feel free to suggest an improvement. |
…line completer resizing aggressively
…line completer resizing aggressively
…eter resizing aggressively (#16552)
…sively (jupyterlab#16507) * Add a test for ghost text spacer * Fix the lines placeholder taking up too much space This fixes the issue caused by the increased number of lines in the placeholder due to the use of `max-width: 0`; the `max-width: 0` was used to prevent the placeholder from expanding in width (due to the necessity of using `display: inline-block` to animate font size reduction effectively; instead the lines placeholder is now rendered with a single character in each line which preserves the functionality but frees use from both issues. * Update snapshots * Improve tests: make the ghost locator editor-specific to prevent randomly selecting the ghost text/line spacer in another cell. Also fixes waitForTimeout being called out of sequence. * Use `text-wrap: none` to prevent height inflation in spacer * Implement minimum and maximum size for inline completer, timeout customization, and min height across suggestions * Simplify the tests
References
Code changes
Adds new completion inline settings :
minLines
maxLines
reserveSpaceForLongest
spacerRemovalDelay
User-facing changes
None by default, but:
maxLines
adds a collapser for preview of remaining linesminLines
adds additional empty linesreserveSpaceForLongest
: adds additional empty lines to match the space of the longest completionBackwards-incompatible changes
None