Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
.idea
.idea
/node_modules
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ion-rangeslider",
"version": "2.3.0",
"version": "2.3.1",
"homepage": "https://github.com/IonDen/ion.rangeSlider",
"authors": [
{
Expand Down
30 changes: 27 additions & 3 deletions js/ion.rangeSlider.js
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,7 @@
grid_margin: true,
grid_num: 4,
grid_snap: false,
grid_scale: [],

hide_min_max: false,
hide_from_to: false,
Expand Down Expand Up @@ -379,6 +380,7 @@
grid_margin: $inp.data("gridMargin"),
grid_num: $inp.data("gridNum"),
grid_snap: $inp.data("gridSnap"),
grid_scale: $inp.data("gridScale"),

hide_min_max: $inp.data("hideMinMax"),
hide_from_to: $inp.data("hideFromTo"),
Expand Down Expand Up @@ -806,7 +808,7 @@
if ($.contains(this.$cache.cont[0], e.target) || this.dragging) {
this.callOnFinish();
}

this.dragging = false;
},

Expand Down Expand Up @@ -2297,8 +2299,30 @@
}
}

this.calcGridCollision(2, start, finish);
this.calcGridCollision(4, start, finish);
if (this.options.grid_scale.length > 0) {
for (i = 0; i < num; i++) {
label = this.$cache.grid_labels[i][0];
var scale = $(label).html();

var inArray = false;

$.each(this.options.grid_scale, function () {
if (this == scale) {
inArray = true;
return false;
}
});

if (inArray) {
label.style.visibility = "visible";
} else {
label.style.visibility = "hidden";
}
}
} else {
this.calcGridCollision(2, start, finish);
this.calcGridCollision(4, start, finish);
}

for (i = 0; i < num; i++) {
label = this.$cache.grid_labels[i][0];
Expand Down
2 changes: 1 addition & 1 deletion js/ion.rangeSlider.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ion-rangeslider",
"version": "2.3.0",
"version": "2.3.1",
"description": "Cool, comfortable and easily customizable range slider with many options and skin support",
"homepage": "http://ionden.com/a/plugins/ion.rangeSlider/en.html",
"author": {
Expand Down