import s from "../../@babel/runtime/helpers/esm/extends.mjs";
import u from "../../@babel/runtime/helpers/esm/classCallCheck.mjs";
import f from "../../@babel/runtime/helpers/esm/createClass.mjs";
import m from "../../@babel/runtime/helpers/esm/inherits.mjs";
import c from "../../@babel/runtime/helpers/esm/createSuper.mjs";
import d, { Component as h } from "react";
import v from "./AjaxUploader.mjs";
function a() {
}
var C = /* @__PURE__ */ function(p) {
  m(e, p);
  var l = c(e);
  function e() {
    var r;
    u(this, e);
    for (var t = arguments.length, n = new Array(t), o = 0; o < t; o++)
      n[o] = arguments[o];
    return r = l.call.apply(l, [this].concat(n)), r.uploader = void 0, r.saveUploader = function(i) {
      r.uploader = i;
    }, r;
  }
  return f(e, [{
    key: "abort",
    value: function(t) {
      this.uploader.abort(t);
    }
  }, {
    key: "render",
    value: function() {
      return /* @__PURE__ */ d.createElement(v, s({}, this.props, {
        ref: this.saveUploader
      }));
    }
  }]), e;
}(h);
C.defaultProps = {
  component: "span",
  prefixCls: "rc-upload",
  data: {},
  headers: {},
  name: "file",
  multipart: !1,
  onStart: a,
  onError: a,
  onSuccess: a,
  multiple: !1,
  beforeUpload: null,
  customRequest: null,
  withCredentials: !1,
  openFileDialogOnClick: !0
};
export {
  C as default
};
