Skip to content
This repository has been archived by the owner on Jul 29, 2019. It is now read-only.

Graph2D breaks when zooming in/out #2580

Closed
mojoaxel opened this issue Jan 14, 2017 · 2 comments
Closed

Graph2D breaks when zooming in/out #2580

mojoaxel opened this issue Jan 14, 2017 · 2 comments
Assignees

Comments

@mojoaxel
Copy link
Member

You can reproduce the problem using "examples/graph2d/08_performance.html":

peek 2017-01-14 16-10

This was introduced after 4.17.0 and needs to be fixed before the 4.18 release!!

@mojoaxel
Copy link
Member Author

Also the console shows errors:

Invalid type received for "sampling". Expected: bool. Received [boolean] "true"
Problem value found at: 
options = {
  sampling
}

Invalid type received for "enabled". Expected: bool. Received [boolean] "false"
Problem value found at: 
options = {
  drawPoints: {
    enabled
  }
}

Invalid type received for "interpolation". Expected: object, bool. Received [boolean] "false"
Problem value found at: 
options = {
  interpolation
}

Errors have been found in the supplied options object.

@mojoaxel mojoaxel self-assigned this Jan 14, 2017
mojoaxel added a commit that referenced this issue Jan 15, 2017
This fixes a fixed strange string-number conversion issue.
It can happen that id "0" !== 0 what causes #2580.

fixes #2580
mojoaxel added a commit that referenced this issue Jan 15, 2017
This fixes a fixed strange string-number conversion issue.
It can happen that id "0" !== 0 what causes #2580.

fixes #2580
yotamberk pushed a commit that referenced this issue Jan 15, 2017
* fix(graph2d): fix #2500 for graph2d; improves #2580

* fix(DataSet): make sure the right id-type is used internaly

This fixes a fixed strange string-number conversion issue.
It can happen that id "0" !== 0 what causes #2580.

fixes #2580
@mojoaxel
Copy link
Member Author

There were two issues here. One is the problem described in #2500. The other one is a really strange:

GraphGroup.js:41 Uncaught TypeError: Cannot read property 'x' of undefined

This is caused by because in LineGraph.js#L481 the comparison between the IDs ("0" !== 0) fails. We have to make sure that internal ids are always of the same type.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants