Improve rendering of jsterm autocomplete when typing the same characters as the selected value
Categories
(DevTools :: Console, defect, P1)
Tracking
(firefox-esr60 unaffected, firefox-esr68 wontfix, firefox68 wontfix, firefox69 fixed)
Tracking | Status | |
---|---|---|
firefox-esr60 | --- | unaffected |
firefox-esr68 | --- | wontfix |
firefox68 | --- | wontfix |
firefox69 | --- | fixed |
People
(Reporter: fvsch, Assigned: nchevobbe)
References
(Regression)
Details
(Keywords: regression, Whiteboard: [console-editor-mvp])
Attachments
(1 file)
I find the Console autocomplete a bit glitchy in a specific scenario, I wonder if that's always been the case or if it's a regression.
STR:
- Open Console and in a blank jsterm, type
wi
- The input line should be autocomplete to
window
, with the lettersndow
in gray. Now type the remaining letters slowly, staring at the gray autocomplete.
Expected result:
Each typed letter should go from gray to colorful (purple), with no visual glitch.
Actual result:
The autocompleted text disappears on each input, looking like this (each line represents a moment in time):
wi
window
win
window
wind
window
windo
window
This back-and-forth is not ideal and makes the autocomplete feel unreliable and/or slow, in my experience.
If we need to redo some work on each keystroke and the results take a little while to come back, maybe we could bypass this work if the typed letter(s) match the currently displayed completion?
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 1•6 years ago
|
||
This is probably caused by Bug 1491776 + Bug 1541352:
- we always clear the completion text
- and we now wait 75ms to reach the autocomplete function, which will update the completion text
Updated•6 years ago
|
Updated•6 years ago
|
Assignee | ||
Comment 2•6 years ago
|
||
We were clearing the completion text all the time to prevent
a visual glitch while typing (See Bug 1491776). But since we
are now waiting for 75ms before calling the autocomplete
function (which triggers the autocompletion text update), we
have a flash of the completion text, which isn't ideal.
In this patch, we check if the typed letters match the begining
of the completion text, and if they do, we don't clear the
completion text.
In the same time, we set the completion text in absolute position
so it doesn't jump when the new letter is added in the CodeMirror
document.
Finally, we change how the Editor pipe events from CodeMirror to
include parameters, so we can use them in JsTerm.
Comment 5•6 years ago
|
||
bugherder |
Updated•6 years ago
|
Updated•3 years ago
|
Description
•