Skip to content

Collapse push and pull into one Sync action with the designed dialog - #4447

Draft
shaunandrews wants to merge 1 commit into
stu-2162-header-replaces-dropdownfrom
stu-2162-single-sync-button
Draft

Collapse push and pull into one Sync action with the designed dialog#4447
shaunandrews wants to merge 1 commit into
stu-2162-header-replaces-dropdownfrom
stu-2162-single-sync-button

Conversation

@shaunandrews

@shaunandrews shaunandrews commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Related issues

⚠️ Visual change: needs human review in light + dark mode.

How AI was used in this PR

Claude Code built and iterated on this live in the running app; verified with typecheck and the existing unit tests.

Proposed Changes

The header's two arrow buttons (Pull, Push) collapse into one primary "Sync" button that opens a single, designed dialog where everything about a sync is decided:

  • Destination — a picker of every connected WordPress.com site (identified by URL, since the Production/Staging label isn't always known), with its last-synced age.
  • Direction — a segmented Push / Pull control, with the consequence spelled out ("Replaces the live site with this one." / the reverse).
  • What to sync — a file tree that lazily browses the local site (push) or the latest remote backup (pull).

It drives the same push/pull mutations and the same file-tree connector methods #4377 exposes; nothing on the main-process/CLI side changes, and the ported selective-sync dialog is left verbatim — this header opens the designed dialog instead.

Also folds in a header layout fix that surfaced here: the chat header had a leftover flex spacer competing with the toolbar, so the actions landed mid-header instead of pinned right, and both host headers double-padded the toolbar's edge. The toolbar now owns its own edge padding and fills the header.

Testing Instructions

  1. Open a connected site → the header shows one Sync button (plus for Disconnect).
  2. Click Sync → confirm the destination picker (when >1 connection), the Push/Pull segmented control, the consequence line, and the file tree.
  3. Flip direction and confirm the tree re-roots (local for push, remote backup for pull) and the selection resets.
  4. Run a push and a pull; confirm both behave as before.
  5. From onboarding, connect a live site and confirm you land with the dialog open on Pull.
  6. Confirm the header actions sit hard-right in both the chat and site-overview headers.
  7. Both light and dark.

Pre-merge Checklist

  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.
  • I have added or updated tests to cover my changes, if applicable.
  • I have tested my changes in both light and dark mode.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@shaunandrews
shaunandrews force-pushed the stu-2162-single-sync-button branch from 1f7e4a4 to 9cf9a82 Compare August 4, 2026 23:26
@shaunandrews shaunandrews changed the title Collapse push and pull into one Sync action with an in-dialog direction switch Collapse push and pull into one Sync action with the designed dialog Aug 4, 2026
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