obsidian-tasks
obsidian-tasks copied to clipboard
Cursor moves 13 characters to the right when toggle task as done
Expected Behavior
I expect that when I execute the command Tasks: Toggle task done that the cursor/caret position should not change after the task status has changed.
Current Behavior
When I execute the command Tasks: Toggle task done for a task which is not done (marking it done) the cursor position moves 13 characters to the right. (And to the left when "uncompleting" a task)
Steps to Reproduce
Happens on both edit/raw markdown mode and new live preview mode in new editor version.
Context (Environment)
- Obsidian version: v0.13.8 (insider)
- Tasks version: 1.4.1
Possible Solution
As the ✅ 2021-12-12 string which is added is 13 characters (including the preceding space) maybe it's something to do with this, that the saved cursor position is not stored correctly after the line is replaced, not sure.
Thank you for the report @jdudleyie. I can reproduce the issue. Will be fixed when I have the time.
This fix was just released in Tasks 1.13.1