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

what props to use for zoom and drag? #53

Open
jahnavi310 opened this issue Oct 13, 2017 · 1 comment
Open

what props to use for zoom and drag? #53

jahnavi310 opened this issue Oct 13, 2017 · 1 comment

Comments

@jahnavi310
Copy link

@jahnavi310 jahnavi310 commented Oct 13, 2017

Hi @fastfrwrd,

I am using the most basic version of the forced graph:

<ForceGraph simulationOptions={{ height: 800, width: 800 }}>
                    <ForceGraphNode node={{ id: 'first-node' }} fill="red" />
                    <ForceGraphNode node={{ id: 'second-node' }} fill="blue"/>
                    <ForceGraphNode node={{ id: 'third-node' }} fill="blue" />
                    <ForceGraphLink link={{ source: 'first-node', target: 'second-node' }} />
                    <ForceGraphLink link={{ source: 'first-node', target: 'third-node' }} />
                   
     </ForceGraph>

I am also referring to the react story book here: https://uber.github.io/react-vis-force/?selectedKind=%3CForceGraph%20%2F%3E&selectedStory=Characters%20from%20Les%20Mis%20%28zoomable%29&full=0&down=1&left=1&panelRight=0&downPanel=kadirahq%2Fstorybook-addon-actions%2Factions-panel

I want to achieve the zoom and drag functionality but I am unable to find the proper documentation on which props need to be set and how.

Any help would be much appreciated.

Thanks in advance.

@JimmyMow
Copy link

@JimmyMow JimmyMow commented Oct 27, 2017

zoom and zoomOptions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.