Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing translations in the users panel #6082

Merged
merged 7 commits into from
Jun 2, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 6 additions & 7 deletions src/panels/config/users/dialog-add-user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ export class DialogAddUser extends LitElement {
required
auto-validate
autocapitalize="on"
error-message="Required"
.errorMessage=${this.hass.localize("ui.common.error_required")}
@value-changed=${this._nameChanged}
@blur=${this._maybePopulateUsername}
></paper-input>
Expand All @@ -99,7 +99,7 @@ export class DialogAddUser extends LitElement {
auto-validate
autocapitalize="none"
@value-changed=${this._usernameChanged}
error-message="Required"
.errorMessage=${this.hass.localize("ui.common.error_required")}
></paper-input>
<paper-input
.label=${this.hass.localize(
Expand All @@ -110,18 +110,17 @@ export class DialogAddUser extends LitElement {
required
auto-validate
@value-changed=${this._passwordChanged}
error-message="Required"
.errorMessage=${this.hass.localize("ui.common.error_required")}
></paper-input>
<ha-switch .checked=${this._isAdmin} @change=${this._adminChanged}>
${this.hass.localize("ui.panel.config.users.editor.admin")}
</ha-switch>
${!this._isAdmin
? html`
<br />
The users group is a work in progress. The user will be unable
to administer the instance via the UI. We're still auditing all
management API endpoints to ensure that they correctly limit
access to administrators.
${this.hass.localize(
"ui.panel.config.users.users_privileges_note"
)}
`
: ""}
</div>
Expand Down
7 changes: 3 additions & 4 deletions src/panels/config/users/dialog-user-detail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,9 @@ class DialogUserDetail extends LitElement {
${!this._isAdmin
? html`
<br />
The users group is a work in progress. The user will be unable
to administer the instance via the UI. We're still auditing
all management API endpoints to ensure that they correctly
limit access to administrators.
${this.hass.localize(
"ui.panel.config.users.users_privileges_note"
)}
`
: ""}
</div>
Expand Down
4 changes: 3 additions & 1 deletion src/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,8 @@
"no": "No",
"successfully_saved": "Successfully saved",
"successfully_deleted": "Successfully deleted",
"back": "Back"
"back": "Back",
"error_required": "Required"
},
"components": {
"entity": {
Expand Down Expand Up @@ -1430,6 +1431,7 @@
"users": {
"caption": "Users",
"description": "Manage users",
"users_privileges_note": "The users group is a work in progress. The user will be unable to administer the instance via the UI. We're still auditing all management API endpoints to ensure that they correctly limit access to administrators.",
"picker": {
"headers": { "name": "Name", "group": "Group", "system": "System" }
},
Expand Down