Skip to content

Commit

Permalink
fix(nui): nui broke noice. added a temporary work-around till the pro…
Browse files Browse the repository at this point in the history
…blem is solved
  • Loading branch information
folke committed Jun 10, 2023
1 parent 36b1935 commit 4db3c8f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lua/noice/view/nui.lua
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,12 @@ function NuiView:create()
end

function NuiView:mount()
-- HACK: nui no longer re-creates the border buffer on mount,
-- which breaks in a lot of different ways, so we do it ourselves
if not (self._nui.border.bufnr and vim.api.nvim_buf_is_valid(self._nui.border.bufnr)) then
self._nui.border.bufnr = vim.api.nvim_create_buf(false, true)
end

self._nui:mount()
if self._opts.close and self._opts.close.events then
self._nui:on(self._opts.close.events, function()
Expand Down

0 comments on commit 4db3c8f

Please sign in to comment.