Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

286
Visualizações
CSS Keyframe Animation Leaves Halo in WebKit

This is primarily happens on mobile Safari but can be reproduced on desktop too:

After a while of running in the background in a different tab or application, returning to this loaded animation results in square halos highlighting the individual moving characters. A refresh fixes this, but how can I make it stop happening in the first place? See attached for the issue and the full code below.

Any help would be insanely appreciated. ♡

CSS Keyframe Animation Halo

<html lang="en" >
<head>
  <meta charset="UTF-8">
  <title>Test</title>
  <style>
  html{
    height:100%;
    width:100%;
    background:#FFF;
  }
  
  body {
    height:100%;
    width:100%;
    display:flex;
    flex-direction: column;
    align-items:center;
    justify-content:center;
    gap:1rem;
    overflow:hidden;
  }
  
  .animated-text {
    font: 12.0vmin/1 "Helvetica";
    letter-spacing: 0.3rem;
  }
  
  .animated-text span.letter{
    display:inline-block;
  }
  
  
  
  .animated-text.tilted span.letter{
    animation: 1s tilted forwards ease-in-out infinite;
  }
  
  
  
  @keyframes tilted {
    0%{
      transform: rotateZ(-15deg);
    }
    50%{
      transform: rotateZ(15deg);
    }
    100%{
      transform: rotateZ(-15deg);
    }
  }
  
  
</style>
</head>
<body>
<!-- partial:index.partial.html -->
<span class="animated-text tilted">
STACK
</span>
<span class="animated-text tilted">
OVERFLOW
</span>

<!-- partial -->
  <script>var animatedText = document.querySelectorAll(".animated-text");
    
    function animate(element){
      var textArray = element.innerText.split("");
      element.firstChild.remove();
      
      var elArray = textArray.map(
        (letter,index)=>{
          if(letter==" ") letter = '&nbsp;';
          var el = document.createElement("span");
          el.className = "letter";
          el.innerHTML = letter;
          el.style.animationDelay = index/(textArray.length)+"s";
          element.appendChild(el);
          return el;
        }
      );
      element.innerHtml = elArray;
    }
    
    Array.from(animatedText).map(animate)</script>

</body>
</html>

https://jsfiddle.net/illustrography/pL5d321c/3/

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda