Any way to turn on/off live captions on Chrome programmatically?
Asked Answered
G

0

9

Recently Chrome released a new accessibility feature in Chrome 89 called Live Captions. This is a great feature for us, as we have a custom video chat app, and I'd like to have a button to allow users to turn the captions on and off for anyone who would like to use them. We could have instructions on how to go to the browser settings and turn them on, but it would be easier if we could just toggle this for them with a button click. Another option would be Hyperlinking to chrome://settings/?search=live+caption, but the button would still be easier.

Gerstner answered 28/4, 2021 at 22:51 Comment(2)
I could be wrong, but I think that web applications can't directly control such settings due to security and privacy reasons. That said, linking directly to chrome://settings/accessibility could work well. You could also consider implementing your own live caption feature within your custom video chat app using a speech-to-text API (e.g. Google Cloud Speech-to-Text (cloud.google.com/speech-to-text).Gath
Short answer: no. Web apps are processed in a sandbox and have no access to Chrome settings. Chrome does not supply any API for websites to modify browser settings. Unfortunately (as of 2023) even if you were writing a Chrome extension and had access to the Chrome extension API you would still not be able to modify the Live Caption setting as it is absent from the Chrome accessibilityFeatures API.Doukhobor

© 2022 - 2024 — McMap. All rights reserved.