@apia/table 3.0.16 → 3.0.18
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/dist/index.js +13 -2
- package/dist/index.js.map +1 -1
- package/package.json +7 -7
package/dist/index.js
CHANGED
|
@@ -1185,10 +1185,12 @@ const NoMemoHeaderCell = ({
|
|
|
1185
1185
|
const uniqueId = window.location.href.match(/busEntId=(\d+)/)?.[1] ?? window.location.href.match(/query=(\d+)/)?.[1] ?? "";
|
|
1186
1186
|
const isGlobal = window.isGlobal ? "isGlobal" : "notGlobal";
|
|
1187
1187
|
const actualName = name + uniqueId + String(isGlobal);
|
|
1188
|
-
const
|
|
1188
|
+
const columns = useResponsiveTable((global) => {
|
|
1189
1189
|
const tableState = global.responsiveTableSlice[name];
|
|
1190
|
-
return tableState?.columns
|
|
1190
|
+
return tableState?.columns;
|
|
1191
1191
|
}, shallowEqual);
|
|
1192
|
+
const column = columns[columnIndex];
|
|
1193
|
+
const additionalInfoColumns = columns.filter((c) => c.showAsAdditional);
|
|
1192
1194
|
const storedWidth = persistentStorage[widthStorageName]?.[actualName]?.[column.name];
|
|
1193
1195
|
const [width, setWidth] = React.useState(storedWidth ?? 200);
|
|
1194
1196
|
const [isResize, setIsResize] = React.useState(storedWidth !== void 0);
|
|
@@ -1339,6 +1341,15 @@ const NoMemoHeaderCell = ({
|
|
|
1339
1341
|
}
|
|
1340
1342
|
};
|
|
1341
1343
|
});
|
|
1344
|
+
additionalInfoColumns.forEach((c) => {
|
|
1345
|
+
persistentStorage[widthStorageName] = {
|
|
1346
|
+
...persistentStorage[widthStorageName],
|
|
1347
|
+
[actualName]: {
|
|
1348
|
+
...persistentStorage[widthStorageName]?.[actualName],
|
|
1349
|
+
[c.name]: 100
|
|
1350
|
+
}
|
|
1351
|
+
};
|
|
1352
|
+
});
|
|
1342
1353
|
document.removeEventListener("mousemove", resize);
|
|
1343
1354
|
document.removeEventListener("mouseup", unsuscribe);
|
|
1344
1355
|
};
|