aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/file_info.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'templates/repo/file_info.tmpl')
-rw-r--r--templates/repo/file_info.tmpl28
1 files changed, 28 insertions, 0 deletions
diff --git a/templates/repo/file_info.tmpl b/templates/repo/file_info.tmpl
new file mode 100644
index 0000000000..90a831fb8e
--- /dev/null
+++ b/templates/repo/file_info.tmpl
@@ -0,0 +1,28 @@
+<div class="file-info text grey normal mono">
+ {{if .FileIsSymlink}}
+ <div class="file-info-entry">
+ {{.locale.Tr "repo.symbolic_link"}}
+ </div>
+ {{end}}
+ {{if .NumLinesSet}}{{/* Explicit attribute needed to show 0 line changes */}}
+ <div class="file-info-entry">
+ {{.NumLines}} {{.locale.TrN .NumLines "repo.line" "repo.lines"}}
+ </div>
+ {{end}}
+ {{if .FileSize}}
+ <div class="file-info-entry">
+ {{FileSize .FileSize}}{{if .IsLFSFile}} ({{.locale.Tr "repo.stored_lfs"}}){{end}}
+ </div>
+ {{end}}
+ {{if .LFSLock}}
+ <div class="file-info-entry ui tooltip" data-content="{{.LFSLockHint}}">
+ {{svg "octicon-lock" 16 "mr-2"}}
+ <a href="{{.LFSLockOwnerHomeLink}}">{{.LFSLockOwner}}</a>
+ </div>
+ {{end}}
+ {{if .LexerName}}
+ <div class="file-info-entry">
+ {{.LexerName}}
+ </div>
+ {{end}}
+</div>