Skip to content

Commit

Permalink
fix: set noice_popupmenu as only source when in ext_popupmenu
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Oct 4, 2022
1 parent 44bdede commit e362b85
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions lua/noice/ui/popupmenu/cmp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,12 @@ function M.setup()
end

function M.on_show()
if not cmp.core.view:visible() then
cmp.complete()
end
local config = vim.deepcopy(cmp.get_config())
config.sources = cmp.config.sources({ { name = "noice_popupmenu" } })
cmp.core:prepare()
cmp.complete({
config = config,
})
end

function M.on_select()
Expand Down

0 comments on commit e362b85

Please sign in to comment.