Giter Club home page Giter Club logo

Comments (5)

zaceno avatar zaceno commented on June 9, 2024

Thanks @atomiks! It's a good idea, but I don't think just clearing the timeout will be enough to get the behavior you want (Try here: https://codepen.io/zaceno/pen/ELybGW).

The idea is, if you click the same square multiple times, you want it to slowly move towards its intended position from where it is now, without janking, right?

I need to think a bit more about this - but to be honest, I don't think it's a high priority issue ... more "nice to have".

from hyperapp-transitions.

atomiks avatar atomiks commented on June 9, 2024

You're right - clearing the timeout fixes the jank due to the old timeout firing before the new transition finishes (so it will instantly move to the new position), but the elements should transition from their current mid-transition position... does getBoundingClientRect() work there?

It also introduces a problem of no transitions occuring sometimes if timed in a certain way.

A semi-solution would be to prevent a new position update if it's still transitioning

from hyperapp-transitions.

atomiks avatar atomiks commented on June 9, 2024

So I started using this module in a proper project and this is proving to be kind of a dealbreaker.

  • Rapidly clicking a button that expands an item inside the transitioned list item causes glitchy transitions of the list items (normal user behavior I'd say)
  • Adding a delay to stagger list items that transition in continually increments the delay each time the list items are filtered since the timeout is not cleared, causing them to not appear after a while

from hyperapp-transitions.

zaceno avatar zaceno commented on June 9, 2024

@atomiks While I'm still not sure if I'll be able to fix this, do you think you could provide an example like in a codepen or repo?

Especially an example of "Rapidly clicking a button that expands an item inside the transitioned list item" since I'm having trouble visualizing what's going on.

No promises, but it would be helpful to me (or hopefully someone smarter) in finding a solution.

from hyperapp-transitions.

zaceno avatar zaceno commented on June 9, 2024

@atomiks

I'm going to close for now -- I'm still open to looking into this but I need an example to work with. Reopen if you've got one!

from hyperapp-transitions.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.