aboutsummaryrefslogtreecommitdiffstats
path: root/src/effects/Tween.js
diff options
context:
space:
mode:
authorOleg Gaidarenko <markelog@gmail.com>2015-08-16 09:59:58 +0300
committerOleg Gaidarenko <markelog@gmail.com>2015-09-07 20:03:50 +0300
commit10fdad742a2a6aa9f0e00b3e04fc5264797c53c7 (patch)
tree6b6d7b1375ff88f4bebbfa0703f7b595eb485df9 /src/effects/Tween.js
parent7aa46e0df8a673e6b00550bbbbed21eed50108b7 (diff)
downloadjquery-10fdad742a2a6aa9f0e00b3e04fc5264797c53c7.tar.gz
jquery-10fdad742a2a6aa9f0e00b3e04fc5264797c53c7.zip
Build: Update jscs and lint files
Fixes gh-2056
Diffstat (limited to 'src/effects/Tween.js')
-rw-r--r--src/effects/Tween.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/effects/Tween.js b/src/effects/Tween.js
index d7cd8e606..d26ddd918 100644
--- a/src/effects/Tween.js
+++ b/src/effects/Tween.js
@@ -1,4 +1,4 @@
-define([
+define( [
"../core",
"../css"
], function( jQuery ) {
@@ -71,10 +71,12 @@ Tween.propHooks = {
// Simple values such as "10px" are parsed to Float;
// complex values such as "rotate(1rad)" are returned as-is.
result = jQuery.css( tween.elem, tween.prop, "" );
+
// Empty strings, null, undefined and "auto" are converted to 0.
return !result || result === "auto" ? 0 : result;
},
set: function( tween ) {
+
// Use step hook for back compat.
// Use cssHook if its there.
// Use .style if available and use plain properties where available.
@@ -116,4 +118,4 @@ jQuery.fx = Tween.prototype.init;
// Back Compat <1.8 extension point
jQuery.fx.step = {};
-});
+} );