Skip to content

feat(sync-menu): sync dialog progress, resilient auto-connect, forced badge & teardown fixes#8

Open
x-limitless-x wants to merge 1 commit into
mainfrom
feat/sync-menu
Open

feat(sync-menu): sync dialog progress, resilient auto-connect, forced badge & teardown fixes#8
x-limitless-x wants to merge 1 commit into
mainfrom
feat/sync-menu

Conversation

@x-limitless-x

Copy link
Copy Markdown
Collaborator

Split out from feat/media-activity-monitoring so the Sync Media dialog work is reviewable on its own.

Changes

  • Determinate progress barprocessed / total across all servers in the Sync dialog.
  • Fix "Connecting to active sync…" hang — the dialog fetches sync status fresh on open instead of relying on a cached SWR onSuccess that never fired on reopen.
  • "Forced refresh" badge — shows when a run bypassed the hash-skip optimization; the server reports forced via sync-status so it survives auto-connect.
  • Dialog teardown fix — the Sync dialog is now always-mounted and driven by isOpen. Conditionally unmounting a Headless UI Dialog while open stranded the page-wide pointer-events lock and made the app unclickable until reload.
  • fetchProcesses hardening — per-server timeout + webhook auth header + concurrent fetch, so the Active Processes endpoint can't hang or 401.
  • "Close" label while connecting/syncing (closes the dialog; the sync keeps running in the background).

Files

  • src/components/Admin/SyncMediaPopup.js
  • src/components/Admin/OverviewPage.js
  • src/components/Admin/Media/SyncButton.js
  • src/utils/server_track_processes.js
  • src/utils/sync.js
  • src/utils/sync/core/events.ts
  • src/app/api/authenticated/[...admin]/route.js

…, dialog teardown

- Determinate progress bar with processed/total across servers

- Fix 'Connecting to active sync' hang: fetch status fresh on open instead of a cached SWR onSuccess that never fired on reopen

- 'Forced refresh' badge when a run bypasses hash-skip (server reports forced via sync-status so it survives auto-connect)

- Always-mount the dialog so Headless UI runs its close teardown (conditional unmount stranded the page-wide pointer-events lock)

- Harden fetchProcesses: per-server timeout + webhook auth + concurrent fetch
@x-limitless-x x-limitless-x self-assigned this Jul 2, 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