import React from 'react';
import { Button, Popconfirm, message } from '@btri-ui/base';

export default () => {
  const cancel = (e: React.MouseEvent<HTMLElement>) => {
    console.log(e);
    message.error('Click on No');
  };

  const confirm = (e: React.MouseEvent<HTMLElement>) => {
    message.success('Click on confirm');
  };
  return (
    <Popconfirm title="确定?" onConfirm={confirm} onCancel={cancel}>
      <Button type="primary">删除</Button>
    </Popconfirm>
  );
};
