Closed primez closed 9 years ago
hi,
no matter at all, all questions are welcome ;)
by default, input 'ng-model' attribute scope model is propagated, if not => bug
<input ng-model="myvalue" type="text" id="myslider" slider options="options" />
and into your js angular code:
$scope.myvalue = "10;15";
$scope.options = {
from: 0,
to: 40,
step: 0.5,
dimension: " $",
round: 1,
scale: [0, '|', 10, '|', 20, '|' , 30, '|', 40],
heterogeneity: ['50/100', '75/250']
}
complete examples here
https://github.com/darul75/ng-slider/blob/master/src/ng-slider.html
keep me up to date
Thank you for your answer. I've checked ng-slider.html code example and made a few screenshots to show you. I think there is a bug, because on this screenshot model and slider are in sync: http://take.ms/XNetB, but then after clicking on a slider -> http://take.ms/XKSmt - model remains the same, but slider value has changed.
can you send me you console output, maybe js error somewhere ? or your html and js code, thx for screenshot, I will help you
This is from an example: http://take.ms/esasm. My code looks the same, I've just copied everything from an example, but without angular-mocks and it works the same.
And one more thing I can't understand -> one your demo page: http://darul75.github.io/ng-slider/ sliders are without click at all.
maybe check several angular versions included, it looks weird, you can remove angular-mock dependency from src html file example, not needed at all
Yes, I've removed mocks. That error has gone, but click still works the same. Ok, I will try previous angular versions
sorry bug :) I was not clicking, just moving...
resolved asap, regression...
Ok. Thank you very much.
resolved in 2.0.8, thanks
Works great, Thank you.
glad to hear
Hi, Julien! Sorry if my question is silly. How can I attach on click callback or prohibit a click on a slider, because click on a slider change it, but model does not seem to change at all.