import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
import React from "react";
import { Switch } from "@alicloudfe/components";
import cls from "classnames";
import BDesignTheme from '../theme';

var BDesignSwitch = function BDesignSwitch(props) {
  var className = props.className,
      theme = props.theme,
      rest = _objectWithoutProperties(props, ["className", "theme"]);

  return /*#__PURE__*/React.createElement(BDesignTheme, {
    theme: theme
  }, function (theme) {
    return /*#__PURE__*/React.createElement(Switch, _extends({
      className: cls(className, {
        'next-switch-blue': theme === "blue"
      })
    }, rest));
  });
};

export default BDesignSwitch;