arthur-mdn / ExportGrafanaDashboardToPDF

Free PDF Export Tool in Grafana Community version - Using Puppeteer
12 stars 1 forks source link

Page width should be configurable by user to improve readability of PDF created #2

Closed OlliKantola closed 2 months ago

OlliKantola commented 3 months ago

Text in panels doesn't fit and overlap. Same problem exists if I view my dashboard in browser and narrow down the window enough. Problem is solved by making the window wider. Here are some screenshots from my dashboard to help describe the issue. image image

File grafana_pdf.js hard codes width_px. Problem gets solved when I change the width to 1700, rebuild image and rerun the PDF creation. image image

Width_px should be possible to configure by user to be able to optimize the readability of PDF created.

arthur-mdn commented 2 months ago

Hello, thank you for the suggestion. The latest commit has introduced a parameter in the .env file to configure the PDF width. Please make sure to add this parameter to your .env file.

PDF_WIDTH_PX=1700