📅  最后修改于: 2022-03-11 15:02:03.355000             🧑  作者: Mango
var $range = $(".js-range-slider"),
$inputFrom = $(".js-input-from"),
$inputTo = $(".js-input-to"),
instance,
min = 0,
max = 1000;
$range.ionRangeSlider({
type: "double",
min: min,
max: max,
from: 100,
to: 900,
onStart: updateInputs,
onChange: updateInputs,
onFinish: updateInputs
});
function updateInputs (data) {
$inputFrom.prop("value", data.from);
$inputTo.prop("value", data.to);
}
instance = $range.data("ionRangeSlider");