Fingertip Translation

approved

by amos

This plugin has not been manually reviewed by Obsidian staff. Translate selected text into your language. Supports Bing Dictionary, Youdao, and MyMemory with built-in pronunciation.

1 stars356 downloadsUpdated 9d ago0BSD

Fingertip Translation

Fingertip Translation

中文文档

A simple and efficient text translation plugin for Obsidian that supports multiple translation services, trigger modes, and automatic pronunciation.

Features

  • Selection Translation - Hold Ctrl and select text to translate, or use direct selection
  • Multiple Translation Services - Supports Bing Dictionary, Youdao (automatic Plus/Webpage switching), MyMemory
  • Dictionary Format - Bing/Youdao display part of speech and exam categories (CET-4, CET-6, etc.)
  • Auto Pronunciation - Automatically plays pronunciation after successful translation (toggleable)
  • Multiple Accents - Supports US English and UK English
  • Lightweight - No API Key required, works out of the box

Installation

Method 1: Development Setup

git clone <repo-url>
cd obsidian-fingertip-translation
npm install
npm run dev

Method 2: Manual Installation

  1. Download or clone this repository
  2. Run npm run build to compile
  3. Copy main.js, styles.css, and manifest.json to your vault plugin folder:
    VaultFolder/.obsidian/plugins/fingertip-translation/
    
  4. Enable the plugin in Obsidian settings

Usage

  1. Select the text you want to translate in a note
  2. A popover will display the translation result (including phonetic symbols, part of speech, definitions)
  3. Click the speaker button to manually play pronunciation
  4. With "Auto Pronunciation" enabled, pronunciation plays automatically after successful translation
  5. Drag the popover to adjust its position
  6. Press ESC or click outside to close the popover

Settings

OptionDescriptionDefault
Translation ServiceBing Dictionary / Youdao / MyMemoryYoudao
Trigger ModeCtrl+Select / Direct SelectCtrl+Select
Pronunciation SourceYoudao Audio / Browser TTSYoudao Audio
Auto PronunciationAuto play after translationOff
Pronunciation AccentUS English / UK EnglishUS English
Show PhoneticDisplay phonetic symbolsOn
Phonetic ModeSingle accent / Both US and UKBoth
Show CategoryDisplay CET-4, CET-6, etc.On

Tech Stack

  • Language: TypeScript
  • Bundler: esbuild
  • API: Obsidian requestUrl() (bypasses CORS)

Project Structure

src/
├── main.ts                       # Plugin main entry
├── settings.ts                   # Settings interface
├── tts.ts                        # Pronunciation (Web Speech API)
├── translator-mymemory.ts        # MyMemory Translation API
├── translator-bing.ts            # Bing Dictionary
└── translator-youdao-integrated.ts # Youdao Dictionary (Integrated Plus + Webpage)

styles.css                        # Popover styles
manifest.json                     # Plugin manifest

Translation Services

ServiceFree QuotaAPI KeyDictionary FormatNotes
Bing DictionaryUnlimitedNot neededPart of speechRecommended
Youdao DictionaryUnlimitedNot neededCollins/Exam/CategoryAuto fallback
MyMemory1000/dayNot neededNone-

Youdao Features:

  • Prefers Plus API for richer data
  • Auto switches to webpage version when Plus API returns no match
  • Displays exam category tags (CET-4, CET-6, Gaokao, IELTS, TOEFL, etc.)
  • Shows US/UK accent labels for phonetics

Developer Guide

# Install dependencies
npm install

# Development mode (watch for changes and auto-compile)
npm run dev

# Production build
npm run build

License

BSD-0

References

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.