light-dark function

preview_player
Показать описание
The light-dark() function in CSS lets developers more easily adapt a color-scheme to a user's preference for light or dark mode.
Use the light-dark() function to specify two different color values within a single CSS property. The browser (or device) will automatically choose the appropriate color based on the element's computed color-scheme value.

Speaker: Adriana Jara
Рекомендации по теме
Комментарии
Автор

This is also amazing! It's a great time to be a web dev

DarrenbyDesign
Автор

Why are we taking this out of a query? Why this and not other query types?

MrQuickLine
Автор

Would be more useful if it could be used to set a custom property and then have the individual css rules reference the custom property as we do currently.

robertedgar
Автор

Where does the user select the theme from though

broleemusic
Автор

Much better to have bunch of .less files (or what ever you like) with styles but variables instead of colors and two-three-ten-hundred files with values for this variables, one file per color scheme.

Lord_Omni