Paperfeed / LiuChan

A Chinese mouseover dictionary extension for Chrome
https://paperfeed.github.io/LiuChan
20 stars 11 forks source link

Show the popup only in Chinese pages #23

Open taichimaeda opened 6 months ago

taichimaeda commented 6 months ago

Hi there, first of all thanks so much for creating this wonderful extension!

As a Mandarin learner myself it has been a great experience using LiuChan, but I sometimes find it inconvenient how the popup shows up even on websites in Japanese, because of the overlap between many Hanzi/Kanji characters.

This PR comes with an option (disabled by default) that uses Chrome API to detect language of the current page, and disables the content script if the language code is neither zh-CN nor zh-TW.

I understand this is no longer actively developed, but it'd be great if you could merge this - it'll be really helpful for Japanese (or Korean) readers!

Also here's some screenshots:

https://github.com/Paperfeed/LiuChan/assets/28210288/bfc74014-7070-4ffd-b779-dd6ec9948761

Paperfeed commented 5 months ago

Hey, so sorry for getting back to you so late. Somehow I completely missed this PR being opened. I will be happy to make a new release with these changes incorporated. I also need to update the manifest to v3.

taichimaeda commented 2 months ago

Hi apologies for missing your reply for quite some time, it will be great if you can merge this & update the manifest - thanks!