Skip to content

Commit

Permalink
use onMouseDown
Browse files Browse the repository at this point in the history
  • Loading branch information
tarasromil committed Jan 10, 2019
1 parent 518f2fd commit 7c9b369
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/Modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ var Modal = function (_React$Component) {
},
style: dialog,
className: (0, _classnames2.default)(className, prefix, { in: props.show && !transition }),
onClick: this.props.backdrop ? function (e) {
onMouseDown: this.props.backdrop ? function (e) {
return _this3.handleBackdropClick(e);
} : null
}),
Expand Down
2 changes: 1 addition & 1 deletion src/Modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ class Modal extends React.Component {
ref={r => this.dialog = r }
style={dialog}
className={cn(className, prefix, { in: props.show && !transition })}
onClick={this.props.backdrop ? e => this.handleBackdropClick(e) : null}
onMouseDown={this.props.backdrop ? e => this.handleBackdropClick(e) : null}
>
<div
key='modal'
Expand Down

0 comments on commit 7c9b369

Please sign in to comment.