Skip to content

Add optional local data cleanup when disconnecting - #116

Merged
TrySound merged 11 commits into
mainfrom
feat/disconnect-cleanup
Nov 11, 2026
Merged

TrySound merged 11 commits into
mainfrom
feat/disconnect-cleanup

Conversation

@TrySound

@TrySound TrySound commented Nov 11, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Disconnect confirmation separates the title “Disconnect from server”, an explanatory question about clearing device data, and the default-off left switch “Clear data on device”. Submission uses a native method="dialog" form.
  • Optional Cache.clear() deletes the selected account’s OPFS cache and empties its existing reactive stores in place. Remembered account identity, preferences, other accounts and server data are unchanged.
  • Optional deletion is best-effort: failures are caught silently in Settings, without an error message or retry UI.
  • Keep existing connection, playback and artwork lifecycles unchanged: no forced media purging, reload, custom focus management or global cleanup effects.
  • Reuse the existing mobile bottom drawer and desktop dialog patterns with shared content. Regular dialogs match the existing card corner treatment; no responsive-padding changes.

Validation

  • pnpm test: 1,199 tests passed
  • pnpm check: passed
  • pnpm build: passed (existing debugName warning)
  • Settings/Downloads browser suites against production preview: 21 passed
  • Consolidated coverage includes account-scoped deletion, late-write safety, failure/reuse, same/different-account reconnects with fresh downloads/playback, and queued download restoration.
  • Independent scope/test-consolidation review approved
  • git diff --check: passed

Scope and limitations

  • No production changes to Playback, Covers, App or Auth, or to ordinary disconnect behavior.
  • Close other Libras tabs before clearing; cross-tab coordination is not implemented.
  • Existing audio/artwork resources may remain temporarily until normal lifecycle cleanup. Deletion failures may leave files on disk without a UI notification.
  • Browser validation used Chromium; Safari and screen-reader checks were not performed.

@TrySound
TrySound merged commit 04fb922 into main Nov 11, 2026
1 check passed
@TrySound
TrySound deleted the feat/disconnect-cleanup branch November 11, 2026 23:03
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