import { memo } from "react"; import { IconPlus } from "@tabler/icons-react"; import { useTranslation } from "react-i18next"; import classes from "@/ee/base/styles/grid.module.css"; type AddRowButtonProps = { onClick?: () => void; }; export const AddRowButton = memo(function AddRowButton({ onClick, }: AddRowButtonProps) { const { t } = useTranslation(); return (
{ if (e.key === "Enter" || e.key === " ") { e.preventDefault(); onClick?.(); } }} role="button" tabIndex={0} > {t("New row")}
); });