desktop: finish the UI, and fix what was quietly broken in it - #8
Merged
Conversation
The renderer looked unfinished rather than broken, so this is mostly polish -- but four things in it were genuinely wrong, and they are the reason it read that way. Actual defects: - DialogFooter hardcoded `-mx-4 -mb-4` to cancel DialogContent's `p-4`. Both dialogs here pass `p-0`, so the footer hung 16px past the rounded corner as a detached bar. The bleed now follows a `--dialog-pad` var. - DialogContent ended its class list with `sm:max-w-sm`, which beat every `max-w-*` a caller passed: the mirror preview asked for max-w-2xl and rendered at 384px, squashing its four-column summary and delete list. - The progress bar styled the Progress ROOT (a flex wrapper) instead of the track, and recoloured `[&>div]` on finish -- the track, not the fill -- so a completed transfer turned the whole bar green whatever the percentage said. Both are addressed by slot now. - formatDate used toISOString(), so every mtime in both panes was shown in UTC while the user's clock said something else. Finishing touches: - The Settings gear had no onClick at all. It now opens the two actions that already exist behind the bridge, plus the project link. - "Hidden" was a raw <input type=checkbox> next to shadcn fields, while ui/checkbox.tsx sat unused. - Each pane spent four full-width toolbars on chrome before showing a file; the path, filter and hidden toggle are one row now. - The idle transfer band was 74px of "Nothing transferring" -- the tallest thing in the window, and there to say nothing was happening. It is a slim strip that names the route and whether deletes are armed. - The rail stacked a 64px button on a 50px button with two corner radii and truncated its labels mid-word. One width, one radius, and "Sync to" in front of the name so the pair stop reading as a destination picker. - Light theme painted white panes on a white window, so a pane was a hairline around nothing. The ground steps back and panels have depth. - Panes answer to the keyboard: arrows, PageUp/Down, Home/End, Enter to open, Backspace for the parent, shift for a range, ctrl/cmd-A. - Loading is skeleton rows; empty, no-match and error each have a state instead of one line of grey text. - The mirror confirm opens focused on Cancel rather than on the trust checkbox, and its delete list no longer reserves 210px for two files. Also drops the third-party analytics tag from the renderer. The shell's own CSP (`script-src 'self'`) blocks it outright, so it never reported anything -- all it did was make a desktop file transfer tool look like it phones home. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TA4kaFusnS896fmoeWHiAa
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.
The desktop renderer looked unfinished rather than broken. Most of this is polish, but four things in it were genuinely wrong, and they are a large part of why it read that way.
Verified by building the renderer and driving it in a browser with a mocked
window.diskpushbridge, screenshotting every state: both themes, the two dialogs, an in-flight transfer, the empty/no-match/error states, and the app's 960x600 minimum window.Actual defects
DialogFooterhardcoded-mx-4 -mb-4to cancelDialogContent'sp-4. Both dialogs here passp-0, so the footer hung 16px past the rounded corner as a detached bar.--dialog-padvar.DialogContentended its class list withsm:max-w-sm, beating everymax-w-*a caller passed. The mirror preview asked formax-w-2xland rendered at 384px.Progressroot (a flex wrapper) rather than the track, and recoloured[&>div]on finish — the track, not the fill — so a finished transfer turned the whole bar green whatever the percentage said.data-slot.formatDateusedtoISOString(), so every mtime in both panes rendered in UTC while the user's clock said something else.Finishing touches
onClickat all. It now opens the two actions already behind the bridge (add a server, import~/.ssh/config) plus the project link.<input type="checkbox">next to shadcn fields, whileui/checkbox.tsxsat unused.to nyc-web…). One width, one radius, and "Sync to" in front of the name so the pair stop reading as a destination picker rather than the buttons that start the transfer.One removal worth flagging
The renderer loaded a third-party analytics tag. The shell's own CSP (
script-src 'self', set inelectron/main/index.ts) blocks it outright, so it never reported anything — all it did was make a desktop file transfer tool look like it phones home. Removed; say the word if it was there for a reason I'm not seeing.Checks
pnpm typecheckclean (renderer and electron configs)pnpm test— 243 passed, 22 filespnpm build:rendererclean🤖 Generated with Claude Code
https://claude.ai/code/session_01TA4kaFusnS896fmoeWHiAa