diff options
Diffstat (limited to 'templates/repo/sub_menu.tmpl')
-rw-r--r-- | templates/repo/sub_menu.tmpl | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/templates/repo/sub_menu.tmpl b/templates/repo/sub_menu.tmpl index 73d6409a90..2c3fb25a9c 100644 --- a/templates/repo/sub_menu.tmpl +++ b/templates/repo/sub_menu.tmpl @@ -5,11 +5,14 @@ <div class="item{{if .PageIsCommits}} active{{end}}"> <a class="ui" href="{{.RepoLink}}/commits{{if .IsViewBranch}}/branch{{else if .IsViewTag}}/tag{{else if .IsViewCommit}}/commit{{end}}/{{EscapePound .BranchName}}">{{svg "octicon-history"}} <b>{{.CommitsCount}}</b> {{.i18n.Tr (TrN .i18n.Lang .CommitsCount "repo.commit" "repo.commits") }}</a> </div> - {{end}} - {{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo) }} <div class="item{{if .PageIsBranches}} active{{end}}"> <a class="ui" href="{{.RepoLink}}/branches/">{{svg "octicon-git-branch"}} <b>{{.BranchesCount}}</b> {{.i18n.Tr (TrN .i18n.Lang .BranchesCount "repo.branch" "repo.branches") }}</a> </div> + {{if $.Permission.CanRead $.UnitTypeCode}} + <div class="item"> + <a class="ui" href="{{.RepoLink}}/tags">{{svg "octicon-tag"}} <b>{{.NumReleases}}</b> {{.i18n.Tr (TrN .i18n.Lang .NumReleases "repo.release" "repo.releases") }}</a> + </div> + {{end}} <div class="item"> <span class="ui">{{svg "octicon-database"}} <b>{{SizeFmt .Repository.Size}}</b></span> </div> |