feat(ai): 语音状态条新增取消入口并统一气泡与文字配色

This commit is contained in:
lik
2026-11-05 22:02:26 +08:00
parent 28793e39f5
commit 0d2912c544
4 changed files with 81 additions and 28 deletions
+7
View File
@@ -792,6 +792,13 @@ Page({
}, VOICE_FINISH_TIMEOUT)
},
// 状态条里的主动取消入口;页面隐藏时直接调用 cancelVoiceInput,不额外弹提示
onCancelVoiceTap() {
if (!this.data.recording) return
this.cancelVoiceInput()
wx.showToast({ title: '已取消语音输入', icon: 'none' })
},
// 页面隐藏 / 主动放弃:中止本轮,输入框回到开录前手打的内容
cancelVoiceInput() {
const stream = this.voiceStream