Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keyboard shortcut to focus cursor #47

Closed
kalenjordan opened this issue Apr 27, 2020 · 7 comments
Closed

Keyboard shortcut to focus cursor #47

kalenjordan opened this issue Apr 27, 2020 · 7 comments

Comments

@kalenjordan
Copy link

kalenjordan commented Apr 27, 2020

A keyboard shortcut to focus the cursor - possibly Command+Enter?

How it works currently:

  1. Search for a page using Command+U
  2. Select a page using arrow keys and Enter
  3. You have to use the mouse to click before you can start typing

How I'd like it to work:

  1. Search for a page using Command+U
  2. Select a page using arrow keys and Enter
  3. Begin typing using this keyboard shortcut.
@teodorlu
Copy link

it is not possible to find a page or create a page and then start typing without using the mouse

I don't think I follow. Didn't you just explain how to do that with? Caveat: I'm on Linux, where control+U takes me to the search bar.

@kalenjordan
Copy link
Author

I updated the initial post to hopefully make it more clear.

@teodorlu
Copy link

teodorlu commented Apr 28, 2020

Ah, I see what you mean now. I agree, that would help create pages faster.

Not sure it's a bug, though. There's a discussion going about how to handle feature requests in #feature-requests on the Roam Slack.

@maxcodes
Copy link

I played around trying to implement this, but couldn't quite figure it out. Simulating a click using element.click() doesn't work. I assume we'd need to fiddle with how React handles events internally, but given the weird compression that Roam uses, I doubt we'll be able to reverse engineer which component does what...

If anyone has any pointers as to how to achieve this, I'd be more than happy to try implementing it

@Stvad
Copy link
Member

Stvad commented May 2, 2020

the functionality to create new block already exists in Roam objects. and there is also #24 PR to improve on that.

I'm not quite sure how to detect that we've just created a new page though

@maxcodes
Copy link

maxcodes commented May 2, 2020 via email

@Stvad
Copy link
Member

Stvad commented Jul 11, 2020

My understanding is that this exists natively in Roam now - Cmd-Enter would get you to the first block

@Stvad Stvad closed this as completed Jul 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants