which-key.nvim icon indicating copy to clipboard operation
which-key.nvim copied to clipboard

Keymap description not being overwritten

Open daephx opened this issue 2 years ago • 3 comments

I have a keymap set for LSP document formatting that is applied to a buffer using on_attach. When looking at WhichKey, it seems to still be using the description for a default command.

Any idea why my description isn't being applied?

vim.keymap.set({ 'n', 'v' }, 'gf', formatting.format_document, {
  desc = 'Format document',
})

image

daephx avatar Sep 30 '22 12:09 daephx

Right, I know what's happening here. Any description set through WhichKey takes precedence, but it shouldn't do this in this particular case.

Will look into this.

folke avatar Sep 30 '22 14:09 folke

I'm also experiencing this issue. I'm no expert with lua but I'm happy to take a look if you have any pointers where to start?

jakenvac avatar Oct 31 '22 20:10 jakenvac

Any updates on this bug?

kevmuko avatar Mar 08 '23 00:03 kevmuko

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Jul 07 '24 01:07 github-actions[bot]

I think this is still a bug.

jakenvac avatar Jul 10 '24 08:07 jakenvac