Zum Hauptinhalt springen
M

dsh-screen-translator

mustakimabdullah25-tech/dsh-screen-translator

Universal on-screen translator for DeepSeek Harness Web UI: translates text, attributes, Shadow DOM, and iframes across 45+ languages.

Installation

dsh plugin --profile web add github:mustakimabdullah25-tech/dsh-screen-translator

README

๐ŸŒ DSH Screen Translator

GitHub License DSH Compatibility Topic

Universal on-screen translator for DeepSeek Harness Web UI.
Translates UI text, menus, sidebars, Settings, MCP Connectors, nested iframes, and Shadow DOM elements across 45+ languages in real time without external API keys or rate limits.


๐Ÿ“– English | ไธญๆ–‡่ฏดๆ˜Ž


โœจ Features

  • ๐ŸŒ 45+ Languages Supported โ€” Instant real-time translation for English, Simplified & Traditional Chinese, Japanese, Korean, Spanish, French, German, Russian, Arabic, and more.
  • โšก Multi-Endpoint Google Engine โ€” Automatic failover between dict-chrome-ex, clients5, single-at, and web-at APIs to completely prevent 429 Too Many Requests rate limiting.
  • ๐Ÿ” Full-Spectrum DOM Coverage:
    • Visible text nodes and SVG typography (<text>, <tspan>).
    • Interactive attributes (placeholder, title, alt, aria-label, aria-placeholder).
    • Open Shadow DOM roots and web components.
    • Same-origin and nested iframes (MCP panels, modals, dialogs).
  • ๐Ÿš€ High Performance & Zero-Lag:
    • Dual-Tier Cache (In-Memory LRU + LocalStorage persistence) โ€” Instant 0ms rendering for previously translated phrases.
    • Smart Debounced MutationObserver โ€” Only newly inserted or altered DOM elements are processed.
    • Sentence Boundary Splitting โ€” Natural splitting at punctuation boundaries (ใ€‚, ๏ผ, ๏ผŸ, ., !, ?) preserves contextual readability.
    • Loop Prevention โ€” Strict self-exclusion tags ([data-no-translate], code blocks, syntax highlighters) prevent infinite loops.
  • ๐ŸŽ›๏ธ Clean Native UI Integration:
    • Integrated into Settings โ†’ General with matching native theme tokens.
    • One-click translation actions directly inside assistant conversation turns.
    • Granular controls: Enable/Disable, Target Language selector, Translate now, and Clear cache.

๐Ÿ“ฆ Installation

In your terminal or DSH session:

dsh plugin add mustakimabdullah25-tech/dsh-screen-translator

Method 2: Manual Installation from Source

Clone the repository into your DSH plugins directory:

cd "path/to/dsh-workspace/plugins"
git clone https://github.com/mustakimabdullah25-tech/dsh-screen-translator.git

Then install the bundle into your profile:

dsh plugin add ./plugins/dsh-screen-translator

โš™๏ธ Configuration & Usage

Once installed and enabled:

  1. Open Settings โ†’ General.
  2. Locate the Screen Translator (Auto-Translate Everywhere) section.
  3. Choose your preferred Target Language from the dropdown.
  4. Toggle Enabled to start automatic screen translation.
  5. Hit Translate now to force-translate the entire visible viewport immediately, or Clear cache to wipe stored translations.

๐Ÿ› ๏ธ Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                   DSH Web Runtime                      โ”‚
โ”‚                                                        โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”   โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚
โ”‚  โ”‚   MutationObserver    โ”‚   โ”‚      TreeWalker       โ”‚ โ”‚
โ”‚  โ”‚ (Watches new DOM/SVG) โ”‚   โ”‚ (Scans DOM/Shadow/IFR)โ”‚ โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜   โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚
โ”‚              โ”‚                           โ”‚             โ”‚
โ”‚              โ–ผ                           โ–ผ             โ”‚
โ”‚       โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”       โ”‚
โ”‚       โ”‚        Language & Token Filter         โ”‚       โ”‚
โ”‚       โ”‚  (Filters Code, Math, Regex, Excludes) โ”‚       โ”‚
โ”‚       โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜       โ”‚
โ”‚                          โ”‚                             โ”‚
โ”‚                          โ–ผ                             โ”‚
โ”‚       โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”       โ”‚
โ”‚       โ”‚    Dual Cache (Memory LRU + Storage)   โ”‚ โ”€โ”€โ–บ Hit (0ms)
โ”‚       โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜       โ”‚
โ”‚                          โ”‚ Miss                        โ”‚
โ”‚                          โ–ผ                             โ”‚
โ”‚       โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”       โ”‚
โ”‚       โ”‚      Multi-Endpoint Network Engine     โ”‚       โ”‚
โ”‚       โ”‚   (Chrome-Ex โž” Clients5 โž” Single-At)   โ”‚       โ”‚
โ”‚       โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜       โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ“ Repository Structure

dsh-screen-translator/
โ”œโ”€โ”€ client.js          # Client bundle: DOM translation engine, cache & settings UI
โ”œโ”€โ”€ index.js           # Host entry point (Cordis apply hook)
โ”œโ”€โ”€ cordis.patch.yml   # Cordis composition patch configuration
โ”œโ”€โ”€ package.json       # Bundle metadata and plugin contract
โ”œโ”€โ”€ README.md          # English documentation
โ”œโ”€โ”€ README_ZH.md       # Chinese documentation
โ””โ”€โ”€ LICENSE            # MIT License

๐Ÿค Contributing

Contributions, issues, and feature requests are welcome!
Feel free to open an issue or submit a pull request on GitHub.


๐Ÿ“„ License

This project is licensed under the MIT License.

ร„hnliche Plugins