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

Feature: Add active class at beginning of transition #36

Closed
shaunmorrison opened this issue Nov 23, 2012 · 6 comments
Closed

Feature: Add active class at beginning of transition #36

shaunmorrison opened this issue Nov 23, 2012 · 6 comments

Comments

@shaunmorrison
Copy link

Move the assignation of the active class to when the transition starts. At the moment the active class becomes assigned after the the transition has completed – which can look not so smooth.

I have a carousel nav that controls a slideshow and when an item in the carousel is clicked I think the user will expect the state to change then not when the transition has completed.

I looked at the code, but I couldn't seem to switch the order of opts.API.updateView(); without breaking the active class totally.

I hope that makes sense?

Many thanks,
Shaun

@malsup
Copy link
Owner

malsup commented Nov 25, 2012

You can now control when updateView is invoked.

http://jquery.malsup.com/cycle2/api/#update-view

@malsup malsup closed this as completed Nov 25, 2012
@malsup
Copy link
Owner

malsup commented Nov 25, 2012

Reverted this feature since it broke a few things. Need to give this some more thought.

@malsup malsup reopened this Nov 25, 2012
malsup added a commit that referenced this issue Nov 25, 2012
@malsup
Copy link
Owner

malsup commented Nov 25, 2012

Ok, have it working now.

@malsup malsup closed this as completed Nov 25, 2012
@shaunmorrison
Copy link
Author

Works perfectly. Thank you for including it!

@randalldon
Copy link

Hi There,

I'm just picking up on this thread as it's exactly the functionality i'm looking for. Is there an example or you you direct to to how i can achieve this with the API?

Many thanks

@randalldon
Copy link

Apologies, i've just seen in the documentation how to achieve this.

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

3 participants