Incorrect behavior of nnoremap z zz mapping
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
Describe the bug
The nnoremap z zz mapping in the Visual Studio Code Vim extension is not working as expected. When using this mapping, the current line is centered, but the cursor also moves forward by one character, which is not the desired behavior.
To Reproduce
Steps to reproduce the behavior:
- Install the Visual Studio Code Vim extension.
- Open Visual Studio Code.
- Set up the mapping
nnoremap z zzin .vimrc file. - Open a file.
- Move the cursor to any line in the file.
- Press the 'z' key.
Expected behavior
After pressing the 'z' key, the current line should be centered without any changes to the cursor position.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the nnoremap z zz mapping in the Visual Studio Code Vim extension using the listed steps, then trace how the mapping handles the z key and cursor position. Done means centering the current line without moving the cursor forward.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100