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

Horizontal scroll breaks after manipulating groups/items #882

Open
Front-start opened this issue Nov 2, 2022 · 2 comments
Open

Horizontal scroll breaks after manipulating groups/items #882

Front-start opened this issue Nov 2, 2022 · 2 comments

Comments

@Front-start
Copy link

Describe the bug
I have implemented a group filter. After I filter all groups and then reset the filter, horizontal scroll to the right starts working as scroll to the left.

To Reproduce

Steps to reproduce the behavior:

  1. Go to codebox
  2. Wait for 6 seconds
  3. Scroll right

Expected behavior
Date goes up

Library Version
0.28.0

@franciscohanna92
Copy link

franciscohanna92 commented Nov 10, 2022

I found a hack to solve it: Force a re-render of the whole thing after altering groups/items.

This could be achieved by passing a prop key={this.state.timelineKey} to <Timeline /> and set that state property to something new each time you change the items or groups (i.e. this.setState({...this.state, timelineKey: Date.now()}))

@fpaupier
Copy link

Thanks so much @franciscohanna92. Your workaround solved a similar issue I was facing.

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