fix(hover): Add more autocmd to unhover and unload state after hover

This commit is contained in:
simrat39
2021-04-22 17:58:23 -07:00
parent e074433710
commit 78109f5741

View File

@@ -48,12 +48,15 @@ function M.show_hover()
}
})
util.close_preview_autocmd({
"CursorMoved", "BufHidden", "InsertCharPre"
"CursorMoved", "BufHidden", "InsertCharPre", "BufWipeout", "BufDelete", "WinClosed"
}, winnr)
return bufnr, winnr
end)
end)
-- kind of a hack but we want the state to always be the latest, so unload
-- this module for the next time it is called its gonna be F R E S H
package.loaded["symbols-outline.hover"] = nil
end
return M