mirror of
https://github.com/go-gitea/gitea
synced 2024-12-22 14:14:11 +01:00
Fix localization texts that contain semicolon (#2900)
This commit is contained in:
parent
4725f91543
commit
134958fd9f
3 changed files with 7 additions and 3 deletions
|
@ -160,6 +160,10 @@ func NewFuncMap() []template.FuncMap {
|
|||
return setting.DisableGitHooks
|
||||
},
|
||||
"TrN": TrN,
|
||||
// TODO: Remove this once go-ini parser supports unescaping comment characters
|
||||
"UnescapeLocale": func(str string) string {
|
||||
return strings.NewReplacer("\\;", ";", "\\#", "#").Replace(str)
|
||||
},
|
||||
}}
|
||||
}
|
||||
|
||||
|
|
|
@ -627,8 +627,8 @@ issues.label_templates.info = There are not any labels yet. You can click on the
|
|||
issues.label_templates.helper = Select a label set
|
||||
issues.label_templates.use = Use this label set
|
||||
issues.label_templates.fail_to_load_file = Failed to load label template file '%s': %v
|
||||
issues.add_label_at = `added the <div class="ui label" style="color: %s; background-color: %s">%s</div> label %s`
|
||||
issues.remove_label_at = `removed the <div class="ui label" style="color: %s; background-color: %s">%s</div> label %s`
|
||||
issues.add_label_at = `added the <div class="ui label" style="color: %s\; background-color: %s">%s</div> label %s`
|
||||
issues.remove_label_at = `removed the <div class="ui label" style="color: %s\; background-color: %s">%s</div> label %s`
|
||||
issues.add_milestone_at = `added this to the <b>%s</b> milestone %s`
|
||||
issues.change_milestone_at = `modified the milestone from <b>%s</b> to <b>%s</b> %s`
|
||||
issues.remove_milestone_at = `removed this from the <b>%s</b> milestone %s`
|
||||
|
|
|
@ -96,7 +96,7 @@
|
|||
<img src="{{.Poster.RelAvatarLink}}">
|
||||
</a>
|
||||
<span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a>
|
||||
{{if .Content}}{{$.i18n.Tr "repo.issues.add_label_at" .Label.ForegroundColor .Label.Color .Label.Name $createdStr | Safe}}{{else}}{{$.i18n.Tr "repo.issues.remove_label_at" .Label.ForegroundColor .Label.Color .Label.Name $createdStr | Safe}}{{end}}</span>
|
||||
{{if .Content}}{{$.i18n.Tr "repo.issues.add_label_at" .Label.ForegroundColor .Label.Color .Label.Name $createdStr | UnescapeLocale | Safe}}{{else}}{{$.i18n.Tr "repo.issues.remove_label_at" .Label.ForegroundColor .Label.Color .Label.Name $createdStr | UnescapeLocale | Safe}}{{end}}</span>
|
||||
</div>
|
||||
{{end}}
|
||||
{{else if eq .Type 8}}
|
||||
|
|
Loading…
Reference in a new issue