"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = exports.ProFieldBadgeColor = void 0;
var _react = _interopRequireDefault(require("react"));
var _badge = _interopRequireDefault(require("../badge"));
var _utils = require("../utils");
require("./style");
var _jsxRuntime = require("react/jsx-runtime");
function createStatusComponent(status) {
  const StatusComponent = ({
    children
  }) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_badge.default, {
    status: status,
    text: children
  });
  StatusComponent.displayName = (0, _utils.pascalCase)(status);
  return StatusComponent;
}

/** 快捷操作，用于快速的展示一个状态 */
const Status = {
  Success: createStatusComponent('success'),
  Error: createStatusComponent('error'),
  Default: createStatusComponent('default'),
  Processing: createStatusComponent('processing'),
  Warning: createStatusComponent('warning'),
  success: createStatusComponent('success'),
  error: createStatusComponent('error'),
  default: createStatusComponent('default'),
  processing: createStatusComponent('processing'),
  warning: createStatusComponent('warning')
};
const ProFieldBadgeColor = ({
  color,
  children
}) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_badge.default, {
  color: color,
  text: children
});
exports.ProFieldBadgeColor = ProFieldBadgeColor;
var _default = Status;
exports.default = _default;