zzc-design-mobile
Advanced tools
Comparing version 1.4.12 to 1.4.13
@@ -84,3 +84,2 @@ 'use strict'; | ||
this.parentNode = this.createParentNode(className); | ||
console.log(this.opt); | ||
this._alert = _reactDom2.default.render(_react2.default.createElement( | ||
@@ -87,0 +86,0 @@ _modal2.default, |
@@ -179,3 +179,3 @@ 'use strict'; | ||
} catch (err) { | ||
console.log(err); | ||
// console.log( err ); | ||
} | ||
@@ -182,0 +182,0 @@ } |
@@ -279,3 +279,3 @@ 'use strict'; | ||
{ getRef: function getRef(dialog) { | ||
console.log(dialog);_this5.getDialog(dialog); | ||
_this5.getDialog(dialog); | ||
}, maskClose: true, maskClassName: prefixCls + '-mask', boxClassName: prefixCls + '-box', transitionName: _config2.default.cls + '-fade', maskTransitionName: _config2.default.cls + '-fade', visible: visible, className: (0, _classnames2.default)(prefixCls, className), style: style, closeCallback: function closeCallback() { | ||
@@ -282,0 +282,0 @@ _this5.close(); |
@@ -254,3 +254,2 @@ 'use strict'; | ||
console.log(this.props.style); | ||
if (this.state.isRenderModal) { | ||
@@ -257,0 +256,0 @@ return _react2.default.createElement( |
@@ -7,2 +7,6 @@ 'use strict'; | ||
var _assign = require('babel-runtime/core-js/object/assign'); | ||
var _assign2 = _interopRequireDefault(_assign); | ||
var _getPrototypeOf = require('babel-runtime/core-js/object/get-prototype-of'); | ||
@@ -55,6 +59,8 @@ | ||
value: function render() { | ||
// 外部调用setState传入props中 | ||
var props = (0, _assign2.default)({}, this.props, this.state); | ||
return _react2.default.createElement( | ||
_Error2.default, | ||
{ componentName: 'Modal' }, | ||
_react2.default.createElement(_modal2.default, this.props) | ||
_react2.default.createElement(_modal2.default, props) | ||
); | ||
@@ -61,0 +67,0 @@ } |
@@ -61,2 +61,4 @@ 'use strict'; | ||
showPopup: _this.props.visible, | ||
lastShowPopup: _this.props.visible, | ||
isClose: false, | ||
animationTypeList: _animateConfig2.default | ||
@@ -76,4 +78,9 @@ }; | ||
this.setState({ | ||
lastShowPopup: true, | ||
showPopup: true | ||
}); | ||
} else if (this.state.lastShowPopup && !nextProps.visible) { | ||
this.setState({ | ||
isClose: true | ||
}); | ||
} | ||
@@ -125,5 +132,8 @@ } | ||
preRender = _props.preRender; | ||
var _state = this.state, | ||
isClose = _state.isClose, | ||
showPopup = _state.showPopup; | ||
// 如果使用了预渲染模式的话,就直接渲染出Dialog | ||
if (this.state.showPopup || preRender) { | ||
if (showPopup || !isClose && preRender) { | ||
return _react2.default.createElement( | ||
@@ -130,0 +140,0 @@ _dialog2.default, |
{ | ||
"name": "zzc-design-mobile", | ||
"name_cn": "租租车主流程UI规范", | ||
"version": "1.4.12", | ||
"version": "1.4.13", | ||
"description": "", | ||
@@ -6,0 +6,0 @@ "main": "./lib/index.js", |
426630
10819