We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a35604c commit 688d23bCopy full SHA for 688d23b
static/js/custom.js
@@ -154,13 +154,15 @@ async function html2Img(html) {
154
addQRPart(footer);
155
div.appendChild(footer);
156
let bodyBackup = document.body;
157
+ let postionBackup = window.pageYOffset || document.documentElement.scrollTop;
158
if (window.mobileCheck()) {
159
document.body = document.createElement("body");
160
}
161
document.body.appendChild(div);
162
let canvas = await html2canvas(div, {allowTaint: true, useCORS: true});
163
164
document.body = bodyBackup;
165
+ window.scrollTo(0, postionBackup);
166
} else {
167
document.body.removeChild(div);
168
0 commit comments