[bugfix/frontend] web/template/page_header.tmpl: use singular verb if necessary (#4600)
# Description If there's just one user, say "who has written x posts", otherwise say "who have written x posts". ## Checklist Please put an x inside each checkbox to indicate that you've read and followed it: `[ ]` -> `[x]` If this is a documentation change, only the first two checkboxes must be filled (you can delete the others if you want). - [x] I/we have read the [GoToSocial contribution guidelines](https://codeberg.org/superseriousbusiness/gotosocial/src/branch/main/CONTRIBUTING.md). - [x] I/we have not used so-called 'AI' to create the proposed changes. - [ ] I/we have discussed the proposed changes already, either in an issue on the repository, or in the Matrix chat. - [x] I/we have performed a self-review of added code. - [x] I/we have written code that is legible and maintainable by others. - [ ] I/we have commented the added code, particularly in hard-to-understand areas. - [ ] I/we have made any necessary changes to documentation. - [ ] I/we have added tests that cover new code. - [ ] I/we have run tests and they pass locally with the changes. - [ ] I/we have run `go fmt ./...` and `golangci-lint run`. Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4600 Co-authored-by: Roberto Ricci <io@r-ricci.it> Co-committed-by: Roberto Ricci <io@r-ricci.it>
This commit is contained in:
@@ -52,9 +52,9 @@ Instance Logo
|
||||
{{- define "strapUsers" -}}
|
||||
{{- with deref .instance.Stats.user_count -}}
|
||||
{{- if eq . 1 -}}
|
||||
<span class="count">{{- . -}}</span> user
|
||||
<span class="count">{{- . -}}</span> user who has written
|
||||
{{- else -}}
|
||||
<span class="count">{{- . -}}</span> users
|
||||
<span class="count">{{- . -}}</span> users who have written
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -101,6 +101,6 @@ Instance Logo
|
||||
<h1>{{- .instance.Title -}}</h1>
|
||||
</a>
|
||||
{{- if .showStrap }}
|
||||
<aside>home to {{ template "strapUsers" . }} who have written {{ template "strapPosts" . }}; knows of {{ template "strapInstances" . }}</aside>
|
||||
<aside>home to {{ template "strapUsers" . }} {{ template "strapPosts" . }}; knows of {{ template "strapInstances" . }}</aside>
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
Reference in New Issue
Block a user