Repository navigation
Description
Goal
The session view's header row follows the design: square status marker, server name as title, user@host:port in mono, the server's group as a badge, the pane switch as a segmented control with icons, Disconnect in the danger style and a "More actions" menu. The split between the panes gets the design's flat divider, and the terminal pane loses its padded frame.
Context
- Design reference: session header and pane area of
docs/design/angular/screens/Main.pnganddocs/design/angular/screens/DeskChat.png(desktop), pane tabs under the header indocs/design/angular/screens/MobTerminal.png(mobile). - Header
apps/smart-ssh-community/frontend/src/components/SessionView.tsx:372-447: server name, status and reconnect texts (:378-407), extension items (src/extensions/SessionHeaderItems.tsx), plain "Disconnect" (:443), "⋯" menu only in the narrow layout (:408-439), Reconnect inline on wide (:404).SessionViewreceives onlyserverNameandserverId(src/App.tsx:260-268);getServer(src/api/api.ts:358) returns host, port, username, groupId, tags (src/generated/ipc.ts:267),listGroups(api.ts:332) the group names. - Panes (wide): AI chat left (flex), right pane resizable and persisted (
:450-500, spec 0053 Part 2) with an internal Terminal | Files switch (:481-505, elevated-files marker:344,505-509); dividerw-1.5(:461-470); terminal wrapperp-2onsurface-sunken(:513). Narrow:TabsAI / Terminal / Files (:450-458). - Specs: 0007 (chat left, terminal right), 0020 §5.1 (Terminal | Files switch in the right area), 0053 Part 2 (resizable right pane), 0113 §4 (narrow session header with "⋯").
Requirements
- Header row (44 px, 1 px bottom rule):
StatusSquarefor the session status, server name intext-title,user@host:portin monofg-faint(loaded withgetServerfor remote servers; local pseudo-server shows its user and "this device"), group name as a neutralBadgewhen the server is in a group, status/reconnect texts and extension items as today. - Pane switch: segmented control with icons (
sparkAI,terminalTerminal,notes/folderFiles) in the header. Semantics stay as today: on wide screens the AI chat is always shown, Terminal and Files are exclusive in the right pane; the elevated-files marker stays on the Files segment. On narrow screens the AI / Terminal / Files tabs sit under the header as today, with icons and the foundation tab style (2 px accent rule). - "Disconnect" as a danger button; a "More actions" icon button (
more) with a menu on wide screens too, containing Reconnect (when available) and the entries the narrow menu has today. - Divider between the panes: 5 px
surface-sunkenstrip with a 1 px grip line; drag and keyboard resize and persistence unchanged. - Terminal and files panes are full-bleed (remove the
p-2frame; the terminal issue adds the inner padding insideTerminalView). - New strings in all 25 locales.
Acceptance Criteria
- The session header matches
docs/design/angular/screens/Main.png(marker, title,deploy@10.0.4.21:22-style line, group badge, segmented switch, Disconnect, More actions). - A server without a group shows no badge; the local pseudo-server shows its local marker and no host line error.
- Switching Terminal/Files from the header behaves as the old switch did, including the elevated-files marker; the AI chat stays visible on wide screens.
- The More actions menu offers Reconnect after a disconnect on wide screens; all actions are reachable by keyboard.
- Resizing the right pane by mouse and keyboard still works and persists.
- Narrow pane tabs show icons and the new tab style; spec 0113 §4 still holds (name and status visible, actions behind "⋯").
- Spec 0020 §5.1 mentions the switch in the session header.
- New strings exist in all 25 locales; colour guard passes; axe scan of the session view passes.
- Unit tests
SessionView.test.tsx,SessionView.narrow.test.tsx,extensions/SessionHeaderItems.test.tsxand e2enarrow-session.spec.ts,reconnect.spec.ts,app-shell-review.spec.ts(session parts) are updated. - Relevant automated tests pass
Technical Notes
- Loading the server details: one
getServercall per session view mount (and on server-updated events if the app already listens to them); do not block rendering of the panes. - Swapping pane sides, a fixed-width chat, hiding the AI pane and a persistent server sidebar next to the session are product decisions listed separately and not part of this issue.
Files: apps/smart-ssh-community/frontend/src/components/SessionView.tsx, apps/smart-ssh-community/frontend/src/components/SessionView.test.tsx, apps/smart-ssh-community/frontend/src/components/SessionView.narrow.test.tsx, apps/smart-ssh-community/frontend/src/locales/*/common.json (session), apps/smart-ssh-community/frontend/e2e/tests/narrow-session.spec.ts, reconnect.spec.ts, app-shell-review.spec.ts, docs/specs/0020-sftp-file-transfer.md
Spec impact: update 0020 (§5.1)
Related Work
- Part of the Angular redesign (docs/design/angular/). Blocked by: Redesign: title bar with logo and main navigation, session tabs with square status markers #1365 (titlebar-session-tabs) — shared shell e2e specs.
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
feat(frontend): session header with server details, pane switch and M…
fix(frontend): use a fieldset for the pane switch group (#1366)
fix(frontend): label the pane switch fieldset with aria-label (#1366)
smart-ssh-coder commentedon Nov 20, 2026
Implementation ready for review. PR #1413. Session header redesigned (status square, user@host:port, group badge, icon segmented pane switch, danger Disconnect, More actions menu with Reconnect, 5 px divider, narrow tabs with icons); strings in all locales, spec 0020 §5.1 and changelog updated. Vitest, lint and the full Playwright suite pass; CI green on PR #1413. No before/after screenshots were made.
smart-ssh-reviewer commentedon Nov 20, 2026
Review: 1. SessionView.tsx:402-403: the fixed 44 px header (h-11) still wraps its left cluster (flex-wrap). With a long server name the status square sits alone on a row at the top edge, and user@host:port drops onto the bottom rule (see app-shell-review captures shell-session-1280x800/800x560). Keep the cluster on one row (nowrap, shrink-0 square, truncating name and line), and extend the long-name e2e test to assert one row inside the header box. 2. SessionView.tsx:500-518: on wide screens the More actions menu is empty while the session is connected, which gives an empty role=menu. The requirement says the menu also contains the narrow menu's entries (Disconnect). Add Disconnect to the wide menu and fix the test 'has no Reconnect entry while connected'. 3. Spec 0107 §1.1/1.3/8.2-8.4 still describes a Reconnect button in the header. No spec describes the new header row (status square, user@host:port, 'this device' for local, group badge, More actions on wide). Update 0107, and describe the header in the session-view spec (e.g. 0017/0113).
fix(frontend): keep session header on one row, Disconnect in wide men…
2 remaining items
fix(frontend): show reconnect error in its own strip below the sessio…
smart-ssh-coder commentedon Nov 20, 2026
Implementation ready for review. PR #1413. Review fixes: reconnect error moved to its own strip below the session header (name keeps a min width), e2e assertion added to reconnect.spec for no overlap at both viewports; Spec 0017 4a corrected. Reconnect spec green in chromium+webkit, CI green.
smart-ssh-reviewer commentedon Nov 20, 2026
Needs maintainer: Question: How should the fixed 44 px session header handle status texts that do not fit on one line?
Context: This PR makes the session header a fixed 44 px row, as in Main.png. For three review rounds in a row, text in that row has overflowed it: round 1 the long server name, round 2 the reconnect error, and now the status texts. These are "Disconnected: ", "Reconnecting… (attempt n)" with Stop, and "Connection could not be restored.". At 800x560, losing the connection with "Connection reset by peer" and then giving up on auto-reconnect makes these texts wrap into 48-64 px blocks. The blocks cover the title bar tabs and the panes. A longer reason does the same even at 1280x800. Before this PR the header grew to fit. The rest of the PR is fine: reconnect error strip, spec 0017/0107/0020, menu, divider and tests. CI is green.
Options:
Recommendation: 1. It is the pattern the PR already uses for the reconnect error, keeps every text readable ("honest notices"), and keeps the design's 44 px header.
brokoskokoli commentedon Nov 21, 2026
option 1
smart-ssh-reviewer commentedon Nov 21, 2026
Review: 1. SessionView.tsx:412-433: implement the maintainer's decision (option 1). Move every status text out of the fixed 44 px header into the strip under it, where the reconnect error already is: the disconnect note 'Disconnected: ', the manual 'Reconnecting…', the auto-reconnect progress with Stop, and 'Connection could not be restored.'. The header keeps only the square, name, host line, badge, extension items and actions. Stop stays reachable by keyboard. Add an e2e assertion, modelled on reconnect.spec 'a failed reconnect shows the error', that these texts sit below the header and do not overlap the title bar or the panes at 1280x800 and 800x560. 2. Update spec 0017 §4a and spec 0107 §1.1/§8.3/§8.4 so they say these texts appear in the strip under the session header, not in the header ('Der Kopf zeigt …'). 3. SessionView.test.tsx:146 'keeps the header working when the server cannot be loaded' passes before the rejected getServer has settled. Wait for the rejection to be handled (waitFor getServer called + await act) before asserting that the line is absent.
fix(frontend): move session status texts into the strip under the hea…
smart-ssh-coder commentedon Nov 21, 2026
Implementation ready for review. PR #1413. Moved all session status texts from the fixed header into the strip below it, updated specs 0017/0107, added e2e layout assertions and fixed the racy unit test. CI green.
smart-ssh-reviewer commentedon Nov 21, 2026
Review passed – moving on to merge. Follow-up round: all three earlier findings are fixed. The status texts now sit in a strip under the fixed 44 px header (maintainer option 1), specs 0017/0107 are updated, and the load-failure unit test waits for the rejection (counter-proof run). reconnect.spec passed 140/140 with --repeat-each=5, the session vitest files passed 29/29, CI is green. Non-blocking: one outdated test name and an outdated PR body.
feat(frontend): session header with server details and pane switch (#…
smart-ssh-coordinator commentedon Nov 21, 2026
Merged and branch deleted: PR #1413 (squash) in develop