-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcorner.html
More file actions
81 lines (72 loc) · 1.39 KB
/
corner.html
File metadata and controls
81 lines (72 loc) · 1.39 KB
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
<!DOCTYPE html>
<html>
<head>
<title>corner圆角布局</title>
<style type="text/css">
body {
background-color: #000;
}
.corner {
position: fixed;
width: 100px;
height: 100px;
background-color: #fff;
border-radius: 50%;
transition:width 2s, height 2s, left 2s, top 2s, right 2s, bottom 2s
}
.corner:hover{
width: 200px;
height: 200px;
}
.corner.left {
left: -50px;
}
.corner.left:hover{
left: -100px;
}
.corner.right {
right: -50px;
}
.corner.right:hover {
right: -100px;
}
.corner.top {
top: -50px;
}
.corner.top:hover {
top: -100px;
}
.corner.bottom {
bottom: -50px;
}
.corner.bottom:hover {
bottom: -100px;
}
.circle{
position: fixed;
width: 100px;
height: 100px;
border-radius: 50%;
background-color: #fff;
left: 50%;
top: 50%;
margin-left: -50px;
margin-top:-50px;
transition: width 2s, height 2s, margin 2s
}
.circle:hover{
width: 200px;
height: 200px;
margin-left: -100px;
margin-top:-100px;
}
</style>
</head>
<body>
<div class="corner left top"></div>
<div class="corner left bottom"></div>
<div class="corner right top"></div>
<div class="corner right bottom"></div>
<div class="circle"></div>
</body>
<html>