material-react-table 1.5.0 → 1.5.1
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/README.md +1 -1
- package/dist/cjs/index.js +8 -4
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/_locales/zh-Hans.d.ts +2 -0
- package/dist/cjs/types/_locales/zh-Hant.d.ts +2 -0
- package/dist/cjs/types/buttons/MRT_ToggleRowActionMenuButton.d.ts +6 -6
- package/dist/cjs/types/index.d.ts +2 -1
- package/dist/esm/material-react-table.esm.js +8 -5
- package/dist/esm/material-react-table.esm.js.map +1 -1
- package/dist/esm/types/_locales/zh-Hans.d.ts +2 -0
- package/dist/esm/types/_locales/zh-Hant.d.ts +2 -0
- package/dist/esm/types/buttons/MRT_ToggleRowActionMenuButton.d.ts +6 -6
- package/dist/esm/types/index.d.ts +2 -1
- package/dist/index.d.ts +28 -21
- package/locales/zh-Hans.d.ts +2 -0
- package/locales/zh-Hans.esm.d.ts +2 -0
- package/locales/zh-Hans.esm.js +94 -0
- package/locales/zh-Hans.esm.js.map +1 -0
- package/locales/zh-Hans.js +98 -0
- package/locales/zh-Hans.js.map +1 -0
- package/locales/zh-Hant.d.ts +2 -0
- package/locales/zh-Hant.esm.d.ts +2 -0
- package/locales/zh-Hant.esm.js +94 -0
- package/locales/zh-Hant.esm.js.map +1 -0
- package/locales/zh-Hant.js +98 -0
- package/locales/zh-Hant.js.map +1 -0
- package/package.json +11 -11
- package/src/MaterialReactTable.tsx +7 -0
- package/src/_locales/zh-Hans.ts +94 -0
- package/src/_locales/zh-Hant.ts +94 -0
- package/src/body/MRT_TableBody.tsx +1 -4
- package/src/buttons/MRT_ToggleRowActionMenuButton.tsx +11 -9
- package/src/footer/MRT_TableFooter.tsx +1 -0
- package/src/index.tsx +2 -0
package/README.md
CHANGED
@@ -57,7 +57,7 @@ _All features can easily be enabled/disabled_
|
|
57
57
|
|
58
58
|
_**Fully Fleshed out [Docs](https://www.material-react-table.com/docs/guides#guides) are available for all features**_
|
59
59
|
|
60
|
-
- [x] <
|
60
|
+
- [x] < 41kb gzipped - [Bundlephobia](https://bundlephobia.com/package/material-react-table)
|
61
61
|
- [x] Advanced TypeScript Generics Support (TypeScript Optional)
|
62
62
|
- [x] Aggregation and Grouping (Sum, Average, Count, etc.)
|
63
63
|
- [x] Click To Copy Cell Values
|
package/dist/cjs/index.js
CHANGED
@@ -2464,9 +2464,7 @@ const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddin
|
|
2464
2464
|
}
|
2465
2465
|
return rankedRows;
|
2466
2466
|
}
|
2467
|
-
return
|
2468
|
-
? getRowModel().rows
|
2469
|
-
: getPrePaginationRowModel().rows;
|
2467
|
+
return getRowModel().rows;
|
2470
2468
|
}, [
|
2471
2469
|
enableGlobalFilterRankedResults,
|
2472
2470
|
(enableGlobalFilterRankedResults && globalFilter) || !enablePagination
|
@@ -2598,7 +2596,7 @@ const MRT_TableFooter = ({ table, virtualColumns, virtualPaddingLeft, virtualPad
|
|
2598
2596
|
? theme.palette.mode === 'light'
|
2599
2597
|
? `1px solid ${theme.palette.grey[300]}`
|
2600
2598
|
: `1px solid ${theme.palette.grey[700]}`
|
2601
|
-
: undefined, position: stickFooter ? 'sticky' : undefined }, ((tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx) instanceof Function
|
2599
|
+
: undefined, position: stickFooter ? 'sticky' : undefined, zIndex: stickFooter ? 1 : undefined }, ((tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx) instanceof Function
|
2602
2600
|
? tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx(theme)
|
2603
2601
|
: tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx))) }), getFooterGroups().map((footerGroup) => (React__default["default"].createElement(MRT_TableFooterRow, { footerGroup: footerGroup, key: footerGroup.id, table: table, virtualColumns: virtualColumns, virtualPaddingLeft: virtualPaddingLeft, virtualPaddingRight: virtualPaddingRight })))));
|
2604
2602
|
};
|
@@ -3020,8 +3018,13 @@ const MaterialReactTable = (_a) => {
|
|
3020
3018
|
const _defaultDisplayColumn = React.useMemo(() => (Object.assign(Object.assign({}, MRT_DefaultDisplayColumn), defaultDisplayColumn)), [defaultDisplayColumn]);
|
3021
3019
|
if (rest.enableRowVirtualization || rest.enableColumnVirtualization) {
|
3022
3020
|
layoutMode = 'grid';
|
3021
|
+
}
|
3022
|
+
if (rest.enableRowVirtualization) {
|
3023
3023
|
enableStickyHeader = true;
|
3024
3024
|
}
|
3025
|
+
if (enablePagination === false && manualPagination === undefined) {
|
3026
|
+
manualPagination = true;
|
3027
|
+
}
|
3025
3028
|
if (!((_b = rest.data) === null || _b === void 0 ? void 0 : _b.length)) {
|
3026
3029
|
manualFiltering = true;
|
3027
3030
|
manualGrouping = true;
|
@@ -3040,6 +3043,7 @@ exports.MRT_TablePagination = MRT_TablePagination;
|
|
3040
3043
|
exports.MRT_ToggleDensePaddingButton = MRT_ToggleDensePaddingButton;
|
3041
3044
|
exports.MRT_ToggleFiltersButton = MRT_ToggleFiltersButton;
|
3042
3045
|
exports.MRT_ToggleGlobalFilterButton = MRT_ToggleGlobalFilterButton;
|
3046
|
+
exports.MRT_ToggleRowActionMenuButton = MRT_ToggleRowActionMenuButton;
|
3043
3047
|
exports.MRT_ToolbarAlertBanner = MRT_ToolbarAlertBanner;
|
3044
3048
|
exports.MRT_ToolbarDropZone = MRT_ToolbarDropZone;
|
3045
3049
|
exports.MRT_ToolbarInternalButtons = MRT_ToolbarInternalButtons;
|