mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-18 13:44:12 +00:00
cabfc592df
Track the highlighted result by entry ID rather than by list index. The index was never reset when results changed, so a background refetch that shrank the list left it pointing past the end and selecting threw on an undefined entry. Resolving by ID falls back to the first result instead, and keeps the user's position across rundown edits. Submit the entry belonging to the clicked row instead of whichever row was highlighted. The two only agreed because a mousemove usually precedes a click, so touch input navigated to the wrong entry. Ignore pointer moves that do not change the cursor position: scrolling the list under a stationary pointer fires a move event which pulled the selection away from the keyboard cursor. Keep the highlighted row scrolled into view while navigating. Close the finder on the search shortcut. Mantine ignores hotkeys while an input is focused, so the global toggle could not close the modal once the user was typing. The global Escape handler is dropped: the dialog already dismisses on Escape, and registering it document wide conflicts with inline field editing. Drop the bounds check in the index search, which compared an event ordinal against the count of all entries. The loop below it already returns no results when no event carries that index. Add e2e coverage for clicking a result, picking one with the keyboard, and closing with the shortcut. This needs the finder rows and the rundown event row to expose test ids and selection state. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DzALEq9gGWwFmwTdgAiFcY