Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

overlapping keymap of which-key #1325

Closed
2 tasks done
Penguin-SAMA opened this issue Jul 14, 2024 · 1 comment
Closed
2 tasks done

overlapping keymap of which-key #1325

Penguin-SAMA opened this issue Jul 14, 2024 · 1 comment
Labels
bug Something isn't working has:repro This issue contains reproducing steps keymap Keymap related issues

Comments

@Penguin-SAMA
Copy link

Version confirmation

  • Confirm

Following prerequisites

  • Confirm

Neovim version

NVIM v0.10.0

Branch info

main (Default/Latest)

Minimal (user) folder structure required to reproduce the issue

/user
├── configs
│   ├── dap-clients
│   ├── editor
│   │   └── visual-multi.lua
│   ├── formatters
│   └── lsp-servers
├── event.lua
├── keymap
│   ├── completion.lua
│   ├── core.lua
│   ├── editor.lua
│   ├── init.lua
│   ├── lang.lua
│   ├── tool.lua
│   └── ui.lua
├── options.lua
├── plugins
│   ├── editor.lua
│   ├── leetcode.lua
│   ├── nvim-surround.lua
│   └── xmake.lua
└── settings.lua

Minimal config with steps on how to reproduce the issue

When I open neovim, the following pop-up window always appear:

image

I use :checkhealth which-key The information output is as follows:


==============================================================================
which-key: require("which-key.health").check()

- OK Most of these checks are for informational purposes only.
  WARNINGS should be treated as a warning, and don't necessarily indicate a problem with your config.
  Please |DON't| report these warnings as an issue.
- WARNING |mini.icons| is not installed
- OK |nvim-web-devicons| is installed

Checking for issues with your mappings ~
- WARNING You're using an old version of the which-key spec.
  Your mappings will work, but it's recommended to update them to the new version.
  Please check the docs and suggested spec below for more info.
  Mappings: >
  {
    ["<leader>"] = {
      S = {
        name = "󰍉 Search"
      },
      W = {
        name = " Window"
      },
      b = {
        name = "󰓩 Buffer"
      },
      d = {
        name = " Debug"
      },
      f = {
        name = " Fuzzy Find"
      },
      g = {
        name = "󰊢 Git"
      },
      l = {
        name = "󱜙 Lsp"
      },
      n = {
        name = " Nvim Tree"
      },
      p = {
        name = " Package"
      },
      s = {
        name = " Session"
      }
    }
  }
  
  -- Suggested Spec:
  {
    { "<leader>S", group = "󰍉 Search" },
    { "<leader>W", group = " Window" },
    { "<leader>b", group = "󰓩 Buffer" },
    { "<leader>d", group = " Debug" },
    { "<leader>f", group = " Fuzzy Find" },
    { "<leader>g", group = "󰊢 Git" },
    { "<leader>l", group = "󱜙 Lsp" },
    { "<leader>n", group = " Nvim Tree" },
    { "<leader>p", group = " Package" },
    { "<leader>s", group = " Session" },
  }

checking for overlapping keymaps ~
- WARNING In mode `n`, <t> overlaps with <tj>, <to>, <tn>, <tk>:
  - <tj>: tab: Move to previous tab
  - <to>: tab: Only keep current tab
  - <tn>: tab: Create a new tab
  - <tk>: tab: Move to next tab
- WARNING In mode `n`, <s> overlaps with <spacefg>, <spacefc>, <spaceff>, <spacefd>, <spacefm>, <spacefp>:
  - <s>: Flash
- WARNING In mode `n`, <yS> overlaps with <ySS>:
  - <yS>: Add a surrounding pair around a motion, on new lines (normal mode)
  - <ySS>: Add a surrounding pair around the current line, on new lines (normal mode)
- WARNING In mode `n`, <ys> overlaps with <yss>:
  - <ys>: Add a surrounding pair around a motion (normal mode)
  - <yss>: Add a surrounding pair around the current line (normal mode)
- WARNING In mode `n`, <gc> overlaps with <gcc>:
  - <gc>: edit: Toggle comment for line with operator
  - <gcc>: edit: Toggle comment for line
- WARNING In mode `n`, <gb> overlaps with <gbc>:
  - <gb>: edit: Toggle comment for block with operator
  - <gbc>: edit: Toggle comment for block
- OK Overlapping keymaps are only reported for informational purposes.
  This doesn't necessarily mean there is a problem with your config.

Checking for duplicate mappings ~
- OK No duplicate mappings found

At the same time, when I use , the pop-up prompt also has the problem of duplicate icons:

image

Expected behavior

I'd like to know how to check and modify these overlapping keymappings, and what causes the duplicate icons.

Additional information

No response

@Penguin-SAMA Penguin-SAMA added the usage User-specific issues label Jul 14, 2024
@CharlesChiuGit
Copy link
Collaborator

#1323 #1324

@CharlesChiuGit CharlesChiuGit removed the usage User-specific issues label Jul 15, 2024
@Jint-lzxy Jint-lzxy added bug Something isn't working has:repro This issue contains reproducing steps keymap Keymap related issues labels Jul 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working has:repro This issue contains reproducing steps keymap Keymap related issues
Projects
None yet
Development

No branches or pull requests

3 participants