fix: reduce recap decoy churn under tmux#2
Open
jms830 wants to merge 1 commit into
Open
Conversation
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.
What
Reduces the decoy-row workaround inside tmux/screen:
bumpDecoy()on submit/input so vertical shifts still get a changed sentinel row;render()when card height/history length changes while inside tmux/screen.Outside multiplexers, behavior remains unchanged.
Why
The current widget intentionally changes the hidden decoy row every render so pi-tui must repaint all rows below the recap card. That helps avoid ghost borders, but inside tmux/screen the renderer has no destructive-clear/reflow semantics for already-committed scrollback. During animation/ticking, the forced repaint of every lower row gets committed into scrollback as mid-state frames.
Observed in tmux 3.5a: repeated recap cards stacked in scrollback and progressive command rows like:
Those artifacts are the lower rows being repainted every tick, not real shell history.
This keeps the decoy's original purpose for true vertical shifts, but stops continuous below-widget churn in multiplexers.
Testing
index.ts,ui/status-widget.ts, andui/status-widget.jswithBun.Transpiler.patchedDependencieson an omp/tmux setup and verified it persists throughbun install.