In certain conditions (e.g. with general directive body { color: #fff }), the translated text may appear as white text on white background.
Possible cause:
The .translation area created to hold the translated text has a css directive font-color: inherit but the parent element does not specify any font-color directive.
As a result the translation area inherits its font-color from outside the web-extension context.
Hi and thanks for that great project 👍
Problem:
In certain conditions (e.g. with general directive
body { color: #fff }
), the translated text may appear as white text on white background.Possible cause:
The
.translation
area created to hold the translated text has a css directivefont-color: inherit
but the parent element does not specify anyfont-color
directive.As a result the translation area inherits its font-color from outside the web-extension context.
https://github.com/jelmervdl/translatelocally-web-ext/blob/main/src/content/SelectionTranslation.css#L27
[edit] Actually the parent element
#x-bergamot-translation-popup
specifies a cssbackground-color
value whereas it should also inherit.