Using relative path for download.

This commit is contained in:
Erignoux Laurent
2025-10-30 16:07:26 +08:00
parent 4547670d6e
commit 83ed006088
+1 -1
View File
@@ -51,7 +51,7 @@ app.registerExtension({
const folderName = cleanFilePath.replace(/[^\\/]+$/, "");
const fileNameMatch = cleanFilePath.match(/[^\\/]+$/);
const fileName = fileNameMatch ? fileNameMatch[0] : "";
const viewUrl = `/api/view?subfolder=${encodeURIComponent(folderName)}&filename=${encodeURIComponent(fileName)}&type=output`;
const viewUrl = `api/view?subfolder=${encodeURIComponent(folderName)}&filename=${encodeURIComponent(fileName)}&type=output`;
// Open the presentation in a new tab
window.open(viewUrl, "_blank");