-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrainbow.css
89 lines (77 loc) · 1.67 KB
/
rainbow.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
/*
.rainbow > div rainbow里面的第一个div
.rainbow div rainbow里面的所有的div
去掉border后回外边距合并
color: hsl(180, 50%, 50%); 色相, 饱和度, 亮度
*/
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
/* border: 1px solid yellowgreen; */
background-color: #fff;
}
.rainbow { /* 类名为rainbow的div */
height: 200px;
overflow: hidden;
}
.rainbow div {
overflow: hidden;
}
.rainbow > div { /* rainbow 后面第一个div */
/* border: 1px solid #ff0000; */
background-color: #ff0000;
width: 400px;
height: 400px;
border-radius: 50%;
}
.rainbow > div > div {
/* border: 1px solid #ffa500; */
background-color: #ffa500;
height: 380px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div {
/* border: 1px solid #ffff00; */
background-color: #ffff00;
height: 360px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div > div {
/* border: 1px solid #008000; */
background-color: #008000;
height: 340px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div > div > div {
/* border: 1px solid #0000ff; */
background-color: #0000ff;
height: 320px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div > div > div > div {
/* border: 1px solid #4b0082; */
background-color: #4b0082;
height: 300px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div > div > div > div > div {
/* border: 1px solid #ee82ee; */
background-color: #ee82ee;
height: 280px;
margin: 10px;
border-radius: 50%;
}
.rainbow > div > div > div > div > div > div > div > div {
background-color: #fff;
height: 260px;
margin: 10px;
border-radius: 50%;
}