TanStack / ranger

🤖 Headless utilities for building range and multi-range sliders in React, Preact, Solid, Vue, Svelte and Angular
MIT License
757 stars 65 forks source link

Support non-linear ranges #3

Closed etimberg closed 6 years ago

etimberg commented 6 years ago

Got this idea when playing with the custom-steps sample. Would be cool to support a logarithmic interpolation on the slider.

Implementation Ideas

  1. Built in support for 'linear' and 'logarithmic' interpolation
  2. Custom interpolation support via props
tannerlinsley commented 6 years ago

The scale used internally could easily be exposed. All it does is translate a value into a width percentage. :)

etimberg commented 6 years ago

Already working on it ;)

tannerlinsley commented 6 years ago

Nice!

etimberg commented 6 years ago

Done in #5