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

Issue: Funnel not drawn #26

Open
RT-TL opened this issue Nov 17, 2020 · 3 comments
Open

Issue: Funnel not drawn #26

RT-TL opened this issue Nov 17, 2020 · 3 comments

Comments

@RT-TL
Copy link

RT-TL commented Nov 17, 2020

Hi greghub,
thanks for building this awesome and beautiful funnel graph library. I am experiencing the issue where either styles are not applied correctly or the SVG funnel is not drawn at all.

I used the CSS/JS files and the code from the example in the Readme. Here is a JS fiddle that shows the issue: https://jsfiddle.net/xyzb95oq/1/

@RT-TL
Copy link
Author

RT-TL commented Nov 17, 2020

Found the issue. A height-value needs to be assigned to the funnel. Otherwise it will draw the labels etc. but the actual SVG areas will be invisible because they have height 0.

@kublermdk
Copy link

Thank you for that @RT-TL

To get something resembling the screenshot in the Readme.md I found that I also had to add a wrapper div with some padding and a background and add graph.updateWidth() to a browser resize event.

Also, I hadn't realised the data structure for the values correctly, it's per label then an array of values for the subLabels, not per subLabel.

My example for anyone else in need:
https://jsfiddle.net/mkubler/cqeaj1vk/

@fdasilvan
Copy link

Thanks!

I wasn't being able to render the funnel but with your example I achieved it!

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