feat: rebuild desktop sync as linked server accounts, fix packaged plugin bundles and UI scaling

This commit is contained in:
LukeGus committed 2026-09-26 00:41:25 -05:00
1 parent 7c02daccf4
commit 6cd9a2846d
242 files changed
+39127 -8558

No files matched your search

+22
View File
@@ -0,0 +1,22 @@
import { useSyncExternalStore } from "react";
import { getSyncStatusSnapshot, subscribeSyncStatus } from "@/lib/sync-status";
/** The desktop's sync status, kept current while the component is mounted. */
export function useSyncStatus() {
return useSyncExternalStore(
subscribeSyncStatus,
getSyncStatusSnapshot,
() => null,
);
}
/** What needs the user's attention in Sync, for the rail badge. */
export function useSyncAttentionCount(): number | null {
const status = useSyncStatus();
if (!status?.linked) return null;
const count =
(status.conflicts ?? 0) +
(status.errors ?? 0) +
(status.status === "signed_out" ? 1 : 0);
return count || null;
}