@patternfly/react-table 6.0.0-alpha.1 → 6.0.0-alpha.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/CHANGELOG.md +136 -0
- package/README.md +2 -2
- package/components/package.json +1 -1
- package/deprecated/package.json +1 -1
- package/dist/dynamic/components/Table/package.json +1 -1
- package/dist/dynamic/components/Table/utils/decorators/package.json +1 -1
- package/dist/dynamic/components/Table/utils/package.json +1 -1
- package/dist/dynamic/deprecated/components/Table/base/package.json +1 -1
- package/dist/dynamic/deprecated/components/Table/package.json +1 -1
- package/dist/dynamic/deprecated/components/package.json +1 -1
- package/dist/esm/components/Table/ActionsColumn.d.ts +1 -1
- package/dist/esm/components/Table/ActionsColumn.d.ts.map +1 -1
- package/dist/esm/components/Table/RowWrapper.d.ts +1 -1
- package/dist/esm/components/Table/Table.d.ts +1 -1
- package/dist/esm/components/Table/Table.d.ts.map +1 -1
- package/dist/esm/components/Table/Table.js +2 -2
- package/dist/esm/components/Table/Table.js.map +1 -1
- package/dist/esm/components/Table/Tbody.d.ts +1 -1
- package/dist/esm/components/Table/Tbody.d.ts.map +1 -1
- package/dist/esm/components/Table/Td.d.ts +1 -1
- package/dist/esm/components/Table/Td.d.ts.map +1 -1
- package/dist/esm/components/Table/Td.js +7 -3
- package/dist/esm/components/Table/Td.js.map +1 -1
- package/dist/esm/components/Table/Th.d.ts +1 -1
- package/dist/esm/components/Table/Th.d.ts.map +1 -1
- package/dist/esm/components/Table/Th.js +4 -1
- package/dist/esm/components/Table/Th.js.map +1 -1
- package/dist/esm/components/Table/Thead.d.ts +1 -1
- package/dist/esm/components/Table/Thead.d.ts.map +1 -1
- package/dist/esm/components/Table/Tr.d.ts +2 -2
- package/dist/esm/components/Table/Tr.d.ts.map +1 -1
- package/dist/esm/components/Table/base/provider.d.ts +8 -8
- package/dist/esm/components/Table/base/types.d.ts +7 -7
- package/dist/esm/components/Table/utils/decorators/treeRow.d.ts +3 -3
- package/dist/esm/components/Table/utils/decorators/treeRow.d.ts.map +1 -1
- package/dist/esm/components/Table/utils/decorators/treeRow.js +3 -3
- package/dist/esm/components/Table/utils/decorators/treeRow.js.map +1 -1
- package/dist/esm/deprecated/components/Table/Body.d.ts +1 -1
- package/dist/esm/deprecated/components/Table/Body.d.ts.map +1 -1
- package/dist/esm/deprecated/components/Table/Table.d.ts +1 -1
- package/dist/esm/deprecated/components/Table/base/body.d.ts +8 -2
- package/dist/esm/deprecated/components/Table/base/body.d.ts.map +1 -1
- package/dist/esm/deprecated/components/Table/base/header.d.ts +1 -1
- package/dist/esm/deprecated/components/Table/base/header.d.ts.map +1 -1
- package/dist/js/components/Table/ActionsColumn.d.ts +1 -1
- package/dist/js/components/Table/ActionsColumn.d.ts.map +1 -1
- package/dist/js/components/Table/ActionsColumn.js +6 -6
- package/dist/js/components/Table/ActionsColumn.js.map +1 -1
- package/dist/js/components/Table/CollapseColumn.js +2 -2
- package/dist/js/components/Table/CollapseColumn.js.map +1 -1
- package/dist/js/components/Table/DraggableCell.js +2 -2
- package/dist/js/components/Table/DraggableCell.js.map +1 -1
- package/dist/js/components/Table/EditColumn.js +4 -4
- package/dist/js/components/Table/EditColumn.js.map +1 -1
- package/dist/js/components/Table/EditableSelectInputCell.js +1 -1
- package/dist/js/components/Table/EditableSelectInputCell.js.map +1 -1
- package/dist/js/components/Table/EditableTextCell.js +1 -1
- package/dist/js/components/Table/EditableTextCell.js.map +1 -1
- package/dist/js/components/Table/FavoritesCell.js +2 -2
- package/dist/js/components/Table/FavoritesCell.js.map +1 -1
- package/dist/js/components/Table/HeaderCellInfoWrapper.js +4 -4
- package/dist/js/components/Table/HeaderCellInfoWrapper.js.map +1 -1
- package/dist/js/components/Table/RowWrapper.d.ts +1 -1
- package/dist/js/components/Table/RowWrapper.js +2 -1
- package/dist/js/components/Table/RowWrapper.js.map +1 -1
- package/dist/js/components/Table/SortColumn.js +3 -3
- package/dist/js/components/Table/SortColumn.js.map +1 -1
- package/dist/js/components/Table/Table.d.ts +1 -1
- package/dist/js/components/Table/Table.d.ts.map +1 -1
- package/dist/js/components/Table/Table.js +2 -2
- package/dist/js/components/Table/Table.js.map +1 -1
- package/dist/js/components/Table/TableText.js +1 -1
- package/dist/js/components/Table/TableText.js.map +1 -1
- package/dist/js/components/Table/TableTypes.js +4 -0
- package/dist/js/components/Table/TableTypes.js.map +1 -1
- package/dist/js/components/Table/Tbody.d.ts +1 -1
- package/dist/js/components/Table/Tbody.d.ts.map +1 -1
- package/dist/js/components/Table/Td.d.ts +1 -1
- package/dist/js/components/Table/Td.d.ts.map +1 -1
- package/dist/js/components/Table/Td.js +8 -4
- package/dist/js/components/Table/Td.js.map +1 -1
- package/dist/js/components/Table/Th.d.ts +1 -1
- package/dist/js/components/Table/Th.d.ts.map +1 -1
- package/dist/js/components/Table/Th.js +5 -2
- package/dist/js/components/Table/Th.js.map +1 -1
- package/dist/js/components/Table/Thead.d.ts +1 -1
- package/dist/js/components/Table/Thead.d.ts.map +1 -1
- package/dist/js/components/Table/Tr.d.ts +2 -2
- package/dist/js/components/Table/Tr.d.ts.map +1 -1
- package/dist/js/components/Table/Tr.js +1 -1
- package/dist/js/components/Table/Tr.js.map +1 -1
- package/dist/js/components/Table/base/provider.d.ts +8 -8
- package/dist/js/components/Table/base/types.d.ts +7 -7
- package/dist/js/components/Table/base/types.js +4 -0
- package/dist/js/components/Table/base/types.js.map +1 -1
- package/dist/js/components/Table/utils/decorators/sortable.js +1 -1
- package/dist/js/components/Table/utils/decorators/sortable.js.map +1 -1
- package/dist/js/components/Table/utils/decorators/treeRow.d.ts +3 -3
- package/dist/js/components/Table/utils/decorators/treeRow.d.ts.map +1 -1
- package/dist/js/components/Table/utils/decorators/treeRow.js +7 -7
- package/dist/js/components/Table/utils/decorators/treeRow.js.map +1 -1
- package/dist/js/deprecated/components/Table/Body.d.ts +1 -1
- package/dist/js/deprecated/components/Table/Body.d.ts.map +1 -1
- package/dist/js/deprecated/components/Table/BodyCell.js +4 -3
- package/dist/js/deprecated/components/Table/BodyCell.js.map +1 -1
- package/dist/js/deprecated/components/Table/Table.d.ts +1 -1
- package/dist/js/deprecated/components/Table/Table.js +1 -1
- package/dist/js/deprecated/components/Table/Table.js.map +1 -1
- package/dist/js/deprecated/components/Table/base/body.d.ts +8 -2
- package/dist/js/deprecated/components/Table/base/body.d.ts.map +1 -1
- package/dist/js/deprecated/components/Table/base/header.d.ts +1 -1
- package/dist/js/deprecated/components/Table/base/header.d.ts.map +1 -1
- package/dist/umd/react-table.min.js +9 -9
- package/package.json +6 -6
- package/src/components/Table/Table.tsx +2 -2
- package/src/components/Table/Td.tsx +10 -5
- package/src/components/Table/Th.tsx +6 -3
- package/src/components/Table/Tr.tsx +1 -1
- package/src/components/Table/examples/Table.md +3 -0
- package/src/components/Table/examples/TableCompoundExpandable.tsx +2 -1
- package/src/components/Table/examples/TableMisc.tsx +3 -1
- package/src/components/Table/examples/TableNestedHeaders.tsx +4 -3
- package/src/components/Table/examples/TableNestedStickyHeader.tsx +4 -3
- package/src/components/Table/utils/decorators/treeRow.tsx +3 -3
- package/src/components/Table/utils/transformers.test.tsx +13 -8
- package/src/deprecated/components/Table/examples/LegacyTableCompoundExpandable.tsx +4 -3
- package/src/deprecated/components/Table/examples/LegacyTableMisc.tsx +4 -3
- package/src/deprecated/components/Table/examples/LegacyTableSelectable.tsx +2 -1
- package/src/deprecated/components/Table/examples/LegacyTableStripedCustomTr.tsx +2 -6
- package/src/deprecated/components/Table/examples/Table.md +2 -0
- package/src/docs/demos/Table.md +3 -5
- package/src/docs/demos/table-demos/BulkSelect.jsx +1 -1
- package/src/docs/demos/table-demos/ColumnManagement.jsx +1 -1
- package/src/docs/demos/table-demos/Compact.jsx +1 -1
- package/src/docs/demos/table-demos/CompoundExpansion.jsx +3 -2
- package/src/docs/demos/table-demos/ExpandCollapseAll.jsx +1 -1
- package/src/docs/demos/table-demos/SortableResponsive.jsx +2 -3
- package/src/docs/demos/table-demos/StaticBottomPagination.jsx +1 -1
- package/src/docs/demos/table-demos/StickyFirstColumn.jsx +1 -1
- package/src/docs/demos/table-demos/StickyHeader.jsx +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@patternfly/react-table",
|
|
3
|
-
"version": "6.0.0-alpha.
|
|
3
|
+
"version": "6.0.0-alpha.2",
|
|
4
4
|
"description": "This library provides a set of React table components for use with the PatternFly 4",
|
|
5
5
|
"main": "dist/js/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -40,10 +40,10 @@
|
|
|
40
40
|
"subpaths": "node ../../scripts/exportSubpaths.js --config subpaths.config.json"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@patternfly/react-core": "^6.0.0-alpha.
|
|
44
|
-
"@patternfly/react-icons": "^6.0.0-alpha.
|
|
45
|
-
"@patternfly/react-styles": "^6.0.0-alpha.
|
|
46
|
-
"@patternfly/react-tokens": "^6.0.0-alpha.
|
|
43
|
+
"@patternfly/react-core": "^6.0.0-alpha.2",
|
|
44
|
+
"@patternfly/react-icons": "^6.0.0-alpha.2",
|
|
45
|
+
"@patternfly/react-styles": "^6.0.0-alpha.2",
|
|
46
|
+
"@patternfly/react-tokens": "^6.0.0-alpha.2",
|
|
47
47
|
"lodash": "^4.17.19",
|
|
48
48
|
"tslib": "^2.5.0"
|
|
49
49
|
},
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"react": "^17 || ^18",
|
|
56
56
|
"react-dom": "^17 || ^18"
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "e097336a87fa3cd2ab41654bec28d120beed10bc"
|
|
59
59
|
}
|
|
@@ -159,8 +159,8 @@ const TableBase: React.FunctionComponent<TableProps> = ({
|
|
|
159
159
|
const handleKeys = (event: KeyboardEvent) => {
|
|
160
160
|
if (
|
|
161
161
|
isNested ||
|
|
162
|
-
!(tableRef && tableRef.current && tableRef.current.classList.contains(
|
|
163
|
-
(tableRef && tableRef.current !== (event.target as HTMLElement).closest(
|
|
162
|
+
!(tableRef && tableRef.current && tableRef.current.classList.contains(stylesTreeView.modifiers.treeView)) || // implements roving tab-index to tree tables only
|
|
163
|
+
(tableRef && tableRef.current !== (event.target as HTMLElement).closest(`.${styles.table}:not(.pf-m-nested)`))
|
|
164
164
|
) {
|
|
165
165
|
return;
|
|
166
166
|
}
|
|
@@ -2,6 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { css } from '@patternfly/react-styles';
|
|
3
3
|
import styles from '@patternfly/react-styles/css/components/Table/table';
|
|
4
4
|
import scrollStyles from '@patternfly/react-styles/css/components/Table/table-scrollable';
|
|
5
|
+
import treeViewStyles from '@patternfly/react-styles/css/components/Table/table-tree-view';
|
|
5
6
|
import { BaseCellProps } from './Table';
|
|
6
7
|
import {
|
|
7
8
|
cellActions,
|
|
@@ -28,6 +29,10 @@ import {
|
|
|
28
29
|
TdSelectType,
|
|
29
30
|
TdTreeRowType
|
|
30
31
|
} from './base/types';
|
|
32
|
+
import cssStickyCellMinWidth from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_MinWidth';
|
|
33
|
+
import cssStickyCellLeft from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_Left';
|
|
34
|
+
import cssStickyCellRight from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_Right';
|
|
35
|
+
|
|
31
36
|
export interface TdProps extends BaseCellProps, Omit<React.HTMLProps<HTMLTableDataCellElement>, 'onSelect' | 'width'> {
|
|
32
37
|
/**
|
|
33
38
|
* The column header the cell corresponds to.
|
|
@@ -253,8 +258,8 @@ const TdBase: React.FunctionComponent<TdProps> = ({
|
|
|
253
258
|
} = merged;
|
|
254
259
|
|
|
255
260
|
const treeTableTitleCell =
|
|
256
|
-
(className && className.includes(
|
|
257
|
-
(mergedClassName && mergedClassName.includes(
|
|
261
|
+
(className && className.includes(treeViewStyles.tableTreeViewTitleCell)) ||
|
|
262
|
+
(mergedClassName && mergedClassName.includes(treeViewStyles.tableTreeViewTitleCell));
|
|
258
263
|
|
|
259
264
|
React.useEffect(() => {
|
|
260
265
|
setTruncated(
|
|
@@ -288,9 +293,9 @@ const TdBase: React.FunctionComponent<TdProps> = ({
|
|
|
288
293
|
{...props}
|
|
289
294
|
{...(isStickyColumn && {
|
|
290
295
|
style: {
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
296
|
+
[cssStickyCellMinWidth.name]: stickyMinWidth ? stickyMinWidth : undefined,
|
|
297
|
+
[cssStickyCellLeft.name]: stickyLeftOffset ? stickyLeftOffset : 0,
|
|
298
|
+
[cssStickyCellRight.name]: stickyRightOffset ? stickyRightOffset : 0,
|
|
294
299
|
...props.style
|
|
295
300
|
} as React.CSSProperties
|
|
296
301
|
})}
|
|
@@ -9,6 +9,9 @@ import { IVisibility } from './utils/decorators/classNames';
|
|
|
9
9
|
import { Tooltip } from '@patternfly/react-core/dist/esm/components/Tooltip/Tooltip';
|
|
10
10
|
import { BaseCellProps } from './Table';
|
|
11
11
|
import { IFormatterValueType, IColumn } from './TableTypes';
|
|
12
|
+
import cssStickyCellMinWidth from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_MinWidth';
|
|
13
|
+
import cssStickyCellLeft from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_Left';
|
|
14
|
+
import cssStickyCellRight from '@patternfly/react-tokens/dist/esm/c_table__sticky_cell_Right';
|
|
12
15
|
|
|
13
16
|
export interface ThProps
|
|
14
17
|
extends BaseCellProps,
|
|
@@ -193,9 +196,9 @@ const ThBase: React.FunctionComponent<ThProps> = ({
|
|
|
193
196
|
{...props}
|
|
194
197
|
{...(isStickyColumn && {
|
|
195
198
|
style: {
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
+
[cssStickyCellMinWidth.name]: stickyMinWidth ? stickyMinWidth : undefined,
|
|
200
|
+
[cssStickyCellLeft.name]: stickyLeftOffset ? stickyLeftOffset : 0,
|
|
201
|
+
[cssStickyCellRight.name]: stickyRightOffset ? stickyRightOffset : 0,
|
|
199
202
|
...props.style
|
|
200
203
|
} as React.CSSProperties
|
|
201
204
|
})}
|
|
@@ -5,7 +5,7 @@ import inlineStyles from '@patternfly/react-styles/css/components/InlineEdit/inl
|
|
|
5
5
|
import { css } from '@patternfly/react-styles';
|
|
6
6
|
import { TableContext } from './Table';
|
|
7
7
|
|
|
8
|
-
export interface TrProps extends React.HTMLProps<HTMLTableRowElement>, OUIAProps {
|
|
8
|
+
export interface TrProps extends Omit<React.HTMLProps<HTMLTableRowElement>, 'onResize'>, OUIAProps {
|
|
9
9
|
/** Content rendered inside the <tr> row */
|
|
10
10
|
children?: React.ReactNode;
|
|
11
11
|
/** Additional classes added to the <tr> row */
|
|
@@ -54,6 +54,9 @@ import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-ico
|
|
|
54
54
|
|
|
55
55
|
import { css } from '@patternfly/react-styles';
|
|
56
56
|
import styles from '@patternfly/react-styles/css/components/Table/table';
|
|
57
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
58
|
+
import textStyles from '@patternfly/react-styles/css/utilities/Text/text';
|
|
59
|
+
import global_BackgroundColor_150 from '@patternfly/react-tokens/dist/esm/global_BackgroundColor_150';
|
|
57
60
|
|
|
58
61
|
## Table examples
|
|
59
62
|
|
|
@@ -4,6 +4,7 @@ import { Table, Thead, Tr, Th, Tbody, Td, TdProps, ExpandableRowContent } from '
|
|
|
4
4
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
5
5
|
import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
6
6
|
import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
7
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
7
8
|
|
|
8
9
|
interface Repository {
|
|
9
10
|
name: string;
|
|
@@ -110,7 +111,7 @@ export const TableCompoundExpandable: React.FunctionComponent = () => {
|
|
|
110
111
|
<Tr isExpanded={isRowExpanded}>
|
|
111
112
|
<Td dataLabel={columnNames[expandedCellKey]} noPadding colSpan={6}>
|
|
112
113
|
<ExpandableRowContent>
|
|
113
|
-
<div className=
|
|
114
|
+
<div className={spacing.mMd}>
|
|
114
115
|
Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem
|
|
115
116
|
ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum
|
|
116
117
|
sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit dolor. Lorem ipsum sit
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Table, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
|
|
3
|
+
/* eslint-disable camelcase */
|
|
4
|
+
import global_BackgroundColor_150 from '@patternfly/react-tokens/dist/esm/global_BackgroundColor_150';
|
|
3
5
|
|
|
4
6
|
interface Repository {
|
|
5
7
|
name: string;
|
|
@@ -65,7 +67,7 @@ export const TableMisc: React.FunctionComponent = () => {
|
|
|
65
67
|
{repositories.map((repo, rowIndex) => {
|
|
66
68
|
const isOddRow = (rowIndex + 1) % 2;
|
|
67
69
|
const customStyle = {
|
|
68
|
-
backgroundColor:
|
|
70
|
+
backgroundColor: global_BackgroundColor_150.var
|
|
69
71
|
};
|
|
70
72
|
// Some arbitrary logic to demonstrate that cell styles can be based on anything
|
|
71
73
|
const nameColSpan = repo.branches === null && repo.prs === null ? 3 : 1;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Table, Thead, Tr, Th, Tbody, Td, InnerScrollContainer, ThProps } from '@patternfly/react-table';
|
|
3
3
|
import { Stack, StackItem } from '@patternfly/react-core';
|
|
4
|
+
import textStyles from '@patternfly/react-styles/css/utilities/Text/text';
|
|
4
5
|
|
|
5
6
|
interface PodConnection {
|
|
6
7
|
source: {
|
|
@@ -162,7 +163,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
162
163
|
<Td dataLabel={columnNames.datetime}>
|
|
163
164
|
<div>
|
|
164
165
|
<span>{new Date(connection.timestamp).toDateString()}</span>{' '}
|
|
165
|
-
<span className=
|
|
166
|
+
<span className={textStyles.color_200}>{new Date(connection.timestamp).toLocaleTimeString()}</span>
|
|
166
167
|
</div>
|
|
167
168
|
</Td>
|
|
168
169
|
<Td dataLabel={columnNames.source}>
|
|
@@ -171,7 +172,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
171
172
|
<span>{connection.source.port.num}</span>
|
|
172
173
|
</StackItem>
|
|
173
174
|
<StackItem>
|
|
174
|
-
<span className=
|
|
175
|
+
<span className={textStyles.color_200}>({connection.source.port.protocol})</span>
|
|
175
176
|
</StackItem>
|
|
176
177
|
</Stack>
|
|
177
178
|
</Td>
|
|
@@ -181,7 +182,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
181
182
|
<span>{connection.destination.port.num}</span>
|
|
182
183
|
</StackItem>
|
|
183
184
|
<StackItem>
|
|
184
|
-
<span className=
|
|
185
|
+
<span className={textStyles.color_200}>({connection.destination.port.protocol})</span>
|
|
185
186
|
</StackItem>
|
|
186
187
|
</Stack>
|
|
187
188
|
</Td>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Table, Thead, Tr, Th, Tbody, Td, InnerScrollContainer, ThProps } from '@patternfly/react-table';
|
|
3
3
|
import { Stack, StackItem } from '@patternfly/react-core';
|
|
4
|
+
import textStyles from '@patternfly/react-styles/css/utilities/Text/text';
|
|
4
5
|
|
|
5
6
|
interface PodConnection {
|
|
6
7
|
source: {
|
|
@@ -165,7 +166,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
165
166
|
<Td dataLabel={columnNames.datetime}>
|
|
166
167
|
<div>
|
|
167
168
|
<span>{new Date(connection.timestamp).toDateString()}</span>{' '}
|
|
168
|
-
<span className=
|
|
169
|
+
<span className={textStyles.color_200}>{new Date(connection.timestamp).toLocaleTimeString()}</span>
|
|
169
170
|
</div>
|
|
170
171
|
</Td>
|
|
171
172
|
<Td dataLabel={columnNames.source}>
|
|
@@ -174,7 +175,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
174
175
|
<span>{connection.source.port.num}</span>
|
|
175
176
|
</StackItem>
|
|
176
177
|
<StackItem>
|
|
177
|
-
<span className=
|
|
178
|
+
<span className={textStyles.color_200}>({connection.source.port.protocol})</span>
|
|
178
179
|
</StackItem>
|
|
179
180
|
</Stack>
|
|
180
181
|
</Td>
|
|
@@ -184,7 +185,7 @@ export const TableNestedHeaders: React.FunctionComponent = () => {
|
|
|
184
185
|
<span>{connection.destination.port.num}</span>
|
|
185
186
|
</StackItem>
|
|
186
187
|
<StackItem>
|
|
187
|
-
<span className=
|
|
188
|
+
<span className={textStyles.color_200}>({connection.destination.port.protocol})</span>
|
|
188
189
|
</StackItem>
|
|
189
190
|
</Stack>
|
|
190
191
|
</Td>
|
|
@@ -31,7 +31,7 @@ export const treeRow =
|
|
|
31
31
|
{icon}
|
|
32
32
|
</span>
|
|
33
33
|
)}
|
|
34
|
-
<span className=
|
|
34
|
+
<span className={styles.tableText} key="table-text">
|
|
35
35
|
{content as React.ReactNode}
|
|
36
36
|
</span>
|
|
37
37
|
</div>
|
|
@@ -41,7 +41,7 @@ export const treeRow =
|
|
|
41
41
|
};
|
|
42
42
|
return {
|
|
43
43
|
component: 'th',
|
|
44
|
-
className:
|
|
44
|
+
className: stylesTreeView.tableTreeViewTitleCell,
|
|
45
45
|
children:
|
|
46
46
|
level !== undefined ? (
|
|
47
47
|
<div className={css(stylesTreeView.tableTreeViewMain)}>
|
|
@@ -83,7 +83,7 @@ export const treeRow =
|
|
|
83
83
|
onToggleRowDetails && onToggleRowDetails(event, rowIndex, content as React.ReactNode, rowData)
|
|
84
84
|
}
|
|
85
85
|
>
|
|
86
|
-
<span className=
|
|
86
|
+
<span className={`${styles.table}__details-toggle-icon`}>
|
|
87
87
|
<EllipsisHIcon aria-hidden />
|
|
88
88
|
</span>
|
|
89
89
|
</Button>
|
|
@@ -29,6 +29,9 @@ import {
|
|
|
29
29
|
IRowData,
|
|
30
30
|
ISeparator
|
|
31
31
|
} from '../TableTypes';
|
|
32
|
+
import { css } from '@patternfly/react-styles';
|
|
33
|
+
import tableStyles from '@patternfly/react-styles/css/components/Table/table';
|
|
34
|
+
import dropdownStyles from '@patternfly/react-styles/css/components/Dropdown/dropdown';
|
|
32
35
|
|
|
33
36
|
const testCellActions = async ({
|
|
34
37
|
actions,
|
|
@@ -65,7 +68,7 @@ const testCellActions = async ({
|
|
|
65
68
|
actions = actionResolver(rowData, extraData);
|
|
66
69
|
}
|
|
67
70
|
|
|
68
|
-
expect(returnedData).toMatchObject({ className:
|
|
71
|
+
expect(returnedData).toMatchObject({ className: tableStyles.tableAction });
|
|
69
72
|
|
|
70
73
|
if (!actions || actions.length === 0) {
|
|
71
74
|
expect(returnedData.children).toBeUndefined();
|
|
@@ -73,7 +76,9 @@ const testCellActions = async ({
|
|
|
73
76
|
const { container } = render(returnedData.children as React.ReactElement<any>);
|
|
74
77
|
await user.click(screen.getAllByRole('button')[0]);
|
|
75
78
|
await waitFor(() =>
|
|
76
|
-
expect(container.querySelectorAll(
|
|
79
|
+
expect(container.querySelectorAll(`.${dropdownStyles.dropdownMenu} li button`)).toHaveLength(
|
|
80
|
+
expectDisabled ? 0 : 1
|
|
81
|
+
)
|
|
77
82
|
);
|
|
78
83
|
}
|
|
79
84
|
};
|
|
@@ -86,7 +91,7 @@ describe('Transformer functions', () => {
|
|
|
86
91
|
extraParams: { onSelect }
|
|
87
92
|
};
|
|
88
93
|
const returnedData = selectable('', { column, rowData: {} } as IExtra);
|
|
89
|
-
expect(returnedData).toMatchObject({ className:
|
|
94
|
+
expect(returnedData).toMatchObject({ className: tableStyles.tableCheck });
|
|
90
95
|
|
|
91
96
|
const user = userEvent.setup();
|
|
92
97
|
|
|
@@ -103,7 +108,7 @@ describe('Transformer functions', () => {
|
|
|
103
108
|
extraParams: { onSelect }
|
|
104
109
|
};
|
|
105
110
|
const returnedData = selectable('', { column, rowIndex: 0, rowData: { selected: true } } as IExtra);
|
|
106
|
-
expect(returnedData).toMatchObject({ className:
|
|
111
|
+
expect(returnedData).toMatchObject({ className: tableStyles.tableCheck });
|
|
107
112
|
const user = userEvent.setup();
|
|
108
113
|
|
|
109
114
|
render(returnedData.children as React.ReactElement<any>);
|
|
@@ -128,7 +133,7 @@ describe('Transformer functions', () => {
|
|
|
128
133
|
const onSort = jest.fn();
|
|
129
134
|
const column = { extraParams: { sortBy: {}, onSort } };
|
|
130
135
|
const returnedData = sortable('', { column, columnIndex: 0 });
|
|
131
|
-
expect(returnedData).toMatchObject({ className:
|
|
136
|
+
expect(returnedData).toMatchObject({ className: tableStyles.tableSort });
|
|
132
137
|
|
|
133
138
|
const user = userEvent.setup();
|
|
134
139
|
|
|
@@ -154,7 +159,7 @@ describe('Transformer functions', () => {
|
|
|
154
159
|
const onSort = jest.fn();
|
|
155
160
|
const column = { extraParams: { sortBy: { index: 0, direction: 'desc' }, onSort } };
|
|
156
161
|
const returnedData = sortable('', { column, columnIndex: 0 } as IExtra);
|
|
157
|
-
expect(returnedData).toMatchObject({ className:
|
|
162
|
+
expect(returnedData).toMatchObject({ className: css(tableStyles.tableSort, tableStyles.modifiers.selected) });
|
|
158
163
|
|
|
159
164
|
const user = userEvent.setup();
|
|
160
165
|
|
|
@@ -226,7 +231,7 @@ describe('Transformer functions', () => {
|
|
|
226
231
|
extraParams: { onCollapse }
|
|
227
232
|
};
|
|
228
233
|
const returnedData = collapsible('', { rowIndex: 0, rowData, column });
|
|
229
|
-
expect(returnedData).toMatchObject({ className:
|
|
234
|
+
expect(returnedData).toMatchObject({ className: tableStyles.tableToggle });
|
|
230
235
|
|
|
231
236
|
const user = userEvent.setup();
|
|
232
237
|
|
|
@@ -332,7 +337,7 @@ describe('Transformer functions', () => {
|
|
|
332
337
|
extraParams: { onRowEdit }
|
|
333
338
|
};
|
|
334
339
|
const returned = editable('test', { rowIndex: 0, column });
|
|
335
|
-
expect(returned).toMatchObject({ className:
|
|
340
|
+
expect(returned).toMatchObject({ className: tableStyles.tableInlineEditAction });
|
|
336
341
|
});
|
|
337
342
|
|
|
338
343
|
describe('visibility classNames', () => {
|
|
@@ -5,6 +5,7 @@ import { compoundExpand } from '@patternfly/react-table';
|
|
|
5
5
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
6
6
|
import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
7
7
|
import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
8
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
8
9
|
|
|
9
10
|
interface Repository {
|
|
10
11
|
name: string;
|
|
@@ -117,7 +118,7 @@ export const LegacyTableCompoundExpandable: React.FunctionComponent = () => {
|
|
|
117
118
|
cells: [
|
|
118
119
|
{
|
|
119
120
|
title: (
|
|
120
|
-
<div className=
|
|
121
|
+
<div className={spacing.mMd} id={`compound-expansion-table-${repo.name}-1`}>
|
|
121
122
|
Expanded content for {repo.name}: Branches goes here!
|
|
122
123
|
</div>
|
|
123
124
|
),
|
|
@@ -132,7 +133,7 @@ export const LegacyTableCompoundExpandable: React.FunctionComponent = () => {
|
|
|
132
133
|
cells: [
|
|
133
134
|
{
|
|
134
135
|
title: (
|
|
135
|
-
<div className=
|
|
136
|
+
<div className={spacing.mMd} id={`compound-expansion-table-${repo.name}-2`}>
|
|
136
137
|
Expanded content for {repo.name}: Pull requests goes here!
|
|
137
138
|
</div>
|
|
138
139
|
),
|
|
@@ -147,7 +148,7 @@ export const LegacyTableCompoundExpandable: React.FunctionComponent = () => {
|
|
|
147
148
|
cells: [
|
|
148
149
|
{
|
|
149
150
|
title: (
|
|
150
|
-
<div className=
|
|
151
|
+
<div className={spacing.mMd} id={`compound-expansion-table-${repo.name}-3`}>
|
|
151
152
|
Expanded content for {repo.name}: Workspaces goes here!
|
|
152
153
|
</div>
|
|
153
154
|
),
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Table, TableHeader, TableBody, TableProps } from '@patternfly/react-table/deprecated';
|
|
3
3
|
import { css } from '@patternfly/react-styles';
|
|
4
|
+
/* eslint-disable camelcase */
|
|
5
|
+
import global_primary_color_100 from '@patternfly/react-tokens/dist/esm/global_primary_color_100';
|
|
4
6
|
|
|
5
7
|
interface Repository {
|
|
6
8
|
name: string;
|
|
@@ -27,14 +29,13 @@ export const LegacyTableMisc: React.FunctionComponent = () => {
|
|
|
27
29
|
repo.lastCommit
|
|
28
30
|
]);
|
|
29
31
|
|
|
30
|
-
const customRowWrapper: TableProps['rowWrapper'] = ({ trRef, className, rowProps, row: _row
|
|
32
|
+
const customRowWrapper: TableProps['rowWrapper'] = ({ trRef, className, rowProps, row: _row }) => {
|
|
31
33
|
const isOddRow = rowProps ? !!((rowProps.rowIndex + 1) % 2) : true;
|
|
32
34
|
const customStyle = {
|
|
33
|
-
borderLeft:
|
|
35
|
+
borderLeft: `3px solid ${global_primary_color_100.var}`
|
|
34
36
|
};
|
|
35
37
|
return (
|
|
36
38
|
<tr
|
|
37
|
-
{...props}
|
|
38
39
|
ref={trRef as React.LegacyRef<HTMLTableRowElement>}
|
|
39
40
|
className={css(className, isOddRow ? 'odd-row-class' : 'even-row-class', 'custom-static-class')}
|
|
40
41
|
style={isOddRow ? customStyle : {}}
|
|
@@ -2,6 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { headerCol } from '@patternfly/react-table';
|
|
3
3
|
import { Table, TableHeader, TableBody, TableProps } from '@patternfly/react-table/deprecated';
|
|
4
4
|
import { Checkbox } from '@patternfly/react-core';
|
|
5
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
5
6
|
|
|
6
7
|
interface Repository {
|
|
7
8
|
name: string;
|
|
@@ -96,7 +97,7 @@ export const LegacyTableSelectable: React.FunctionComponent = () => {
|
|
|
96
97
|
<div>
|
|
97
98
|
<Checkbox
|
|
98
99
|
label="Can select all"
|
|
99
|
-
className=
|
|
100
|
+
className={spacing.mbLg}
|
|
100
101
|
isChecked={canSelectAll}
|
|
101
102
|
onChange={(_event, checked) => setCanSelectAll(checked)}
|
|
102
103
|
aria-label="toggle select all checkbox"
|
|
@@ -27,14 +27,10 @@ export const LegacyTableStripedCustomTr: React.FunctionComponent = () => {
|
|
|
27
27
|
repo.lastCommit
|
|
28
28
|
]);
|
|
29
29
|
|
|
30
|
-
const customRowWrapper: TableProps['rowWrapper'] = ({ trRef, className, rowProps, row: _row
|
|
30
|
+
const customRowWrapper: TableProps['rowWrapper'] = ({ trRef, className, rowProps, row: _row }) => {
|
|
31
31
|
const isOddRow = rowProps ? !!((rowProps.rowIndex + 1) % 2) : true;
|
|
32
32
|
return (
|
|
33
|
-
<tr
|
|
34
|
-
{...props}
|
|
35
|
-
ref={trRef as React.LegacyRef<HTMLTableRowElement>}
|
|
36
|
-
className={css(className, isOddRow && 'pf-m-striped')}
|
|
37
|
-
/>
|
|
33
|
+
<tr ref={trRef as React.LegacyRef<HTMLTableRowElement>} className={css(className, isOddRow && 'pf-m-striped')} />
|
|
38
34
|
);
|
|
39
35
|
};
|
|
40
36
|
|
|
@@ -32,6 +32,8 @@ import {
|
|
|
32
32
|
|
|
33
33
|
import { css } from '@patternfly/react-styles';
|
|
34
34
|
import styles from '@patternfly/react-styles/css/components/Table/table';
|
|
35
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
36
|
+
import global_primary_color_100 from '@patternfly/react-tokens/dist/esm/global_primary_color_100';
|
|
35
37
|
|
|
36
38
|
## Table Columns
|
|
37
39
|
|
package/src/docs/demos/Table.md
CHANGED
|
@@ -20,7 +20,6 @@ SkipToContent,
|
|
|
20
20
|
Breadcrumb,
|
|
21
21
|
BreadcrumbItem,
|
|
22
22
|
Page,
|
|
23
|
-
PageSectionVariants,
|
|
24
23
|
TextContent,
|
|
25
24
|
Text,
|
|
26
25
|
Divider } from '@patternfly/react-core';
|
|
@@ -47,7 +46,6 @@ import AngleDownIcon from '@patternfly/react-icons/dist/esm/icons/angle-down-ico
|
|
|
47
46
|
import AngleRightIcon from '@patternfly/react-icons/dist/esm/icons/angle-right-icon';
|
|
48
47
|
import BarsIcon from '@patternfly/react-icons/dist/esm/icons/bars-icon';
|
|
49
48
|
import AttentionBellIcon from '@patternfly/react-icons/dist/esm/icons/attention-bell-icon';
|
|
50
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/examples/DashboardWrapper';
|
|
51
49
|
import BlueprintIcon from '@patternfly/react-icons/dist/esm/icons/blueprint-icon';
|
|
52
50
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
53
51
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
@@ -1468,7 +1466,7 @@ import {
|
|
|
1468
1466
|
PageSection
|
|
1469
1467
|
} from '@patternfly/react-core';
|
|
1470
1468
|
import SearchIcon from '@patternfly/react-icons/dist/esm/icons/search-icon';
|
|
1471
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
1469
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
1472
1470
|
|
|
1473
1471
|
export const TableEmptyState: React.FunctionComponent = () => (
|
|
1474
1472
|
<DashboardWrapper hasPageTemplateTitle>
|
|
@@ -1529,7 +1527,7 @@ import {
|
|
|
1529
1527
|
PageSection,
|
|
1530
1528
|
Spinner
|
|
1531
1529
|
} from '@patternfly/react-core';
|
|
1532
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
1530
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
1533
1531
|
|
|
1534
1532
|
export const LoadingStateDemo: React.FunctionComponent = () => (
|
|
1535
1533
|
<DashboardWrapper hasPageTemplateTitle>
|
|
@@ -1580,7 +1578,7 @@ import {
|
|
|
1580
1578
|
} from '@patternfly/react-core';
|
|
1581
1579
|
import ExclamationCircleIcon from '@patternfly/react-icons/dist/esm/icons/exclamation-circle-icon';
|
|
1582
1580
|
import globalDangerColor200 from '@patternfly/react-tokens/dist/esm/global_danger_color_200';
|
|
1583
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
1581
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
1584
1582
|
|
|
1585
1583
|
export const ErrorStateDemo: React.FunctionComponent = () => (
|
|
1586
1584
|
<DashboardWrapper hasPageTemplateTitle>
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
ToolbarItem
|
|
15
15
|
} from '@patternfly/react-core';
|
|
16
16
|
import { Table, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
|
|
17
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
17
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
18
18
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
19
19
|
|
|
20
20
|
export const BulkSelectTableDemo = () => {
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
import { Table, TableText, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
|
|
29
29
|
import FilterIcon from '@patternfly/react-icons/dist/esm/icons/filter-icon';
|
|
30
30
|
import SortAmountDownIcon from '@patternfly/react-icons/dist/esm/icons/sort-amount-down-icon';
|
|
31
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
31
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper.js';
|
|
32
32
|
import { capitalize } from '@patternfly/react-table/src/components/Table/utils/utils';
|
|
33
33
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
34
34
|
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
} from '@patternfly/react-core';
|
|
18
18
|
import { Table, TableText, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
|
|
19
19
|
import FilterIcon from '@patternfly/react-icons/dist/esm/icons/filter-icon';
|
|
20
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
20
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
21
21
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
22
22
|
|
|
23
23
|
export const CompactTable = () => {
|
|
@@ -19,8 +19,9 @@ import {
|
|
|
19
19
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
20
20
|
import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
21
21
|
import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
22
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
22
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
23
23
|
import FilterIcon from '@patternfly/react-icons/dist/esm/icons/filter-icon';
|
|
24
|
+
import spacing from '@patternfly/react-styles/css/utilities/Spacing/spacing';
|
|
24
25
|
|
|
25
26
|
export const CompoundExpandable = () => {
|
|
26
27
|
// In real usage, this data would come from some external source like an API via props.
|
|
@@ -248,7 +249,7 @@ export const CompoundExpandable = () => {
|
|
|
248
249
|
<NestedItemsTable />
|
|
249
250
|
) : (
|
|
250
251
|
<ExpandableRowContent>
|
|
251
|
-
<div className=
|
|
252
|
+
<div className={spacing.mMd}>
|
|
252
253
|
Expanded content for {repo.name}: {expandedCellKey} goes here!
|
|
253
254
|
</div>
|
|
254
255
|
</ExpandableRowContent>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Card, Label, PageSection, TextVariants, Text, TextContent } from '@patternfly/react-core';
|
|
3
3
|
import { Table, Thead, Tbody, Tr, Th, Td, ExpandableRowContent } from '@patternfly/react-table';
|
|
4
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
4
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
5
5
|
|
|
6
6
|
const expandableColumns = ['Servers', 'Threads', 'Applications', 'Workspaces', 'Status'];
|
|
7
7
|
|
|
@@ -17,7 +17,6 @@ import {
|
|
|
17
17
|
OverflowMenuGroup,
|
|
18
18
|
OverflowMenuItem,
|
|
19
19
|
PageSection,
|
|
20
|
-
PageSectionVariants,
|
|
21
20
|
Pagination,
|
|
22
21
|
Select,
|
|
23
22
|
SelectOption,
|
|
@@ -38,7 +37,7 @@ import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
|
38
37
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
39
38
|
import SortAmountDownIcon from '@patternfly/react-icons/dist/esm/icons/sort-amount-down-icon';
|
|
40
39
|
import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
41
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
40
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
42
41
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
43
42
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
44
43
|
|
|
@@ -231,7 +230,7 @@ export const ComposableTableSortable = () => {
|
|
|
231
230
|
return (
|
|
232
231
|
<React.Fragment>
|
|
233
232
|
<DashboardWrapper>
|
|
234
|
-
<PageSection isWidthLimited
|
|
233
|
+
<PageSection isWidthLimited>
|
|
235
234
|
<TextContent>
|
|
236
235
|
<Text component="h1">Table demos</Text>
|
|
237
236
|
<Text component="p">
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
} from '@patternfly/react-core';
|
|
18
18
|
import { Table, TableText, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
|
|
19
19
|
import FilterIcon from '@patternfly/react-icons/dist/esm/icons/filter-icon';
|
|
20
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
20
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
21
21
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
22
22
|
|
|
23
23
|
export const StaticBottomPagination = () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Table, Thead, Tr, Th, Tbody, Td, InnerScrollContainer } from '@patternfly/react-table';
|
|
3
3
|
import { Card, PageSection } from '@patternfly/react-core';
|
|
4
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
4
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
5
5
|
|
|
6
6
|
export const StickyFirstColumn = () => {
|
|
7
7
|
const facts = Array.from(
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
|
|
3
3
|
import { Card, Label, PageSection } from '@patternfly/react-core';
|
|
4
4
|
import { Table, Thead, Tr, Th, Tbody, Td, TableText } from '@patternfly/react-table';
|
|
5
|
-
import DashboardWrapper from '@patternfly/react-core/src/demos/
|
|
5
|
+
import { DashboardWrapper } from '@patternfly/react-core/src/demos/DashboardWrapper';
|
|
6
6
|
import { rows, columns } from '@patternfly/react-table/src/docs/demos/table-demos/sampleData';
|
|
7
7
|
|
|
8
8
|
export const StickyHeader: React.FunctionComponent = () => {
|