Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix(web): explicitly resume AudioContext and play audio on first TTS load (#35901)

kien duong7bc19d8251fe
diff --git a/web/app/components/base/audio-btn/audio.ts b/web/app/components/base/audio-btn/audio.ts
index 24615b333fd..9d524640fa9 100644
--- a/web/app/components/base/audio-btn/audio.ts
+++ b/web/app/components/base/audio-btn/audio.ts
@@ -136,6 +136,10 @@ export default class AudioPlayer {
}
else {
this.isLoadData = true
+ this.audioContext.resume().then((_) => {
+ this.audio.play()
+ this.callback?.('play')
+ })
this.loadAudio()
}
}