Cursor "Jumps" to Bottom After Action


This scenario often occurs when I initiate a Drafts 5 action, for example “undo” and various others: After tapping an action, the cursor then immediately jumps to the very bottom of the text?

Is there a way to keep this from happening? Do I need to include additional custom Javascript inside the action to prevent this behavior?

I usually want my cursor to stay in place, so I can continue editing without having to scroll all the way back up to find my place again.



Have you figured this out yet?

I am having this same issue and hoping there is a way to figure it out. Might ask in slack and see if there is any reply.

Don’t believe this is still an issue. Can’t reproduce it here. What is the context you are seeing it happen?

In regards to a shortcut being run.

I have set up a shortcut, a mini daily log, that pulls in the date, time, address and weather information and simply asks, what did you do today? I prepend it to the draft, using the draft ID so that the most recent entry is at the top.

Yet, the cursor is always at the very bottom. I am also trying to find a way for the cursor to be below the question of “What did you do today?”, if that is possible.

[sorry, I can only upload one image as a new user.]


Hmm. The only way to set the cursor position is within a Drafts action. If you had a scripted action in Drafts that set the cursor position to the top, you could call that using the “Run Action” option in the Shortcuts “Add to Draft” step.

The action would need to be just a script something like: