Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

js lint suggestions

  • Loading branch information...
commit 3e409e184548c10e024f3b88533ffb0c69681671 1 parent d9b4c4a
@heygrady authored
Showing with 7 additions and 8 deletions.
  1. +7 −8 lib/jquery.transform.js
View
15 lib/jquery.transform.js
@@ -527,7 +527,7 @@
'left': (offset.left + tx + sides.left + pos.left) + 'px',
'zoom': 1
};
- var parent = this.$elem.parent();
+
this.$elem.css(css);
}
};
@@ -1403,7 +1403,6 @@
*/
$.fx.multivalueInit = function(fx) {
var $elem = $(fx.elem),
- parts,
values = fx.transform.getAttr(fx.prop), // existing values
initValues = $elem.data('data-animate-' + fx.prop); // new values passed into animate
@@ -1435,7 +1434,8 @@
// This happens in the doctored animate function when we pass a unit or multiple values
if (initValues) {
var start,
- rscalefunc = $.transform.rfunc.scale;
+ rscalefunc = $.transform.rfunc.scale,
+ parts;
$.each(initValues, function(i, val) {
// pull out the start value
if ($.isArray(values)) {
@@ -1456,10 +1456,9 @@
start = parseFloat(start);
// handle the existence of += and -= prefixes
- if (parts = rfxnum.exec(val.end)) {
- if (parts[1]) {
- val.end = ((parts[1] === "-=" ? -1 : 1) * parseFloat(parts[2])) + start;
- }
+ parts = rfxnum.exec(val.end);
+ if (parts && parts[1]) {
+ val.end = ((parts[1] === "-=" ? -1 : 1) * parseFloat(parts[2])) + start;
}
// Save the values
@@ -1511,7 +1510,7 @@
var r = $.transform.rfunc;
if (r.angle.test(fx.prop)) {
//TODO: we should convert from other rational units
- fx.unit = 'deg'
+ fx.unit = 'deg';
} else if (r.scale.test(fx.prop)) {
fx.unit = '';
} else if (r.reflect.test(fx.prop)) {
Please sign in to comment.
Something went wrong with that request. Please try again.