gerson
2025-03-25 982732e3aea8e429a9bbecc9e9927caa1d51a2fb
src/utils/speech/synthesis.ts
@@ -49,6 +49,15 @@
      this.synth.speak(this.synthesis);
   }
   public onEnd(callback: () => void): void {
      this.synthesis.addEventListener('end', callback);
   }
   // 移除事件监听
   public off(callback: () => void): void {
      this.synth.removeEventListener('end', callback);
   }
   public pause(): void {
      this.synth.pause();
   }