From 20221e1faa52540362740f913c68cf177e184362 Mon Sep 17 00:00:00 2001 From: yszl666 <941131649@qq.com> Date: Thu, 23 Jul 2026 10:05:43 +0800 Subject: [PATCH] fix(file-tree): handle submodule links and missing view container (#38033) Prevent tree view navigation from intercepting submodule entries so the browser can follow external repository links normally. --------- Signed-off-by: wxiaoguang Co-authored-by: dzf Co-authored-by: wxiaoguang --- web_src/js/components/ViewFileTreeItem.vue | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web_src/js/components/ViewFileTreeItem.vue b/web_src/js/components/ViewFileTreeItem.vue index c898b1df60..1e7a378a34 100644 --- a/web_src/js/components/ViewFileTreeItem.vue +++ b/web_src/js/components/ViewFileTreeItem.vue @@ -32,6 +32,8 @@ const onItemClick = (e: MouseEvent) => { // - the user didn't press any special key like "Ctrl+Click" (which may have custom browser behavior) // - the editor/commit form isn't dirty (a full page reload shows a confirmation dialog if the form contains unsaved changes) if (!isPlainClick(e) || shouldTriggerAreYouSure()) return; + // submodules (commit entry mode) point to external repos, let the browser handle navigation normally + if (props.item.entryMode === 'commit') return; e.preventDefault(); if (props.item.entryMode === 'tree') doLoadChildren(); store.navigateTreeView(props.item.fullPath);