In dhtmlx gantt chart exportToPDF if i pass the raw: true property custom styles are reflecting but the gantt chart is downloading only the visible portion which we get in the browser. If i didnt pass the raw : true whole gantt chart is downloading

gantt.exportToPDF({
//@ts-ignore
name: ${chartType === "phase" ? chartDetails?.phase_name : chartDetails?.name}_${option}ly_${ moment().get("date") < 10 ? 0${moment().get(“date”)} : moment().get("date") }-${ moment().get("month") < 10 ?0${moment().get(“month”) + 1} : moment().get("month") + 1 }-${moment().get("year")},${ moment().get("hour") < 10 ?0${moment().get(“hour”)} : moment().get("hour") }-${ moment().get("minute") < 10 ?0${moment().get(“minute”)} : moment().get("minute") }-${ moment().get("second") < 10 ?0${moment().get(“second”)} : moment().get("second") }.pdf,
header: “” + header + “”,
// raw: true,
callback: function (res: any) {
// alert(res.url);
window.open(res.url, “_self”);

  },
});

Can you please help to fix this issue.

Hello Uday,
Most likely, that issue occurs because of the layout configuration (the cols: [rows:[]] structure). The dev team will fix it in the future, but I cannot give you any ETA.
For now, you need to use various workarounds to make it works as expected.

Workarounds:
Add the style rule to extend the timeline only on the export module:
http://snippet.dhtmlx.com/5/7b1605226
http://snippet.dhtmlx.com/5/0821bda46

Use the autosize option to stretch the grid, then restore the previous width:
http://snippet.dhtmlx.com/5/343f8e2a6
https://snippet.dhtmlx.com/5/810d70012

Hello Uday,
The dev team updated the PDF export module to the 0.7.0 version. This includes the fix for the bug when the timeline is not fully displayed when using the cols: [rows:[]] layout configuration and exporting with the raw: true parameter.

Here is full list of changes:
https://docs.dhtmlx.com/gantt/desktop__pdf_export_module_whatsnew.html#070

If you use the online export server, you can try the beta export server that uses the latest version of the export module.

You can check how it works in the following snippets:

Main server:
https://snippet.dhtmlx.com/ytls1w1v
https://snippet.dhtmlx.com/1o1ij2l7

Beta server:
https://snippet.dhtmlx.com/9sleamvp
https://snippet.dhtmlx.com/rm7i50xd

After some time, the main server will use the newer version of the export module.

If you use the standalone export module, you can download the new version from the Client’s Area: