Jump to content
Search Community

Draggable : overshootTolerance with inertia

DRJO test
Moderator Tag

Recommended Posts

Been trying a few things out with draggable, trying to simulate an <input: type=range /> component with inertia.

 

However the problem I find when using inertia with draggable it does not respect the bounds and flies offscreen when thrown, I would assume it would ease to the bounds. 

 

Apologies if I sound lazy asking maybe a simple question but I am thought I'd use gsap for my project to save time. 

 

this.dragger = Draggable.create(this.$refs['handle'], {
type: 'x',
edgeResistance: 1,
inertia: true,
throwResistance: 5000,
lockAxis: true,
bounds: '#progressbar',
onDrag: this.onDrag,
onThrowUpdate: this.onDrag,
onThrowComplete: this.onThrowComplete,
onDragEnd: this.onDragEnd,
allowNativeTouchScrolling: false,
zIndexBoost: false,
overshootTolerance: 0.5
})
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...