import React from 'react';
import AntdSwitch from 'antd/es/switch';

import { getPrefixCls } from '../config-provider';
import './index.less';

const Switch = props => {
  const { prefixCls: customizePrefixCls, ...restProps } = props;
  const prefixCls = getPrefixCls('switch', customizePrefixCls);
  return <AntdSwitch {...restProps} prefixCls={prefixCls} />;
};

Switch.__ANT_SWITCH = true;

export default Switch;
