Skip to content

[FEATURE] Add Ctrl+J/Ctrl+K navigation in menu bar (Vim-friendly) #7056

Closed as not planned

Description

@muzig

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

What do you want to change or add?
Add Vim-style keyboard navigation support to the project's menu bar (e.g., the "Commands" panel in the attached screenshot):

  • Bind Ctrl+K to move upward between menu options
  • Bind Ctrl+J to move downward between menu options

What are the benefits of implementing this?

  1. Improves efficiency for Vim developers: they can navigate menus without switching to mouse/other keys, keeping a keyboard-first workflow
  2. Enhances accessibility for a common developer group (Vim users), reducing friction when using the project's interface

Activity

  1. added
    discussionUsed for feature requests, proposals, ideas, etc. Open discussion
    on Jan 6, 2026
  2. added
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on Jan 6, 2026
  3. github-actions commented on Jan 6, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    Feel free to ignore if none of these address your specific case.

    For keybind-related issues, please also check our pinned keybinds documentation: #4997

  4. fengwk commented on Jan 10, 2026

    @fengwk

    Expected to get this feature

  5. rafael-unloan commented on Feb 16, 2026

    @rafael-unloan

    I would've thought you could implement via:

    "keybinds": {
       "input_newline": "shift+return,ctrl+return,alt+return",
       "input_move_up": "ctrl+k",
       "input_move_down": "ctrl+j",
       "history_previous": "ctrl+j"
    }
    

    but nope. Why is this?

  6. added a commit that references this issue on Mar 25, 2026
    f043bf4
  7. dblume commented on Mar 25, 2026

    @dblume

    It turns out that the lists in the TUI dialogs have some hardcoded handlers. My proposed fix is to make a change where the key events are already hardcoded in dialog-select.tsx. The only intentional tradeoff I know of is in a dialog like /themes where you preview themes as you navigate. With ctrl+k, either you get the preview, or you get "input_delete_to_line_end" but not both. I chose the preview, as it's consistent with ctrl+j. My proposed change is over here: dblume/opencode@dev...dblume-fix-opencode7056

  8. dblume commented on Mar 27, 2026

    @dblume

    @kommander , I hope the PR mentioned above is acceptable. I think it adds useful and desired functionality.

  9. removed
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    discussionUsed for feature requests, proposals, ideas, etc. Open discussion
    on May 3, 2026
  10. github-actions commented on Jul 3, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions