Skip to content

Commit 62c61aa

Browse files
GiteaBotyszl666dzfwxiaoguang
authored
fix(file-tree): handle submodule links and missing view container (#38033) (#38589)
Backport #38033 Signed-off-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: yszl666 <941131649@qq.com> Co-authored-by: dzf <douzf@sparkspacetech.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
1 parent 337fa5a commit 62c61aa

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

web_src/js/components/ViewFileTreeItem.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ const onItemClick = (e: MouseEvent) => {
3232
// - the user didn't press any special key like "Ctrl+Click" (which may have custom browser behavior)
3333
// - the editor/commit form isn't dirty (a full page reload shows a confirmation dialog if the form contains unsaved changes)
3434
if (!isPlainClick(e) || shouldTriggerAreYouSure()) return;
35+
// submodules (commit entry mode) point to external repos, let the browser handle navigation normally
36+
if (props.item.entryMode === 'commit') return;
3537
e.preventDefault();
3638
if (props.item.entryMode === 'tree') doLoadChildren();
3739
store.navigateTreeView(props.item.fullPath);

0 commit comments

Comments
 (0)