rc-table
Advanced tools
Comparing version 7.45.3 to 7.45.4
@@ -124,3 +124,3 @@ import _extends from "@babel/runtime/helpers/esm/extends"; | ||
// >>>>> ClassName | ||
var mergedClassName = classNames(cellPrefixCls, className, (_classNames = {}, _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-left"), isFixLeft && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-left-first"), firstFixLeft && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-left-last"), lastFixLeft && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-left-all"), lastFixLeft && allColumnsFixedLeft && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-right"), isFixRight && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-right-first"), firstFixRight && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-right-last"), lastFixRight && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-ellipsis"), ellipsis), _defineProperty(_classNames, "".concat(cellPrefixCls, "-with-append"), appendNode), _defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-sticky"), (isFixLeft || isFixRight) && isSticky && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-row-hover"), !legacyCellProps && hovering), _classNames), additionalProps.className, legacyCellProps === null || legacyCellProps === void 0 ? void 0 : legacyCellProps.className); | ||
var mergedClassName = classNames(cellPrefixCls, className, (_classNames = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_classNames, "".concat(cellPrefixCls, "-fix-left"), isFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-first"), firstFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-last"), lastFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-all"), lastFixLeft && allColumnsFixedLeft && supportSticky), "".concat(cellPrefixCls, "-fix-right"), isFixRight && supportSticky), "".concat(cellPrefixCls, "-fix-right-first"), firstFixRight && supportSticky), "".concat(cellPrefixCls, "-fix-right-last"), lastFixRight && supportSticky), "".concat(cellPrefixCls, "-ellipsis"), ellipsis), "".concat(cellPrefixCls, "-with-append"), appendNode), "".concat(cellPrefixCls, "-fix-sticky"), (isFixLeft || isFixRight) && isSticky && supportSticky), _defineProperty(_classNames, "".concat(cellPrefixCls, "-row-hover"), !legacyCellProps && hovering)), additionalProps.className, legacyCellProps === null || legacyCellProps === void 0 ? void 0 : legacyCellProps.className); | ||
@@ -127,0 +127,0 @@ // >>>>> Style |
@@ -116,3 +116,2 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray"; | ||
if (expandable) { | ||
var _expandColumn; | ||
var cloneColumns = baseColumns.slice(); | ||
@@ -156,6 +155,6 @@ | ||
// >>> Create expandable column | ||
var expandColumn = (_expandColumn = {}, _defineProperty(_expandColumn, INTERNAL_COL_DEFINE, { | ||
var expandColumn = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, INTERNAL_COL_DEFINE, { | ||
className: "".concat(prefixCls, "-expand-icon-col"), | ||
columnType: 'EXPAND_COLUMN' | ||
}), _defineProperty(_expandColumn, "title", columnTitle), _defineProperty(_expandColumn, "fixed", fixedColumn), _defineProperty(_expandColumn, "className", "".concat(prefixCls, "-row-expand-icon-cell")), _defineProperty(_expandColumn, "width", columnWidth), _defineProperty(_expandColumn, "render", function render(_, record, index) { | ||
}), "title", columnTitle), "fixed", fixedColumn), "className", "".concat(prefixCls, "-row-expand-icon-cell")), "width", columnWidth), "render", function render(_, record, index) { | ||
var rowKey = getRowKey(record, index); | ||
@@ -179,3 +178,3 @@ var expanded = expandedKeys.has(rowKey); | ||
return icon; | ||
}), _expandColumn); | ||
}); | ||
return cloneColumns.map(function (col) { | ||
@@ -182,0 +181,0 @@ return col === EXPAND_COLUMN ? expandColumn : col; |
@@ -5,3 +5,4 @@ /* istanbul ignore next */ | ||
* So HOC will not work on this. | ||
*/ // eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
function Column(_) { | ||
@@ -8,0 +9,0 @@ return null; |
@@ -5,3 +5,4 @@ /* istanbul ignore next */ | ||
* So HOC will not work on this. | ||
*/ // eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
function ColumnGroup(_) { | ||
@@ -8,0 +9,0 @@ return null; |
@@ -72,3 +72,2 @@ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty"; | ||
function Table(tableProps, ref) { | ||
var _classNames; | ||
var props = _objectSpread({ | ||
@@ -583,3 +582,3 @@ rowKey: 'key', | ||
var fullTable = /*#__PURE__*/React.createElement("div", _extends({ | ||
className: classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, "".concat(prefixCls, "-rtl"), direction === 'rtl'), _defineProperty(_classNames, "".concat(prefixCls, "-ping-left"), pingedLeft), _defineProperty(_classNames, "".concat(prefixCls, "-ping-right"), pingedRight), _defineProperty(_classNames, "".concat(prefixCls, "-layout-fixed"), tableLayout === 'fixed'), _defineProperty(_classNames, "".concat(prefixCls, "-fixed-header"), fixHeader), _defineProperty(_classNames, "".concat(prefixCls, "-fixed-column"), fixColumn), _defineProperty(_classNames, "".concat(prefixCls, "-fixed-column-gapped"), fixColumn && hasGapFixed), _defineProperty(_classNames, "".concat(prefixCls, "-scroll-horizontal"), horizonScroll), _defineProperty(_classNames, "".concat(prefixCls, "-has-fix-left"), flattenColumns[0] && flattenColumns[0].fixed), _defineProperty(_classNames, "".concat(prefixCls, "-has-fix-right"), flattenColumns[flattenColumns.length - 1] && flattenColumns[flattenColumns.length - 1].fixed === 'right'), _classNames)), | ||
className: classNames(prefixCls, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-ping-left"), pingedLeft), "".concat(prefixCls, "-ping-right"), pingedRight), "".concat(prefixCls, "-layout-fixed"), tableLayout === 'fixed'), "".concat(prefixCls, "-fixed-header"), fixHeader), "".concat(prefixCls, "-fixed-column"), fixColumn), "".concat(prefixCls, "-fixed-column-gapped"), fixColumn && hasGapFixed), "".concat(prefixCls, "-scroll-horizontal"), horizonScroll), "".concat(prefixCls, "-has-fix-left"), flattenColumns[0] && flattenColumns[0].fixed), "".concat(prefixCls, "-has-fix-right"), flattenColumns[flattenColumns.length - 1] && flattenColumns[flattenColumns.length - 1].fixed === 'right')), | ||
style: style, | ||
@@ -586,0 +585,0 @@ id: id, |
@@ -5,3 +5,2 @@ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty"; | ||
export function renderExpandIcon(_ref) { | ||
var _classNames; | ||
var prefixCls = _ref.prefixCls, | ||
@@ -23,3 +22,3 @@ record = _ref.record, | ||
return /*#__PURE__*/React.createElement("span", { | ||
className: classNames(expandClassName, (_classNames = {}, _defineProperty(_classNames, "".concat(prefixCls, "-row-expanded"), expanded), _defineProperty(_classNames, "".concat(prefixCls, "-row-collapsed"), !expanded), _classNames)), | ||
className: classNames(expandClassName, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-row-expanded"), expanded), "".concat(prefixCls, "-row-collapsed"), !expanded)), | ||
onClick: onClick | ||
@@ -26,0 +25,0 @@ }); |
@@ -74,2 +74,3 @@ import _extends from "@babel/runtime/helpers/esm/extends"; | ||
var rowNode = /*#__PURE__*/React.createElement(RowComponent, _extends({}, rowProps, restProps, { | ||
"data-row-key": rowKey, | ||
ref: rowSupportExpand ? null : ref, | ||
@@ -76,0 +77,0 @@ className: classNames(className, "".concat(prefixCls, "-row"), rowProps === null || rowProps === void 0 ? void 0 : rowProps.className, _defineProperty({}, "".concat(prefixCls, "-row-extra"), extra)), |
@@ -134,3 +134,3 @@ "use strict"; | ||
// >>>>> ClassName | ||
var mergedClassName = (0, _classnames.default)(cellPrefixCls, className, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-left"), isFixLeft && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-left-first"), firstFixLeft && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-left-last"), lastFixLeft && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-left-all"), lastFixLeft && allColumnsFixedLeft && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-right"), isFixRight && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-right-first"), firstFixRight && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-right-last"), lastFixRight && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-ellipsis"), ellipsis), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-with-append"), appendNode), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-sticky"), (isFixLeft || isFixRight) && isSticky && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-row-hover"), !legacyCellProps && hovering), _classNames), additionalProps.className, legacyCellProps === null || legacyCellProps === void 0 ? void 0 : legacyCellProps.className); | ||
var mergedClassName = (0, _classnames.default)(cellPrefixCls, className, (_classNames = {}, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-fix-left"), isFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-first"), firstFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-last"), lastFixLeft && supportSticky), "".concat(cellPrefixCls, "-fix-left-all"), lastFixLeft && allColumnsFixedLeft && supportSticky), "".concat(cellPrefixCls, "-fix-right"), isFixRight && supportSticky), "".concat(cellPrefixCls, "-fix-right-first"), firstFixRight && supportSticky), "".concat(cellPrefixCls, "-fix-right-last"), lastFixRight && supportSticky), "".concat(cellPrefixCls, "-ellipsis"), ellipsis), "".concat(cellPrefixCls, "-with-append"), appendNode), "".concat(cellPrefixCls, "-fix-sticky"), (isFixLeft || isFixRight) && isSticky && supportSticky), (0, _defineProperty2.default)(_classNames, "".concat(cellPrefixCls, "-row-hover"), !legacyCellProps && hovering)), additionalProps.className, legacyCellProps === null || legacyCellProps === void 0 ? void 0 : legacyCellProps.className); | ||
@@ -137,0 +137,0 @@ // >>>>> Style |
@@ -127,3 +127,2 @@ "use strict"; | ||
if (expandable) { | ||
var _expandColumn; | ||
var cloneColumns = baseColumns.slice(); | ||
@@ -167,6 +166,6 @@ | ||
// >>> Create expandable column | ||
var expandColumn = (_expandColumn = {}, (0, _defineProperty2.default)(_expandColumn, _legacyUtil.INTERNAL_COL_DEFINE, { | ||
var expandColumn = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _legacyUtil.INTERNAL_COL_DEFINE, { | ||
className: "".concat(prefixCls, "-expand-icon-col"), | ||
columnType: 'EXPAND_COLUMN' | ||
}), (0, _defineProperty2.default)(_expandColumn, "title", columnTitle), (0, _defineProperty2.default)(_expandColumn, "fixed", fixedColumn), (0, _defineProperty2.default)(_expandColumn, "className", "".concat(prefixCls, "-row-expand-icon-cell")), (0, _defineProperty2.default)(_expandColumn, "width", columnWidth), (0, _defineProperty2.default)(_expandColumn, "render", function render(_, record, index) { | ||
}), "title", columnTitle), "fixed", fixedColumn), "className", "".concat(prefixCls, "-row-expand-icon-cell")), "width", columnWidth), "render", function render(_, record, index) { | ||
var rowKey = getRowKey(record, index); | ||
@@ -190,3 +189,3 @@ var expanded = expandedKeys.has(rowKey); | ||
return icon; | ||
}), _expandColumn); | ||
}); | ||
return cloneColumns.map(function (col) { | ||
@@ -193,0 +192,0 @@ return col === _constant.EXPAND_COLUMN ? expandColumn : col; |
@@ -11,3 +11,4 @@ "use strict"; | ||
* So HOC will not work on this. | ||
*/ // eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
function Column(_) { | ||
@@ -14,0 +15,0 @@ return null; |
@@ -11,3 +11,4 @@ "use strict"; | ||
* So HOC will not work on this. | ||
*/ // eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
function ColumnGroup(_) { | ||
@@ -14,0 +15,0 @@ return null; |
@@ -83,3 +83,2 @@ "use strict"; | ||
function Table(tableProps, ref) { | ||
var _classNames; | ||
var props = (0, _objectSpread2.default)({ | ||
@@ -594,3 +593,3 @@ rowKey: 'key', | ||
var fullTable = /*#__PURE__*/React.createElement("div", (0, _extends2.default)({ | ||
className: (0, _classnames.default)(prefixCls, className, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-rtl"), direction === 'rtl'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-ping-left"), pingedLeft), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-ping-right"), pingedRight), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-layout-fixed"), tableLayout === 'fixed'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-fixed-header"), fixHeader), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-fixed-column"), fixColumn), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-fixed-column-gapped"), fixColumn && hasGapFixed), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-scroll-horizontal"), horizonScroll), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-has-fix-left"), flattenColumns[0] && flattenColumns[0].fixed), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-has-fix-right"), flattenColumns[flattenColumns.length - 1] && flattenColumns[flattenColumns.length - 1].fixed === 'right'), _classNames)), | ||
className: (0, _classnames.default)(prefixCls, className, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-ping-left"), pingedLeft), "".concat(prefixCls, "-ping-right"), pingedRight), "".concat(prefixCls, "-layout-fixed"), tableLayout === 'fixed'), "".concat(prefixCls, "-fixed-header"), fixHeader), "".concat(prefixCls, "-fixed-column"), fixColumn), "".concat(prefixCls, "-fixed-column-gapped"), fixColumn && hasGapFixed), "".concat(prefixCls, "-scroll-horizontal"), horizonScroll), "".concat(prefixCls, "-has-fix-left"), flattenColumns[0] && flattenColumns[0].fixed), "".concat(prefixCls, "-has-fix-right"), flattenColumns[flattenColumns.length - 1] && flattenColumns[flattenColumns.length - 1].fixed === 'right')), | ||
style: style, | ||
@@ -597,0 +596,0 @@ id: id, |
@@ -16,3 +16,2 @@ "use strict"; | ||
function renderExpandIcon(_ref) { | ||
var _classNames; | ||
var prefixCls = _ref.prefixCls, | ||
@@ -34,3 +33,3 @@ record = _ref.record, | ||
return /*#__PURE__*/React.createElement("span", { | ||
className: (0, _classnames.default)(expandClassName, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-row-expanded"), expanded), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-row-collapsed"), !expanded), _classNames)), | ||
className: (0, _classnames.default)(expandClassName, (0, _defineProperty2.default)((0, _defineProperty2.default)({}, "".concat(prefixCls, "-row-expanded"), expanded), "".concat(prefixCls, "-row-collapsed"), !expanded)), | ||
onClick: onClick | ||
@@ -37,0 +36,0 @@ }); |
@@ -84,2 +84,3 @@ "use strict"; | ||
var rowNode = /*#__PURE__*/React.createElement(RowComponent, (0, _extends2.default)({}, rowProps, restProps, { | ||
"data-row-key": rowKey, | ||
ref: rowSupportExpand ? null : ref, | ||
@@ -86,0 +87,0 @@ className: (0, _classnames.default)(className, "".concat(prefixCls, "-row"), rowProps === null || rowProps === void 0 ? void 0 : rowProps.className, (0, _defineProperty2.default)({}, "".concat(prefixCls, "-row-extra"), extra)), |
{ | ||
"name": "rc-table", | ||
"version": "7.45.3", | ||
"version": "7.45.4", | ||
"description": "table ui component for react", | ||
@@ -5,0 +5,0 @@ "engines": { |
398378
8829
1
9
0
38