diff --git a/_locales/en/messages.json b/_locales/en/messages.json index 521a8e0a0..6ebf58fab 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -2110,6 +2110,14 @@ "message": "Leave Group", "description": "Button action that the user can click to leave the group" }, + "leaveOpenGroup": { + "message": "Leave Open Group", + "description": "Button action that the user can click to leave the group" + }, + "leaveClosedGroup": { + "message": "Leave Closed Group", + "description": "Button action that the user can click to leave the group" + }, "leaveGroupDialogTitle": { "message": "Are you sure you want to leave this group?", "description": @@ -2226,7 +2234,7 @@ "message": "Server URL", "description": "Placeholder for server URL input" }, - "noServerUrl": { + "noServerURL": { "message": "Please enter a server URL", "description": "Error message when no server url entered" }, diff --git a/js/views/app_view.js b/js/views/app_view.js index 5a861aafd..b61b9f659 100644 --- a/js/views/app_view.js +++ b/js/views/app_view.js @@ -224,7 +224,7 @@ }, showCreateGroup() { // TODO: make it impossible to open 2 dialogs as once - // Curretnly, if the button is in focus, it is possible to + // Currently, if the button is in focus, it is possible to // create a new dialog by pressing 'Enter' const dialog = new Whisper.CreateGroupDialogView(); this.el.append(dialog.el); diff --git a/ts/components/session/SessionChannelSettings.tsx b/ts/components/session/SessionChannelSettings.tsx index b625cbea7..7b89edc65 100644 --- a/ts/components/session/SessionChannelSettings.tsx +++ b/ts/components/session/SessionChannelSettings.tsx @@ -17,6 +17,7 @@ interface Props { description: string; avatarPath: string; timerOptions: Array; + isPublic: boolean; onGoBack: () => void; onInviteFriends: () => void; @@ -183,9 +184,10 @@ export class SessionChannelSettings extends React.Component { } public render() { - const { memberCount, name, onLeaveGroup } = this.props; + const { memberCount, name, onLeaveGroup, isPublic } = this.props; const { documents, media, onItemClick } = this.state; const showMemberCount = !!(memberCount && memberCount > 0); + const leaveGroupString = isPublic ? window.i18n('leaveOpenGroup') : window.i18n('leaveClosedGroup'); return (
@@ -213,7 +215,7 @@ export class SessionChannelSettings extends React.Component { onItemClick={onItemClick} />