From 186f5282d89ee2659e207ed9eec02b58b57053ee Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 7 Sep 2025 12:02:09 +0000 Subject: [PATCH 1/3] Initial plan From 01da58a737c7015988327029f4f6ef8c0d727ebc Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 7 Sep 2025 12:10:46 +0000 Subject: [PATCH 2/3] Add mic button to Host panel header with toggle functionality Co-authored-by: acdc-digital <127530566+acdc-digital@users.noreply.github.com> --- smnb/app/dashboard/studio/host/Host.tsx | 13 ++- smnb/lib/stores/host/hostAgentStore.ts | 18 ++++ test-host.html | 136 ++++++++++++++++++++++++ 3 files changed, 165 insertions(+), 2 deletions(-) create mode 100644 test-host.html diff --git a/smnb/app/dashboard/studio/host/Host.tsx b/smnb/app/dashboard/studio/host/Host.tsx index 5527687..5233971 100644 --- a/smnb/app/dashboard/studio/host/Host.tsx +++ b/smnb/app/dashboard/studio/host/Host.tsx @@ -14,7 +14,7 @@ import React, { useEffect } from "react"; import { WaterfallNarration } from "@/components/host/WaterfallNarration"; import { useHostAgentStore } from "@/lib/stores/host/hostAgentStore"; -import { Settings } from 'lucide-react'; +import { Settings, Mic, MicOff } from 'lucide-react'; export default function Host() { const { @@ -25,8 +25,10 @@ export default function Host() { nextStoryCountdown, isGenerating, stats, + isMicActive, initializeHostAgent, - cleanup + cleanup, + toggleMic } = useHostAgentStore(); // Initialize host agent on mount @@ -75,6 +77,13 @@ export default function Host() { > + diff --git a/smnb/lib/stores/host/hostAgentStore.ts b/smnb/lib/stores/host/hostAgentStore.ts index fb0535f..d2c72c5 100644 --- a/smnb/lib/stores/host/hostAgentStore.ts +++ b/smnb/lib/stores/host/hostAgentStore.ts @@ -85,6 +85,9 @@ interface HostAgentState { isActive: boolean; currentNarration: HostNarration | null; + // Audio control state + isMicActive: boolean; + // Streaming state isStreaming: boolean; streamingText: string; @@ -120,6 +123,9 @@ interface HostAgentState { processRedditPost: (post: EnhancedRedditPost) => Promise; processLiveFeedPost: (post: EnhancedRedditPost) => void; + // Audio control actions + toggleMic: () => void; + // Streaming actions addToQueue: () => void; processNextInQueue: () => void; @@ -145,6 +151,9 @@ export const useHostAgentStore = create((set, get) => ({ isActive: false, currentNarration: null, + // Audio control state + isMicActive: false, + // Streaming state isStreaming: false, streamingText: '', @@ -543,5 +552,14 @@ export const useHostAgentStore = create((set, get) => ({ })); console.log('✅ Complete host agent state reset completed'); + }, + + // Toggle mic active state + toggleMic: () => { + set((state) => { + const newMicState = !state.isMicActive; + console.log(`🎤 HOST: Mic ${newMicState ? 'activated' : 'deactivated'}`); + return { isMicActive: newMicState }; + }); } })); diff --git a/test-host.html b/test-host.html new file mode 100644 index 0000000..e6c8e9a --- /dev/null +++ b/test-host.html @@ -0,0 +1,136 @@ + + + + + + Host Component Test + + + +
+
+
+ Next: -s +
+
+
+ Offline + + +
+
+
+

Host Panel Content (WaterfallNarration component would go here)

+

Click the mic button to test the toggle functionality

+
+
+ + + + \ No newline at end of file From 1cc191b33b71354f86cea093e7f2a7df676b3937 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 7 Sep 2025 12:11:05 +0000 Subject: [PATCH 3/3] Remove test file from repository Co-authored-by: acdc-digital <127530566+acdc-digital@users.noreply.github.com> --- test-host.html | 136 ------------------------------------------------- 1 file changed, 136 deletions(-) delete mode 100644 test-host.html diff --git a/test-host.html b/test-host.html deleted file mode 100644 index e6c8e9a..0000000 --- a/test-host.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - Host Component Test - - - -
-
-
- Next: -s -
-
-
- Offline - - -
-
-
-

Host Panel Content (WaterfallNarration component would go here)

-

Click the mic button to test the toggle functionality

-
-
- - - - \ No newline at end of file