diff --git a/src/components/Modal/BaseModal.js b/src/components/Modal/BaseModal.js index d9fccfef3312..a4b7ed90a8fe 100644 --- a/src/components/Modal/BaseModal.js +++ b/src/components/Modal/BaseModal.js @@ -16,15 +16,11 @@ const propTypes = { /** The ref to the modal container */ forwardedRef: PropTypes.func, - - /** Ensure that callback and trap deactivation are in the same loop on the web platform */ - shouldUseOnDismiss: PropTypes.bool, }; const defaultProps = { ...modalDefaultProps, forwardedRef: () => {}, - shouldUseOnDismiss: false, }; class BaseModal extends PureComponent { @@ -113,8 +109,7 @@ class BaseModal extends PureComponent { this.props.onModalShow(); }} propagateSwipe={this.props.propagateSwipe} - onDismiss={this.props.shouldUseOnDismiss ? this.hideModal : () => {}} - onModalHide={!this.props.shouldUseOnDismiss ? this.hideModal : () => {}} + onModalHide={this.hideModal} onSwipeComplete={this.props.onClose} swipeDirection={swipeDirection} isVisible={this.props.isVisible} diff --git a/src/components/Modal/index.web.js b/src/components/Modal/index.web.js index 24c83001698c..3cb6f3561b60 100644 --- a/src/components/Modal/index.web.js +++ b/src/components/Modal/index.web.js @@ -29,7 +29,6 @@ const Modal = (props) => {