Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to redraw slider on resize windows? #5

Open
exdeniz opened this issue May 21, 2014 · 1 comment
Open

How to redraw slider on resize windows? #5

exdeniz opened this issue May 21, 2014 · 1 comment

Comments

@exdeniz
Copy link

exdeniz commented May 21, 2014

Resize 100% div and this - http://i.imgur.com/3SBKe6y.png

@Insider77
Copy link

I solved it this way:

add this to powerange.js

Powerange.prototype.responsive = function() {
if (this.options.step) this.step(this.slider.offsetWidth, this.handle.offsetWidth);
this.setStart(this.element.value);
};

and this to your script

$(window).resize(function() {
your_slider_reference.responsive();
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants