1
1
mirror of https://github.com/go-gitea/gitea synced 2025-08-03 08:08:36 +00:00

Refactor i18n to locale (#20153)

* Refactor `i18n` to `locale`

- Currently we're using the `i18n` variable naming for the `locale`
struct. This contains locale's specific information and cannot be used
for general i18n purpose, therefore refactoring it to `locale` makes
more sense.
- Ref: https://github.com/go-gitea/gitea/pull/20096#discussion_r906699200

* Update routers/install/install.go
This commit is contained in:
Gusted
2022-06-27 22:58:46 +02:00
committed by GitHub
parent b551bc2a08
commit d55a0b7238
285 changed files with 3668 additions and 3668 deletions

View File

@@ -1,16 +1,16 @@
<h4 class="ui top attached header">
{{.i18n.Tr "settings.manage_openid"}}
{{.locale.Tr "settings.manage_openid"}}
</h4>
<div class="ui attached segment">
<div class="ui openid list">
<div class="item">
{{.i18n.Tr "settings.openid_desc"}}
{{.locale.Tr "settings.openid_desc"}}
</div>
{{range .OpenIDs}}
<div class="item">
<div class="right floated content">
<button class="ui red tiny button delete-button" data-modal-id="delete-openid" data-url="{{AppSubUrl}}/user/settings/security/openid/delete" data-id="{{.ID}}">
{{$.i18n.Tr "settings.delete_key"}}
{{$.locale.Tr "settings.delete_key"}}
</button>
</div>
<div class="right floated content">
@@ -20,12 +20,12 @@
{{if .Show}}
<button class="ui tiny button">
{{svg "octicon-eye" 16 "icon"}}
{{$.i18n.Tr "settings.hide_openid"}}
{{$.locale.Tr "settings.hide_openid"}}
</button>
{{else}}
<button class="ui tiny button">
{{svg "octicon-eye-closed" 16 "icon"}}
{{$.i18n.Tr "settings.show_openid"}}
{{$.locale.Tr "settings.show_openid"}}
</button>
{{end}}
</button>
@@ -42,11 +42,11 @@
<form class="ui form" action="{{AppSubUrl}}/user/settings/security/openid" method="post">
{{.CsrfTokenHtml}}
<div class="required field {{if .Err_OpenID}}error{{end}}">
<label for="openid">{{.i18n.Tr "settings.add_new_openid"}}</label>
<label for="openid">{{.locale.Tr "settings.add_new_openid"}}</label>
<input id="openid" name="openid" type="text" required>
</div>
<button class="ui green button">
{{.i18n.Tr "settings.add_openid"}}
{{.locale.Tr "settings.add_openid"}}
</button>
</form>
</div>
@@ -54,10 +54,10 @@
<div class="ui small basic delete modal" id="delete-openid">
<div class="ui icon header">
{{svg "octicon-trash"}}
{{.i18n.Tr "settings.openid_deletion"}}
{{.locale.Tr "settings.openid_deletion"}}
</div>
<div class="content">
<p>{{.i18n.Tr "settings.openid_deletion_desc"}}</p>
<p>{{.locale.Tr "settings.openid_deletion_desc"}}</p>
</div>
{{template "base/delete_modal_actions" .}}
</div>