Merge pull request #268 from EdouardVanbelle/feat/file-url-history

This commit is contained in:
Dionisio Pozo
2026-04-07 18:49:42 +02:00
committed by GitHub
8 changed files with 73 additions and 21 deletions
+5 -1
View File
@@ -514,7 +514,11 @@ class InlineViewer {
URL.revokeObjectURL(this.currentBlobUrl);
this.currentBlobUrl = null;
}
// clear
window.app.viewFile = null;
window.updateHistory(false);
// Clear references
this.currentFile = null;
}
+3 -9
View File
@@ -27,15 +27,9 @@ class WopiEditor {
*/
async openInModal(fileId, fileName, action) {
action = action || 'edit';
try {
var data = await this._getEditorUrlWithFallback(fileId, fileName, action);
this._showModal(data, fileName);
} catch (error) {
console.error('Failed to open WOPI editor:', error);
if (window.showNotification) {
window.showNotification('Could not open the document editor.', 'error');
}
}
// Error is thrown, caller can handle a classic view as fallback
var data = await this._getEditorUrlWithFallback(fileId, fileName, action);
this._showModal(data, fileName);
}
/**