0
0
mirror of https://github.com/go-gitea/gitea.git synced 2026-02-05 12:54:34 +01:00
gitea/templates/repo/pulls/tab_menu.tmpl
silverwind 1d399bb1d1
Improve diff file headers (#36215)
- reduce file name font size from 15px to 14px
- fix labels and buttons being cut off when their size is constrained
- change labels from monospace to sans-serif font
- move diff stats to right and change them from sum of changes to +/-
- change filemode to label and change text to match other labels

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-01-12 20:29:35 +08:00

24 lines
1.2 KiB
Handlebars

<div class="ui pull tabs container">
<div class="ui top attached pull tabular menu">
<a class="item {{if .PageIsPullConversation}}active{{end}}" href="{{.Issue.Link}}">
{{svg "octicon-comment-discussion"}}
{{template "shared/misc/tabtitle" (ctx.Locale.Tr "repo.pulls.tab_conversation")}}
<span class="ui small label">{{.Issue.NumComments}}</span>
</a>
<a class="item {{if .PageIsPullCommits}}active{{end}}" {{if .NumCommits}}href="{{.Issue.Link}}/commits"{{end}}>
{{svg "octicon-git-commit"}}
{{template "shared/misc/tabtitle" (ctx.Locale.Tr "repo.pulls.tab_commits")}}
<span class="ui small label">{{if .NumCommits}}{{.NumCommits}}{{else}}-{{end}}</span>
</a>
<a class="item {{if .PageIsPullFiles}}active{{end}}" href="{{.Issue.Link}}/files">
{{svg "octicon-diff"}}
{{template "shared/misc/tabtitle" (ctx.Locale.Tr "repo.pulls.tab_files")}}
<span class="ui small label">{{if .NumFiles}}{{.NumFiles}}{{else}}-{{end}}</span>
</a>
{{if or .DiffShortStat.TotalAddition .DiffShortStat.TotalDeletion}}
{{template "repo/diff/stats" dict "Addition" .DiffShortStat.TotalAddition "Deletion" .DiffShortStat.TotalDeletion "Classes" "tw-ml-auto tw-pl-3 tw-font-semibold"}}
{{end}}
</div>
<div class="ui tabs divider"></div>
</div>