Skip to content

Commit e38290d

Browse files
authored
Merge pull request #684 from icflorescu/next
Publish new version
2 parents 191c708 + 19bef05 commit e38290d

17 files changed

+435
-359
lines changed

CHANGELOG.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@
33
The following is a list of notable changes to the Mantine DataTable component.
44
Minor versions that are not listed in the changelog are bug fixes and small improvements.
55

6+
## 7.15.1 (2024-12-20)
7+
8+
- Fix [#682](https://github.com/icflorescu/mantine-datatable/issues/682) - request to remove CSS source maps from the dist
9+
- Update dev dependencies to ensure compatibility with Mantine 7.15.1 and Next.js 15 GA
10+
- Fix a few type imports
11+
612
## 7.14.5 (2024-10-26)
713

814
- Remove leftover `console.log` statement
@@ -46,7 +52,6 @@ Minor versions that are not listed in the changelog are bug fixes and small impr
4652
- Update dev dependencies
4753
- Emphasize that PRs should be made against the `next` branch in the README and on the [documentation website](https://icflorescu.github.io/mantine-datatable/)
4854

49-
5055
## 7.11.1 (2024-06-30)
5156

5257
- Add new `paginationWithControls` prop (thanks to [@ValentinJS](https://github.com/ValentinJS) for PR [#611](https://github.com/icflorescu/mantine-datatable/pull/611))
@@ -91,7 +96,7 @@ Minor versions that are not listed in the changelog are bug fixes and small impr
9196
## 7.8.2 (2024-04-26)
9297

9398
- Add `rowExpansion.expandable` property defining if row can be expanded (see [#579](https://github.com/icflorescu/mantine-datatable/issues/579), by [@camdarley](https://github.com/camdarley))
94-
- Update dev dependencies to ensure compatibility with Mantine 7.8.1, Next.js 14.2.3 and React 18.3
99+
- Update dev dependencies to ensure compatibility with Mantine 7.8.1, Next.js 14.2.3 and React 18.3
95100

96101
## 7.8.1 (2024-04-12)
97102

@@ -159,7 +164,7 @@ Minor versions that are not listed in the changelog are bug fixes and small impr
159164

160165
- Ensure compatibility with Mantine 7.4
161166
- Minor docs improvements
162-
167+
163168
## 7.3.5 (2023-12-29)
164169

165170
- Minor README updates
@@ -221,6 +226,7 @@ Minor versions that are not listed in the changelog are bug fixes and small impr
221226
### First V7 release! 🎉
222227

223228
This is a **major rewrite** of the library internals, with the following goals in mind:
229+
224230
- **Mantine V7 compatibility** - switch the styling approach from CSS-in-JS to PostCSS (or PostCSS modules)
225231
- Make the repo easier to maintain by switching from a monorepo approach to a single-package that includes the source code, documentation and examples; this should also make it easier for new contributors to get started
226232
- Streamline the build process - switch from `esbuild` to plain `tsc` and `postcss` commands

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ This is a [Next.js](https://nextjs.org/) project with an [app router](https://ne
1919
The Mantine DataTable package code is located in the `package` folder, while the documentation website code is located in the `app` folder.
2020
The `components` folder holds generic React components used by the documentation website.
2121
If you want to implement a new feature or improve an existing one, make sure to add an example page and/or alter the one(s) already referring to it.
22-
It’s not a feature if other people don’t know about it or don’t understand how to use it.
22+
It’s not a feature if other people don’t know about it or don’t understand how to use it.
2323

2424
**Please target your PRs to the `next` branch.**
2525
Pushing to the `main` branch triggers the GitHub deployment workflow, so PRs targeting `main` will be rejected.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ If you're a company using Mantine, Mantine DataTable or [Mantine ContextMenu](ht
163163

164164
## Other means of support
165165

166-
If you can't afford to sponsor the project or hire my services, there are other ways you can support my work:
166+
If you can't afford to sponsor the project or hire my services, there are other ways you can support my work:
167167

168168
- 🙏 star the repository;
169169
- 💕 [tweet about it](http://twitter.com/share?text=Build%20data-rich%20React%20applications%20with%20Mantine%20DataTable&url=https%3A%2F%2Fgithub.com%2Ficflorescu%2Fmantine-datatable&hashtags=mantine%2Cdatatable%2Cdatagrid%2Creact&via=icflorescu);

data/async.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ export async function getEmployeesAsync({
3535
sortAccessor === 'name'
3636
? `${employee.firstName} ${employee.lastName}`
3737
: sortAccessor === 'age'
38-
? now.diff(employee.birthDate)
39-
: get(employee, sortAccessor)
38+
? now.diff(employee.birthDate)
39+
: get(employee, sortAccessor)
4040
);
4141

4242
if (sortDirection === 'desc') result.reverse();

data/companies.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,4 +103,4 @@
103103
"state": "ID",
104104
"missionStatement": "Eliminate best-of-breed e-markets."
105105
}
106-
]
106+
]

data/departments.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,4 +399,4 @@
399399
"companyId": "3fdba2fc-2347-464b-b29a-3ef8f03ccf56",
400400
"name": "Games"
401401
}
402-
]
402+
]

data/employees.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4499,4 +4499,4 @@
44994499
"birthDate": "1988-10-22T14:54:38.877Z",
45004500
"departmentId": "1c99b83a-9883-43c2-828c-0ace9b812a8a"
45014501
}
4502-
]
4502+
]

package.json

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "mantine-datatable",
3-
"version": "7.14.5",
3+
"version": "7.15.1",
44
"description": "The lightweight, dependency-free, dark-theme aware table component for your Mantine UI data-rich applications, featuring asynchronous data loading support, pagination, intuitive Gmail-style additive batch rows selection, column sorting, custom cell data rendering, row expansion, nesting, context menus, and much more",
55
"keywords": [
66
"mantine",
@@ -71,41 +71,41 @@
7171
"format": "prettier --write ."
7272
},
7373
"devDependencies": {
74-
"@docsearch/react": "^3.8.0",
75-
"@faker-js/faker": "^9.2.0",
74+
"@docsearch/react": "^3.8.2",
75+
"@faker-js/faker": "^9.3.0",
7676
"@formkit/auto-animate": "^0.8.2",
7777
"@hello-pangea/dnd": "^17.0.0",
78-
"@mantine/code-highlight": "^7.14.2",
79-
"@mantine/core": "^7.14.2",
80-
"@mantine/dates": "^7.14.2",
81-
"@mantine/hooks": "^7.14.2",
82-
"@mantine/modals": "^7.14.2",
83-
"@mantine/notifications": "^7.14.2",
84-
"@tabler/icons-react": "^3.22.0",
85-
"@tanstack/react-query": "^5.61.3",
78+
"@mantine/code-highlight": "^7.15.1",
79+
"@mantine/core": "^7.15.1",
80+
"@mantine/dates": "^7.15.1",
81+
"@mantine/hooks": "^7.15.1",
82+
"@mantine/modals": "^7.15.1",
83+
"@mantine/notifications": "^7.15.1",
84+
"@tabler/icons-react": "^3.26.0",
85+
"@tanstack/react-query": "^5.62.8",
8686
"@types/lodash": "^4.17.13",
87-
"@types/node": "^22.10.0",
88-
"@types/react": "^18.3.12",
89-
"@types/react-dom": "^18.3.1",
90-
"@typescript-eslint/eslint-plugin": "^8.16.0",
91-
"@typescript-eslint/parser": "^8.16.0",
87+
"@types/node": "^22.10.2",
88+
"@types/react": "^19.0.2",
89+
"@types/react-dom": "^19.0.2",
90+
"@typescript-eslint/eslint-plugin": "^8.18.1",
91+
"@typescript-eslint/parser": "^8.18.1",
9292
"clsx": "^2.1.1",
9393
"cssnano": "^7.0.6",
9494
"dayjs": "^1.11.13",
9595
"eslint": "^8",
96-
"eslint-config-next": "^15.0.3",
96+
"eslint-config-next": "^15.1.2",
9797
"eslint-config-prettier": "^9.1.0",
9898
"lodash": "^4.17.21",
99-
"mantine-contextmenu": "^7.14.2",
100-
"next": "^15.0.3",
99+
"mantine-contextmenu": "^7.15.1",
100+
"next": "^15.1.2",
101101
"postcss": "^8.4.49",
102102
"postcss-cli": "^11.0.0",
103103
"postcss-import": "^16.1.0",
104104
"postcss-preset-mantine": "^1.17.0",
105105
"postcss-simple-vars": "^7.0.1",
106-
"prettier": "^3.4.0",
107-
"react": "^18.3.1",
108-
"react-dom": "^18.3.1",
106+
"prettier": "^3.4.2",
107+
"react": "^19.0.0",
108+
"react-dom": "^19.0.0",
109109
"sharp": "^0.33.5",
110110
"swr": "^2.2.5",
111111
"tsup": "^8.3.5",

package/DataTable.css

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,10 @@
3131
rgba(0, 0, 0, 0)
3232
),
3333
linear-gradient(to left, rgba(0, 0, 0, light-dark(0.05, 0.25)), rgba(0, 0, 0, 0) 30%);
34-
--mantine-datatable-shadow-background-bottom: linear-gradient(rgba(0, 0, 0, 0), rgba(0, 0, 0, light-dark(0.05, 0.25))),
34+
--mantine-datatable-shadow-background-bottom: linear-gradient(
35+
rgba(0, 0, 0, 0),
36+
rgba(0, 0, 0, light-dark(0.05, 0.25))
37+
),
3538
linear-gradient(rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, light-dark(0.05, 0.25)));
3639
--mantine-datatable-shadow-background-left: linear-gradient(
3740
to right,

package/DataTableFooter.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { TableTfoot, TableTr, rem, type MantineStyleProp } from '@mantine/core';
22
import clsx from 'clsx';
3-
import { forwardRef } from 'react';
3+
import { forwardRef, type JSX } from 'react';
44
import { DataTableFooterCell } from './DataTableFooterCell';
55
import { DataTableFooterSelectorPlaceholderCell } from './DataTableFooterSelectorPlaceholderCell';
66
import type { DataTableColumn, DataTableDefaultColumnProps } from './types';

package/DataTableHeader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {
1111
type MantineStyleProp,
1212
} from '@mantine/core';
1313
import clsx from 'clsx';
14-
import { forwardRef, useState } from 'react';
14+
import { forwardRef, useState, type JSX } from 'react';
1515
import { DataTableColumnGroupHeaderCell } from './DataTableColumnGroupHeaderCell';
1616
import { useDataTableColumnsContext } from './DataTableColumns.context';
1717
import { DataTableHeaderCell } from './DataTableHeaderCell';

package/DataTablePagination.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Box, Pagination, Text, rem, type MantineSpacing, type MantineStyleProp } from '@mantine/core';
22
import clsx from 'clsx';
3-
import { forwardRef, type ForwardedRef } from 'react';
3+
import { forwardRef, type ForwardedRef, type JSX } from 'react';
44
import { DataTablePageSizeSelector } from './DataTablePageSizeSelector';
55
import { getPaginationCssVariables } from './cssVariables';
66
import { useMediaQueryStringOrFunction } from './hooks';

package/hooks/useMediaQueries.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ function attachMediaListeners(queries: MediaQueryList[], callback: (matches: boo
1818
try {
1919
query.addEventListener('change', callbackWrapper);
2020
return () => query.removeEventListener('change', callbackWrapper);
21-
} catch (e) {
21+
} catch {
2222
query.addListener(callbackWrapper);
2323
return () => query.removeListener(callbackWrapper);
2424
}
@@ -50,7 +50,7 @@ export function useMediaQueries(
5050
const [matches, setMatches] = useState(
5151
getInitialValueInEffect ? initialValues : getInitialValue(queries, initialValues)
5252
);
53-
const queryRef = useRef<MediaQueryList[]>();
53+
const queryRef = useRef<MediaQueryList[]>(null);
5454

5555
useEffect(() => {
5656
if ('matchMedia' in window) {

package/types/DataTableProps.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ export type DataTableProps<T = Record<string, unknown>> = {
234234
* Ref pointing to the scrollable viewport element.
235235
* Useful for imperative scrolling.
236236
*/
237-
scrollViewportRef?: React.RefObject<HTMLDivElement>;
237+
scrollViewportRef?: React.RefObject<HTMLDivElement | null>;
238238

239239
/**
240240
* Additional props passed to the underlying `ScrollArea` element.

postcss.config.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
module.exports = {
2-
map: { inline: false },
32
plugins: {
43
'postcss-import': {},
54
'postcss-preset-mantine': {},
@@ -12,6 +11,6 @@ module.exports = {
1211
'mantine-breakpoint-xl': '88em',
1312
},
1413
},
14+
cssnano: { preset: 'default' },
1515
},
16-
cssnano: { preset: 'default' },
1716
};

public/googlea3479269b2f388cf.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
google-site-verification: googlea3479269b2f388cf.html
1+
google-site-verification: googlea3479269b2f388cf.html

0 commit comments

Comments
 (0)