mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-08-04 00:00:08 +08:00
fix(tts-advanced): use promise-based API (#5131)
Co-authored-by: Daniel Kleebinder <daniel.kleebinder@gmail.com>
This commit is contained in:
co-authored by
Daniel Kleebinder
parent
91743e7e03
commit
fc67fb8174
@@ -62,8 +62,7 @@ export class TextToSpeechAdvanced extends AwesomeCordovaNativePlugin {
|
||||
* @returns {Promise<any>} Returns a promise that resolves when the speaking finishes
|
||||
*/
|
||||
@Cordova({
|
||||
successIndex: 1,
|
||||
errorIndex: 2,
|
||||
otherPromise: true
|
||||
})
|
||||
speak(textOrOptions: string | TTSOptions): Promise<any> {
|
||||
return;
|
||||
@@ -74,7 +73,9 @@ export class TextToSpeechAdvanced extends AwesomeCordovaNativePlugin {
|
||||
*
|
||||
* @returns {Promise<any>}
|
||||
*/
|
||||
@Cordova()
|
||||
@Cordova({
|
||||
otherPromise: true
|
||||
})
|
||||
stop(): Promise<any> {
|
||||
return;
|
||||
}
|
||||
@@ -84,7 +85,9 @@ export class TextToSpeechAdvanced extends AwesomeCordovaNativePlugin {
|
||||
*
|
||||
* @returns {Promise<TTSVoice[]>}
|
||||
*/
|
||||
@Cordova()
|
||||
@Cordova({
|
||||
otherPromise: true
|
||||
})
|
||||
getVoices(): Promise<TTSVoice[]> {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user