Scope folder realtime refreshes by device

This commit is contained in:
kris
2026-04-10 12:55:43 +08:00
parent d1e5a1ac5e
commit 0cba837ed3
11 changed files with 357 additions and 9 deletions

View File

@@ -262,11 +262,15 @@ export function RealtimeRefresh({
events,
projectId,
projectIds,
deviceId,
deviceIds,
conversationUpdatedNotes,
}: {
events: BossEventName[];
projectId?: string;
projectIds?: string[];
deviceId?: string;
deviceIds?: string[];
conversationUpdatedNotes?: string[];
}) {
const router = useRouter();
@@ -291,6 +295,8 @@ export function RealtimeRefresh({
eventData,
projectId,
projectIds,
deviceId,
deviceIds,
conversationUpdatedNotes,
})) {
return;
@@ -326,7 +332,7 @@ export function RealtimeRefresh({
cancelScheduledRefresh(throttleState);
source.close();
};
}, [conversationUpdatedNotes, events, projectId, projectIds, router]);
}, [conversationUpdatedNotes, deviceId, deviceIds, events, projectId, projectIds, router]);
return null;
}