-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
executable file
·728 lines (683 loc) · 27.6 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
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
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>FITC Amsterdam 2016 - Creating a Beautiful CSS3 Animations</title>
<meta name="description" content="FITC Amsterdam 2016 - Creating a Beautiful CSS3 Animations">
<meta name="author" content="Rami Sayar">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, minimal-ui">
<link rel="stylesheet" href="css/reveal.css">
<link rel="stylesheet" href="css/theme/black.css" id="theme">
<!-- Code syntax highlighting -->
<link rel="stylesheet" href="lib/css/zenburn.css">
<!-- Printing and PDF exports -->
<script>
var link = document.createElement( 'link' );
link.rel = 'stylesheet';
link.type = 'text/css';
link.href = window.location.search.match( /print-pdf/gi ) ? 'css/print/pdf.css' : 'css/print/paper.css';
document.getElementsByTagName( 'head' )[0].appendChild( link );
</script>
<!--[if lt IE 9]>
<script src="lib/js/html5shiv.js"></script>
<![endif]-->
<style>
.trans-anim {
transition:all 2s ease-in-out;
perspective: 800px;
perspective-origin: 50% 100px;
}
</style>
</head>
<body>
<!--
Use h1 for slides with only a title
Use h2 for slides with title & content
-->
<div class="reveal">
<div class="slides">
<section>
<h1>Creating Beautiful CSS Animations</h1>
<h3><a href="https://twitter.com/ramisayar">@ramisayar</a></h3>
<p>
<small>FITC Amsterdam 2016</small>
</p>
</section>
<section>
<section data-markdown>
## Agenda
* History of Animation on the Web
* Introducing CSS3 Animations
* Browser Compatibility
* CSS3 Animation Libraries
* Principles for Beautiful Animations
</section>
<section data-markdown>
## Assumptions
* You know what the web is…
* Working knowledge of HTML5 & CSS3.
* Slides will be made available on [SlideShare.net/RamiSayar](http://slideshare.net/ramisayar)</a>
</section>
<section data-background="img/ramisayar.png">
</section>
<section data-background="img/snowyowlmtl.png">
</section>
</section>
<section>
<section>
<iframe width="1280" height="768" data-src="ripgeocities.html"></iframe>
</section>
<section>
<h1><a href="http://www.cameronsworld.net/" data-preview-link>Cameron's World</a></h1>
</section>
</section>
<section>
<section>
<h1>And then there was flash</h1>
</section>
<section>
<h2>It was a very dark time for the web. I can’t believe this still <a href="http://industrialpainter.com" data-preview-link>exists</a>... </h2>
</section>
<section>
<h1>Classic Flash Animations</h1>
</section>
<section>
<iframe width="640" height="480" src="https://www.youtube.com/embed/AYdDRTRaWr8" frameborder="0" allowfullscreen></iframe>
</section>
<section>
<iframe width="640" height="480" src="https://www.youtube.com/embed/npTC6b5-yvM" frameborder="0" allowfullscreen></iframe>
</section>
<section>
<iframe width="640" height="480" src="https://www.youtube.com/embed/nxM1cnphLpw" frameborder="0" allowfullscreen></iframe>
</section>
<!--<section>
<h2><a href="http://astrange.ithinksw.net/flash/" data-preview-link>The Best Flash Animation of All Time</a></h2>
</section> -->
<section>
<h1>Things didn't end well...</h1>
</section>
<section>
<h2>April 2010, Steve Jobs writes <a href="http://www.apple.com/hotnews/thoughts-on-flash/">“Thoughts on Flash”</a></h2>
<img src="img/stevejobs.png" />
</section>
<section data-background="img/occupyflash.png">
</section>
<section>
<h1>RIP Flash. 2015</h1>
</section>
<section>
<h2>But One More For Old Times Sake</h2>
<iframe width="640" height="480" src="https://www.youtube.com/embed/EOfy5LDpEHo" frameborder="0" allowfullscreen></iframe>
</section>
</section>
<section>
<section data-markdown>
## While Flash existed, we had JavaScript & DHTML
</section>
<section data-markdown>
## DHTML is the combination of HTML, CSS and JavaScript.
* Animate text and images in their document, independently moving each element from any starting point to any ending point, following a predetermined path or one chosen by the user.
* Embed a ticker that automatically refreshes its content with the latest news, stock quotes, or other data.
* Use a form to capture user input, and then process, verify and respond to that data without having to send data back to the server.
* Include rollover buttons or drop-down menus.
</section>
<section>
<h2><a href="http://www.cwdjr.net/text/DrunkHarlequinText.html" target="_blank" data-preview-link>Drunk Harlequin Text</a></h2>
</section>
<section>
<h2>DHTML Code Sample</h2>
<pre><code class="hljs" data-trim contenteditable>
function splat(text){ // randomize text color, size, and weight
text=text.substring(0,text.length);
var fs=.5
for(i=0;text.length > i;i++){
f=Math.random();
if (Math.abs(f-fs) < .11) {f=Math.random()};
if (Math.abs(f-fs) < .11) {f=Math.random()};
if (f<.1) {c='00ffff'};
if (f>=.1 && f<.2) {c='7cfc00'};
if (f>=.2 && f<.3) {c='6495ed'};
if (f>=.3 && f<.4) {c='ffd700'};
if (f>=.4 && f<.5) {c='ff7f50'};
if (f>=.5 && f<.6) {c='ff00ff'};
if (f>=.6 && f<.7) {c='ccff00'};
if (f>=.7 && f<.8) {c='ff6964'};
if (f>=.8 && f<.9) {c='ff4500'};
if (f>=.9) {c='dc143c'};
g=Math.random();
if (g<.5) {w="font-weight:bold"};
if (g >=.5) {w="font-style:italic"};
r=Math.random();
if (r<.33) {s=10};
if (r>=.33 && r<.66){s=15};
if (r>=.55) {s=20};
document.write('<span style="color:#'+c+'; font-size:'+s+'px;'+w+'">'+text.substring(i,i+1)+'<\/span>');
fs=f
}
}
function jerk(){ // shake text
h=Math.random(); // randomize vertical displacements
if (h<.1) {j=0};
if (h>=.1 && h<.2) {j=4};
if (h>=.2 && h<.3) {j=8};
if (h>=.3 && h<.4) {j=12};
if (h>=.4 && h<.5) {j=16};
if (h>=.5 && h<.6) {j=20};
if (h>=.6 && h<.7) {j=24};
if (h>=.7 && h<.8) {j=28};
if (h>=.8 && h<.9) {j=32};
if (h>=.9) {j=36};
z=Math.random(); // randomize horizontal displacements
if (z<.1) {m=0};
if (z>=.1 && z<.2) {m=4};
if (z>=.2 && z<.3) {m=8};
if (z>=.3 && z<.4) {m=12};
if (z>=.4 && z<.5) {m=16};
if (z>=.5 && z<.6) {m=20};
if (z>=.6 && z<.7) {m=24};
if (z>=.7 && z<.8) {m=28};
if (z>=.8 && z<.9) {m=32};
if (z>=.9) {m=36};
if (document.all && !document.getElementById){
document.all['shake'].style.pixelTop =j+10;
document.all['shake'].style.pixelLeft =m+20
}
else{
document.getElementById('shake').style.top=j+10+'px';
document.getElementById('shake').style.left=m+20+'px';
}
setTimeout("jerk()",500); // the 500 ms
}
</code></pre>
</section>
</section>
<section>
<h2>JavaScript and HTML5 Canvas</h2>
<h4>Examples:</h4>
<ul>
<li><a href="http://codepen.io/dissimulate/pen/KrAwx" target="_blank">Tearable Cloth</a></li>
<li><a href="http://www.freeriderhd.com/t/1016-layers" target="_blank">Free Rider HD</a></li>
</ul>
<p>Canvas is great for big, complex animations but it absolutely kills accessibility on your website. Not to mention that the JavaScript code quickly becomes complicated.</p>
</section>
<section data-markdown>
## History of Animations on the Web
* 1987 – Initial release of Graphics Interchange Format
* 1996 – Initial release of Adobe Flash Player
* 1997 – Netscape releases the “layers” feature in Netscape 4.
* Layers was a precursor to div. Subsequently, dropped for divs.
* JavaScript animations popular, part of a set of techniques called Dynamic HTML. Standards movement contributed to death of DHTML.
* 2004 – HTML5 Canvas Introduced by Apple in WebKit.
* 2008 – Initial release of Animated Portable Network Graphics (apng)
* 2009 – Initial Draft of CSS Animations (CSS3 Module)
* 2012-2016 – Resurgence of GIF in popularity???
</section>
<section data-background="img/cssawesome.png">
</section>
<section>
<section>
<h1>Introducing CSS3 Animations</h1>
</section>
<section data-markdown>
## Introducing CSS3 Animations
* CSS3 Animations can be performed with 3 different techniques:
* Transitions
* Transforms
* Animations (Narrow Definition)
</section>
</section>
<section>
<section>
<h1>CSS3 Transitions</h1>
</section>
<section>
<h2>CSS3 Transitions</h2>
<pre><code class="hljs" data-trim>
transition: [ <transition-property> || <transition-duration>
|| <transition-timing-function> || <transition-delay> ]
</code></pre>
<p>transition-property includes color, width, height, background-color, padding, margin, top, right, bottom, left, font-size, font-weight, etc.</p>
<p>See <a href="https://www.w3.org/TR/css3-transitions/#properties-from-css-" data-preview-link>W3C Spec.</a></p>
</section>
<section>
<h2>CSS3 Transitions</h2>
<pre><code class="hljs" data-trim>
transition: [ <transition-property> || <transition-duration>
|| <transition-timing-function> || <transition-delay> ]
</code></pre>
<p>transition-duration is how long the animation takes in seconds.</p>
<p>transition-delay is how long the animation waits before changing the transition-property.</p>
</section>
<section>
<h2>CSS3 Transitions</h2>
<pre><code class="hljs" data-trim>
transition: [ <transition-property> || <transition-duration>
|| <transition-timing-function> || <transition-delay> ]
</code></pre>
<p>transition-timing-function determines how intermediate values of the transition are calculated. Only two classes of timing functions: cubic-bezier() and steps() functions.</p>
</section>
<section>
<h2>CSS3 Transitions – Timing Functions</h2>
<img src="img/example-bezier-curves.png" />
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
<section>
<h2>CSS3 Transitions – cubic-bezier()</h2>
<ul>
<li>cubic-bezier() defines a cubic Bézier curve</li>
<li>Curves are continuous, sometimes called easing functions.</li>
</ul>
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
<section>
<h2>CSS3 Transitions – cubic-bezier()</h2>
<ul>
<li>Defined by four points P0, P1, P2, and P3. P0 and P3 are the start and the end of the curve.</li>
<li>In CSS3, P0 is always set to (0, 0) and represents the initial time and the initial state, P3 is (1, 1) and represents the final time and the final state.</li>
</ul>
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
<section>
<h2>CSS3 Transitions – cubic-bezier()</h2>
<img src="img/bizier-explanation.png" />
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
<section>
<h2>CSS3 Transitions – cubic-bezier()</h2>
<ul>
<li>Invalid curves are possible and cause the entire property to be ignored.</li>
<li>P1 or P2 ordinate outside the [0, 1] range may generate bouncing effects.</li>
</ul>
<pre><code class="hljs" data-trim>
cubic-bezier(x1, y1, x2, y2);
</code></pre>
</section>
<section>
<h2>CSS3 Transitions – cubic-bezier()</h2>
<ul>
<li>Common cubic bezier are named in CSS3.</li>
<li>Cheat Sheet <a href="http://easings.net" data-preview-link>easings.net</a></li>
</ul>
</section>
<section>
<h2>CSS3 Transitions – steps()</h2>
<ul>
<li>steps(number_of_steps, direction) defines a step function with the direction indicating if it’s left/right-continuous.</li>
<li>Direction is specified with start||end.</li>
</ul>
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
<section>
<h2>CSS3 Transitions – steps()</h2>
<pre><code class="hljs" data-trim>
steps(2, start);
</code></pre>
<img src="img/steps-example.png" />
<p><small>Reference <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function">MDN</a></small></p>
</section>
</section>
<section>
<section data-markdown>
## CSS3 Transforms
#### 2D Transforms:
```css
transform: skew(x, y | <angle>) || scale(x, y | <length> or <percentage>) || rotate(angle | <angle>) || translate(x, y | <length> or <percentage>)
```
</section>
<section id="css2dtransforms-slide">
<h2>CSS3 2D Transforms Code Sample</h2>
<img id="twodtrans-1" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
<img id="twodtrans-2" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
<img id="twodtrans-3" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
<img id="twodtrans-4" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" />
</section>
<section data-markdown>
## CSS3 Transforms
#### 3D Transforms:
```css
transform: translate3d(x, y, z | <length> or <percentage>) /* Except z=<length> */ || scale3d(x, y, z | <number>) || rotateX(<angle>) || rotateY(<angle>) || rotateZ(<angle>)
```
Perspective and perspective-origin set user’s perspective and vanishing point.
There are other properties like: transform-box, transform-origin, transform-style, backface-visibility.
</section>
<section id="css3dtransforms-slide">
<h2>CSS3 3D Transforms Code Sample</h2>
<img id="threedtrans-1" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
<img id="threedtrans-2" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
<img id="threedtrans-3" class="trans-anim" width="100px" src="img/fitc_logo_redspot.png" style="margin-right:100px" />
</section>
</section>
<section>
<section data-markdown>
## CSS3 Animations - @keyframes
* @keyframes define what an animation looks like at each stage.
* @keyframes are composed of three parts:
* name - name of the animation
* stage – a percentage used to define the properties at that stage. 0% (also can use from) and 100% (also can use to) have to be defined.
* properties – CSS properties
</section>
<section>
<h2>CSS3 Animations - @keyframes</h2>
<pre><code class="hljs" data-trim>
@keyframes name {
0% {/*can use from */
top: 0;
}
50% {
top: 30px;
}
100% {/* can use to*/
top: 0;
}
}
</code></pre>
</section>
</section>
<section>
<section>
<h2>CSS3 Animations - Animation</h2>
</section>
<section data-markdown>
## CSS3 Animations - Animation
* Animation does two things:
* Assign the @keyframes to the elements.
* Define how it is animated.
```css
#div {
animation-name: keyframe-name;
animation-duration: 1s;
animation-timing-function: ease;
}
```
</section>
<section data-markdown>
## CSS3 Animations - Animation Properties
* Animation Properties:
* animation-name: name (Default: none)
* animation-duration: time of animation in seconds (Default: 0s)
* animation-timing-function: timing function, remember cubic bezier curves (Default: ease)
* animation-delay: delay to start of animation (Default: 0s)
</section>
<section data-markdown>
## CSS3 Animations - Animation Properties
* Animation Properties:
* animation-iteration-count: times to run the animation (Default: 1)
* animation-direction: direction to play the animation, normal || reverse || alternate || alternate-reverse (Default: normal)
* animation-fill-mode: how should CSS apply styles, none || forwards || backwards || both (Default: none)
* animation-play-state: animation running || paused (Default: running)
</section>
<section data-markdown>
## CSS3 Animations - Animation Properties
Animation Shorthand Syntax:
```css
animation: [animation-name]
[animation-duration]
[animation-timing-function]
[animation-delay]
[animation-iteration-count];
```
</section>
<section id="css3anim-slide">
<h2>CSS3 Animation Code Sample</h2>
<img id="css3animation" width="100px" src="img/fitc_logo_redspot.png" />
</section>
<section>
<h2>Beautiful CSS Animation Examples</h2>
<ul>
<li><a href="http://codepen.io/juliangarnier/pen/idhuG" target="_blank">CSS 3D Solar System</a></li>
<li><a href="http://anthonycalzadilla.com/css3-ATAT/index.html" target="_blank">Pure CSS3 AT-AT Walker</a></li>
<li><a href="http://roxik.com/cat/" target="_blank">Stretchy Cat</a></li>
</ul>
</section>
</section>
<section data-background="img/99littlebugs.png">
</section>
<section>
<section>
<h1>Browser Compatibility</h1>
</section>
<section>
<img src="img/csstransition.png" />
</section>
<section>
<img src="img/css2dtransform.png" />
</section>
<section>
<img src="img/css3dtransform.png" />
</section>
<section>
<img src="img/cssanimation.png" />
</section>
<section data-markdown>
## Handling Browser Prefixes Sanely – AutoPrefixer
* [PostCSS](https://github.com/postcss/postcss) plugin to parse CSS and add vendor prefixes to CSS rules using values from [Can I Use](http://caniuse.com/).
* Can add to Grunt and Gulp.
</section>
<section data-markdown>
```css
@keyframes name {
0% {
top: 0;
}
50% {
top: 30px;
}
100% {
top: 0;
}
}
```
</section>
<section data-markdown>
# becomes
</section>
<section data-markdown>
```css
@-webkit-keyframes name {
0% {
top: 0;
}
50% {
top: 30px;
}
100% {
top: 0; }
}
@keyframes name {
0% {
top: 0;
}
50% {
top: 30px;
}
100% {
top: 0;
}
}
```
</section>
<section data-markdown>
## Handling Browser Prefixes Sanely – Bourbon.io
* Simple mixins library for Sass. Using @include to output prefixes.
```css
box:hover {
@include animation(scale 1.0s ease-in, slide 2.0s ease);
}
```
</section>
</section>
<section>
<section>
<h2>CSS3 Animation Libraries</h2>
<p>animate.css is a bunch of cool, fun, and cross-browser animations for you to use in your projects. Great for emphasis, home pages, sliders, and general just-add-water-awesomeness.
<a href="https://daneden.github.io/animate.css/" target="_blank">Demo</a>
</p>
<p>Magic.css is a bunch of CSS3 Animations with special effects. <a href="http://minimamente.com/example/magic_animations/" target="_blank">Demo</a></p>
</section>
<section>
<h1><a href="http://www.wonder-tonic.com/geocitiesizer/" target="_blank">The Geocities-izer</a></h1>
</section>
</section>
<section>
<section data-markdown>
# Principles for Beautiful Animations
</section>
<section>
<h3>Disney Animation: The Illusion of Life</h3>
<img width="300" src="img/illusion_of_life.jpg" />
<p>Book by Ollie Johnston and Frank Thomas, two of the animation masters at Disney's during the Golden Age of animation, referred by Walt Disney as his "Nine Old Men".</p>
</section>
<section data-markdown>
# Principle 1: Squash and Stretch
Give a sense of weight and flexibility to drawn objects.
</section>
<section data-markdown>
# Principle 2: Anticipation
Prepare the audience for an action, and to make the action appear more realistic.
Ex. A dancer jumping off the floor has to bend his knees first.
</section>
<section data-markdown>
# Principle 3: Staging
Direct the audience's attention and make it clear what is important.
</section>
<section data-markdown>
# Principle 4: Straight Ahead Action and Pose to Pose
"Straight ahead action" means drawing out a scene frame by frame from beginning to end, while "pose to pose" involves starting with drawing a few key frames, and then filling in the intervals later. </section>
<section data-markdown>
# Principle 5: Follow Through and Overlapping Action
Give the impression that characters follow the laws of physics, including the principle of inertia.
</section>
<section data-markdown>
# Principle 6: Slow In and Slow Out
Accelerate and Decelerate.
</section>
<section data-markdown>
# Principle 7: Follow Arcs
</section>
<section data-markdown>
# Principle 8: Secondary Action
</section>
<section data-markdown>
# Principle 9: Timing (aka frames/second)
</section>
<section data-markdown>
# Principle 10: Exaggeration
</section>
<section data-markdown>
# Principle 11: Solid drawing
</section>
<section data-markdown>
# Principle 12: Appeal aka Charisma
</section>
<section data-markdown>
# [Pure CSS Fail Whale](http://www.subcide.com/experiments/fail-whale/)
</section>
</section>
<section>
<section data-markdown>
## What did we learn?
* History of Animation on the Web
* CSS3 Animations
* Transitions
* Transforms
* @keyframes & Animations
* Browser Compatibility
* Autoprefixer
* Bourbon.io
* CSS3 Animation Libraries
* Animate.css
</section>
<section data-markdown>
# Thank You! Questions?
## Also, I would love to speak more in Europe ;)
#### tw: [@ramisayar](https://twitter.com/ramisayar) | gh: [@sayar](https://github.com/sayar)
#### [slideshare.net/ramisayar](https://slideshare.net/ramisayar)
</section>
<section data-markdown>
## Resources, References, Links
* http://dailyjs.com/2010/06/27/167-history-of-javascript/
* http://www.nytimes.com/2013/02/14/fashion/common-on-early-internet-gif-files-make-comeback.html?_r=1&
* https://hg.csswg.org/drafts/log/2579c1842a7c/css3-animations/Overview.src.html
* http://www.peterbe.com/plog/worst-flash-site-of-the-year-2010
* https://www.kirupa.com/html5/creating_simple_html5_canvas_animation.htm
* http://stackoverflow.com/questions/11182478/performance-css3-animations-vs-html5-canvas
</section>
<section data-markdown>
## Resources, References, Links
* http://css3.bradshawenterprises.com/transitions/#delays
* https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Transitions/Using_CSS_transitions
* https://developer.mozilla.org/en-US/docs/Web/CSS/timing-function
* https://robots.thoughtbot.com/css-animation-for-beginners
* https://www.smashingmagazine.com/2011/09/the-guide-to-css-animation-principles-and-examples/
* https://ihatetomatoes.net/the-guide-to-css-animations-for-the-web/
* http://www.creativebloq.com/css3/animation-with-css3-712437
</section>
</section>
</div>
</div>
<script src="lib/js/head.min.js"></script>
<script src="js/reveal.js"></script>
<script>
// Full list of configuration options available at:
// https://github.com/hakimel/reveal.js#configuration
Reveal.initialize({
controls: true,
progress: true,
history: true,
center: true,
slideNumber: true,
fragments: false,
width: 1024,
height: 768,
transition: 'slide', // none/fade/slide/convex/concave/zoom
// Optional reveal.js plugins
dependencies: [
{ src: 'lib/js/classList.js', condition: function() { return !document.body.classList; } },
{ src: 'plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: 'plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: 'plugin/highlight/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } },
{ src: 'plugin/zoom-js/zoom.js', async: true },
{ src: 'plugin/notes/notes.js', async: true },
{ src: 'plugin/anything/anything.js' },
{ src: 'plugin/reveal-css-snippet/css-snippet.js', callback: function() {
document.getElementById('css2dtransforms-slide').appendChild(RevealCSSSnippet({
cssValue: "#twodtrans-1{\r\n transform: skew(10deg, 10deg);\r\n}\r\n\
#twodtrans-2{\r\n transform: scale(2, 1);\r\n}\r\n\
#twodtrans-3{\r\n transform: rotate(60deg);\r\n}\r\n\
#twodtrans-4{\r\n transform: translate(-10px, 50px);\r\n}\r\n"
}));
document.getElementById('css3dtransforms-slide').appendChild(RevealCSSSnippet({
cssValue: "#threedtrans-1{\r\n transform: rotateX(180deg);\r\n}\r\n\
#threedtrans-2{\r\n transform: rotateY(180deg);\r\n}\r\n\
#threedtrans-3{\r\n transform: rotateZ(180deg);\r\n}\r\n\
/* perspective: 800px; perspective-origin: 50% 100px; */"
}));
document.getElementById('css3anim-slide').appendChild(RevealCSSSnippet({
cssValue: "\
@keyframes fadeOut {\r\n\
0% {opacity: 1;}\r\n\
100% {opacity: 0;}\r\n\
}\r\n\
@keyframes pulse {\r\n\
0% { transform: scale(1); }\r\n\
50% { transform: scale(1.2); }\r\n\
100% { transform: scale(1); }\r\n\
}\r\n\
#css3animation{\r\n\
animation-name: pulse, fadeOut;\r\n\
animation-duration: 1s, 5s;\r\n\
animation-delay: 0s, 5s;\r\n\
animation-iteration-count: infinite, infinite;\r\n\
animation-play-state: paused;\r\n\
}\r\n"
}));
} },
],
anything: [
]
});
</script>
</body>
</html>