mirror of
https://github.com/lencx/ChatGPT.git
synced 2026-02-06 14:26:49 +00:00
fix:windows voices is empty
This commit is contained in:
parent
488e249193
commit
fa96092728
5
src/view/settings/General.tsx
vendored
5
src/view/settings/General.tsx
vendored
@ -12,6 +12,11 @@ export default function General() {
|
||||
|
||||
useInit(async () => {
|
||||
setPlatform(await platform());
|
||||
speechSynthesis.addEventListener('voiceschanged', () => {
|
||||
const voices = speechSynthesis.getVoices();
|
||||
console.log(voices);
|
||||
setVoices(voices);
|
||||
});
|
||||
setVoices(speechSynthesis.getVoices());
|
||||
});
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user