Google Translate Auto Language Enchanced

Automatically set the target language to English based on detected source language changes

目前為 2024-12-11 提交的版本,檢視 最新版本

作者
UniverseDev
評價
0 0 0
版本
2.3
建立日期
2024-12-11
更新日期
2024-12-11
尺寸
1.2 KB
授權條款
GPL-3.0-or-later
腳本執行於

Description

This userscript ensures that the target language in Google Translate is always set to English whenever the source language changes. Ideal for users who frequently translate into English, this script eliminates the need for manual adjustments, enhancing productivity and ease of use.

Original Script: Google Translate Auto Languages by kkocdko.


Features

  • 🌐 Auto-Set Target Language: Automatically switches the target language to English when the source language changes.
  • 🔄 Dynamic Detection: Monitors and responds to source language changes in real-time.
  • Lightweight and Efficient: Runs only when required, ensuring smooth performance.
  • 🚫 No Frame Interference: Designed to work seamlessly without affecting embedded iframes.

Installation

  1. Install a userscript manager:
  2. Add the script:
    • Click Install Script on this page, or manually paste the code into a new script in your userscript manager.
  3. Enable the script:
    • Ensure the script is active for *://translate.google.*/*.

Usage Notes

  • This script is tailored for Google Translate and will not affect other translation tools.
  • The default target language is set to English ("en"). To change it, modify the targetLang variable in the script.
  • To ensure proper functioning, allow the page to fully load before using the translation feature.

Change Log

  • v2.3: Improved mutation observer for source language changes.
  • v2.2: Enhanced compatibility with different Google Translate domains.

License

This script is licensed under the GPL-3.0-or-later.

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址