Skip to content

Commit

Permalink
fix: disable ghost text in command mode
Browse files Browse the repository at this point in the history
Closes #524
  • Loading branch information
Saghen committed Dec 13, 2024
1 parent e3b3fde commit ad17735
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/blink/cmp/completion/windows/ghost_text.lua
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ function ghost_text.show_preview(selected_item)
return
end

-- doesn't work in command mode
-- TODO: integrate with noice.nvim?
if vim.api.nvim_get_mode().mode ~= 'c' then return end

-- update state and redraw
local changed = ghost_text.selected_item ~= selected_item
ghost_text.selected_item = selected_item
Expand Down

0 comments on commit ad17735

Please sign in to comment.