pending.nvim/lua
Barrett Ruth d18c0d3c82 fix(init): preserve cursor column and position in mutation functions (#152)
Problem: `toggle_complete()`, `toggle_priority()`, `adjust_priority()`,
`toggle_status()`, and `move_task()` captured only the row from
`nvim_win_get_cursor` and restored the cursor to column 0 after
re-render. Additionally, `toggle_complete()` followed the toggled task
to its new sorted position at the bottom of the category, which is
disorienting when working through a list of tasks.

Solution: Capture both row and column from the cursor, and restore the
column in all five functions. For `toggle_complete()`, instead of
chasing the task ID after render, clamp the cursor to the original row
(or total lines if shorter) and advance to the nearest task line,
similar to the `]t` motion in `textobj.lua`.
2026-03-13 20:49:33 -04:00
..
pending fix(init): preserve cursor column and position in mutation functions (#152) 2026-03-13 20:49:33 -04:00