fix(tui): name deleted session in toast - #39768
Merged
Merged
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
Name the deleted session in the TUI toast introduced by #39750.
Before:
The current session was deletedAfter:
Session "OpenCode Drive" was deletedHow
Retain the last loaded active session ID and title before the deletion event removes it from the data store. The existing
session.deletedhandler uses that retained title, with the generic text as a fallback if the session was never loaded.The cache updates independently of terminal-title preferences, so disabling terminal window titles does not affect the toast.
Testing
bun typecheckinpackages/tuibun run testinpackages/tui(573 passed, 5 skipped)v1.4.1with required protocol negotiation: deleted the active simulated session, assertedSession "OpenCode Drive" was deleted, and verified zero sessions remainedDemo
recording-70757955-bbf6-4884-8c3b-622a6172d7bd.mp4