Skip to content

A modern and easy to use dashboard. 80+ integrations. 20K+ icons built in. Authentication out of the box. No YAML, drag and drop configuration.

fix(docker): restore container selection toolbar broken by Mantine v9 (#5855)

Thomasfe4598f7221a
diff --git a/apps/nextjs/src/app/[locale]/manage/tools/docker/docker-table.tsx b/apps/nextjs/src/app/[locale]/manage/tools/docker/docker-table.tsx
index 4820a3a54..f0a91d904 100644
--- a/apps/nextjs/src/app/[locale]/manage/tools/docker/docker-table.tsx
+++ b/apps/nextjs/src/app/[locale]/manage/tools/docker/docker-table.tsx
@@ -107,6 +107,23 @@ export function DockerTable(initialData: RouterOutputs["docker"]["getContainers"
refetchOnReconnect: false,
});
const relativeTime = useTimeAgo(data.timestamp);
+ const utils = clientApi.useUtils();
+ const { mutate, isPending } = clientApi.docker.invalidate.useMutation({
+ async onSuccess() {
+ await utils.docker.getContainers.invalidate();
+ showSuccessNotification({
+ title: tDocker("action.refresh.notification.success.title"),
+ message: tDocker("action.refresh.notification.success.message"),
+ });
+ },
+ onError() {
+ showErrorNotification({
+ title: tDocker("action.refresh.notification.error.title"),
+ message: tDocker("action.refresh.notification.error.message"),
+ });
+ },
+ });
+
const table = useTranslatedMantineReactTable({
data: data.containers,
enableDensityToggle: false,
@@ -125,35 +142,11 @@ export function DockerTable(initialData: RouterOutputs["docker"]["getContainers"
},
initialState: { density: "xs", showGlobalFilter: true },
- renderTopToolbarCustomActions: () => {
- const utils = clientApi.useUtils();
- const { mutate, isPending } = clientApi.docker.invalidate.useMutation({
- async onSuccess() {
- await utils.docker.getContainers.invalidate();
- showSuccessNotification({
- title: tDocker("action.refresh.notification.success.title"),
- message: tDocker("action.refresh.notification.success.message"),
- });
- },
- onError() {
- showErrorNotification({
- title: tDocker("action.refresh.notification.error.title"),
- message: tDocker("action.refresh.notification.error.message"),
- });
- },
- });
-
- return (
- <Button
- variant="default"
- rightSection={<IconRefresh size="1rem" />}
- onClick={() => mutate()}
- loading={isPending}
- >
- {tDocker("action.refresh.label")}
- </Button>
- );
- },
+ renderTopToolbarCustomActions: () => (
+ <Button variant="default" rightSection={<IconRefresh size="1rem" />} onClick={() => mutate()} loading={isPending}>
+ {tDocker("action.refresh.label")}
+ </Button>
+ ),
renderToolbarAlertBannerContent: ({ groupedAlert, table }) => {
const dockerContainers = table.getSelectedRowModel().rows.map((row) => row.original);
return (
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 318fb6023..4e91f385c 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -388,8 +388,8 @@ catalogs:
specifier: ^4.5.0
version: 4.5.0
mantine-react-table:
- specifier: 2.0.0-beta.9
- version: 2.0.0-beta.9
+ specifier: npm:[email protected]
+ version: 9.0.3
maria2:
specifier: ^0.4.1
version: 0.4.1
@@ -819,7 +819,7 @@ importers:
mantine-react-table:
specifier: 'catalog:'
next:
specifier: 'catalog:'
@@ -2204,7 +2204,7 @@ importers:
version: 4.3.1
mantine-react-table:
specifier: 'catalog:'
next:
specifier: 'catalog:'
@@ -2259,7 +2259,7 @@ importers:
version: 4.2.0
mantine-react-table:
specifier: 'catalog:'
next:
specifier: 'catalog:'
@@ -2450,7 +2450,7 @@ importers:
version: 1.11.21
mantine-react-table:
specifier: 'catalog:'
next:
specifier: 'catalog:'
@@ -7442,18 +7442,18 @@ packages:
resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==}
engines: {node: '>=10'}
- resolution: {integrity: sha512-ZdfcwebWaPERoDvAuk43VYcBCzamohARVclnbuepT0PHZ0wRcDPMBR+zgaocL+pFy8EXUGwvWTOKNh25ITpjNQ==}
+ resolution: {integrity: sha512-HsrBU4KZluj96FPvvH0wcLzog0m5LIMdwB/59oj6BpftLGEibiLxX00G+tDM06PL2jXuiRxiGKPJ4oQOV+VK8w==}
engines: {node: '>=16'}
peerDependencies:
- '@mantine/core': ^7.9
- '@mantine/dates': ^7.9
- '@mantine/hooks': ^7.9
+ '@mantine/core': ^9.0.0
+ '@mantine/dates': ^9.0.0
+ '@mantine/hooks': ^9.0.0
'@tabler/icons-react': '>=2.23.0'
clsx: '>=2'
dayjs: '>=1.11'
- react: '>=18.0'
- react-dom: '>=18.0'
+ react: '>=19.2'
+ react-dom: '>=19.2'
resolution: {integrity: sha512-3lr8UeB+R+BN9c7eOBkeH1GlHf7+0Kzt0pcEgsT9xoXIA5gfXAzjd1niYiYDsvb62v5rLPqCqDiyYxtmmhGJ3g==}
@@ -14795,7 +14795,7 @@ snapshots:
dependencies:
semver: 7.7.4
dependencies:
diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml
index c2bd18e38..0bae29b39 100644
--- a/pnpm-workspace.yaml
+++ b/pnpm-workspace.yaml
@@ -131,7 +131,7 @@ catalog:
json5: ^2.2.3
ldapts: 8.1.8
lodash.clonedeep: ^4.5.0
- mantine-react-table: 2.0.0-beta.9
+ mantine-react-table: npm:[email protected]
maria2: ^0.4.1
mysql2: 3.22.4
next: 16.2.6