Repository navigation
fix(ui): one long model id no longer squeezes every picker row's name (#859) - #906
Merged
Merged
Conversation
…#859) The search picker padded every id to the longest one, so a single 92-cell id pushed every name past fzf's window, and a match typed in a name scrolled the row sideways until only the id's tail showed. Now only ids wider than the column are cut, each to a head…tail form that still parts it from every other id; the column stays within half the terminal unless no cut can part the ids (they differ only in length), fzf runs with --no-hscroll, and the receipt echoes the whole chosen id. When only a head and a tail of its own fits each of many long ids, an id that differs from another by a character also keeps that character in sight, so it never differs only in where its "…" falls. A gateway can list one model on many rows. Those rows now count once when the cut decides what tells the ids apart and where their first difference is: counted per row, one duplicated variant outvoted a whole distinct family, widened the column until the short model's name left the window, and made two ids that only a length tells apart read alike. The ids an uncut column shows whole count when a cut keeps what tells the ids apart, and a head and a tail are taken in cells: beside its 33-cell "v1" sibling, a 92-cell CJK id no longer loses the "v2" that tells the two apart, and the name beside a short id stays in sight. The real-fzf test clears FZF_DEFAULT_OPTS and FZF_DEFAULT_OPTS_FILE as the production call does, so a person's own fzf defaults cannot change what it reads. Continues #385 Closes #859 Co-Authored-By: Claude Code <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #859
The search picker padded every id to the longest one, so a single 92-cell
id pushed every name past fzf's window, and a match typed in a name
scrolled the row sideways until only the id's tail showed. Now only ids
wider than the column are cut, each to a head…tail form that still parts
it from every other id; the column stays within half the terminal unless
no cut can part the ids (they differ only in length), fzf runs with
--no-hscroll, and the receipt echoes the whole chosen id.
When only a head and a tail of its own fits each of many long ids, an id
that differs from another by a character also keeps that character in
sight, so it never differs only in where its "…" falls.
A gateway can list one model on many rows. Those rows now count once when
the cut decides what tells the ids apart and where their first difference
is: counted per row, one duplicated variant outvoted a whole distinct
family, widened the column until the short model's name left the window,
and made two ids that only a length tells apart read alike.
The ids an uncut column shows whole count when a cut keeps what tells the
ids apart, and a head and a tail are taken in cells: beside its 33-cell
"v1" sibling, a 92-cell CJK id no longer loses the "v2" that tells the
two apart, and the name beside a short id stays in sight. The real-fzf
test clears FZF_DEFAULT_OPTS and FZF_DEFAULT_OPTS_FILE as the production
call does, so a person's own fzf defaults cannot change what it reads.
Continues #385
Closes #859
Co-Authored-By: Claude Code noreply@anthropic.com