summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-pseudo/target-text-010.html
blob: 4aae966a2d0da7e8a0bab5f032acf012d772b2bd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<!doctype html>
<html class="reftest-wait">
<meta charset="utf-8">
<title>CSS Pseudo-Elements Test: ::target-text color rendering - overlap targets with hidden: until-found</title>
<link rel="author" title="Stephen Chenney (Igalia)" href="mailto:schenney@chromium.org">
<link rel="help" href="https://drafts.csswg.org/css-pseudo/#selectordef-target-text">
<link rel="match" href="target-text-five-words-ref.html">
<script src="/common/reftest-wait.js"></script>
<style>
  div { display: inline; }
  ::target-text {
    color: darkgrey;
    background-color: orange;
  }
</style>
<p>PASS if <div hidden="until-found">"match</div> me and me"</p>
<p>is rendered dark grey on an orange background.</p>
<script>
  window.location.hash = "#:~:text=match,me&text=me%20and%20me";
  requestAnimationFrame(() => requestAnimationFrame(() => {
    requestAnimationFrame(() => takeScreenshot());
  }));
</script>
</html>