aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/client/sync/index.ts
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-12-07 19:24:18 +0900
committernsfisis <nsfisis@gmail.com>2025-12-07 19:24:18 +0900
commit83be5ccd5d64c64f65c7efbfb9feb94ab0f75ce6 (patch)
treecb880dd513112827f4f6132843b8949121c9167a /src/client/sync/index.ts
parent9632d70ea0d326ac0df4e9bffb7fb669013f0755 (diff)
downloadkioku-83be5ccd5d64c64f65c7efbfb9feb94ab0f75ce6.tar.gz
kioku-83be5ccd5d64c64f65c7efbfb9feb94ab0f75ce6.tar.zst
kioku-83be5ccd5d64c64f65c7efbfb9feb94ab0f75ce6.zip
feat(client): add sync queue management for offline sync
Implement SyncQueue class to manage pending changes for offline sync: - Track unsynced decks, cards, and review logs from IndexedDB - Manage sync status (idle, syncing, error) with listener support - Persist last sync version and timestamp to localStorage - Provide methods to mark items as synced after push - Apply pulled changes from server to local database 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Diffstat (limited to 'src/client/sync/index.ts')
-rw-r--r--src/client/sync/index.ts9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/client/sync/index.ts b/src/client/sync/index.ts
new file mode 100644
index 0000000..6f75a29
--- /dev/null
+++ b/src/client/sync/index.ts
@@ -0,0 +1,9 @@
+export {
+ SyncQueue,
+ SyncStatus,
+ syncQueue,
+ type PendingChanges,
+ type SyncQueueListener,
+ type SyncQueueState,
+ type SyncStatusType,
+} from "./queue";