Can't export PNG or PDF

Is it possible to adjust and accept files with larger height and width?
I use the built-in export function, but it always shows “request entity too large”.
But the JSON file itself is only 1MB.

image

Provide examples for local testing
20240722.json (1.0 MB)

Hello.

Your provided data itself exports correctly:
https://snippet.dhtmlx.com/t57sdohy
The problem most probable in the usage of the additional custom css.
Please, make sure to define which css styles should be sent to the export service with the exportStyles property:

const diagram = new dhx.Diagram("diagram_container", { 
    exportStyles:[
        "https://mySite.com/exportStyle.css",
        "https://mySite.com/secondExportStyle.css"
    ]
});

If the problem still occurs for you please, provide a complete demo, where the problem can be reconstructed locally

I still use the above attached file and try to add this line afterwards,
exportStyles: false
.pdf can be produced normally.
But .png still shows Internal error
aaa

Please help check if there is any problem, thanks.

Below is my code
html

<section id="control_list" class="dhx_sample-controls">
	<button class="dhx_sample-btn dhx_sample-btn--flat" onclick="runEditor()">Edit</button>
	<button class="dhx_sample-btn dhx_sample-btn--flat" id="ex_png">Export PNG</button>
	<button class="dhx_sample-btn dhx_sample-btn--flat" id="ex_pdf">Export PDF</button>
</section>
<section id="container" class="dhx_sample-container__without-editor">
	<div id="diagram" class="dhx_sample-widget"></div>
	<div id="editor" class="dhx_sample-widget" style="display: none;"></div>
</section>

js

diagram = new dhx.Diagram("diagram", {
    lineConfig: {
      lineGap: 30,
    },
    exportStyles: false,
  });
  // initializing Diagram Editor
  editor = new dhx.DiagramEditor("editor", {
    controls: { autoLayout: false },
    lineConfig: {
      lineGap: 30,
    },
  });
  editorCont = document.querySelector("#editor");
  diagramCont = document.querySelector("#diagram");
  control = document.querySelector("#control_list");
  container = document.querySelector("#container");

  withEditor = "dhx_sample-container__with-editor";
  withoutEditor = "dhx_sample-container__without-editor";

  editor.events.on("ApplyButton", function () {
    collapse();
    diagram.data.parse(editor.serialize());
  });

  editor.events.on("ResetButton", function () {
    collapse();
  });
  // loads data from a local data source
  diagram.data.parse(the_json_data);

let file_name = "abc"
diagram.export.png({name: `${file_name}.png`});

Hello.

Unfortunately I was not able to reconstructed your issue locally.
Could you please, provide a complete demo or a demo link, where the problem can be reproduced?