-
Notifications
You must be signed in to change notification settings - Fork 3
png/svg download to include legend? #541
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
Comments
It's mostly an observablehq question, but it's also a Plot question, since Plot returns an HTML figure. Either way we'll need to find a good solution! For PNG downloads, I've started experimenting with the image-to-html library here: https://observablehq.com/@fil/hello-html-to-image ; one could also try with html2canvas https://observablehq.com/@fil/hello-html2canvas For SVG, I haven't found how to generically convert HTML to SVG, but I have a heap of code that 99% works. https://observablehq.com/@fil/plot-figure-to-svg |
Please file this in the Observable feedback repository: https://github.com/observablehq/feedback I would transfer it but for some reason GitHub isn’t letting me. |
This comment was marked as off-topic.
This comment was marked as off-topic.
@Fil Thanks! The html-to-image tool will let me do what I need to, looking forward to an update in observablehq :) |
This now works! Try it out and let us know if you run into other issues. |
I don't know if this is a
Plot
question or anobservablehq.com
question, but I thought I'd start here.On any of the charts with legends here: https://observablehq.com/@observablehq/plot-legends, if I click "Download PNG" or "Download SVG", I get an image of the chart that does not include the legend. I imagine this follows from the legend being an add-on to the chart.
Could there be a convenient way to get them both in an image download?
Thanks!
The text was updated successfully, but these errors were encountered: