mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-07-17 17:23:24 +02:00
feat(snacks): use snacks notifier instead of nvim-notify
This commit is contained in:
parent
b006ac7afb
commit
b6ddeb2341
2 changed files with 22 additions and 45 deletions
|
@ -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.
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue