@canvas-components/react-list-table 0.3.44 → 0.3.45
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.cjs +5 -4
- package/dist/index.js +5 -4
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -4038,6 +4038,10 @@ function resolvePrintSelectedKeys(sourceColumns, presetConfig, cached) {
|
|
|
4038
4038
|
return true;
|
|
4039
4039
|
}).map((column) => column.key);
|
|
4040
4040
|
}
|
|
4041
|
+
function selectPrintColumns(columns, selectedKeys) {
|
|
4042
|
+
const selected = new Set(selectedKeys.map(String));
|
|
4043
|
+
return columns.filter((column) => selected.has(column.key));
|
|
4044
|
+
}
|
|
4041
4045
|
function createCachedPrintTableOptions(source, storageKey, printPresets = []) {
|
|
4042
4046
|
const cached = readPrintSettings(storageKey);
|
|
4043
4047
|
const selectedPreset = cached?.presetName ? printPresets.find((preset) => preset.name === cached.presetName) : cached ? void 0 : printPresets[0];
|
|
@@ -4359,10 +4363,7 @@ function ReactListTablePrintDialog(props) {
|
|
|
4359
4363
|
return () => window.removeEventListener("resize", updateViewport);
|
|
4360
4364
|
}, []);
|
|
4361
4365
|
const autoCalculateColumnWidths = () => {
|
|
4362
|
-
const
|
|
4363
|
-
const selectedColumns = columns.filter(
|
|
4364
|
-
(column) => selectedColumnSet.has(column.key)
|
|
4365
|
-
);
|
|
4366
|
+
const selectedColumns = selectPrintColumns(columns, selectedKeys);
|
|
4366
4367
|
const calculated = print.calculateBrowserPrintColumnWidths(selectedColumns, {
|
|
4367
4368
|
pageMargins,
|
|
4368
4369
|
paperSize,
|
package/dist/index.js
CHANGED
|
@@ -4037,6 +4037,10 @@ function resolvePrintSelectedKeys(sourceColumns, presetConfig, cached) {
|
|
|
4037
4037
|
return true;
|
|
4038
4038
|
}).map((column) => column.key);
|
|
4039
4039
|
}
|
|
4040
|
+
function selectPrintColumns(columns, selectedKeys) {
|
|
4041
|
+
const selected = new Set(selectedKeys.map(String));
|
|
4042
|
+
return columns.filter((column) => selected.has(column.key));
|
|
4043
|
+
}
|
|
4040
4044
|
function createCachedPrintTableOptions(source, storageKey, printPresets = []) {
|
|
4041
4045
|
const cached = readPrintSettings(storageKey);
|
|
4042
4046
|
const selectedPreset = cached?.presetName ? printPresets.find((preset) => preset.name === cached.presetName) : cached ? void 0 : printPresets[0];
|
|
@@ -4358,10 +4362,7 @@ function ReactListTablePrintDialog(props) {
|
|
|
4358
4362
|
return () => window.removeEventListener("resize", updateViewport);
|
|
4359
4363
|
}, []);
|
|
4360
4364
|
const autoCalculateColumnWidths = () => {
|
|
4361
|
-
const
|
|
4362
|
-
const selectedColumns = columns.filter(
|
|
4363
|
-
(column) => selectedColumnSet.has(column.key)
|
|
4364
|
-
);
|
|
4365
|
+
const selectedColumns = selectPrintColumns(columns, selectedKeys);
|
|
4365
4366
|
const calculated = calculateBrowserPrintColumnWidths(selectedColumns, {
|
|
4366
4367
|
pageMargins,
|
|
4367
4368
|
paperSize,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@canvas-components/react-list-table",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.45",
|
|
4
4
|
"description": "React adapter for the list table core engine.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -28,9 +28,9 @@
|
|
|
28
28
|
"pnpm": ">=9.0.0"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
+
"@canvas-components/chart": "0.3.8",
|
|
31
32
|
"@canvas-components/list-table": "0.3.37",
|
|
32
33
|
"@canvas-components/print": "0.1.1",
|
|
33
|
-
"@canvas-components/chart": "0.3.8",
|
|
34
34
|
"@canvas-components/react-components": "0.3.19"
|
|
35
35
|
},
|
|
36
36
|
"peerDependencies": {
|