UNPKG

@yzsf2e/render-core

Version:

1,652 lines 1.75 MB
import { getCurrentInstance as Hr, defineComponent as Ce, ref as mt, computed as Ht, createVNode as Yt, mergeProps as Me, openBlock as wt, createBlock as qt, resolveDynamicComponent as Xr, resolveComponent as Ft, normalizeStyle as zr, withCtx as Et, renderSlot as ur, createCommentVNode as _e, effectScope as Eu, unref as ae, isRef as er, toRefs as br, customRef as Tu, onMounted as yr, nextTick as sr, getCurrentScope as Au, onScopeDispose as Mu, readonly as Ou, watch as ge, shallowRef as Fn, createElementBlock as ne, Fragment as Re, createTextVNode as Ne, toDisplayString as fe, createElementVNode as re, reactive as cr, createSlots as _n, normalizeProps as _r, guardReactiveProps as Un, onUnmounted as ti, watchEffect as Gr, renderList as ar, createApp as Ru, inject as Ue, toRaw as Ge, h as ir, onBeforeUnmount as Iu, onRenderTriggered as ju, isVNode as Pu, resolveDirective as _s, normalizeClass as xs, withDirectives as gn, withModifiers as Ua, vShow as Ha, provide as Er } from "vue"; import { DatePicker as Va, Modal as Hn, Button as ei, Space as Tn, message as Ie, InputGroup as Nu, InputNumber as go, Input as Du, Select as Ti, Cascader as Fu, RangePicker as Bu, Table as Lu, Pagination as $u, Form as $s, Col as zu, Row as Uu, Alert as bo, Spin as Hu, Transfer as Vu, Menu as qu, MenuItem as Wu, Dropdown as Ku, DropdownButton as Xu } from "ant-design-vue"; import * as Yu from "@ant-design/icons-vue"; import { CloseOutlined as Gu, ShrinkOutlined as Zu, ArrowsAltOutlined as Ju, HolderOutlined as Qu, CopyOutlined as tc, LoadingOutlined as qa, FilterOutlined as ec, DownOutlined as Wa, UpOutlined as rc, SettingOutlined as nc } from "@ant-design/icons-vue"; import { useI18n as Ka } from "vue-i18n"; import { useRouter as ic } from "vue-router"; /*! * @yzsf2e/render-core v1.2.263 Wed Jul 22 2026 14:54:47 GMT+0800 (China Standard Time) * (c) 2023 @yzsf2e. */ const sc = "@yzsf2e/render-core", oc = "1.2.263", ac = "dist/render-core", lc = "dist/render-core", uc = [ "dist" ], cc = { dev: "storybook dev -p 6006", build: "vite build", lint: "vite lint", release: "node scripts/release.js --gitTag", "build-storybook": "storybook build" }, fc = { registry: "https://registry.npmjs.org/", access: "public" }, hc = "yzsf2e", dc = [ "vue3", "antdv", "frontend", "component", "components" ], pc = { "@ant-design/icons-vue": "7.0.1", "@vueuse/components": "^10.5.0", "@vueuse/core": "^10.5.0", "@yzsf2e/use": "workspace:^", "ant-design-vue": "3.2.20", axios: "^1.6.2", "big.js": "^6.2.1", dayjs: "1.11.10", exceljs: "^4.4.0", "file-saver": "^2.0.5", "lodash-es": "^4.17.21", store: "^2.0.12", "v-viewer": "^3.0.13", viewerjs: "^1.11.6", "vue-i18n": "^10.0.1", "vue-request": "^2.0.3", "vue-router": "^4.2.5" }, mc = { "@ant-design/icons-vue": "7.0.1", "ant-design-vue": "3.2.20", axios: "^1.6.2", vue: "3.3.4", "vue-i18n": "^10.0.1", "vue-router": "^4.2.5" }, gc = { "@storybook/addon-essentials": "^7.6.6", "@storybook/addon-interactions": "^7.6.6", "@storybook/addon-links": "^7.6.6", "@storybook/blocks": "^7.6.6", "@storybook/test": "^7.6.6", "@storybook/vue3": "^7.6.6", "@storybook/vue3-vite": "^7.6.6", "@types/file-saver": "^2.0.7", "@types/node": "^18.16.3", "@types/vue-i18n": "^7.0.0", "@vitejs/plugin-vue": "^4.0.0", "@vitejs/plugin-vue-jsx": "^3.0.0", autoprefixer: "^10.4.16", postcss: "^8.4.32", react: "^18.2.0", "react-dom": "^18.2.0", sass: "^1.69.5", storybook: "^7.6.6", typescript: "^5.0.4", vite: "^4.4.2", vue: "3.3.4" }, bc = { name: sc, version: oc, main: ac, module: lc, files: uc, scripts: cc, publishConfig: fc, author: hc, keywords: dc, dependencies: pc, peerDependencies: mc, devDependencies: gc }, zs = Object.assign, Je = `${location.origin}/api`, An = () => Hr().appContext.config.globalProperties.$axios; function Ss(c) { return Object.entries(c).map(([k, t]) => ({ label: t, value: k })); } const yo = () => ({ type: Array, default: () => [] }), yc = (c) => ({ type: Number, default: c }), vc = (c) => ({ type: Boolean, default: c }); function Ze(c) { return [`yzs-${c}`]; } const wc = /-(\w)/g, _c = (c) => c.replace(wc, (k, t) => t.toUpperCase()), rr = (c) => { const k = c; return k.install = function(t) { t.component(k.name, k), t.component(_c(`-${k.name}`), k); }, c; }, [xc] = Ze("date-picker"), Sc = { allowClear: !0, autofocus: !1, bordered: !0, format: "YYYY-MM-DD", nextIcon: "icon-right", open: !1, placement: "bottomLeft", popupStyle: {}, prevIcon: "icon-left", size: "small", suffixIcon: "icon-calendar", superNextIcon: "icon-double-right", superPrevIcon: "icon-double-left", valueFormat: "YYYY-MM-DD", renderExtraFooter: () => null, showNow: !0, showTime: !1, showToday: !0 }, kc = { dateRender: Function, disabled: Boolean, disabledDate: Function, dropdownClassName: String, getPopupContainer: Function, inputReadOnly: Boolean, locale: Object, mode: String, picker: String, placeholder: String, presets: Array, status: String, defaultPickerValue: Object, disabledTime: Function, format: String, value: Object }, Cc = /* @__PURE__ */ Ce({ name: xc, props: kc, emits: ["change", "ok", "update:value", "openChange", "panelChange"], setup(c, { emit: k, expose: t }) { const b = mt(null), g = Ht(() => zs(c, Sc)), f = (i) => { k("ok", i); }, s = (i) => { k("change", i), k("update:value", i); }, a = (i) => { k("openChange", i); }, r = (i, o) => { k("openChange", i, o); }; t({ blur: () => { var i; (i = b.value) == null || i.blur(); }, focus: () => { var i; (i = b.value) == null || i.focus(); } }); const l = { ...g.value, ok: f, onChange: s, onOpenChange: a, panelChange: r }; return () => Yt(Va, Me({ ref: b }, l), null); } }), Ec = rr(Cc), Tc = Ce({ name: "AIcon", components: Yu, props: { type: { required: !0, type: String } } }), fr = (c, k) => { const t = c.__vccOpts || c; for (const [b, g] of k) t[b] = g; return t; }; function Ac(c, k, t, b, g, f) { return wt(), qt(Xr(c.type)); } const Us = /* @__PURE__ */ fr(Tc, [["render", Ac]]), [Mc] = Ze("debounce-button"), Oc = { name: Mc }, Rc = /* @__PURE__ */ Ce({ ...Oc, props: { block: { type: Boolean }, danger: { type: Boolean }, disabled: { type: Boolean }, ghost: { type: Boolean }, href: {}, htmlType: {}, icon: {}, shape: {}, size: { default: "middle" }, target: {}, type: { default: "primary" }, loadingTime: { default: 5e3 }, style: {} }, emits: ["click"], setup(c, { emit: k }) { const t = c, b = mt(!1); let g = null; function f() { b.value || (b.value = !0, k("click", () => { b.value = !1, clearTimeout(g); }), g = setTimeout(() => { b.value = !1; }, t.loadingTime || 0)); } return (s, a) => { const r = Ft("a-button"); return wt(), qt(r, { block: s.block, danger: s.danger, disabled: s.disabled, ghost: s.ghost, href: s.href, "html-type": s.htmlType, icon: s.icon, shape: s.shape, size: s.size, target: s.target, type: s.type, loading: b.value, style: zr(s.style), onClick: f }, { default: Et(() => [ s.$slots.default ? ur(s.$slots, "default", { key: 0 }) : _e("", !0) ]), _: 3 }, 8, ["block", "danger", "disabled", "ghost", "href", "html-type", "icon", "shape", "size", "target", "type", "loading", "style"]); }; } }), Ic = rr(Rc); function Xa(c) { return Au() ? (Mu(c), !0) : !1; } function ri(c) { let k = !1, t; const b = Eu(!0); return (...g) => (k || (t = b.run(() => c(...g)), k = !0), t); } function nr(c) { return typeof c == "function" ? c() : ae(c); } const Ya = typeof window < "u" && typeof document < "u"; typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope; const jc = (c) => typeof c < "u", Pc = Object.prototype.toString, Nc = (c) => Pc.call(c) === "[object Object]", ks = () => { }; function Ga(c, k) { function t(...b) { return new Promise((g, f) => { Promise.resolve(c(() => k.apply(this, b), { fn: k, thisArg: this, args: b })).then(g).catch(f); }); } return t; } const Za = (c) => c(); function Dc(c, k = {}) { let t, b, g = ks; const f = (a) => { clearTimeout(a), g(), g = ks; }; return (a) => { const r = nr(c), e = nr(k.maxWait); return t && f(t), r <= 0 || e !== void 0 && e <= 0 ? (b && (f(b), b = null), Promise.resolve(a())) : new Promise((n, l) => { g = k.rejectOnCancel ? l : n, e && !b && (b = setTimeout(() => { t && f(t), b = null, n(a()); }, e)), t = setTimeout(() => { b && f(b), b = null, n(a()); }, r); }); }; } function Fc(c = Za) { const k = mt(!0); function t() { k.value = !1; } function b() { k.value = !0; } const g = (...f) => { k.value && c(...f); }; return { isActive: Ou(k), pause: t, resume: b, eventFilter: g }; } function Bc(c) { return c || Hr(); } function Lc(c, k = 200, t = {}) { return Ga( Dc(k, t), c ); } function $c(c, k, t = {}) { const { eventFilter: b = Za, ...g } = t; return ge( c, Ga( b, k ), g ); } function zc(c, k, t = {}) { const { eventFilter: b, ...g } = t, { eventFilter: f, pause: s, resume: a, isActive: r } = Fc(b); return { stop: $c( c, k, { ...g, eventFilter: f } ), pause: s, resume: a, isActive: r }; } function Uc(c, k = {}) { if (!er(c)) return br(c); const t = Array.isArray(c.value) ? Array.from({ length: c.value.length }) : {}; for (const b in c.value) t[b] = Tu(() => ({ get() { return c.value[b]; }, set(g) { var f; if ((f = nr(k.replaceRef)) != null ? f : !0) if (Array.isArray(c.value)) { const a = [...c.value]; a[b] = g, c.value = a; } else { const a = { ...c.value, [b]: g }; Object.setPrototypeOf(a, Object.getPrototypeOf(c.value)), c.value = a; } else c.value[b] = g; } })); return t; } function Hc(c, k = !0, t) { const b = Bc(t); b ? yr(c, b) : k ? c() : sr(c); } function Cs(c) { var k; const t = nr(c); return (k = t == null ? void 0 : t.$el) != null ? k : t; } const Vn = Ya ? window : void 0; function Bn(...c) { let k, t, b, g; if (typeof c[0] == "string" || Array.isArray(c[0]) ? ([t, b, g] = c, k = Vn) : [k, t, b, g] = c, !k) return ks; Array.isArray(t) || (t = [t]), Array.isArray(b) || (b = [b]); const f = [], s = () => { f.forEach((n) => n()), f.length = 0; }, a = (n, l, i, o) => (n.addEventListener(l, i, o), () => n.removeEventListener(l, i, o)), r = ge( () => [Cs(k), nr(g)], ([n, l]) => { if (s(), !n) return; const i = Nc(l) ? { ...l } : l; f.push( ...t.flatMap((o) => b.map((h) => a(n, o, h, i))) ); }, { immediate: !0, flush: "post" } ), e = () => { r(), s(); }; return Xa(e), e; } function Vc() { const c = mt(!1); return Hr() && yr(() => { c.value = !0; }), c; } function qc(c) { const k = Vc(); return Ht(() => (k.value, !!c())); } function Wc(c) { return JSON.parse(JSON.stringify(c)); } const gi = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, bi = "__vueuse_ssr_handlers__", Kc = /* @__PURE__ */ Xc(); function Xc() { return bi in gi || (gi[bi] = gi[bi] || {}), gi[bi]; } function Yc(c, k) { return Kc[c] || k; } function Gc(c) { return c == null ? "any" : c instanceof Set ? "set" : c instanceof Map ? "map" : c instanceof Date ? "date" : typeof c == "boolean" ? "boolean" : typeof c == "string" ? "string" : typeof c == "object" ? "object" : Number.isNaN(c) ? "any" : "number"; } const Zc = { boolean: { read: (c) => c === "true", write: (c) => String(c) }, object: { read: (c) => JSON.parse(c), write: (c) => JSON.stringify(c) }, number: { read: (c) => Number.parseFloat(c), write: (c) => String(c) }, any: { read: (c) => c, write: (c) => String(c) }, string: { read: (c) => c, write: (c) => String(c) }, map: { read: (c) => new Map(JSON.parse(c)), write: (c) => JSON.stringify(Array.from(c.entries())) }, set: { read: (c) => new Set(JSON.parse(c)), write: (c) => JSON.stringify(Array.from(c)) }, date: { read: (c) => new Date(c), write: (c) => c.toISOString() } }, vo = "vueuse-storage"; function Ni(c, k, t, b = {}) { var g; const { flush: f = "pre", deep: s = !0, listenToStorageChanges: a = !0, writeDefaults: r = !0, mergeDefaults: e = !1, shallow: n, window: l = Vn, eventFilter: i, onError: o = (D) => { console.error(D); }, initOnMounted: h } = b, d = (n ? Fn : mt)(typeof k == "function" ? k() : k); if (!t) try { t = Yc("getDefaultStorage", () => { var D; return (D = Vn) == null ? void 0 : D.localStorage; })(); } catch (D) { o(D); } if (!t) return d; const u = nr(k), p = Gc(u), m = (g = b.serializer) != null ? g : Zc[p], { pause: x, resume: C } = zc( d, () => M(d.value), { flush: f, deep: s, eventFilter: i } ); return l && a && Hc(() => { Bn(l, "storage", j), Bn(l, vo, $), h && j(); }), h || j(), d; function M(D) { try { if (D == null) t.removeItem(c); else { const F = m.write(D), z = t.getItem(c); z !== F && (t.setItem(c, F), l && l.dispatchEvent(new CustomEvent(vo, { detail: { key: c, oldValue: z, newValue: F, storageArea: t } }))); } } catch (F) { o(F); } } function P(D) { const F = D ? D.newValue : t.getItem(c); if (F == null) return r && u != null && t.setItem(c, m.write(u)), u; if (!D && e) { const z = m.read(F); return typeof e == "function" ? e(z, u) : p === "object" && !Array.isArray(z) ? { ...u, ...z } : z; } else return typeof F != "string" ? F : m.read(F); } function $(D) { j(D.detail); } function j(D) { if (!(D && D.storageArea !== t)) { if (D && D.key == null) { d.value = u; return; } if (!(D && D.key !== c)) { x(); try { (D == null ? void 0 : D.newValue) !== m.write(d.value) && (d.value = P(D)); } catch (F) { o(F); } finally { D ? sr(C) : C(); } } } } } function Jc(c, k = {}) { var t, b; const { pointerTypes: g, preventDefault: f, stopPropagation: s, exact: a, onMove: r, onEnd: e, onStart: n, initialValue: l, axis: i = "both", draggingElement: o = Vn, containerElement: h, handle: d = c } = k, u = mt( (t = nr(l)) != null ? t : { x: 0, y: 0 } ), p = mt(), m = ($) => g ? g.includes($.pointerType) : !0, x = ($) => { nr(f) && $.preventDefault(), nr(s) && $.stopPropagation(); }, C = ($) => { var j; if (!m($) || nr(a) && $.target !== nr(c)) return; const D = nr(h), F = (j = D == null ? void 0 : D.getBoundingClientRect) == null ? void 0 : j.call(D), z = nr(c).getBoundingClientRect(), L = { x: $.clientX - (D ? z.left - F.left : z.left), y: $.clientY - (D ? z.top - F.top : z.top) }; (n == null ? void 0 : n(L, $)) !== !1 && (p.value = L, x($)); }, M = ($) => { var j; if (!m($) || !p.value) return; const D = nr(h), F = (j = D == null ? void 0 : D.getBoundingClientRect) == null ? void 0 : j.call(D), z = nr(c).getBoundingClientRect(); let { x: L, y: E } = u.value; (i === "x" || i === "both") && (L = $.clientX - p.value.x, D && (L = Math.min(Math.max(0, L), F.width - z.width))), (i === "y" || i === "both") && (E = $.clientY - p.value.y, D && (E = Math.min(Math.max(0, E), F.height - z.height))), u.value = { x: L, y: E }, r == null || r(u.value, $), x($); }, P = ($) => { m($) && p.value && (p.value = void 0, e == null || e(u.value, $), x($)); }; if (Ya) { const $ = { capture: (b = k.capture) != null ? b : !0 }; Bn(d, "pointerdown", C, $), Bn(o, "pointermove", M, $), Bn(o, "pointerup", P, $); } return { ...Uc(u), position: u, isDragging: Ht(() => !!p.value), style: Ht( () => `left:${u.value.x}px;top:${u.value.y}px;` ) }; } function Qc(c, k, t = {}) { const { window: b = Vn, ...g } = t; let f; const s = qc(() => b && "ResizeObserver" in b), a = () => { f && (f.disconnect(), f = void 0); }, r = Ht(() => Array.isArray(c) ? c.map((l) => Cs(l)) : [Cs(c)]), e = ge( r, (l) => { if (a(), s.value && b) { f = new ResizeObserver(k); for (const i of l) i && f.observe(i, g); } }, { immediate: !0, flush: "post", deep: !0 } ), n = () => { a(), e(); }; return Xa(n), { isSupported: s, stop: n }; } function Sr(c, k, t, b = {}) { var g, f, s; const { clone: a = !1, passive: r = !1, eventName: e, deep: n = !1, defaultValue: l, shouldEmit: i } = b, o = Hr(), h = t || (o == null ? void 0 : o.emit) || ((g = o == null ? void 0 : o.$emit) == null ? void 0 : g.bind(o)) || ((s = (f = o == null ? void 0 : o.proxy) == null ? void 0 : f.$emit) == null ? void 0 : s.bind(o == null ? void 0 : o.proxy)); let d = e; k || (k = "modelValue"), d = d || `update:${k.toString()}`; const u = (x) => a ? typeof a == "function" ? a(x) : Wc(x) : x, p = () => jc(c[k]) ? u(c[k]) : l, m = (x) => { i ? i(x) && h(d, x) : h(d, x); }; if (r) { const x = p(), C = mt(x); let M = !1; return ge( () => c[k], (P) => { M || (M = !0, C.value = u(P), sr(() => M = !1)); } ), ge( C, (P) => { !M && (P !== c[k] || n) && m(P); }, { deep: n } ), C; } else return Ht({ get() { return p(); }, set(x) { m(x); } }); } const [tf] = Ze("drag-drawer"), ef = Ce({ name: tf, components: { CloseOutlined: Gu, ShrinkOutlined: Zu, ArrowsAltOutlined: Ju }, props: { visible: { type: Boolean, default: !1 }, title: { type: String, default: "" }, mask: { type: Boolean, default: !1 }, width: { type: [Number, String], default: 500 }, getContainer: { type: Function, default: () => { if (document.querySelector(".page-renderer-wrapper")) return document.querySelector(".page-renderer-wrapper"); if (document.querySelector(".main__container")) return document.querySelector(".main__container"); } }, hideFooter: { type: Boolean, default: !1 } }, setup(c, { emit: k }) { const t = mt(null), b = Sr(c, "visible", k), g = mt(c.width), f = mt(!1), s = () => b.value = !1, a = () => c.getContainer(), r = a(), e = 500, n = () => { g.value = f.value ? c.width : "100%", f.value = !f.value; }; return ge(b, (i) => { i || (f.value = !1, g.value = c.width); }), { show: b, fullScreen: f, dragDrawer: t, actualWidth: g, getContainerFn: a, handleClose: s, toggleFullScreen: n, handleMouseDown: (i) => { const o = i.clientX, h = g.value, d = (r == null ? void 0 : r.clientWidth) || document.body.clientWidth; document.body.classList.add("disable-select-in-dragging"), window.onmousemove = function(u) { const m = u.clientX - o, x = typeof h == "number" ? h - m : window.innerWidth - u.x; g.value = Math.min(x < e ? e : x, d); }, window.onmouseup = () => { window.onmousemove = null, document.body.classList.remove("disable-select-in-dragging"); }; } }; } }); const rf = { key: 0, style: { position: "absolute", bottom: "0", left: "0", height: "50px", "line-height": "49px", width: "100%", "border-top": "1px solid #eee", "box-sizing": "content-box", "background-color": "#fff", "z-index": "2" } }; function nf(c, k, t, b, g, f) { const s = Ft("ArrowsAltOutlined"), a = Ft("ShrinkOutlined"), r = Ft("CloseOutlined"), e = Ft("a-space"), n = Ft("a-button"), l = Ft("a-drawer"); return wt(), qt(l, { ref: "dragDrawer", class: "drag-drawer-warpper", placement: "right", mask: c.mask, width: c.actualWidth, "get-container": c.getContainerFn, closable: !1, "destroy-on-close": !0, push: !0, visible: c.show, "onUpdate:visible": k[1] || (k[1] = (i) => c.show = i) }, { title: Et(() => [ c.title ? (wt(), ne(Re, { key: 0 }, [ Ne(fe(c.title), 1) ], 64)) : ur(c.$slots, "title", { key: 1 }) ]), extra: Et(() => [ Yt(e, { style: { transform: "translateY(2px)" } }, { default: Et(() => [ c.fullScreen ? (wt(), qt(a, { key: 1, style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" }, onClick: c.toggleFullScreen }, null, 8, ["onClick"])) : (wt(), qt(s, { key: 0, style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" }, onClick: c.toggleFullScreen }, null, 8, ["onClick"])), Yt(r, { style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" }, onClick: c.handleClose }, null, 8, ["onClick"]) ]), _: 1 }) ]), default: Et(() => [ ur(c.$slots, "default"), re("div", { class: "drag-trigger", onMousedown: k[0] || (k[0] = (i) => c.handleMouseDown(i)) }, null, 32), c.hideFooter ? _e("", !0) : (wt(), ne("div", rf, [ Yt(e, { style: { "padding-left": "20px" } }, { default: Et(() => [ Yt(n, { onClick: c.handleClose }, { default: Et(() => [ Ne(fe(c.$t("close") || "关闭"), 1) ]), _: 1 }, 8, ["onClick"]), ur(c.$slots, "footBtn") ]), _: 3 }) ])) ]), _: 3 }, 8, ["mask", "width", "get-container", "visible"]); } const sf = /* @__PURE__ */ fr(ef, [["render", nf]]), of = rr(sf), hr = () => { try { return Ka(); } catch { return { t: () => { } }; } }, [af] = Ze("page-renderer-form-modal"), lf = Ce({ name: af, components: { Modal: Hn, Button: ei, Space: Tn }, props: { form: { type: Object, required: !0 }, rows: { type: Array, default: () => [] }, extraData: { type: Object }, getContainer: { type: Function, default: () => { if (document.querySelector(".page-renderer-wrapper")) return document.querySelector(".page-renderer-wrapper"); if (document.querySelector(".main__container")) return document.querySelector(".main__container"); } } }, emits: ["refresh"], setup(c, { expose: k, emit: t }) { const { t: b } = hr(), { form: g } = br(c), f = mt(!1), s = mt(!1), a = mt(null), r = cr({ showOk: !0 }), e = async () => { var o, h; s.value = !0; const i = ((o = a.value) == null ? void 0 : o.finish) || (() => Promise.resolve({ success: !0 })); (h = a.value) != null && h.finish || console.warn("form组件没有提供finish方法"), i().then((d) => { const { needFeedback: u = !0, needRefresh: p = !0, successMsg: m = b("operationSuccessful") || "操作成功" } = g.value; s.value = !1, d && d.success && (u && Ie.success(m), l(), p && t("refresh")); }).catch((d) => { var p; if (s.value = !1, console.log("[PageRendererFormModal handleOk Error]: ", d), typeof d == "string") return Ie.warn(d); const { errorFields: u } = d; u && u.length && Ie.warn((p = u[0]) == null ? void 0 : p.errors.join("、")); }); }; ge(f, (i) => { i && sr(() => { const o = document.querySelector(".ant-modal-root"), h = o == null ? void 0 : o.querySelector(".ant-modal-header"), d = o == null ? void 0 : o.querySelector(".ant-modal"); h.style.cursor = "move"; const u = d.currentStyle || window.getComputedStyle(d, null); h.onmousedown = (p) => { const m = p.clientX - h.offsetLeft, x = p.clientY - h.offsetTop; let C, M; u.left.includes("%") ? (C = +document.body.clientWidth * (+u.left.replace(/%/g, "") / 100), M = +document.body.clientHeight * (+u.top.replace(/%/g, "") / 100)) : (C = +u.left.replace(/\px/g, ""), M = +u.top.replace(/\px/g, "")), document.onmousemove = function(P) { const $ = P.clientX - m, j = P.clientY - x; d.style.left = `${$ + C}px`, d.style.top = `${j + M}px`; }, document.onmouseup = function() { document.onmousemove = null, document.onmouseup = null; }; }; }); }); const n = () => f.value = !0, l = () => { var i, o; (o = (i = a.value) == null ? void 0 : i.reset) == null || o.call(i), f.value = !1; }; return k({ openModal: n, closeModal: l }), { handleOk: e, closeModal: l, visible: f, modalConfig: r, currentForm: a, confirmLoading: s }; } }); const uf = { key: 1 }; function cf(c, k, t, b, g, f) { const s = Ft("Button"), a = Ft("Space"), r = Ft("Modal"); return wt(), qt(r, Me({ "wrap-class-name": "drag-modal-wrapper", visible: c.visible, "onUpdate:visible": k[1] || (k[1] = (e) => c.visible = e) }, c.form.modalProps, { "destroy-on-close": !0, "get-container": c.getContainer, onCancel: c.closeModal }), { title: Et(() => [ re("span", null, fe(c.form.title), 1) ]), footer: Et(() => { var e; return [ ((e = c.form.modalProps) == null ? void 0 : e.hideFooter) !== !0 ? (wt(), qt(a, { key: 0 }, { default: Et(() => { var n; return [ Yt(s, { onClick: c.closeModal }, { default: Et(() => { var l; return [ Ne(fe(((l = c.form.modalProps) == null ? void 0 : l.cancelText) || c.$t("cancel") || "取消"), 1) ]; }), _: 1 }, 8, ["onClick"]), ((n = c.form.modalProps) == null ? void 0 : n.hideOkButton) !== !0 && c.modalConfig.showOk ? (wt(), qt(s, { key: 0, type: "primary", onClick: c.handleOk, loading: c.confirmLoading }, { default: Et(() => { var l; return [ Ne(fe(((l = c.form.modalProps) == null ? void 0 : l.okText) || c.$t("ok") || "确定"), 1) ]; }), _: 1 }, 8, ["onClick", "loading"])) : _e("", !0) ]; }), _: 1 })) : _e("", !0) ]; }), default: Et(() => [ c.form.component ? (wt(), qt(Xr(c.form.component), Me({ key: 0, rows: c.rows, "extra-data": c.extraData }, c.form.props, { modalConfig: c.modalConfig, "onUpdate:modalConfig": k[0] || (k[0] = (e) => c.modalConfig = e), ref: "currentForm" }), null, 16, ["rows", "extra-data", "modalConfig"])) : (wt(), ne("span", uf, "form配置中没有为【" + fe(c.form.title) + "】事件提供组件", 1)) ]), _: 1 }, 16, ["visible", "get-container", "onCancel"]); } const Ja = /* @__PURE__ */ fr(lf, [["render", cf]]), ff = rr(Ja), [hf] = Ze("drag-modal-plus"), df = Ce({ name: hf, components: { Modal: Hn, Button: ei, Space: Tn }, props: { visible: { type: Boolean, default: !1 }, title: { type: String, default: "标题" }, width: { type: [Number, String], default: 500 }, cancelText: { type: String, default: "" }, modalProps: { type: Object, default: () => ({}) }, getContainer: { type: Function, default: () => { if (document.querySelector(".page-renderer-wrapper")) return document.querySelector(".page-renderer-wrapper"); if (document.querySelector(".main__container")) return document.querySelector(".main__container"); } }, hideFooter: { type: Boolean, default: !1 } }, emits: ["update:visible"], setup(c, { expose: k, emit: t }) { const b = mt(null), g = Sr(c, "visible", t); function f() { if (!g.value) return; const r = document.querySelector(".ant-modal-root"), e = r == null ? void 0 : r.querySelector(".ant-modal-header"), n = r == null ? void 0 : r.querySelector(".ant-modal"); e.style.cursor = "move"; const l = n.currentStyle || window.getComputedStyle(n, null); e.onmousedown = (i) => { const o = i.clientX - e.offsetLeft, h = i.clientY - e.offsetTop; let d, u; l.left.includes("%") ? (d = +document.body.clientWidth * (+l.left.replace(/%/g, "") / 100), u = +document.body.clientHeight * (+l.top.replace(/%/g, "") / 100)) : (d = +l.left.replace(/\px/g, ""), u = +l.top.replace(/\px/g, "")), document.onmousemove = function(p) { const m = p.clientX - o, x = p.clientY - h; n.style.left = `${m + d}px`, n.style.top = `${x + u}px`; }, document.onmouseup = function() { document.onmousemove = null, document.onmouseup = null; }; }; } ge(g, (r) => { sr(() => { setTimeout(f, 500); }); }, { immediate: !0, flush: "post" }); const s = () => g.value = !1; return k({ openModal: () => g.value = !0, closeModal: s }), { show: g, closeModal: s, dragModalPlusRef: b }; } }); function pf(c, k, t, b, g, f) { const s = Ft("Button"), a = Ft("Space"), r = Ft("Modal"); return wt(), qt(r, Me({ ref: "dragModalPlusRef", "wrap-class-name": "drag-modal-wrapper" }, c.modalProps, { visible: c.show, "onUpdate:visible": k[0] || (k[0] = (e) => c.show = e), width: c.width, "destroy-on-close": !0, "get-container": c.getContainer, onCancel: c.closeModal }), { title: Et(() => [ re("span", null, fe(c.title), 1) ]), footer: Et(() => [ c.hideFooter ? _e("", !0) : (wt(), qt(a, { key: 0 }, { default: Et(() => [ Yt(s, { onClick: c.closeModal }, { default: Et(() => [ Ne(fe(c.cancelText || c.$t("cancel") || "取消"), 1) ]), _: 1 }, 8, ["onClick"]), ur(c.$slots, "footBtn") ]), _: 3 })) ]), default: Et(() => [ ur(c.$slots, "default") ]), _: 3 }, 16, ["visible", "width", "get-container", "onCancel"]); } const mf = /* @__PURE__ */ fr(df, [["render", pf]]), gf = rr(mf), Qr = ri(() => { const c = An(), k = mt({}), t = mt({}), b = mt({}), g = async (r, e) => { const n = `${r}-${e}`; if (b.value[n]) return b.value[n]; const l = await c({ url: `${Je}/base-biz-data-server/query/data/apiDataSource/${r}/${e}`, method: "get" }); return b.value[n] = l.data, b.value[n]; }; return { getApiDataSource: g, getEnumData: async (r, e, n) => { const l = n ? JSON.stringify(n) : "", i = `${r}-${e}-${l}`; if (t.value[i]) return t.value[i]; const o = await g(r, e); o.async && !location.href.includes("carrierglobe") && (Ie.warn(`当前词条 ${e} 是懒加载数据源,请使用 YzsEnumFuzzySelect 组件!`), console.error(`当前词条 ${e} 是懒加载数据源,请使用 YzsEnumFuzzySelect 组件!`)); let h = {}; try { h = JSON.parse(o.apiParam); } catch { h = {}; } const d = await c({ url: `${Je}${o.apiUrl}`, method: o.apiPost ? "post" : "get", [o.apiPost ? "data" : "params"]: { ...h, ...n } }); return t.value[i] = d, t.value[i]; }, getI18nBizCodeList: async (r, e, n) => (await c({ url: `${Je}/base-biz-data-server/query/i18n/biz/code/list`, method: "post", data: { codeType: r, attributeName: e, dataCodes: n } })).data, getDepartmentAuthData: async () => { if (k.value.auth) return k.value; const [r, e] = await Promise.all([ c({ url: `${Je}/iam-auth-web/auth/user/token/userInfo`, method: "post" }), c({ url: `${Je}/iam-auth-web/auth/user/user/data/org`, method: "get" }) ]); return k.value.auth = e.data, k.value.userInfo = r.data, k.value; } }; }), [bf] = Ze("enum-select"), yf = { name: bf }, vf = /* @__PURE__ */ Ce({ ...yf, props: { value: {}, code: {}, name: {}, label: {}, codeType: { default: "we" }, required: { type: Boolean }, showLabel: { type: Boolean, default: !0 }, disabled: { type: Boolean }, placeholder: {}, params: {}, formItemProps: {}, selectProps: { default: () => ({ allowClear: !0, showSearch: !0 }) }, transform: {} }, emits: ["update:value", "pressEnter", "change"], setup(c, { emit: k }) { const t = c, { t: b } = hr(), g = Sr(t, "value", k); let f = ""; const s = mt([]), { getEnumData: a } = Qr(), r = Ht(() => ({ required: t.required, ...t.formItemProps })), e = Ht(() => ({ allowClear: !0, showSearch: !0, optionFilterProp: "label", ...t.selectProps, disabled: t.disabled, placeholder: t.disabled ? "" : n() })); function n() { return t.placeholder ? t.placeholder : b("pleaseSelect") ? `${b("pleaseSelect")}${t.label || b(t.code)}` : ""; } async function l() { const u = await a(t.codeType, t.code, t.params); s.value = await (t.transform ? Promise.resolve(t.transform(u)) : Promise.resolve(u.data)); } ge( [() => t.codeType, () => t.code, () => t.params], () => { l(); }, { deep: !0, immediate: !0 } ); function i(u) { (u.keyCode === 13 || u.key === "Enter") && setTimeout(() => k("pressEnter")); } function o(u) { k("change", u); } function h(u) { f = u; } const d = (u = "", p) => { const m = u.trim().toLowerCase(); return String(p.label ?? p.value).toLowerCase().includes(m); }; return (u, p) => { const m = Ft("a-select"), x = Ft("a-form-item"); return u.showLabel !== !1 ? (wt(), qt(x, Me({ key: 0, name: u.name, label: u.label || ae(b)(u.code) || u.code }, r.value), { default: Et(() => [ Yt(m, Me({ value: ae(g), "onUpdate:value": p[0] || (p[0] = (C) => er(g) ? g.value = C : null), options: s.value }, e.value, { class: [{ "enum-select-selector-active": Array.isArray(ae(g)) ? ae(g).length > 0 : ae(g) }, "enum-select-selector"], "filter-option": d, onSearch: h, onChange: o, onKeydown: i }), _n({ _: 2 }, [ u.$slots.option ? { name: "option", fn: Et((C) => [ ur(u.$slots, "option", _r(Un({ ...C, searchValue: ae(f) }))) ]), key: "0" } : void 0 ]), 1040, ["value", "options", "class"]) ]), _: 3 }, 16, ["name", "label"])) : (wt(), qt(m, Me({ key: 1, value: ae(g), "onUpdate:value": p[1] || (p[1] = (C) => er(g) ? g.value = C : null), options: s.value }, e.value, { class: [{ "enum-select-selector-active": Array.isArray(ae(g)) ? ae(g).length > 0 : ae(g) }, "enum-select-selector"], "filter-option": d, onSearch: h, onChange: o, onKeydown: i }), _n({ _: 2 }, [ u.$slots.option ? { name: "option", fn: Et((C) => [ ur(u.$slots, "option", _r(Un({ ...C, searchValue: ae(f) }))) ]), key: "0" } : void 0 ]), 1040, ["value", "options", "class"])); }; } }); const Qa = rr(vf), wf = ["title"], _f = ["innerHTML"], xf = { key: 0, class: "yzs-select-staff-option-extinfo" }, Sf = { key: 1, class: "yzs-select-staff-option-resigned" }, [kf] = Ze("select-staff-option"), Cf = { name: kf }, tl = /* @__PURE__ */ Ce({ ...Cf, props: { label: { default: "" }, value: {}, searchValue: { default: "" }, ext: { default: { resign: 0, mainDeptNames: "" // '北方营销中心/智能科技部', } } }, setup(c) { const k = (t, b) => { if (!b) return t; const g = new RegExp(`(${b})`, "gi"); return t.replace( g, '<span style="color:#448ef7;">$1</span>' ); }; return (t, b) => (wt(), ne("div", { class: "yzs-select-staff-option", title: `${t.label} ${t.ext.mainDeptNames ? "/" + t.ext.mainDeptNames : ""} ${t.ext.resign == 1 ? "[已离职]" : ""}` }, [ re("span", { innerHTML: k(t.label, t.searchValue) }, null, 8, _f), Ne("   "), t.ext.mainDeptNames ? (wt(), ne("span", xf, "/" + fe(t.ext.mainDeptNames) + "  ", 1)) : _e("", !0), t.ext.resign == 1 ? (wt(), ne("span", Sf, "已离职")) : _e("", !0) ], 8, wf)); } }); const [Ef] = Ze("enum-custom-select"), Tf = { name: Ef }, Af = /* @__PURE__ */ Ce({ ...Tf, props: { value: {}, code: {}, name: {}, label: {}, codeType: { default: "we" }, required: { type: Boolean }, showLabel: { type: Boolean, default: !0 }, disabled: { type: Boolean }, placeholder: {}, params: {}, formItemProps: {}, selectProps: {}, transform: {}, auth: {} }, emits: ["update:value", "pressEnter", "change"], setup(c, { emit: k }) { const t = c, b = Sr(t, "value", k), g = mt(!1), f = mt({ access: "", departments: [] }); let s = (l) => (l == null ? void 0 : l.data) || []; const { getDepartmentAuthData: a } = Qr(); r(t.auth); function r(l) { l === "DEPARTMENT" && (g.value = !0, a().then((i) => { f.value = i.auth, s = (o) => { if (i.auth.access === "SELF") return [{ label: i.userInfo.nick, value: i.userInfo.huid, ext: { mainDeptNames: "", resign: "0" } }]; if (i.auth.access === "DEPT") { const h = (o == null ? void 0 : o.data) || [], d = (i.auth.departments || []).map((u) => u.departmentId); return h.filter((u) => d.some((p) => { var m; return (((m = u == null ? void 0 : u.ext) == null ? void 0 : m.mainDeptIds) || "").includes(p); })); } else if (i.auth.access === "ALL") return (o == null ? void 0 : o.data) || []; return (o == null ? void 0 : o.data) || []; }; }).finally(() => { g.value = !1; })); } const e = () => k("pressEnter"), n = (l) => k("change", l); return (l, i) => { const o = Ft("YzsEnumFuzzyCustomSelect"), h = Ft("YzsEnumSelect"); return g.value ? _e("", !0) : (wt(), ne(Re, { key: 0 }, [ f.value.access === "ALL" ? (wt(), qt(o, Me({ key: 0 }, t, { value: ae(b), "onUpdate:value": i[0] || (i[0] = (d) => er(b) ? b.value = d : null), "show-warn": !1, onPressEnter: e, onChange: n }), null, 16, ["value"])) : (wt(), qt(h, Me({ key: 1 }, t, { value: ae(b), "onUpdate:value": i[1] || (i[1] = (d) => er(b) ? b.value = d : null), transform: ae(s), onPressEnter: e, onChange: n }), { option: Et(({ value: d, label: u, ext: p, searchValue: m }) => [ Yt(tl, { value: d, label: u, ext: p, searchValue: m }, null, 8, ["value", "label", "ext", "searchValue"]) ]), _: 1 }, 16, ["value", "transform"])) ], 64)); }; } }), el = rr(Af); var Mf = typeof global == "object" && global && global.Object === Object && global; const rl = Mf; var Of = typeof self == "object" && self && self.Object === Object && self, Rf = rl || Of || Function("return this")(); const kr = Rf; var If = kr.Symbol; const Mr = If; var nl = Object.prototype, jf = nl.hasOwnProperty, Pf = nl.toString, Pn = Mr ? Mr.toStringTag : void 0; function Nf(c) { var k = jf.call(c, Pn), t = c[Pn]; try { c[Pn] = void 0; var b = !0; } catch { } var g = Pf.call(c); return b && (k ? c[Pn] = t : delete c[Pn]), g; } var Df = Object.prototype, Ff = Df.toString; function Bf(c) { return Ff.call(c); } var Lf = "[object Null]", $f = "[object Undefined]", wo = Mr ? Mr.toStringTag : void 0; function tn(c) { return c == null ? c === void 0 ? $f : Lf : wo && wo in Object(c) ? Nf(c) : Bf(c); } function jr(c) { return c != null && typeof c == "object"; } var zf = "[object Symbol]"; function xn(c) { return typeof c == "symbol" || jr(c) && tn(c) == zf; } function bn(c, k) { for (var t = -1, b = c == null ? 0 : c.length, g = Array(b); ++t < b; ) g[t] = k(c[t], t, c); return g; } var Uf = Array.isArray; const Qe = Uf; var Hf = 1 / 0, _o = Mr ? Mr.prototype : void 0, xo = _o ? _o.toString : void 0; function il(c) { if (typeof c == "string") return c; if (Qe(c)) return bn(c, il) + ""; if (xn(c)) return xo ? xo.call(c) : ""; var k = c + ""; return k == "0" && 1 / c == -Hf ? "-0" : k; } var Vf = /\s/; function qf(c) { for (var k = c.length; k-- && Vf.test(c.charAt(k)); ) ; return k; } var Wf = /^\s+/; function Kf(c) { return c && c.slice(0, qf(c) + 1).replace(Wf, ""); } function gr(c) { var k = typeof c; return c != null && (k == "object" || k == "function"); } var So = 0 / 0, Xf = /^[-+]0x[0-9a-f]+$/i, Yf = /^0b[01]+$/i, Gf = /^0o[0-7]+$/i, Zf = parseInt; function Es(c) { if (typeof c == "number") return c; if (xn(c)) return So; if (gr(c)) { var k = typeof c.valueOf == "function" ? c.valueOf() : c; c = gr(k) ? k + "" : k; } if (typeof c != "string") return c === 0 ? c : +c; c = Kf(c); var t = Yf.test(c); return t || Gf.test(c) ? Zf(c.slice(2), t ? 2 : 8) : Xf.test(c) ? So : +c; } var ko = 1 / 0, Jf = 17976931348623157e292; function Qf(c) { if (!c) return c === 0 ? c : 0; if (c = Es(c), c === ko || c === -ko) { var k = c < 0 ? -1 : 1; return k * Jf; } return c === c ? c : 0; } function th(c) { var k = Qf(c), t = k % 1; return k === k ? t ? k - t : k : 0; } function sl(c) { return c; } var eh = "[object AsyncFunction]", rh = "[object Function]", nh = "[object GeneratorFunction]", ih = "[object Proxy]"; function ol(c) { if (!gr(c)) return !1; var k = tn(c); return k == rh || k == nh || k == eh || k == ih; } var sh = kr["__core-js_shared__"]; const us = sh; var Co = function() { var c = /[^.]+$/.exec(us && us.keys && us.keys.IE_PROTO || ""); return c ? "Symbol(src)_1." + c : ""; }(); function oh(c) { return !!Co && Co in c; } var ah = Function.prototype, lh = ah.toString; function en(c) { if (c != null) { try { return lh.call(c); } catch { } try { return c + ""; } catch { } } return ""; } var uh = /[\\^$.*+?()[\]{}|]/g, ch = /^\[object .+?Constructor\]$/, fh = Function.prototype, hh = Object.prototype, dh = fh.toString, ph = hh.hasOwnProperty, mh = RegExp( "^" + dh.call(ph).replace(uh, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$" ); function gh(c) { if (!gr(c) || oh(c)) return !1; var k = ol(c) ? mh : ch; return k.test(en(c)); } function bh(c, k) { return c == null ? void 0 : c[k]; } function rn(c, k) { var t = bh(c, k); return gh(t) ? t : void 0; } var yh = rn(kr, "WeakMap"); const Ts = yh; var Eo = Object.create, vh = function() { function c() { } return function(k) { if (!gr(k)) return {}; if (Eo) return Eo(k); c.prototype = k; var t = new c(); return c.prototype = void 0, t; }; }(); const wh = vh; function _h() { } function xh(c, k) { var t = -1, b = c.length; for (k || (k = Array(b)); ++t < b; ) k[t] = c[t]; return k; } var Sh = function() { try { var c = rn(Object, "defineProperty"); return c({}, "", {}), c; } catch { } }(); const To = Sh; function kh(c, k) { for (var t = -1, b = c == null ? 0 : c.length; ++t < b && k(c[t], t, c) !== !1; ) ; return c; } function Ch(c, k, t, b) { for (var g = c.length, f = t + (b ? 1 : -1); b ? f-- : ++f < g; ) if (k(c[f], f, c)) return f; return -1; } function Eh(c) { return c !== c; } function Th(c, k, t) { for (var b = t - 1, g = c.length; ++b < g; ) if (c[b] === k) return b; return -1; } function al(c, k, t) { return k === k ? Th(c, k, t) : Ch(c, Eh, t); } function Ah(c, k) { var t = c == null ? 0 : c.length; return !!t && al(c, k, 0) > -1; } var Mh = 9007199254740991, Oh = /^(?:0|[1-9]\d*)$/; function qi(c, k) { var t = typeof c; return k = k ?? Mh, !!k && (t == "number" || t != "symbol" && Oh.test(c)) && c > -1 && c % 1 == 0 && c < k; } function Hs(c, k, t) { k == "__proto__" && To ? To(c, k, { configurable: !0, enumerable: !0, value: t, writable: !0 }) : c[k] = t; } function Wi(c, k) { return c === k || c !== c && k !== k; } var Rh = Object.prototype, Ih = Rh.hasOwnProperty; function Vs(c, k, t) { var b = c[k]; (!(Ih.call(c, k) && Wi(b, t)) || t === void 0 && !(k in c)) && Hs(c, k, t); } function Ki(c, k, t, b) { var g = !t; t || (t = {}); for (var f = -1, s = k.length; ++f < s; ) { var a = k[f], r = b ? b(t[a], c[a], a, t, c) : void 0; r === void 0 && (r = c[a]), g ? Hs(t, a, r) : Vs(t, a, r); } return t; } var jh = 9007199254740991; function qs(c) { return typeof c == "number" && c > -1 && c % 1 == 0 && c <= jh; } function Mn(c) { return c != null && qs(c.length) && !ol(c); } function Ph(c, k, t) { if (!gr(t)) return !1; var b = typeof k; return (b == "number" ? Mn(t) && qi(k, t.length) : b == "string" && k in t) ? Wi(t[k], c) : !1; } var Nh = Object.prototype; function Ws(c) { var k = c && c.constructor, t = typeof k == "function" && k.prototype || Nh; return c === t; } function Dh(c, k) { for (var t = -1, b = Array(c); ++t < c; ) b[t] = k(t); return b; } var Fh = "[object Arguments]"; function Ao(c) { return jr(c) && tn(c) == Fh; } var ll = Object.prototype, Bh = ll.hasOwnProperty, Lh = ll.propertyIsEnumerable, $h = Ao(function() { return arguments; }()) ? Ao : function(c) { return jr(c) && Bh.call(c, "callee") && !Lh.call(c, "callee"); }; const ul = $h; function zh() { return !1; } var cl = typeof exports == "object" && exports && !exports.nodeType && exports, Mo = cl && typeof module == "object" && module && !module.nodeType && module, Uh = Mo && Mo.exports === cl, Oo = Uh ? kr.Buffer : void 0, Hh = Oo ? Oo.isBuffer : void 0, Vh = Hh || zh; const Di = Vh; var qh = "[object Arguments]", Wh = "[object Array]", Kh = "[object Boolean]", Xh = "[object Date]", Yh = "[object Error]", Gh = "[object Function]", Zh = "[object Map]", Jh = "[object Number]", Qh = "[object Object]", td = "[object RegExp]", ed = "[object Set]", rd = "[object String]", nd = "[object WeakMap]", id = "[object ArrayBuffer]", sd = "[object DataView]", od = "[object Float32Array]", ad = "[object Float64Array]", ld = "[object Int8Array]", ud = "[object Int16Array]", cd = "[object Int32Array]", fd = "[object Uint8Array]", hd = "[object Uint8ClampedArray]", dd = "[object Uint16Array]", pd = "[object Uint32Array]", $e = {}; $e[od] = $e[ad] = $e[ld] = $e[ud] = $e[cd] = $e[fd] = $e[hd] = $e[dd] = $e[pd] = !0; $e[qh] = $e[Wh] = $e[id] = $e[Kh] = $e[sd] = $e[Xh] = $e[Yh] = $e[Gh] = $e[Zh] = $e[Jh] = $e[Qh] = $e[td] = $e[ed] = $e[rd] = $e[nd] = !1; function md(c) { return jr(c) && qs(c.length) && !!$e[tn(c)]; } function Xi(c) { return function(k) { return c(k); }; } var fl = typeof exports == "object" && exports && !exports.nodeType && exports, Ln = fl && typeof module == "object" && module && !module.nodeType && module, gd = Ln && Ln.exports === fl, cs = gd && rl.process, bd = function() { try { var c = Ln && Ln.require && Ln.require("util").types; return c || cs && cs.binding && cs.binding("util"); } catch { } }(); const Sn = bd; var Ro = Sn && Sn.isTypedArray, yd = Ro ? Xi(Ro) : md; const hl = yd; var vd = Object.prototype, wd = vd.hasOwnProperty; function dl(c, k) { var t = Qe(c), b = !t && ul(c), g = !t && !b && Di(c), f = !t && !b && !g && hl(c), s = t || b || g || f, a = s ? Dh(c.length, String) : [], r = a.length; for (var e in c) (k || wd.call(c, e)) && !(s && // Safari 9 has enumerable `arguments.length` in strict mode. (e == "length" || // Node.js 0.10 has enumerable non-index properties on buffers. g && (e == "offset" || e == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays. f && (e == "buffer" || e == "byteLength" || e == "byteOffset") || // Skip index properties. qi(e, r))) && a.push(e); return a; } function pl(c, k) { return function(t) { return c(k(t)); }; } var _d = pl(Object.keys, Object); const xd = _d; var Sd = Object.prototype, kd = Sd.hasOwnProperty; function Cd(c) { if (!Ws(c)) return xd(c); var k = []; for (var t in Object(c)) kd.call(c, t) && t != "constructor" && k.push(t); return k; } function On(c) { return Mn(c) ? dl(c) : Cd(c); } function Ed(c) { var k = []; if (c != null) for (var t in Object(c)) k.push(t); return k; } var Td = Object.prototyp