flickity icon indicating copy to clipboard operation
flickity copied to clipboard

Less bouncy sliding animation

Open dom-turnbull opened this issue 11 years ago • 5 comments

Is there any way to decrease the force of the physics on slide?

Every time I slide, using drag or arrows (even if it is one slide), it bounces quite heavily.

See comparison gifs below:

physics-demo My flickity instance, loaded with this code:

$('.md-iphone-5 .md-screen').flickity();

physics-demo-flickity-example single.html flickity instance in the sandbox folder.

How can this be resolved so I can just have the smooth transition, rather than a bounce?

dom-turnbull avatar Feb 11 '15 15:02 dom-turnbull

To adjust the bounce just use the friction setting. I found out while testing 0.4 is a good value for a smooth sliding effect :smile:

iamstiil avatar Feb 11 '15 16:02 iamstiil

@pavethiran Cheers, mate! I never even noticed that setting. :smile:

dom-turnbull avatar Feb 11 '15 16:02 dom-turnbull

I haven't documented friction because I'm likely to change it to improve the bounciness you've pointed out. Right now the physics works differently based on the size of the cells. It should be more consistent.

desandro avatar Feb 11 '15 17:02 desandro

@desandro, I thought I hadn’t seen it anywhere. Cheers for the response.

dom-turnbull avatar Feb 11 '15 17:02 dom-turnbull

Experienced this one today as well when trying to get flickity to flick between slides faster. Got super long bounce times. There seems to be a limit in when the slides start to bounce when clicking on arrows. The setting combination in the documentation works quite well however. So +1 for improving bounciness features and docs! :-)

spacecat avatar Aug 20 '16 17:08 spacecat