Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configuring off speech synthesis #2408

Merged
merged 2 commits into from
Sep 19, 2019
Merged

Conversation

compulim
Copy link
Contributor

@compulim compulim commented Sep 19, 2019

Fixes #2379.

Changelog Entry

Fixed

Description

To configure off speech synthesis but leaving speech recognition, we pass a Web Speech ponyfill:

{
  SpeechGrammarList: ...,
  SpeechRecognition: ...,
  speechSynthesis: null,
  SpeechSynthesisUtterance: null
}

We explicitly set speechSynthesis to null rather than leaving it as undefined, because undefined usually means, "implicitly leave as blank" and "leave it as default". I.e. Web Chat will use speech synthesis engine from browser if it is undefined.

But when we setting it to null, we are seeing exception because we are trying to synthesis using a null engine.

Specific Changes

In BasicTranscript.js, if speechSynthesis is falsy, do not render <SpeakActivity>, which will stop from synthesizing the text.


  • Testing Added

CHANGELOG.md Outdated Show resolved Hide resolved
Copy link
Contributor

@tdurnford tdurnford left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Co-Authored-By: TJ Durnford <[email protected]>
@coveralls
Copy link

Coverage Status

Coverage increased (+0.03%) to 65.233% when pulling a5e72f2 on compulim:fix-2379 into 563863a on microsoft:master.

@compulim compulim merged commit 59ef438 into microsoft:master Sep 19, 2019
@compulim compulim deleted the fix-2379 branch September 19, 2019 07:48
@compulim compulim mentioned this pull request Oct 4, 2019
13 tasks
@compulim compulim mentioned this pull request Oct 25, 2019
55 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Disable Text-To-Speech issue
3 participants