3 ms·
I like how the result text switches from white to black depending on the brightness of the selected background color. does anyone know how this is done? I could
by swyx 6y ago
I like how the result text switches from white to black depending on the brightness of the selected background color. does anyone know how this is done? I could use this algorithm in other projects
- pmhpereira 6y agoIt's called Luminance Contrast: https://stackoverflow.com/a/36888120 https://stackoverflow.com/a/36888120
- swyx 6y agoty!