-
-
Notifications
You must be signed in to change notification settings - Fork 75
/
Copy pathbrowser.css
93 lines (74 loc) · 1.41 KB
/
browser.css
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
/* https://github.com/web-platform-tests/wpt/blob/master/css/selectors/is-nested.html */
#main_a .a+.b+.c>.e+.d {
color: black;
font-size: 10px;
width: 10px;
}
#main_a .e:is(.b+.f, .e:is(*, .c>.e, .g, *))+.d {
color: red;
font-size: 20px;
}
#main_a .a+.b+.c>.e+.d {
color: yellow;
}
/* Testing specificty of a class within :is() */
#main_a .a+.c>.e {
color: black;
}
#main_a .e:is(.b+.f, :is(.c>.e, .g)) {
color: red;
}
#main_a .c>.e {
color: black;
}
/* https://github.com/web-platform-tests/wpt/blob/master/css/selectors/is-specificity.html */
#main_b .b.c+.d+.q.r+.s+#target {
font-size: 10px;
height: 10px;
width: 10px;
}
#main_b :is(.a, .b.c + .d, .q)+ :is(* + .p, .q.r + .s, * + .t)+#target {
height: 20px;
width: 20px;
}
#main_b .b.c+.d+.q.r+.s+#target {
width: 30px;
}
/* https://github.com/web-platform-tests/wpt/blob/master/css/selectors/invalidation/is.html */
#main_c .b {
color: yellow;
}
/*Simple selector arguments */
#main_c .a :is(.b, .c) {
color: red;
}
/*Compound selector arguments */
#main_c .a :is(.c#d, .e) {
color: green;
}
/* Complex selector arguments */
#main_c .a .g>.b {
color: black;
}
#main_c .a :is(.e+.f, .g>.b, .h) {
color: blue;
}
#main_c .g>.b {
color: black;
}
#main_c .a .h {
color: black;
}
/* Nested */
#main_c .a+.c>.e {
color: black;
}
#main_c .c>.a+.e {
color: black;
}
#main_c .a+:is(.b+.f, :is(.c>.e, .g)) {
color: red;
}
#main_c .c>.e {
color: black;
}