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

positioning of the chart #293

Closed
Saranyavijayan opened this issue Jul 27, 2023 · 1 comment
Closed

positioning of the chart #293

Saranyavijayan opened this issue Jul 27, 2023 · 1 comment
Labels
question Further information is requested

Comments

@Saranyavijayan
Copy link

My chart is now right aligned and have layout property set to "left". Is there a way to align the chart to the left ? Also how can i align the chart nodes to the top.

git

My current chart looks like above image(center aligned) how can i apply custom transform to move the chart to left (align graph to left of the page).

Also how can i change the position of all nodes to the top . I want all my nodes to start from the top of the page

@bumbeishvili
Copy link
Owner

I think the only property which we have currently is rootMargin

Which basically moves root (and subsequent nodes) up or down, haven't really tried it for other directions

You can also override centerTransform method before chart rendering and move chart to any side you want

"centerTransform": ({ root, rootMargin, centerY, scale, centerX }) => `translate(${rootMargin},${centerY}) scale(${scale})`,

@bumbeishvili bumbeishvili added the question Further information is requested label Sep 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants