Skip to content

Commit f0d3c20

Browse files
committed
Update : Customized Noice.nvim
1 parent e931a8c commit f0d3c20

3 files changed

Lines changed: 76 additions & 15 deletions

File tree

lazy-lock.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"neo-tree.nvim": { "branch": "main", "commit": "8cdd6b1940f333c1dd085526a9c45b30fb2dbf50" },
3535
"neovim": { "branch": "main", "commit": "72a04c4065345b51b56aed4859ea1d884f734097" },
3636
"nightfox.nvim": { "branch": "main", "commit": "ba47d4b4c5ec308718641ba7402c143836f35aa9" },
37-
"noice.nvim": { "branch": "main", "commit": "d14d02cb709e3bb2da88363c32f8b4250bced52d" },
37+
"noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" },
3838
"none-ls.nvim": { "branch": "main", "commit": "a96172f673f720cd4f3572e1fcd08400ed3eb25d" },
3939
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
4040
"nvim-autopairs": { "branch": "master", "commit": "7a2c97cccd60abc559344042fefb1d5a85b3e33b" },

lua/plugins/noise.lua

Lines changed: 75 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,76 @@
11
return {
2-
'folke/noice.nvim',
3-
event = 'VeryLazy',
4-
opts = {
5-
-- add any options here
6-
},
7-
dependencies = {
8-
-- if you lazy-load any plugin below, make sure to add proper `module="..."` entries
9-
'MunifTanjim/nui.nvim',
10-
-- OPTIONAL:
11-
-- `nvim-notify` is only needed, if you want to use the notification view.
12-
-- If not available, we use `mini` as the fallback
13-
'rcarriga/nvim-notify',
14-
},
15-
}
2+
"folke/noice.nvim",
3+
event = "VeryLazy",
4+
dependencies = {
5+
"MunifTanjim/nui.nvim",
6+
"rcarriga/nvim-notify",
7+
},
8+
config = function(_, opts)
9+
local notify = require("notify")
10+
notify.setup({
11+
stages = "fade_in_slide_out",
12+
timeout = 3000,
13+
render = "wrapped-compact",
14+
background_colour = "#000000",
15+
})
16+
17+
local purple = "#bd93f9"
18+
local pink = "#ff79c6"
19+
local green = "#50fa7b"
20+
local bg = "#1e1e2e"
21+
local hl = vim.api.nvim_set_hl
22+
23+
local function apply_ui_colors()
24+
hl(0, "NoiceCmdlinePopupBorder", { fg = pink })
25+
hl(0, "NoiceCmdlinePopupTitle", { fg = bg, bg = purple, bold = true })
26+
hl(0, "NoiceCmdlineIcon", { fg = pink })
27+
hl(0, "NoiceCmdlineIconLua", { fg = green })
28+
29+
hl(0, "NotifyINFOBorder", { fg = purple })
30+
hl(0, "NotifyINFOTitle", { fg = purple, bold = true })
31+
hl(0, "NotifyINFOIcon", { fg = purple })
32+
33+
hl(0, "NotifySUCCESSBorder", { fg = green })
34+
hl(0, "NotifySUCCESSTitle", { fg = green, bold = true })
35+
hl(0, "NotifySUCCESSIcon", { fg = green })
36+
37+
hl(0, "NotifyWARNBorder", { fg = pink })
38+
hl(0, "NotifyWARNTitle", { fg = pink, bold = true })
39+
hl(0, "NotifyWARNIcon", { fg = pink })
40+
41+
hl(0, "NotifyERRORBorder", { fg = "#ff5555" })
42+
hl(0, "NotifyERRORTitle", { fg = "#ff5555", bold = true })
43+
end
44+
45+
apply_ui_colors()
46+
47+
require("noice").setup(opts)
48+
49+
vim.defer_fn(apply_ui_colors, 100)
50+
end,
51+
opts = {
52+
lsp = {
53+
override = {
54+
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
55+
["vim.lsp.util.stylize_markdown"] = true,
56+
["cmp.entry.get_documentation"] = true,
57+
},
58+
},
59+
presets = {
60+
bottom_search = true,
61+
command_palette = true,
62+
long_message_to_split = true,
63+
lsp_doc_border = true,
64+
},
65+
views = {
66+
cmdline_popup = {
67+
position = { row = 25, col = "50%" },
68+
size = { width = 50, height = "auto" },
69+
border = {
70+
style = "rounded",
71+
text = { top = " Command " },
72+
},
73+
},
74+
},
75+
},
76+
}

neo-tree filesystem [1]

Whitespace-only changes.

0 commit comments

Comments
 (0)