Skip to content

Commit 291c868

Browse files
authored
Change join_on translation to joined_on and include placeholder for the date (#24550)
The correct thing to do is to translate the entire phrase into a single string. The previous translation assumed all languages have a space between the "joined on" and the date (and that "joined on" comes before the date). Some languages, like Hebrew, have no space between the "joined on" and the date. For example: ```ini joined_on=נרשם ב-%s ``` ("joined" becomes נרשם, "on" is ב and when paired with a date we use a dash to connect ב with the date)
1 parent e5a8ebc commit 291c868

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

options/locale/locale_en-US.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ target_branch_not_exist = Target branch does not exist.
559559

560560
[user]
561561
change_avatar = Change your avatar…
562-
join_on = Joined on
562+
joined_on = Joined on %s
563563
repositories = Repositories
564564
activity = Public Activity
565565
followers = Followers

templates/explore/organizations.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
{{svg "octicon-link"}}
2424
<a href="{{.Website}}" rel="nofollow">{{.Website}}</a>
2525
{{end}}
26-
{{svg "octicon-clock"}} {{$.locale.Tr "user.join_on"}} {{DateTime "short" .CreatedUnix}}
26+
{{svg "octicon-clock"}} {{$.locale.Tr "user.joined_on" (DateTime "short" .CreatedUnix) | Safe}}
2727
</div>
2828
</div>
2929
</div>

templates/explore/users.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
{{svg "octicon-mail"}}
1919
<a href="mailto:{{.Email}}" rel="nofollow">{{.Email}}</a>
2020
{{end}}
21-
{{svg "octicon-clock"}} {{$.locale.Tr "user.join_on"}} {{DateTime "short" .CreatedUnix}}
21+
{{svg "octicon-clock"}} {{$.locale.Tr "user.joined_on" (DateTime "short" .CreatedUnix) | Safe}}
2222
</div>
2323
</div>
2424
</div>

templates/repo/user_cards.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
{{else if .Location}}
1919
{{svg "octicon-location"}} {{.Location}}
2020
{{else}}
21-
{{svg "octicon-clock"}} {{$.locale.Tr "user.join_on"}} {{DateTime "short" .CreatedUnix}}
21+
{{svg "octicon-clock"}} {{$.locale.Tr "user.joined_on" (DateTime "short" .CreatedUnix) | Safe}}
2222
{{end}}
2323
</div>
2424
</li>

templates/user/profile.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
</li>
7474
{{end}}
7575
{{end}}
76-
<li>{{svg "octicon-clock"}} {{.locale.Tr "user.join_on"}} {{DateTime "short" .ContextUser.CreatedUnix}}</li>
76+
<li>{{svg "octicon-clock"}} {{.locale.Tr "user.joined_on" (DateTime "short" .ContextUser.CreatedUnix) | Safe}}</li>
7777
{{if and .Orgs .HasOrgsVisible}}
7878
<li>
7979
<ul class="user-orgs">

0 commit comments

Comments
 (0)