On Github poshaughnessy / edtechdevs-awesome-mobile-animations
Source code: bit.ly/awesome-mobile-animations
Please view in a modern browser.
↓
Dots app via capptivate.co
Yelp app via capptivate.co
Paper app via capptivate.co
Moldiv app via captivate.co
↓
<canvas id="myCanvas"> my fallback content </canvas>
var canvas = document.getElementById('myCanvas'); var ctx = canvas.getContext('2d'); ctx.fillStyle = 'rgb(255, 0, 0)'; ctx.fillRect( 20, 20, 100, 200 );
Knoggins (an app we created in 1 day at a hackathon)
www.goodboydigital.com/runpixierun/ (Pixi.js)
↓
<canvas id="myCanvas"> my fallback content </canvas>
var canvas = document.getElementById('myCanvas'); var gl = canvas.getContext('webgl') || canvas.getContext('experimental-webgl'); /* Lots of low level code here! Or use a library */
See bit.ly/third-dimension (desktop)
bit.ly/bunnymark (Pixi.js) 1000 bunnies @ ~14 FPS
bit.ly/bunnymark (Pixi.js) 1000 bunnies @ ~58 FPS
↓
.demo { transition-property: transform; transition-duration: 2s; } .demo:hover { transform: rotateX(45deg) scale(1.2); }
Hover over the code area. NB. Vendor prefixes omitted for simplicity
React touch demo (menu @ 0:43, gallery @ 2:10) Live demo at: petehunt.github.io/react-touch
bit.ly/css3d-per (Three.js CSS3DRenderer)
↓
@keyframes spin3d { 0% { transform: rotateY(0deg); } 100% { transform: rotateY(360deg); } } .you-spin-me-right-round-baby-right-round:hover { animation: spin3d 3s ease-in-out infinite; }
Hover over the code area. NB. Vendor prefixes omitted for simplicity
snowFlake.style.transform = 'translate(' + snowLeft + 'px, -100%)'; // wait a frame snowFlake.offsetWidth; snowFlake.style.transitionProperty = 'transform'; snowFlake.style.transitionDuration = '1500ms'; snowFlake.style.transform = 'translate(' + snowLeft + 'px, ' + window.innerHeight + 'px)';
snowFlake.animate([ {transform: 'translate(' + snowLeft + 'px, -100%)'}, {transform: 'translate(' + snowLeft + 'px, ' + window.innerHeight + 'px)'} ], 1500);
var player = snowFlake.animate( ... ); // Changed my mind player.cancel(); var player = snowFlake.animate( ... ); player.onfinish = function(e) { console.log('Snowflake landed!'); }
↓
By Joe Fleming