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

slideUp/Down Sequences v2.0 #121

Closed
wants to merge 3 commits into from

Conversation

legomushroom
Copy link

The pull request consist of 3 commits.

  1. 703c07e Improves slideUp and slideDown animations, by skipping redundant tweens.
  2. 88fd8f7 Fixes broken animation with border-box box model.
  3. 6ee44e3 just an amend to 1. 703c07e

they 3 close #96 but I'd like to make more improvements in the future. For instance systemize all 'show' and 'hide' animations(fadeIn, fadeDown, slideIn, slideDown etc) like jquery does it, so codebase will be dry.

More about 1 - 703c07e
Basically sequences are created first and then we have an ability to check if particular sequence is needed (in the begin callback), so I'm setting isSkipped flag on the element and then at the tick() I'm completeCall() -ing it relying on this flag. It adds below 0.008ms more CPU time for flag checks for every element in the Velocity.State.calls loop and as for me could not be considered as perf overhead. My concern is the place where isSkipped flag is set(right on the element itself), but without access to the tween I don't see better one now :)

@julianshapiro julianshapiro changed the title Close https://github.com/julianshapiro/velocity/issues/96 PR: slideUp/Down Sequences v2.0 Jun 24, 2014
@julianshapiro julianshapiro changed the title PR: slideUp/Down Sequences v2.0 slideUp/Down Sequences v2.0 Jun 26, 2014
@julianshapiro julianshapiro added this to the 1.0.0 milestone Jun 27, 2014
Rycochet pushed a commit that referenced this pull request Aug 3, 2020
Fixes slideUp/Down behavior with box-sizing:border-box. Closes #121.
Thank you, @legomushroom.

Fixed issue where couldn’t get height/width values on an element set to
display:none.
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

Successfully merging this pull request may close these issues.

Help Wanted: Do a better job than me on the slideDown/slideUp sequences
2 participants