0

Following http://danielcrisp.github.io/angular-rangeslider/demo I created a slider to change a price value.

 <div range-slider min="5000000" max="1000000000" model-min="demo1.min" model-max="demo1.max"></div> {{demo1.max}}

In the place of {{demo1.max}} instead of 5000000 I want to show 5 Million. As the value reaches Billion, want to show like 1 Billion. I know I have to write custom code for this, but how can I catch the change event of Angular rangeSlider? Can I change filter, filter-options from code? Thanks.

Shoreki
  • 1,057
  • 4
  • 14
  • 33

2 Answers2

1

How can I catch the change event of Angular rangeSlider?

To do this, you can use on-handle-down property. It will trigger given function when you release the range handles. You can check your model values in this function and act as you wish.

<div range-slider on-handle-up='handleUp();' ... ></div>
Nirav Gandhi
  • 1,945
  • 1
  • 23
  • 32
1

In Angular rangeSlider, you can get two events

<div range-slider on-handle-up='handleUp();' on-handle-down="handleDown();"></div>
  1. When to handle is grabbed on-handle-down
  2. when handle is released on-handle-up
byteC0de
  • 5,153
  • 5
  • 33
  • 66