Update to latest version of jRange (fixes issue #867)
This commit is contained in:
parent
6ea5b57715
commit
84833ca15e
2
library/jRange/jquery.range-min.js
vendored
2
library/jRange/jquery.range-min.js
vendored
File diff suppressed because one or more lines are too long
@ -19,6 +19,9 @@
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
}
|
}
|
||||||
|
.slider-container .back-bar .pointer.last-active {
|
||||||
|
z-index: 3;
|
||||||
|
}
|
||||||
.slider-container .back-bar .pointer-label {
|
.slider-container .back-bar .pointer-label {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: -17px;
|
top: -17px;
|
||||||
|
@ -33,7 +33,9 @@
|
|||||||
step : 1,
|
step : 1,
|
||||||
format: '%s',
|
format: '%s',
|
||||||
theme : 'theme-green',
|
theme : 'theme-green',
|
||||||
width : 300
|
width : 300,
|
||||||
|
minRange: 0,
|
||||||
|
maxRange: 'auto'
|
||||||
},
|
},
|
||||||
template : '<div class="slider-container">\
|
template : '<div class="slider-container">\
|
||||||
<div class="back-bar">\
|
<div class="back-bar">\
|
||||||
@ -103,7 +105,8 @@
|
|||||||
if(e.which !== 1){return;}
|
if(e.which !== 1){return;}
|
||||||
e.stopPropagation(); e.preventDefault();
|
e.stopPropagation(); e.preventDefault();
|
||||||
var pointer = $(e.target);
|
var pointer = $(e.target);
|
||||||
pointer.addClass('focused');
|
this.pointers.removeClass('last-active');
|
||||||
|
pointer.addClass('focused last-active');
|
||||||
this[(pointer.hasClass('low')?'low':'high') + 'Label'].addClass('focused');
|
this[(pointer.hasClass('low')?'low':'high') + 'Label'].addClass('focused');
|
||||||
$(document).on('mousemove.slider', $.proxy(this.onDrag, this, pointer));
|
$(document).on('mousemove.slider', $.proxy(this.onDrag, this, pointer));
|
||||||
$(document).on('mouseup.slider', $.proxy(this.onDragEnd, this));
|
$(document).on('mouseup.slider', $.proxy(this.onDragEnd, this));
|
||||||
@ -280,6 +283,7 @@
|
|||||||
options = typeof option === 'object' && option;
|
options = typeof option === 'object' && option;
|
||||||
if (!data) {
|
if (!data) {
|
||||||
$this.data('plugin_' + pluginName, (data = new jRange(this, options)));
|
$this.data('plugin_' + pluginName, (data = new jRange(this, options)));
|
||||||
|
$(window).resize(function() { data.setValue(data.getValue()); }); // Update slider position when window is resized to keep it in sync with scale
|
||||||
}
|
}
|
||||||
// if first argument is a string, call silimarly named function
|
// if first argument is a string, call silimarly named function
|
||||||
// this gives flexibility to call functions of the plugin e.g.
|
// this gives flexibility to call functions of the plugin e.g.
|
||||||
|
@ -73,6 +73,9 @@
|
|||||||
cursor: move;
|
cursor: move;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
|
&.last-active{
|
||||||
|
z-index: 3;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.pointer-label {
|
.pointer-label {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
Reference in New Issue
Block a user