feat: add presence-gated Expo push notifications

This commit is contained in:
Mohamed Boudra
2026-02-03 12:59:00 +07:00
parent ad632cb3bd
commit af89de1237
7 changed files with 332 additions and 122 deletions
@@ -13,6 +13,7 @@ import { useMutation } from "@tanstack/react-query";
import { useDaemonClient } from "@/hooks/use-daemon-client";
import { useAudioPlayer } from "@/hooks/use-audio-player";
import { useClientActivity } from "@/hooks/use-client-activity";
import { usePushTokenRegistration } from "@/hooks/use-push-token-registration";
import {
applyStreamEvent,
generateMessageId,
@@ -388,6 +389,7 @@ export function SessionProvider({
// Client activity tracking (heartbeat, push token registration)
useClientActivity({ client, focusedAgentId });
usePushTokenRegistration({ client, serverId });
// State for voice detection flags (will be set by RealtimeContext)
const isDetectingRef = useRef(false);