feat(ui): Add more LSP improvements, install fancy UI plugins

This commit is contained in:
Калистратов Максим
2026-06-03 21:58:43 +03:00
parent 81e111c01e
commit ba05846b9f
13 changed files with 88 additions and 18 deletions

View File

@@ -1,6 +1,7 @@
---@type vim.lsp.Config ---@type vim.lsp.Config
return { return {
root_markers = { "composer.json" }, filetypes = { "php" },
root_markers = { ".git" },
---@type lspconfig.settings.intelephense ---@type lspconfig.settings.intelephense
settings = { settings = {
intelephense = { intelephense = {

View File

@@ -5,7 +5,30 @@ return {
"typescript", "typescript",
"vue", "vue",
}, },
---@type lspconfig.settings.vtsls
settings = { settings = {
typescript = {
inlayHints = {
enumMemberValues = {
enabled = true,
},
parameterNames = {
enabled = "literals",
},
parameterTypes = {
enabled = true,
},
propertyDeclarationTypes = {
enabled = true,
},
variableTypes = {
enabled = true,
},
functionLikeReturnTypes = {
enabled = true,
},
},
},
---@type lspconfig.settings.vtsls ---@type lspconfig.settings.vtsls
vtsls = { vtsls = {
tsserver = { tsserver = {
@@ -22,20 +45,6 @@ return {
autoImports = true, autoImports = true,
}, },
updateImportsOnFileMove = { enabled = "always" }, updateImportsOnFileMove = { enabled = "always" },
inlayHints = {
enumMemberValues = {
enabled = true,
},
parameterNames = {
enabled = "literals",
},
parameterTypes = {
enabled = true,
},
propertyDeclarationTypes = {
enabled = true,
},
},
}, },
}, },
} }

View File

@@ -1,2 +1,4 @@
---@type lspconfig.Config ---@type lspconfig.Config
return {} return {
enabled = false,
}

5
after/plugin/fidget.lua Normal file
View File

@@ -0,0 +1,5 @@
local fidget = require("fidget")
local options = {}
fidget.setup(options)

View File

@@ -6,3 +6,4 @@ gitsigns.setup({
delay = 100, delay = 100,
}, },
}) })
require("scrollbar.handlers.gitsigns").setup()

3
after/plugin/laravel.lua Normal file
View File

@@ -0,0 +1,3 @@
local laravel = require("laravel")
laravel.setup()

10
after/plugin/lspsaga.lua Normal file
View File

@@ -0,0 +1,10 @@
local lspsaga = require("lspsaga")
lspsaga.setup({
implement = {
enable = true,
},
symbol_in_winbar = {
enable = true,
},
})

View File

@@ -0,0 +1,3 @@
local scrollbar = require("scrollbar")
scrollbar.setup()

View File

@@ -8,6 +8,9 @@ end
---@type nvim_tree.config ---@type nvim_tree.config
local options = { local options = {
view = {
side = "right",
},
update_focused_file = { update_focused_file = {
enable = true, enable = true,
exclude = function(args) exclude = function(args)

View File

@@ -24,7 +24,7 @@ opt.tabstop = 4
opt.shiftwidth = 4 opt.shiftwidth = 4
opt.softtabstop = 4 opt.softtabstop = 4
opt.smartindent = true opt.smartindent = true
opt.breakindent = true opt.autoindent = true
-- Search -- Search
opt.ignorecase = true opt.ignorecase = true
@@ -62,3 +62,4 @@ opt.mouse = "a"
opt.showmode = false opt.showmode = false
opt.isfname:append("@-@") opt.isfname:append("@-@")
opt.exrc = true opt.exrc = true
opt.winbar = "%=%m"

View File

@@ -6,7 +6,17 @@ cmp.build():pwait()
---@type blink.cmp.Config ---@type blink.cmp.Config
local cmp_options = { local cmp_options = {
keymap = { preset = "default" }, keymap = { preset = "default" },
completion = { menu = { auto_show = true }, documentation = { auto_show = true } }, completion = {
menu = { auto_show = true },
documentation = { auto_show = true },
ghost_text = { enabled = true },
list = {
selection = {
auto_insert = false,
preselect = true,
},
},
},
sources = { default = { "lsp", "path", "snippets", "buffer" } }, sources = { default = { "lsp", "path", "snippets", "buffer" } },
fuzzy = { implementation = "rust" }, fuzzy = { implementation = "rust" },
} }

View File

@@ -39,6 +39,12 @@ vim.pack.add({
{ src = "https://github.com/nvim-tree/nvim-tree.lua" }, { src = "https://github.com/nvim-tree/nvim-tree.lua" },
{ src = "https://github.com/tpope/vim-fugitive" }, { src = "https://github.com/tpope/vim-fugitive" },
{ src = "https://github.com/lewis6991/gitsigns.nvim" }, { src = "https://github.com/lewis6991/gitsigns.nvim" },
{ src = "https://github.com/petertriho/nvim-scrollbar" },
{ src = "https://github.com/j-hui/fidget.nvim" },
{ src = "https://github.com/nvimdev/lspsaga.nvim" },
-- Framework specific
{ src = "https://github.com/adibhanna/laravel.nvim" },
-- WoW Addon API -- WoW Addon API
{ src = "https://github.com/Tyrannican/warcraft-api.nvim" }, { src = "https://github.com/Tyrannican/warcraft-api.nvim" },

View File

@@ -12,10 +12,22 @@
"rev": "619363c30309d29ffa631e67c8183f2a72caa373", "rev": "619363c30309d29ffa631e67c8183f2a72caa373",
"src": "https://github.com/stevearc/conform.nvim" "src": "https://github.com/stevearc/conform.nvim"
}, },
"fidget.nvim": {
"rev": "82404b196e73a00b1727a91903beef5ddc319d22",
"src": "https://github.com/j-hui/fidget.nvim"
},
"gitsigns.nvim": { "gitsigns.nvim": {
"rev": "dd3f588bacbeb041be6facf1742e42097f62165d", "rev": "dd3f588bacbeb041be6facf1742e42097f62165d",
"src": "https://github.com/lewis6991/gitsigns.nvim" "src": "https://github.com/lewis6991/gitsigns.nvim"
}, },
"laravel.nvim": {
"rev": "a0013e3ee80f09baed482cc79b03b0fc00ea47b0",
"src": "https://github.com/adibhanna/laravel.nvim"
},
"lspsaga.nvim": {
"rev": "3e33a6a6c5d379f3d4fae77fae6b53b762a0a30f",
"src": "https://github.com/nvimdev/lspsaga.nvim"
},
"lualine.nvim": { "lualine.nvim": {
"rev": "221ce6b2d999187044529f49da6554a92f740a96", "rev": "221ce6b2d999187044529f49da6554a92f740a96",
"src": "https://github.com/nvim-lualine/lualine.nvim" "src": "https://github.com/nvim-lualine/lualine.nvim"
@@ -40,6 +52,10 @@
"rev": "9573948c38bfabeec353ae7dd7d3ffec4c506a6b", "rev": "9573948c38bfabeec353ae7dd7d3ffec4c506a6b",
"src": "https://github.com/neovim/nvim-lspconfig" "src": "https://github.com/neovim/nvim-lspconfig"
}, },
"nvim-scrollbar": {
"rev": "f8e87b96cd6362ef8579be456afee3b38fd7e2a8",
"src": "https://github.com/petertriho/nvim-scrollbar"
},
"nvim-tree.lua": { "nvim-tree.lua": {
"rev": "07f541fcaa4a5ae019598240362449ab7e9812b3", "rev": "07f541fcaa4a5ae019598240362449ab7e9812b3",
"src": "https://github.com/nvim-tree/nvim-tree.lua" "src": "https://github.com/nvim-tree/nvim-tree.lua"