diff options
Diffstat (limited to 'src/components/settings')
-rw-r--r-- | src/components/settings/navigation/SettingsNavigation.js | 5 | ||||
-rw-r--r-- | src/components/settings/settings/EditSettingsForm.js | 7 |
2 files changed, 10 insertions, 2 deletions
diff --git a/src/components/settings/navigation/SettingsNavigation.js b/src/components/settings/navigation/SettingsNavigation.js index df4b3b3b2..e1c5cabc3 100644 --- a/src/components/settings/navigation/SettingsNavigation.js +++ b/src/components/settings/navigation/SettingsNavigation.js | |||
@@ -63,6 +63,7 @@ export default @inject('stores') @observer class SettingsNavigation extends Comp | |||
63 | const { isDarkThemeActive } = stores.ui; | 63 | const { isDarkThemeActive } = stores.ui; |
64 | const { router, user } = stores; | 64 | const { router, user } = stores; |
65 | const { intl } = this.context; | 65 | const { intl } = this.context; |
66 | const isLoggedIn = Boolean(localStorage.getItem('authToken')); | ||
66 | 67 | ||
67 | return ( | 68 | return ( |
68 | <div className="settings-navigation"> | 69 | <div className="settings-navigation"> |
@@ -130,10 +131,10 @@ export default @inject('stores') @observer class SettingsNavigation extends Comp | |||
130 | </Link> | 131 | </Link> |
131 | <span className="settings-navigation__expander" /> | 132 | <span className="settings-navigation__expander" /> |
132 | <Link | 133 | <Link |
133 | to="/auth/logout" | 134 | to={ isLoggedIn ? "/auth/logout" : '/auth/welcome'} |
134 | className="settings-navigation__link" | 135 | className="settings-navigation__link" |
135 | > | 136 | > |
136 | {intl.formatMessage(messages.logout)} | 137 | { isLoggedIn ? intl.formatMessage(messages.logout) : 'Login'} |
137 | </Link> | 138 | </Link> |
138 | </div> | 139 | </div> |
139 | ); | 140 | ); |
diff --git a/src/components/settings/settings/EditSettingsForm.js b/src/components/settings/settings/EditSettingsForm.js index ab93188cf..de324b115 100644 --- a/src/components/settings/settings/EditSettingsForm.js +++ b/src/components/settings/settings/EditSettingsForm.js | |||
@@ -9,6 +9,7 @@ import Button from '../../ui/Button'; | |||
9 | import Toggle from '../../ui/Toggle'; | 9 | import Toggle from '../../ui/Toggle'; |
10 | import Select from '../../ui/Select'; | 10 | import Select from '../../ui/Select'; |
11 | import PremiumFeatureContainer from '../../ui/PremiumFeatureContainer'; | 11 | import PremiumFeatureContainer from '../../ui/PremiumFeatureContainer'; |
12 | import Input from '../../ui/Input'; | ||
12 | 13 | ||
13 | import { FRANZ_TRANSLATION } from '../../../config'; | 14 | import { FRANZ_TRANSLATION } from '../../../config'; |
14 | 15 | ||
@@ -162,6 +163,12 @@ export default @observer class EditSettingsForm extends Component { | |||
162 | {process.platform === 'win32' && ( | 163 | {process.platform === 'win32' && ( |
163 | <Toggle field={form.$('minimizeToSystemTray')} /> | 164 | <Toggle field={form.$('minimizeToSystemTray')} /> |
164 | )} | 165 | )} |
166 | <Input | ||
167 | placeholder="Server" | ||
168 | onChange={e => this.submit(e)} | ||
169 | field={form.$('server')} | ||
170 | autoFocus | ||
171 | /> | ||
165 | 172 | ||
166 | {/* Appearance */} | 173 | {/* Appearance */} |
167 | <h2 id="apperance">{intl.formatMessage(messages.headlineAppearance)}</h2> | 174 | <h2 id="apperance">{intl.formatMessage(messages.headlineAppearance)}</h2> |