grav-theme-learn2 icon indicating copy to clipboard operation
grav-theme-learn2 copied to clipboard

Translation for special blockquotes

Open rbukovansky opened this issue 8 years ago • 4 comments

Hi, there are 4 words used for special blockquotes in this theme (Warning, Info, Note, Tip), unfortunatelly CSS files are SCSS (if my understanding is correct). Is there any way how to leverage using languages.yaml file to translate those strings?

rbukovansky avatar Feb 10 '17 14:02 rbukovansky

This issue was also raised in https://github.com/getgrav/grav-learn/issues/385#issuecomment-277556194

flaviocopes avatar Feb 10 '17 18:02 flaviocopes

@flaviocopes OK. So, will there be any solution for it? It seems to be really great feature, but this way it's not usable for non-EN pages...

Proposal: During translation of page from MD&Twig to HTML, put that text there in proper place and then using CSS just show it or hide it. Is it doable?

rbukovansky avatar Feb 22 '17 13:02 rbukovansky

The non-english pages could automatically load a language-specific CSS, like css/ru.css, and in this file, override those CSS rules to add the russian translation.

flaviocopes avatar Feb 22 '17 14:02 flaviocopes

Does it work it now?

rbukovansky avatar Feb 23 '17 09:02 rbukovansky