update UI plugins
This commit is contained in:
parent
071be15dc1
commit
a4e06120d2
4 changed files with 179 additions and 134 deletions
|
|
@ -1,10 +0,0 @@
|
|||
return {
|
||||
-- better imputs
|
||||
"stevearc/dressing.nvim",
|
||||
opts = {
|
||||
input = {
|
||||
-- handle by noice
|
||||
enabled = false,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
@ -1,123 +0,0 @@
|
|||
return {
|
||||
"folke/noice.nvim",
|
||||
event = "VeryLazy",
|
||||
dependencies = {
|
||||
-- if you lazy-load any plugin below, make sure to add proper `module="..."` entries
|
||||
"MunifTanjim/nui.nvim",
|
||||
},
|
||||
opts = {
|
||||
presets = {
|
||||
bottom_search = true,
|
||||
-- command_palette = true,
|
||||
long_message_to_split = true,
|
||||
inc_rename = true,
|
||||
},
|
||||
lsp = {
|
||||
override = {
|
||||
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
|
||||
["vim.lsp.util.stylize_markdown"] = true,
|
||||
["cmp.entry.get_documentation"] = true,
|
||||
},
|
||||
},
|
||||
routes = {
|
||||
{
|
||||
filter = {
|
||||
event = "msg_show",
|
||||
any = {
|
||||
{ find = "%d+L, %d+B" },
|
||||
{ find = "; after #%d+" },
|
||||
{ find = "; before #%d+" },
|
||||
},
|
||||
},
|
||||
view = "mini",
|
||||
},
|
||||
{
|
||||
filter = {
|
||||
event = "msg_show",
|
||||
kind = "search_count",
|
||||
},
|
||||
opts = { skip = true },
|
||||
},
|
||||
},
|
||||
views = {
|
||||
cmdline_popup = {
|
||||
position = {
|
||||
row = 5,
|
||||
col = "50%",
|
||||
},
|
||||
size = {
|
||||
width = 60,
|
||||
height = "auto",
|
||||
},
|
||||
},
|
||||
popupmenu = {
|
||||
relative = "editor",
|
||||
position = {
|
||||
row = 8,
|
||||
col = "50%",
|
||||
},
|
||||
size = {
|
||||
width = 60,
|
||||
height = 10,
|
||||
},
|
||||
border = {
|
||||
style = "rounded",
|
||||
padding = { 0, 1 },
|
||||
},
|
||||
win_options = {
|
||||
winhighlight = { Normal = "Normal", FloatBorder = "DiagnosticInfo" },
|
||||
},
|
||||
},
|
||||
notify = {
|
||||
enabled = false,
|
||||
},
|
||||
messages = {
|
||||
enabled = false,
|
||||
},
|
||||
},
|
||||
},
|
||||
-- stylua: ignore
|
||||
keys = {
|
||||
{
|
||||
"<S-Enter>",
|
||||
function() require("noice").redirect(vim.fn.getcmdline()) end,
|
||||
mode = "c",
|
||||
desc =
|
||||
"Redirect Cmdline"
|
||||
},
|
||||
{
|
||||
"<leader>unl",
|
||||
function() require("noice").cmd("last") end,
|
||||
desc =
|
||||
"Noice Last Message"
|
||||
},
|
||||
{
|
||||
"<leader>unh",
|
||||
function() require("noice").cmd("history") end,
|
||||
desc =
|
||||
"Noice History"
|
||||
},
|
||||
{ "<leader>una", function() require("noice").cmd("all") end, desc = "Noice All" },
|
||||
{ "<leader>und", function() require("noice").cmd("dismiss") end, desc = "Dismiss All" },
|
||||
{
|
||||
"<c-f>",
|
||||
function() if not require("noice.lsp").scroll(4) then return "<c-f>" end end,
|
||||
silent = true,
|
||||
expr = true,
|
||||
desc =
|
||||
"Scroll forward",
|
||||
mode = {
|
||||
"i", "n", "s" }
|
||||
},
|
||||
{
|
||||
"<c-b>",
|
||||
function() if not require("noice.lsp").scroll(-4) then return "<c-b>" end end,
|
||||
silent = true,
|
||||
expr = true,
|
||||
desc =
|
||||
"Scroll backward",
|
||||
mode = {
|
||||
"i", "n", "s" }
|
||||
},
|
||||
},
|
||||
}
|
||||
177
config/nvim/lua/aleidk/plugins-base/ui.lua
Normal file
177
config/nvim/lua/aleidk/plugins-base/ui.lua
Normal file
|
|
@ -0,0 +1,177 @@
|
|||
return {
|
||||
{
|
||||
-- better imputs
|
||||
"stevearc/dressing.nvim",
|
||||
opts = {
|
||||
input = {
|
||||
-- handle by noice
|
||||
enabled = false,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"folke/noice.nvim",
|
||||
event = "VeryLazy",
|
||||
dependencies = {
|
||||
"MunifTanjim/nui.nvim",
|
||||
"rcarriga/nvim-notify",
|
||||
},
|
||||
opts = {
|
||||
presets = {
|
||||
bottom_search = true,
|
||||
long_message_to_split = true,
|
||||
inc_rename = true,
|
||||
lsp_doc_border = true,
|
||||
},
|
||||
lsp = {
|
||||
override = {
|
||||
-- override the default lsp markdown formatter with Noice
|
||||
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
|
||||
-- override the lsp markdown formatter with Noice
|
||||
["vim.lsp.util.stylize_markdown"] = true,
|
||||
-- override cmp documentation with Noice (needs the other options to work)
|
||||
["cmp.entry.get_documentation"] = true,
|
||||
},
|
||||
message = {
|
||||
view = "mini",
|
||||
},
|
||||
progress = {
|
||||
view = "mini_left"
|
||||
}
|
||||
},
|
||||
routes = {
|
||||
{
|
||||
filter = {
|
||||
event = "msg_show",
|
||||
kind = "",
|
||||
find = "written",
|
||||
},
|
||||
opts = { skip = true },
|
||||
},
|
||||
{
|
||||
filter = {
|
||||
event = "notify",
|
||||
min_height = 15
|
||||
},
|
||||
view = 'popup'
|
||||
},
|
||||
{
|
||||
filter = {
|
||||
event = "notify",
|
||||
kind = "info"
|
||||
},
|
||||
view = 'mini'
|
||||
},
|
||||
},
|
||||
views = {
|
||||
notify = {
|
||||
merge = true
|
||||
},
|
||||
cmdline_popup = {
|
||||
position = {
|
||||
row = 5,
|
||||
col = "50%",
|
||||
},
|
||||
size = {
|
||||
width = 60,
|
||||
height = "auto",
|
||||
},
|
||||
},
|
||||
popupmenu = {
|
||||
relative = "editor",
|
||||
position = {
|
||||
row = 8,
|
||||
col = "50%",
|
||||
},
|
||||
size = {
|
||||
width = 60,
|
||||
height = 10,
|
||||
},
|
||||
border = {
|
||||
style = "rounded",
|
||||
padding = { 0, 1 },
|
||||
},
|
||||
win_options = {
|
||||
winhighlight = { Normal = "Normal", FloatBorder = "DiagnosticInfo" },
|
||||
},
|
||||
},
|
||||
mini_left = {
|
||||
backend = "mini",
|
||||
relative = "editor",
|
||||
align = "left",
|
||||
timeout = 2000,
|
||||
reverse = true,
|
||||
focusable = false,
|
||||
position = {
|
||||
row = -1,
|
||||
col = 0,
|
||||
},
|
||||
size = {
|
||||
width = "auto",
|
||||
height = "auto",
|
||||
max_height = 10,
|
||||
},
|
||||
border = {
|
||||
style = "none",
|
||||
},
|
||||
zindex = 60,
|
||||
win_options = {
|
||||
winbar = "",
|
||||
foldenable = false,
|
||||
winblend = 30,
|
||||
winhighlight = {
|
||||
Normal = "NoiceMini",
|
||||
IncSearch = "",
|
||||
CurSearch = "",
|
||||
Search = "",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
-- stylua: ignore
|
||||
keys = {
|
||||
{
|
||||
"<S-Enter>",
|
||||
function() require("noice").redirect(vim.fn.getcmdline()) end,
|
||||
mode = "c",
|
||||
desc =
|
||||
"Redirect Cmdline"
|
||||
},
|
||||
{
|
||||
"<leader>unl",
|
||||
function() require("noice").cmd("last") end,
|
||||
desc =
|
||||
"Noice Last Message"
|
||||
},
|
||||
{
|
||||
"<leader>unh",
|
||||
function() require("noice").cmd("history") end,
|
||||
desc =
|
||||
"Noice History"
|
||||
},
|
||||
{ "<leader>una", function() require("noice").cmd("all") end, desc = "Noice All" },
|
||||
{ "<leader>und", function() require("noice").cmd("dismiss") end, desc = "Dismiss All" },
|
||||
{
|
||||
"<c-f>",
|
||||
function() if not require("noice.lsp").scroll(4) then return "<c-f>" end end,
|
||||
silent = true,
|
||||
expr = true,
|
||||
desc =
|
||||
"Scroll forward",
|
||||
mode = {
|
||||
"i", "n", "s" }
|
||||
},
|
||||
{
|
||||
"<c-b>",
|
||||
function() if not require("noice.lsp").scroll(-4) then return "<c-b>" end end,
|
||||
silent = true,
|
||||
expr = true,
|
||||
desc =
|
||||
"Scroll backward",
|
||||
mode = {
|
||||
"i", "n", "s" }
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue