⬇️ fix: Image Download Browser Compatibility (#7950)

* fix: Add null check for SelectedTTS in MessageAudio component to prevent rendering issues

* fix: image download browser compatibility with error handling and fallback mechanism

- Updated the downloadImage function to use fetch for improved reliability and added error handling.
- Implemented a fallback to the original download method in case of fetch failure.
- Ensured the download link uses a blob URL for better compatibility with various image types.
This commit is contained in:
Danny Avila 2025-06-17 21:11:39 -04:00 committed by GitHub
parent ec7370dfe9
commit 10c0d7d474
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 30 additions and 7 deletions

View file

@ -14,6 +14,9 @@ function MessageAudio(props: TMessageAudio) {
};
const SelectedTTS = TTSComponents[engineTTS];
if (!SelectedTTS) {
return null;
}
return <SelectedTTS {...props} />;
}