From 58eaab04481ef2be56a95d91393637de3471f564 Mon Sep 17 00:00:00 2001 From: jquense Date: Wed, 22 Jul 2015 20:40:39 -0400 Subject: [PATCH] [changed] pass transition callbacks to Modal Transition --- src/Modal.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Modal.js b/src/Modal.js index b7744aedb0..f6c64ec3d3 100644 --- a/src/Modal.js +++ b/src/Modal.js @@ -141,6 +141,7 @@ const Modal = React.createClass({ render() { let { children, animation, backdrop, ...props } = this.props; + let { onExit, onExiting, onEnter, onEntering, onEntered } = props; let show = !!props.show; @@ -166,7 +167,12 @@ const Modal = React.createClass({ unmountOnExit in={show} duration={Modal.TRANSITION_DURATION} + onExit={onExit} + onExiting={onExiting} onExited={this.handleHidden} + onEnter={onEnter} + onEntering={onEntering} + onEntered={onEntered} > { modal } @@ -316,6 +322,9 @@ const Modal = React.createClass({ this.onHide(); + if (this.props.onExited) { + this.props.onExited(...args); + } }, handleBackdropClick(e) {