import _extends from "@babel/runtime/helpers/extends";
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
var _excluded = ["className", "color", "size", "tint"];
import cx from 'classnames';
import React, { forwardRef } from 'react';
import Box from '../box';
import theme from './theme.css';
var LoadingSpinner = /*#__PURE__*/forwardRef(function (_ref, ref) {
  var className = _ref.className,
      _ref$color = _ref.color,
      color = _ref$color === void 0 ? 'teal' : _ref$color,
      _ref$size = _ref.size,
      size = _ref$size === void 0 ? 'medium' : _ref$size,
      _ref$tint = _ref.tint,
      tint = _ref$tint === void 0 ? 'darkest' : _ref$tint,
      others = _objectWithoutProperties(_ref, _excluded);

  var classNames = cx(theme['loading-spinner'], theme["is-".concat(color)], theme["is-".concat(size)], theme["is-".concat(tint)], className);
  return /*#__PURE__*/React.createElement(Box, _extends({
    "data-teamleader-ui": "loading-spinner",
    className: classNames
  }, others, {
    ref: ref
  }));
});
LoadingSpinner.displayName = 'LoadingSpinner';
export default LoadingSpinner;