Ivy: do *not* fix :preselect getting deselected with new input #1563
Comments
The recent commit fixed a clearly not intended behavior of the index remaining at 1 (zero-based) while sliding to non-:preselect on input. Your intended behavior should be there, related to |
Yes, I noticed that the faulty behavior is a bit hard to reproduce (though it is consistent with a given test case). Example test case, click to expandFor example, with some nonstandard settings enabled, I ran I would now expect that if I type a character, my selection moves back to the beginning of the list. That doesn't happen: But if I type a second character, it does: And most puzzling of all, if I delete the second character, then my selection is back at the beginning as it should have been in the first place: If I delete the first character, then I'm back at the preselected candidate, and can repeat the process as desired:
If you don't see the behavior in your own configuration, then I can see about getting a test case that starts from |
@abo-abo Actually, this is very easy to reproduce. Simply activate to: whereas I would like it to return me to the beginning of the menu, like this: |
@abo-abo The code which causes this behavior is: Lines 3066 to 3072 in be6db35 The code allows for the index to be maintained if the previously selected candidate is still available in the list. That would make sense for a manually selected candidate, but perhaps a case needs to be added there so that the logic is not triggered in the case of a preselected candidate. |
Created #1573. |
I noticed the recent commit 4fef67f. Actually, I would like the contrary behavior: when any key is typed, the selection should be moved to the first candidate, disregarding the preselected candidate (if any). Is there a way I can achieve this behavior?
The text was updated successfully, but these errors were encountered: