remove console.logs from prod code

This commit is contained in:
jordy 2023-04-22 14:09:03 +02:00
parent 43107965a9
commit fb24398b01

View file

@ -117,9 +117,7 @@
while (!imgContainer.classList.contains("page-container")) { while (!imgContainer.classList.contains("page-container")) {
imgContainer = imgContainer.parentNode; imgContainer = imgContainer.parentNode;
} }
console.log("imgContainer", imgContainer);
const sibling = imgContainer.previousSibling; const sibling = imgContainer.previousSibling;
console.log("sibling", sibling);
if (sibling) { if (sibling) {
pagesContainer.removeChild(imgContainer); pagesContainer.removeChild(imgContainer);
pagesContainer.insertBefore(imgContainer, sibling); pagesContainer.insertBefore(imgContainer, sibling);
@ -134,17 +132,13 @@
while (!imgContainer.classList.contains("page-container")) { while (!imgContainer.classList.contains("page-container")) {
imgContainer = imgContainer.parentNode; imgContainer = imgContainer.parentNode;
} }
console.log("imgContainer", imgContainer);
const sibling = imgContainer.nextSibling; const sibling = imgContainer.nextSibling;
console.log("sibling", sibling);
if (sibling) { if (sibling) {
pagesContainer.removeChild(imgContainer); pagesContainer.removeChild(imgContainer);
if (sibling.nextSibling) { if (sibling.nextSibling) {
pagesContainer.insertBefore(imgContainer, sibling.nextSibling); pagesContainer.insertBefore(imgContainer, sibling.nextSibling);
console.log("insert sibling.nextSibling", sibling.nextSibling);
} else { } else {
pagesContainer.appendChild(imgContainer) pagesContainer.appendChild(imgContainer)
console.log("append");
} }
imgContainer.scrollIntoView({ imgContainer.scrollIntoView({
behavior: "instant", behavior: "instant",
@ -307,7 +301,6 @@
const rotation = img.style.rotate; const rotation = img.style.rotate;
if (rotation) { if (rotation) {
const rotationAngle = parseInt(rotation.replace(/[^\d-]/g, '')); const rotationAngle = parseInt(rotation.replace(/[^\d-]/g, ''));
console.log(img.style.rotate, img.style.rotate.replace(/[^\d-]/g, ''))
page.setRotation(PDFLib.degrees(page.getRotation().angle + rotationAngle)) page.setRotation(PDFLib.degrees(page.getRotation().angle + rotationAngle))
} }