Open GideonWolfe opened 4 years ago
I'm not sure how much work would need to be done but I just took a quick look at the source and it seems like someone already had a similar idea?
HA! hjkl
was my first reaction when I found this as well - looks they were added in https://github.com/rastapasta/mapscii/commit/fccacad3a24c5fc995eae2917f1d2cca91ecbb8d and work if running with npx
but not in the wild :(
The problem
When I open this program my hands instinctively try to adjust the map using the vim keys. This is the natural mode of navigation for countless TUI programs.
Proposed solution
h
,j
,k
, andl
are the classic left, down, up, right controls. You could keep zooming asa
andz
, but I would love to useJ
andK
.Additional context
I don't believe these keybinds would interfere with any preexisting options, and non vim users could easily stick to the arrow keys.
This also provides a framework for more keybinds. For example if you implement a search feature, the
/
key is already most peoples go-to and it makes the program easy to learn.