diff options
author | 2018-12-09 20:48:25 +0100 | |
---|---|---|
committer | 2018-12-09 20:48:25 +0100 | |
commit | 5d6164973e92fa8a3e3c18a0eb2e29494aea4f48 (patch) | |
tree | 382e6c672bbc0f7582b3b627b02111dcce902894 /src/components/ui/Input.js | |
parent | Add React 16 didCatch/ErrorBoundary component (diff) | |
download | ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.tar.gz ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.tar.zst ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.zip |
Fix linting issues
Diffstat (limited to 'src/components/ui/Input.js')
-rw-r--r-- | src/components/ui/Input.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/components/ui/Input.js b/src/components/ui/Input.js index 7bf6e1b00..9b070c4df 100644 --- a/src/components/ui/Input.js +++ b/src/components/ui/Input.js | |||
@@ -33,6 +33,8 @@ export default @observer class Input extends Component { | |||
33 | passwordScore: 0, | 33 | passwordScore: 0, |
34 | } | 34 | } |
35 | 35 | ||
36 | inputElement = null; | ||
37 | |||
36 | componentDidMount() { | 38 | componentDidMount() { |
37 | if (this.props.focus) { | 39 | if (this.props.focus) { |
38 | this.focus(); | 40 | this.focus(); |
@@ -53,8 +55,6 @@ export default @observer class Input extends Component { | |||
53 | this.inputElement.focus(); | 55 | this.inputElement.focus(); |
54 | } | 56 | } |
55 | 57 | ||
56 | inputElement = null; | ||
57 | |||
58 | render() { | 58 | render() { |
59 | const { | 59 | const { |
60 | field, | 60 | field, |
@@ -110,7 +110,7 @@ export default @observer class Input extends Component { | |||
110 | 'mdi-eye': !this.state.showPassword, | 110 | 'mdi-eye': !this.state.showPassword, |
111 | 'mdi-eye-off': this.state.showPassword, | 111 | 'mdi-eye-off': this.state.showPassword, |
112 | })} | 112 | })} |
113 | onClick={() => this.setState({ showPassword: !this.state.showPassword })} | 113 | onClick={() => this.setState(prevState => ({ showPassword: !prevState.showPassword }))} |
114 | tabIndex="-1" | 114 | tabIndex="-1" |
115 | /> | 115 | /> |
116 | )} | 116 | )} |