@progress/kendo-react-pivotgrid 6.1.1 → 7.0.0-develop.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +1 -1
- package/{dist/npm/PivotGrid.d.ts → PivotGrid.d.ts} +4 -0
- package/{dist/es/components → components}/AxesEditor.d.ts +4 -6
- package/{dist/npm/components → components}/AxisEditor.d.ts +4 -0
- package/{dist/es/components → components}/AxisFilterFieldsEditor.d.ts +4 -0
- package/{dist/npm/components → components}/Cell.d.ts +4 -0
- package/{dist/es/components → components}/Column.d.ts +4 -0
- package/{dist/npm/components → components}/Configurator.d.ts +4 -0
- package/{dist/npm/components → components}/ConfiguratorButton.d.ts +4 -0
- package/{dist/es/components → components}/ConfiguratorEditor.d.ts +4 -0
- package/{dist/es/components → components}/Container.d.ts +4 -0
- package/components/EditorContext.d.ts +11 -0
- package/{dist/npm/components → components}/FieldsEditor.d.ts +4 -0
- package/{dist/es/components → components}/HeaderCell.d.ts +4 -0
- package/{dist/es/components → components}/Row.d.ts +4 -0
- package/dist/cdn/js/kendo-react-pivotgrid.js +5 -2
- package/hooks/index.d.ts +6 -0
- package/{dist/es/hooks → hooks}/useExpansion.d.ts +5 -1
- package/{dist/es/hooks → hooks}/useHeaders.d.ts +5 -1
- package/hooks/useHorizontalScrollSync.d.ts +9 -0
- package/{dist/es/hooks → hooks}/usePivotConfiguratorEditor.d.ts +5 -1
- package/{dist/npm/hooks → hooks}/usePivotLocalDataService.d.ts +4 -0
- package/{dist/npm/hooks → hooks}/usePivotOLAPService.d.ts +4 -0
- package/hooks/useVerticalScrollSync.d.ts +9 -0
- package/index.d.ts +22 -0
- package/index.js +5 -0
- package/index.mjs +1585 -0
- package/{dist/es/messages → messages}/index.d.ts +4 -0
- package/{dist/es/models → models}/index.d.ts +4 -1
- package/package-metadata.d.ts +9 -0
- package/package.json +36 -54
- package/{dist/es/shared → shared}/PivotGridConfiguratorEditorEventsContext.d.ts +4 -0
- package/{dist/npm/shared → shared}/PivotGridConfiguratorEditorStateContext.d.ts +4 -0
- package/shared/index.d.ts +6 -0
- package/{dist/es/utils → utils}/index.d.ts +4 -0
- package/about.md +0 -3
- package/dist/cdn/js/kendo-react-pivotgrid.js.LICENSE.txt +0 -14
- package/dist/es/PivotGrid.d.ts +0 -177
- package/dist/es/PivotGrid.js +0 -245
- package/dist/es/components/AxesEditor.js +0 -43
- package/dist/es/components/AxisEditor.d.ts +0 -52
- package/dist/es/components/AxisEditor.js +0 -138
- package/dist/es/components/AxisFilterFieldsEditor.js +0 -150
- package/dist/es/components/Cell.d.ts +0 -65
- package/dist/es/components/Cell.js +0 -31
- package/dist/es/components/Column.js +0 -33
- package/dist/es/components/Configurator.d.ts +0 -125
- package/dist/es/components/Configurator.js +0 -118
- package/dist/es/components/ConfiguratorButton.d.ts +0 -40
- package/dist/es/components/ConfiguratorButton.js +0 -39
- package/dist/es/components/ConfiguratorEditor.js +0 -191
- package/dist/es/components/Container.js +0 -22
- package/dist/es/components/FieldsEditor.d.ts +0 -74
- package/dist/es/components/FieldsEditor.js +0 -90
- package/dist/es/components/HeaderCell.js +0 -50
- package/dist/es/components/Row.js +0 -28
- package/dist/es/hooks/index.d.ts +0 -2
- package/dist/es/hooks/index.js +0 -2
- package/dist/es/hooks/useExpansion.js +0 -89
- package/dist/es/hooks/useHeaders.js +0 -25
- package/dist/es/hooks/useHorizontalScrollSync.d.ts +0 -5
- package/dist/es/hooks/useHorizontalScrollSync.js +0 -27
- package/dist/es/hooks/usePivotConfiguratorEditor.js +0 -103
- package/dist/es/hooks/usePivotLocalDataService.d.ts +0 -79
- package/dist/es/hooks/usePivotLocalDataService.js +0 -105
- package/dist/es/hooks/usePivotOLAPService.d.ts +0 -41
- package/dist/es/hooks/usePivotOLAPService.js +0 -371
- package/dist/es/hooks/useVerticalScrollSync.d.ts +0 -5
- package/dist/es/hooks/useVerticalScrollSync.js +0 -27
- package/dist/es/main.d.ts +0 -18
- package/dist/es/main.js +0 -17
- package/dist/es/messages/index.js +0 -71
- package/dist/es/models/index.js +0 -1
- package/dist/es/package-metadata.d.ts +0 -5
- package/dist/es/package-metadata.js +0 -11
- package/dist/es/shared/PivotGridConfiguratorEditorEventsContext.js +0 -5
- package/dist/es/shared/PivotGridConfiguratorEditorStateContext.d.ts +0 -6
- package/dist/es/shared/PivotGridConfiguratorEditorStateContext.js +0 -18
- package/dist/es/shared/index.d.ts +0 -2
- package/dist/es/shared/index.js +0 -2
- package/dist/es/utils/index.js +0 -118
- package/dist/npm/PivotGrid.js +0 -248
- package/dist/npm/components/AxesEditor.d.ts +0 -46
- package/dist/npm/components/AxesEditor.js +0 -46
- package/dist/npm/components/AxisEditor.js +0 -141
- package/dist/npm/components/AxisFilterFieldsEditor.d.ts +0 -114
- package/dist/npm/components/AxisFilterFieldsEditor.js +0 -153
- package/dist/npm/components/Cell.js +0 -34
- package/dist/npm/components/Column.d.ts +0 -42
- package/dist/npm/components/Column.js +0 -36
- package/dist/npm/components/Configurator.js +0 -121
- package/dist/npm/components/ConfiguratorButton.js +0 -42
- package/dist/npm/components/ConfiguratorEditor.d.ts +0 -126
- package/dist/npm/components/ConfiguratorEditor.js +0 -194
- package/dist/npm/components/Container.d.ts +0 -46
- package/dist/npm/components/Container.js +0 -25
- package/dist/npm/components/FieldsEditor.js +0 -93
- package/dist/npm/components/HeaderCell.d.ts +0 -96
- package/dist/npm/components/HeaderCell.js +0 -53
- package/dist/npm/components/Row.d.ts +0 -50
- package/dist/npm/components/Row.js +0 -31
- package/dist/npm/hooks/index.d.ts +0 -2
- package/dist/npm/hooks/index.js +0 -18
- package/dist/npm/hooks/useExpansion.d.ts +0 -19
- package/dist/npm/hooks/useExpansion.js +0 -93
- package/dist/npm/hooks/useHeaders.d.ts +0 -12
- package/dist/npm/hooks/useHeaders.js +0 -30
- package/dist/npm/hooks/useHorizontalScrollSync.d.ts +0 -5
- package/dist/npm/hooks/useHorizontalScrollSync.js +0 -31
- package/dist/npm/hooks/usePivotConfiguratorEditor.d.ts +0 -83
- package/dist/npm/hooks/usePivotConfiguratorEditor.js +0 -107
- package/dist/npm/hooks/usePivotLocalDataService.js +0 -110
- package/dist/npm/hooks/usePivotOLAPService.js +0 -376
- package/dist/npm/hooks/useVerticalScrollSync.d.ts +0 -5
- package/dist/npm/hooks/useVerticalScrollSync.js +0 -31
- package/dist/npm/main.d.ts +0 -18
- package/dist/npm/main.js +0 -43
- package/dist/npm/messages/index.d.ts +0 -70
- package/dist/npm/messages/index.js +0 -74
- package/dist/npm/models/index.d.ts +0 -45
- package/dist/npm/models/index.js +0 -2
- package/dist/npm/package-metadata.d.ts +0 -5
- package/dist/npm/package-metadata.js +0 -14
- package/dist/npm/shared/PivotGridConfiguratorEditorEventsContext.d.ts +0 -13
- package/dist/npm/shared/PivotGridConfiguratorEditorEventsContext.js +0 -8
- package/dist/npm/shared/PivotGridConfiguratorEditorStateContext.js +0 -21
- package/dist/npm/shared/index.d.ts +0 -2
- package/dist/npm/shared/index.js +0 -18
- package/dist/npm/utils/index.d.ts +0 -47
- package/dist/npm/utils/index.js +0 -130
- package/dist/systemjs/kendo-react-pivotgrid.js +0 -1
- package/e2e-next/basic.tests.ts +0 -24
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
1
5
|
/**
|
|
2
6
|
* @hidden
|
|
3
7
|
*/
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
2
5
|
import { SortDescriptor, FilterDescriptor } from '@progress/kendo-data-query';
|
|
3
6
|
import { PivotGridField, PivotGridAxis } from '@progress/kendo-pivotgrid-common';
|
|
4
7
|
import { PivotGridHandle } from '../PivotGrid';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { PackageMetadata } from '@progress/kendo-licensing';
|
|
6
|
+
/**
|
|
7
|
+
* @hidden
|
|
8
|
+
*/
|
|
9
|
+
export declare const packageMetadata: PackageMetadata;
|
package/package.json
CHANGED
|
@@ -1,20 +1,38 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-pivotgrid",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0-develop.2",
|
|
4
4
|
"description": "React PivotGrid (also called Pivot Table) can be data-bound to an OLAP service and customized extensively. KendoReact PivotGrid package",
|
|
5
|
-
"
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
"author": "Progress",
|
|
6
|
+
"license": "SEE LICENSE IN LICENSE.md",
|
|
7
|
+
"homepage": "https://www.telerik.com/kendo-react-ui",
|
|
8
|
+
"main": "./index.js",
|
|
9
|
+
"types": "./index.d.ts",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"import": "./index.mjs",
|
|
13
|
+
"require": "./index.js"
|
|
14
|
+
}
|
|
8
15
|
},
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
+
"sideEffects": false,
|
|
17
|
+
"peerDependencies": {
|
|
18
|
+
"@progress/kendo-data-query": "^1.5.5",
|
|
19
|
+
"@progress/kendo-licensing": "^1.3.0",
|
|
20
|
+
"@progress/kendo-pivotgrid-common": "0.5.3",
|
|
21
|
+
"@progress/kendo-react-buttons": "7.0.0-develop.2",
|
|
22
|
+
"@progress/kendo-react-common": "7.0.0-develop.2",
|
|
23
|
+
"@progress/kendo-react-data-tools": "7.0.0-develop.2",
|
|
24
|
+
"@progress/kendo-react-form": "7.0.0-develop.2",
|
|
25
|
+
"@progress/kendo-react-indicators": "7.0.0-develop.2",
|
|
26
|
+
"@progress/kendo-react-intl": "7.0.0-develop.2",
|
|
27
|
+
"@progress/kendo-react-labels": "7.0.0-develop.2",
|
|
28
|
+
"@progress/kendo-react-treeview": "7.0.0-develop.2",
|
|
29
|
+
"@progress/kendo-svg-icons": "^2.0.0",
|
|
30
|
+
"react": "^16.8.2 || ^17.0.0 || ^18.0.0",
|
|
31
|
+
"react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0"
|
|
32
|
+
},
|
|
33
|
+
"dependencies": {
|
|
34
|
+
"prop-types": "^15.6.0"
|
|
16
35
|
},
|
|
17
|
-
"homepage": "https://www.telerik.com/kendo-react-ui?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-pivotgrid&utm_content=homepage",
|
|
18
36
|
"keywords": [
|
|
19
37
|
"Kendo UI",
|
|
20
38
|
"React",
|
|
@@ -27,51 +45,15 @@
|
|
|
27
45
|
"PivotGrid",
|
|
28
46
|
"Pivot Table"
|
|
29
47
|
],
|
|
30
|
-
"peerDependencies": {
|
|
31
|
-
"@progress/kendo-data-query": "^1.5.5",
|
|
32
|
-
"@progress/kendo-licensing": "^1.3.0",
|
|
33
|
-
"@progress/kendo-react-buttons": "^6.0.0",
|
|
34
|
-
"@progress/kendo-react-data-tools": "^6.0.0",
|
|
35
|
-
"@progress/kendo-react-form": "^6.0.0",
|
|
36
|
-
"@progress/kendo-react-indicators": "^6.0.0",
|
|
37
|
-
"@progress/kendo-react-intl": "^6.0.0",
|
|
38
|
-
"@progress/kendo-react-labels": "^6.0.0",
|
|
39
|
-
"@progress/kendo-react-treeview": "^6.0.0",
|
|
40
|
-
"@progress/kendo-svg-icons": "^2.0.0",
|
|
41
|
-
"react": "^16.8.2 || ^17.0.0 || ^18.0.0",
|
|
42
|
-
"react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0"
|
|
43
|
-
},
|
|
44
|
-
"dependencies": {
|
|
45
|
-
"@progress/kendo-pivotgrid-common": "0.5.3",
|
|
46
|
-
"@progress/kendo-react-common": "6.1.1",
|
|
47
|
-
"prop-types": "^15.6.0"
|
|
48
|
-
},
|
|
49
|
-
"devDependencies": {
|
|
50
|
-
"@progress/kendo-data-query": "^1.5.5",
|
|
51
|
-
"@progress/kendo-date-math": "^1.5.2",
|
|
52
|
-
"@progress/kendo-drawing": "^1.17.2",
|
|
53
|
-
"@progress/kendo-file-saver": "^1.1.1",
|
|
54
|
-
"@progress/kendo-licensing": "^1.3.0",
|
|
55
|
-
"@progress/kendo-ooxml": "^1.6.5",
|
|
56
|
-
"@progress/kendo-react-animation": "6.1.1",
|
|
57
|
-
"@progress/kendo-react-buttons": "6.1.1",
|
|
58
|
-
"@progress/kendo-react-charts": "6.1.1",
|
|
59
|
-
"@progress/kendo-react-data-tools": "6.1.1",
|
|
60
|
-
"@progress/kendo-react-form": "6.1.1",
|
|
61
|
-
"@progress/kendo-react-indicators": "6.1.1",
|
|
62
|
-
"@progress/kendo-react-intl": "6.1.1",
|
|
63
|
-
"@progress/kendo-react-labels": "6.1.1",
|
|
64
|
-
"@progress/kendo-react-treeview": "6.1.1",
|
|
65
|
-
"@progress/kendo-svg-icons": "^2.0.0"
|
|
66
|
-
},
|
|
67
48
|
"@progress": {
|
|
68
49
|
"friendlyName": "PivotGrid",
|
|
69
50
|
"framework": "KendoReact"
|
|
70
51
|
},
|
|
71
|
-
"
|
|
72
|
-
|
|
52
|
+
"repository": {
|
|
53
|
+
"type": "git",
|
|
54
|
+
"url": "git+https://github.com/telerik/kendo-react.git"
|
|
55
|
+
},
|
|
73
56
|
"publishConfig": {
|
|
74
57
|
"access": "public"
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
1
5
|
import * as React from 'react';
|
|
2
6
|
import { PivotGridAxisFilterFieldsExpandChangeEvent, PivotGridAxisFilterFieldExpandEvent } from '../components/AxisFilterFieldsEditor';
|
|
3
7
|
/**
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
1
5
|
import * as React from 'react';
|
|
2
6
|
import { PivotGridConfiguratorAction, PivotGridConfiguratorEditorState } from '../hooks/usePivotConfiguratorEditor';
|
|
3
7
|
/**
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
export * from './PivotGridConfiguratorEditorEventsContext';
|
|
6
|
+
export * from './PivotGridConfiguratorEditorStateContext';
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
1
5
|
import { AxisDescriptor, PivotDataItem, PivotGridField, Tuple } from '@progress/kendo-pivotgrid-common';
|
|
2
6
|
/**
|
|
3
7
|
* Generates suitable data for Charting visualization.
|
package/about.md
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
<a href="https://www.telerik.com/kendo-react-ui?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid&utm_content=banner" target="_blank">
|
|
2
|
-
<img src="https://www.telerik.com/kendo-react-ui/components/npm-banner.svg" alt="KendoReact NPM Banner">
|
|
3
|
-
</a>
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/*! *****************************************************************************
|
|
2
|
-
Copyright (c) Microsoft Corporation.
|
|
3
|
-
|
|
4
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
5
|
-
purpose with or without fee is hereby granted.
|
|
6
|
-
|
|
7
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
8
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
9
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
10
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
11
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
12
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
13
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
14
|
-
***************************************************************************** */
|
package/dist/es/PivotGrid.d.ts
DELETED
|
@@ -1,177 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { PivotGridRowProps } from './components/Row';
|
|
3
|
-
import { PivotGridCellProps } from './components/Cell';
|
|
4
|
-
import { PivotGridHeaderCellProps } from './components/HeaderCell';
|
|
5
|
-
import { PivotGridColumnProps } from './components/Column';
|
|
6
|
-
import { CustomComponent } from '@progress/kendo-react-common';
|
|
7
|
-
import { PivotGridAxis, PivotDataItem, Tuple, AxisRow } from '@progress/kendo-pivotgrid-common';
|
|
8
|
-
import { PivotGridAxesChangeEvent } from './models';
|
|
9
|
-
/**
|
|
10
|
-
* Represents the props of the [KendoReact PivotGrid component]({% slug api_pivotgrid_pivotgrid %}).
|
|
11
|
-
*/
|
|
12
|
-
export interface PivotGridProps {
|
|
13
|
-
/**
|
|
14
|
-
* Sets the `style` property of the top-most element of the PivotGrid.
|
|
15
|
-
*/
|
|
16
|
-
style?: React.CSSProperties;
|
|
17
|
-
/**
|
|
18
|
-
* Sets the `className` property of the top-most element of the PivotGrid in addition to the default `k-pivotgrid` class.
|
|
19
|
-
*/
|
|
20
|
-
className?: string;
|
|
21
|
-
/**
|
|
22
|
-
* Sets the `id` property of the top-most element of the PivotGrid.
|
|
23
|
-
*/
|
|
24
|
-
id?: string;
|
|
25
|
-
/**
|
|
26
|
-
* Sets the `tabIndex` property of the top-most element of the PivotGrid.
|
|
27
|
-
*/
|
|
28
|
-
tabIndex?: number;
|
|
29
|
-
/**
|
|
30
|
-
* If set to `true`, the user can use dedicated shortcuts to interact with the PivotGrid.
|
|
31
|
-
* By default, navigation is disabled.
|
|
32
|
-
*/
|
|
33
|
-
navigatable?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Sets the `data` of the PivotGrid.
|
|
36
|
-
*/
|
|
37
|
-
data?: PivotDataItem[];
|
|
38
|
-
/**
|
|
39
|
-
* Sets the `columns` data of the PivotGrid.
|
|
40
|
-
*/
|
|
41
|
-
columns?: Tuple[];
|
|
42
|
-
/**
|
|
43
|
-
* Sets the `rows` data of the PivotGrid.
|
|
44
|
-
*/
|
|
45
|
-
rows?: Tuple[];
|
|
46
|
-
/**
|
|
47
|
-
* The configuration of the `column` axes.
|
|
48
|
-
*/
|
|
49
|
-
columnAxes?: PivotGridAxis[];
|
|
50
|
-
/**
|
|
51
|
-
* A callback, fired whenever the `columnAxes` property should change.
|
|
52
|
-
*/
|
|
53
|
-
onColumnAxesChange?: (event: PivotGridAxesChangeEvent) => void;
|
|
54
|
-
/**
|
|
55
|
-
* The configuration of the `row` axes.
|
|
56
|
-
*/
|
|
57
|
-
rowAxes?: PivotGridAxis[];
|
|
58
|
-
/**
|
|
59
|
-
* A callback, fired whenever the `rowAxes` property should change.
|
|
60
|
-
*/
|
|
61
|
-
onRowAxesChange?: (event: PivotGridAxesChangeEvent) => void;
|
|
62
|
-
/**
|
|
63
|
-
* Overrides the default `row` component.
|
|
64
|
-
*
|
|
65
|
-
* The default component is: [PivotGridRow]({% slug api_pivotgrid_pivotgridrow %}).
|
|
66
|
-
*
|
|
67
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
68
|
-
*/
|
|
69
|
-
row?: CustomComponent<PivotGridRowProps>;
|
|
70
|
-
/**
|
|
71
|
-
* Overrides the default `column` component.
|
|
72
|
-
*
|
|
73
|
-
* The default component is: [PivotGridColumn]({% slug api_pivotgrid_pivotgridcolumn %}).
|
|
74
|
-
*
|
|
75
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
76
|
-
*/
|
|
77
|
-
column?: CustomComponent<PivotGridColumnProps>;
|
|
78
|
-
/**
|
|
79
|
-
* Overrides the default `cell` component.
|
|
80
|
-
*
|
|
81
|
-
* The default component is: [PivotGridCell]({% slug api_pivotgrid_pivotgridcell %}).
|
|
82
|
-
*
|
|
83
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
84
|
-
*/
|
|
85
|
-
cell?: CustomComponent<PivotGridCellProps>;
|
|
86
|
-
/**
|
|
87
|
-
* Overrides the default `headerCell` component.
|
|
88
|
-
*
|
|
89
|
-
* The default component is: [PivotGridHeaderCell]({% slug api_pivotgrid_pivotgridheadercell %}).
|
|
90
|
-
*
|
|
91
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
92
|
-
*/
|
|
93
|
-
headerCell?: CustomComponent<PivotGridHeaderCellProps>;
|
|
94
|
-
/**
|
|
95
|
-
* Overrides the default column-headers `row` component.
|
|
96
|
-
*
|
|
97
|
-
* The default component is: [PivotGridRow]({% slug api_pivotgrid_pivotgridrow %}).
|
|
98
|
-
*
|
|
99
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
100
|
-
*/
|
|
101
|
-
columnHeadersRow?: React.ComponentType<PivotGridRowProps>;
|
|
102
|
-
/**
|
|
103
|
-
* Overrides the default column-headers `column` component.
|
|
104
|
-
*
|
|
105
|
-
* The default component is: [PivotGridColumn]({% slug api_pivotgrid_pivotgridcolumn %}).
|
|
106
|
-
*
|
|
107
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
108
|
-
*/
|
|
109
|
-
columnHeadersColumn?: React.ComponentType<PivotGridColumnProps>;
|
|
110
|
-
/**
|
|
111
|
-
* Overrides the default column-headers `headerCell` component.
|
|
112
|
-
*
|
|
113
|
-
* The default component is: [PivotGridHeaderCell]({% slug api_pivotgrid_pivotgridheadercell %}).
|
|
114
|
-
*
|
|
115
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
116
|
-
*/
|
|
117
|
-
columnHeadersCell?: React.ComponentType<PivotGridHeaderCellProps>;
|
|
118
|
-
/**
|
|
119
|
-
* Overrides the default row-headers `row` component.
|
|
120
|
-
*
|
|
121
|
-
* The default component is: [PivotGridRow]({% slug api_pivotgrid_pivotgridrow %}).
|
|
122
|
-
*
|
|
123
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
124
|
-
*/
|
|
125
|
-
rowHeadersRow?: React.ComponentType<PivotGridRowProps>;
|
|
126
|
-
/**
|
|
127
|
-
* Overrides the default row-headers `column` component.
|
|
128
|
-
*
|
|
129
|
-
* The default component is: [PivotGridColumn]({% slug api_pivotgrid_pivotgridcolumn %}).
|
|
130
|
-
*
|
|
131
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
132
|
-
*/
|
|
133
|
-
rowHeadersColumn?: React.ComponentType<PivotGridColumnProps>;
|
|
134
|
-
/**
|
|
135
|
-
* Overrides the default row-headers `headerCell` component.
|
|
136
|
-
*
|
|
137
|
-
* The default component is: [PivotGridHeaderCell]({% slug api_pivotgrid_pivotgridheadercell %}).
|
|
138
|
-
*
|
|
139
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
140
|
-
*/
|
|
141
|
-
rowHeadersCell?: React.ComponentType<PivotGridHeaderCellProps>;
|
|
142
|
-
/**
|
|
143
|
-
* Overrides the default data `row` component.
|
|
144
|
-
*
|
|
145
|
-
* The default component is: [PivotGridRow]({% slug api_pivotgrid_pivotgridrow %}).
|
|
146
|
-
*
|
|
147
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
148
|
-
*/
|
|
149
|
-
dataRow?: React.ComponentType<PivotGridRowProps>;
|
|
150
|
-
/**
|
|
151
|
-
* Overrides the default data `column` component.
|
|
152
|
-
*
|
|
153
|
-
* The default component is: [PivotGridColumn]({% slug api_pivotgrid_pivotgridcolumn %}).
|
|
154
|
-
*
|
|
155
|
-
* For more information, refer to the [PivotGrid Customization]({% slug customization_pivotgrid %}) article.
|
|
156
|
-
*/
|
|
157
|
-
dataColumn?: React.ComponentType<PivotGridColumnProps>;
|
|
158
|
-
}
|
|
159
|
-
/**
|
|
160
|
-
* Represents the object which is passed to the [`ref`](https://reactjs.org/docs/refs-and-the-dom.html) callback of the PivotGrid component.
|
|
161
|
-
*/
|
|
162
|
-
export interface PivotGridHandle {
|
|
163
|
-
element: HTMLDivElement | null;
|
|
164
|
-
props: PivotGridProps;
|
|
165
|
-
columnHeaderRows: AxisRow[];
|
|
166
|
-
rowHeaderRows: AxisRow[];
|
|
167
|
-
dataCells: {
|
|
168
|
-
row: string[];
|
|
169
|
-
cells: PivotDataItem[];
|
|
170
|
-
}[];
|
|
171
|
-
rowHeaderBreadth: number;
|
|
172
|
-
columnHeaderBreadth: number;
|
|
173
|
-
}
|
|
174
|
-
/**
|
|
175
|
-
* Represents the [KendoReact PivotGrid component]({% slug api_pivotgrid_pivotgridprops %}).
|
|
176
|
-
*/
|
|
177
|
-
export declare const PivotGrid: React.ForwardRefExoticComponent<PivotGridProps & React.RefAttributes<PivotGridHandle | null>>;
|
package/dist/es/PivotGrid.js
DELETED
|
@@ -1,245 +0,0 @@
|
|
|
1
|
-
var __assign = (this && this.__assign) || function () {
|
|
2
|
-
__assign = Object.assign || function(t) {
|
|
3
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
-
s = arguments[i];
|
|
5
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
-
t[p] = s[p];
|
|
7
|
-
}
|
|
8
|
-
return t;
|
|
9
|
-
};
|
|
10
|
-
return __assign.apply(this, arguments);
|
|
11
|
-
};
|
|
12
|
-
import * as React from 'react';
|
|
13
|
-
import { validatePackage } from '@progress/kendo-react-common';
|
|
14
|
-
import { packageMetadata } from './package-metadata';
|
|
15
|
-
import { useLocalization } from '@progress/kendo-react-intl';
|
|
16
|
-
import { messages, emptyCellAriaLabel } from './messages';
|
|
17
|
-
import { PivotGridRow } from './components/Row';
|
|
18
|
-
import { PivotGridCell } from './components/Cell';
|
|
19
|
-
import { useHeaders, HEADERS_ACTION } from './hooks/useHeaders';
|
|
20
|
-
import { PivotGridHeaderCell } from './components/HeaderCell';
|
|
21
|
-
import { useHorizontalScrollSync } from './hooks/useHorizontalScrollSync';
|
|
22
|
-
import { useVerticalScrollSync } from './hooks/useVerticalScrollSync';
|
|
23
|
-
import { PivotGridColumn } from './components/Column';
|
|
24
|
-
import { generateKey, generateDataKey } from './utils';
|
|
25
|
-
import { classNames, setScrollbarWidth, useCustomComponent } from '@progress/kendo-react-common';
|
|
26
|
-
import { toColumns, toRows, toTree, toData, PivotGridNavigation } from '@progress/kendo-pivotgrid-common';
|
|
27
|
-
/**
|
|
28
|
-
* Represents the [KendoReact PivotGrid component]({% slug api_pivotgrid_pivotgridprops %}).
|
|
29
|
-
*/
|
|
30
|
-
export var PivotGrid = React.forwardRef(function (props, ref) {
|
|
31
|
-
validatePackage(packageMetadata);
|
|
32
|
-
var _a = __assign(__assign({}, defaultProps), props), rows = _a.rows, rowAxes = _a.rowAxes, columns = _a.columns, columnAxes = _a.columnAxes, data = _a.data;
|
|
33
|
-
var element = React.useRef(null);
|
|
34
|
-
var target = React.useRef(null);
|
|
35
|
-
var rowHeadersTable = React.useRef(null);
|
|
36
|
-
var columnHeadersTable = React.useRef(null);
|
|
37
|
-
var rowHeadersContainer = React.useRef(null);
|
|
38
|
-
var columnHeadersContainer = React.useRef(null);
|
|
39
|
-
var valuesHeadersContainer = React.useRef(null);
|
|
40
|
-
var localization = useLocalization();
|
|
41
|
-
var handleRowAxesChange = function (newRowAxes, syntheticEvent) {
|
|
42
|
-
if (props.onRowAxesChange) {
|
|
43
|
-
props.onRowAxesChange({
|
|
44
|
-
value: newRowAxes,
|
|
45
|
-
target: target.current,
|
|
46
|
-
syntheticEvent: syntheticEvent
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
};
|
|
50
|
-
var handleColumnAxesChange = function (newRowAxes, syntheticEvent) {
|
|
51
|
-
if (props.onColumnAxesChange) {
|
|
52
|
-
props.onColumnAxesChange({
|
|
53
|
-
value: newRowAxes,
|
|
54
|
-
target: target.current,
|
|
55
|
-
syntheticEvent: syntheticEvent
|
|
56
|
-
});
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
var rowsTree = toTree((rows || []).slice());
|
|
60
|
-
var _b = useHeaders((rowAxes || []).slice(), rowsTree, handleRowAxesChange), dispatchRows = _b[1];
|
|
61
|
-
var _c = toRows(rowsTree), rowHeaderRows = _c[0], rowHeaderLeafs = _c[1], rowHeaderDepth = _c[2], rowHeaderBreadth = _c[3];
|
|
62
|
-
var columnsTree = toTree((columns || []).slice());
|
|
63
|
-
var _d = useHeaders((columnAxes || []).slice(), columnsTree, handleColumnAxesChange), dispatchColumns = _d[1];
|
|
64
|
-
var _e = toColumns(columnsTree), columnHeaderRows = _e[0], columnHeaderLeafs = _e[1], columnHeaderBreadth = _e[3];
|
|
65
|
-
var measures = toData((data || []).slice(), columnHeaderLeafs, rowHeaderLeafs, columnHeaderBreadth, rowHeaderDepth);
|
|
66
|
-
React.useImperativeHandle(target, function () { return ({
|
|
67
|
-
props: props,
|
|
68
|
-
element: element.current,
|
|
69
|
-
columnHeaderRows: columnHeaderRows,
|
|
70
|
-
rowHeaderRows: rowHeaderRows,
|
|
71
|
-
dataCells: measures,
|
|
72
|
-
rowHeaderBreadth: rowHeaderBreadth,
|
|
73
|
-
columnHeaderBreadth: columnHeaderBreadth
|
|
74
|
-
}); });
|
|
75
|
-
React.useImperativeHandle(ref, function () { return target.current; });
|
|
76
|
-
var dataColumns = [];
|
|
77
|
-
var rowHeaderColumns = [];
|
|
78
|
-
var columnHeadersColumns = [];
|
|
79
|
-
/* Defaults */
|
|
80
|
-
var _f = useCustomComponent(props.row || defaultProps.row), RowComponent = _f[0], RowProps = _f[1];
|
|
81
|
-
var _g = useCustomComponent(props.column || defaultProps.column), ColumnComponent = _g[0], ColumnProps = _g[1];
|
|
82
|
-
var _h = useCustomComponent(props.cell || defaultProps.cell), CellComponent = _h[0], CellProps = _h[1];
|
|
83
|
-
var _j = useCustomComponent(props.headerCell || defaultProps.headerCell), HeaderCellComponent = _j[0], HeaderCellProps = _j[1];
|
|
84
|
-
/* Advanced */
|
|
85
|
-
var ColumnHeadersRowComponent = props.columnHeadersRow || RowComponent;
|
|
86
|
-
var ColumnHeadersColumnComponent = props.columnHeadersColumn || ColumnComponent;
|
|
87
|
-
var ColumnHeadersColumnCellComponent = props.columnHeadersCell || HeaderCellComponent;
|
|
88
|
-
var RowHeadersRowComponent = props.rowHeadersRow || RowComponent;
|
|
89
|
-
var RowHeadersColumnComponent = props.rowHeadersColumn || ColumnComponent;
|
|
90
|
-
var RowHeadersCellComponent = props.rowHeadersCell || HeaderCellComponent;
|
|
91
|
-
var DataRowComponent = props.dataRow || RowComponent;
|
|
92
|
-
var DataColumnComponent = props.dataColumn || ColumnComponent;
|
|
93
|
-
for (var i = 0; i < columnHeaderLeafs.length; i++) {
|
|
94
|
-
dataColumns.push(React.createElement(DataColumnComponent, __assign({ key: String(columnHeaderLeafs[i].path) }, ColumnProps, { path: columnHeaderLeafs[i].path })));
|
|
95
|
-
columnHeadersColumns.push(React.createElement(ColumnHeadersColumnComponent, __assign({ key: String(columnHeaderLeafs[i].path) }, ColumnProps, { path: columnHeaderLeafs[i].path })));
|
|
96
|
-
}
|
|
97
|
-
for (var i = 0; i < rowHeaderBreadth; i++) {
|
|
98
|
-
rowHeaderColumns.push(React.createElement(RowHeadersColumnComponent, __assign({ key: i }, ColumnProps)));
|
|
99
|
-
}
|
|
100
|
-
var handleColumnCellClick = function (event) {
|
|
101
|
-
if (event.target.props.expandable) {
|
|
102
|
-
dispatchColumns({
|
|
103
|
-
type: HEADERS_ACTION.toggle,
|
|
104
|
-
payload: event.target.props.dataItem.path
|
|
105
|
-
}, event.syntheticEvent);
|
|
106
|
-
}
|
|
107
|
-
};
|
|
108
|
-
var handleRowCellClick = function (event) {
|
|
109
|
-
if (event.target.props.expandable) {
|
|
110
|
-
dispatchRows({
|
|
111
|
-
type: HEADERS_ACTION.toggle,
|
|
112
|
-
payload: event.target.props.dataItem.path
|
|
113
|
-
}, event.syntheticEvent);
|
|
114
|
-
}
|
|
115
|
-
};
|
|
116
|
-
var handleHorizontalScroll = useHorizontalScrollSync(valuesHeadersContainer, columnHeadersContainer);
|
|
117
|
-
var handleVerticalScroll = useVerticalScrollSync(valuesHeadersContainer, rowHeadersContainer);
|
|
118
|
-
var handleValuesContainerScroll = function (event) {
|
|
119
|
-
handleHorizontalScroll(event);
|
|
120
|
-
handleVerticalScroll(event);
|
|
121
|
-
};
|
|
122
|
-
var setRowsTemplate = React.useCallback(function () {
|
|
123
|
-
if (element.current && columnHeadersTable.current) {
|
|
124
|
-
// Reset gridTemplateRows before getting the new size
|
|
125
|
-
element.current.style.gridTemplateRows = '';
|
|
126
|
-
element.current.style.gridTemplateRows = "".concat(columnHeadersTable.current.offsetHeight, "px 1fr");
|
|
127
|
-
}
|
|
128
|
-
}, []);
|
|
129
|
-
var setColumnsTemplate = React.useCallback(function () {
|
|
130
|
-
if (element.current && rowHeadersTable.current) {
|
|
131
|
-
// Reset gridTemplateColumns before getting the new size
|
|
132
|
-
element.current.style.gridTemplateColumns = '';
|
|
133
|
-
element.current.style.gridTemplateColumns = "".concat(rowHeadersTable.current.offsetWidth, "px 1fr");
|
|
134
|
-
}
|
|
135
|
-
}, []);
|
|
136
|
-
var navigation = React.useRef(new PivotGridNavigation({ tabIndex: props.tabIndex || 0 }));
|
|
137
|
-
React.useEffect(function () {
|
|
138
|
-
if (element.current) {
|
|
139
|
-
var tabIndex = props.tabIndex || 0;
|
|
140
|
-
navigation.current.stop();
|
|
141
|
-
navigation.current.tabIndex = tabIndex;
|
|
142
|
-
if (props.navigatable) {
|
|
143
|
-
navigation.current.start(element.current);
|
|
144
|
-
var firstCell = navigation.current.first;
|
|
145
|
-
if (firstCell) {
|
|
146
|
-
firstCell.setAttribute('tabindex', String(tabIndex));
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
return function () {
|
|
151
|
-
navigation.current.stop();
|
|
152
|
-
};
|
|
153
|
-
}, [props.tabIndex, props.navigatable]);
|
|
154
|
-
React.useEffect(function () {
|
|
155
|
-
navigation.current.update();
|
|
156
|
-
});
|
|
157
|
-
React.useEffect(function () {
|
|
158
|
-
if (columnHeadersTable.current) {
|
|
159
|
-
var observer_1 = new window.ResizeObserver(setRowsTemplate);
|
|
160
|
-
observer_1.observe(columnHeadersTable.current);
|
|
161
|
-
return function () { observer_1.disconnect(); };
|
|
162
|
-
}
|
|
163
|
-
}, [setRowsTemplate]);
|
|
164
|
-
React.useEffect(function () {
|
|
165
|
-
if (rowHeadersTable.current) {
|
|
166
|
-
var observer_2 = new window.ResizeObserver(setColumnsTemplate);
|
|
167
|
-
observer_2.observe(rowHeadersTable.current);
|
|
168
|
-
return function () { observer_2.disconnect(); };
|
|
169
|
-
}
|
|
170
|
-
}, [setColumnsTemplate]);
|
|
171
|
-
React.useLayoutEffect(function () {
|
|
172
|
-
setScrollbarWidth();
|
|
173
|
-
if (rowHeadersTable.current) {
|
|
174
|
-
var observer_3 = new window.ResizeObserver(setScrollbarWidth);
|
|
175
|
-
observer_3.observe(rowHeadersTable.current);
|
|
176
|
-
return function () { observer_3.disconnect(); };
|
|
177
|
-
}
|
|
178
|
-
}, []);
|
|
179
|
-
var columnHeaderCellsIds = new Array(columnHeaderRows.length).fill([]).map(function () { return new Array(columnHeaderLeafs.length); });
|
|
180
|
-
columnHeaderRows.forEach(function (row, r) {
|
|
181
|
-
var curColSpan = 0;
|
|
182
|
-
Array.from(row.cells).forEach(function (cell) {
|
|
183
|
-
var expanded = Boolean(cell && cell.children && cell.children.length);
|
|
184
|
-
var id = (cell ? generateKey(cell.normalizedPath)
|
|
185
|
-
+ (cell.total ? '|[TOTAL]' : '')
|
|
186
|
-
+ (expanded ? '|[EXPANDED]' : '') : '').replace(/\s/g, '-');
|
|
187
|
-
if (cell) {
|
|
188
|
-
for (var colSp = 0; colSp < (cell.colSpan || 1); colSp++) {
|
|
189
|
-
for (var rowSp = 0; rowSp < (cell.rowSpan || 1); rowSp++) {
|
|
190
|
-
var ind = columnHeaderCellsIds[r + rowSp].findIndex(function (val, curInd) { return curInd >= curColSpan && !val; });
|
|
191
|
-
columnHeaderCellsIds[r + rowSp][ind] = id;
|
|
192
|
-
}
|
|
193
|
-
curColSpan++;
|
|
194
|
-
}
|
|
195
|
-
}
|
|
196
|
-
});
|
|
197
|
-
});
|
|
198
|
-
var dataCellsIds = measures.map(function (row) {
|
|
199
|
-
return row.cells.map(function (cell) { return generateDataKey(cell.rowTuple.members, cell.columnTuple.members).replace(/\s/g, '-'); });
|
|
200
|
-
});
|
|
201
|
-
return (React.createElement("div", { ref: element, id: props.id, style: props.style, tabIndex: !props.navigatable ? props.tabIndex : undefined, className: classNames('k-pivotgrid', props.className), role: "grid" },
|
|
202
|
-
React.createElement("span", { className: "k-pivotgrid-empty-cell" },
|
|
203
|
-
React.createElement("span", { className: "k-sr-only" }, localization.toLanguageString(emptyCellAriaLabel, messages[emptyCellAriaLabel]))),
|
|
204
|
-
React.createElement("div", { ref: columnHeadersContainer, className: "k-pivotgrid-column-headers", onScroll: handleHorizontalScroll },
|
|
205
|
-
React.createElement("table", { ref: columnHeadersTable, className: "k-pivotgrid-table", role: "none" },
|
|
206
|
-
React.createElement("colgroup", null, columnHeadersColumns),
|
|
207
|
-
React.createElement("tbody", { className: "k-pivotgrid-tbody", role: 'rowgroup' }, columnHeaderRows.map(function (row, r) {
|
|
208
|
-
var foundCell = false;
|
|
209
|
-
return (React.createElement(ColumnHeadersRowComponent, __assign({ key: row.name, role: "row" }, RowProps), row.cells.map(function (cell, cellIdx) {
|
|
210
|
-
var first = cellIdx !== 0 && !foundCell;
|
|
211
|
-
if (cell) {
|
|
212
|
-
foundCell = true;
|
|
213
|
-
}
|
|
214
|
-
var expanded = cell && Boolean(cell.children && cell.children.length);
|
|
215
|
-
var expandable = cell && (cell.hasChildren && (!cell.total || (cell.total && cell.parent.total)));
|
|
216
|
-
return cell
|
|
217
|
-
? (React.createElement(ColumnHeadersColumnCellComponent, __assign({}, HeaderCellProps, { key: columnHeaderCellsIds[r][cellIdx], "data-key": columnHeaderCellsIds[r][cellIdx], id: columnHeaderCellsIds[r][cellIdx], columnPath: cell.normalizedPath, rowSpan: cell.rowSpan || undefined, colSpan: cell.colSpan || undefined, onIconClick: handleColumnCellClick, dataItem: cell, expanded: expanded, expandable: expandable, total: cell.total, first: first, root: cell.levelNum === 0, role: "columnheader" }), cell.caption))
|
|
218
|
-
: null;
|
|
219
|
-
})));
|
|
220
|
-
})))),
|
|
221
|
-
React.createElement("div", { ref: rowHeadersContainer, className: "k-pivotgrid-row-headers" },
|
|
222
|
-
React.createElement("table", { ref: rowHeadersTable, className: "k-pivotgrid-table", role: "none" },
|
|
223
|
-
React.createElement("colgroup", null, rowHeaderColumns),
|
|
224
|
-
React.createElement("tbody", { className: "k-pivotgrid-tbody", role: "rowgroup" }, rowHeaderRows.map(function (row, rowId) { return (React.createElement(RowHeadersRowComponent, __assign({ key: generateKey(rowHeaderLeafs[rowId].path) }, RowProps, { path: rowHeaderLeafs[rowId].path, role: "row", ariaOwns: dataCellsIds[rowId].join(' ') }), row.cells.filter(Boolean).map(function (cell) { return cell
|
|
225
|
-
? (React.createElement(RowHeadersCellComponent, __assign({}, HeaderCellProps, { key: generateKey(cell.normalizedPath)
|
|
226
|
-
+ (cell.total ? '|[TOTAL]' : '')
|
|
227
|
-
+ (Boolean(cell.children && cell.children.length) ? '|[EXPANDED]' : ''), "data-key": generateKey(cell.normalizedPath)
|
|
228
|
-
+ (cell.total ? '|[TOTAL]' : '')
|
|
229
|
-
+ (Boolean(cell.children && cell.children.length) ? '|[EXPANDED]' : ''), rowPath: cell.normalizedPath, rowSpan: cell.rowSpan || undefined, colSpan: cell.colSpan || undefined, dataItem: cell, expanded: Boolean(cell.children && cell.children.length), expandable: cell.hasChildren && !cell.total, total: cell.total, onIconClick: handleRowCellClick, root: cell.levelNum === 0, role: "rowheader" }), cell.caption))
|
|
230
|
-
: null; }))); })))),
|
|
231
|
-
React.createElement("div", { ref: valuesHeadersContainer, className: "k-pivotgrid-values", onScroll: handleValuesContainerScroll },
|
|
232
|
-
React.createElement("table", { className: "k-pivotgrid-table", role: "none" },
|
|
233
|
-
React.createElement("colgroup", null, dataColumns),
|
|
234
|
-
React.createElement("tbody", { className: "k-pivotgrid-tbody", role: "none" }, measures.map(function (row, rowId) { return (React.createElement(DataRowComponent, __assign({ key: generateKey(rowHeaderLeafs[rowId].path) }, RowProps, { path: rowHeaderLeafs[rowId].path, role: "none" }), row.cells.map(function (cell, cellId) { return (React.createElement(CellComponent, __assign({ key: dataCellsIds[rowId][cellId], "data-key": dataCellsIds[rowId][cellId], id: dataCellsIds[rowId][cellId] }, CellProps, { rowPath: cell.rowTuple.members.map(function (m) { return m.name; }), columnPath: cell.columnTuple.members.map(function (m) { return m.name; }), dataItem: cell, total: rowHeaderLeafs[rowId].total || columnHeaderLeafs[cellId].total, role: "gridcell", ariaDescribedby: columnHeaderCellsIds.map(function (r) { return r[cellId]; }).join(' ') }), (cell && cell.data && cell.data.fmtValue) ? cell.data.fmtValue : '\u00A0')); }))); }))))));
|
|
235
|
-
});
|
|
236
|
-
var defaultProps = {
|
|
237
|
-
rowAxes: [],
|
|
238
|
-
columnAxes: [],
|
|
239
|
-
data: [],
|
|
240
|
-
row: PivotGridRow,
|
|
241
|
-
column: PivotGridColumn,
|
|
242
|
-
cell: PivotGridCell,
|
|
243
|
-
headerCell: PivotGridHeaderCell
|
|
244
|
-
};
|
|
245
|
-
PivotGrid.displayName = 'KendoReactPivotGrid';
|