-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathindex.html
More file actions
185 lines (140 loc) · 8.66 KB
/
Copy pathindex.html
File metadata and controls
185 lines (140 loc) · 8.66 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
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
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
<!doctype html>
<!--[if lt IE 7 ]> <html class="no-js ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]> <html class="no-js ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]> <html class="no-js ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<title>Ceaser - CSS Easing Animation Tool - Matthew Lein</title>
<meta name="description" content="Ceaser is an interactive CSS easing animation tool. It lets you build any kind of ease you want, and comes with many of the Penner Easing Equations.">
<meta name="author" content="Matthew Lein">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="http://fonts.googleapis.com/css?family=Neuton:regular" rel="stylesheet" type="text/css" >
<link rel="stylesheet" href="css/style.css?v=1.2">
<script src="js/modernizr.custom.37368.js"></script>
</head>
<body>
<div id="container">
<header>
<h1><span>Ceaser</span> CSS Easing Animation Tool</h1>
<a href="http://twitter.com/share" class="twitter-share-button" data-text="Wow. CSS Easing is now complete." data-count="none" data-via="matthewlein">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
<section class="description">
<ol>
<li>Choose an easing type and test it out with a few effects.</li>
<li>If you don’t quite like the easing, grab a handle and fix it.</li>
<li>When you’re happy, snag your code and off you go.</li>
</ol>
<p>Now that we can use CSS transitions in all the modern browsers, let’s make them pretty. I love the classic Penner equations with Flash and jQuery, so I included most of those. If you’re anything like me*, you probably thought this about the default easing options: “ease-in, ease-out...yawn.” The mysterious cubic-bezier has a lot of potential, but was cumbersome to use. Until now. <nobr>Also, touch-device</nobr> friendly!</p>
<small>*If you <em>are</em> anything like me, we should be friends <a href="http://twitter.com/matthewlein" target="_blank">@matthewlein</a></small>
<p>
<strong>Note:</strong> Bugfixes have landed, so the newest Webkit now supports values above 1 and below 0. For the time being, I am including fallback code for older Webkit that is clamped between 0 and 1 when needed.
</p>
</section>
</header>
<section class="demo">
<div class="controls clearfix">
<div class="graph">
<figure>
<canvas id="curve" width="200" height="450"></canvas>
<figcaption id="axisTime">Time</figcaption>
<figcaption id="axisAnimation">Animation (%)</figcaption>
</figure>
</div>
<div class="options">
<label for="presets"><span class="text">Easing:</span>
<select name="presets" id="presets">
<optgroup label="defaults">
<option value="0.250, 0.250, 0.750, 0.750" selected>linear</option>
<option value="0.250, 0.100, 0.250, 1.000">ease (default)</option>
<option value="0.420, 0.000, 1.000, 1.000">ease-in</option>
<option value="0.000, 0.000, 0.580, 1.000">ease-out</option>
<option value="0.420, 0.000, 0.580, 1.000">ease-in-out</option>
</optgroup>
<optgroup label="Penner Equations (approximated)">
<option value="0.550, 0.085, 0.680, 0.530">easeInQuad</option>
<option value="0.550, 0.055, 0.675, 0.190">easeInCubic</option>
<option value="0.895, 0.030, 0.685, 0.220">easeInQuart</option>
<option value="0.755, 0.050, 0.855, 0.060">easeInQuint</option>
<option value="0.470, 0.000, 0.745, 0.715">easeInSine</option>
<option value="0.950, 0.050, 0.795, 0.035">easeInExpo</option>
<option value="0.600, 0.040, 0.980, 0.335">easeInCirc</option>
<option value="0.600, -0.280, 0.735, 0.045">easeInBack</option>
<option value="0.250, 0.460, 0.450, 0.940">easeOutQuad</option>
<option value="0.215, 0.610, 0.355, 1.000">easeOutCubic</option>
<option value="0.165, 0.840, 0.440, 1.000">easeOutQuart</option>
<option value="0.230, 1.000, 0.320, 1.000">easeOutQuint</option>
<option value="0.390, 0.575, 0.565, 1.000">easeOutSine</option>
<option value="0.190, 1.000, 0.220, 1.000">easeOutExpo</option>
<option value="0.075, 0.820, 0.165, 1.000">easeOutCirc</option>
<option value="0.175, 0.885, 0.320, 1.275">easeOutBack</option>
<option value="0.455, 0.030, 0.515, 0.955">easeInOutQuad</option>
<option value="0.645, 0.045, 0.355, 1.000">easeInOutCubic</option>
<option value="0.770, 0.000, 0.175, 1.000">easeInOutQuart</option>
<option value="0.860, 0.000, 0.070, 1.000">easeInOutQuint</option>
<option value="0.445, 0.050, 0.550, 0.950">easeInOutSine</option>
<option value="1.000, 0.000, 0.000, 1.000">easeInOutExpo</option>
<option value="0.785, 0.135, 0.150, 0.860">easeInOutCirc</option>
<option value="0.680, -0.550, 0.265, 1.550">easeInOutBack</option>
</optgroup>
<optgroup label="custom">
<option value="0.500, 0.250, 0.500, 0.750">custom (drag the handles)</option>
</optgroup>
</select>
</label>
<label for="time"><span class="text">Duration:</span>
<input type="number" step="100" value="500" size="7" maxlength="4" pattern="[0-9]*" name="time" value="time" id="time">
</label>
<label for="buttons"><span class="text">Effect:</span>
<input type="button" name="left" value="left" id="left" class="testButton">
<input type="button" name="width" value="width" id="width" class="testButton">
<input type="button" name="height" value="height" id="height" class="testButton">
<input type="button" name="opacity" value="opacity" id="opacity" class="testButton">
</label>
<div class="anim">
<div id="box"><!-- demo thing is here --></div>
</div>
</div>
</div>
<div id="snippets">
<h3>Code snippets, short and long-hand:</h3>
<code id="codeOutput"><!-- codez go here --></code>
</div>
<div id="donate">
<p>If this saves you time, or blows your mind, consider making a <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZE64V33WCDFMQ" class="donation">donation</a> to keep these projects alive.</p>
</div>
</section>
<section id="resources">
<h2>Resources</h2>
<ul>
<li>Very nice overview of CSS Transitions and Animation: <a href="http://css3.bradshawenterprises.com/" target="_blank">http://css3.bradshawenterprises.com/</a></li>
<li>Jared Hardy’s Ceaser Compass extension: <a href="https://github.com/jhardy/compass-ceaser-easing" target="_blank">https://github.com/jhardy/compass-ceaser-easing</a></li>
<li>Excellent CSS3 LESS mixin by Matthew Wagerfield: <a href="https://github.com/MatthewWagerfield/LESS-CSS3-Mixins" target="_blank">https://github.com/MatthewWagerfield/LESS-CSS3-Mixins</a></li>
<li>Ceaser TextMate Bundle: <a href="https://github.com/matthewlein/Ceaser-CSS-Easing-tmbundle" target="_blank">https://github.com/matthewlein/Ceaser-CSS-Easing-tmbundle</a></li>
<li>LESS easing by Kirk Strobeck <a href="https://github.com/kirkstrobeck/bootstrap/blob/master/less/easing.less" target="_blank">https://github.com/kirkstrobeck/bootstrap/blob/master/less/easing.less</a></li>
<li>Ceaser cubic bezier’s in <a href="https://github.com/matthewlein/Ceaser/tree/master/developer" target="_blank">JS/LESS/SASS for plugin/mixin developers</a></li>
<li>AppMobi did a simple how-to video for Ceaser <a href="http://youtu.be/xv92qmlqZa4" target="_blank">on Youtube</a></li>
<li>-ms- prefix was <a href="http://www.impressivewebs.com/dropping-ms-vendor-prefixes-ie10/" target="_blank">never really needed</a></li>
</ul>
</section>
<section id="needs">
<del datetime="2011-10-12T21:45:23-0400"><p><strong>Webkit/Safari/Chrome desicion-makers:</strong> Hoping Bug <a href="https://bugs.webkit.org/show_bug.cgi?id=45761" target="_blank">45761</a> gets fixed/implemented soon so I can add easeBack effects.</p></del>
<p>
Let the good times roll!
</p>
</section>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"></script>
<script>window.jQuery || document.write("<script src='js/jquery-1.5.1.min.js'>\x3C/script>")</script>
<script src="js/ceaser.js?v1.3"></script>
<section id="comments">
<script>
var disqus_identifier = 'Ceaser';
</script>
<!--#include virtual="/inc/experiment-disqus.html" -->
</section>
</div>
<!--#include virtual="/inc/google.html" -->
<section id="oldBrowser">
Your browser does not support CSS transitions. Firefox 4, Safari & Chrome have what it takes.
</section>
</body>
</html>