aboutsummaryrefslogtreecommitdiffstats
path: root/src/components
diff options
context:
space:
mode:
Diffstat (limited to 'src/components')
-rw-r--r--src/components/layout/Sidebar.js36
-rw-r--r--src/components/settings/navigation/SettingsNavigation.js21
-rw-r--r--src/components/settings/settings/EditSettingsForm.js16
3 files changed, 30 insertions, 43 deletions
diff --git a/src/components/layout/Sidebar.js b/src/components/layout/Sidebar.js
index 2bae57648..18492be80 100644
--- a/src/components/layout/Sidebar.js
+++ b/src/components/layout/Sidebar.js
@@ -14,7 +14,6 @@ import {
14 addNewServiceShortcutKey, 14 addNewServiceShortcutKey,
15 muteFerdiShortcutKey, 15 muteFerdiShortcutKey,
16} from '../../environment'; 16} from '../../environment';
17import { workspaceStore } from '../../features/workspaces';
18import { todosStore } from '../../features/todos'; 17import { todosStore } from '../../features/todos';
19import { todoActions } from '../../features/todos/actions'; 18import { todoActions } from '../../features/todos/actions';
20import AppStore from '../../stores/AppStore'; 19import AppStore from '../../stores/AppStore';
@@ -160,8 +159,7 @@ class Sidebar extends Component {
160 <i className="mdi mdi-lock" /> 159 <i className="mdi mdi-lock" />
161 </button> 160 </button>
162 ) : null} 161 ) : null}
163 {todosStore.isFeatureEnabled && 162 {todosStore.isFeatureEnabledByUser ? (
164 todosStore.isFeatureEnabledByUser ? (
165 <button 163 <button
166 type="button" 164 type="button"
167 onClick={() => { 165 onClick={() => {
@@ -179,23 +177,21 @@ class Sidebar extends Component {
179 <i className="mdi mdi-check-all" /> 177 <i className="mdi mdi-check-all" />
180 </button> 178 </button>
181 ) : null} 179 ) : null}
182 {workspaceStore.isFeatureEnabled ? ( 180 <button
183 <button 181 type="button"
184 type="button" 182 onClick={() => {
185 onClick={() => { 183 toggleWorkspaceDrawer();
186 toggleWorkspaceDrawer(); 184 this.updateToolTip();
187 this.updateToolTip(); 185 }}
188 }} 186 className={`sidebar__button sidebar__button--workspaces ${
189 className={`sidebar__button sidebar__button--workspaces ${ 187 isWorkspaceDrawerOpen ? 'is-active' : ''
190 isWorkspaceDrawerOpen ? 'is-active' : '' 188 }`}
191 }`} 189 data-tip={`${intl.formatMessage(
192 data-tip={`${intl.formatMessage( 190 workspaceToggleMessage,
193 workspaceToggleMessage, 191 )} (${workspaceToggleShortcutKey(false)})`}
194 )} (${workspaceToggleShortcutKey(false)})`} 192 >
195 > 193 <i className="mdi mdi-view-grid" />
196 <i className="mdi mdi-view-grid" /> 194 </button>
197 </button>
198 ) : null}
199 <button 195 <button
200 type="button" 196 type="button"
201 onClick={() => { 197 onClick={() => {
diff --git a/src/components/settings/navigation/SettingsNavigation.js b/src/components/settings/navigation/SettingsNavigation.js
index 18a71fdeb..dbb1365b0 100644
--- a/src/components/settings/navigation/SettingsNavigation.js
+++ b/src/components/settings/navigation/SettingsNavigation.js
@@ -6,7 +6,6 @@ import { RouterStore } from 'mobx-react-router';
6 6
7import { LOCAL_SERVER, LIVE_FERDI_API, LIVE_FRANZ_API } from '../../../config'; 7import { LOCAL_SERVER, LIVE_FERDI_API, LIVE_FRANZ_API } from '../../../config';
8import Link from '../../ui/Link'; 8import Link from '../../ui/Link';
9import { workspaceStore } from '../../../features/workspaces';
10import UIStore from '../../../stores/UIStore'; 9import UIStore from '../../../stores/UIStore';
11import SettingsStore from '../../../stores/SettingsStore'; 10import SettingsStore from '../../../stores/SettingsStore';
12import UserStore from '../../../stores/UserStore'; 11import UserStore from '../../../stores/UserStore';
@@ -117,17 +116,15 @@ class SettingsNavigation extends Component {
117 {intl.formatMessage(messages.yourServices)}{' '} 116 {intl.formatMessage(messages.yourServices)}{' '}
118 <span className="badge">{serviceCount}</span> 117 <span className="badge">{serviceCount}</span>
119 </Link> 118 </Link>
120 {workspaceStore.isFeatureEnabled ? ( 119 <Link
121 <Link 120 to="/settings/workspaces"
122 to="/settings/workspaces" 121 className="settings-navigation__link"
123 className="settings-navigation__link" 122 activeClassName="is-active"
124 activeClassName="is-active" 123 disabled={!isLoggedIn}
125 disabled={!isLoggedIn} 124 >
126 > 125 {intl.formatMessage(messages.yourWorkspaces)}{' '}
127 {intl.formatMessage(messages.yourWorkspaces)}{' '} 126 <span className="badge">{workspaceCount}</span>
128 <span className="badge">{workspaceCount}</span> 127 </Link>
129 </Link>
130 ) : null}
131 {!isUsingWithoutAccount && ( 128 {!isUsingWithoutAccount && (
132 <Link 129 <Link
133 to="/settings/user" 130 to="/settings/user"
diff --git a/src/components/settings/settings/EditSettingsForm.js b/src/components/settings/settings/EditSettingsForm.js
index 60bd91493..54f2025e5 100644
--- a/src/components/settings/settings/EditSettingsForm.js
+++ b/src/components/settings/settings/EditSettingsForm.js
@@ -194,9 +194,7 @@ class EditSettingsForm extends Component {
194 isClearingAllCache: PropTypes.bool.isRequired, 194 isClearingAllCache: PropTypes.bool.isRequired,
195 onClearAllCache: PropTypes.func.isRequired, 195 onClearAllCache: PropTypes.func.isRequired,
196 getCacheSize: PropTypes.func.isRequired, 196 getCacheSize: PropTypes.func.isRequired,
197 isTodosEnabled: PropTypes.bool.isRequired,
198 isTodosActivated: PropTypes.bool.isRequired, 197 isTodosActivated: PropTypes.bool.isRequired,
199 isWorkspaceEnabled: PropTypes.bool.isRequired,
200 automaticUpdates: PropTypes.bool.isRequired, 198 automaticUpdates: PropTypes.bool.isRequired,
201 isDarkmodeEnabled: PropTypes.bool.isRequired, 199 isDarkmodeEnabled: PropTypes.bool.isRequired,
202 isAdaptableDarkModeEnabled: PropTypes.bool.isRequired, 200 isAdaptableDarkModeEnabled: PropTypes.bool.isRequired,
@@ -244,8 +242,6 @@ class EditSettingsForm extends Component {
244 isClearingAllCache, 242 isClearingAllCache,
245 onClearAllCache, 243 onClearAllCache,
246 getCacheSize, 244 getCacheSize,
247 isTodosEnabled,
248 isWorkspaceEnabled,
249 automaticUpdates, 245 automaticUpdates,
250 isDarkmodeEnabled, 246 isDarkmodeEnabled,
251 isTodosActivated, 247 isTodosActivated,
@@ -414,14 +410,12 @@ class EditSettingsForm extends Component {
414 410
415 <Hr /> 411 <Hr />
416 412
417 {isWorkspaceEnabled && ( 413 <>
418 <> 414 <Toggle field={form.$('keepAllWorkspacesLoaded')} />
419 <Toggle field={form.$('keepAllWorkspacesLoaded')} /> 415 <Hr />
420 <Hr /> 416 </>
421 </>
422 )}
423 417
424 {isTodosEnabled && !hasAddedTodosAsService && ( 418 {!hasAddedTodosAsService && (
425 <> 419 <>
426 <Toggle field={form.$('enableTodos')} /> 420 <Toggle field={form.$('enableTodos')} />
427 {isTodosActivated && ( 421 {isTodosActivated && (