testing/web-platform/tests/css/css-backgrounds/background-clip/clip-text-animated-text.html
author Cosmin Sabou <csabou@mozilla.com>
Sat, 12 Jul 2025 09:18:08 +0300 (9 hours ago)
changeset 796290 5ad1f0c58c82bdfa2f42fed870bbe143465398d0
parent 748612 b9facc68e8e95f92ea79a1f4d0af83cb843fa9be
permissions -rw-r--r--
Revert "Bug 1977019 - re-enable hw video decoding testing. r=media-playback-reviewers,jolin" for causing win mda failures on test_hw_video_decoding.html This reverts commit 158474bdc0cf585b701bc47921f0a7d84f7bb84d.
<!doctype html>
<html class="reftest-wait">
<title>CSS Test: background-clip: text animated text</title>
<link rel="help" href="https://drafts.csswg.org/css-backgrounds-4/#valdef-background-clip-text">
<link rel="author" href="mailto:nathan@knowler.dev" title="Nathan Knowler">
<link rel="match" href="clip-text-animated-text-ref.html">
<style>
  .text {
    background-color: DeepPink;
    background-clip: text;
    font-size: 50px;
    font-family: sans-serif;
    font-weight: 600;
    color: transparent;
  }

  .text p {
    animation: fade-in 0.1s both;
  }

  @keyframes fade-in {
    from { opacity: 0; }
  }
</style>
<div class="text">
  <p>Text</p>
</div>
<script>
  const [animation] = document.querySelector(".text p").getAnimations();
  animation.finished.then(() => {
    document.documentElement.classList.remove("reftest-wait");
  });
</script>