import { type FC } from 'react';

import { Stack } from '@mui/material';

import { type TableToolbarProps } from './types';

const TableToolbar: FC<TableToolbarProps> = ({
  children,
  sx = {},
  ...props
}) => {
  return (
    <Stack
      sx={{
        px: 2,
        py: 3,
        color: theme => theme.palette.new.text.neutral.lighter,
        backgroundColor: theme => theme.palette.new.background.layout.tertiary,
        ...sx,
      }}
      {...props}
    >
      {children}
    </Stack>
  );
};

export type { TableToolbarProps };

TableToolbar.displayName = 'TableToolbar';

export default TableToolbar;
