diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-10-11 10:27:00 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-10-11 10:27:00 +0000 |
commit | 65aa53fc52ff15efe54df4147564828d535837f8 (patch) | |
tree | 31c51dad04fdcca80e6d3043c8bd49d2f1a51f83 /templates/repo/shabox_badge.tmpl | |
parent | Initial commit. (diff) | |
download | forgejo-upstream.tar.xz forgejo-upstream.zip |
Adding upstream version 8.0.3.HEADupstream/8.0.3upstreamdebian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'templates/repo/shabox_badge.tmpl')
-rw-r--r-- | templates/repo/shabox_badge.tmpl | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/templates/repo/shabox_badge.tmpl b/templates/repo/shabox_badge.tmpl new file mode 100644 index 00000000..939292ba --- /dev/null +++ b/templates/repo/shabox_badge.tmpl @@ -0,0 +1,15 @@ +<div class="ui detail icon button"> + {{if .verification.Verified}} + <div title="{{if eq .verification.TrustStatus "trusted"}}{{else if eq .verification.TrustStatus "untrusted"}}{{ctx.Locale.Tr "repo.commits.signed_by_untrusted_user"}}: {{else}}{{ctx.Locale.Tr "repo.commits.signed_by_untrusted_user_unmatched"}}: {{end}}{{.verification.Reason}}"> + {{if ne .verification.SigningUser.ID 0}} + {{svg "gitea-lock"}} + {{ctx.AvatarUtils.Avatar .verification.SigningUser 28 "signature"}} + {{else}} + <span title="{{ctx.Locale.Tr "gpg.default_key"}}">{{svg "gitea-lock-cog"}}</span> + {{ctx.AvatarUtils.AvatarByEmail .verification.SigningEmail "" 28 "signature"}} + {{end}} + </div> + {{else}} + <span title="{{ctx.Locale.Tr .verification.Reason}}">{{svg "gitea-unlock"}}</span> + {{end}} +</div> |