Comparing version 1.0.1-master.6dc8065 to 1.0.1-master.eb5b8bd
@@ -78,2 +78,9 @@ 'use strict'; | ||
// For Chrome quirks, we need a custom queue, because we need to definitely know when to expect a "start" event. | ||
// If we don't have a queue, the "start" event could be happening long time later because it's still pending in the queue. | ||
// But with the custom queue, the first item might be started from non-user event. That means in Safari, the first item is muted. | ||
// And after the first fail, the custom queue will play the second item from a non-user event code path. That means, all subsequent | ||
// items are blocked until Safari has the very first item queued from user event. | ||
// console.debug(`STARTING: ${ utterance.text }`); | ||
@@ -128,22 +135,19 @@ | ||
endEvent = _context2.sent; | ||
_context2.t0 = endEvent.type; | ||
_context2.next = _context2.t0 === 'cancel' ? 15 : _context2.t0 === 'error' ? 17 : 18; | ||
break; | ||
case 15: | ||
speechSynthesis.cancel(); | ||
throw new Error('cancelled'); | ||
if (!(endEvent.type === 'error')) { | ||
_context2.next = 14; | ||
break; | ||
} | ||
case 17: | ||
throw endEvent.error; | ||
case 18: | ||
case 14: | ||
return _context2.abrupt('return', resolve()); | ||
case 21: | ||
_context2.prev = 21; | ||
_context2.t1 = _context2['catch'](0); | ||
return _context2.abrupt('return', reject(_context2.t1)); | ||
case 17: | ||
_context2.prev = 17; | ||
_context2.t0 = _context2['catch'](0); | ||
return _context2.abrupt('return', reject(_context2.t0)); | ||
case 24: | ||
case 20: | ||
case 'end': | ||
@@ -153,3 +157,3 @@ return _context2.stop(); | ||
} | ||
}, _callee2, this, [[0, 21]]); | ||
}, _callee2, this, [[0, 17]]); | ||
})); | ||
@@ -290,3 +294,3 @@ | ||
case 0: | ||
console.debug('CANCELLING QUEUED ITEMS: ' + this.queueWithCurrent.length); | ||
// console.debug(`CANCELLING QUEUED ITEMS: ${ this.queueWithCurrent.length }`); | ||
@@ -307,19 +311,15 @@ this.queueWithCurrent.forEach(function (entry) { | ||
_context3.prev = 4; | ||
_context3.next = 7; | ||
_context3.prev = 3; | ||
_context3.next = 6; | ||
return cancelAll; | ||
case 7: | ||
_context3.next = 11; | ||
case 6: | ||
_context3.next = 10; | ||
break; | ||
case 9: | ||
_context3.prev = 9; | ||
_context3.t0 = _context3['catch'](4); | ||
case 8: | ||
_context3.prev = 8; | ||
_context3.t0 = _context3['catch'](3); | ||
case 11: | ||
console.debug('ALL CANCELLED OR FINISHED'); | ||
case 12: | ||
case 10: | ||
case 'end': | ||
@@ -329,3 +329,3 @@ return _context3.stop(); | ||
} | ||
}, _callee3, this, [[4, 9]]); | ||
}, _callee3, this, [[3, 8]]); | ||
})); | ||
@@ -542,2 +542,2 @@ | ||
}; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9Db21wb3Nlci5qcyJdLCJuYW1lcyI6WyJzcGVlY2hTeW50aGVzaXMiLCJyZWplY3QiLCJyZXNvbHZlIiwidXR0ZXJhbmNlIiwic3RhcnREZWZlcnJlZCIsImVycm9yRGVmZXJyZWQiLCJlbmREZWZlcnJlZCIsImFkZEV2ZW50TGlzdGVuZXIiLCJzcGVhayIsInJhY2UiLCJwcm9taXNlIiwiY2FuY2VsIiwic3BlYWtpbmciLCJ0aGVuIiwidHlwZSIsImFydGlmaWNpYWwiLCJlbmRFdmVudCIsIkVycm9yIiwiZXJyb3IiLCJzcGVha1V0dGVyYW5jZSIsImNyZWF0ZVV0dGVyYW5jZSIsInV0dGVyYW5jZUxpa2UiLCJwb255ZmlsbCIsIlNwZWVjaFN5bnRoZXNpc1V0dGVyYW5jZSIsImxhbmciLCJvbkJvdW5kYXJ5Iiwib25FbmQiLCJvbkVycm9yIiwib25TdGFydCIsInBpdGNoIiwicmF0ZSIsInRleHQiLCJ2b2ljZSIsInZvbHVtZSIsInRhcmdldFZvaWNlIiwiY2FsbCIsImdldFNlcmlhbGl6YWJsZVZvaWNlcyIsInZvaWNlVVJJIiwiZmluZCIsInNsaWNlIiwidiIsIlNwZWVjaENvbnRleHQiLCJxdWV1ZVdpdGhDdXJyZW50IiwiYmluZCIsInNldFB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b2YgY2hpbGRyZW4gPT09ICdmdW5jdGlvbicgPyBjaGlsZHJlbihjb250ZXh0KSA6IGNoaWxkcmVuXG4gICAgICAgICAgOlxuICAgICAgICAgICAgPENvbnRleHQuUHJvdmlkZXIgdmFsdWU9eyB0aGlzLm1lcmdlQ29udGV4dChzdGF0ZS5jb250ZXh0LCBzdGF0ZS52b2ljZXMpIH0+XG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICB0eXBlb2YgY2hpbGRyZW4gPT09ICdmdW5jdGlvbicgP1xuICAgICAgICAgICAgICAgICAgPENvbnRleHQuQ29uc3VtZXI+XG4gICAgICAgICAgICAgICAgICAgIHsgY29udGV4dCA9PiBjaGlsZHJlbihjb250ZXh0KSB9XG4gICAgICAgICAgICAgICAgICA8L0NvbnRleHQuQ29uc3VtZXI+XG4gICAgICAgICAgICAgICAgOlxuICAgICAgICAgICAgICAgICAgY2hpbGRyZW5cbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgPC9Db250ZXh0LlByb3ZpZGVyPlxuICAgICAgICB9XG4gICAgICA8L0NvbnRleHQuQ29uc3VtZXI+XG4gICAgKTtcbiAgfVxufVxuXG5Db21wb3Nlci5kZWZhdWx0UHJvcHMgPSB7XG4gIHNwZWVjaFN5bnRoZXNpczogd2luZG93LnNwZWVjaFN5bnRoZXNpcyB8fCB3aW5kb3cud2Via2l0U3BlZWNoU3ludGhlc2lzLFxuICBzcGVlY2hTeW50aGVzaXNVdHRlcmFuY2U6IHdpbmRvdy5TcGVlY2hTeW50aGVzaXNVdHRlcmFuY2UgfHwgd2luZG93LndlYmtpdFNwZWVjaFN5bnRoZXNpc1V0dGVyYW5jZVxufTtcblxuQ29tcG9zZXIucHJvcFR5cGVzID0ge1xuICBzcGVlY2hTeW50aGVzaXM6IFByb3BUeXBlcy5hbnksXG4gIHNwZWVjaFN5bnRoZXNpc1V0dGVyYW5jZTogUHJvcFR5cGVzLmFueVxufTtcbiJdfQ== |
@@ -7,2 +7,10 @@ 'use strict'; | ||
var _regenerator = require('babel-runtime/regenerator'); | ||
var _regenerator2 = _interopRequireDefault(_regenerator); | ||
var _asyncToGenerator2 = require('babel-runtime/helpers/asyncToGenerator'); | ||
var _asyncToGenerator3 = _interopRequireDefault(_asyncToGenerator2); | ||
var _propTypes = require('prop-types'); | ||
@@ -32,20 +40,45 @@ | ||
'button', | ||
{ onClick: function onClick(event) { | ||
props.exclusive && context.cancel(); | ||
{ onClick: function () { | ||
var _ref = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee(event) { | ||
return _regenerator2.default.wrap(function _callee$(_context) { | ||
while (1) { | ||
switch (_context.prev = _context.next) { | ||
case 0: | ||
if (!props.exclusive) { | ||
_context.next = 3; | ||
break; | ||
} | ||
context.speak({ | ||
lang: props.lang, | ||
onBoundary: props.onBoundary, | ||
onEnd: props.onEnd, | ||
onError: props.onError, | ||
onStart: props.onStart, | ||
pitch: props.pitch, | ||
rate: props.rate, | ||
text: props.speak, | ||
voice: props.voice, | ||
volume: props.volume | ||
}); | ||
_context.next = 3; | ||
return context.cancel(); | ||
props.onClick && props.onClick(event); | ||
} }, | ||
case 3: | ||
context.speak({ | ||
lang: props.lang, | ||
onBoundary: props.onBoundary, | ||
onEnd: props.onEnd, | ||
onError: props.onError, | ||
onStart: props.onStart, | ||
pitch: props.pitch, | ||
rate: props.rate, | ||
text: props.speak, | ||
voice: props.voice, | ||
volume: props.volume | ||
}); | ||
props.onClick && props.onClick(event); | ||
case 5: | ||
case 'end': | ||
return _context.stop(); | ||
} | ||
} | ||
}, _callee, undefined); | ||
})); | ||
return function (_x) { | ||
return _ref.apply(this, arguments); | ||
}; | ||
}() }, | ||
props.children | ||
@@ -72,2 +105,2 @@ ); | ||
exports.default = SayButton; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9TYXlCdXR0b24uanMiXSwibmFtZXMiOlsiU2F5QnV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JvcHMucGl0Y2gsXG4gICAgICAgICAgcmF0ZTogcHJvcHMucmF0ZSxcbiAgICAgICAgICB0ZXh0OiBwcm9wcy5zcGVhayxcbiAgICAgICAgICB2b2ljZTogcHJvcHMudm9pY2UsXG4gICAgICAgICAgdm9sdW1lOiBwcm9wcy52b2x1bWVcbiAgICAgICAgfSk7XG5cbiAgICAgICAgcHJvcHMub25DbGljayAmJiBwcm9wcy5vbkNsaWNrKGV2ZW50KTtcbiAgICAgIH0gfT5cbiAgICAgICAgeyBwcm9wcy5jaGlsZHJlbiB9XG4gICAgICA8L2J1dHRvbj5cbiAgICB9XG4gIDwvQ29udGV4dC5Db25zdW1lcj5cblxuU2F5QnV0dG9uLnByb3BUeXBlcyA9IHtcbiAgZXhjbHVzaXZlOiBQcm9wVHlwZXMuYm9vbCxcbiAgbGFuZzogUHJvcFR5cGVzLnN0cmluZyxcbiAgb25Cb3VuZGFyeTogUHJvcFR5cGVzLmZ1bmMsXG4gIG9uRW5kOiBQcm9wVHlwZXMuZnVuYyxcbiAgb25FcnJvcjogUHJvcFR5cGVzLmZ1bmMsXG4gIG9uU3RhcnQ6IFByb3BUeXBlcy5mdW5jLFxuICBwaXRjaDogUHJvcFR5cGVzLm51bWJlcixcbiAgcmF0ZTogUHJvcFR5cGVzLm51bWJlcixcbiAgc3BlYWs6IFByb3BUeXBlcy5zdHJpbmcsXG4gIHZvaWNlOiBQcm9wVHlwZXMub25lT2ZUeXBlKFtQcm9wVHlwZXMuYW55LCBQcm9wVHlwZXMuZnVuY10pLFxuICB2b2x1bWU6IFByb3BUeXBlcy5udW1iZXJcbn07XG5cbmV4cG9ydCBkZWZhdWx0IFNheUJ1dHRvbjtcbiJdfQ== |
@@ -7,2 +7,10 @@ 'use strict'; | ||
var _regenerator = require('babel-runtime/regenerator'); | ||
var _regenerator2 = _interopRequireDefault(_regenerator); | ||
var _asyncToGenerator2 = require('babel-runtime/helpers/asyncToGenerator'); | ||
var _asyncToGenerator3 = _interopRequireDefault(_asyncToGenerator2); | ||
var _getPrototypeOf = require('babel-runtime/core-js/object/get-prototype-of'); | ||
@@ -110,18 +118,39 @@ | ||
function (context) { | ||
exclusive && context.cancel(); | ||
(0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee() { | ||
return _regenerator2.default.wrap(function _callee$(_context) { | ||
while (1) { | ||
switch (_context.prev = _context.next) { | ||
case 0: | ||
if (!exclusive) { | ||
_context.next = 3; | ||
break; | ||
} | ||
context.speak({ | ||
lang: lang, | ||
onBoundary: _this2.handleBoundary, | ||
onEnd: _this2.handleEnd, | ||
onError: _this2.handleError, | ||
onStart: _this2.handleStart, | ||
pitch: pitch, | ||
rate: rate, | ||
text: text, | ||
uniqueID: uniqueID, | ||
voice: voice, | ||
volume: volume | ||
}); | ||
_context.next = 3; | ||
return context.cancel(); | ||
case 3: | ||
context.speak({ | ||
lang: lang, | ||
onBoundary: _this2.handleBoundary, | ||
onEnd: _this2.handleEnd, | ||
onError: _this2.handleError, | ||
onStart: _this2.handleStart, | ||
pitch: pitch, | ||
rate: rate, | ||
text: text, | ||
uniqueID: uniqueID, | ||
voice: voice, | ||
volume: volume | ||
}); | ||
case 4: | ||
case 'end': | ||
return _context.stop(); | ||
} | ||
} | ||
}, _callee, _this2); | ||
}))(); | ||
return false; | ||
@@ -151,2 +180,2 @@ } | ||
}; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9TYXlQcmltaXRpdmUuanMiXSwibmFtZXMiOlsiU2F5IiwicHJvcHMiLCJoYW5kbGVCb3VuZGFyeSIsImJpbmQiLCJoYW5kbGVFbmQiLCJoYW5kbGVFcnJvciIsImhhbmRsZVN0YXJ0Iiwic3RhdGUiLCJ1bmlxdWVJRCIsIkRhdGUiLCJub3ciLCJNYXRoIiwicmFuZG9tIiwidW5tb3VudGVkIiwiZXZlbnQiLCJvbkJvdW5kYXJ5Iiwib25FbmQiLCJv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4gICAgICAgICAgICAgICAgdGV4dCxcbiAgICAgICAgICAgICAgICB1bmlxdWVJRCxcbiAgICAgICAgICAgICAgICB2b2ljZSxcbiAgICAgICAgICAgICAgICB2b2x1bWVcbiAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9KSgpO1xuXG4gICAgICAgICAgICByZXR1cm4gZmFsc2U7XG4gICAgICAgIH0gfVxuICAgICAgPC9Db250ZXh0LkNvbnN1bWVyPlxuICAgICk7XG4gIH1cbn1cblxuU2F5LnByb3BUeXBlcyA9IHtcbiAgZXhjbHVzaXZlOiBQcm9wVHlwZXMuYm9vbCxcbiAgbGFuZzogUHJvcFR5cGVzLnN0cmluZyxcbiAgcGl0Y2g6IFByb3BUeXBlcy5udW1iZXIsXG4gIHJhdGU6IFByb3BUeXBlcy5udW1iZXIsXG4gIG9uQm91bmRhcnk6IFByb3BUeXBlcy5mdW5jLFxuICBvbkVuZDogUHJvcFR5cGVzLmZ1bmMsXG4gIG9uRXJyb3I6IFByb3BUeXBlcy5mdW5jLFxuICBvblN0YXJ0OiBQcm9wVHlwZXMuZnVuYyxcbiAgc3BlYWs6IFByb3BUeXBlcy5zdHJpbmcsXG4gIHZvaWNlOiBQcm9wVHlwZXMub25lT2ZUeXBlKFtQcm9wVHlwZXMuYW55LCBQcm9wVHlwZXMuZnVuY10pLFxuICB2b2x1bWU6IFByb3BUeXBlcy5udW1iZXJcbn07XG4iXX0= |
{ | ||
"name": "react-say", | ||
"version": "1.0.1-master.6dc8065", | ||
"version": "1.0.1-master.eb5b8bd", | ||
"description": "A React component that synthesis text into speech using Web Speech API", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
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
86118
864
0