-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCh3.css
100 lines (69 loc) · 1.5 KB
/
Ch3.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
<style>
/* @group general styles
--------------------------------------------------------*/
/* @group helper styles
--------------------------------------------------------*/
/* @group page structure
--------------------------------------------------------*/
/* @group page components
--------------------------------------------------------*/
/* 1. the horizontal margin or the height or width of an inline box can't change the heigtht of the line*/
#str {
/* color: blue;*/
}
.sss {
color: red;
margin: 50px;
font-size: 50px;
height: 100px;
width: 100px;
}
#ppp {
padding: 90px;
padding-left: 0px;
padding-right: 0px;
margin-top: 40px;
margin-bottom: 40px;
}
/* 3. abosolute position*/
#branding {
position: relative;
height: 400px;
width: 400px;
border: 1px black solid;
}
#branding .tel {
position: absolute;
right: 2px;
bottom: 2px;
}
/* 4. float */
#floatImg {
float: left;
height: 20%;
}
#secondPara {
clear: left;
}
/* 4.2 float 2 */
.news {
border: 10px solid green;
background-color: grey;
}
.news img {
float: left;
height: 20%;
}
/*@/? ??????????????????????????????why <p> doesn't float?????*/
/*cause too much words in <p></p> so it takes the whole width of the parent element(<body>, so floating left or right doesn't make a difference*/
.news p {
float: right;
}
/*
.news hr {
clear: both;
}
*/
/* @group override
________________________________________________________*/
</style>