+5
-3
appview/pages/templates/repo/blob.html
+5
-3
appview/pages/templates/repo/blob.html
···
16
{{ end }}
17
</div>
18
<div id="file-info">
19
-
<span class="text-gray-500 text-xs">
20
{{ .Lines }} lines
21
-
·
22
{{ byteFmt .SizeHint }}
23
-
</span>
24
</div>
25
</div>
26
</div>
27
28
29
{{ if .IsBinary }}<p class="text-center text-gray-400">This is a binary file and will not be displayed.</p>{{ else }}
30
<pre class="font-mono text-sm overflow-auto relative text-ellipsis"><code>{{ range $idx, $line := $lines }}<span class="flex">
31
<span class="{{ $code_number_style }}" style="min-width: {{$tot_chars}}ch;">{{ add $idx 1 }}</span>
32
<span class="whitespace-pre">{{ escapeHtml $line }}</span></span>{{ else }}<em class="text-gray-400">this file is empty</em>{{ end }}</code></pre>{{ end}}
33
{{ end }}
···
16
{{ end }}
17
</div>
18
<div id="file-info">
19
{{ .Lines }} lines
20
+
<span class="select-none px-2 [&:before]:content-['·']"></span>
21
{{ byteFmt .SizeHint }}
22
</div>
23
</div>
24
</div>
25
26
+
{{ if eq .Lines 0 }}
27
+
<p class="text-center text-gray-400">This file is empty.</p>
28
+
{{ else }}
29
30
{{ if .IsBinary }}<p class="text-center text-gray-400">This is a binary file and will not be displayed.</p>{{ else }}
31
<pre class="font-mono text-sm overflow-auto relative text-ellipsis"><code>{{ range $idx, $line := $lines }}<span class="flex">
32
<span class="{{ $code_number_style }}" style="min-width: {{$tot_chars}}ch;">{{ add $idx 1 }}</span>
33
<span class="whitespace-pre">{{ escapeHtml $line }}</span></span>{{ else }}<em class="text-gray-400">this file is empty</em>{{ end }}</code></pre>{{ end}}
34
{{ end }}
35
+
{{ end }}
+9
-18
appview/pages/templates/repo/commit.html
+9
-18
appview/pages/templates/repo/commit.html
···
19
</div>
20
21
<p class="text-sm text-gray-500">
22
-
<a href="mailto:{{ $commit.Author.Email }}" class="no-underline hover:underline text-gray-500">
23
-
{{ $commit.Author.Name }}
24
-
</a>
25
-
·
26
{{ timeFmt $commit.Author.When }}
27
-
·
28
<span class="font-mono">{{ $stat.FilesChanged }}</span> files <span class="font-mono">(+{{ $stat.Insertions }}, -{{ $stat.Deletions }})</span>
29
-
·
30
-
<a href="/{{ $repo }}/commit/{{ $commit.This }}" class="no-underline hover:underline text-gray-500">
31
-
{{ slice $commit.This 0 8 }}
32
-
</a>
33
{{ if $commit.Parent }}
34
-
<--
35
-
<a href="/{{ $repo }}/commit/{{ $commit.Parent }}" class="no-underline hover:underline text-gray-500">
36
-
{{ slice $commit.Parent 0 8 }}
37
-
</a>
38
{{ end }}
39
</p>
40
-
41
<div class="diff-stat">
42
<br>
43
<strong>jump to</strong>
···
94
95
<div id="right-side-items" class="p-2">
96
<a href="#file-{{ .Name.New }}" class="no-underline hover:underline">top of file</a>
97
-
98
{{ if gt $idx 0 }}
99
-
·
100
{{ $prev := index $diff (sub $idx 1) }}
101
<a href="#file-{{ $prev.Name.New }}" class="no-underline hover:underline">prev</a>
102
{{ end }}
103
104
-
105
{{ if lt $idx $last }}
106
-
·
107
{{ $next := index $diff (add $idx 1) }}
108
<a href="#file-{{ $next.Name.New }}" class="no-underline hover:underline">next</a>
109
{{ end }}
···
19
</div>
20
21
<p class="text-sm text-gray-500">
22
+
<a href="mailto:{{ $commit.Author.Email }}" class="no-underline hover:underline text-gray-500">{{ $commit.Author.Name }}</a>
23
+
<span class="px-1 select-none before:content-['\00B7']"></span>
24
{{ timeFmt $commit.Author.When }}
25
+
<span class="px-1 select-none before:content-['\00B7']"></span>
26
<span class="font-mono">{{ $stat.FilesChanged }}</span> files <span class="font-mono">(+{{ $stat.Insertions }}, -{{ $stat.Deletions }})</span>
27
+
<span class="px-1 select-none before:content-['\00B7']"></span>
28
+
<a href="/{{ $repo }}/commit/{{ $commit.This }}" class="no-underline hover:underline text-gray-500">{{ slice $commit.This 0 8 }}</a>
29
{{ if $commit.Parent }}
30
+
<span class="select-none">←</span>
31
+
<a href="/{{ $repo }}/commit/{{ $commit.Parent }}" class="no-underline hover:underline text-gray-500">{{ slice $commit.Parent 0 8 }}</a>
32
{{ end }}
33
</p>
34
<div class="diff-stat">
35
<br>
36
<strong>jump to</strong>
···
87
88
<div id="right-side-items" class="p-2">
89
<a href="#file-{{ .Name.New }}" class="no-underline hover:underline">top of file</a>
90
{{ if gt $idx 0 }}
91
+
<span class="px-1 select-none before:content-['\00B7']"></span>
92
{{ $prev := index $diff (sub $idx 1) }}
93
<a href="#file-{{ $prev.Name.New }}" class="no-underline hover:underline">prev</a>
94
{{ end }}
95
96
{{ if lt $idx $last }}
97
+
<span class="px-1 select-none before:content-['\00B7']"></span>
98
{{ $next := index $diff (add $idx 1) }}
99
<a href="#file-{{ $next.Name.New }}" class="no-underline hover:underline">next</a>
100
{{ end }}
+10
-10
appview/pages/templates/repo/index.html
+10
-10
appview/pages/templates/repo/index.html
···
127
href="/{{ $.RepoInfo.FullName }}/commit/{{ .Hash.String }}"
128
class="text-gray-500 no-underline hover:underline"
129
>{{ slice .Hash.String 0 8 }}</a
130
-
>
131
-
</span>
132
-
·
133
-
<span>
134
-
<a
135
href="mailto:{{ .Author.Email }}"
136
class="text-gray-500 no-underline hover:underline"
137
>{{ .Author.Name }}</a
138
-
>
139
-
</span>
140
-
·
141
-
<span>{{ timeFmt .Author.When }}</span>
142
-
</div>
143
</div>
144
{{ end }}
145
</div>
···
127
href="/{{ $.RepoInfo.FullName }}/commit/{{ .Hash.String }}"
128
class="text-gray-500 no-underline hover:underline"
129
>{{ slice .Hash.String 0 8 }}</a
130
+
>
131
+
</span>
132
+
<span class="mx-2 before:content-['·'] before:select-none"></span>
133
+
<span>
134
+
<a
135
href="mailto:{{ .Author.Email }}"
136
class="text-gray-500 no-underline hover:underline"
137
>{{ .Author.Name }}</a
138
+
>
139
+
</span>
140
+
<div class="inline-block px-1 select-none after:content-['·']"></div>
141
+
<span>{{ timeFmt .Author.When }}</span>
142
+
</div>
143
</div>
144
{{ end }}
145
</div>
+2
-2
appview/pages/templates/repo/tree.html
+2
-2
appview/pages/templates/repo/tree.html