ember-cli-nouislider icon indicating copy to clipboard operation
ember-cli-nouislider copied to clipboard

Cannot update `max` value after initial render

Open cmackenz opened this issue 4 years ago • 1 comments

Version: 1.1.0

When updating the max value I would expect the slider to respond to this new value, but unfortunately it does not.

The only way I have found to update this value in realtime is to force rerender the component.

{{#if sliderReady}}
  {{range-slider 
    start=start
    min=1
    max=calculatedTotal  <-- When updating `calculateTotal` the slider does update to reflect the new value
    connect=connect
    tooltips=true
    step=1
    on-change="sliderChanged"
  }}
{{/if}}

Basically, I observe the calculatedTotal change and then toggle the sliderReady value from true to false, and then back to true. This will rerender the range-slider with the udpated max value.

cmackenz avatar Apr 23 '20 21:04 cmackenz

The same issue affects "direction" option!

rreckonerr avatar Jun 03 '20 10:06 rreckonerr