fix(voice): messages worded before reaching the status also follow a language change (#1661)

The radio and push-to-talk helpers shared by both voice providers now pass
English catalog text, and the OpenAI controller words its detail when shown,
like the Gemini session. A token failure without a server message carries
its status as sourceParams, so it is worded again with the number. The docs
say sourceDetail is the message as given, catalog text when it is the app's
own.
This commit is contained in:
Sameh Khamis committed 2026-11-10 18:11:07 -08:00
1 parent 44dd6d48a8
commit 874f83ba48
9 files changed
+107 -19

No files matched your search

+2 -2
View File
@@ -1,4 +1,4 @@
import { t } from '../i18n/index.js';
import { msg } from '../i18n/index.js';
import {
silenceRadioForVoice,
startPreparedRadioAfterPlaybackReady,
@@ -261,7 +261,7 @@ export class RealtimeRadio {
if (radioHandoff.result?.ok || radioHandoff.cancelled || !stillCurrent)
return;
if (this.dc?.readyState === 'open' && !this.userTurnPending) {
this.setStatus('listening', t('Radio did not start'));
this.setStatus('listening', msg('Radio did not start'));
this.queueResponseCreate(
'Say exactly one short correction: “The Radio station could not start. Voice is still on.”',
);