Merge pull request #181 from sharetribe/fix-tests-and-format

Fix tests and format
This commit is contained in:
Mikko Koski 2017-05-18 10:49:15 +03:00 committed by GitHub
commit 96d405a663
2 changed files with 7 additions and 7 deletions

View file

@ -8,7 +8,7 @@
* </AddImages>
*/
import React, { Component, PropTypes } from 'react';
import { SortableContainer, SortableElement } from 'react-sortable-hoc';
import { SortableContainer } from 'react-sortable-hoc';
import classNames from 'classnames';
import { Promised } from '../../components';
import { uuid } from '../../util/propTypes';

View file

@ -22,14 +22,14 @@ const windowWidth = () => {
const x = w.innerWidth || e.clientWidth || g.clientWidth;
return x;
}
};
class MobileFrame extends Component {
constructor(props) {
super(props);
this.state = {
manuallyDisabled: false,
automaticallyDisabled: false
automaticallyDisabled: false,
};
this.closeFrame = this.closeFrame.bind(this);
@ -41,11 +41,11 @@ class MobileFrame extends Component {
}
componentDidMount() {
window.addEventListener("resize", this.toggleBasedOnWindowSize);
window.addEventListener('resize', this.toggleBasedOnWindowSize);
}
componentWillUnmount() {
window.removeEventListener("resize", this.toggleBasedOnWindowSize);
window.removeEventListener('resize', this.toggleBasedOnWindowSize);
}
closeFrame(e) {
@ -57,9 +57,9 @@ class MobileFrame extends Component {
const shouldHide = windowWidth() < SHOW_FRAME_BREAKPOINT;
if (shouldHide) {
this.setState({automaticallyDisabled: true})
this.setState({ automaticallyDisabled: true });
} else {
this.setState({automaticallyDisabled: false})
this.setState({ automaticallyDisabled: false });
}
}