@capacitor-community/text-to-speech
Advanced tools
Comparing version 0.2.1-dev.63108ab to 0.2.1-dev.65857f5
@@ -0,0 +0,0 @@ ## [0.2.0](https://github.com/capacitor-community/text-to-speech/compare/v0.1.3...v0.2.0) (2020-06-30) |
@@ -10,3 +10,3 @@ declare module '@capacitor/core' { | ||
getSupportedLanguages(): Promise<{ | ||
languages: any; | ||
languages: string[]; | ||
}>; | ||
@@ -33,8 +33,29 @@ getSupportedVoices(): Promise<{ | ||
} | ||
/** | ||
* The SpeechSynthesisVoice interface represents a voice that the system supports. | ||
*/ | ||
export interface SpeechSynthesisVoice { | ||
voiceURI: string; | ||
name: string; | ||
/** | ||
* Specifies whether the voice is the default voice for the current app (`true`) or not (`false`). | ||
*/ | ||
default: boolean; | ||
/** | ||
* BCP 47 language tag indicating the language of the voice. | ||
* Example: `en-US` | ||
*/ | ||
lang: string; | ||
/** | ||
* Specifies whether the voice is supplied by a local (`true`) or remote (`false`) speech synthesizer service. | ||
*/ | ||
localService: boolean; | ||
default: boolean; | ||
/** | ||
* Human-readable name that represents the voice. | ||
* Example: `Microsoft Zira Desktop - English (United States)` | ||
*/ | ||
name: string; | ||
/** | ||
* Type of URI and location of the speech synthesis service for this voice. | ||
* Example: `urn:moz-tts:sapi:Microsoft Zira Desktop - English (United States)?en-US` | ||
*/ | ||
voiceURI: string; | ||
} |
export * from './definitions'; | ||
export * from './web'; |
export * from './definitions'; | ||
export * from './web'; | ||
//# sourceMappingURL=index.js.map |
import { WebPlugin } from '@capacitor/core'; | ||
import { TextToSpeechPlugin, TTSOptions, SpeechSynthesisVoice } from './definitions'; | ||
import { TextToSpeechPlugin, SpeechSynthesisVoice, TTSOptions } from './definitions'; | ||
export declare class TextToSpeechWeb extends WebPlugin implements TextToSpeechPlugin { | ||
private speechSynthesizer; | ||
private activeUtterance; | ||
private notSupportedMessage; | ||
private supportedVoices; | ||
private speechSynthesis; | ||
private currentlyActive; | ||
constructor(); | ||
@@ -12,3 +10,3 @@ speak(options: TTSOptions): Promise<void>; | ||
getSupportedLanguages(): Promise<{ | ||
languages: any; | ||
languages: string[]; | ||
}>; | ||
@@ -25,4 +23,8 @@ getSupportedVoices(): Promise<{ | ||
}): Promise<void>; | ||
private createSpeechSynthesisUtterance; | ||
private getSpeechSynthesisVoices; | ||
private throwUnsupportedError; | ||
private throwUnimplementedError; | ||
} | ||
declare const TextToSpeech: TextToSpeechWeb; | ||
export { TextToSpeech }; |
@@ -0,1 +1,10 @@ | ||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
return new (P || (P = Promise))(function (resolve, reject) { | ||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } | ||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } | ||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } | ||
step((generator = generator.apply(thisArg, _arguments || [])).next()); | ||
}); | ||
}; | ||
import { WebPlugin } from '@capacitor/core'; | ||
@@ -8,91 +17,106 @@ export class TextToSpeechWeb extends WebPlugin { | ||
}); | ||
this.notSupportedMessage = 'Speech Synthesizer is not yet initialized or supported.'; | ||
this.supportedVoices = []; | ||
if (!this.speechSynthesizer && window && window.speechSynthesis) { | ||
this.speechSynthesizer = window.speechSynthesis; | ||
this.speechSynthesis = null; | ||
this.currentlyActive = false; | ||
if ('speechSynthesis' in window) { | ||
this.speechSynthesis = window.speechSynthesis; | ||
} | ||
} | ||
speak(options) { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
if (!options) { | ||
reject('No options were provided.'); | ||
return; | ||
if (!options.text) { | ||
throw new Error('Text option was not provided.'); | ||
} | ||
if (!options.text) { | ||
reject('Text option was not provided'); | ||
const speechSynthesis = this.speechSynthesis; | ||
if (this.currentlyActive) { | ||
return; | ||
} | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (!this.activeUtterance) { | ||
this.activeUtterance = new SpeechSynthesisUtterance(); | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
this.activeUtterance.voice = this.supportedVoices[voice]; | ||
this.activeUtterance.rate = | ||
speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
this.activeUtterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
this.activeUtterance.text = text; | ||
this.activeUtterance.lang = locale; | ||
this.activeUtterance.pitch = | ||
pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
if (voice) { | ||
this.activeUtterance.voice = voice; | ||
} | ||
this.activeUtterance.onend = (ev) => { | ||
resolve(ev); | ||
this.activeUtterance = undefined; | ||
this.currentlyActive = true; | ||
const utterance = this.createSpeechSynthesisUtterance(options); | ||
return new Promise((resolve, reject) => { | ||
utterance.onend = () => { | ||
this.currentlyActive = false; | ||
resolve(); | ||
}; | ||
this.activeUtterance.onerror = (ev) => { | ||
reject(ev); | ||
this.activeUtterance = undefined; | ||
utterance.onerror = (event) => { | ||
this.currentlyActive = false; | ||
reject(event); | ||
}; | ||
this.speechSynthesizer.speak(this.activeUtterance); | ||
} | ||
speechSynthesis.speak(utterance); | ||
}); | ||
}); | ||
} | ||
stop() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
this.speechSynthesizer.cancel(); | ||
resolve(); | ||
this.speechSynthesis.cancel(); | ||
}); | ||
} | ||
getSupportedLanguages() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
resolve(); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const languages = voices.map(voice => voice.lang); | ||
const filteredLanguages = languages.filter((v, i, a) => a.indexOf(v) == i); | ||
return { languages: filteredLanguages }; | ||
}); | ||
} | ||
getSupportedVoices() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
resolve({ | ||
voices: this.supportedVoices, | ||
}); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
return { voices }; | ||
}); | ||
} | ||
openInstall() { | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setPitchRate(_options) { | ||
// Pitch rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setSpeechRate(_options) { | ||
// Speech rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
createSpeechSynthesisUtterance(options) { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const utterance = new SpeechSynthesisUtterance(); | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (voice) { | ||
utterance.voice = voices[voice]; | ||
} | ||
if (volume) { | ||
utterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
} | ||
if (speechRate) { | ||
utterance.rate = speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
} | ||
if (pitchRate) { | ||
utterance.pitch = pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
} | ||
if (locale) { | ||
utterance.lang = locale; | ||
} | ||
utterance.text = text; | ||
return utterance; | ||
} | ||
getSpeechSynthesisVoices() { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
return this.speechSynthesis.getVoices(); | ||
} | ||
throwUnsupportedError() { | ||
throw new Error('Not supported on this device.'); | ||
} | ||
throwUnimplementedError() { | ||
throw new Error('Not implemented on web.'); | ||
} | ||
} | ||
@@ -99,0 +123,0 @@ const TextToSpeech = new TextToSpeechWeb(); |
@@ -7,2 +7,11 @@ 'use strict'; | ||
var __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
return new (P || (P = Promise))(function (resolve, reject) { | ||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } | ||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } | ||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } | ||
step((generator = generator.apply(thisArg, _arguments || [])).next()); | ||
}); | ||
}; | ||
class TextToSpeechWeb extends core.WebPlugin { | ||
@@ -14,91 +23,106 @@ constructor() { | ||
}); | ||
this.notSupportedMessage = 'Speech Synthesizer is not yet initialized or supported.'; | ||
this.supportedVoices = []; | ||
if (!this.speechSynthesizer && window && window.speechSynthesis) { | ||
this.speechSynthesizer = window.speechSynthesis; | ||
this.speechSynthesis = null; | ||
this.currentlyActive = false; | ||
if ('speechSynthesis' in window) { | ||
this.speechSynthesis = window.speechSynthesis; | ||
} | ||
} | ||
speak(options) { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
if (!options) { | ||
reject('No options were provided.'); | ||
return; | ||
if (!options.text) { | ||
throw new Error('Text option was not provided.'); | ||
} | ||
if (!options.text) { | ||
reject('Text option was not provided'); | ||
const speechSynthesis = this.speechSynthesis; | ||
if (this.currentlyActive) { | ||
return; | ||
} | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (!this.activeUtterance) { | ||
this.activeUtterance = new SpeechSynthesisUtterance(); | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
this.activeUtterance.voice = this.supportedVoices[voice]; | ||
this.activeUtterance.rate = | ||
speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
this.activeUtterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
this.activeUtterance.text = text; | ||
this.activeUtterance.lang = locale; | ||
this.activeUtterance.pitch = | ||
pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
if (voice) { | ||
this.activeUtterance.voice = voice; | ||
} | ||
this.activeUtterance.onend = (ev) => { | ||
resolve(ev); | ||
this.activeUtterance = undefined; | ||
this.currentlyActive = true; | ||
const utterance = this.createSpeechSynthesisUtterance(options); | ||
return new Promise((resolve, reject) => { | ||
utterance.onend = () => { | ||
this.currentlyActive = false; | ||
resolve(); | ||
}; | ||
this.activeUtterance.onerror = (ev) => { | ||
reject(ev); | ||
this.activeUtterance = undefined; | ||
utterance.onerror = (event) => { | ||
this.currentlyActive = false; | ||
reject(event); | ||
}; | ||
this.speechSynthesizer.speak(this.activeUtterance); | ||
} | ||
speechSynthesis.speak(utterance); | ||
}); | ||
}); | ||
} | ||
stop() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
this.speechSynthesizer.cancel(); | ||
resolve(); | ||
this.speechSynthesis.cancel(); | ||
}); | ||
} | ||
getSupportedLanguages() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
resolve(); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const languages = voices.map(voice => voice.lang); | ||
const filteredLanguages = languages.filter((v, i, a) => a.indexOf(v) == i); | ||
return { languages: filteredLanguages }; | ||
}); | ||
} | ||
getSupportedVoices() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
resolve({ | ||
voices: this.supportedVoices, | ||
}); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
return { voices }; | ||
}); | ||
} | ||
openInstall() { | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setPitchRate(_options) { | ||
// Pitch rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setSpeechRate(_options) { | ||
// Speech rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
createSpeechSynthesisUtterance(options) { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const utterance = new SpeechSynthesisUtterance(); | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (voice) { | ||
utterance.voice = voices[voice]; | ||
} | ||
if (volume) { | ||
utterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
} | ||
if (speechRate) { | ||
utterance.rate = speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
} | ||
if (pitchRate) { | ||
utterance.pitch = pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
} | ||
if (locale) { | ||
utterance.lang = locale; | ||
} | ||
utterance.text = text; | ||
return utterance; | ||
} | ||
getSpeechSynthesisVoices() { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
return this.speechSynthesis.getVoices(); | ||
} | ||
throwUnsupportedError() { | ||
throw new Error('Not supported on this device.'); | ||
} | ||
throwUnimplementedError() { | ||
throw new Error('Not implemented on web.'); | ||
} | ||
} | ||
@@ -105,0 +129,0 @@ const TextToSpeech = new TextToSpeechWeb(); |
var capacitorTextToSpeech = (function (exports, core) { | ||
'use strict'; | ||
var __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
return new (P || (P = Promise))(function (resolve, reject) { | ||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } | ||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } | ||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } | ||
step((generator = generator.apply(thisArg, _arguments || [])).next()); | ||
}); | ||
}; | ||
class TextToSpeechWeb extends core.WebPlugin { | ||
@@ -10,91 +19,106 @@ constructor() { | ||
}); | ||
this.notSupportedMessage = 'Speech Synthesizer is not yet initialized or supported.'; | ||
this.supportedVoices = []; | ||
if (!this.speechSynthesizer && window && window.speechSynthesis) { | ||
this.speechSynthesizer = window.speechSynthesis; | ||
this.speechSynthesis = null; | ||
this.currentlyActive = false; | ||
if ('speechSynthesis' in window) { | ||
this.speechSynthesis = window.speechSynthesis; | ||
} | ||
} | ||
speak(options) { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
if (!options) { | ||
reject('No options were provided.'); | ||
return; | ||
if (!options.text) { | ||
throw new Error('Text option was not provided.'); | ||
} | ||
if (!options.text) { | ||
reject('Text option was not provided'); | ||
const speechSynthesis = this.speechSynthesis; | ||
if (this.currentlyActive) { | ||
return; | ||
} | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (!this.activeUtterance) { | ||
this.activeUtterance = new SpeechSynthesisUtterance(); | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
this.activeUtterance.voice = this.supportedVoices[voice]; | ||
this.activeUtterance.rate = | ||
speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
this.activeUtterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
this.activeUtterance.text = text; | ||
this.activeUtterance.lang = locale; | ||
this.activeUtterance.pitch = | ||
pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
if (voice) { | ||
this.activeUtterance.voice = voice; | ||
} | ||
this.activeUtterance.onend = (ev) => { | ||
resolve(ev); | ||
this.activeUtterance = undefined; | ||
this.currentlyActive = true; | ||
const utterance = this.createSpeechSynthesisUtterance(options); | ||
return new Promise((resolve, reject) => { | ||
utterance.onend = () => { | ||
this.currentlyActive = false; | ||
resolve(); | ||
}; | ||
this.activeUtterance.onerror = (ev) => { | ||
reject(ev); | ||
this.activeUtterance = undefined; | ||
utterance.onerror = (event) => { | ||
this.currentlyActive = false; | ||
reject(event); | ||
}; | ||
this.speechSynthesizer.speak(this.activeUtterance); | ||
} | ||
speechSynthesis.speak(utterance); | ||
}); | ||
}); | ||
} | ||
stop() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
this.speechSynthesizer.cancel(); | ||
resolve(); | ||
this.speechSynthesis.cancel(); | ||
}); | ||
} | ||
getSupportedLanguages() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
resolve(); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const languages = voices.map(voice => voice.lang); | ||
const filteredLanguages = languages.filter((v, i, a) => a.indexOf(v) == i); | ||
return { languages: filteredLanguages }; | ||
}); | ||
} | ||
getSupportedVoices() { | ||
return new Promise((resolve, reject) => { | ||
if (!this.speechSynthesizer) { | ||
reject(this.notSupportedMessage); | ||
return; | ||
} | ||
this.supportedVoices = window.speechSynthesis.getVoices(); | ||
resolve({ | ||
voices: this.supportedVoices, | ||
}); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
return { voices }; | ||
}); | ||
} | ||
openInstall() { | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setPitchRate(_options) { | ||
// Pitch rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
setSpeechRate(_options) { | ||
// Speech rate cannot be set while engine is active | ||
throw new Error('Method not implemented.'); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
this.throwUnimplementedError(); | ||
}); | ||
} | ||
createSpeechSynthesisUtterance(options) { | ||
const voices = this.getSpeechSynthesisVoices(); | ||
const utterance = new SpeechSynthesisUtterance(); | ||
const { text, locale, speechRate, volume, voice, pitchRate } = options; | ||
if (voice) { | ||
utterance.voice = voices[voice]; | ||
} | ||
if (volume) { | ||
utterance.volume = volume >= 0 && volume <= 1 ? volume : 1; | ||
} | ||
if (speechRate) { | ||
utterance.rate = speechRate >= 0.1 && speechRate <= 10 ? speechRate : 1; | ||
} | ||
if (pitchRate) { | ||
utterance.pitch = pitchRate >= 0 && pitchRate <= 2 ? pitchRate : 2; | ||
} | ||
if (locale) { | ||
utterance.lang = locale; | ||
} | ||
utterance.text = text; | ||
return utterance; | ||
} | ||
getSpeechSynthesisVoices() { | ||
if (!this.speechSynthesis) { | ||
this.throwUnsupportedError(); | ||
} | ||
return this.speechSynthesis.getVoices(); | ||
} | ||
throwUnsupportedError() { | ||
throw new Error('Not supported on this device.'); | ||
} | ||
throwUnimplementedError() { | ||
throw new Error('Not implemented on web.'); | ||
} | ||
} | ||
@@ -101,0 +125,0 @@ const TextToSpeech = new TextToSpeechWeb(); |
{ | ||
"name": "@capacitor-community/text-to-speech", | ||
"version": "0.2.1-dev.63108ab", | ||
"version": "0.2.1-dev.65857f5", | ||
"description": "Capacitor plugin for synthesizing speech from text.", | ||
@@ -23,5 +23,2 @@ "main": "dist/plugin.js", | ||
"license": "MIT", | ||
"dependencies": { | ||
"@capacitor/core": "latest" | ||
}, | ||
"devDependencies": { | ||
@@ -41,2 +38,5 @@ "@capacitor/android": "2.4.7", | ||
}, | ||
"peerDependencies": { | ||
"@capacitor/core": "^2.4.6" | ||
}, | ||
"files": [ | ||
@@ -43,0 +43,0 @@ "android/src/main/", |
@@ -0,0 +0,0 @@ <p align="center"><br><img src="https://user-images.githubusercontent.com/236501/85893648-1c92e880-b7a8-11ea-926d-95355b8175c7.png" width="128" height="128" /></p> |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
72555
473
1
+ Added@capacitor/core@2.5.0(transitive)
+ Addedtslib@1.14.1(transitive)
- Removed@capacitor/core@latest
- Removed@capacitor/core@7.0.1(transitive)
- Removedtslib@2.8.1(transitive)