feat: built-in select has winblend option
This commit is contained in:
parent
106dfb93a3
commit
f57f0f3587
|
@ -54,6 +54,9 @@ local default_config = {
|
|||
col = 0,
|
||||
border = "rounded",
|
||||
|
||||
-- Window options
|
||||
winblend = 10,
|
||||
|
||||
-- These can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
|
||||
width = nil,
|
||||
max_width = 0.8,
|
||||
|
|
|
@ -42,6 +42,7 @@ M.select = function(config, items, opts, on_choice)
|
|||
style = "minimal",
|
||||
}
|
||||
local winnr = vim.api.nvim_open_win(bufnr, true, winopt)
|
||||
vim.api.nvim_win_set_option(winnr, "winblend", config.winblend)
|
||||
vim.api.nvim_win_set_option(winnr, "cursorline", true)
|
||||
if vim.fn.exists("&cursorlineopt") ~= 0 then
|
||||
vim.api.nvim_win_set_option(winnr, "cursorlineopt", "both")
|
||||
|
|
Loading…
Reference in New Issue