1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-26 12:18:36 +00:00

Improve detecting empty files (#31332)

Co-authored-by: silverwind <me@silverwind.io>
This commit is contained in:
wxiaoguang
2024-06-13 09:06:46 +08:00
committed by GitHub
parent 7115dce773
commit 47ca61d8ba
11 changed files with 29 additions and 13 deletions

View File

@@ -4,12 +4,12 @@
{{ctx.Locale.Tr "repo.symbolic_link"}}
</div>
{{end}}
{{if .NumLinesSet}}{{/* Explicit attribute needed to show 0 line changes */}}
{{if ne .NumLines nil}}
<div class="file-info-entry">
{{.NumLines}} {{ctx.Locale.TrN .NumLines "repo.line" "repo.lines"}}
</div>
{{end}}
{{if .FileSize}}
{{if ne .FileSize nil}}
<div class="file-info-entry">
{{FileSize .FileSize}}{{if .IsLFSFile}} ({{ctx.Locale.Tr "repo.stored_lfs"}}){{end}}
</div>