Skip to content

Kesk0/DeepLopener

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DeepLopener

日本語解説記事に日本語で詳しくインストール方法や使用方法を書いているのでこちらを読んでください.
How to use (YouTube)

This Google chrome extension can replace texts that you want to translate with translation results by DeepL(deepl.com) keepking the original style.
On pdf, this extension displays frames showing translated sentences.

Install from Chrome Web Store

ChromeWebStore

Web site

https://deeplopener.ml/DeepLopener/

How to use

Text translation

(1)【Layout-oriented replacement mode】
Click the icon icon24.png in the upper right corner or right-click without selecting the text, move the cursor and right-click to translate, and left-click to cancel to select.
layoutContextMenu.png
layout-oriented.gif
The selected frame will be translated on layout-oriented replacement mode keeping the original style.
If you click the icon icon24.png in the right-hand corner and select Translate this page!, the whole page contents will be translated like below.
pagetrans.gif

(2)【PDF mode】
On PDF, select the text you want to translate and right-click on the text and click on DeepL:selected_text.
pdfmode.gif
For sites whose MIME type is application/pdf (local PDF files available!), the transition mode changes to PDF mode and the other modes are disabled.
You can move the translation frame around freely in Drag-and-Drop, and right-clicking on the translation result frame will remove it.

(3)【Text-oriented replacement mode】
With the text to be translated selected, press Ctrl Shift K (⌘ Shift K on mac) twice within 1 second or click on the icon icno24.png that appears after selecting the text.
text-oriented.gif
The selected text is highlighted in red first. After traslation , it turns yellow.
Right-click on the translation to display the original text.If you do it again, the letters will be toggled back to translation.
It is recommended to use this mode separately from the layout-oriented replacement mode because the original layout will be destroyed.

(4)【Transition mode】
Right click on the text you want to translate → Click on DeepL:selected_text.
openDeepL.gif
Move to https://www.deepl.com/translator#ja/en/selected_text

Usage
The number of characters translated so far in the current billing period is displayed in the upper right icon.
usage.png
I translated 11% (55000/500000) characters in the current billing period with DeepL API Free.

ShortCuts
Several modes can be executed by shortcuts.
These shortcuts can be edited from chrome://extensions/shortcuts
shortcuts.png

  • Layout-oriented replacement mode: Ctrl Shift L (⌘ Shift L on mac)
  • Text-oriented replacement mode: Ctrl Shift K (⌘ Shift K on mac) twice within 1 second

Document translation

doctrans.gif

Document files can be translated from v1.2.0!
Click in the upper right corner of the popup window will take you to the document translation page.
earthIcon.png

How to translate

translating.png

  1. Select a target language
  2. Choose documents you want to translate
    The following file types and extensions are supported:
  • "docx" - Microsoft Word Document

  • "pptx" - Microsoft PowerPoint Document

  • "htm / html" - HTML Document

  • "txt" - Plain Text Document

  • "pdf" - Portable Document Format
    Please note that in order to translate PDF documents you need to give one-time consent to using the Adobe API via the account interface.
    PDFTranslationSettings.png

    Please check out the official reference document for details.

  1. click Translate button and translate! Translation status will be shown in Translation status.
    • Date: Date and time of translation
    • Name: File name
    • Language: The selected target language
    • Progress: Translation progress (is automatically updated at 5-second intervals)
      • translating: Now translating.
      • done: Translation completed. Click to download the translated document.
      • error: Translation failed. The error will be alerted and removed from Translation status.

Options

You can change the language of the translated text by changing this setting.
To change the setting, please right click the icon icon24.png in the right-hand corner and select Options.
open_options.png
options.png

Target language The text will be translated into this language.
(Default: Target : English(American))

Translation icon
When "Enable", icon24.png will be displayed on the web page.
(Default:"Enable")

HoverText
hover2.gif
When "Enable", the original text is displayed under the translation (and vice versa) on text-oriented replacement mode.
(Default:"Enable")

DeepL API_KEY
The API of DeepL is available in two versions: DeepL API Free and DeepL API Pro.
Please check the version of the API you are using and configure it appropriately.

Chrome Sync

  • To use this extension, please sign in to Chrome and sync turns on. If you do not sign in or sync turns off, you will get an error like
    Error in response to storage.get: Error: Invocation of form identity.getProfileUserInfo(null, function) doesn't match definition identity.getProfileUserInfo(function callback).
    syncon.png
  • Don't want to log in to Chrome and sync? If so, there is an another version that asks for a password every time you translate for the first time after launching chrome instead of synchronization (but deprecated).

Q&A

  • I can't use page translation.
    → There are two main possibilities. The first is that the size of the page you want to translate is larger than 30kbytes. The second is CORS. In either case, please use the layout-oriented replacement mode instead. Please read the error codes in the Developer Tools for more information.

  • I can't use PDF mode on local PDF files.
    → Ensure that the "Allow access to file URLs" is checked on options page of this extension like below.
    Improper settings may cause the translation to be performed in transition mode instead of PDF mode.
    allowAccessToFileURL.png

免責事項(Disclaimer)

  • 本拡張機能は非公式です.問題がある場合は即公開停止するので,連絡してください.また,いかなる場合も,本拡張機能の利用に起因した損害に対して一切の責任と義務を負いません.
  • ページ翻訳は大量のテキストを送信する可能性があるので十分に注意して実行してください.
    意図しない挙動を起こしても一切責任を負いません.
    DeepL API を契約する際にAPI 使用額上限を低めに設定することを強く推奨します.
  • 脆弱性により API の秘密鍵等が流出する可能性があります. 使用する場合はリスクを考慮したうえで自己責任で使用してください.ソースコードの挙動を理解できない場合は使用しないでください. 開発者は一切責任を負いません.
  • 定期的に身に覚えのない API 使用履歴がないかご利用状況を確認してください.
  • 開発者はド素人なので,特に API 鍵の保存方法に関するアドバイスを頂けると幸いです.

About

Unofficial DeepL chrome extension

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 79.2%
  • HTML 14.1%
  • CSS 6.0%
  • Python 0.7%