Comments (8)
@jonsch1 Thanks for providing the example!
Different hardware and browsers can have different maximum point size limit which makes it a bit difficult to adapt to. We're thinking about implementing a new point sizing strategy on zoom and will keep you posted. Most likely that will happen closer to summer.
from cosmos.
@jonsch1 Sorry, my mistake, not zoomNodesOnZoom
, but scaleNodesOnZoom
🤦♀️ Should work with react too.
from cosmos.
Thanks @jonsch1 !
Could you please share more details about the scaling issue you're encountering? As a potential solution, you could try using the beta version of the @cosmograph/react library, version 1.4.0-beta.0, which includes a newer version of the @cosmograph/cosmos library.
from cosmos.
Thank you for the quick response! So, i tried the 1.4.0 beta version, but it didn't help.
Here is a more detailed explanation and image of the scaling issue:
When zooming in from a high distance, nodes grow until they reach their maximum size. Further zooming in won't change the node size, as they shrink to maintain their relative size.
However, when opening the visualization in Safari, it seems that the maximum node size is much larger, which reduces the visualization's effectiveness when zooming in to focus on a group of nodes.
from cosmos.
@jonsch1 You can alternatively disable the resizing of nodes on zoom by setting the config option zoomNodesOnZoom
to false
.
from cosmos.
Thank you all for the answers!! @Stukova Thank you for the suggestion, although I wouldn't want to disable the resizing I think. The option zoomNodesOnZoom seems not to be available in the current react version (1.4.0 beta). In general if I want to have the quickest access to new features it probably makes sense to use the typescript vanilla version, right? :)
from cosmos.
That works, thanks!
from cosmos.
So, setting scaleNodesOnZoom to false and setting nodeSize to 20 actually solves my cross-browser scaling issue. So i wouldn't mind if you close this issue. :)
from cosmos.
Related Issues (20)
- graph nodes are in blury format and the labels are illegible HOT 4
- Feature request: same dataset should render the same layout HOT 2
- Missing dist folder in the published 1.3.0-beta.0 HOT 2
- Visually highlight a node when hovering/clicking HOT 2
- Selection and with selection; action(s)
- Question: Using only the simulation and skipping visualization? HOT 3
- repulsionFromMouse doesn't seem to work HOT 1
- Feature request: Distinct Node Colors for various Groups Perception
- Is it possible to add/remove nodes and links during simulation?
- set linkColor rgba HOT 2
- Center on a specific node during simulation?
- First node in graph has no mouse event HOT 1
- Device render problem HOT 4
- Adjustable Link Length HOT 1
- Style nodes using images or svgs HOT 5
- Is iOS support still planned / possible? HOT 1
- A problem with building application after using @interacta/css-labels HOT 2
- Is a React Component possible? HOT 5
- Can't get basic setup to work on a Vue application HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cosmos.