mirror of
https://github.com/go-gitea/gitea.git
synced 2025-04-08 17:05:45 +02:00
fix
This commit is contained in:
parent
3cbcd95e6a
commit
6f2de3ea5e
@ -84,10 +84,13 @@ export function initViewFileTreeSidebar() {
|
||||
}});
|
||||
fileTreeView.mount(fileTree);
|
||||
|
||||
window.addEventListener('popstate', () => {
|
||||
selectedItem.value = getSelectedPath(refString);
|
||||
loadContent(el);
|
||||
});
|
||||
if (!window.popstateListenerForViewFilePageAdded) {
|
||||
window.addEventListener('popstate', () => {
|
||||
selectedItem.value = getSelectedPath(refString);
|
||||
loadContent(el);
|
||||
});
|
||||
window.popstateListenerForViewFilePageAdded = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
1
web_src/js/globals.d.ts
vendored
1
web_src/js/globals.d.ts
vendored
@ -74,5 +74,6 @@ interface Window {
|
||||
turnstile: any,
|
||||
hcaptcha: any,
|
||||
codeEditors: any[],
|
||||
popstateListenerForViewFilePageAdded: boolean,
|
||||
updateCloneStates: () => void,
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user