capacitor-community / text-to-speech

⚡️ Capacitor plugin for synthesizing speech from text.
MIT License
99 stars 29 forks source link

feat(android): support the `voice` property #90

Closed ecc521 closed 1 year ago

ecc521 commented 1 year ago

This finishes the second part of #38 (so once PR #89 and this are merged, #38 can be closed). Both of these PRs should be fully backwards compatible (I did change the generation of names a little in this one to make them all unique, which can be undone easily without adverse consequences)

Ultimately, it needs to be considered if the current voice property needs to be replaced with a voiceURI in the future for simplicity. That said, these PRs use the voice property identically to the current web behavior, and there's no immediate reason for any sort of breaking change (especially since I've already written the code for the current API)

ecc521 commented 1 year ago

In case you want to view the combined #89 and #90 changes in one place, I created an ecc521/android-and-ios-full-support fork (npm installable tarball at https://github.com/ecc521/text-to-speech/releases/download/v2.1.0/capacitor-community-text-to-speech-2.1.0.tgz).