test aplicar props de header styles y header classes
This commit is contained in:
parent
f406acc490
commit
21d8b114b6
@ -92,6 +92,13 @@ function makeRenderer() {
|
|||||||
var colKeys = pivotData.getColKeys();
|
var colKeys = pivotData.getColKeys();
|
||||||
var grandTotalAggregator = pivotData.getAggregator([], []);
|
var grandTotalAggregator = pivotData.getAggregator([], []);
|
||||||
|
|
||||||
|
var getStylesHeaders = function getStylesHeaders() {
|
||||||
|
return _this2.props.stylesHeaders;
|
||||||
|
};
|
||||||
|
var getHeaderClass = function getHeaderClass() {
|
||||||
|
return _this2.props.headerClass;
|
||||||
|
};
|
||||||
|
|
||||||
var valueCellColors = function valueCellColors() {};
|
var valueCellColors = function valueCellColors() {};
|
||||||
var rowTotalColors = function rowTotalColors() {};
|
var rowTotalColors = function rowTotalColors() {};
|
||||||
var colTotalColors = function colTotalColors() {};
|
var colTotalColors = function colTotalColors() {};
|
||||||
@ -229,9 +236,10 @@ function makeRenderer() {
|
|||||||
return _react2.default.createElement(
|
return _react2.default.createElement(
|
||||||
'th',
|
'th',
|
||||||
{
|
{
|
||||||
className: 'pvtColLabel',
|
className: 'pvtColLabel ' + getHeaderClass(),
|
||||||
key: 'colKey' + i,
|
key: 'colKey' + i,
|
||||||
colSpan: x,
|
colSpan: x,
|
||||||
|
style: getStylesHeaders(),
|
||||||
rowSpan: j === colAttrs.length - 1 && rowAttrs.length !== 0 ? 2 : 1
|
rowSpan: j === colAttrs.length - 1 && rowAttrs.length !== 0 ? 2 : 1
|
||||||
},
|
},
|
||||||
colKey[j]
|
colKey[j]
|
||||||
@ -240,10 +248,11 @@ function makeRenderer() {
|
|||||||
j === 0 && _react2.default.createElement(
|
j === 0 && _react2.default.createElement(
|
||||||
'th',
|
'th',
|
||||||
{
|
{
|
||||||
className: 'pvtTotalLabel',
|
className: 'pvtTotalLabel ' + getHeaderClass(),
|
||||||
|
style: getStylesHeaders(),
|
||||||
rowSpan: colAttrs.length + (rowAttrs.length === 0 ? 0 : 1)
|
rowSpan: colAttrs.length + (rowAttrs.length === 0 ? 0 : 1)
|
||||||
},
|
},
|
||||||
'Totals'
|
'Total'
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
@ -253,14 +262,14 @@ function makeRenderer() {
|
|||||||
rowAttrs.map(function (r, i) {
|
rowAttrs.map(function (r, i) {
|
||||||
return _react2.default.createElement(
|
return _react2.default.createElement(
|
||||||
'th',
|
'th',
|
||||||
{ className: 'pvtAxisLabel', key: 'rowAttr' + i },
|
{ className: 'pvtAxisLabel ' + getHeaderClass(), key: 'rowAttr' + i, style: getStylesHeaders() },
|
||||||
r
|
r
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
_react2.default.createElement(
|
_react2.default.createElement(
|
||||||
'th',
|
'th',
|
||||||
{ className: 'pvtTotalLabel' },
|
{ className: 'pvtTotalLabel ' + getHeaderClass(), style: getStylesHeaders() },
|
||||||
colAttrs.length === 0 ? 'Totals' : null
|
colAttrs.length === 0 ? 'Total' : null
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
@ -281,7 +290,8 @@ function makeRenderer() {
|
|||||||
'th',
|
'th',
|
||||||
{
|
{
|
||||||
key: 'rowKeyLabel' + i + '-' + j,
|
key: 'rowKeyLabel' + i + '-' + j,
|
||||||
className: 'pvtRowLabel',
|
className: 'pvtRowLabel ' + getHeaderClass(),
|
||||||
|
style: getStylesHeaders(),
|
||||||
rowSpan: x,
|
rowSpan: x,
|
||||||
colSpan: j === rowAttrs.length - 1 && colAttrs.length !== 0 ? 2 : 1
|
colSpan: j === rowAttrs.length - 1 && colAttrs.length !== 0 ? 2 : 1
|
||||||
},
|
},
|
||||||
|
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "v-react-pivottable",
|
"name": "v-react-pivottable",
|
||||||
"version": "0.11.14",
|
"version": "0.11.15",
|
||||||
"description": "A React-based pivot table",
|
"description": "A React-based pivot table",
|
||||||
"main": "PivotTableUI.js",
|
"main": "PivotTableUI.js",
|
||||||
"files": [
|
"files": [
|
||||||
|
Loading…
Reference in New Issue
Block a user