Repository navigation
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The clock is not paused during shell and suspend terminal handoffs, so subsequent ticks incorrectly count time spent away and jump the spinner phase.
1 open issue
What changed in this PR
This PR moves visual animations across the full-screen TUI, lean TUI, and board from tick counters to elapsed-time sampling, making animation speed independent of refresh cadence.
Changes:
- Centralizes animation durations and progress helpers, excluding idle time from the shared clock.
- Migrates spinners, transfer rails, recording dots, and transcript slack to elapsed-time updates.
- Adds timing tests, package documentation, and a linter rule against tick-driven visuals.
| File | Description |
|---|---|
pkg/tui/tui.go |
Connects recording editors to shared animation ticks. |
pkg/tui/components/spinner/spinner.go |
Samples the text highlight sweep by elapsed time. |
pkg/tui/components/spinner/spinner_test.go |
Tests sweep positions and dwell boundaries. |
pkg/tui/components/sidebar/sidebar.go |
Converts transfer rail motion to elapsed time. |
pkg/tui/components/sidebar/agent_transfer_test.go |
Tests rails using accepted runtime ticks. |
pkg/tui/components/sidebar/agent_panel_test.go |
Uses a deterministic animation scheduler. |
pkg/tui/components/reasoningblock/reasoningblock.go |
Uses shared progress calculation for tool fades. |
pkg/tui/components/messages/slack_test.go |
Tests elapsed-time slack decay and cleanup. |
pkg/tui/components/messages/messages.go |
Decays transcript slack by elapsed duration. |
pkg/tui/components/editor/recording_animation_test.go |
Tests recording dots, pause behavior, and cleanup. |
pkg/tui/components/editor/editor.go |
Moves recording dots onto the shared runtime. |
pkg/tui/animation/transition.go |
Adds reusable elapsed-time progress calculation. |
pkg/tui/animation/transition_test.go |
Tests irregular samples, pauses, and idle intervals. |
pkg/tui/animation/spinners.go |
Clamps negative elapsed time before calculating steps. |
pkg/tui/animation/durations.go |
Defines shared durations for migrated effects. |
pkg/tui/animation/doc.go |
Documents animation clocks and timer exemptions. |
pkg/tui/animation/coordinator.go |
Clears the elapsed baseline when subscriptions become idle. |
pkg/leantui/view.go |
Passes elapsed animation time into screen rendering. |
pkg/leantui/ui/transcript.go |
Uses elapsed time for live tools and working indicators. |
pkg/leantui/ui/tool.go |
Creates tool snapshots from elapsed duration. |
pkg/leantui/ui/tool_test.go |
Updates tool rendering tests to duration inputs. |
pkg/leantui/ui/screen.go |
Propagates elapsed time through screen rendering. |
pkg/leantui/tool_test.go |
Updates snapshot and cache tests to duration inputs. |
pkg/leantui/leantui.go |
Accumulates spinner time while busy UI is active. |
pkg/leantui/animation_test.go |
Tests active-time sampling and idle exclusion. |
pkg/board/tui/view.go |
Renders busy-card glyphs from the animation clock. |
pkg/board/tui/tui.go |
Adds runtime subscriptions and attach pause/resume handling. |
pkg/board/tui/animation_test.go |
Tests board spinner timing and idle exclusion. |
lint/tui_animation_duration.go |
Detects tick-based visual counters and legacy frame reads. |
lint/tui_animation_duration_test.go |
Tests detection and exempt timer patterns. |
lint/registrations_test.go |
Verifies registration of the new rule. |
lint/main.go |
Registers the animation-duration linter rule. |
Review effort: Balanced
53058d8 to
bd16a16
Compare
aheritier
left a comment
There was a problem hiding this comment.
Thanks for moving these effects off tick counts. The board now excludes time spent away from the terminal, but the full-screen TUI still charges that time to the newly migrated animations.
Prior threads: #4652813108 is addressed. The board pauses before suspend, resumes when Bubble Tea returns, and handles both successful and failed shell exits.
|
Please mark this PR ready for review once you have addressed the review feedback. |
bd16a16 to
da3dacc
Compare
da3dacc to
759fdad
Compare
|
👋 This PR has merge conflicts with the base branch. Please rebase or merge the latest base branch and resolve them. I've moved it to draft and added |
Share durations and easing across terminal UIs, preserve discrete effect pacing at different redraw cadences, and flag tick-counted visual progress in the project linter. Signed-off-by: Christopher Petito <chrisjpetito@gmail.com>
759fdad to
fbfbf20
Compare

Consolidate usage of duration based animations and easing effects across all docker-agent surfaces, and add a linter rule to try and catch raw tick-based animations in the future