diff --git a/lua/custom/lspconfig.lua b/lua/custom/lspconfig.lua index 13d7c8c..15e6dfd 100644 --- a/lua/custom/lspconfig.lua +++ b/lua/custom/lspconfig.lua @@ -71,8 +71,10 @@ local on_attach = function(_, bufnr) local opts = { noremap = true, silent = true, buffer = bufnr } keymap.set("n", "g0", "lua vim.lsp.buf.document_symbol()", opts) - keymap.set("n", "gd", "lua vim.lsp.buf.definition()", opts) - keymap.set("n", "gi", "lua vim.lsp.buf.implementation()", opts) + -- floating popups instead of the quickfix split for multiple results + keymap.set("n", "gd", "Lspsaga finder def", opts) + keymap.set("n", "gi", "Lspsaga finder imp", opts) + keymap.set("n", "gy", "Lspsaga finder tyd", opts) keymap.set("n", "l", format_buffer, { desc = "Format code function" }) keymap.set( "n", diff --git a/lua/custom/plugins/init.lua b/lua/custom/plugins/init.lua index 9ef31ae..5f2eb71 100644 --- a/lua/custom/plugins/init.lua +++ b/lua/custom/plugins/init.lua @@ -30,6 +30,7 @@ return { -- use enter to open file from the finder finder = { keys = { toggle_or_open = "" }, + methods = { tyd = "textDocument/typeDefinition" }, }, -- use enter to open file with definition preview definition = {