Commit 1dd1fb4f authored by 陈帅's avatar 陈帅

fix code style warring

parent 5b5a737a
......@@ -69,14 +69,14 @@ export default class HeaderSearch extends PureComponent {
};
enterSearchMode = () => {
const { onVisibleChange } = this.props;
onVisibleChange(true);
this.setState({ searchMode: true }, () => {
const { searchMode } = this.state;
if (searchMode) {
this.input.focus();
}
});
const { onVisibleChange } = this.props;
onVisibleChange(true);
};
leaveSearchMode = () => {
......@@ -110,11 +110,9 @@ export default class HeaderSearch extends PureComponent {
className={classNames(className, styles.headerSearch)}
onClick={this.enterSearchMode}
onTransitionEnd={({ propertyName }) => {
if (propertyName === 'width') {
if (!searchMode) {
const { onVisibleChange } = this.props;
onVisibleChange(searchMode);
}
if (propertyName === 'width' && !searchMode) {
const { onVisibleChange } = this.props;
onVisibleChange(searchMode);
}
}}
>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment