Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Incorrect border rendering when using css transform in Firefox

Tags:

html

css

firefox

I have a simple CSS arrow like this:

.arrow-brown {
    height: 18px;
    width: 18px;
    border-top: 6px solid #39170b;
    border-right: 6px solid #39170b;
    -moz-transform: rotate(-45deg);
    -ms-transform: rotate(-45deg);
    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);
}

In Firefox the borders are not rendered correctly, two thin white lines are appearing accross the border width. Is there any workaround to get rid of them??

Here's the rendered picture: https://i.sstatic.net/zUsoQ.png

And here's the fiddle: https://jsfiddle.net/w2s9gp8w/

like image 465
xbilek18 Avatar asked Mar 05 '26 11:03

xbilek18


1 Answers

That worked for me:

transform-style: preserve-3d;
like image 75
PawelGIX Avatar answered Mar 08 '26 01:03

PawelGIX



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!