-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
101 lines (90 loc) · 2.26 KB
/
index.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
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
94
95
96
97
98
99
100
101
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Pure css ripple effect</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css">
<style type="text/css">
* {
padding:0;
margin:0;
}
body {
font-family:Verdana, Geneva, sans-serif;
font-size:18px;
background-color:#FFF;
background-color:#EEE;
}
.ripple-button1, .ripple-button2{
position:relative;
width:150px;
height:75px;
background-color:#99C;
color:#FFF;
border-radius:3px;
text-decoration:none;
text-align:center;
vertical-align:middle;
display:table-cell;
}
.wave1{
position:absolute;
width:75px;
height:75px;
background-color:#FFF;
top:0;
left:35px;
transform: scale(0);
opacity:0.5;
border-radius:300px;
}
.wave2{
position:absolute;
width:150px;
height:75px;
background-color:#FFF;
top:0;
left:0;
transform: scale(0);
opacity:0.5;
}
.ripple-button1:hover > .wave1{
animation: ripple-in1 2s;
}
.ripple-button2:hover > .wave2{
animation: ripple-in2 2s;
}
@keyframes ripple-in1 {
0% {transform: scale(0);}
20%{transform: scale(1);opacity:0.3;}
100%{transform: scale(1);opacity:0;}
}
@keyframes ripple-in2 {
0% {transform: scaleX(0);}
20%{transform: scaleX(1);opacity:0.3;}
100%{transform: scaleX(1);opacity:0;}
}
</style>
</head>
<body>
<!-- Our Page Header -->
<header style="width:100%;background-color:#333;">
<div style="float:left;padding:15px;">
<a href="http://androidcss.com" title="androidcss" rel="home" style="font-size:24px;text-decoration:none;color:#FFF;"><span style="color:#690">Android</span><span style="color:#CCC">CSS</span></a>
</div>
<div style="float:right;padding:15px;">
<a href=" http://androidcss.com/css/pure-css-ripple-effect/" style="color:#FFF;font-size:16px;">Tutorial</a>
</div>
<div style="clear:both;"></div>
</header>
<!-- Heading/Title -->
<h1 style="margin:15px;text-align:center;font-size:30px;">Pure css ripple effect demo</h1>
<!-- Actual Demo code starts here -->
<div style="width:200px;margin:auto;">
<a href="#" class="ripple-button1"><div class="wave1"></div>Ripple1</a>
<a href="#" class="ripple-button2"><div class="wave2"></div>Ripple2</a>
</div>
</body>
</html>