Closed adriankarlen closed 3 weeks ago
mini.files
When using MiniFilesWindowUpdate-event to update window height via config, the cursor placement hops back when inserting first letter if the window height is configured to be larger than the file list. I've recorded the issue.
MiniFilesWindowUpdate
https://github.com/user-attachments/assets/e137829f-60a6-4f6a-9b9c-fde6232e5662
The issue does not appear when the filelist is larger than the configured height.
I've tested it with only this event in my config.
0.10.1
vim.api.nvim_create_autocmd("User", { pattern = "MiniFilesWindowUpdate", callback = function(args) local config = vim.api.nvim_win_get_config(args.data.win_id) config.height = 15 vim.api.nvim_win_set_config(args.data.win_id, config) end, })
If I type hello.lua, it should become the file name.
hello.lua
The file name becomes ello.luah
ello.luah
Thanks for the issue!
I can reproduce. Will look into it.
This should now be fixed on latest main.
main
Contributing guidelines
Module(s)
mini.files
Description
When using
MiniFilesWindowUpdate
-event to update window height via config, the cursor placement hops back when inserting first letter if the window height is configured to be larger than the file list. I've recorded the issue.https://github.com/user-attachments/assets/e137829f-60a6-4f6a-9b9c-fde6232e5662
The issue does not appear when the filelist is larger than the configured height.
I've tested it with only this event in my config.
Neovim version
0.10.1
Steps to reproduce
Expected behavior
If I type
hello.lua
, it should become the file name.Actual behavior
The file name becomes
ello.luah