diff --git a/nvim/.config/nvim/lua/plugins/whichkey.lua b/nvim/.config/nvim/lua/plugins/whichkey.lua index 531a752..bec8281 100644 --- a/nvim/.config/nvim/lua/plugins/whichkey.lua +++ b/nvim/.config/nvim/lua/plugins/whichkey.lua @@ -2,19 +2,19 @@ return { -- Useful plugin to show you pending keybinds. "folke/which-key.nvim", event = "VimEnter", -- Sets the loading event to 'VimEnter' config = function() -- This is the function that runs, AFTER loading - require("which-key").setup({ - triggers_blacklist = { - n = { "d", "y", "v" }, - }, + local wk = require("which-key") + wk.setup({ + modes = { defer = { v = true, y = true, d = true } }, }) -- Document existing key chains - require("which-key").register({ - ["c"] = { name = "[C]ode", _ = "which_key_ignore" }, - ["d"] = { name = "[D]ocument", _ = "which_key_ignore" }, - ["r"] = { name = "[R]ename", _ = "which_key_ignore" }, - ["s"] = { name = "[S]earch", _ = "which_key_ignore" }, - ["w"] = { name = "[W]orkspace", _ = "which_key_ignore" }, + + wk.add({ + + { "c", group = "[C]ode" }, + { "d", group = "[D]ocument" }, + { "s", group = "[S]earch" }, + { "w", group = "[W]orkspace" }, }) end, }