feat(snacks): use snacks notifier instead of nvim-notify

This commit is contained in:
Folke Lemaitre 2024-11-05 16:55:30 +01:00
parent b006ac7afb
commit b6ddeb2341
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040
2 changed files with 22 additions and 45 deletions

View file

@ -1,39 +1,4 @@
return {
-- Better `vim.notify()`
{
"rcarriga/nvim-notify",
keys = {
{
"<leader>un",
function()
require("notify").dismiss({ silent = true, pending = true })
end,
desc = "Dismiss All Notifications",
},
},
opts = {
stages = "static",
timeout = 3000,
max_height = function()
return math.floor(vim.o.lines * 0.75)
end,
max_width = function()
return math.floor(vim.o.columns * 0.75)
end,
on_open = function(win)
vim.api.nvim_win_set_config(win, { zindex = 100 })
end,
},
init = function()
-- when noice is not enabled, install notify on VeryLazy
if not LazyVim.has("noice.nvim") then
LazyVim.on_very_lazy(function()
vim.notify = require("notify")
end)
end
end,
},
-- This is what powers LazyVim's fancy-looking
-- tabs, which include filetype icons and close buttons.
{