aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/diff/section_unified.tmpl
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2020-07-13 15:21:19 +0200
committerGitHub <noreply@github.com>2020-07-13 16:21:19 +0300
commit84a419de98701fe1e8a0d7f1be5d82c7f5e4ac92 (patch)
tree9953031b9d1200d86006ba1717f638fe8c986888 /templates/repo/diff/section_unified.tmpl
parentb49a195839ae388184c5111464d8ea3dbe03772b (diff)
downloadgitea-84a419de98701fe1e8a0d7f1be5d82c7f5e4ac92.tar.gz
gitea-84a419de98701fe1e8a0d7f1be5d82c7f5e4ac92.zip
Replace code fold icons with octicons (#12222)
- replace font-awesome icons with octicons - clean up js and css surrounding the code expansion and file folding - fix hover color on arc-green - tweak diff line number colors Co-authored-by: zeripath <art27@cantab.net>
Diffstat (limited to 'templates/repo/diff/section_unified.tmpl')
-rw-r--r--templates/repo/diff/section_unified.tmpl12
1 files changed, 9 insertions, 3 deletions
diff --git a/templates/repo/diff/section_unified.tmpl b/templates/repo/diff/section_unified.tmpl
index 040545069a..0f561a8a84 100644
--- a/templates/repo/diff/section_unified.tmpl
+++ b/templates/repo/diff/section_unified.tmpl
@@ -5,13 +5,19 @@
{{if eq .GetType 4}}
<td colspan="2" class="lines-num">
{{if or (eq $line.GetExpandDirection 3) (eq $line.GetExpandDirection 5) }}
- <i class="ui blob-excerpt fa fa-caret-down" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=down" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}"></i>
+ <a role="button" class="blob-excerpt" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=down" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}">
+ {{svg "octicon-fold-down" 16}}
+ </a>
{{end}}
{{if or (eq $line.GetExpandDirection 3) (eq $line.GetExpandDirection 4) }}
- <i class="ui blob-excerpt fa fa-caret-up" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=up" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}"></i>
+ <a role="button" class="blob-excerpt" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=up" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}">
+ {{svg "octicon-fold-up" 16}}
+ </a>
{{end}}
{{if eq $line.GetExpandDirection 2}}
- <span class="ui blob-excerpt" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}">{{svg "octicon-fold" 16}}</span>
+ <a role="button" class="blob-excerpt" data-url="{{$.root.RepoLink}}/blob_excerpt/{{$.root.AfterCommitID}}" data-query="{{$line.GetBlobExcerptQuery}}&style=unified&direction=" data-anchor="diff-{{Sha1 $file.Name}}K{{$line.SectionInfo.RightIdx}}">
+ {{svg "octicon-fold" 16}}
+ </a>
{{end}}
</td>
{{else}}