Added scrollarea on table
This commit is contained in:
parent
852459fdc2
commit
d06010abe6
|
|
@ -1,15 +1,16 @@
|
|||
"use client";
|
||||
import React from "react";
|
||||
|
||||
import { Table, Center } from "@mantine/core"
|
||||
import { Table, Center, ScrollArea } from "@mantine/core";
|
||||
import { Table as ReactTable, flexRender } from "@tanstack/react-table";
|
||||
|
||||
interface Props<TData> {
|
||||
table: ReactTable<TData>
|
||||
table: ReactTable<TData>;
|
||||
}
|
||||
|
||||
export default function DashboardTable<T>({table}: Props<T>) {
|
||||
export default function DashboardTable<T>({ table }: Props<T>) {
|
||||
return (
|
||||
<ScrollArea.Autosize>
|
||||
<Table verticalSpacing="xs" horizontalSpacing="xs">
|
||||
{/* Thead */}
|
||||
<Table.Thead>
|
||||
|
|
@ -64,5 +65,6 @@ export default function DashboardTable<T>({table}: Props<T>) {
|
|||
)}
|
||||
</Table.Tbody>
|
||||
</Table>
|
||||
</ScrollArea.Autosize>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user