roam-toolkit
roam-toolkit copied to clipboard
Vim mappings wishlist
- [x] Toggle page expanded/collapsed in block references/query
- [x] Expand next breadcrumb in block reference/query (have an implementation for this one locally)
- [ ] Show references for current/topmost panel in sidebar
- [ ] >> and << for indentation (and just supporting Tab in normal mode)
some ideas..
- how about ctrl-o and ctrl-i jumplist-like behavior? maybe a dummy one could just be browser back/forward
- H/M/L block jumping
- zz zt zb to scroll relative to block selection
- zR to fold/unfold ALL (would really be useful for me in some cases :D)
- prefix # to hjkl
- maybe have relative block number hints?
- some kind of search with /, maybe just does cmd u for searchbar?
Mostly I've been too lazy to figure out how to get surfingkeys and this to work better together- think I'm mostly missing left sidebar nav and forward/back browser history nav :D
+1 for making this work better with other vim-mapping extension. The people that are likely to use this features are likely installed an full-fledge vim-mapping extension such as Surfingkey or Vimium already.
Currently it doesn't work too well with each other, because of the overlapping normal mode and the override of Escape Key. I'm wondering if vim mode operate directly on Roam's native block-selection mode would be better than having a separate Normal mode as the current implementation?
@lkhphuc for now what I do re Surfingkeys is unmap everything but a select number of mappings like https://gist.github.com/Stvad/02d3d40b08e9505c548e00bba05ccea0#file-surfingkeys_config-js-L185
+1 for ctrl-o / ctrl-i jumplist style behaviour. It feels like the only essential thing missing is being able to jump back.
@lkhphuc for now what I do re Surfingkeys is unmap everything but a select number of mappings like https://gist.github.com/Stvad/02d3d40b08e9505c548e00bba05ccea0#file-surfingkeys_config-js-L185
Hey thank for the link, especially for the Roam clickable stuffs. The workflow with SurfingKey is much better now.
~~FWIW, because I use the horizontal layout in Roam, I keep the page scrolling functionality jkhl
in SurfingKey and remap Roam-toolkit block movement using Shift+H/J/K/L
.~~
unmapAllExcept([
'f', 'F', '/', 'C', '?', 't', 'T', 'S', 'D',
'j', 'k', 'J', 'K', 'cs', 'cS',
], /roamresearch\.com/i);
Edit: SurfingKey scroll doesn't follow Block selection so I revert to normal i/j/k/l navigation.
Toggle page expanded/collapsed in block references/query
Would be great to collapse block while inside the block as well, more like vim folding. Currently can only fold/unfold at the parent block.
One thing I miss from Workflowy (I think) is "collapse to parent" - on repeat of the collapse shortcut it'd jump to parent and then collapse it.
@neildurant @butterywombat what would ctrl-o/i do in this case? IMHO remapping browser back/forward does not seem too valuable..
- [x] delete block (possible with alt-k but i'd like a vim shortcut for it)
- [x] duplicate block (same as above)
- [ ]
/
to open search bar (maybe even allown
/N
to go through search results, though that is of less certain value)
* [ ] delete block (possible with alt-k but i'd like a vim shortcut for it)
We already has dd
for that, though it's not effective 100% of the time at the moment. Sometime press d bring me to insert mode.
* [ ] duplicate block (same as above)
Already has y
and k
working as well.
* [ ] `/` to open search bar (maybe even allow `n`/`N` to go through search results, though that is of less certain value)
Do you have SurfingKey, you can use it for this.
Any chance there could be a mapping for "go to sibling"? For example, let's say I have the following:
- item 1
- item 2
- item 3
- item 4
and I have "item 4" selected, there's no easy way that I can see to go to "item 1" unless you manually go up up up to it (or use the mouse, which naturally we're trying to avoid 🙂).
That, and relative line number jumping would be 👨🍳 💋
Open current block in zoomed in view/sidebar from normal mode. (Ctrl-o/Ctrl-shift-o
in the insert mode)
Click on page/references filter followed by autofocus of the search field in resulting window
Open daily pages in Sidebar (should be possible by simulating Shift+click on "daily notes" now)
Open current block in zoomed in view/sidebar from normal mode. (
Ctrl-o/Ctrl-shift-o
in the insert mode)
It would be great to have a mapping to zoom in and out but in normal mode.
I look forward to using .
to repeat the last command if that's possible.
I've got the following for general suggestions and I didn't know where to put them other than in the wishlist issue
- change amount the page scrolls up by when using those hotkeys
- implement vimmotion
followed by key (allow us to set the key for each of these) to allow quick jumping to the following: - insert mode at the beginning of a block
- insert mode at the end of a block
- insert mode at the beginning of a word
- insert mode at the end of a word
- move blocks up, down, indent, or outdent with alt+h/j/k/l (really any default hotkey works, just allow us to rebind it)
- when auto complete list is on screen as in when / is typed or when filling a page reference or tag, use j and k to navigate up and down the list