Carousel bootstrap text dims in Safari

I am using Bootstrap 3.3.1, and I notice that the text dims when the carousel scrolls in Safari. Chrome is fine.

Here is a demo using the sample code from the official website: http://s.codepen.io/resting/debug/QwEoPp ?
Pen: http://codepen.io/resting/pen/QwEoPp

the code:

<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
  <!-- Indicators -->
  <ol class="carousel-indicators">
    <li data-target="#carousel-example-generic" data-slide-to="0" class="active"></li>
    <li data-target="#carousel-example-generic" data-slide-to="1"></li>
    <li data-target="#carousel-example-generic" data-slide-to="2"></li>
  </ol>

  <!-- Wrapper for slides -->
  <div class="carousel-inner" role="listbox">
    <div class="item active">
      <img src="http://placehold.it/1024x400" alt="...">

      <div class="carousel-caption">
        ...
      </div>
    </div>
    <div class="item">
      <img src="http://placehold.it/1024x400" alt="...">

      <div class="carousel-caption">
        ...
      </div>
    </div>
    ...
  </div>

  <!-- Controls -->
  <a class="left carousel-control" href="#carousel-example-generic" role="button" data-slide="prev">
    <span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
    <span class="sr-only">Previous</span>
  </a>
  <a class="right carousel-control" href="#carousel-example-generic" role="button" data-slide="next">
    <span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
    <span class="sr-only">Next</span>
  </a>
</div>

<div class="container-fluid">

  <div class="row">
    <div class="col-xs-12">
      Text dim in Safari when carousel scrolls.
    </div>
  </div>
</div>

Does anyone have any fix for this?

+4
source share
2 answers

Have you tried to add text -webkit-transform-style: preserve-3d;or -webkit-backface-visibility: hidden;to text? Generally, flickering of text on a safari is a common problem, and these are two common fixes.

.carousel-inner {
  -webkit-transform-style: preserve-3d;
  -webkit-backface-visibility: hidden;
}
+3
source

.carousel-inner {
  -webkit-transform-style: preserve-3d;
}
+4

Source: https://habr.com/ru/post/1568535/


All Articles