* @private
*/
_events() {
- var _this = this,
- $body = $('html, body'),
- opts = {
- duration: _this.options.animationDuration,
- easing: _this.options.animationEasing
- };
+ var _this = this;
$(window).one('load', function(){
if(_this.options.deepLinking){
this.$input = this.inputs.length ? this.inputs.eq(0) : $(`#${this.$handle.attr('aria-controls')}`);
this.$fill = this.$element.find('[data-slider-fill]').css(this.options.vertical ? 'height' : 'width', 0);
- var isDbl = false,
- _this = this;
+ var _this = this;
if (this.options.disabled || this.$element.hasClass(this.options.disabledClass)) {
this.options.disabled = true;
this.$element.addClass(this.options.disabledClass);
if (!this.inputs[1]) {
this.inputs = this.inputs.add(this.$input2);
}
- isDbl = true;
// this.$handle.triggerHandler('click.zf.slider');
this._setInitAttr(1);
param = vertical ? 'height' : 'width',
direction = vertical ? 'top' : 'left',
eventOffset = vertical ? e.pageY : e.pageX,
- halfOfHandle = this.$handle[0].getBoundingClientRect()[param] / 2,
barDim = this.$element[0].getBoundingClientRect()[param],
windowScroll = vertical ? $(window).scrollTop() : $(window).scrollLeft();
-
var elemOffset = this.$element.offset()[direction];
// touch events emulated by the touch util give position relative to screen, add window.scroll to event coordinates...
*/
_eventsForHandle($handle) {
var _this = this,
- curHandle,
- timer;
+ curHandle;
const handleChangeEvent = function(e) {
const idx = _this.inputs.index($(this));
css = {},
anchorPt = (this.points ? this.points[1] - this.points[0] : this.anchorHeight) - this.elemHeight,
mrgn = stickToTop ? 'marginTop' : 'marginBottom',
- notStuckTo = stickToTop ? 'bottom' : 'top',
topOrBottom = isTop ? 'top' : 'bottom';
css[mrgn] = 0;