mirror of
https://github.com/portainer/portainer.git
synced 2025-07-22 14:59:41 +02:00
chore(deps): upgrade react-table to v8 [EE-4837] (#8245)
This commit is contained in:
parent
f20d3e72b9
commit
757461d58b
140 changed files with 1805 additions and 2872 deletions
|
@ -1,5 +1,4 @@
|
|||
import { Box, Plus, Trash2 } from 'lucide-react';
|
||||
import { useStore } from 'zustand';
|
||||
|
||||
import { ContainerGroup } from '@/react/azure/types';
|
||||
import { Authorized } from '@/react/hooks/useUser';
|
||||
|
@ -9,7 +8,7 @@ import { Datatable } from '@@/datatables';
|
|||
import { Button } from '@@/buttons';
|
||||
import { Link } from '@@/Link';
|
||||
import { createPersistedStore } from '@@/datatables/types';
|
||||
import { useSearchBarState } from '@@/datatables/SearchBar';
|
||||
import { useTableState } from '@@/datatables/useTableState';
|
||||
|
||||
import { columns } from './columns';
|
||||
|
||||
|
@ -22,19 +21,13 @@ export interface Props {
|
|||
}
|
||||
|
||||
export function ContainersDatatable({ dataset, onRemoveClick }: Props) {
|
||||
const settings = useStore(settingsStore);
|
||||
const [search, setSearch] = useSearchBarState(tableKey);
|
||||
const tableState = useTableState(settingsStore, tableKey);
|
||||
|
||||
return (
|
||||
<Datatable
|
||||
dataset={dataset}
|
||||
columns={columns}
|
||||
initialPageSize={settings.pageSize}
|
||||
onPageSizeChange={settings.setPageSize}
|
||||
initialSortBy={settings.sortBy}
|
||||
onSortByChange={settings.setSortBy}
|
||||
searchValue={search}
|
||||
onSearchChange={setSearch}
|
||||
settingsManager={tableState}
|
||||
title="Containers"
|
||||
titleIcon={Box}
|
||||
getRowId={(container) => container.id}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue