blob: 64d56bdd63227ec2a2cbb27ba6edc48bc1a2f9a3 (
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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
<html>
<head>
<style>
:visited { color: red }
:visited #l1 { color: green }
:visited > #l2 { color: green }
:visited span :visited { color: green }
:link + #span1 { color: green }
:visited + #span1 { color: red }
:link ~ #span2 { color: green }
:visited ~ #span2 { color: red }
</style>
</head>
<body>
<p>
Test that visited style matches to the topmost link in a decendant selector.
The link should be green, with red underlining.
</p>
<p>
<a href=""><span id="l1">Link</span></a>
</p>
<p>
Test that visited style matches to the topmost link in a child selector.
The link should be green, with red underlining.
</p>
<p>
<a href=""><span id="l2">Link</span></a>
</p>
<p>
Test that visited style does not match to non-topmost links.
The link should be red, with red underlining.
</p>
<p>
<a href=""><span><a href="" id="l3">Link</a></span></a>
</p>
<p>
Test that direct adjacent selector doesn't match visited style.
The link should be red, with red underlining.
The span should be green.
</p>
<p>
<a href="">Link</a>
<span id=span1>Span</span>
</p>
<p>
Test that indirect adjacent selector doesn't match visited style.
The link should be red, with red underlining.
The span should be green.
</p>
<p>
<a href="">Link</a>
<span id=span2>Span</span>
</p>
</body>
</html>
|