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

Update core animate() to allow additional functionality #35

Closed
peterh-capella opened this issue Jan 18, 2013 · 6 comments
Closed

Update core animate() to allow additional functionality #35

peterh-capella opened this issue Jan 18, 2013 · 6 comments
Assignees

Comments

@peterh-capella
Copy link

At its heart, jquery.scrollTo uses this format of the .animate() method:

.animate(properties [, duration ] [, easing ] [, complete ])

Would it be possible to use the alternate version of the .animate() method:

.animate(properties, options)

to allow optional passing in of additional properties that could be animated while the scroll is happening? For example, animating (with the proper plug-ins) the background color of an element while it scrolls.

It appears on cursory examination that this would involve moving the current duration, settings.easing, and callback arguments to a new options object as well as getting the current attr argument into a new properties object along with any other properties that are passed into the plug-in.

@flesler
Copy link
Owner

flesler commented Jan 19, 2013

Yes, there's an open issue that adds the step option so I thought of rewriting it as you say, I'll tackle both asap (bear with me).

@peterh-capella
Copy link
Author

Good to hear! I'm working on something that would benefit from the enhancement but understand these things take time. :) If I come up with anything in the meantime, I'll let you know.

@flesler
Copy link
Owner

flesler commented Jan 23, 2013

Thanks, if you get to submit a pull request I'll check it out asap.

On Wed, Jan 23, 2013 at 3:43 PM, Peter Hentges notifications@github.comwrote:

Good to hear! I'm working on something that would benefit from the
enhancement but understand these things take time. :) If I come up with
anything in the meantime, I'll let you know.


Reply to this email directly or view it on GitHubhttps://github.com//issues/35#issuecomment-12612061.

Ariel Flesler

@flesler
Copy link
Owner

flesler commented Apr 7, 2013

As I commented on another similar issue, found there's a conflict with the "queue" setting which is also recognized by jQuery.animate(). Will look into this.

@ghost ghost assigned flesler Jan 13, 2014
@flesler
Copy link
Owner

flesler commented Mar 4, 2015

This feature is implemented on the window-scroll-alt branch. I created the issue #107 for the whole thing that has a larger scope.
If that branch makes it to master this issue will be fixed too.

@flesler flesler closed this as completed Mar 4, 2015
@flesler flesler reopened this Mar 4, 2015
@flesler
Copy link
Owner

flesler commented Mar 18, 2015

I merged 2.0.0 to master via #109, the call to $().animate() receives the whole setting object so any setting supported by your version of $().animate() can also be used with scrollTo.
If you have any issue after the update, first check this link, If your problem is not solved then go ahead and report the issue.

@flesler flesler closed this as completed Mar 18, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants