Skip to content

Commit

Permalink
fix(colorschemes): only display highlight group on enter
Browse files Browse the repository at this point in the history
  • Loading branch information
barrett-ruth authored and ibhagwan committed Nov 27, 2024
1 parent e310190 commit 4678ab0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lua/fzf-lua/providers/colorschemes.lua
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,10 @@ M.highlights = function(opts)
end

opts.fn_selected = function(selected)
vim.cmd('hi ' .. selected[2])
vim.api.nvim_exec2('hi ' .. selected[2], {})
if selected[1] == 'enter' then
vim.cmd('hi ' .. selected[2])
vim.api.nvim_exec2('hi ' .. selected[2], {})
end
end

core.fzf_exec(contents, opts)
Expand Down

0 comments on commit 4678ab0

Please sign in to comment.