-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhas.html
54 lines (51 loc) · 1.78 KB
/
has.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://pro.fontawesome.com/releases/v5.15.3/css/all.css"
integrity="sha384-iKbFRxucmOHIcpWdX9NTZ5WETOPm0Goy0WmfyNcl52qSYtc2Buk0NCe6jU1sWWNB" crossorigin="anonymous">
<link rel="stylesheet" href="css/has.css">
<script src="https://kit.fontawesome.com/b182c44c0a.js" crossorigin="anonymous"></script>
<title>has</title>
</head>
<body>
<div class="container">
<header>
<h1>:has</h1>
<p>A parent selector!</p>
</header>
<main>
<div class="parent">
<code>
:has(.planet) <br />
background: pink
</code>
<i class="fa-sharp fa-solid fa-planet-ringed"></i>
</div>
<div class="parent">
<i class="fa-sharp fa-solid fa-popsicle"></i>
<code>
:has(.popsicle) <br />
background: green
</code>
</div>
<div class="parent">
<i class="fa-sharp fa-solid fa-football-helmet"></i>
<code>
:has(.helmet) <br />
background: blue
</code>
</div>
<div class="parent">
<code>
:has(.star) <br />
background: orange
</code>
<i class="fa-sharp fa-solid fa-star-shooting"></i>
</div>
</main>
</div>
</body>
</html>