mirror of
https://github.com/go-gitea/gitea
synced 2025-07-26 12:18:36 +00:00
Add file tree to file view page (#32721)
Resolve #29328 This pull request introduces a file tree on the left side when reviewing files of a repository. --------- Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
15
templates/repo/view_file_tree.tmpl
Normal file
15
templates/repo/view_file_tree.tmpl
Normal file
@@ -0,0 +1,15 @@
|
||||
<div class="flex-text-block tw-mb-2">
|
||||
<button class="ui compact tiny icon button"
|
||||
data-global-click="onRepoViewFileTreeToggle" data-toggle-action="hide"
|
||||
data-tooltip-content="{{ctx.Locale.Tr "repo.diff.hide_file_tree"}}">
|
||||
{{svg "octicon-sidebar-expand"}}
|
||||
</button>
|
||||
<b>Files</b>
|
||||
</div>
|
||||
|
||||
{{/* TODO: Dynamically move components such as refSelector and createPR here */}}
|
||||
<div id="view-file-tree" class="tw-overflow-auto tw-h-full is-loading"
|
||||
data-repo-link="{{.RepoLink}}"
|
||||
data-tree-path="{{$.TreePath}}"
|
||||
data-current-ref-name-sub-url="{{.RefTypeNameSubURL}}"
|
||||
></div>
|
Reference in New Issue
Block a user