summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2023-03-17 02:25:04 +0800
committerGitHub <noreply@github.com>2023-03-16 14:25:04 -0400
commit6bad0fb24f0a2549da42d3d143be9f355712e8b3 (patch)
tree4d34b57b03336922608265f6c03a032db4f16b4b /templates
parent574d8fe6d6675c8aa05e2b75fdbc01c009efd8be (diff)
downloadgitea-6bad0fb24f0a2549da42d3d143be9f355712e8b3.tar.gz
gitea-6bad0fb24f0a2549da42d3d143be9f355712e8b3.zip
Fix review comment context menu clipped bug (#23523)
This is another regression of #22959 (the first regression has been fixed by the Image Diff fix) Close #23517 This is a quick fix. Luckily, there is no "dropdown menu" for image/csv view, so we could only add the "overflow-x: scroll" to the image/csv view. After fix: ![image](https://user-images.githubusercontent.com/2114189/225643575-9e964b4f-5543-4a69-86c2-2ffc8e40d9a6.png) ![image](https://user-images.githubusercontent.com/2114189/225643670-f0e575d0-f4af-41f4-b023-2d9ddb6462e9.png) Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/diff/box.tmpl3
1 files changed, 2 insertions, 1 deletions
diff --git a/templates/repo/diff/box.tmpl b/templates/repo/diff/box.tmpl
index e0c58896f0..e04c27b5e9 100644
--- a/templates/repo/diff/box.tmpl
+++ b/templates/repo/diff/box.tmpl
@@ -161,7 +161,8 @@
{{end}}
</div>
{{if $showFileViewToggle}}
- <div id="diff-rendered-{{$file.NameHash}}" class="file-body file-code {{if $.IsSplitStyle}} code-diff-split{{else}} code-diff-unified{{end}}">
+ {{/* for image or CSV, it can have a horizontal scroll bar, there won't be review comment context menu (position absolute) which would be clipped by "overflow" */}}
+ <div id="diff-rendered-{{$file.NameHash}}" class="file-body file-code {{if $.IsSplitStyle}}code-diff-split{{else}}code-diff-unified{{end}} gt-overflow-x-scroll">
<table class="chroma gt-w-100">
{{if $isImage}}
{{template "repo/diff/image_diff" dict "file" . "root" $ "blobBase" $blobBase "blobHead" $blobHead}}