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

PNGs downloaded from different breakpoints have charts of different widths #1206

Open
anth-volk opened this issue Jan 17, 2024 · 3 comments
Open

Comments

@anth-volk
Copy link
Collaborator

This is what I receive if I download a chart from roughly full-screen on desktop:

genderDeepPovertyImpactPolicy #44170(3)

And this is what I get from about two-thirds width:

genderDeepPovertyImpactPolicy #44170(2)

Ideally, we should revamp how the downloads are setup and be more concise so that all users receive the same output, given the same policy and desired chart.

@abhcs
Copy link
Collaborator

abhcs commented Jan 17, 2024

Do you see the same issues when you use the "print + save as pdf" workflow?

@anth-volk
Copy link
Collaborator Author

Interestingly, no, I don't have those issues, although there's absolutely no margin or padding on the printed version, meaning parts would almost certainly get cut off if anyone ever actually printed them

@abhcs
Copy link
Collaborator

abhcs commented Jan 18, 2024

Interestingly, no

That is expected because react-to-print creates a new frame and adds contents to it unlike the current solution for "download png".

parts would almost certainly get cut off if anyone ever actually printed them

Could be fixed by passing margins to react-to-print: MatthewHerbst/react-to-print#29 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

2 participants