react-bootstrap-table-next
Advanced tools
Comparing version 3.1.6 to 3.1.7
@@ -246,3 +246,4 @@ 'use strict'; | ||
expandHeaderColumnRenderer: _propTypes2.default.func, | ||
expandColumnPosition: _propTypes2.default.oneOf([_const2.default.INDICATOR_POSITION_LEFT, _const2.default.INDICATOR_POSITION_RIGHT]) | ||
expandColumnPosition: _propTypes2.default.oneOf([_const2.default.INDICATOR_POSITION_LEFT, _const2.default.INDICATOR_POSITION_RIGHT]), | ||
parentClassName: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]) | ||
}), | ||
@@ -249,0 +250,0 @@ rowStyle: _propTypes2.default.oneOfType([_propTypes2.default.object, _propTypes2.default.func]), |
@@ -16,3 +16,7 @@ 'use strict'; | ||
INDICATOR_POSITION_LEFT: 'left', | ||
INDICATOR_POSITION_RIGHT: 'right' | ||
INDICATOR_POSITION_RIGHT: 'right', | ||
TYPE_STRING: 'string', | ||
TYPE_NUMBER: 'number', | ||
TYPE_BOOLEAN: 'bool', | ||
TYPE_DATE: 'date' | ||
}; |
@@ -130,2 +130,3 @@ 'use strict'; | ||
text: _propTypes2.default.string.isRequired, | ||
type: _propTypes2.default.oneOf([_const2.default.TYPE_STRING, _const2.default.TYPE_NUMBER, _const2.default.TYPE_BOOLEAN, _const2.default.TYPE_DATE]), | ||
isDummyField: _propTypes2.default.bool, | ||
@@ -132,0 +133,0 @@ hidden: _propTypes2.default.bool, |
@@ -14,2 +14,6 @@ 'use strict'; | ||
var _classnames = require('classnames'); | ||
var _classnames2 = _interopRequireDefault(_classnames); | ||
var _expandRow = require('./expand-row'); | ||
@@ -31,2 +35,3 @@ | ||
var renderWithExpansion = function renderWithExpansion(props, expandRow) { | ||
var parentClassName = ''; | ||
var key = props.value; | ||
@@ -37,2 +42,6 @@ | ||
var expandable = !expandRow.nonExpandable || !_utils2.default.contains(expandRow.nonExpandable, key); | ||
if (expanded) { | ||
parentClassName = _utils2.default.isFunction(expandRow.parentClassName) ? expandRow.parentClassName(expanded, props.row, props.rowIndex) : expandRow.parentClassName || ''; | ||
} | ||
return [_react2.default.createElement(Component, _extends({}, props, { | ||
@@ -42,3 +51,4 @@ key: key, | ||
expandable: expandable, | ||
expandRow: _extends({}, expandRow) | ||
expandRow: _extends({}, expandRow), | ||
className: (0, _classnames2.default)(props.className, parentClassName) | ||
})), expanded || isClosing ? _react2.default.createElement( | ||
@@ -54,3 +64,3 @@ _expandRow2.default, | ||
}, | ||
expandRow.renderer(props.row) | ||
expandRow.renderer(props.row, props.rowIndex) | ||
) : null]; | ||
@@ -57,0 +67,0 @@ }; |
@@ -77,3 +77,3 @@ 'use strict'; | ||
value: function shouldComponentUpdate(nextProps) { | ||
if (this.props.selected !== nextProps.selected || this.props.expanded !== nextProps.expanded || this.props.expandable !== nextProps.expandable || this.props.selectable !== nextProps.selectable || this.shouldUpdatedBySelfProps(nextProps)) { | ||
if (this.props.selected !== nextProps.selected || this.props.expanded !== nextProps.expanded || this.props.expandable !== nextProps.expandable || this.props.selectable !== nextProps.selectable || this.props.selectRow.hideSelectColumn !== nextProps.selectRow.hideSelectColumn || this.shouldUpdatedBySelfProps(nextProps)) { | ||
this.shouldUpdateRowContent = this.shouldRowContentUpdate(nextProps); | ||
@@ -80,0 +80,0 @@ return true; |
@@ -29,4 +29,8 @@ 'use strict'; | ||
var _type = require('./type'); | ||
var type = _interopRequireWildcard(_type); | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } | ||
exports.default = _extends({}, rows, selection, expand, mutate, sort); | ||
exports.default = _extends({}, rows, selection, expand, mutate, sort, type); |
{ | ||
"name": "react-bootstrap-table-next", | ||
"version": "3.1.6", | ||
"version": "3.1.7", | ||
"description": "Next generation of react-bootstrap-table", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
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
1079146
53
12542