diff --git a/src/core/xfa/template.js b/src/core/xfa/template.js index 52f927c82..74dcf4145 100644 --- a/src/core/xfa/template.js +++ b/src/core/xfa/template.js @@ -4540,8 +4540,10 @@ class Template extends XFAObject { this[$extra].breakingNode = null; if (node.targetType === "auto") { - // Just ignore the break and do layout again. - i--; + html = root[$flushHTML](); + if (html) { + htmlContentAreas[i].children.push(html); + } continue; } diff --git a/test/pdfs/xfa_hsbc_closure.pdf.link b/test/pdfs/xfa_hsbc_closure.pdf.link new file mode 100644 index 000000000..49301ac04 --- /dev/null +++ b/test/pdfs/xfa_hsbc_closure.pdf.link @@ -0,0 +1 @@ +https://web.archive.org/web/20210610145227/https://www.hsbc.fr/content/dam/hsbc/fr/docs/pib/Cloture-Compte.pdf diff --git a/test/test_manifest.json b/test/test_manifest.json index 0285f41f4..c582b83e3 100644 --- a/test/test_manifest.json +++ b/test/test_manifest.json @@ -2741,6 +2741,14 @@ "enableXfa": true, "type": "eq" }, + { "id": "hsbc_closure", + "file": "pdfs/xfa_hsbc_closure.pdf", + "md5": "7d101861d6232fe5f658e8aeca5c9891", + "rounds": 1, + "link": true, + "enableXfa": true, + "type": "eq" + }, { "id": "xfa_imm1344e", "file": "pdfs/xfa_imm1344e.pdf", "md5": "f9b8b6e7d385691efdea2544576f5eb2",