]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
fixes issue with Slider plugin improperly filling in with two handles. Fixes #7351...
authorChris Oyler <chris@zurb.com>
Mon, 14 Dec 2015 21:25:15 +0000 (13:25 -0800)
committerChris Oyler <chris@zurb.com>
Mon, 14 Dec 2015 21:25:15 +0000 (13:25 -0800)
js/foundation.slider.js

index 2e3de6d9da17d3fbb1cc25b96f7b9afa473f2f4f..5211bbdebdf4adc03fbd2febcad60f8ecd87309a 100644 (file)
         css['min-' + hOrW] = dim;
         if(cb && typeof cb === 'function'){ cb(); }
       }else{
-        location = (location < 100 ? location : 100) - (parseFloat(this.$handle[0].style.left) || this.options.end - location);
+        var handleLeft = parseFloat(this.$handle[0].style.left);
+        location = (location < 100 ? location : 100) - (!isNaN(handleLeft) ? handleLeft : this.options.end - location);
         css['min-' + hOrW] = location + '%';
       }
     }