fzf-lua winopts tweaks

This commit is contained in:
2024-12-28 18:48:37 -05:00
parent d669855aa7
commit 4f1bcddcd9
+12
View File
@@ -199,6 +199,18 @@ local P = { -- Define Telescope Plugins Specs
glob_separator = '%s%-%-', -- query separator pattern (lua): ' --'
},
},
init = function()
require('fzf-lua').register_ui_select(function(_, items)
local min_h, max_h = 0.15, 0.70
local h = (#items + 4) / vim.o.lines
if h < min_h then
h = min_h
elseif h > max_h then
h = max_h
end
return { winopts = { height = h, width = 0.60, row = 0.40 } }
end)
end,
},
{
'danielfalk/smart-open.nvim',