@yzsf2e/render-core
Version:
1,704 lines • 1.7 MB
JavaScript
import { getCurrentInstance as $r, defineComponent as ke, ref as bt, computed as Yt, createVNode as Ut, mergeProps as Le, openBlock as wt, createBlock as Wt, resolveDynamicComponent as bn, resolveComponent as Nt, normalizeStyle as Vr, withCtx as Ct, renderSlot as Tr, createCommentVNode as Me, effectScope as bu, unref as Se, isRef as ar, toRefs as pr, customRef as yu, onMounted as Or, nextTick as tr, getCurrentScope as vu, onScopeDispose as wu, readonly as _u, watch as ve, shallowRef as Pn, createElementBlock as ie, Fragment as De, createTextVNode as Re, toDisplayString as me, createElementVNode as Ye, reactive as or, onUnmounted as Jn, watchEffect as Xr, renderList as ir, createApp as xu, inject as ze, toRaw as Xe, h as Qe, onRenderTriggered as Su, isVNode as ku, resolveDirective as Da, createSlots as Ba, withDirectives as Ln, withModifiers as Fa, normalizeClass as La, normalizeProps as ln, vShow as $a, guardReactiveProps as Cu, provide as Fr } from "vue";
import { DatePicker as za, Modal as $n, Button as Qn, Space as kn, message as Be, InputGroup as Eu, InputNumber as lo, Input as Tu, Select as ki, Cascader as Au, RangePicker as Mu, Table as Ou, Form as js, Col as Ru, Row as Iu, Alert as uo, Spin as ju, Transfer as Pu, Menu as Nu, MenuItem as Du, Dropdown as Bu, Pagination as Fu, DropdownButton as Lu } from "ant-design-vue";
import * as $u from "@ant-design/icons-vue";
import { CloseOutlined as zu, ShrinkOutlined as Uu, ArrowsAltOutlined as Hu, HolderOutlined as qu, CopyOutlined as Vu, LoadingOutlined as Ua, FilterOutlined as Wu, DownOutlined as Ha, UpOutlined as Ku, SettingOutlined as Xu } from "@ant-design/icons-vue";
import { useI18n as qa } from "vue-i18n";
import { useRouter as Yu } from "vue-router";
/*!
* @yzsf2e/render-core v1.0.2-alpha.201 Wed Aug 20 2025 09:30:38 GMT+0800 (中国标准时间)
* (c) 2023 @yzsf2e.
*/
const Gu = "@yzsf2e/render-core", Zu = "1.0.2-alpha.201", Ju = "dist/render-core", Qu = "dist/render-core", tc = [
"dist"
], ec = {
dev: "storybook dev -p 6006",
build: "vite build",
lint: "vite lint",
release: "node scripts/release.js --gitTag",
"build-storybook": "storybook build"
}, rc = {
registry: "https://registry.npmjs.org/",
access: "public"
}, nc = "yzsf2e", ic = [
"vue3",
"antdv",
"frontend",
"component",
"components"
], sc = {
"@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"
}, oc = {
"@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"
}, ac = {
"@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"
}, lc = {
name: Gu,
version: Zu,
main: Ju,
module: Qu,
files: tc,
scripts: ec,
publishConfig: rc,
author: nc,
keywords: ic,
dependencies: sc,
peerDependencies: oc,
devDependencies: ac
}, Ps = Object.assign, hr = location.href.includes("carrierglobe") ? "https://api.carrierglobe.com" : "https://api.fat.driverglobe.com/api", ti = () => $r().appContext.config.globalProperties.$axios;
function co(f) {
return Object.entries(f).map(([k, t]) => ({
label: t,
value: k
}));
}
const ss = () => ({
type: Array,
default: () => []
}), uc = (f) => ({
type: Number,
default: f
});
function er(f) {
return [`yzs-${f}`];
}
const cc = /-(\w)/g, fc = (f) => f.replace(cc, (k, t) => t.toUpperCase()), lr = (f) => {
const k = f;
return k.install = function(t) {
t.component(k.name, k), t.component(fc(`-${k.name}`), k);
}, f;
}, [hc] = er("date-picker"), dc = {
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
}, pc = {
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
}, mc = /* @__PURE__ */ ke({
name: hc,
props: pc,
emits: ["change", "ok", "update:value", "openChange", "panelChange"],
setup(f, {
emit: k,
expose: t
}) {
const g = bt(null), b = Yt(() => Ps(f, dc)), u = (i) => {
k("ok", i);
}, s = (i) => {
k("change", i), k("update:value", i);
}, a = (i) => {
k("openChange", i);
}, n = (i, o) => {
k("openChange", i, o);
};
t({
blur: () => {
var i;
(i = g.value) == null || i.blur();
},
focus: () => {
var i;
(i = g.value) == null || i.focus();
}
});
const l = {
...b.value,
ok: u,
onChange: s,
onOpenChange: a,
panelChange: n
};
return () => Ut(za, Le({
ref: g
}, l), null);
}
}), gc = lr(mc), bc = ke({
name: "AIcon",
components: $u,
props: {
type: {
required: !0,
type: String
}
}
}), ur = (f, k) => {
const t = f.__vccOpts || f;
for (const [g, b] of k)
t[g] = b;
return t;
};
function yc(f, k, t, g, b, u) {
return wt(), Wt(bn(f.type));
}
const Ns = /* @__PURE__ */ ur(bc, [["render", yc]]), [vc] = er("debounce-button"), wc = { name: vc }, _c = /* @__PURE__ */ ke({
...wc,
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(f, { emit: k }) {
const t = f, g = bt(!1);
let b = null;
function u() {
g.value || (g.value = !0, k("click", () => {
g.value = !1, clearTimeout(b);
}), b = setTimeout(() => {
g.value = !1;
}, t.loadingTime || 0));
}
return (s, a) => {
const n = Nt("a-button");
return wt(), Wt(n, {
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: g.value,
style: Vr(s.style),
onClick: u
}, {
default: Ct(() => [
s.$slots.default ? Tr(s.$slots, "default", { key: 0 }) : Me("", !0)
]),
_: 3
}, 8, ["block", "danger", "disabled", "ghost", "href", "html-type", "icon", "shape", "size", "target", "type", "loading", "style"]);
};
}
}), xc = lr(_c);
function Va(f) {
return vu() ? (wu(f), !0) : !1;
}
function ei(f) {
let k = !1, t;
const g = bu(!0);
return (...b) => (k || (t = g.run(() => f(...b)), k = !0), t);
}
function nr(f) {
return typeof f == "function" ? f() : Se(f);
}
const Wa = typeof window < "u" && typeof document < "u";
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
const Sc = (f) => typeof f < "u", kc = Object.prototype.toString, Cc = (f) => kc.call(f) === "[object Object]", Ec = () => {
};
function Tc(f, k) {
function t(...g) {
return new Promise((b, u) => {
Promise.resolve(f(() => k.apply(this, g), { fn: k, thisArg: this, args: g })).then(b).catch(u);
});
}
return t;
}
const Ka = (f) => f();
function Ac(f = Ka) {
const k = bt(!0);
function t() {
k.value = !1;
}
function g() {
k.value = !0;
}
const b = (...u) => {
k.value && f(...u);
};
return { isActive: _u(k), pause: t, resume: g, eventFilter: b };
}
function Mc(f) {
return f || $r();
}
function Oc(f, k, t = {}) {
const {
eventFilter: g = Ka,
...b
} = t;
return ve(
f,
Tc(
g,
k
),
b
);
}
function Rc(f, k, t = {}) {
const {
eventFilter: g,
...b
} = t, { eventFilter: u, pause: s, resume: a, isActive: n } = Ac(g);
return { stop: Oc(
f,
k,
{
...b,
eventFilter: u
}
), pause: s, resume: a, isActive: n };
}
function Ic(f, k = {}) {
if (!ar(f))
return pr(f);
const t = Array.isArray(f.value) ? Array.from({ length: f.value.length }) : {};
for (const g in f.value)
t[g] = yu(() => ({
get() {
return f.value[g];
},
set(b) {
var u;
if ((u = nr(k.replaceRef)) != null ? u : !0)
if (Array.isArray(f.value)) {
const a = [...f.value];
a[g] = b, f.value = a;
} else {
const a = { ...f.value, [g]: b };
Object.setPrototypeOf(a, Object.getPrototypeOf(f.value)), f.value = a;
}
else
f.value[g] = b;
}
}));
return t;
}
function jc(f, k = !0, t) {
const g = Mc(t);
g ? Or(f, g) : k ? f() : tr(f);
}
function ys(f) {
var k;
const t = nr(f);
return (k = t == null ? void 0 : t.$el) != null ? k : t;
}
const zn = Wa ? window : void 0;
function Nn(...f) {
let k, t, g, b;
if (typeof f[0] == "string" || Array.isArray(f[0]) ? ([t, g, b] = f, k = zn) : [k, t, g, b] = f, !k)
return Ec;
Array.isArray(t) || (t = [t]), Array.isArray(g) || (g = [g]);
const u = [], s = () => {
u.forEach((r) => r()), u.length = 0;
}, a = (r, l, i, o) => (r.addEventListener(l, i, o), () => r.removeEventListener(l, i, o)), n = ve(
() => [ys(k), nr(b)],
([r, l]) => {
if (s(), !r)
return;
const i = Cc(l) ? { ...l } : l;
u.push(
...t.flatMap((o) => g.map((h) => a(r, o, h, i)))
);
},
{ immediate: !0, flush: "post" }
), e = () => {
n(), s();
};
return Va(e), e;
}
function Pc() {
const f = bt(!1);
return $r() && Or(() => {
f.value = !0;
}), f;
}
function Nc(f) {
const k = Pc();
return Yt(() => (k.value, !!f()));
}
function Dc(f) {
return JSON.parse(JSON.stringify(f));
}
const pi = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, mi = "__vueuse_ssr_handlers__", Bc = /* @__PURE__ */ Fc();
function Fc() {
return mi in pi || (pi[mi] = pi[mi] || {}), pi[mi];
}
function Lc(f, k) {
return Bc[f] || k;
}
function $c(f) {
return f == null ? "any" : f instanceof Set ? "set" : f instanceof Map ? "map" : f instanceof Date ? "date" : typeof f == "boolean" ? "boolean" : typeof f == "string" ? "string" : typeof f == "object" ? "object" : Number.isNaN(f) ? "any" : "number";
}
const zc = {
boolean: {
read: (f) => f === "true",
write: (f) => String(f)
},
object: {
read: (f) => JSON.parse(f),
write: (f) => JSON.stringify(f)
},
number: {
read: (f) => Number.parseFloat(f),
write: (f) => String(f)
},
any: {
read: (f) => f,
write: (f) => String(f)
},
string: {
read: (f) => f,
write: (f) => String(f)
},
map: {
read: (f) => new Map(JSON.parse(f)),
write: (f) => JSON.stringify(Array.from(f.entries()))
},
set: {
read: (f) => new Set(JSON.parse(f)),
write: (f) => JSON.stringify(Array.from(f))
},
date: {
read: (f) => new Date(f),
write: (f) => f.toISOString()
}
}, fo = "vueuse-storage";
function Xa(f, k, t, g = {}) {
var b;
const {
flush: u = "pre",
deep: s = !0,
listenToStorageChanges: a = !0,
writeDefaults: n = !0,
mergeDefaults: e = !1,
shallow: r,
window: l = zn,
eventFilter: i,
onError: o = (D) => {
console.error(D);
},
initOnMounted: h
} = g, d = (r ? Pn : bt)(typeof k == "function" ? k() : k);
if (!t)
try {
t = Lc("getDefaultStorage", () => {
var D;
return (D = zn) == null ? void 0 : D.localStorage;
})();
} catch (D) {
o(D);
}
if (!t)
return d;
const c = nr(k), p = $c(c), m = (b = g.serializer) != null ? b : zc[p], { pause: S, resume: C } = Rc(
d,
() => A(d.value),
{ flush: u, deep: s, eventFilter: i }
);
return l && a && jc(() => {
Nn(l, "storage", I), Nn(l, fo, F), h && I();
}), h || I(), d;
function A(D) {
try {
if (D == null)
t.removeItem(f);
else {
const B = m.write(D), z = t.getItem(f);
z !== B && (t.setItem(f, B), l && l.dispatchEvent(new CustomEvent(fo, {
detail: {
key: f,
oldValue: z,
newValue: B,
storageArea: t
}
})));
}
} catch (B) {
o(B);
}
}
function P(D) {
const B = D ? D.newValue : t.getItem(f);
if (B == null)
return n && c != null && t.setItem(f, m.write(c)), c;
if (!D && e) {
const z = m.read(B);
return typeof e == "function" ? e(z, c) : p === "object" && !Array.isArray(z) ? { ...c, ...z } : z;
} else
return typeof B != "string" ? B : m.read(B);
}
function F(D) {
I(D.detail);
}
function I(D) {
if (!(D && D.storageArea !== t)) {
if (D && D.key == null) {
d.value = c;
return;
}
if (!(D && D.key !== f)) {
S();
try {
(D == null ? void 0 : D.newValue) !== m.write(d.value) && (d.value = P(D));
} catch (B) {
o(B);
} finally {
D ? tr(C) : C();
}
}
}
}
}
function Uc(f, k = {}) {
var t, g;
const {
pointerTypes: b,
preventDefault: u,
stopPropagation: s,
exact: a,
onMove: n,
onEnd: e,
onStart: r,
initialValue: l,
axis: i = "both",
draggingElement: o = zn,
containerElement: h,
handle: d = f
} = k, c = bt(
(t = nr(l)) != null ? t : { x: 0, y: 0 }
), p = bt(), m = (F) => b ? b.includes(F.pointerType) : !0, S = (F) => {
nr(u) && F.preventDefault(), nr(s) && F.stopPropagation();
}, C = (F) => {
var I;
if (!m(F) || nr(a) && F.target !== nr(f))
return;
const D = nr(h), B = (I = D == null ? void 0 : D.getBoundingClientRect) == null ? void 0 : I.call(D), z = nr(f).getBoundingClientRect(), $ = {
x: F.clientX - (D ? z.left - B.left : z.left),
y: F.clientY - (D ? z.top - B.top : z.top)
};
(r == null ? void 0 : r($, F)) !== !1 && (p.value = $, S(F));
}, A = (F) => {
var I;
if (!m(F) || !p.value)
return;
const D = nr(h), B = (I = D == null ? void 0 : D.getBoundingClientRect) == null ? void 0 : I.call(D), z = nr(f).getBoundingClientRect();
let { x: $, y: E } = c.value;
(i === "x" || i === "both") && ($ = F.clientX - p.value.x, D && ($ = Math.min(Math.max(0, $), B.width - z.width))), (i === "y" || i === "both") && (E = F.clientY - p.value.y, D && (E = Math.min(Math.max(0, E), B.height - z.height))), c.value = {
x: $,
y: E
}, n == null || n(c.value, F), S(F);
}, P = (F) => {
m(F) && p.value && (p.value = void 0, e == null || e(c.value, F), S(F));
};
if (Wa) {
const F = { capture: (g = k.capture) != null ? g : !0 };
Nn(d, "pointerdown", C, F), Nn(o, "pointermove", A, F), Nn(o, "pointerup", P, F);
}
return {
...Ic(c),
position: c,
isDragging: Yt(() => !!p.value),
style: Yt(
() => `left:${c.value.x}px;top:${c.value.y}px;`
)
};
}
function Hc(f, k, t = {}) {
const { window: g = zn, ...b } = t;
let u;
const s = Nc(() => g && "ResizeObserver" in g), a = () => {
u && (u.disconnect(), u = void 0);
}, n = Yt(() => Array.isArray(f) ? f.map((l) => ys(l)) : [ys(f)]), e = ve(
n,
(l) => {
if (a(), s.value && g) {
u = new ResizeObserver(k);
for (const i of l)
i && u.observe(i, b);
}
},
{ immediate: !0, flush: "post", deep: !0 }
), r = () => {
a(), e();
};
return Va(r), {
isSupported: s,
stop: r
};
}
function Rr(f, k, t, g = {}) {
var b, u, s;
const {
clone: a = !1,
passive: n = !1,
eventName: e,
deep: r = !1,
defaultValue: l,
shouldEmit: i
} = g, o = $r(), h = t || (o == null ? void 0 : o.emit) || ((b = o == null ? void 0 : o.$emit) == null ? void 0 : b.bind(o)) || ((s = (u = o == null ? void 0 : o.proxy) == null ? void 0 : u.$emit) == null ? void 0 : s.bind(o == null ? void 0 : o.proxy));
let d = e;
k || (k = "modelValue"), d = d || `update:${k.toString()}`;
const c = (S) => a ? typeof a == "function" ? a(S) : Dc(S) : S, p = () => Sc(f[k]) ? c(f[k]) : l, m = (S) => {
i ? i(S) && h(d, S) : h(d, S);
};
if (n) {
const S = p(), C = bt(S);
let A = !1;
return ve(
() => f[k],
(P) => {
A || (A = !0, C.value = c(P), tr(() => A = !1));
}
), ve(
C,
(P) => {
!A && (P !== f[k] || r) && m(P);
},
{ deep: r }
), C;
} else
return Yt({
get() {
return p();
},
set(S) {
m(S);
}
});
}
const [qc] = er("drag-drawer"), Vc = ke({
name: qc,
components: { CloseOutlined: zu, ShrinkOutlined: Uu, ArrowsAltOutlined: Hu },
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(f, { emit: k }) {
const t = bt(null), g = Rr(f, "visible", k), b = bt(f.width), u = bt(!1), s = () => g.value = !1, a = () => f.getContainer(), n = a(), e = 500, r = () => {
b.value = u.value ? f.width : "100%", u.value = !u.value;
};
return ve(g, (i) => {
i || (u.value = !1, b.value = f.width);
}), {
show: g,
fullScreen: u,
dragDrawer: t,
actualWidth: b,
getContainerFn: a,
handleClose: s,
toggleFullScreen: r,
handleMouseDown: (i) => {
const o = i.clientX, h = b.value, d = (n == null ? void 0 : n.clientWidth) || document.body.clientWidth;
document.body.classList.add("disable-select-in-dragging"), window.onmousemove = function(c) {
const m = c.clientX - o, S = typeof h == "number" ? h - m : window.innerWidth - c.x;
b.value = Math.min(S < e ? e : S, d);
}, window.onmouseup = () => {
window.onmousemove = null, document.body.classList.remove("disable-select-in-dragging");
};
}
};
}
});
const Wc = {
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 Kc(f, k, t, g, b, u) {
const s = Nt("ArrowsAltOutlined"), a = Nt("ShrinkOutlined"), n = Nt("CloseOutlined"), e = Nt("a-space"), r = Nt("a-button"), l = Nt("a-drawer");
return wt(), Wt(l, {
ref: "dragDrawer",
class: "drag-drawer-warpper",
placement: "right",
mask: f.mask,
width: f.actualWidth,
"get-container": f.getContainerFn,
closable: !1,
"destroy-on-close": !0,
push: !0,
visible: f.show,
"onUpdate:visible": k[1] || (k[1] = (i) => f.show = i)
}, {
title: Ct(() => [
f.title ? (wt(), ie(De, { key: 0 }, [
Re(me(f.title), 1)
], 64)) : Tr(f.$slots, "title", { key: 1 })
]),
extra: Ct(() => [
Ut(e, { style: { transform: "translateY(2px)" } }, {
default: Ct(() => [
f.fullScreen ? (wt(), Wt(a, {
key: 1,
style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" },
onClick: f.toggleFullScreen
}, null, 8, ["onClick"])) : (wt(), Wt(s, {
key: 0,
style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" },
onClick: f.toggleFullScreen
}, null, 8, ["onClick"])),
Ut(n, {
style: { color: "#000", "font-size": "18px", cursor: "pointer", "margin-right": "10px" },
onClick: f.handleClose
}, null, 8, ["onClick"])
]),
_: 1
})
]),
default: Ct(() => [
Tr(f.$slots, "default"),
Ye("div", {
class: "drag-trigger",
onMousedown: k[0] || (k[0] = (i) => f.handleMouseDown(i))
}, null, 32),
f.hideFooter ? Me("", !0) : (wt(), ie("div", Wc, [
Ut(e, { style: { "padding-left": "20px" } }, {
default: Ct(() => [
Ut(r, { onClick: f.handleClose }, {
default: Ct(() => [
Re(me(f.$t("close") || "关闭"), 1)
]),
_: 1
}, 8, ["onClick"]),
Tr(f.$slots, "footBtn")
]),
_: 3
})
]))
]),
_: 3
}, 8, ["mask", "width", "get-container", "visible"]);
}
const Xc = /* @__PURE__ */ ur(Vc, [["render", Kc]]), Yc = lr(Xc), mr = () => {
try {
return qa();
} catch {
return { t: () => {
} };
}
}, [Gc] = er("page-renderer-form-modal"), Zc = ke({
name: Gc,
components: { Modal: $n, Button: Qn, Space: kn },
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(f, { expose: k, emit: t }) {
const { t: g } = mr(), { form: b } = pr(f), u = bt(!1), s = bt(!1), a = bt(null), n = or({
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: c = !0,
needRefresh: p = !0,
successMsg: m = g("operationSuccessful") || "操作成功"
} = b.value;
s.value = !1, d && d.success && (c && Be.success(m), l(), p && t("refresh"));
}).catch((d) => {
var p;
if (s.value = !1, console.log("[PageRendererFormModal handleOk Error]: ", d), typeof d == "string")
return Be.warn(d);
const { errorFields: c } = d;
c && c.length && Be.warn((p = c[0]) == null ? void 0 : p.errors.join("、"));
});
};
ve(u, (i) => {
i && tr(() => {
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 c = d.currentStyle || window.getComputedStyle(d, null);
h.onmousedown = (p) => {
const m = p.clientX - h.offsetLeft, S = p.clientY - h.offsetTop;
let C, A;
c.left.includes("%") ? (C = +document.body.clientWidth * (+c.left.replace(/%/g, "") / 100), A = +document.body.clientHeight * (+c.top.replace(/%/g, "") / 100)) : (C = +c.left.replace(/\px/g, ""), A = +c.top.replace(/\px/g, "")), document.onmousemove = function(P) {
const F = P.clientX - m, I = P.clientY - S;
d.style.left = `${F + C}px`, d.style.top = `${I + A}px`;
}, document.onmouseup = function() {
document.onmousemove = null, document.onmouseup = null;
};
};
});
});
const r = () => u.value = !0, l = () => {
var i, o;
(o = (i = a.value) == null ? void 0 : i.reset) == null || o.call(i), u.value = !1;
};
return k({ openModal: r, closeModal: l }), {
handleOk: e,
closeModal: l,
visible: u,
modalConfig: n,
currentForm: a,
confirmLoading: s
};
}
});
const Jc = { key: 1 };
function Qc(f, k, t, g, b, u) {
const s = Nt("Button"), a = Nt("Space"), n = Nt("Modal");
return wt(), Wt(n, Le({
"wrap-class-name": "drag-modal-wrapper",
visible: f.visible,
"onUpdate:visible": k[1] || (k[1] = (e) => f.visible = e)
}, f.form.modalProps, {
"destroy-on-close": !0,
"get-container": f.getContainer,
onCancel: f.closeModal
}), {
title: Ct(() => [
Ye("span", null, me(f.form.title), 1)
]),
footer: Ct(() => {
var e;
return [
((e = f.form.modalProps) == null ? void 0 : e.hideFooter) !== !0 ? (wt(), Wt(a, { key: 0 }, {
default: Ct(() => {
var r;
return [
Ut(s, { onClick: f.closeModal }, {
default: Ct(() => {
var l;
return [
Re(me(((l = f.form.modalProps) == null ? void 0 : l.cancelText) || f.$t("cancel") || "取消"), 1)
];
}),
_: 1
}, 8, ["onClick"]),
((r = f.form.modalProps) == null ? void 0 : r.hideOkButton) !== !0 && f.modalConfig.showOk ? (wt(), Wt(s, {
key: 0,
type: "primary",
onClick: f.handleOk,
loading: f.confirmLoading
}, {
default: Ct(() => {
var l;
return [
Re(me(((l = f.form.modalProps) == null ? void 0 : l.okText) || f.$t("ok") || "确定"), 1)
];
}),
_: 1
}, 8, ["onClick", "loading"])) : Me("", !0)
];
}),
_: 1
})) : Me("", !0)
];
}),
default: Ct(() => [
f.form.component ? (wt(), Wt(bn(f.form.component), Le({
key: 0,
rows: f.rows,
"extra-data": f.extraData
}, f.form.props, {
modalConfig: f.modalConfig,
"onUpdate:modalConfig": k[0] || (k[0] = (e) => f.modalConfig = e),
ref: "currentForm"
}), null, 16, ["rows", "extra-data", "modalConfig"])) : (wt(), ie("span", Jc, "form配置中没有为【" + me(f.form.title) + "】事件提供组件", 1))
]),
_: 1
}, 16, ["visible", "get-container", "onCancel"]);
}
const Ya = /* @__PURE__ */ ur(Zc, [["render", Qc]]), tf = lr(Ya), [ef] = er("drag-modal-plus"), rf = ke({
name: ef,
components: { Modal: $n, Button: Qn, Space: kn },
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(f, { expose: k, emit: t }) {
const g = bt(null), b = Rr(f, "visible", t);
function u() {
if (!b.value)
return;
const n = document.querySelector(".ant-modal-root"), e = n == null ? void 0 : n.querySelector(".ant-modal-header"), r = n == null ? void 0 : n.querySelector(".ant-modal");
e.style.cursor = "move";
const l = r.currentStyle || window.getComputedStyle(r, null);
e.onmousedown = (i) => {
const o = i.clientX - e.offsetLeft, h = i.clientY - e.offsetTop;
let d, c;
l.left.includes("%") ? (d = +document.body.clientWidth * (+l.left.replace(/%/g, "") / 100), c = +document.body.clientHeight * (+l.top.replace(/%/g, "") / 100)) : (d = +l.left.replace(/\px/g, ""), c = +l.top.replace(/\px/g, "")), document.onmousemove = function(p) {
const m = p.clientX - o, S = p.clientY - h;
r.style.left = `${m + d}px`, r.style.top = `${S + c}px`;
}, document.onmouseup = function() {
document.onmousemove = null, document.onmouseup = null;
};
};
}
ve(b, (n) => {
tr(() => {
setTimeout(u, 500);
});
}, {
immediate: !0,
flush: "post"
});
const s = () => b.value = !1;
return k({ openModal: () => b.value = !0, closeModal: s }), { show: b, closeModal: s, dragModalPlusRef: g };
}
});
function nf(f, k, t, g, b, u) {
const s = Nt("Button"), a = Nt("Space"), n = Nt("Modal");
return wt(), Wt(n, Le({
ref: "dragModalPlusRef",
"wrap-class-name": "drag-modal-wrapper"
}, f.modalProps, {
visible: f.show,
"onUpdate:visible": k[0] || (k[0] = (e) => f.show = e),
width: f.width,
"destroy-on-close": !0,
"get-container": f.getContainer,
onCancel: f.closeModal
}), {
title: Ct(() => [
Ye("span", null, me(f.title), 1)
]),
footer: Ct(() => [
f.hideFooter ? Me("", !0) : (wt(), Wt(a, { key: 0 }, {
default: Ct(() => [
Ut(s, { onClick: f.closeModal }, {
default: Ct(() => [
Re(me(f.cancelText || f.$t("cancel") || "取消"), 1)
]),
_: 1
}, 8, ["onClick"]),
Tr(f.$slots, "footBtn")
]),
_: 3
}))
]),
default: Ct(() => [
Tr(f.$slots, "default")
]),
_: 3
}, 16, ["visible", "width", "get-container", "onCancel"]);
}
const sf = /* @__PURE__ */ ur(rf, [["render", nf]]), of = lr(sf), $i = ei(() => {
const f = ti(), k = bt({}), t = bt({}), g = async (s, a) => {
const n = `${s}-${a}`;
if (k.value[n])
return k.value[n];
const e = await f({
url: `${hr}/base-biz-data-server/query/data/apiDataSource/${s}/${a}`,
method: "get"
});
return k.value[n] = e.data, k.value[n];
};
return { getApiDataSource: g, getEnumData: async (s, a, n) => {
const e = `${s}-${a}`;
if (t.value[e])
return t.value[e];
const r = await g(s, a);
r.async && !location.href.includes("carrierglobe") && (Be.warn(`当前词条 ${a} 是懒加载数据源,请使用 YzsEnumFuzzySelect 组件!`), console.error(`当前词条 ${a} 是懒加载数据源,请使用 YzsEnumFuzzySelect 组件!`));
let l = {};
try {
l = JSON.parse(r.apiParam);
} catch {
l = {};
}
const i = await f({
url: `${hr}${r.apiUrl}`,
method: r.apiPost ? "post" : "get",
[r.apiPost ? "data" : "params"]: { ...l, ...n }
});
return t.value[e] = i, t.value[e];
}, getI18nBizCodeList: async (s, a, n) => (await f({
url: `${hr}/base-biz-data-server/query/i18n/biz/code/list`,
method: "post",
data: {
codeType: s,
attributeName: a,
dataCodes: n
}
})).data };
}), [af] = er("enum-select"), lf = { name: af }, uf = /* @__PURE__ */ ke({
...lf,
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(f, { emit: k }) {
const t = f, { t: g } = mr(), b = Rr(t, "value", k), u = bt([]), { getEnumData: s } = $i(), a = Yt(() => ({
required: t.required,
...t.formItemProps
})), n = Yt(() => ({
allowClear: !0,
showSearch: !0,
optionFilterProp: "label",
...t.selectProps,
disabled: t.disabled,
placeholder: t.disabled ? "" : e()
}));
function e() {
return t.placeholder ? t.placeholder : g("pleaseSelect") ? `${g("pleaseSelect")}${t.label || g(t.code)}` : "";
}
r();
async function r() {
const o = await s(t.codeType, t.code, t.params);
u.value = await (t.transform ? Promise.resolve(t.transform(o)) : Promise.resolve(o.data));
}
function l(o) {
(o.keyCode === 13 || o.key === "Enter") && setTimeout(() => k("pressEnter"));
}
function i(o) {
k("change", o);
}
return (o, h) => {
const d = Nt("a-select"), c = Nt("a-form-item");
return o.showLabel !== !1 ? (wt(), Wt(c, Le({
key: 0,
name: o.name,
label: o.label || Se(g)(o.code) || o.code
}, a.value), {
default: Ct(() => [
Ut(d, Le({
value: Se(b),
"onUpdate:value": h[0] || (h[0] = (p) => ar(b) ? b.value = p : null),
options: u.value
}, n.value, {
class: [{ "enum-select-selector-active": Se(b) }, "enum-select-selector"],
onChange: i,
onKeydown: l
}), null, 16, ["value", "options", "class"])
]),
_: 1
}, 16, ["name", "label"])) : (wt(), Wt(d, Le({
key: 1,
value: Se(b),
"onUpdate:value": h[1] || (h[1] = (p) => ar(b) ? b.value = p : null),
options: u.value
}, n.value, {
class: [{ "enum-select-selector-active": Se(b) }, "enum-select-selector"],
onChange: i,
onKeydown: l
}), null, 16, ["value", "options", "class"]));
};
}
});
const Ga = lr(uf);
var cf = typeof global == "object" && global && global.Object === Object && global;
const Za = cf;
var ff = typeof self == "object" && self && self.Object === Object && self, hf = Za || ff || Function("return this")();
const vr = hf;
var df = vr.Symbol;
const Sr = df;
var Ja = Object.prototype, pf = Ja.hasOwnProperty, mf = Ja.toString, Rn = Sr ? Sr.toStringTag : void 0;
function gf(f) {
var k = pf.call(f, Rn), t = f[Rn];
try {
f[Rn] = void 0;
var g = !0;
} catch {
}
var b = mf.call(f);
return g && (k ? f[Rn] = t : delete f[Rn]), b;
}
var bf = Object.prototype, yf = bf.toString;
function vf(f) {
return yf.call(f);
}
var wf = "[object Null]", _f = "[object Undefined]", ho = Sr ? Sr.toStringTag : void 0;
function Zr(f) {
return f == null ? f === void 0 ? _f : wf : ho && ho in Object(f) ? gf(f) : vf(f);
}
function Ar(f) {
return f != null && typeof f == "object";
}
var xf = "[object Symbol]";
function yn(f) {
return typeof f == "symbol" || Ar(f) && Zr(f) == xf;
}
function Wr(f, k) {
for (var t = -1, g = f == null ? 0 : f.length, b = Array(g); ++t < g; )
b[t] = k(f[t], t, f);
return b;
}
var Sf = Array.isArray;
const Ge = Sf;
var kf = 1 / 0, po = Sr ? Sr.prototype : void 0, mo = po ? po.toString : void 0;
function Qa(f) {
if (typeof f == "string")
return f;
if (Ge(f))
return Wr(f, Qa) + "";
if (yn(f))
return mo ? mo.call(f) : "";
var k = f + "";
return k == "0" && 1 / f == -kf ? "-0" : k;
}
var Cf = /\s/;
function Ef(f) {
for (var k = f.length; k-- && Cf.test(f.charAt(k)); )
;
return k;
}
var Tf = /^\s+/;
function Af(f) {
return f && f.slice(0, Ef(f) + 1).replace(Tf, "");
}
function dr(f) {
var k = typeof f;
return f != null && (k == "object" || k == "function");
}
var go = 0 / 0, Mf = /^[-+]0x[0-9a-f]+$/i, Of = /^0b[01]+$/i, Rf = /^0o[0-7]+$/i, If = parseInt;
function vs(f) {
if (typeof f == "number")
return f;
if (yn(f))
return go;
if (dr(f)) {
var k = typeof f.valueOf == "function" ? f.valueOf() : f;
f = dr(k) ? k + "" : k;
}
if (typeof f != "string")
return f === 0 ? f : +f;
f = Af(f);
var t = Of.test(f);
return t || Rf.test(f) ? If(f.slice(2), t ? 2 : 8) : Mf.test(f) ? go : +f;
}
var bo = 1 / 0, jf = 17976931348623157e292;
function Pf(f) {
if (!f)
return f === 0 ? f : 0;
if (f = vs(f), f === bo || f === -bo) {
var k = f < 0 ? -1 : 1;
return k * jf;
}
return f === f ? f : 0;
}
function Nf(f) {
var k = Pf(f), t = k % 1;
return k === k ? t ? k - t : k : 0;
}
function tl(f) {
return f;
}
var Df = "[object AsyncFunction]", Bf = "[object Function]", Ff = "[object GeneratorFunction]", Lf = "[object Proxy]";
function el(f) {
if (!dr(f))
return !1;
var k = Zr(f);
return k == Bf || k == Ff || k == Df || k == Lf;
}
var $f = vr["__core-js_shared__"];
const os = $f;
var yo = function() {
var f = /[^.]+$/.exec(os && os.keys && os.keys.IE_PROTO || "");
return f ? "Symbol(src)_1." + f : "";
}();
function zf(f) {
return !!yo && yo in f;
}
var Uf = Function.prototype, Hf = Uf.toString;
function Jr(f) {
if (f != null) {
try {
return Hf.call(f);
} catch {
}
try {
return f + "";
} catch {
}
}
return "";
}
var qf = /[\\^$.*+?()[\]{}|]/g, Vf = /^\[object .+?Constructor\]$/, Wf = Function.prototype, Kf = Object.prototype, Xf = Wf.toString, Yf = Kf.hasOwnProperty, Gf = RegExp(
"^" + Xf.call(Yf).replace(qf, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
);
function Zf(f) {
if (!dr(f) || zf(f))
return !1;
var k = el(f) ? Gf : Vf;
return k.test(Jr(f));
}
function Jf(f, k) {
return f == null ? void 0 : f[k];
}
function Qr(f, k) {
var t = Jf(f, k);
return Zf(t) ? t : void 0;
}
var Qf = Qr(vr, "WeakMap");
const ws = Qf;
var vo = Object.create, th = function() {
function f() {
}
return function(k) {
if (!dr(k))
return {};
if (vo)
return vo(k);
f.prototype = k;
var t = new f();
return f.prototype = void 0, t;
};
}();
const eh = th;
function rh() {
}
function nh(f, k) {
var t = -1, g = f.length;
for (k || (k = Array(g)); ++t < g; )
k[t] = f[t];
return k;
}
var ih = function() {
try {
var f = Qr(Object, "defineProperty");
return f({}, "", {}), f;
} catch {
}
}();
const wo = ih;
function sh(f, k) {
for (var t = -1, g = f == null ? 0 : f.length; ++t < g && k(f[t], t, f) !== !1; )
;
return f;
}
function oh(f, k, t, g) {
for (var b = f.length, u = t + (g ? 1 : -1); g ? u-- : ++u < b; )
if (k(f[u], u, f))
return u;
return -1;
}
function ah(f) {
return f !== f;
}
function lh(f, k, t) {
for (var g = t - 1, b = f.length; ++g < b; )
if (f[g] === k)
return g;
return -1;
}
function rl(f, k, t) {
return k === k ? lh(f, k, t) : oh(f, ah, t);
}
function uh(f, k) {
var t = f == null ? 0 : f.length;
return !!t && rl(f, k, 0) > -1;
}
var ch = 9007199254740991, fh = /^(?:0|[1-9]\d*)$/;
function zi(f, k) {
var t = typeof f;
return k = k ?? ch, !!k && (t == "number" || t != "symbol" && fh.test(f)) && f > -1 && f % 1 == 0 && f < k;
}
function Ds(f, k, t) {
k == "__proto__" && wo ? wo(f, k, {
configurable: !0,
enumerable: !0,
value: t,
writable: !0
}) : f[k] = t;
}
function Ui(f, k) {
return f === k || f !== f && k !== k;
}
var hh = Object.prototype, dh = hh.hasOwnProperty;
function Bs(f, k, t) {
var g = f[k];
(!(dh.call(f, k) && Ui(g, t)) || t === void 0 && !(k in f)) && Ds(f, k, t);
}
function Hi(f, k, t, g) {
var b = !t;
t || (t = {});
for (var u = -1, s = k.length; ++u < s; ) {
var a = k[u], n = g ? g(t[a], f[a], a, t, f) : void 0;
n === void 0 && (n = f[a]), b ? Ds(t, a, n) : Bs(t, a, n);
}
return t;
}
var ph = 9007199254740991;
function Fs(f) {
return typeof f == "number" && f > -1 && f % 1 == 0 && f <= ph;
}
function Cn(f) {
return f != null && Fs(f.length) && !el(f);
}
function mh(f, k, t) {
if (!dr(t))
return !1;
var g = typeof k;
return (g == "number" ? Cn(t) && zi(k, t.length) : g == "string" && k in t) ? Ui(t[k], f) : !1;
}
var gh = Object.prototype;
function Ls(f) {
var k = f && f.constructor, t = typeof k == "function" && k.prototype || gh;
return f === t;
}
function bh(f, k) {
for (var t = -1, g = Array(f); ++t < f; )
g[t] = k(t);
return g;
}
var yh = "[object Arguments]";
function _o(f) {
return Ar(f) && Zr(f) == yh;
}
var nl = Object.prototype, vh = nl.hasOwnProperty, wh = nl.propertyIsEnumerable, _h = _o(function() {
return arguments;
}()) ? _o : function(f) {
return Ar(f) && vh.call(f, "callee") && !wh.call(f, "callee");
};
const il = _h;
function xh() {
return !1;
}
var sl = typeof exports == "object" && exports && !exports.nodeType && exports, xo = sl && typeof module == "object" && module && !module.nodeType && module, Sh = xo && xo.exports === sl, So = Sh ? vr.Buffer : void 0, kh = So ? So.isBuffer : void 0, Ch = kh || xh;
const Ii = Ch;
var Eh = "[object Arguments]", Th = "[object Array]", Ah = "[object Boolean]", Mh = "[object Date]", Oh = "[object Error]", Rh = "[object Function]", Ih = "[object Map]", jh = "[object Number]", Ph = "[object Object]", Nh = "[object RegExp]", Dh = "[object Set]", Bh = "[object String]", Fh = "[object WeakMap]", Lh = "[object ArrayBuffer]", $h = "[object DataView]", zh = "[object Float32Array]", Uh = "[object Float64Array]", Hh = "[object Int8Array]", qh = "[object Int16Array]", Vh = "[object Int32Array]", Wh = "[object Uint8Array]", Kh = "[object Uint8ClampedArray]", Xh = "[object Uint16Array]", Yh = "[object Uint32Array]", Pe = {};
Pe[zh] = Pe[Uh] = Pe[Hh] = Pe[qh] = Pe[Vh] = Pe[Wh] = Pe[Kh] = Pe[Xh] = Pe[Yh] = !0;
Pe[Eh] = Pe[Th] = Pe[Lh] = Pe[Ah] = Pe[$h] = Pe[Mh] = Pe[Oh] = Pe[Rh] = Pe[Ih] = Pe[jh] = Pe[Ph] = Pe[Nh] = Pe[Dh] = Pe[Bh] = Pe[Fh] = !1;
function Gh(f) {
return Ar(f) && Fs(f.length) && !!Pe[Zr(f)];
}
function qi(f) {
return function(k) {
return f(k);
};
}
var ol = typeof exports == "object" && exports && !exports.nodeType && exports, Dn = ol && typeof module == "object" && module && !module.nodeType && module, Zh = Dn && Dn.exports === ol, as = Zh && Za.process, Jh = function() {
try {
var f = Dn && Dn.require && Dn.require("util").types;
return f || as && as.binding && as.binding("util");
} catch {
}
}();
const vn = Jh;
var ko = vn && vn.isTypedArray, Qh = ko ? qi(ko) : Gh;
const al = Qh;
var td = Object.prototype, ed = td.hasOwnProperty;
function ll(f, k) {
var t = Ge(f), g = !t && il(f), b = !t && !g && Ii(f), u = !t && !g && !b && al(f), s = t || g || b || u, a = s ? bh(f.length, String) : [], n = a.length;
for (var e in f)
(k || ed.call(f, e)) && !(s && // Safari 9 has enumerable `arguments.length` in strict mode.
(e == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
b && (e == "offset" || e == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
u && (e == "buffer" || e == "byteLength" || e == "byteOffset") || // Skip index properties.
zi(e, n))) && a.push(e);
return a;
}
function ul(f, k) {
return function(t) {
return f(k(t));
};
}
var rd = ul(Object.keys, Object);
const nd = rd;
var id = Object.prototype, sd = id.hasOwnProperty;
function od(f) {
if (!Ls(f))
return nd(f);
var k = [];
for (var t in Object(f))
sd.call(f, t) && t != "constructor" && k.push(t);
return k;
}
function En(f) {
return Cn(f) ? ll(f) : od(f);
}
function ad(f) {
var k = [];
if (f != null)
for (var t in Object(f))
k.push(t);
return k;
}
var ld = Object.prototype, ud = ld.hasOwnProperty;
function cd(f) {
if (!dr(f))
return ad(f);
var k = Ls(f), t = [];
for (var g in f)
g == "constructor" && (k || !ud.call(f, g)) || t.push(g);
return t;
}
function $s(f) {
return Cn(f) ? ll(f, !0) : cd(f);
}
var fd = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, hd = /^\w*$/;
function zs(f, k) {
if (Ge(f))
return !1;
var t = typeof f;
return t == "number" || t == "symbol" || t == "boolean" || f == null || yn(f) ? !0 : hd.test(f) || !fd.test(f) || k != null && f in Object(k);
}
var dd = Qr(Object, "create");
const Un = dd;
function pd() {
this.__data__ = Un ? Un(null) : {}, this.size = 0;
}
function md(f) {
var k = this.has(f) && delete this.__data__[f];
return this.size -= k ? 1 : 0, k;
}
var gd = "__lodash_hash_undefined__", bd = Object.prototype, yd = bd.hasOwnProperty;
function vd(f) {
var k = this.__data__;
if (Un) {
var t = k[f];
return t === gd ? void 0 : t;
}
return yd.call(k, f) ? k[f] : void 0;
}
var wd = Object.prototype, _d = wd.hasOwnProperty;
function xd(f) {
var k = this.__data__;
return Un ? k[f] !== void 0 : _d.call(k, f);
}
var Sd = "__lodash_hash_undefined__";
function kd(f, k) {
var t = this.__data__;
return this.size += this.has(f) ? 0 : 1, t[f] = Un && k === void 0 ? Sd : k, this;
}
function Yr(f) {
var k = -1, t = f == null ? 0 : f.length;
for (this.clear(); ++k < t; ) {
var g = f[k];
this.set(g[0], g[1]);
}
}
Yr.prototype.clear = pd;
Yr.prototype.delete = md;
Yr.prototype.get = vd;
Yr.prototype.has = xd;
Yr.prototype.set = kd;
function Cd() {
this.__data__ = [], this.size = 0;
}
function Vi(f, k) {
for (var t = f.length; t--; )
if (Ui(f[t][0], k))
return t;
return -1;
}
var Ed = Array.prototype, Td = Ed.splice;
function Ad(f) {
var k = this.__data__, t = Vi(k, f);
if (t < 0)
return !1;
var g = k.length - 1;
return t == g ? k.pop() : Td.call(k, t, 1), --this.size, !0;
}
function Md(f) {
var k = this.__data__, t = Vi(k, f);
return t < 0 ? void 0 : k[t][1];
}
function Od(f) {
return Vi(this.__data__, f) > -1;
}
function Rd(f, k) {
var t = this.__data__, g = Vi(t, f);
return g < 0 ? (++this.size, t.push([f, k])) : t[g][1] = k, this;
}
function Ir(f) {
var k = -1, t = f == null ? 0 : f.length;
for (this.clear(); ++k < t; ) {
var g = f[k];
this.set(g[0], g[1]);
}
}
Ir.prototype.clear = Cd;
Ir.prototype.delete = Ad;
Ir.prototype.get = Md;
Ir.prototype.has = Od;
Ir.prototype.set = Rd;
var Id = Qr(vr, "Map");
const Hn = Id;
function jd() {
this.size = 0, this.__data__ = {
hash: new Yr(),
map: new (Hn || Ir)(),
string: new Yr()
};
}
function Pd(f) {
var k = typeof f;
return k == "string" || k == "number" || k == "symbol" || k == "boolean" ? f !== "__proto__" : f === null;
}
function Wi(f, k) {
var t = f.__data__;
return Pd(k) ? t[typeof k == "string" ? "string" : "hash"] : t.map;
}
function Nd(f) {
var k = Wi(this, f).delete(f);
return this.size -= k ? 1 : 0, k;
}
function Dd(f) {
return Wi(this, f).get(f);
}
function Bd(f) {
return Wi(this, f).has(f);
}
function Fd(f, k) {
var t = Wi(this, f), g = t.size;
return t.set(f, k), this.size += t.size == g ? 0 : 1, this;
}
function jr(f) {
var k = -1, t = f == null ? 0 : f.length;
for (this.clear(); ++k < t; ) {
var g = f[k];
this.set(g[0], g[1]);
}
}
jr.prototype.clear = jd;
jr.prototype.delete = Nd;
jr.prototype.get = Dd;
jr.prototype.has = Bd;
jr.prototype.set = Fd;
var Ld = "Expected a function";
function Us(f, k) {
if (typeof f != "function" || k != null && typeof k != "function")
throw new TypeError(Ld);
var t = function() {
var g = arguments, b = k ? k.apply(this, g) : g[0], u = t.cache;
if (u.has(b))
return u.get(b);
var s = f.apply(this, g);
return t.cache = u.set(b, s) || u, s;
};
return t.cache = new (Us.Cache || jr)(), t;
}
Us.Cache = jr;
var $d = 500;
function zd(f) {
var k = Us(f, function(g) {
return t.size === $d && t.clear(), g;
}), t = k.cache;
return k;
}
var Ud = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, Hd = /\\(\\)?/g, qd = zd(function(f) {
var k = [];
return f.charCodeAt(0) === 46 && k.push(""), f.replace(Ud, function(t, g, b, u) {
k.push(b ? u.replace(Hd, "$1") : g || t);
}), k;
});
const Vd = qd;
function Wd(f) {
return f == null ? "" : Qa(f);
}
function Ki(f, k) {
return Ge(f) ? f : zs(f, k) ? [f] : Vd(Wd(f));
}
var Kd = 1 / 0;
function ri(f) {
if (typeof f == "string" || yn(f))
return f;
var k = f + "";
return k == "0" && 1 / f == -Kd ? "-0" : k;
}
function Xi(f, k) {
k = Ki(k, f);
for (var t = 0, g = k.length; f != null && t < g; )
f = f[ri(k[t++])];
return t && t == g ? f : void 0;
}
function Tn(f, k, t) {
var g = f == null ? void 0 : Xi(f, k);
return g === void 0 ? t : g;
}
function cl(f, k) {
for (var t = -1, g = k.length, b = f.length; ++t < g; )
f[b + t] = k[t];
return f;
}
var Xd = ul(Object.getPrototypeOf, Object);
const fl = Xd;
function Yd() {
this.__data__ = new Ir(), this.size = 0;
}
function Gd(f) {
var k = this.__data__, t = k.delete(f);
return this.size = k.size, t;
}
function Zd(f) {
return this.__data__.get(f);
}
function Jd(f) {
return this.__data__.has(f);
}
var Qd = 200;
function tp(f, k) {
var t = this.__data__;
if (t instanceof Ir) {
var g = t.__data__;
if (!Hn || g.length < Qd - 1)
return g.push([f, k]), this.size = ++t.size, this;
t = this.__data__ = new jr(g);
}
return t.set(f, k), this.size = t.size, this;
}
function _r(f) {
var k = this.__data__ = new Ir(f);
this.size = k.size;
}
_r.prototype.clear = Yd;
_r.prototype.delete = Gd;
_r.prototype.get = Zd;
_r.prototype.has = Jd;
_r.prototype.set = tp;
function ep(f, k) {
return f && H