fix(tui): 没入→在席ズームアウト直後の Esc で元のタブへ再アタッチ#433
Merged
Merged
Conversation
没入中のエージェントから Ctrl-O a(Ctrl-T)で在席へズームアウトし 直後に Esc を押すと、在席に留まって(ライブなペインのプレビュー上で 停止して)しまい、操作元のタブへ戻れなかった。 在席が「ライブなペインからのズームアウト」で開かれたときに 1 回限りの 再アタッチ用フラグ(focus_return_attach)を立て、直後の Esc はその ペインへ再アタッチ(没入へ復帰=直前のタブへ戻る)するようにした。 間に他のキーを押すとフラグは解除され、Esc は従来どおり一段戻る。 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
📊 Test Coverage
🎉✨ パーフェクト!全ファイル Lines カバレッジ 100% を達成しました 🏆🐰 |
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.
目的
没入(Attached)中のエージェントから在席(Focus)へズームアウトし、直後に
Escを押すと在席に留まってしまうバグを修正する。再現手順:
Ctrl-O a(Ctrl-T相当 / ToFocus)で在席へズームアウトEsc期待: 操作元のタブへ戻る(再アタッチ)。
実際: 在席のまま、ライブなペインのプレビュー上で停止していた(
focus_discard_new_tabが「+ new」を破棄してペインタブのプレビューへ移るだけ)。変更内容
HomeStateに 1 回限りの再アタッチ用フラグfocus_return_attachを追加。PaneExit::ToFocus)でこのフラグを立てる(arm_focus_return_attach)。Escハンドラで、フラグが立っていればそのペインへ再アタッチ(没入へ復帰=直前のタブへ戻る)。focus_discard_new_tabより先に判定するため、ライブなタブストリップが再公開されていても再アタッチが優先される。Esc以外のキーを処理した時点(clear_focus_return_attach)と、在席に通常入る経路(enter_focus_surface)で解除する。これによりtで在席を開いた場合など、ズームアウト由来でない経路のEscは従来どおり一段戻る。document/design/05-home.mdのモード遷移・在席のEsc説明を更新。テスト・確認方法
cargo fmt/cargo clippy --all-targets -- -D warnings/cargo test(全 2222 件パス)。attached::ctrl_t_then_esc_re_attaches_to_the_zoomed_out_pane— ライブなタブストリップを再公開する本番同等の条件で、ズームアウト直後のEscがペインへ再アタッチすることを検証(順序保証込み)。attached::ctrl_t_in_the_pane_zooms_out_to_focus— ToFocus 自体は再アタッチしないこと+他キーで再アタッチarming が解除されることを検証。focus_menu::focus_esc_on_the_new_tab_over_panes_steps_back_onto_the_pane— arming を解除した「+ new」over panes のEsc(従来のプレビューへ戻る経路)を引き続き検証。run_full_tabs(カスタムtab_op)を追加。🤖 Generated with Claude Code