diff --git a/routers/web/repo/issue_watch.go b/routers/web/repo/issue_watch.go
index dfa3491786e..19d723c0eae 100644
--- a/routers/web/repo/issue_watch.go
+++ b/routers/web/repo/issue_watch.go
@@ -5,7 +5,6 @@ package repo
import (
"net/http"
- "strconv"
issues_model "code.gitea.io/gitea/models/issues"
"code.gitea.io/gitea/modules/log"
@@ -46,12 +45,7 @@ func IssueWatch(ctx *context.Context) {
return
}
- watch, err := strconv.ParseBool(ctx.Req.PostFormValue("watch"))
- if err != nil {
- ctx.ServerError("watch is not bool", err)
- return
- }
-
+ watch := ctx.FormBool("watch")
if err := issues_model.CreateOrUpdateIssueWatch(ctx, ctx.Doer.ID, issue.ID, watch); err != nil {
ctx.ServerError("CreateOrUpdateIssueWatch", err)
return
diff --git a/services/gitdiff/gitdiff.go b/services/gitdiff/gitdiff.go
index 6bc339bc61e..5c85b50d337 100644
--- a/services/gitdiff/gitdiff.go
+++ b/services/gitdiff/gitdiff.go
@@ -228,7 +228,7 @@ func (d *DiffLine) RenderBlobExcerptButtons(fileNameHash string, data *DiffBlobE
link += fmt.Sprintf("&pull_issue_index=%d", data.PullIssueIndex)
}
return htmlutil.HTMLFormat(
- ``,
+ ``,
link, dataHiddenCommentIDs, svg.RenderHTML(svgName),
)
}
diff --git a/templates/base/head.tmpl b/templates/base/head.tmpl
index 90f6b7546e5..9b29ab3843a 100644
--- a/templates/base/head.tmpl
+++ b/templates/base/head.tmpl
@@ -23,7 +23,7 @@
{{template "base/head_script" .}}
{{template "custom/header" .}}
-
+
{{template "custom/body_outer_pre" .}}
diff --git a/templates/org/follow_unfollow.tmpl b/templates/org/follow_unfollow.tmpl
index ba0bd01efe4..77977c12794 100644
--- a/templates/org/follow_unfollow.tmpl
+++ b/templates/org/follow_unfollow.tmpl
@@ -1,4 +1,4 @@
-
diff --git a/templates/repo/issue/view_content/watching.tmpl b/templates/repo/issue/view_content/watching.tmpl
index 1abc92742ad..1fdf93b9ee2 100644
--- a/templates/repo/issue/view_content/watching.tmpl
+++ b/templates/repo/issue/view_content/watching.tmpl
@@ -1,12 +1,7 @@
-
+
+ {{if $.IssueWatch.IsWatching}}
+ {{svg "octicon-mute" 16}} {{ctx.Locale.Tr "repo.issues.unsubscribe"}}
+ {{else}}
+ {{svg "octicon-unmute" 16}} {{ctx.Locale.Tr "repo.issues.subscribe"}}
+ {{end}}
+
diff --git a/templates/shared/user/profile_big_avatar.tmpl b/templates/shared/user/profile_big_avatar.tmpl
index 41bcdaccb0d..b70013c7f0e 100644
--- a/templates/shared/user/profile_big_avatar.tmpl
+++ b/templates/shared/user/profile_big_avatar.tmpl
@@ -115,16 +115,19 @@
{{end}}
{{if and .IsSigned (ne .SignedUserID .ContextUser.ID)}}
{{if not .UserBlocking}}
-
- {{if $.IsFollowing}}
-
+
+ {{$buttonExtraClass := Iif $.IsFollowing "" "primary"}}
+ {{$followAction := Iif $.IsFollowing "unfollow" "follow"}}
+
- {{else}}
-
+ {{else}}
{{svg "octicon-person"}} {{ctx.Locale.Tr "user.follow"}}
-
- {{end}}
+ {{end}}
+
{{end}}
diff --git a/templates/user/notification/notification_div.tmpl b/templates/user/notification/notification_div.tmpl
index 993975169b5..8a28f8dc620 100644
--- a/templates/user/notification/notification_div.tmpl
+++ b/templates/user/notification/notification_div.tmpl
@@ -53,8 +53,8 @@
{{DateUtils.TimeSince $one.UpdatedUnix}}
{{end}}
-