https://gist.github.com/Rudo2204/7327a5bd25a60aefee963fd65327a9b7
- Add it to your yomichan.
- It supports 8 dictionaries (the "recommended for first time monolingual users" from the guide).
glossary-jmdict
glossary-jmdict-compact : same as above, it only replaces linebreak with one single space to make it more compact. Could be useful.
glossary-kenkyusha
glossary-kensyusha-ne : ne stands for no-example. This basically removes all the example sentences from the entry.
glossary-kireicake
glossary-meikyou
glossary-shinjirin
glossary-shinmeikai
glossary-jitsuyou
glossary-daijisen
- You can also add
-brief
or-no-dictionary
(e.g:{glossary-shinmeikai-no-dictionary}
) to remove dictionary's name. - I totally stole
ッツ#0176
's template so it also supports:one-dict
(paste one dictionary entry),two-dict
(paste at most two dictionary entries) (These paste the first one/two dictionary entries depending on your dictionary priority in yomichan's settings) - NOTE 1:
For these 3 dictionaries JMDict, Kenkyusha, Shinjirin I removed the first line which contains reading guide for the word (you can get reading from{reading}
{furigana-plain}
already so I decided to remove it).
If you want them back for whatever reason you can search forinline "glossary-<name>"
, edit the second line after that fromglossary-all-remove-first
toglossary-all-generic
.
If you want to remove the first line of other dictionaries too, changegeneric
toremove-first
. - NOTE 2: I removed aligning left divs (it's better to do it inside anki using card's template) so if your card somehow get messed up this is probably why.
- Add these before the
{{~> (lookup . "marker") ~}}
line (near end of file):
{{~#*inline "glossary-NAME"~}}
{{~> glossary-all-generic brief=brief noDictionaryTag=noDictionaryTag targetDictionary="DICTIONARY-NAME" ~}}
{{~/inline~}}
{{#*inline "glossary-NAME-no-dictionary"}}
{{~> glossary-NAME noDictionaryTag=true ~}}
{{/inline}}
{{#*inline "glossary-NAME-brief"}}
{{~> glossary-NAME brief=true ~}}
{{/inline}}
- Change NAME to whatever you want and DICTIONARY-NAME to the dictionary name you get from yomichan.
- (Optional) If you want to remove the first line you can change
generic
toremove-first
Let's say we want to add ヨガ日本語アクセント辞典
. We name it as accent
. So this is what you paste in your handlebars.
{{~#*inline "glossary-accent"~}}
{{~> glossary-all-generic brief=brief noDictionaryTag=noDictionaryTag targetDictionary="ヨガ日本語アクセント辞典" ~}}
{{~/inline~}}
{{#*inline "glossary-accent-no-dictionary"}}
{{~> glossary-accent noDictionaryTag=true ~}}
{{/inline}}
{{#*inline "glossary-accent-brief"}}
{{~> glossary-accent brief=true ~}}
{{/inline}}
This is amazing. Thank you!