import { Space, Switch } from 'antd';
import { FormattedMessage } from 'umi';

const Level = ({ checkStrictly, setCheckStrictly }) => {
  return (
    <Space>
      <FormattedMessage id="component.CustomTree.level.label" />
      <FormattedMessage id="component.CustomTree.level.label.no" />
      <Switch checked={checkStrictly} onChange={setCheckStrictly} />
      <a onClick={() => setCheckStrictly(true)}>
        <FormattedMessage id="component.CustomTree.level.label.yes" />
      </a>
    </Space>
  );
};
export default Level;
