Skip to content

Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.

feat(desktop): open Settings at Voice chat from the call bar

leepokai5081aedca1d4
diff --git a/apps/desktop/src/renderer/views/ChatWindow.tsx b/apps/desktop/src/renderer/views/ChatWindow.tsx
index f2513fa9..7a836a7c 100644
--- a/apps/desktop/src/renderer/views/ChatWindow.tsx
+++ b/apps/desktop/src/renderer/views/ChatWindow.tsx
@@ -1,4 +1,4 @@
-import { useEffect, useMemo, useRef, useState, type ReactNode } from 'react'
+import { useCallback, useEffect, useMemo, useRef, useState, type ReactNode } from 'react'
import type { WindowCommand } from '@shared/ipc'
import { draftOf, isGroup, type Bot, type BotDraft } from '@shared/models'
import { CharacterAvatar } from '../components/Avatar'
@@ -23,6 +23,7 @@ import { SettingsView, type SettingsPage } from './settings/SettingsView'
import { ApprovalSheet } from './settings/ApprovalSheet'
import { UpdateNeededCard } from './UpdateNeededCard'
import { AccountWelcomeView } from './AccountWelcomeView'
+import { OpenVoiceSettings } from './call/CallView'
import { useTraySummary } from './tray-summary'
import { useSSHAttachments } from './settings/ssh-model'
import './chat-window.css'
@@ -159,6 +160,7 @@ function ChatSplitView() {
const [newSessionBot, setNewSessionBot] = useState<BotTarget | null>(null)
const [marketplace, setMarketplace] = useState<string | null>(null)
const [settings, setSettings] = useState<SettingsPage | null>(null)
+ const openVoiceSettings = useCallback(() => setSettings('voice'), [])
const [showAccount, setShowAccount] = useState(false)
const [windowSize, setWindowSize] = useState({ width: window.innerWidth, height: window.innerHeight })
const searchRef = useRef<HTMLInputElement>(null)
@@ -439,7 +441,10 @@ function ChatSplitView() {
)}
</aside>
<div className="sidebar-divider" onPointerDown={onDividerDown} onPointerMove={onDividerMove} onPointerUp={() => (dragStart.current = null)} role="separator" aria-label="Resize sidebar" aria-valuenow={width} />
- <main className="detail">{detail}</main>
+ <main className="detail">
+ {/* The call bar's settings open this window's Settings at Voice chat. */}
+ <OpenVoiceSettings.Provider value={openVoiceSettings}>{detail}</OpenVoiceSettings.Provider>
+ </main>
{showAccount ? (
<AccountPanelLayer
diff --git a/apps/desktop/src/renderer/views/call/CallView.tsx b/apps/desktop/src/renderer/views/call/CallView.tsx
index 9a1ee33a..a8f2275e 100644
--- a/apps/desktop/src/renderer/views/call/CallView.tsx
+++ b/apps/desktop/src/renderer/views/call/CallView.tsx
@@ -1,5 +1,5 @@
import { isWorking } from '@shared/models'
-import { useEffect, useRef, useState } from 'react'
+import { createContext, useContext, useEffect, useRef, useState } from 'react'
import { BotAvatar } from '../../components/Avatar'
import { Icon } from '../../components/Icon'
import { Sheet } from '../../components/Overlay'
@@ -9,6 +9,12 @@ import { avatarColor, useDark, useReduceMotion, withAlpha } from '../../lib/them
import { useStore } from '../../store/context'
import { VoiceChatSettingsView } from '../settings/VoiceChatSettingsView'
import { CallOperator } from './call-operator'
+
+/**
+ * Opens the window's own Settings at Voice chat; without it (no Settings screen around) the
+ * call bar shows the voice settings in their own sheet.
+ */
+export const OpenVoiceSettings = createContext<(() => void) | null>(null)
import { CloudSpeechEngine } from './CloudSpeechEngine'
import { GeminiLiveEngine } from './GeminiLiveEngine'
import { OnDeviceEngine } from './OnDeviceEngine'
@@ -36,6 +42,7 @@ export function CallView({ botId, onSpeaking, interrupt, onEnd }: {
/** No engine could start at all. */
const [blocked, setBlocked] = useState<string | null>(null)
const [settings, setSettings] = useState(false)
+ const openVoiceSettings = useContext(OpenVoiceSettings)
const engine = useRef<VoiceEngine | null>(null)
/** When the current cloud engine started, for this month's minutes. */
const cloudStartedAt = useRef<number | null>(null)
@@ -188,7 +195,7 @@ export function CallView({ botId, onSpeaking, interrupt, onEnd }: {
{providerName(session.provider)}
</span>
) : null}
- <button className="call-round" title="Call settings" aria-label="Call settings" onClick={() => setSettings(true)}>
+ <button className="call-round" title="Call settings" aria-label="Call settings" onClick={() => (openVoiceSettings ? openVoiceSettings() : setSettings(true))}>
<Icon name="gearshape" size={16} weight="medium" scaled={false} />
</button>
<button