From cddba671ccd00a4386a90d4d769ed50b9780921b Mon Sep 17 00:00:00 2001
From: yp05327 <576951401@qq.com>
Date: Mon, 21 Aug 2023 06:39:58 +0000
Subject: [PATCH 1/4] improve
---
templates/repo/issue/view_content.tmpl | 13 +----
.../repo/issue/view_content/comments.tmpl | 56 +++----------------
.../repo/issue/view_content/show_role.tmpl | 15 +++++
3 files changed, 23 insertions(+), 61 deletions(-)
create mode 100644 templates/repo/issue/view_content/show_role.tmpl
diff --git a/templates/repo/issue/view_content.tmpl b/templates/repo/issue/view_content.tmpl
index f6572d49653a4..69760ac0703db 100644
--- a/templates/repo/issue/view_content.tmpl
+++ b/templates/repo/issue/view_content.tmpl
@@ -44,18 +44,7 @@
{{end}}
@@ -567,21 +539,7 @@
{{end}}
{{if (.ShowRole.HasRole "Writer")}}
-
- {{.locale.Tr "repo.issues.collaborator"}}
-
+
+ {{.locale.Tr "repo.issues.collaborator"}}
+
{{end}}
{{if (.ShowRole.HasRole "Owner")}}
From f30e182d151821cf0ead0ab6eaf7bae3e174ca5c Mon Sep 17 00:00:00 2001
From: yp05327 <576951401@qq.com>
Date: Tue, 22 Aug 2023 00:10:25 +0000
Subject: [PATCH 3/4] use ctx.Locale
---
templates/repo/issue/view_content.tmpl | 2 +-
templates/repo/issue/view_content/comments.tmpl | 6 +++---
templates/repo/issue/view_content/show_role.tmpl | 6 +++---
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/templates/repo/issue/view_content.tmpl b/templates/repo/issue/view_content.tmpl
index 69760ac0703db..78587ac7b6e2a 100644
--- a/templates/repo/issue/view_content.tmpl
+++ b/templates/repo/issue/view_content.tmpl
@@ -44,7 +44,7 @@
{{end}}