summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2020-01-26 09:17:25 +0100
committerzeripath <art27@cantab.net>2020-01-26 08:17:25 +0000
commitfd094eea959a235654b7591da066dcbbee11fc25 (patch)
treed5b7029b39a58ceafa168016c03c312b2c792dab /templates
parent8d51f28ba04980734a04fef645a8065472e6ca63 (diff)
downloadgitea-fd094eea959a235654b7591da066dcbbee11fc25.tar.gz
gitea-fd094eea959a235654b7591da066dcbbee11fc25.zip
fix commit view JS features, reimplement folding (#9968)
* fix commit view JS features, reimplement folding File content folding was not working so I reimplemented it in a saner way. Then I noticed the issue was actually because of missing JS libraries (seen on the console of every commit with error 'SimpleMDE is not defined'). Fixed the libraries. I think the reimplementation is worth to keep. * add .closest polyfill Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/diff/box.tmpl4
1 files changed, 2 insertions, 2 deletions
diff --git a/templates/repo/diff/box.tmpl b/templates/repo/diff/box.tmpl
index 9b0738b1b7..15ba387dca 100644
--- a/templates/repo/diff/box.tmpl
+++ b/templates/repo/diff/box.tmpl
@@ -80,7 +80,7 @@
</div>
{{else}}
<div class="diff-file-box diff-box file-content {{TabSizeClass $.Editorconfig $file.Name}}" id="diff-{{.Index}}">
- <h4 class="ui top attached normal header">
+ <h4 class="diff-file-header ui top attached normal header">
{{$isImage := false}}
{{if $file.IsDeleted}}
{{$isImage = (call $.IsImageFileInBase $file.Name)}}
@@ -111,7 +111,7 @@
{{end}}
{{end}}
</h4>
- <div class="ui attached unstackable table segment">
+ <div class="diff-file-body ui attached unstackable table segment">
{{if ne $file.Type 4}}
<div class="file-body file-code code-view has-context-menu code-diff {{if $.IsSplitStyle}}code-diff-split{{else}}code-diff-unified{{end}}">
<table>