CSS uses the properties of other components

is it possible to implement the properties of one component using other components in css?

for example, a component .class1 {background-color: black;},
now wants the color attribute of .class to be black, but hopes to achieve the effect of "when replacing the background-color of class1, the color attribute of class2 will also be replaced by Synchronize". Can it be achieved only with css?

Css
Mar.09,2021

you can use CSS variable

  http://www.zhangxinxu.com/wor.

Menu