Closed ink-splatters closed 1 year ago
Hi @ink-splatters, can you elaborate more about what will a vi mode be used for?
I guess OP means vim-like navigation keys, so hjkl
with hl
for opening/closing a post and jk
to move verticallly between posts, plus things like gg/G
to go to the first/last displayed entry. I agree it would be to have that, as many TUI applications provide such bindings and I'm used to them.
@BachoSeven thanks for the additional insight.
Tbh, the default keybindings are kinda a mess 😢. I haven't used any TUIs before I built HN-TUI, so I have no idea what the bindings other apps normally provide.
I hope this is still addressable with the help of key mapping in the configuration file.
Key mappings in config file would be perfect, I could provide a vi-mode
bindings config file which can be linked to in the README for those interested, will do soon.
Hey @BachoSeven ! How's that binding config file coming through? This is an awesome app, but it is really needed!
@slarrain
As someone who's used a ton of TUI apps and with a vim background, these bindings make a lot more sense to me, as they're more consistent with many other TUI apps:
[keymap.global_keymap]
quit = "C-c"
goto_previous_view = "q"
goto_search_view = "/"
[keymap.story_view_keymap]
page_down = "C-d"
page_up = "C-u"
prev_story_tag = "["
next_story_tag = "]"
open_article_in_article_view = "v"
[keymap.comment_view_keymap]
page_down = "C-d"
page_up = "C-u"
open_link_in_browser = "o"
open_link_in_article_view = "v"
toggle_collapse_comment = " "
[keymap.article_view_keymap]
page_down = "C-d"
page_up = "C-u"
open_link_in_browser = "o"
open_link_in_article_view = "v"
The default keybindings are not perfect but I guess it can be worked around by using the above keymap.
I'll close this issue for now.
Hi,
@aome510 any plans for this one?
Anyone around interested in?
Thanks a lot