WuTheFWasThat / vimflowy

An open source productivity tool drawing inspiration from workflowy and vim
https://www.wuthejeff.com/vimflowy
MIT License
1.6k stars 111 forks source link

Spacebar causes window scroll when typing #317

Closed jeanlucthumm closed 3 years ago

jeanlucthumm commented 4 years ago

Bug: Sometimes the main window loses focus which causes it to scroll when the spacebar is hit, even in insert mode. Really annoying because you hit the spacebar a lot when typing a sentence.

How to reproduce:

  1. Start with more bullets than can be displayed in the main window so that scrolling is enabled
  2. Scroll to the middle of the page such that the scroll bar indicates there is room to scroll up and down.
  3. Create a new bullet with a few words
  4. Go to the beginning of any word in the new bullet and do the motion "c e" to delete to end of word and go to insert mode.
  5. Type another word and go back to command mode.
  6. Press spacebar. This should cause scrolling.

Expected behavior: When pressing spacebar in step 6 above, no scroll occurs.

I was using vimflowy through a local docker instance on Chrome Version 77.0.3865.120

jeanlucthumm commented 4 years ago

Also, I use Ctrl-C instead of ESC to go to command mode

jeanlucthumm commented 4 years ago

Found another simpler way to get this bug to come up:

  1. Write a sentence in a bullet
  2. Go to insert mode and use Ctrl-Backspace to delete a word
  3. Spacebar now scrolls
WuTheFWasThat commented 4 years ago

thanks for the bug report! sadly don't have much time to devote to this project these days but will see if there's an easy fix when i get the chance

WuTheFWasThat commented 3 years ago

fixed, thanks to @platers!