Repository navigation
Open worktree, Open pull request, Compare to revision and Go to symbol show their keys on buttons, and F1 lists the rest #573
Description
Context
Part of #560: the second half. Open worktree (ow), Open pull request (opr), Compare to revision and Go to symbol (gs) still end in a hint row, and F1 doesn't list their keys. They move onto MentalDesk.Tui's PickerDialog, as the first task (#572) moves the others. They can't move yet because PickerDialog (as of 0.3.12) lacks four things they need. It takes a fixed list of rows, it has no column header, no loading or failed state inside the list, and no inline error that keeps the picker open.
Waits on a tui-style-guide release with those four, and on #572. The Dev can't open the library PR. The stakeholder, or the tui-style-guide team's Lead, files the issue below there. This task is held with blocked until a MentalDesk.Tui release has it.
Draft issue for mentaldesk/tui-style-guide
Title: A picker whose rows load slowly, have columns, or can fail to open still has to build its own list, so its keys end up in a hint row
Opportunity. PickerDialog covers a picker whose rows are known up front. TuiCode has four that aren't like that, so they can't use it, and they keep hint rows the guide forbids:
- Rows that arrive later, or fail to. Open pull request, Compare to revision and Go to symbol fetch their rows. They show Loading… inside the list, then the rows, or a failure with a retry, as the guide's loading rule says (TuiCode#525).
PickerDialogtakes its rows in the constructor. - A column header. Open worktree lists branch, folder and status in aligned columns under a dimmed header that fits the width.
- An error that keeps the picker open. When Open pull request can't check out the chosen PR, it says why inside the picker and stays open, so the user can pick another.
Ask. PickerDialog gains: rows set after it opens, with loading and failed states inside the list area (reusing LoadStateView, with the pick button dimmed while not loaded), an optional header line above the list, and a way to show an error line and stay open after a pick fails. The guide's picker section says how each looks.
Acceptance criteria
All four pickers
- The filter field says a dimmed
Type to filteruntil I type. - At the foot are two buttons and no hint row. The pick button is
▓ Enter Open ▓in Open worktree,▓ Enter Check out ▓in Open pull request,▓ Enter Compare ▓in Compare to revision and▓ Enter Go to ▓in Go to symbol, each beside▓ Esc Cancel ▓. - When the filter matches nothing, the list says
(no matches)and the pick button dims. -
F1opens Help headed with the picker's title, listing every key it binds.Escreturns to the picker as it was.
Each one's own behaviour, unchanged
- Open worktree still shows its column header, aligned with the rows at any width.
- Open pull request, Compare to revision and Go to symbol still show loading inside the list, then the rows, or a failure I can retry. The pick button is dimmed until rows arrive.
- When a PR can't be checked out, Open pull request says why and stays open.
- Every key works as before.
Tests
- Per picker: placeholder, button labels, no hint row,
(no matches)with the button disabled, andF1sheet contents. - Loading → loaded, loading → failed → retry, for the three pickers that fetch.
- Worktree header alignment at a narrow and a wide width.
- PR checkout failure keeps the picker open with the message shown.
- Remove the TuiCode-side picker code these no longer need.
Out of scope
- Open (
Ctrl+O) andPathPromptView: tui-style-guide#60. - Building the missing pieces in TuiCode instead of the library.
- Any new key.
Activity
a-team-app commentedon Oct 17, 2026
Blocked by #572: Same move onto PickerDialog, in the same views and helpers as #572
a-team-app commentedon Oct 17, 2026
Held as
blockeduntil a MentalDesk.Tui release letsPickerDialogtake rows after it opens (with loading and failed states), show a column header, and show an error while staying open. The draft issue for tui-style-guide is in the body, ready for you or that team's Lead to file. Remove the label once a release has it.a-team-app commentedon Oct 23, 2026
The
PickerDialogadditions this needs are up as a draft: mentaldesk/tui-style-guide#110 (rows that load, a column header, a pick that fails and stays open). Please review and release it. This task waits on that release and picks up from there.a-team-app commentedon Oct 23, 2026
Blocked by mentaldesk/tui-style-guide#110, until released: PickerDialog needs to load rows, show a header and stay open on a failed pick
GitHub can't link mentaldesk/tui-style-guide#110 as a dependency, so the wait is recorded here.