summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2020-08-23 21:05:17 +0200
committerGitHub <noreply@github.com>2020-08-23 20:05:17 +0100
commitdd8ec121880fda03691cf9f4b17be88e1d4be030 (patch)
treec6379e584b2a3b57ee9ef00d59ca1151d6b5294c /templates
parentd2cee3eea60cd0e459e665dad289b2c5adc1a2a5 (diff)
downloadgitea-dd8ec121880fda03691cf9f4b17be88e1d4be030.tar.gz
gitea-dd8ec121880fda03691cf9f4b17be88e1d4be030.zip
Increase clickable area on files table links (#12553)
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/view_list.tmpl52
1 files changed, 23 insertions, 29 deletions
diff --git a/templates/repo/view_list.tmpl b/templates/repo/view_list.tmpl
index de7d5b1ea9..db810890f5 100644
--- a/templates/repo/view_list.tmpl
+++ b/templates/repo/view_list.tmpl
@@ -45,41 +45,35 @@
<tr>
{{if $entry.IsSubModule}}
<td>
- <span class="truncate">
- {{svg "octicon-file-submodule" 16}}
- {{$refURL := $commit.RefURL AppUrl $.Repository.FullName}}
- {{if $refURL}}
- <a href="{{$refURL}}">{{$entry.Name}}</a> @ <a href="{{$refURL}}/commit/{{$commit.RefID}}">{{ShortSha $commit.RefID}}</a>
- {{else}}
- {{$entry.Name}} @ {{ShortSha $commit.RefID}}
- {{end}}
- </span>
+ {{svg "octicon-file-submodule" 16}}
+ {{$refURL := $commit.RefURL AppUrl $.Repository.FullName}}
+ {{if $refURL}}
+ <a href="{{$refURL}}">{{$entry.Name}}</a> @ <a href="{{$refURL}}/commit/{{$commit.RefID}}">{{ShortSha $commit.RefID}}</a>
+ {{else}}
+ {{$entry.Name}} @ {{ShortSha $commit.RefID}}
+ {{end}}
</td>
{{else}}
<td class="name four wide">
- <span class="truncate">
- {{if $entry.IsDir}}
- {{$subJumpablePathName := $entry.GetSubJumpablePathName}}
- {{$subJumpablePath := SubJumpablePath $subJumpablePathName}}
- {{svg "octicon-file-directory" 16}}
- <a href="{{EscapePound $.TreeLink}}/{{EscapePound $subJumpablePathName}}" title="{{$subJumpablePathName}}">
- {{if eq (len $subJumpablePath) 2}}
- <span class="jumpable-path">{{index $subJumpablePath 0}}</span>{{index $subJumpablePath 1}}
- {{else}}
- {{index $subJumpablePath 0}}
- {{end}}
- </a>
- {{else}}
- {{svg (printf "octicon-%s" (EntryIcon $entry)) 16}}
- <a href="{{EscapePound $.TreeLink}}/{{EscapePound $entry.Name}}" title="{{$entry.Name}}">{{$entry.Name}}</a>
- {{end}}
- </span>
+ {{if $entry.IsDir}}
+ {{$subJumpablePathName := $entry.GetSubJumpablePathName}}
+ {{$subJumpablePath := SubJumpablePath $subJumpablePathName}}
+ {{svg "octicon-file-directory" 16}}
+ <a href="{{EscapePound $.TreeLink}}/{{EscapePound $subJumpablePathName}}" title="{{$subJumpablePathName}}">
+ {{if eq (len $subJumpablePath) 2}}
+ <span class="jumpable-path">{{index $subJumpablePath 0}}</span>{{index $subJumpablePath 1}}
+ {{else}}
+ {{index $subJumpablePath 0}}
+ {{end}}
+ </a>
+ {{else}}
+ {{svg (printf "octicon-%s" (EntryIcon $entry)) 16}}
+ <a href="{{EscapePound $.TreeLink}}/{{EscapePound $entry.Name}}" title="{{$entry.Name}}">{{$entry.Name}}</a>
+ {{end}}
</td>
{{end}}
<td class="message nine wide">
- <span class="truncate">
- <a href="{{$.RepoLink}}/commit/{{$commit.ID}}" title="{{$commit.Summary}}">{{$commit.Summary | RenderEmoji}}</a>
- </span>
+ <a href="{{$.RepoLink}}/commit/{{$commit.ID}}" title="{{$commit.Summary}}">{{$commit.Summary | RenderEmoji}}</a>
</td>
<td class="text right age three wide">{{TimeSince $commit.Committer.When $.Lang}}</td>
</tr>