pixel-react 1.10.8 → 1.10.9
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/lib/index.esm.js +10 -5
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +10 -5
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/AddResourceButton/ArrowsButton/ArrowsButton.tsx +0 -1
- package/src/components/MenuOption/MenuOption.tsx +1 -1
- package/src/components/Table/Table.tsx +3 -1
- package/src/components/TableTree/TableTree.scss +15 -14
- package/src/utils/TableCell/TableCell.ts +3 -0
package/package.json
CHANGED
@@ -40,14 +40,16 @@ const SortableRow = ({
|
|
40
40
|
transform: CSS.Transform.toString(transform),
|
41
41
|
transition,
|
42
42
|
};
|
43
|
+
const key = row._id || row.id;
|
43
44
|
return (
|
44
45
|
<tr
|
45
46
|
ref={setNodeRef}
|
46
47
|
style={style}
|
47
|
-
key={
|
48
|
+
key={key}
|
48
49
|
className={classNames(tableBodyRowClass, {
|
49
50
|
'disabled-row': row.disabled,
|
50
51
|
})}
|
52
|
+
id={key}
|
51
53
|
>
|
52
54
|
{columns.map((column: any, index: number) => {
|
53
55
|
return (
|
@@ -140,6 +140,21 @@
|
|
140
140
|
z-index: 2;
|
141
141
|
}
|
142
142
|
|
143
|
+
.ff-table-tree-row:hover,
|
144
|
+
.ff-table-tree-row.hover {
|
145
|
+
background-color: var(--hover-color);
|
146
|
+
|
147
|
+
.ff-table-tree-td {
|
148
|
+
&:first-child {
|
149
|
+
background-color: var(--hover-color);
|
150
|
+
}
|
151
|
+
}
|
152
|
+
|
153
|
+
.table-tree-row-action {
|
154
|
+
display: inline-flex;
|
155
|
+
align-items: center;
|
156
|
+
}
|
157
|
+
}
|
143
158
|
.ff-table-tree-row {
|
144
159
|
background-color: var(--base-bg-color);
|
145
160
|
|
@@ -152,20 +167,6 @@
|
|
152
167
|
z-index: 9999;
|
153
168
|
align-items: center;
|
154
169
|
}
|
155
|
-
&:hover {
|
156
|
-
background-color: var(--hover-color);
|
157
|
-
|
158
|
-
.ff-table-tree-td {
|
159
|
-
&:first-child {
|
160
|
-
background-color: var(--hover-color);
|
161
|
-
}
|
162
|
-
}
|
163
|
-
|
164
|
-
.table-tree-row-action {
|
165
|
-
display: inline-flex;
|
166
|
-
align-items: center;
|
167
|
-
}
|
168
|
-
}
|
169
170
|
|
170
171
|
&::after {
|
171
172
|
content: '';
|
@@ -1,10 +1,13 @@
|
|
1
1
|
export const prepareData = (dataObj: any, columnObj: any) => {
|
2
2
|
let cellData = dataObj[columnObj.accessor];
|
3
3
|
if (columnObj.cell) {
|
4
|
+
const refId = dataObj._id || dataObj.id;
|
5
|
+
|
4
6
|
return columnObj.cell({
|
5
7
|
value: cellData,
|
6
8
|
row: dataObj,
|
7
9
|
column: columnObj.accessor,
|
10
|
+
...(refId && { refId }),
|
8
11
|
});
|
9
12
|
} else if (columnObj.accessor) {
|
10
13
|
return cellData;
|