Comparing version 5.2.1 to 5.2.3
@@ -360,3 +360,4 @@ 'use strict'; | ||
optionText = _context3.optionText, | ||
prefix = _context3.prefix; | ||
prefix = _context3.prefix, | ||
maxLeafSize = _context3.maxLeafSize; | ||
var _props2 = this.props, | ||
@@ -465,3 +466,3 @@ sku = _props2.sku, | ||
}), | ||
sku[optionValue] > 0 && !disabled ? _react2['default'].createElement( | ||
sku[optionValue] > 0 && !disabled && (!maxLeafSize || sku.leaf.length < maxLeafSize) ? _react2['default'].createElement( | ||
_pop2['default'], | ||
@@ -494,2 +495,3 @@ { | ||
maxLeafTextLength: _propTypes2['default'].number, | ||
maxLeafSize: _propTypes2['default'].number, | ||
optionValue: _propTypes2['default'].string, | ||
@@ -496,0 +498,0 @@ optionText: _propTypes2['default'].string, |
@@ -122,2 +122,3 @@ 'use strict'; | ||
maxLeafTextLength: this.props.maxLeafTextLength, | ||
maxLeafSize: this.props.maxLeafSize, | ||
optionValue: this.props.optionValue, | ||
@@ -214,2 +215,3 @@ optionText: this.props.optionText, | ||
maxLeafTextLength: _propTypes2['default'].number, | ||
maxLeafSize: _propTypes2['default'].number, | ||
optionValue: _propTypes2['default'].string, | ||
@@ -228,2 +230,3 @@ optionText: _propTypes2['default'].string, | ||
maxSize: _propTypes2['default'].number, | ||
maxLeafSize: _propTypes2['default'].number, | ||
maxSKUTextLength: _propTypes2['default'].number, | ||
@@ -247,2 +250,3 @@ maxLeafTextLength: _propTypes2['default'].number, | ||
maxSize: 3, | ||
maxLeafSize: 0, | ||
maxSKUTextLength: 4, | ||
@@ -249,0 +253,0 @@ maxLeafTextLength: 20, |
{ | ||
"name": "zan-sku", | ||
"version": "5.2.1", | ||
"version": "5.2.3", | ||
"description": "这是一个React组件", | ||
@@ -18,3 +18,3 @@ "repository": "url/to/your/component", | ||
"dependencies": { | ||
"zan-upload": "^5.4.1", | ||
"zan-upload": "^5.4.3", | ||
"zan-utils": "^1.0.7" | ||
@@ -21,0 +21,0 @@ }, |
@@ -61,2 +61,3 @@ ## zan-sku | ||
<SKU | ||
maxLeafSize={3} | ||
onFetchGroup={this.fetchSKUTree} | ||
@@ -161,2 +162,3 @@ onFetchSKU={this.fetchSKU} | ||
| maxSize | 最大规格名称数 | number | `3` | | | ||
| maxLeafSize | 最大可添加规格值数,0为不限制 | number | `0` | | | ||
| maxSKUTextLength | 规格名称文字最大长度 | number | `4` | | | ||
@@ -163,0 +165,0 @@ | maxLeafTextLength | 规格值文字最大长度 | number | `20` | | |
Sorry, the diff of this file is too big to display
300
1470694
41164
Updatedzan-upload@^5.4.3