-
References: {{.Issue.ReferenceLink}}
-
- {{svg "octicon-copy"}}
-
+
+
+ {{.i18n.Tr "repo.issues.reference_link" .Issue.ReferenceLink}}
+
diff --git a/web_src/less/_repository.less b/web_src/less/_repository.less
index cbc295f445f2d..13f9384ba0635 100644
--- a/web_src/less/_repository.less
+++ b/web_src/less/_repository.less
@@ -1201,19 +1201,6 @@
}
}
}
-
- .ui.reference {
- .text {
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- padding-right: 1rem;
- }
-
- .copy-button {
- cursor: pointer;
- }
- }
}
.comment.form {
From fd138927ef36c5f23b450563089eda61b7f90a1d Mon Sep 17 00:00:00 2001
From: neonn <78957398+neonn@users.noreply.github.com>
Date: Thu, 5 May 2022 00:45:02 +0100
Subject: [PATCH 4/7] Added i18 translation key for reference link string
---
options/locale/locale_en-US.ini | 1 +
1 file changed, 1 insertion(+)
diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini
index 0175c8bfc8b00..3fd4d5cd7ce86 100644
--- a/options/locale/locale_en-US.ini
+++ b/options/locale/locale_en-US.ini
@@ -1480,6 +1480,7 @@ issues.content_history.created = created
issues.content_history.delete_from_history = Delete from history
issues.content_history.delete_from_history_confirm = Delete from history?
issues.content_history.options = Options
+issues.reference_link = References: %s
compare.compare_base = base
compare.compare_head = compare
From f2aee4e565f2f074be1322a5ee20b468eb8584ec Mon Sep 17 00:00:00 2001
From: neonn <78957398+neonn@users.noreply.github.com>
Date: Thu, 5 May 2022 19:19:25 +0100
Subject: [PATCH 5/7] Corrected spelling of "References:" to "Reference:" for
reference link text
---
options/locale/locale_en-US.ini | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini
index 3fd4d5cd7ce86..c040386ca70c4 100644
--- a/options/locale/locale_en-US.ini
+++ b/options/locale/locale_en-US.ini
@@ -1480,7 +1480,7 @@ issues.content_history.created = created
issues.content_history.delete_from_history = Delete from history
issues.content_history.delete_from_history_confirm = Delete from history?
issues.content_history.options = Options
-issues.reference_link = References: %s
+issues.reference_link = Reference: %s
compare.compare_base = base
compare.compare_head = compare
From c3f7c4c0467e4f29d447128a5983c14963955afa Mon Sep 17 00:00:00 2001
From: neonn <78957398+neonn@users.noreply.github.com>
Date: Thu, 5 May 2022 19:23:56 +0100
Subject: [PATCH 6/7] Removed `Issue.ReferenceLink` in favour of a local
template variable
---
models/issue.go | 4 ----
templates/repo/issue/view_content/sidebar.tmpl | 5 +++--
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/models/issue.go b/models/issue.go
index 5d019a6927221..98e64adafd226 100644
--- a/models/issue.go
+++ b/models/issue.go
@@ -430,10 +430,6 @@ func (issue *Issue) PatchURL() string {
return ""
}
-func (issue *Issue) ReferenceLink() string {
- return fmt.Sprintf("%s#%d", issue.Repo.FullName(), issue.Index)
-}
-
// State returns string representation of issue status.
func (issue *Issue) State() api.StateType {
if issue.IsClosed {
diff --git a/templates/repo/issue/view_content/sidebar.tmpl b/templates/repo/issue/view_content/sidebar.tmpl
index 834ea810ad0e2..ffc46bfedee75 100644
--- a/templates/repo/issue/view_content/sidebar.tmpl
+++ b/templates/repo/issue/view_content/sidebar.tmpl
@@ -571,8 +571,9 @@
- {{.i18n.Tr "repo.issues.reference_link" .Issue.ReferenceLink}}
-
+ {{$issueReferenceLink := printf "%s#%d" .Issue.Repo.FullName .Issue.Index}}
+ {{.i18n.Tr "repo.issues.reference_link" $issueReferenceLink}}
+
From 13a6282fc717ba1093050597584a8f8c353154d3 Mon Sep 17 00:00:00 2001
From: neonn <78957398+neonn@users.noreply.github.com>
Date: Fri, 9 Sep 2022 18:20:27 +0100
Subject: [PATCH 7/7] Corrected layout of WebAuthN page to center-align content
---
templates/user/auth/webauthn.tmpl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/templates/user/auth/webauthn.tmpl b/templates/user/auth/webauthn.tmpl
index 8e82c12fc03bb..304d199da21aa 100644
--- a/templates/user/auth/webauthn.tmpl
+++ b/templates/user/auth/webauthn.tmpl
@@ -1,7 +1,7 @@
{{template "base/head" .}}