Skip to content

feat(history): j/k nav + bracket/star fixes - #232

Merged
Maxteabag merged 3 commits into
mainfrom
feat/history-jk-nav
May 25, 2026
Merged

Maxteabag merged 3 commits into
mainfrom
feat/history-jk-nav

Conversation

@Maxteabag

Copy link
Copy Markdown
Owner

Adds vim-style j/k navigation to the query history / telescope screen — moves the highlight down/up in the list when the filter is closed. When the filter is open, j and k are typed into the search like any other character, so fuzzy/substring matches that contain them still work.

Maxteabag added 3 commits May 25, 2026 13:18
j and k now move the cursor down/up in the history OptionList when the
filter is closed; when the filter is open, they're typed into the search
like any other character.
Two bugs in the query history screen:

1. Bracket identifiers like [dbo].[ServiceFeatures] were truncated to
   "[dbo]." in the option list. rich.markup.escape only escapes brackets
   whose tag-name starts with [a-z#/@], so [ServiceFeatures] slipped
   through and Textual's markup parser ate it as an unknown tag. Build
   options (and the preview) as Rich Text instead of markup strings to
   sidestep parsing entirely.

2. Starring one row marked every same-text row as starred, because
   history dedup is per (connection, database, query_hash) but the
   starred store is keyed by (connection, query_text). Collapse rows
   with identical query text in _merge_entries (keeping the most-recent
   timestamp), so the display row count matches the starring model.
@Maxteabag Maxteabag changed the title feat(history): j/k vim navigation in query history feat(history): j/k nav + bracket/star fixes May 25, 2026
@Maxteabag
Maxteabag merged commit f2c8194 into main May 25, 2026
21 checks passed
@Maxteabag
Maxteabag deleted the feat/history-jk-nav branch May 25, 2026 11:59
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

Successfully merging this pull request may close these issues.

1 participant