fix settings and navigation

This commit is contained in:
nahakubuilde
2025-08-25 18:56:00 +01:00
parent e97e24699e
commit 27b8442c6f
2 changed files with 13 additions and 9 deletions

View File

@@ -380,6 +380,16 @@
}
});
// Right-click on folder in sidebar opens folder view in current page
document.addEventListener('contextmenu', function(e) {
const toggle = e.target.closest('.tree-toggle');
if (!toggle) return;
e.preventDefault();
const path = toggle.getAttribute('data-path') || '';
const url = '/folder/' + path;
window.location.href = url;
});
// Auto-expand active path
function expandActivePath() {
const activeItem = document.querySelector('.sidebar-item.active');