CSS multiple borders aren't changed in dynamic width
I written multiple borders using pseudo elements way of CSS-tricks.
<span class="something">
label: <span id="count">20</span>
</span>
CSS style is like this:
.something {
background-color: #B3B3B3;
padding: 10px;
position: relative;
border: 2px solid #000;
}
.something:before {
content: " ";
display: block;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
border: 2px solid #FF6666;
}
It looks good. but if I changed count, it cause change width and inner
border isn't changed like this:
You can see this demo at jsfiddle. How can I fix it?
No comments:
Post a Comment