diff --git a/src/components/ModalPortal.js b/src/components/ModalPortal.js index 7d2efeca..6f48c513 100644 --- a/src/components/ModalPortal.js +++ b/src/components/ModalPortal.js @@ -232,6 +232,9 @@ export default class ModalPortal extends Component { if (this.moveFromContentToOverlay === null) { this.shouldClose = false; } + if (this.props.shouldCloseOnOverlayClick) { + this.shouldClose = true; + } }; handleContentOnMouseUp = () => {