aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo
diff options
context:
space:
mode:
authorAdam Strzelecki <ono@java.pl>2015-11-30 15:22:24 +0100
committerAdam Strzelecki <ono@java.pl>2015-12-02 21:38:52 +0100
commit99b958db4325fd52566dd0d0e81afb8d891bac27 (patch)
treefc547efd47a356c1f2db0e0e01c59b7a6ee33c24 /templates/repo
parent22b0dfbb35f10f22ef0485e289f44532d7a71863 (diff)
downloadgitea-99b958db4325fd52566dd0d0e81afb8d891bac27.tar.gz
gitea-99b958db4325fd52566dd0d0e81afb8d891bac27.zip
UI: Mark top menu icons blue only when non-zero
Diffstat (limited to 'templates/repo')
-rw-r--r--templates/repo/sidebar.tmpl8
1 files changed, 4 insertions, 4 deletions
diff --git a/templates/repo/sidebar.tmpl b/templates/repo/sidebar.tmpl
index 912b50570b..4c0ab588c6 100644
--- a/templates/repo/sidebar.tmpl
+++ b/templates/repo/sidebar.tmpl
@@ -4,16 +4,16 @@
<i class="icon octicon octicon-code"></i> {{.i18n.Tr "repo.code"}}
</a>
<a class="{{if .PageIsIssueList}}active{{end}} item" href="{{.RepoLink}}/issues">
- <i class="icon octicon octicon-issue-opened"></i> {{.i18n.Tr "repo.issues"}} <span class="ui blue small label">{{.Repository.NumOpenIssues}}</span>
+ <i class="icon octicon octicon-issue-opened"></i> {{.i18n.Tr "repo.issues"}} <span class="ui {{if eq 0 .Repository.NumOpenIssues}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenIssues}}</span>
</a>
<a class="{{if .PageIsPullList}}active{{end}} item" href="{{.RepoLink}}/pulls">
- <i class="icon octicon octicon-git-pull-request"></i> {{.i18n.Tr "repo.pulls"}} <span class="ui blue small label">{{.Repository.NumOpenPulls}}</span>
+ <i class="icon octicon octicon-git-pull-request"></i> {{.i18n.Tr "repo.pulls"}} <span class="ui {{if eq 0 .Repository.NumOpenPulls}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenPulls}}</span>
</a>
<a class="{{if .PageIsCommits}}active{{end}} item" href="{{.RepoLink}}/commits/{{EscapePound .BranchName}}">
- <i class="icon octicon octicon-history"></i> {{.i18n.Tr "repo.commits"}} <span class="ui blue small label">{{.CommitsCount}}</span>
+ <i class="icon octicon octicon-history"></i> {{.i18n.Tr "repo.commits"}} <span class="ui {{if eq 0 .CommitsCount}}gray{{else}}blue{{end}} small label">{{.CommitsCount}}</span>
</a>
<a class="{{if .PageIsReleaseList}}active{{end}} item" href="{{.RepoLink}}/releases">
- <i class="icon octicon octicon-tag"></i> {{.i18n.Tr "repo.releases"}} <span class="ui blue small label">{{.Repository.NumTags}}</span>
+ <i class="icon octicon octicon-tag"></i> {{.i18n.Tr "repo.releases"}} <span class="ui {{if eq 0 .Repository.NumTags}}gray{{else}}blue{{end}} small label">{{.Repository.NumTags}}</span>
</a>
<a class="{{if .PageIsWiki}}active{{end}} item" href="{{.RepoLink}}/wiki">
<i class="icon octicon octicon-book"></i> {{.i18n.Tr "repo.wiki"}}