@patternfly/react-table 4.60.2 → 4.60.3
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
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## 4.60.3 (2022-01-19)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **examples:** amend row index in tree table examples ([#6830](https://github.com/patternfly/patternfly-react/issues/6830)) ([e676fb1](https://github.com/patternfly/patternfly-react/commit/e676fb1171618e957a4564af31c15ca6e3800507)), closes [#6719](https://github.com/patternfly/patternfly-react/issues/6719)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
## 4.60.2 (2022-01-19)
|
|
7
18
|
|
|
8
19
|
**Note:** Version bump only for package @patternfly/react-table
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@patternfly/react-table",
|
|
3
|
-
"version": "4.60.
|
|
3
|
+
"version": "4.60.3",
|
|
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",
|
|
@@ -31,10 +31,10 @@
|
|
|
31
31
|
"clean": "rimraf dist"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@patternfly/react-core": "^4.191.
|
|
35
|
-
"@patternfly/react-icons": "^4.42.
|
|
36
|
-
"@patternfly/react-styles": "^4.41.
|
|
37
|
-
"@patternfly/react-tokens": "^4.43.
|
|
34
|
+
"@patternfly/react-core": "^4.191.3",
|
|
35
|
+
"@patternfly/react-icons": "^4.42.3",
|
|
36
|
+
"@patternfly/react-styles": "^4.41.3",
|
|
37
|
+
"@patternfly/react-tokens": "^4.43.3",
|
|
38
38
|
"lodash": "^4.17.19",
|
|
39
39
|
"tslib": "^2.0.0"
|
|
40
40
|
},
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"react": "^16.8.0 || ^17.0.0",
|
|
47
47
|
"react-dom": "^16.8.0 || ^17.0.0"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "f161ca861cb4f1a679ea090a0606c15bdd5e795b"
|
|
50
50
|
}
|
|
@@ -137,6 +137,12 @@ export const LegacyTableTree: React.FunctionComponent = () => {
|
|
|
137
137
|
icon = isExpanded ? <FolderOpenIcon aria-hidden /> : <FolderIcon aria-hidden />;
|
|
138
138
|
}
|
|
139
139
|
flattenedNodes.push(node);
|
|
140
|
+
|
|
141
|
+
const childRows =
|
|
142
|
+
node.children && node.children.length
|
|
143
|
+
? buildRows(node.children, level + 1, 1, rowIndex + 1, !isExpanded || isHidden)
|
|
144
|
+
: [];
|
|
145
|
+
|
|
140
146
|
return [
|
|
141
147
|
{
|
|
142
148
|
cells: [node.name, node.branches, node.pullRequests, node.workspaces],
|
|
@@ -151,16 +157,8 @@ export const LegacyTableTree: React.FunctionComponent = () => {
|
|
|
151
157
|
icon
|
|
152
158
|
}
|
|
153
159
|
},
|
|
154
|
-
...
|
|
155
|
-
|
|
156
|
-
: []),
|
|
157
|
-
...buildRows(
|
|
158
|
-
remainingNodes,
|
|
159
|
-
level,
|
|
160
|
-
posinset + 1,
|
|
161
|
-
rowIndex + 1 + ((node.children && node.children.length) || 0),
|
|
162
|
-
isHidden
|
|
163
|
-
)
|
|
160
|
+
...childRows,
|
|
161
|
+
...buildRows(remainingNodes, level, posinset + 1, rowIndex + 1 + childRows.length, isHidden)
|
|
164
162
|
];
|
|
165
163
|
};
|
|
166
164
|
|
|
@@ -163,6 +163,11 @@ export const ComposableTableTree: React.FunctionComponent = () => {
|
|
|
163
163
|
}
|
|
164
164
|
};
|
|
165
165
|
|
|
166
|
+
const childRows =
|
|
167
|
+
node.children && node.children.length
|
|
168
|
+
? renderRows(node.children, level + 1, 1, rowIndex + 1, !isExpanded || isHidden)
|
|
169
|
+
: [];
|
|
170
|
+
|
|
166
171
|
return [
|
|
167
172
|
<TreeRowWrapper key={node.name} row={{ props: treeRow.props }}>
|
|
168
173
|
<Td dataLabel={columnNames.name} treeRow={treeRow}>
|
|
@@ -172,16 +177,8 @@ export const ComposableTableTree: React.FunctionComponent = () => {
|
|
|
172
177
|
<Td dataLabel={columnNames.prs}>{node.pullRequests}</Td>
|
|
173
178
|
<Td dataLabel={columnNames.workspaces}>{node.workspaces}</Td>
|
|
174
179
|
</TreeRowWrapper>,
|
|
175
|
-
...
|
|
176
|
-
|
|
177
|
-
: []),
|
|
178
|
-
...renderRows(
|
|
179
|
-
remainingNodes,
|
|
180
|
-
level,
|
|
181
|
-
posinset + 1,
|
|
182
|
-
rowIndex + 1 + ((node.children && node.children.length) || 0),
|
|
183
|
-
isHidden
|
|
184
|
-
)
|
|
180
|
+
...childRows,
|
|
181
|
+
...renderRows(remainingNodes, level, posinset + 1, rowIndex + 1 + childRows.length, isHidden)
|
|
185
182
|
];
|
|
186
183
|
};
|
|
187
184
|
|