Bug when trying to open print dialog in chrome
Hi, I'm using pagedjs 0.1.25 and an example very similar to the Moby Dick one. I have a root tag containing mostly
and some trivial other tags after loading I use
const paged = new Previewer()
const flow = paged.preview(document.getElementById('template'), undefined, undefined).then(flow => {
console.log('Rendered', flow.total, 'pages.')
})
to get a paged preview, which looks correct on first view.
BUT when opening the print dialog in chrome I get:
paged.js:644 Uncaught TypeError: Cannot read property 'getAttribute' of null
at findElement (paged.js:644)
at Layout.findEndToken (paged.js:1703)
at Page.checkUnderflowAfterResize (paged.js:2103)
at ResizeObserver.<anonymous> (paged.js:2060)
this is due the fact that, when reparsing on print dialog open tags are found with data-split-from="null"
like:
<template data-split-from="null" data-id="template"></template>
In the root tag all tags have data-ref's with a uuid.
Any ideas Ognian