You Can Achieve the Effect
Technically the answer "no" is correct. However, because we are talking about "lightening" (or "darkening"), that is, adding white or black, then the effect can be achieved still through either css3 rgba()
colors or opacity
on a pseudo element. Consider these (each would be used on the child element):
Opt #1: CSS3 rgba
.lighten {
background-color: rgba(255, 255, 255, 0.3);
}
Opt #2: CSS2 Pseudo-element with opacity
.lighten{
position: relative;
z-index: 0;
}
.lighten:before {
content: '';
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: -1;
background-color: #fff;
opacity: 0.3;
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…