From cc45569b6c52ee20b1627c2b37a15dc76a015b6c Mon Sep 17 00:00:00 2001 From: Mike Fix Date: Thu, 17 Jan 2019 10:34:03 -0800 Subject: [PATCH] remove old mounted state from BackgroundSelect --- components/BackgroundSelect.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/components/BackgroundSelect.js b/components/BackgroundSelect.js index cba44df..b43ffe5 100644 --- a/components/BackgroundSelect.js +++ b/components/BackgroundSelect.js @@ -8,12 +8,6 @@ import { validateColor } from '../lib/colors' import { capitalize, stringifyRGBA } from '../lib/util' class BackgroundSelect extends React.PureComponent { - state = { mounted: false } - - componentDidMount() { - this.setState({ mounted: true }) - } - selectTab = name => { if (this.props.mode !== name) { this.props.onChange({ backgroundMode: name }) @@ -24,7 +18,6 @@ class BackgroundSelect extends React.PureComponent { render() { const { color, mode, image, onChange, aspectRatio, isVisible, toggleVisibility } = this.props - const { mounted } = this.state let background = typeof color === 'string' @@ -68,7 +61,7 @@ class BackgroundSelect extends React.PureComponent {
- {mounted && } +