Give the usage bars a line of their own, always
Squeezing the 5h/7d group onto line one was what cost the reset times and the pace figure at laptop width, and it made the layout jump between one and two lines as the branch name or the cost changed width. Line two is now the group's own at every terminal size, so both timestamps and the burn rate fit; the ladder only starts giving things up below ~80 columns. The bars also survive down to 35 columns now rather than being dropped below 68, since a line of their own is all they need. Every rung of the ladder is fit-checked, the last one included: with the floor that low, a percentage the API reports in more digits than anyone expects would otherwise have overflowed the line rather than dropped the group. The two timestamps still cost ~10 subprocesses to format on a line that redraws per keystroke, so that is skipped when line two provably cannot show them -- an under-estimate, so the fit check stays the decider. With nothing left to squeeze, WRAP_NARROW, the wrap band and the split tier go: line one is the full tier down to 150, wide to 68, then narrow. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
2a785a55a7
commit
ab96dfc52a
7 changed files with 148 additions and 155 deletions
|
|
@ -82,8 +82,10 @@ echo "Fallbacks and tiers:"
|
|||
has true "" "◆ thinking" 200 "absent effort falls back to the old label"
|
||||
has true garbage "◆ thinking" 200 "an unrecognised level falls back rather than widening the line"
|
||||
has true high "◆ high" 120 "the label survives the wide tier"
|
||||
# The split tier (76-99) is unreachable while WRAP_NARROW=true -- that band is
|
||||
# overridden to wide and wrapped -- so only narrow is asserted here.
|
||||
# Below 68 columns the narrow tier drops the segment entirely; between there
|
||||
# and 100 the compact tier keeps the label, since the usage group has moved off
|
||||
# line one and left room for it.
|
||||
has true high "◆ high" 85 "the label survives the compact tier"
|
||||
lacks true high "◆" 60 "narrow tier hides the segment"
|
||||
|
||||
echo
|
||||
|
|
|
|||
Loading…
Reference in a new issue