3 ms·
Yeah, you also have to account for box sizing by adding borders. What I've done for this in the past is use a css &:after pseudo-element and make it absolutely
by gravity13 11y ago
Yeah, you also have to account for box sizing by adding borders. What I've done for this in the past is use a css &:after pseudo-element and make it absolutely positioned, and set width and height at 100% and position it at left: 0 and top: 0. You can do things like give it a fill with opacity too, to highlight not with just outline but color overlay too.
.outlined:after {
content: "";
position: absolute;
top: 0;
width: 0;
height: 100%;
width: 100%;
background-color: green;
opacity: 0.3;
}
.outlined {
position: relative;
} // this part my be a poor assumption
- 720kb 11y agoHi, yes this is another alternative, probably the best one but it's hard actually to find the real best one because in the end everyone use different styles, different css frameworks, different use cases, in many cases it may break something in many others not, you know :) Anyway appreciated a lot your example and your tips, let's just wait for some feedback from people who use it and make decisions more clear. Thank you really :)