[speech][Android] Rewrite using new API (#23862)# Why Rewrite the speech module on Android to use the new API. # Test Plan - bare-expo ✅
[ios][speech] Migrate to Expo Modules (#21814)
[speech] Add TTS word tracking events (#20726)# Why We need the ability to highlight each word of a string of text in a native UI being uttered via text-to-speech SDK's. The current expo-speec
[speech] Add TTS word tracking events (#20726)# Why We need the ability to highlight each word of a string of text in a native UI being uttered via text-to-speech SDK's. The current expo-speech does not implement the related events for Android and iOS. # How I added the relevant events for Android and iOS as shown in their docs, respectively, to the existing expo-speech module: - [Android `onRangeStart`](https://developer.android.com/reference/android/speech/tts/UtteranceProgressListener#onRangeStart(java.lang.String,%20int,%20int,%20int)) - [iOS delegate with `willSpeakRangeOfSpeech`](https://developer.apple.com/documentation/avfaudio/avspeechsynthesizerdelegate/1619681-speechsynthesizer/) # Test Plan I smoke tested this in the application I need it for on a physical iPhone and Android emulator. The e2e tests for Speech are a bit rough at this time, so I was afraid to touch them. Here's a rough sketch of how it works in an application (see an [early prototype](https://github.com/gabrieljoelc/TextToSpeech/pull/2)): ```js function onWillSayNextString({location, length}) { console.log('onWillSayNextString character options', { location, length }); } function customSpeakPressHandler() { speak('Some text to utter', { onWillSayNextString }); } return ( <Button title='Speak' onPress={customSpeakPressHandler} /> ); ``` Co-authored-by: Bartłomiej Klocek <[email protected]>
show more ...
[speech][android] Code style fix
[expo-speech] Add comments to `LanguageUtils`A supplement to #14008- Added comments about null-unsafe helpers- Used getter methods for ISO Language and Country instead of _property access syntax
[expo-speech] Add comments to `LanguageUtils`A supplement to #14008- Added comments about null-unsafe helpers- Used getter methods for ISO Language and Country instead of _property access syntax_, because of readibility (`locale.getISO3Language()` vs `locale.isO3Language`)
[expo-speech] Rewrite Android module to Kotlin (#14008)
[expo-modules] Move code from `unimodules` into `expo-modules-core` (#13703)# Why Migrated `unimodules-core`, `unimodules-react-native-adapter`, `unimodules-app-loader` into `expo-modules-core`
[expo-modules] Move code from `unimodules` into `expo-modules-core` (#13703)# Why Migrated `unimodules-core`, `unimodules-react-native-adapter`, `unimodules-app-loader` into `expo-modules-core` # How - Change package using AS refactor tools - Fix some places where AS wasn't able to do automatically - Fix compatibility with new auto-linking - Ensure that classes which are used during installation steps are still available in the old place # Test Plan - expo-go (tested using unversioned and 41) - bare-expo
[expo-speech] Add support for max length of input string (#9243)# Why Fixes https://github.com/expo/expo/issues/7214 Also, maximum input string length is platform-dependent, so it would be usef
[expo-speech] Add support for max length of input string (#9243)# Why Fixes https://github.com/expo/expo/issues/7214 Also, maximum input string length is platform-dependent, so it would be useful to have a way to get it. # How Added new constant `Speech.maxSpeechInputLength`. It is platform dependent: - **Android** - used built-in [`getMaxSpeechInputLength()`](https://developer.android.com/reference/android/speech/tts/TextToSpeech#getMaxSpeechInputLength()) and exported it as a constant - **iOS** - I haven't found anything about the limit, the constant returns `Number.MAX_VALUE` on TypeScript side - **web** - [According to MDN](https://developer.mozilla.org/en-US/docs/Web/API/SpeechSynthesisUtterance/text), it is 32767. On Android and Web, calling `Speech.speak()` with text exceeding its maximum length, throws `ERR_SPEECH_INPUT_LENGTH`. I also updated `expo-speech` docs with features above. # Test Plan It was tested on all platforms using code from [this snack](https://snack.expo.io/@barthap10/expo-speech-text-length-demo). Test-suite ran without errors.
Fix speech test failing because english isn't available (#6171)* Fix speech test failing because english isn't available * Update Speech.js * Update Speech.js * Transform Android speech lo
Fix speech test failing because english isn't available (#6171)* Fix speech test failing because english isn't available * Update Speech.js * Update Speech.js * Transform Android speech locales
[android][speech] Implement getVoices and add voice speak option (#5887)
[unimodules][android] Change ModuleRegistryConsumer to RegistryLifecycleListener (#4345)# Why Modules need to know when they should release resources.
[packages] Move unimodules foundation to `org.unimodules` scope
[ios][android] Convert SpeechModule into universal module (#3091)* Convert Speech into universal module * pod install * [android] add expo-speech to app/build.gradle * [ts] fix speech test
[ios][android] Convert SpeechModule into universal module (#3091)* Convert Speech into universal module * pod install * [android] add expo-speech to app/build.gradle * [ts] fix speech tests not passing