(sessionId: string, title: string)
| 502 | }, |
| 503 | |
| 504 | setSessionTitle(sessionId: string, title: string): void { |
| 505 | const info = sessionDisplayInfo.get(sessionId) |
| 506 | if (!info) return |
| 507 | info.title = title |
| 508 | // Guard against reconnecting/failed — renderStatusLine clears then returns |
| 509 | // early for those states, which would erase the spinner/error. |
| 510 | if (currentState === 'reconnecting' || currentState === 'failed') return |
| 511 | if (sessionMax === 1) { |
| 512 | // Single-session: show title in the main status line too. |
| 513 | currentState = 'titled' |
| 514 | currentStateText = truncatePrompt(title, 40) |
| 515 | } |
| 516 | renderStatusLine() |
| 517 | }, |
| 518 | |
| 519 | removeSession(sessionId: string): void { |
| 520 | sessionDisplayInfo.delete(sessionId) |
nothing calls this directly
no test coverage detected