feat(tui): wipe in first generated titles - #41903
Open
kitlangton wants to merge 1 commit into
Open
Conversation
kitlangton
force-pushed
the
tab-placeholders
branch
from
August 12, 2026 02:39
2dc1d21 to
b1ab999
Compare
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
The left-to-right title wipe removed in #40318 returns, gated and feathered: when a session's first real title arrives, it wipes in over the placeholder instead of popping.
Stacked on #41921 (dim placeholders), which supplies the placeholder predicate the gate uses.
Before / After
Before: the generated title replaces "Untitled session"/"New session" in a single frame. (And in the original pre-#40318 wipe: a hard splice — full-brightness new characters cut against full-brightness old ones, firing on every title change.)
After: the wipe fires only on the placeholder → real transition — the background generated-title moment. The outgoing title dims toward the background the moment the wipe starts, the new title reveals left-to-right behind a 3-cell feathered edge (freshly revealed characters brighten as the front passes), and the front decelerates on an ease-out cubic over 450 ms. Every other title change — user renames, persisted-title sync corrections, real → real updates — jumps immediately, which is what #40318 was fixing.
How
packages/tui/src/component/session-tabs.tsx—createTitleWipe, shared by both orientations:frontcut 0 → 1 (tweenwith ease-out cubic, 0.45 s). The gate lives in its effect: any transition that is not placeholder → real jumps tofront: 1with no outgoing title retained.partssplices incoming graphemes over outgoing ones per cell (padded with spaces where lengths differ, so a shorter incoming title erases the tail as the front passes).mix(index)returns a per-cell tint toward the background: the outgoing block sits at ~50% dim (deepening slightly as the wipe advances, with a fast ramp-in so the start doesn't flash), and theWIPE_FEATHERcells behind the front ramp freshly revealed characters from dim to full.characterColor/titleColorapplymixafter the existing glow and fade treatments, and the per-character render path is forced while a wipe is active.Flow
flowchart LR change["tab.title changes"] --> gate{"previous title was\na placeholder?"} gate -->|no| jump["jump: render new title immediately"] gate -->|yes| wipe["wipe: outgoing dims,\nfront reveals with feathered edge"] wipe --> settle["450ms ease-out → settled title"]Scope
session.renamedcarries no source), so the gate is prior-state based; a user manually titling an untitled session also wipes, which reads fine.Testing
bun typecheck(packages/tui) clean.bun run test(packages/tui): 647 tests, 0 fail.Demo
Storybook (
OPENCODE_STORY=session-tabs), vertical rail: two tabs open untitled (dim, italic — from #41921) and earn their titles on their first completed run, each wiping in with the dimmed-outgoing, feathered-edge treatment.feather-demo-final.mp4