Added localised strings.

Only override name when editing profile.
pull/61/head
Mikunj 7 years ago
parent f7e9af4e3a
commit 610a305e23

@ -1648,5 +1648,13 @@
"settingsUnblockHeader": { "settingsUnblockHeader": {
"message": "Blocked Users", "message": "Blocked Users",
"description": "Shown in the settings page as the heading for the blocked user settings" "description": "Shown in the settings page as the heading for the blocked user settings"
},
"editProfileTitle": {
"message": "Change your own display name",
"description": "The title shown when user edits their own profile"
},
"editProfileDisplayNameWarning": {
"message": "Note: Your display name will be visible to your contacts",
"description": "Shown to the user as a warning about setting display name"
} }
} }

@ -574,8 +574,8 @@
const displayName = profile && profile.name && profile.name.displayName; const displayName = profile && profile.name && profile.name.displayName;
if (appView) { if (appView) {
appView.showNicknameDialog({ appView.showNicknameDialog({
title: 'Change your own display name', title: window.i18n('editProfileTitle'),
message: 'Note: Your display name will be visible to your contacts.', message: window.i18n('editProfileDisplayNameWarning'),
nickname: displayName, nickname: displayName,
onOk: async (newName) => { onOk: async (newName) => {
// Update our profiles accordingly' // Update our profiles accordingly'
@ -585,6 +585,7 @@
await storage.removeLocalProfile(); await storage.removeLocalProfile();
} else { } else {
newProfile = { newProfile = {
...(profile || {}),
name: { name: {
displayName: trimmed, displayName: trimmed,
}, },

Loading…
Cancel
Save