From b7b1230d2d1cf1a7cf70dc18f08830846943672c Mon Sep 17 00:00:00 2001 From: Herwin Bozet Date: Sun, 2 Mar 2025 21:52:23 +0100 Subject: [PATCH] Hotfix for broken templates on BS4 and RAW post-processors Update excel-password-remover.mjs --- .../excel-password-remover/excel-password-remover.mjs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/static/resources/NibblePoker/applets/excel-password-remover/excel-password-remover.mjs b/static/resources/NibblePoker/applets/excel-password-remover/excel-password-remover.mjs index 7ada503..392bafb 100644 --- a/static/resources/NibblePoker/applets/excel-password-remover/excel-password-remover.mjs +++ b/static/resources/NibblePoker/applets/excel-password-remover/excel-password-remover.mjs @@ -108,12 +108,16 @@ export function isExcelExtension(fileName) { ).then(eFragment => { console.debug(eFragment); - const eFileOutput = eFragment.firstChild; + // Doesn't work on BS4 and RAW, it returns " "... + //const eFileOutput = eFragment.firstChild; + + const eFileOutput = eFragment.querySelector("*"); eFileOutput.addEventListener("click", function() { console.debug(123); //processedZipFile downloadProcessedFile(excelFile); }); + console.debug(eFileOutput); eResultContainer.appendChild(eFileOutput); //const uuid = crypto.randomUUID(); @@ -294,7 +298,7 @@ export function isExcelExtension(fileName) { if(excelFile.filesTotalCount !== excelFile.filesProcessedCount) { setTimeout(waitFilesBeingProcessed, 50); } else { - console.debug("Done, now switching the page !"); + console.debug("Done !"); if(excelFile.passwordsRemoved > 0) { onFileHavingPasswordRemoved(excelFile); } else {