Search code examples
cssgoogle-chromergba

Weird outline around rgba letter


I added a rgba color to a letter on a dark background and there is a very small white outline around it in Chrome (67). I forced a outline: none but nothing changed.

weird outline

body {
 background: #575354;
}

span.letter-back{
  top:-40px;
  z-index: 1;

  color:rgba(237, 28, 36, 0.3);
  font-size:300px;
  font-weight:900;
  font-family: sans-serif;

  outline:none !important;
}
<span class="letter-back">B</span>

Any ideas? Thanks!


Solution

  • Try using rgb to define the color and set opacity to .3

    span.letter-back {
     color:rgb(237, 28, 36);
     opacity: .3;
    }
    

    It renders differently than RGBA.