diff options
author | Amine <amine@mouafik.fr> | 2020-03-31 14:09:05 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-31 14:09:05 +0100 |
commit | 899d2bf551e111bdc68608dba02e93782eec9f85 (patch) | |
tree | 2ead7fcc3a8f08d74af186931267e9021d21812e /src/components | |
parent | Retry flaky commands on AppVeyor (#526) (diff) | |
download | ferdium-app-899d2bf551e111bdc68608dba02e93782eec9f85.tar.gz ferdium-app-899d2bf551e111bdc68608dba02e93782eec9f85.tar.zst ferdium-app-899d2bf551e111bdc68608dba02e93782eec9f85.zip |
* add condition if on todo options
* add drop down for todo server
* fix error TODOS_FRONTEND
* add todo list apps'
* update name of dropdown menu to Todo Service
* add other service to dropdown menu and subsetting field for user to input url
* add Other Service to drop down
* fixed typos
* reverted wording
* fix custom field
* fix linting
* fix linting
* Delete tsconfig.tsbuildinfo
* Delete tsconfig.tsbuildinfo
* Delete tsconfig.tsbuildinfo
* Add regex to validate custom todo url
* Add note with source of regex function
* Move regex function declaration to function body root
* Apply code style
* Add migration for todo settings
* Apply code style
Co-authored-by: romain <romain@jumboprivacy.com>
Co-authored-by: Roman <46404814+yourcontact@users.noreply.github.com>
Co-authored-by: romain <rpsa@pm.me>
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/settings/settings/EditSettingsForm.js | 38 |
1 files changed, 25 insertions, 13 deletions
diff --git a/src/components/settings/settings/EditSettingsForm.js b/src/components/settings/settings/EditSettingsForm.js index 5478ce8bf..f76378a3e 100644 --- a/src/components/settings/settings/EditSettingsForm.js +++ b/src/components/settings/settings/EditSettingsForm.js | |||
@@ -156,6 +156,7 @@ export default @observer class EditSettingsForm extends Component { | |||
156 | cacheSize: PropTypes.string.isRequired, | 156 | cacheSize: PropTypes.string.isRequired, |
157 | isSpellcheckerIncludedInCurrentPlan: PropTypes.bool.isRequired, | 157 | isSpellcheckerIncludedInCurrentPlan: PropTypes.bool.isRequired, |
158 | isTodosEnabled: PropTypes.bool.isRequired, | 158 | isTodosEnabled: PropTypes.bool.isRequired, |
159 | isTodosActivated: PropTypes.bool.isRequired, | ||
159 | isWorkspaceEnabled: PropTypes.bool.isRequired, | 160 | isWorkspaceEnabled: PropTypes.bool.isRequired, |
160 | noUpdates: PropTypes.bool.isRequired, | 161 | noUpdates: PropTypes.bool.isRequired, |
161 | hibernationEnabled: PropTypes.bool.isRequired, | 162 | hibernationEnabled: PropTypes.bool.isRequired, |
@@ -201,6 +202,7 @@ export default @observer class EditSettingsForm extends Component { | |||
201 | isDarkmodeEnabled, | 202 | isDarkmodeEnabled, |
202 | isTrayEnabled, | 203 | isTrayEnabled, |
203 | openProcessManager, | 204 | openProcessManager, |
205 | isTodosActivated, | ||
204 | } = this.props; | 206 | } = this.props; |
205 | const { intl } = this.context; | 207 | const { intl } = this.context; |
206 | 208 | ||
@@ -275,22 +277,32 @@ export default @observer class EditSettingsForm extends Component { | |||
275 | {isTodosEnabled && ( | 277 | {isTodosEnabled && ( |
276 | <> | 278 | <> |
277 | <Toggle field={form.$('enableTodos')} /> | 279 | <Toggle field={form.$('enableTodos')} /> |
278 | <Input | 280 | {isTodosActivated && ( |
279 | placeholder="Todo Server" | 281 | <div> |
280 | onChange={e => this.submit(e)} | 282 | <Select field={form.$('predefinedTodoServer')} /> |
281 | field={form.$('todoServer')} | 283 | {form.$('predefinedTodoServer').value === 'isUsingCustomTodoService' && ( |
282 | /> | 284 | <div> |
283 | <p | 285 | <Input |
284 | className="settings__message" | 286 | placeholder="Todo Server" |
285 | style={{ | 287 | onChange={e => this.submit(e)} |
286 | borderTop: 0, marginTop: 0, paddingTop: 0, marginBottom: '2rem', | 288 | field={form.$('customTodoServer')} |
287 | }} | 289 | /> |
288 | > | 290 | <p |
289 | { intl.formatMessage(messages.todoServerInfo) } | 291 | className="settings__message" |
290 | </p> | 292 | style={{ |
293 | borderTop: 0, marginTop: 0, paddingTop: 0, marginBottom: '2rem', | ||
294 | }} | ||
295 | > | ||
296 | { intl.formatMessage(messages.todoServerInfo) } | ||
297 | </p> | ||
298 | </div> | ||
299 | )} | ||
300 | </div> | ||
301 | )} | ||
291 | </> | 302 | </> |
292 | )} | 303 | )} |
293 | 304 | ||
305 | |||
294 | <Hr /> | 306 | <Hr /> |
295 | 307 | ||
296 | <Toggle field={form.$('lockingFeatureEnabled')} /> | 308 | <Toggle field={form.$('lockingFeatureEnabled')} /> |