deleteButton.tsx 488 B

12345678910111213141516171819202122
  1. import type {MouseEventHandler} from 'react';
  2. import {Button} from 'sentry/components/button';
  3. import {IconDelete} from 'sentry/icons';
  4. import {t} from 'sentry/locale';
  5. interface Props {
  6. onDelete: MouseEventHandler<Element>;
  7. }
  8. export function DeleteButton({onDelete}: Props) {
  9. return (
  10. <Button
  11. size="zero"
  12. borderless
  13. onClick={onDelete}
  14. icon={<IconDelete />}
  15. title={t('Remove this Y-Axis')}
  16. aria-label={t('Remove this Y-Axis')}
  17. />
  18. );
  19. }