aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorvelengel <kounakadora528@gmail.com>2021-11-23 11:44:10 +0900
committerGitHub <noreply@github.com>2021-11-22 21:44:10 -0500
commita1f5c7bfce6af221930df8c417057ca7946c810e (patch)
tree6768bd8a37b4d7b3b5aa676037106aed70199422 /templates
parentb2daa7e2032fdb015bc2990e22082c46f4e08d63 (diff)
downloadgitea-a1f5c7bfce6af221930df8c417057ca7946c810e.tar.gz
gitea-a1f5c7bfce6af221930df8c417057ca7946c810e.zip
Add copy Commit ID button in commits list (#17759)
* fix: implement commit id copy to clipboard * fix: remove abundant attributes / consider edge-case * fix: locale_en fixed * fix: use ui button * tune copy button * fix: button size * Fix merge Co-authored-by: Ysmr-Ry <ryo.yossy@live.jp> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/commits_list.tmpl3
1 files changed, 2 insertions, 1 deletions
diff --git a/templates/repo/commits_list.tmpl b/templates/repo/commits_list.tmpl
index 3a98a3afb2..e270a99972 100644
--- a/templates/repo/commits_list.tmpl
+++ b/templates/repo/commits_list.tmpl
@@ -23,7 +23,8 @@
{{$userName}}
{{end}}
</td>
- <td class="sha">
+ <td class="sha df">
+ <button class="ui button copy-commit-sha df ac" data-clipboard-text="{{.ID}}">{{svg "octicon-copy" 14}}</button>
{{$class := "ui sha label"}}
{{if .Signature}}
{{$class = (printf "%s%s" $class " isSigned")}}