Skip to content

fix(desktop): one shared height for the remote file rows - #1331

Merged
huichen merged 4 commits into
mainfrom
dev-huichen
Oct 23, 2026
Merged

huichen merged 4 commits into
mainfrom
dev-huichen

Conversation

@huichen

@huichen huichen commented Oct 23, 2026 •

Copy link
Copy Markdown
Collaborator

What and why

Every row in the remote files panel took its height from its contents, so a folder row (no size label, no download button) sat noticeably shorter than the file rows beside it. Measured with the screenshot harness, the four rows came out at 33, 49, 49, 49px. This PR gives both row kinds one shared height floor so the panel reads as a single table, and keeps the floor on the row rather than on the controls so enlarged text still grows the row instead of clipping it.

Commits

  • fix(desktop): one row height in the remote files panel — the real change in this PR: min-h-10 (40px) on the row, the download icon button dropped to size-7, and vertical padding py-1.5 → py-1 so the floor governs the height. Adds a remote-files-rows screenshot scenario plus a folder in the demo data (the fixture previously held only files, which hid the difference).
  • fix(remote): keep send out of the composer while a run is still going — content-identical to what already landed on main as fix(remote): keep send out of the composer while a run is still going #1330, so it contributes no diff to this PR; it is listed only because it sits in the branch history.

Verification

  • vitest on src/features/remote-peer — 772 tests passed, including the new RemoteFilesPanel.test.tsx cases (folder and file rows share one row style; the download button is size-7).
  • tsc --noEmit and eslint clean.
  • Screenshot scenario remote-files-rows asserts every row's getBoundingClientRect().height is equal and that the download button does not stretch the row: it failed before the fix with the rows are not one height: 33,49 and reports 40px rows after it.

Notes

RemoteFilesDialog, the dialog form of the file list, has no test of its own. It reuses the same panel component, so the row-height behaviour carries over, but the dialog's own layout is not asserted.

Diff vs main

4 files, 67 insertions, 1 deletion (RemoteFilesPanel.tsx, RemoteFilesPanel.test.tsx, scripts/screenshots/scenarios.json, desktop/shot/mock/data.ts).

The remote composer handed Send back as soon as the field had text, while the
host answers one prompt at a time and refuses a second with 'This session is
still running; wait for it to finish or abort it first'. That refusal lands
after the prompt is written down, so the press became an error over a message
the reader meant to send.

Stop now replaces Send for as long as the run streams, whatever the field
holds -- the local composer's rule and the phone's, which both block sending
while a reply is in flight -- and Enter meets the same guard inside send(),
where the button and the key meet. A draft typed meanwhile stays in the field
and goes once the run settles.

The screenshot scenario that watches a streamed run now types a follow-up
mid-run and asserts the composer offers Stop and no Send; it fails with the
previous condition.
A folder row carries neither a size label nor a download control, so the
row's height was left to its contents and came out 33px beside file rows
of 49px: the panel read as a ragged column. Both kinds now share a 40px
floor, and a file row's download button is small enough (size-7) not to
set the row's height from outside it — while text scaling can still grow
a row rather than being clipped.

The demo listing gains a folder, since a listing of files alone could not
show the three row kinds the height has to keep in step, and a scenario
measures the rows: it caught 33,49 before the fix and reads 40px rows
after it.
@huichen huichen changed the title fix(desktop): one row height in the remote files panel fix(desktop): one shared height for the remote file rows Oct 23, 2026
@huichen
huichen merged commit 7834832 into main Oct 23, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant