forked from maccman/gfx
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
147 lines (120 loc) · 4.39 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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="description" content="GFX - a 3D CSS3 animation library for jQuery">
<meta name="keywords" content="gfx,3d,css3,animation,jquery,transitions">
<title>GFX</title>
<link rel="stylesheet" href="site/site.css" type="text/css" charset="utf-8">
<script src="site/jquery.js" type="text/javascript" charset="utf-8"></script>
<script src="lib/gfx.js" type="text/javascript" charset="utf-8"></script>
<script src="lib/gfx.effects.js" type="text/javascript" charset="utf-8"></script>
<script src="lib/gfx.overlay.js" type="text/javascript" charset="utf-8"></script>
<script src="lib/gfx.flip.js" type="text/javascript" charset="utf-8"></script>
<script src="lib/gfx.cube.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" charset="utf-8">
jQuery(function($) {
$("#container").gfxPopIn({
scale: ".8"
});
if ( !$.browser.webkit )
$("#unsupported").show()
$("#crazy").click(function() {
return $(this).gfx({
scale: "1.5",
rotate: "180deg"
}).delay(100).gfx({
scale: "1"
}).gfx({
rotate: "0deg",
translateX: "-100px"
}).gfx({
translateX: "100px"
}).gfx({
translateX: 0
}).gfxExplodeOut().delay(100).gfxExplodeIn().gfxShake().gfx({
background: "#FFFFD1"
}).gfx({
background: "#E3E3E3"
});
});
$(".about").click(function() {
return $.gfxOverlay("#aboutText", {
css: {
width: 300,
height: 130
}
});
});
$("#flip").gfxFlip().click(function() {
return $(this).trigger("flip");
});
$("#shake").click(function() {
return $(this).gfxShake();
});
$("#explode").click(function() {
return $(this).gfxExplodeOut({
reset: false
}).delay(300).gfxExplodeIn();
});
$("#cube").gfxCube({
width: 500,
height: 290
});
$("#main .download").click(function() {
return $("#cube").trigger("cube", "right");
});
return $("#main .back").click(function() {
return $("#cube").trigger("cube", "front");
});
});
</script>
<script type="text/plain" id="aboutText">
<h2>About</h2>
<p>GFX was created by <a href="http://alexmaccaw.co.uk">Alex MacCaw</a>.</p>
<p><a href="http://twitter.com/maccman">Friend him</a> on Twitter.</p>
</script>
</head>
<body>
<div id="container">
<div id="inner">
<div id="unsupported"><h2>Sorry, your browser isn't fully supported yet. <br /> Things on this site may not work!</h2></div>
<div id="main">
<div id="cube">
<div class="box front face">
<h1>GFX - a 3D CSS3 animation library for jQuery</h1>
<p>GFX integrates CSS3 transforms and transitions into <a href="http://jquery.com">jQuery</a>, making it stupidly simple to create sophisticated and gorgeous animations.</p>
<pre><code>$(this).gfx({scale: "1.5"})
.delay(100)
.gfx({scale: "1"})
.gfx({rotate: "180deg"})
.delay(300)
.gfx({rotate: "0deg"})
.gfx({translateX: "100px", opacity: 0.2})
.gfx({translateX: 0, opacity: 1})
.gfxExplodeOut().delay(100).gfxExplodeIn()
.gfxShake();</code></pre>
<footer><a class="about">About</a> <a class="download">Download & docs » </a></footer>
</div>
<div class="box right face">
<h2>Download GFX</h2>
<p>Download the <a href="https://github.com/maccman/gfx/tarball/gh-pages">latest version (0.0.1)</a>, or checkout the <a href="http://github.com/maccman/gfx">source</a>.</p>
<h2>Documentation</h2>
<p>You can find the libraries documentation in the <a href="https://github.com/maccman/gfx/blob/master/README.md">README</a></p>
<footer><a class="back">« Back</a></footer>
</div>
</div>
</div>
<div id="examples">
<div id="flip" class="item">
<div class="box front"><h2>Flip</h2></div>
<div class="box back"><h2>Flipped!</h2></div>
</div>
<div id="explode" class="box item"><h2>Explode</h2></div>
<div id="shake" class="box item"><h2>Shake</h2></div>
<div id="crazy" class="box item"><h2>Crazy</h2></div>
</div>
</div>
</div>
</body>
</html>