The core function of this script is to translate chat messages on Twitch to other languages. A choice of two servers are included...
Google Legacy - Free and always available. No Accounts or API keys needed. Unlimited translations
DeepL - Free and Paid accounts available with DeepL. An account is required to get an API key. Free tier limited to 500,000 characters per month.
Features:
Access the settings via a new chat button
On/Off toggle
Support for at least 66 Languages
Color customization for translated messages
Only translates messages if the detected language is different to the selected language
Only posts translated messages if it's different enough to the original text
Choose to show/hide emotes on translated messages.
Works in Pop-out chat and dashboard.
Now works on VoDs as of version 1.0.4 (settings button may appear in playback bar instead of chat box)
Potential future features
May look at the ability to translate user messages before posting to the chatrooms.
Removed in 1.0 and later
Some sensitivity settings no longer have entries in the settings menu. They can still be changed directly in the code block.
Blocked words list (was primarily designed for emotes which are now handled differently)
" Temporarily (tm) " removed Historical Translations as its broken
Compatibility
Works with BTTV and 7TV
Other 3rd party extensions are untested
This script was originally designed for personal use, and was being developed while learning how to program in JavaScript. As such there are likely to be some portions of the code that are poorly designed or unnecessary, and may well be liable to bugs. Keep in mind the accuracy of Translations relies soley on the API's, not the code.
On rare occasions, the settings button doesn't load properly but the script still runs. A page refresh usually fixes this.
The script was created and tested on Brave and Firefox, but may have issues with other browser
Important note: Developer mode must be enabled for Tampermonkey or equivalent, in order to allow for proper injection to the webpage. This needs to be done via your browser extensions.