-
Notifications
You must be signed in to change notification settings - Fork 24
/
Copy pathtransform.html
61 lines (55 loc) · 1.2 KB
/
transform.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
<!doctype html>
<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test: Transform</title>
<style>
body{
margin:0;
padding:0;
}
.square{
position: relative;
display: inline-block;
left:0;
width: auto;
height: auto;
vertical-align: text-bottom;
color: #fff;
background-color: #000;
padding: 20px;
margin-bottom: 5%;
}
#square_4{
background-color: #090;
transform: translateX(500px) scaleX(2) rotateZ(45deg) skewX(50deg);
}
</style>
</head>
<body>
<br><br><br><br>
<div id="square_1" class="square">1</div><br>
<div id="square_2" class="square">2</div><br>
<div id="square_3" class="square">3</div><br>
<div id="square_4" class="square">4</div><br>
<script type="text/javascript" src="../fat.js"></script>
<script>
Fat.transform("#square_1", {
translateX: "+=500px",
scaleX: 2,
rotateZ: "45deg",
skewX: "50deg"
},{
duration: 2000
});
Fat.animate("#square_2", {
transform: "translateX(+=500px) scaleX(*=2) rotateZ(45deg) skewX(50deg)"
},{
duration: 2000
});
Fat.transform("#square_3", "translateX(+=500px) scaleX(*=2) rotateZ(45deg) skewX(50deg)",{
duration: 2000
});
</script>
</body>
</html>