import { j as r } from "../../node_modules/react/jsx-runtime.mjs";
import { isMobile as e } from "../../node_modules/react-device-detect/dist/lib.mjs";
import u from "../../node_modules/antd/es/config-provider/index.mjs";
import b from "../../node_modules/antd/es/drawer/index.mjs";
import t from "../../node_modules/antd/es/button/button.mjs";
const B = ({
  configProvider: i,
  title: s = "",
  open: m = !1,
  onClose: o = () => {
  },
  onSubmit: l = () => {
  },
  children: a,
  pcWidth: p = 800,
  mobileHeight: c = 600,
  showFooter: n = !0,
  showSubmitBtn: f = !0,
  showCancelBtn: d = !0,
  submitBtnText: h = "保存",
  cancelBtnText: x = "取消",
  ...j
}) => /* @__PURE__ */ r.jsx(u, { ...i, children: /* @__PURE__ */ r.jsx(
  b,
  {
    ...j,
    title: s,
    placement: e ? "bottom" : "right",
    height: e ? c : "",
    width: e ? "" : p,
    closable: !1,
    onClose: o,
    open: m,
    footer: n ? /* @__PURE__ */ r.jsxs("div", { className: e ? "mobileFooter" : "pcFooter", children: [
      f && /* @__PURE__ */ r.jsx(t, { type: "primary", onClick: l, children: h }),
      d && /* @__PURE__ */ r.jsx(t, { onClick: o, children: x })
    ] }) : "",
    children: a
  }
) });
export {
  B as default
};
