feat(export): fast accurate content session counts on cards

This commit is contained in:
tisonhuang committed 2026-03-04 21:19:10 +08:00
1 parent f0f70def8c
commit b6878aefd6
7 files changed
+721 -5

No files matched your search

+22
View File
@@ -113,6 +113,28 @@ export interface ElectronAPI {
counts?: Record<string, number>
error?: string
}>
getExportContentSessionCounts: (options?: {
triggerRefresh?: boolean
forceRefresh?: boolean
}) => Promise<{
success: boolean
data?: {
totalSessions: number
textSessions: number
voiceSessions: number
imageSessions: number
videoSessions: number
emojiSessions: number
pendingMediaSessions: number
updatedAt: number
refreshing: boolean
}
error?: string
}>
refreshExportContentSessionCounts: (options?: { forceRefresh?: boolean }) => Promise<{
success: boolean
error?: string
}>
enrichSessionsContactInfo: (usernames: string[]) => Promise<{
success: boolean
contacts?: Record<string, { displayName?: string; avatarUrl?: string }>