-
Notifications
You must be signed in to change notification settings - Fork 602
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 hide prev/next arrows if not needed #566
Comments
Sorry there is no setting or easy way. But there may be hacks. See discussion in #289 |
simply just add display:none to .flickity-button in your stylesheet. it worked for me. .flickity-button { or you can use prevNextButtons: false, |
I'm looking for an automatic thing. Something that understand viewport size, number of items in the carousel, etc. It is not known whether there will be enough items in every single instantiation to warrant scrolling buttons, and in such cases, I don't want to show an arrow. |
@robarwebservices If you don't mind with just CSS hiding I made last time solution for that:
With this you can hide your controllers by class 'slider-is-single'. |
freeScroll: true, |
This was working for me:
|
Try this:
|
I got around it with this ` var elem = document.querySelector('#{{ section.id }} .main-carousel'); function handleResize() { |
Is there any setting or easy way to hide the prev/next only if there aren't enough items to need them?
e.g. dynamic width container (width=100%), where each item is a thumb. if the parent container > width of the thumbs in total, there is no scrolling needed. Is it possible to handle this case?
The text was updated successfully, but these errors were encountered: