Comparing version 0.9.1-beta6 to 0.9.1-beta7
@@ -9,3 +9,3 @@ # 更新日志 | ||
* 新增 [timeline](http://ant.design/components/timeline) 和 [badge](http://ant.design/components/badge) 组件。 | ||
* 新增 [timeline](components/timeline/) 和 [badge](components/badge/) 组件。 | ||
* 优化弹出层类组件的动画效果,使其更加流畅。 | ||
@@ -12,0 +12,0 @@ * 部分文案更新。 |
@@ -54,2 +54,2 @@ require('./index.css'); | ||
antd.version = '0.9.1-beta6'; | ||
antd.version = '0.9.1-beta7'; |
@@ -17,5 +17,6 @@ 'use strict'; | ||
var div = undefined; | ||
exports['default'] = function (props) { | ||
var div = document.createElement('div'); | ||
document.body.appendChild(div); | ||
exports['default'] = function (props) { | ||
var d = undefined; | ||
@@ -35,2 +36,3 @@ props = props || {}; | ||
}); | ||
_react2['default'].unmountComponentAtNode(div); | ||
} | ||
@@ -135,7 +137,2 @@ | ||
if (!div) { | ||
div = document.createElement('div'); | ||
document.body.appendChild(div); | ||
} | ||
_react2['default'].render(_react2['default'].createElement( | ||
@@ -142,0 +139,0 @@ _index2['default'], |
@@ -44,3 +44,5 @@ 'use strict'; | ||
type: file.type, | ||
uid: file.uid | ||
uid: file.uid, | ||
response: file.response, | ||
error: file.error | ||
}; | ||
@@ -87,2 +89,12 @@ } | ||
onSuccess: function onSuccess(response, file) { | ||
// 服务器端需要返回标准 json 字符串 | ||
// 否则视为失败 | ||
try { | ||
if (typeof response === 'string') { | ||
JSON.parse(response); | ||
} | ||
} catch (e) { | ||
this.onError(new Error('No response'), response, file); | ||
return; | ||
} | ||
var fileList = this.state.fileList.concat(); | ||
@@ -112,6 +124,8 @@ var targetItem = (0, _getFileItem2['default'])(file, fileList); | ||
onError: function onError(error, response, file) { | ||
file.error = error; | ||
file.response = response; | ||
file.status = 'error'; | ||
this.handleRemove(file); | ||
var fileList = this.state.fileList; | ||
var targetItem = (0, _getFileItem2['default'])(file, fileList); | ||
targetItem.error = error; | ||
targetItem.response = response; | ||
targetItem.status = 'error'; | ||
this.handleRemove(targetItem); | ||
}, | ||
@@ -118,0 +132,0 @@ handleRemove: function handleRemove(file) { |
{ | ||
"name": "antd", | ||
"version": "0.9.1-beta6", | ||
"version": "0.9.1-beta7", | ||
"stableVersion": "0.9.0", | ||
@@ -55,3 +55,3 @@ "title": "Ant Design", | ||
"rc-slider": "~1.4.0", | ||
"rc-steps": "~1.3.0", | ||
"rc-steps": "~1.3.2", | ||
"rc-switch": "~1.2.0", | ||
@@ -100,3 +100,4 @@ "rc-table": "~3.2.0", | ||
"clean": "rm -rf _site dist", | ||
"deploy": "rm -rf node_modules && node scripts/install.js && npm run clean && webpack && webpack --config webpack.config.min.js && NODE_ENV=PRODUCTION nico build && node scripts/deploy.js", | ||
"deploy": "rm -rf node_modules && node scripts/install.js && npm run just-deploy", | ||
"just-deploy": "npm run clean && webpack && webpack --config webpack.config.min.js && NODE_ENV=PRODUCTION nico build && node scripts/deploy.js", | ||
"lint": "eslint components index.js --ext '.js,.jsx'", | ||
@@ -103,0 +104,0 @@ "lesslint": "lesslint style", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
351233
12422
Updatedrc-steps@~1.3.2