D
D
Dima2020-06-25 10:58:01
css
Dima, 2020-06-25 10:58:01

How to automatically make text white if the background is dark and vice versa?

there is a background. it changes. It has a link with text in one place. how to understand on what background the text is dark or light?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Seanyr, 2020-06-25
Dolgoter @SpiderPigAndCat

There is such an interesting thing as mix-blend-mode
You can use it like this:

Example

здесь применяется просто разница цветов, но у него есть и куча других значений

Support is not bad , only IE is in flight

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question