2023-02-01 19:11:37 +00:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
...
|
2023-11-08 02:16:46 +00:00
|
|
|
}: let
|
|
|
|
inherit (lib) mkIf nvim optionalString;
|
|
|
|
|
2023-02-01 19:11:37 +00:00
|
|
|
cfg = config.vim.lsp;
|
|
|
|
in {
|
|
|
|
config = mkIf (cfg.enable && cfg.lspSignature.enable) {
|
2023-02-27 19:25:39 +00:00
|
|
|
vim.startPlugins = [
|
|
|
|
"lsp-signature"
|
|
|
|
];
|
2023-02-01 19:11:37 +00:00
|
|
|
|
|
|
|
vim.luaConfigRC.lsp-signature = nvim.dag.entryAnywhere ''
|
|
|
|
-- Enable lsp signature viewer
|
2023-07-26 07:27:57 +00:00
|
|
|
require("lsp_signature").setup({
|
|
|
|
${optionalString (config.vim.ui.borders.plugins.lsp-signature.enable) ''
|
|
|
|
bind = true, -- This is mandatory, otherwise border config won't get registered.
|
|
|
|
handler_opts = {
|
|
|
|
border = "${config.vim.ui.borders.plugins.lsp-signature.style}"
|
|
|
|
}
|
|
|
|
''}
|
|
|
|
})
|
2023-02-01 19:11:37 +00:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
}
|