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

VictoryGraph with VictoryZoomContainer reverts to old values if updated after zoom #597

Closed
johnhydroware opened this issue May 19, 2017 · 6 comments
Assignees

Comments

@johnhydroware
Copy link

https://jsfiddle.net/qk8w84of/2/

When started 1) zoom in the graph 2) Click "All" button. New dataset is shown. 3) Click in the graph. The old dataset is now shown.

@johnhydroware johnhydroware changed the title VictoryGraph with VictoryZoomContainer if updated after zoom VictoryGraph with VictoryZoomContainer reverts to old values if updated after zoom May 23, 2017
@boygirl
Copy link
Contributor

boygirl commented May 23, 2017

@johnhydroware thank you for the reproduction.

@chrisbolin
Copy link
Contributor

we can see a very similar behavior on http://formidable.com/open-source/victory/guides/brush-and-zoom/. the zoomed seems to "forget" about actions from brush.

@chrisbolin chrisbolin self-assigned this May 26, 2017
@chrisbolin
Copy link
Contributor

just a quick update -- making progress on this. It looks like there are two distinct bugs:

  1. ZoomContainer doesn't respect outside zoomDomain changes (well it does, until you zoom again). This is best seen in the JSfiddle if you zoom, then click "Part", then zoom again. I've been able to fix this bug.
  2. ZoomContainer only calculates the originalDomain once. This is a theory for now; still investigating. This bug is best seen in the JSfiddle if you zoom, then click "All", then zoom again.

@chrisbolin
Copy link
Contributor

fixed (1) bug, ZoomContainer doesn't respect outside zoomDomain changes. PR FormidableLabs/victory-chart#475. look for it in a release in the near future.

@chrisbolin
Copy link
Contributor

another bug still lingers: ZoomContainer only calculates the originalDomain once. This is fine for many cases, but if new data is added (as in the JSFiddle example) the ZoomContainer won't recognize it.

@boygirl how should a container calculate its actually full domain (meaning what it can be zoomed out to)? I looked around victory-core, but wasn't sure what path to take.

@chrisbolin
Copy link
Contributor

fixed (2) bug, ZoomContainer only calculates the originalDomain once; therefore if new data is added the ZoomContainer wouldn't recognize it. PR FormidableLabs/victory-chart#476

boygirl added a commit that referenced this issue Jul 17, 2018
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