3/24/2010

Spritely in PURE CSS3

(Disclaimer: I've tried in an entirely week-end to animate birds using only CSS3 but without great success... sorry about that).

1) animate the clouds (#clouds):
@-webkit-keyframes animClouds{
0% {background-position: 0px 102px; }
100% {background-position: -1068px 102px; }
}

#clouds {
-webkit-animation-name: animClouds;
-webkit-animation-duration: 70s;
-webkit-animation-timing-function: linear;
-webkit-animation-iteration-count: infinite;

/* is the same as */
-webkit-animation:animClouds 70s linear 0s infinite;
}

2) animate the hills (#hill2 & #hill1):
@-webkit-keyframes animHill2{
from {background-position: 0px 258px; }
to {background-position: -1110px 258px; }
}

@-webkit-keyframes animHill1{
0% {background-position: 0px 104px; }
100% {background-position: -2220px 104px; }
}

#hill2{
-webkit-animation: animHill2 25s linear 0s infinite;
}

#hill1 {
-webkit-animation: animHill1 25s linear 0s infinite;
}


And that's all ! Check the demos here (Safari/Chrome only): Demo 1 Demo 2

1/13/2010

jQuery 1.4: What's new & useful

You may not have noticed but I've tweeted about jQuery 1.4 new features. Here is my selection of the best jQuery 1.4 brand-new methods:

#jQuery 1.4 .delay( duration, [ queueName ] ) method seems very useful ! http://api.jquery.com/delay/

#jQuery 1.4 .toArray(); //helper
toArray: function() { return slice.call( this, 0 ); }
#jQuery 1.4 .prevUntil() .nextUntil() .parentsUntil() ROCKS! http://bit.ly/5DDcsv //A new way for traversing the DOM :)

#jQuery 1.4 jQuery.noop() ? I Don't get the point... http://api.jquery.com/jQuery.noop/
noop: function(){}
#jQuery 1.4 .isEmptyObject(obj) //helper
isEmptyObject: function( obj ) { for ( var name in obj ) { return false; } return true; }

Don't forget to follow me on twitter @FGRibreau :)

1/09/2010

Diaporama de ma conférence "Découverte HTML5/CSS3"

Voici le diaporama de ma conférence "Découverte HTML5/CSS3" avec une introduction aux bonnes pratiques dans le développement web:


N'hésitez pas à commenter, mettre en favoris le diaporama sur la page slideshare.
« »
 
 
Made with ❤ on a hot august night from an airplane the 19th of March 2017.