Skip to content

Instantly share code, notes, and snippets.

@acidjazz
Created May 15, 2014 02:16
Show Gist options
  • Save acidjazz/17f4f4f56c6aad83c35b to your computer and use it in GitHub Desktop.
Save acidjazz/17f4f4f56c6aad83c35b to your computer and use it in GitHub Desktop.
return transition = function(el, time) {
var css, key, s, value, _results;
console.log(el.length);
s = time / 1000;
css = {
'-webkit-transition-duration': "" + s + "s",
'-moz-transition-duration': "" + s,
'-o-transition-duration': "" + s,
'-ms-transition-duration': "" + s,
'transition-duration': "" + s,
'background-color': 'blue'
};
_results = [];
for (key in css) {
value = css[key];
_results.push(el.css(key, value));
}
return _results;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment