fix(input): make sure to show input window with a higher zindex of the parent window (if float)

This commit is contained in:
Folke Lemaitre 2024-12-16 17:49:21 +01:00
parent ff803a60b3
commit 3123e6e988
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040

View file

@ -167,6 +167,9 @@ function M.input(opts, on_confirm)
},
})
local parent_zindex = vim.api.nvim_win_get_config(parent_win).zindex
opts.win.zindex = parent_zindex and parent_zindex + 1 or opts.win.zindex
local min_width = opts.win.width or 60
if opts.expand then
---@param self snacks.win