UI for Pandoc integration (#393)

Co-authored-by: Thorsten Sommer
This commit is contained in:
nilskruthoffandThorsten Sommer authored and GitHub committed 2025-05-29 14:01:56 +02:00
1 parent 1d31fd9a22
commit 5b685193ef
15 files changed
+766 -4

No files matched your search

+10
View File
@@ -25,4 +25,14 @@ window.clearDiv = function (divName) {
window.scrollToBottom = function(element) {
element.scrollIntoView({ behavior: 'smooth', block: 'end', inline: 'nearest' });
}
window.triggerDownload = function(url, filename) {
const a = document.createElement('a');
a.href = url;
a.setAttribute('download', filename);
a.style.display = 'none';
document.body.appendChild(a);
a.click();
document.body.removeChild(a);
}