27 lines
1.2 KiB
HTML
27 lines
1.2 KiB
HTML
<!doctype html>
|
|
<meta charset="utf-8">
|
|
<title>CSS Pseudo-Elements Test: paired cascade: rule includes highlight pseudos other than ::selection</title>
|
|
<link rel="author" name="Delan Azabani" href="mailto:dazabani@igalia.com">
|
|
<link rel="help" href="https://drafts.csswg.org/css-pseudo-4/#highlight-cascade">
|
|
<link rel="mismatch" href="highlight-paired-cascade-004-notref.html">
|
|
<meta name="assert" value="This test verifies that setting color on ::target-text suppresses any UA non-initial used value for background-color. ::target-text is a highlight pseudo with a recommended UA default background-color that is not initial (Mark), so paired cascade can be observed.">
|
|
<link rel="stylesheet" href="../support/highlights.css">
|
|
<style>
|
|
:link, :visited {
|
|
color: blue;
|
|
}
|
|
main {
|
|
font-size: 7em;
|
|
margin: 0.5em;
|
|
}
|
|
main::target-text {
|
|
/*
|
|
Used background-color should be initial (transparent).
|
|
https://www.w3.org/TR/CSS21/colors.html#propdef-background-color
|
|
*/
|
|
color: black;
|
|
}
|
|
</style>
|
|
<p>Test passes if the text below does not appear to be highlighted (<a href="">test again</a>).
|
|
<main class="highlight_reftest">quick</main>
|
|
<script>location.href = "#:~:text=quick";</script>
|