feat(tabs): per-session independent Terminal instances#77
Merged
Conversation
セッションごとに独立した Terminal + FitAddon + PTY を持つアーキテクチャに変更。 セッション切り替え時に PTY を kill/restart せず、コンテナの show/hide で切り替え。 各セッションのプロセスが独立して生存し続ける。 - SessionState interface: terminal, fitAddon, containerEl, ptyId, unlisten per session - TabState: sessions Map + activeSessionId + terminalAreaEl (replaces single terminal) - createSessionTerminal / destroySessionTerminal / switchSessionTerminal helpers - sessions.ts: onSessionCreate / onSessionDelete callbacks - CSS: .terminal-area parent container for per-session .terminal-container divs - closeTab: kills ALL session PTYs and disposes ALL terminals - Restored sessions from persistence get terminals created on-demand Refs #76 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This was referenced Apr 13, 2026
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.
Refs #76
セッションごとに独立した Terminal + PTY インスタンスを持つアーキテクチャに変更。
セッション切り替え時に PTY を kill せず、コンテナの show/hide で切り替えることで、各セッションのプロセスが生存し続ける。
SessionStateインターフェース追加(terminal, fitAddon, containerEl, ptyId, unlisten をセッション単位で保持)TabStateから単一 terminal/ptyId を削除し、sessions: Map<string, SessionState>+activeSessionId+terminalAreaElに置換createSessionTerminal/destroySessionTerminal/switchSessionTerminalヘルパー追加sessions.tsにonSessionCreate/onSessionDeleteコールバック追加.terminal-area親コンテナを追加、セッション単位の.terminal-containerはその子要素closeTabは全セッションの PTY kill + Terminal dispose を実行