diff options
author | muhamedsalih-tw <104364298+muhamedsalih-tw@users.noreply.github.com> | 2022-12-01 00:33:39 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-30 19:03:39 +0000 |
commit | 6df93308d7a93cccb281f3e979668df23007ab5d (patch) | |
tree | 7cce68384707b3bec22c1b5f7b37b9be63bb1ce8 /src/components | |
parent | fix: [#809] unable to save custom icon for any service (#811) (diff) | |
download | ferdium-app-6df93308d7a93cccb281f3e979668df23007ab5d.tar.gz ferdium-app-6df93308d7a93cccb281f3e979668df23007ab5d.tar.zst ferdium-app-6df93308d7a93cccb281f3e979668df23007ab5d.zip |
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/auth/Invite.tsx | 2 | ||||
-rw-r--r-- | src/components/auth/Locked.tsx | 2 | ||||
-rw-r--r-- | src/components/auth/Login.tsx | 2 | ||||
-rw-r--r-- | src/components/auth/Password.tsx | 2 | ||||
-rw-r--r-- | src/components/auth/Signup.tsx | 2 | ||||
-rw-r--r-- | src/components/settings/services/EditServiceForm.tsx | 3 | ||||
-rw-r--r-- | src/components/settings/settings/EditSettingsForm.tsx | 3 | ||||
-rw-r--r-- | src/components/settings/user/EditUserForm.tsx | 2 | ||||
-rw-r--r-- | src/components/ui/input/index.tsx | 2 | ||||
-rw-r--r-- | src/components/ui/select/index.tsx | 2 | ||||
-rw-r--r-- | src/components/ui/textarea/index.tsx | 7 |
11 files changed, 16 insertions, 13 deletions
diff --git a/src/components/auth/Invite.tsx b/src/components/auth/Invite.tsx index 7723ea1ac..4ab5157a8 100644 --- a/src/components/auth/Invite.tsx +++ b/src/components/auth/Invite.tsx | |||
@@ -117,7 +117,7 @@ class Invite extends Component<IProps, IState> { | |||
117 | 117 | ||
118 | this.setState({ showSuccessInfo: true }); | 118 | this.setState({ showSuccessInfo: true }); |
119 | }, | 119 | }, |
120 | onError: () => {}, | 120 | onError: noop, |
121 | }); | 121 | }); |
122 | } | 122 | } |
123 | 123 | ||
diff --git a/src/components/auth/Locked.tsx b/src/components/auth/Locked.tsx index 8b4e26878..00ff5a4c5 100644 --- a/src/components/auth/Locked.tsx +++ b/src/components/auth/Locked.tsx | |||
@@ -72,7 +72,7 @@ class Locked extends Component<IProps> { | |||
72 | onSuccess: form => { | 72 | onSuccess: form => { |
73 | this.props.onSubmit(form.values()); | 73 | this.props.onSubmit(form.values()); |
74 | }, | 74 | }, |
75 | onError: () => {}, | 75 | onError: noop, |
76 | }); | 76 | }); |
77 | } | 77 | } |
78 | 78 | ||
diff --git a/src/components/auth/Login.tsx b/src/components/auth/Login.tsx index 185a6ad48..0a95b0565 100644 --- a/src/components/auth/Login.tsx +++ b/src/components/auth/Login.tsx | |||
@@ -103,7 +103,7 @@ class Login extends Component<IProps> { | |||
103 | onSuccess: form => { | 103 | onSuccess: form => { |
104 | this.props.onSubmit(form.values()); | 104 | this.props.onSubmit(form.values()); |
105 | }, | 105 | }, |
106 | onError: () => {}, | 106 | onError: noop, |
107 | }); | 107 | }); |
108 | } | 108 | } |
109 | 109 | ||
diff --git a/src/components/auth/Password.tsx b/src/components/auth/Password.tsx index 53fdbf842..03adc3859 100644 --- a/src/components/auth/Password.tsx +++ b/src/components/auth/Password.tsx | |||
@@ -71,7 +71,7 @@ class Password extends Component<IProps> { | |||
71 | onSuccess: form => { | 71 | onSuccess: form => { |
72 | this.props.onSubmit(form.values()); | 72 | this.props.onSubmit(form.values()); |
73 | }, | 73 | }, |
74 | onError: () => {}, | 74 | onError: noop, |
75 | }); | 75 | }); |
76 | } | 76 | } |
77 | 77 | ||
diff --git a/src/components/auth/Signup.tsx b/src/components/auth/Signup.tsx index af14430aa..fb2a2360e 100644 --- a/src/components/auth/Signup.tsx +++ b/src/components/auth/Signup.tsx | |||
@@ -114,7 +114,7 @@ class Signup extends Component<IProps> { | |||
114 | onSuccess: form => { | 114 | onSuccess: form => { |
115 | this.props.onSubmit(form.values()); | 115 | this.props.onSubmit(form.values()); |
116 | }, | 116 | }, |
117 | onError: () => {}, | 117 | onError: noop, |
118 | }); | 118 | }); |
119 | } | 119 | } |
120 | 120 | ||
diff --git a/src/components/settings/services/EditServiceForm.tsx b/src/components/settings/services/EditServiceForm.tsx index 7104b1344..2b87dff1e 100644 --- a/src/components/settings/services/EditServiceForm.tsx +++ b/src/components/settings/services/EditServiceForm.tsx | |||
@@ -4,6 +4,7 @@ import { Link } from 'react-router-dom'; | |||
4 | import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl'; | 4 | import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl'; |
5 | import normalizeUrl from 'normalize-url'; | 5 | import normalizeUrl from 'normalize-url'; |
6 | import { mdiInformation } from '@mdi/js'; | 6 | import { mdiInformation } from '@mdi/js'; |
7 | import { noop } from 'lodash'; | ||
7 | import Form from '../../../lib/Form'; | 8 | import Form from '../../../lib/Form'; |
8 | import Tabs from '../../ui/Tabs/Tabs'; | 9 | import Tabs from '../../ui/Tabs/Tabs'; |
9 | import TabItem from '../../ui/Tabs/TabItem'; | 10 | import TabItem from '../../ui/Tabs/TabItem'; |
@@ -213,7 +214,7 @@ class EditServiceForm extends Component<IProps, IState> { | |||
213 | 214 | ||
214 | this.setState({ isValidatingCustomUrl: false }); | 215 | this.setState({ isValidatingCustomUrl: false }); |
215 | }, | 216 | }, |
216 | onError: () => {}, | 217 | onError: noop, |
217 | }); | 218 | }); |
218 | } | 219 | } |
219 | 220 | ||
diff --git a/src/components/settings/settings/EditSettingsForm.tsx b/src/components/settings/settings/EditSettingsForm.tsx index c8e7e2c45..49798dd92 100644 --- a/src/components/settings/settings/EditSettingsForm.tsx +++ b/src/components/settings/settings/EditSettingsForm.tsx | |||
@@ -4,6 +4,7 @@ import { observer } from 'mobx-react'; | |||
4 | import prettyBytes from 'pretty-bytes'; | 4 | import prettyBytes from 'pretty-bytes'; |
5 | import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl'; | 5 | import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl'; |
6 | import { mdiGithub, mdiOpenInNew, mdiPowerPlug } from '@mdi/js'; | 6 | import { mdiGithub, mdiOpenInNew, mdiPowerPlug } from '@mdi/js'; |
7 | import { noop } from 'lodash'; | ||
7 | import Form from '../../../lib/Form'; | 8 | import Form from '../../../lib/Form'; |
8 | import Button from '../../ui/button'; | 9 | import Button from '../../ui/button'; |
9 | import Toggle from '../../ui/toggle'; | 10 | import Toggle from '../../ui/toggle'; |
@@ -343,7 +344,7 @@ class EditSettingsForm extends Component<IProps, IState> { | |||
343 | } | 344 | } |
344 | this.props.onSubmit(values); | 345 | this.props.onSubmit(values); |
345 | }, | 346 | }, |
346 | onError: () => {}, | 347 | onError: noop, |
347 | }); | 348 | }); |
348 | } | 349 | } |
349 | 350 | ||
diff --git a/src/components/settings/user/EditUserForm.tsx b/src/components/settings/user/EditUserForm.tsx index 3b604a79f..5a2a5a83e 100644 --- a/src/components/settings/user/EditUserForm.tsx +++ b/src/components/settings/user/EditUserForm.tsx | |||
@@ -53,7 +53,7 @@ class EditUserForm extends Component<IProps> { | |||
53 | const values = form.values(); | 53 | const values = form.values(); |
54 | this.props.onSubmit(values); | 54 | this.props.onSubmit(values); |
55 | }, | 55 | }, |
56 | onError: () => {}, | 56 | onError: noop, |
57 | }); | 57 | }); |
58 | } | 58 | } |
59 | 59 | ||
diff --git a/src/components/ui/input/index.tsx b/src/components/ui/input/index.tsx index a6d401195..fe8f35607 100644 --- a/src/components/ui/input/index.tsx +++ b/src/components/ui/input/index.tsx | |||
@@ -42,7 +42,7 @@ interface IProps | |||
42 | showPasswordToggle?: boolean; | 42 | showPasswordToggle?: boolean; |
43 | data?: IData; | 43 | data?: IData; |
44 | inputClassName?: string; | 44 | inputClassName?: string; |
45 | onEnterKey?: () => {}; | 45 | onEnterKey?: () => void; |
46 | } | 46 | } |
47 | 47 | ||
48 | interface IState { | 48 | interface IState { |
diff --git a/src/components/ui/select/index.tsx b/src/components/ui/select/index.tsx index b22c15320..31aa8a15f 100644 --- a/src/components/ui/select/index.tsx +++ b/src/components/ui/select/index.tsx | |||
@@ -386,7 +386,7 @@ class SelectComponent extends Component<IProps, IState> { | |||
386 | this.setState((state: IState) => ({ | 386 | this.setState((state: IState) => ({ |
387 | open: !state.open, | 387 | open: !state.open, |
388 | })) | 388 | })) |
389 | : () => {} | 389 | : noop |
390 | } | 390 | } |
391 | > | 391 | > |
392 | {selection} | 392 | {selection} |
diff --git a/src/components/ui/textarea/index.tsx b/src/components/ui/textarea/index.tsx index d4ea424be..89e85ac11 100644 --- a/src/components/ui/textarea/index.tsx +++ b/src/components/ui/textarea/index.tsx | |||
@@ -2,6 +2,7 @@ import classnames from 'classnames'; | |||
2 | import { Component, createRef, TextareaHTMLAttributes } from 'react'; | 2 | import { Component, createRef, TextareaHTMLAttributes } from 'react'; |
3 | import injectSheet, { WithStylesProps } from 'react-jss'; | 3 | import injectSheet, { WithStylesProps } from 'react-jss'; |
4 | 4 | ||
5 | import { noop } from 'lodash'; | ||
5 | import { IFormField } from '../typings/generic'; | 6 | import { IFormField } from '../typings/generic'; |
6 | 7 | ||
7 | import Error from '../error'; | 8 | import Error from '../error'; |
@@ -24,9 +25,9 @@ interface IProps | |||
24 | 25 | ||
25 | class TextareaComponent extends Component<IProps> { | 26 | class TextareaComponent extends Component<IProps> { |
26 | static defaultProps = { | 27 | static defaultProps = { |
27 | onChange: () => {}, | 28 | onChange: noop, |
28 | onBlur: () => {}, | 29 | onBlur: noop, |
29 | onFocus: () => {}, | 30 | onFocus: noop, |
30 | showLabel: true, | 31 | showLabel: true, |
31 | disabled: false, | 32 | disabled: false, |
32 | rows: 5, | 33 | rows: 5, |