To implement some fancy round progress bars, I used an element with border radius and overflow:hidden. Everything looks fine, except one thing: all browsers display a thin line where the overflow ends.
here's some simple snippet that reproduces this bug in all major browsers:
function setMarginLeft(value){
var element = document.querySelector(".overflowing");
element.style.marginLeft = value+"px";
}
function setMarginTop(value){
var element = document.querySelector(".overflowing");
element.style.marginTop = value+"px";
}
.backdrop {
background-color: white;
padding: 10px;
width:100px;
height:100px;
}
.circle {
background-color: red;
width:100px;
height:100px;
border-radius: 100px;
overflow:hidden;
}
.overflowing {
width:200px;
height:200px;
margin-top: 10px;
margin-left: 10px;
background-color:#fff;
}
input {
margin-top:10px;
}
<div class="backdrop">
<div class="circle">
<div class="overflowing"></div>
</div>
</div>
<span>top and right of the circle you should see some red, bottom left not</span><br />
<em>Feel free to play around with these values:</em><br />
Top margin: <input type="number" id="cngMargin" oninput="setMarginTop(this.value)" value="10"><br />
Left margin: <input type="number" id="cngMargin" oninput="setMarginLeft(this.value)" value="10">
since the layout isn't nearly as easy as the snippet above, i can't change the layout much. i guess the essential problem here is the browser's anti-aliasing, which i think is not alterable by css, or is it?
i googled myself stupid on that matter and can't come up with really usefull ressources. i guess if nothing else works, i'll have to do it anew in SVG or on a canvas -.-

margin-topandmargin-lefton the.overflowingelement? Without that I don't see the bleed.