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: enable stacking events #255

Merged
merged 12 commits into from
Sep 17, 2022

Conversation

pdpino
Copy link
Collaborator

@pdpino pdpino commented Aug 18, 2022

Fixes #233

(See demos in docs/overlaps.md)

@pdpino pdpino added the type: feature enhancements or new features label Aug 18, 2022
@pdpino
Copy link
Collaborator Author

pdpino commented Sep 16, 2022

@hoangnm have you been able to check this PR?


Sorry for the large PR, I'll add a small code walkthrough in case is useful 🙂:

  • Moving stuff to box.js and types.js is refactoring (i.e. minor code changes or not at all)
  • Moving stuff to position.js is mainly refactoring, plus support a stackOffset in left and width
  • resolveEventOverlaps() function in overlap.js handles lane/stack/ignored cases:
    • the overall algorithm remains very similar (functions resolveEventOverlaps, addOverlappedToArray)
    • buildFromOverlappedEvents() handles different overlapped cases
    • The Classes are helpers to remember state throughout the process

Copy link
Owner

@hoangnm hoangnm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is really awesome, great solution and clean code, @pdpino .

@hoangnm hoangnm merged commit b9dbec5 into hoangnm:master Sep 17, 2022
@rdewolff
Copy link

Wouhou, amazing! Thanks for your hard work!

@pdpino pdpino deleted the feature/233-stack-vs-lane branch September 17, 2022 13:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: feature enhancements or new features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stack event when they can
3 participants