From 93a9c9a4b499400aa5bd1e7af16cf216ef40982b Mon Sep 17 00:00:00 2001 From: what Date: Thu, 23 Apr 2026 14:07:36 +0800 Subject: [PATCH] v0.6.27 --- dist/button.js | 2 +- .../{main-Dtr3vSp2.js => main-BNMEkn4Y.js} | 1098 ++++++++--------- dist/components.js | 2 +- dist/container.js | 2 +- dist/data-converter.js | 2 +- dist/data-list.js | 2 +- dist/data-list/utils.js | 2 +- dist/grid-layout-form.js | 2 +- dist/grid-layout-form/utils.js | 2 +- dist/grid-layout.js | 2 +- dist/grid-layout/utils.js | 2 +- dist/hooks.js | 2 +- dist/iconfont.js | 2 +- dist/index.js | 2 +- dist/pages.js | 2 +- dist/res-ws.js | 2 +- dist/style.css | 2 +- dist/utils.js | 2 +- dist/virtual-fs.js | 2 +- package.json | 2 +- 20 files changed, 568 insertions(+), 568 deletions(-) rename dist/common/{main-Dtr3vSp2.js => main-BNMEkn4Y.js} (67%) diff --git a/dist/button.js b/dist/button.js index 952ba6b..386b3ec 100644 --- a/dist/button.js +++ b/dist/button.js @@ -1,4 +1,4 @@ -import { aj as s, ai as u, ak as e } from "./common/main-Dtr3vSp2.js"; +import { aj as s, ai as u, ak as e } from "./common/main-BNMEkn4Y.js"; export { s as auth, u as default, diff --git a/dist/common/main-Dtr3vSp2.js b/dist/common/main-BNMEkn4Y.js similarity index 67% rename from dist/common/main-Dtr3vSp2.js rename to dist/common/main-BNMEkn4Y.js index 9f74cb9..79f0487 100644 --- a/dist/common/main-Dtr3vSp2.js +++ b/dist/common/main-BNMEkn4Y.js @@ -1,94 +1,94 @@ -var tn = Object.defineProperty; -var ni = (t) => { +var nn = Object.defineProperty; +var ri = (t) => { throw TypeError(t); }; -var nn = (t, e, i) => e in t ? tn(t, e, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[e] = i; -var N = (t, e, i) => nn(t, typeof e != "symbol" ? e + "" : e, i), ri = (t, e, i) => e.has(t) || ni("Cannot " + i); -var c = (t, e, i) => (ri(t, e, "read from private field"), i ? i.call(t) : e.get(t)), S = (t, e, i) => e.has(t) ? ni("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, i), W = (t, e, i, n) => (ri(t, e, "write to private field"), n ? n.call(t, i) : e.set(t, i), i); -var ai = (t, e, i, n) => ({ +var rn = (t, e, i) => e in t ? nn(t, e, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[e] = i; +var x = (t, e, i) => rn(t, typeof e != "symbol" ? e + "" : e, i), ai = (t, e, i) => e.has(t) || ri("Cannot " + i); +var c = (t, e, i) => (ai(t, e, "read from private field"), i ? i.call(t) : e.get(t)), v = (t, e, i) => e.has(t) ? ri("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, i), B = (t, e, i, n) => (ai(t, e, "write to private field"), n ? n.call(t, i) : e.set(t, i), i); +var oi = (t, e, i, n) => ({ set _(r) { - W(t, e, r, i); + B(t, e, r, i); }, get _() { return c(t, e, n); } }); import { jsx as h, jsxs as A } from "react/jsx-runtime"; -import E, { useEffect as V, useState as j, useCallback as X, useRef as _, useContext as le, useMemo as K, useId as jt, isValidElement as rn, useLayoutEffect as an } from "react"; +import E, { useEffect as M, useState as I, useCallback as X, useRef as H, useContext as le, useMemo as K, useId as It, isValidElement as an, useLayoutEffect as on } from "react"; import ce from "pathe"; import b from "prop-types"; import O from "classnames"; -import * as oi from "react-is"; -import { useNotification as on } from "rc-notification"; +import * as si from "react-is"; +import { useNotification as sn } from "rc-notification"; import m from "lodash"; -import ie, { Field as Ht, FieldContext as bi } from "rc-field-form"; -import { M as Rt, N as Je, a as Ae, s as It, b as sn, S as ln } from "./vender-BkiRbACr.js"; -import Ci from "immutability-helper"; -import { Space as cn, Form as ft, Input as dn, Button as wt, Pagination as un, Tree as pn, Breadcrumb as gn, Table as hn, Empty as mn, Popover as fn, Popconfirm as yn, Tooltip as wn } from "antd"; +import ie, { Field as Jt, FieldContext as Ci } from "rc-field-form"; +import { M as Rt, N as Je, a as Ae, s as jt, b as ln, S as cn } from "./vender-BkiRbACr.js"; +import ki from "immutability-helper"; +import { Space as dn, Form as ft, Input as un, Button as wt, Pagination as pn, Tree as gn, Breadcrumb as hn, Empty as Mt, Table as mn, Popover as fn, Popconfirm as yn, Tooltip as wn } from "antd"; import { useMergedState as bn } from "rc-util"; -import { generatePath as Cn, useInRouterContext as ki, useParams as kn, useLocation as En, createBrowserRouter as $n, Navigate as xn } from "react-router-dom"; +import { generatePath as Cn, useInRouterContext as $i, useParams as kn, useLocation as $n, createBrowserRouter as En, Navigate as Sn } from "react-router-dom"; import "rc-util/lib/hooks/useMergedState"; -import Sn from "rc-drawer"; -import vn from "rc-dialog"; -var ze, Ge, We, we, Le, je; +import vn from "rc-drawer"; +import Nn from "rc-dialog"; +var ze, Ye, Be, we, Le, Ie; class Ei { constructor(e, i) { - S(this, ze, /* @__PURE__ */ new Map()); - S(this, Ge, !0); - S(this, We, []); - S(this, we); - S(this, Le, () => c(this, we)); - S(this, je, () => Promise.resolve()); - N(this, "get", (...e) => new Promise((i, n) => { + v(this, ze, /* @__PURE__ */ new Map()); + v(this, Ye, !0); + v(this, Be, []); + v(this, we); + v(this, Le, () => c(this, we)); + v(this, Ie, () => Promise.resolve()); + x(this, "get", (...e) => new Promise((i, n) => { const r = JSON.stringify(e); - if (c(this, ze).has(r)) return i(c(this, je).call(this, c(this, we), ...e)); - if (c(this, we) === void 0) c(this, We).push([e, i, n]), c(this, Ge) && (W(this, Ge, !1), Promise.resolve(typeof c(this, Le) == "function" ? c(this, Le).call(this) : c(this, Le)).then((a) => W(this, we, a || null)).finally(() => { - c(this, We).forEach(([a, o, s]) => { + if (c(this, ze).has(r)) return i(c(this, Ie).call(this, c(this, we), ...e)); + if (c(this, we) === void 0) c(this, Be).push([e, i, n]), c(this, Ye) && (B(this, Ye, !1), Promise.resolve(typeof c(this, Le) == "function" ? c(this, Le).call(this) : c(this, Le)).then((a) => B(this, we, a || null)).finally(() => { + c(this, Be).forEach(([a, o, s]) => { try { - const l = c(this, je).call(this, c(this, we), ...a); + const l = c(this, Ie).call(this, c(this, we), ...a); c(this, ze).set(JSON.stringify(a), l), o(l); } catch (l) { s(l); } - }), c(this, We).length = 0; + }), c(this, Be).length = 0; })); else { - const a = c(this, je).call(this, c(this, we), ...e); + const a = c(this, Ie).call(this, c(this, we), ...e); c(this, ze).set(r, a), i(a); } })); - W(this, je, i), W(this, Le, e); + B(this, Ie, i), B(this, Le, e); } } -ze = new WeakMap(), Ge = new WeakMap(), We = new WeakMap(), we = new WeakMap(), Le = new WeakMap(), je = new WeakMap(); -const Hr = () => h("div", { children: "Empty" }), st = E.createContext({ ele: {}, mount: () => { +ze = new WeakMap(), Ye = new WeakMap(), Be = new WeakMap(), we = new WeakMap(), Le = new WeakMap(), Ie = new WeakMap(); +const Jr = () => h("div", { children: "Empty" }), st = E.createContext({ ele: {}, mount: () => { }, unmount: () => { -} }), G = ({ rootClassName: t, className: e, children: i, actions: n, title: r, subTitle: a, extras: o, style: s = {} }) => { +} }), Y = ({ rootClassName: t, className: e, children: i, actions: n, title: r, subTitle: a, extras: o, style: s = {} }) => { const { mount: l, unmount: u } = E.useContext(st); - return G.Action({ children: n }), G.Title({ children: r }), G.SubTitle({ children: a }), G.Extra({ children: o }), V(() => (l("rootClassName", t), () => u(t)), [t]), h("div", { className: O("ff-container", e), style: s, children: i }); + return Y.Action({ children: n }), Y.Title({ children: r }), Y.SubTitle({ children: a }), Y.Extra({ children: o }), M(() => (l("rootClassName", t), () => u(t)), [t]), h("div", { className: O("ff-container", e), style: s, children: i }); }, mt = (t) => ({ children: e, className: i }) => { const { mount: n, unmount: r } = E.useContext(st); - return V(() => (e && n(t, E.createElement("div", { key: `ff-${t}`, className: O(`ff-popup-${t}`, i) }, e)), () => r(t)), [i, e]), null; + return M(() => (e && n(t, E.createElement("div", { key: `ff-${t}`, className: O(`ff-popup-${t}`, i) }, e)), () => r(t)), [i, e]), null; }; -G.Action = mt("actions"), G.Title = mt("title"), G.SubTitle = mt("sub-title"), G.Extra = mt("extras"), G.propTypes = { className: b.string, style: b.object, title: b.any, subTitle: b.any, actions: b.any, extras: b.any }; -const Jr = () => h(G, { className: "ff-loading", children: A("div", { className: "loader", children: [A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] })] }) }), Yr = () => h("div", { children: "NotFound" }), $i = ({ children: t }) => { - const [e, i] = j({}), n = X((a, o) => i((s) => ({ ...s, [a]: o })), []), r = X((a) => i((o) => ({ ...o, [a]: void 0 })), []); +Y.Action = mt("actions"), Y.Title = mt("title"), Y.SubTitle = mt("sub-title"), Y.Extra = mt("extras"), Y.propTypes = { className: b.string, style: b.object, title: b.any, subTitle: b.any, actions: b.any, extras: b.any }; +const Gr = () => h(Y, { className: "ff-loading", children: A("div", { className: "loader", children: [A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] }), A("div", { className: "square", children: [h("span", {}), h("span", {}), h("span", {})] })] }) }), Yr = () => h("div", { children: "NotFound" }), Si = ({ children: t }) => { + const [e, i] = I({}), n = X((a, o) => i((s) => ({ ...s, [a]: o })), []), r = X((a) => i((o) => ({ ...o, [a]: void 0 })), []); return typeof (t == null ? void 0 : t.type) == "string" ? t : h(st.Provider, { value: { ele: e, mount: n, unmount: r }, children: E.cloneElement(t, { className: e.rootClassName, title: e.title, subTitle: e["sub-title"], actions: e.actions, extras: e.extras }) }); }; -$i.propTypes = { children: b.element.isRequired }; -const si = { close: ["M563.8 512l262.5-312.9c4.4-5.2 0.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9c-4.4 5.2-0.7 13.1 6.1 13.1h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"], check: ["M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474c-6.1-7.7-15.3-12.2-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1 0.4-12.8-6.3-12.8z"], info: ["M512 224m-64 0a64 64 0 1 0 128 0 64 64 0 1 0-128 0Z", "M544 392h-64c-4.4 0-8 3.6-8 8v464c0 4.4 3.6 8 8 8h64c4.4 0 8-3.6 8-8V400c0-4.4-3.6-8-8-8z"] }, Jt = ({ type: t, props: e }) => h("i", { ...e, children: h("svg", { viewBox: "0 0 1024 1024", width: "1em", height: "1em", fill: "currentColor", children: (si[t] || si.info).map((i, n) => h("path", { d: i }, n)) }) }), xi = ({ className: t, content: e, icon: i, $close: n }) => A(E.Fragment, { children: [i && h("div", { className: O("ff-notification-icon", t), children: h(Jt, { type: i }) }), e] }), Nn = ({}) => h(G, { children: "Confirm" }); -var xe, Be; +Si.propTypes = { children: b.element.isRequired }; +const li = { close: ["M563.8 512l262.5-312.9c4.4-5.2 0.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9c-4.4 5.2-0.7 13.1 6.1 13.1h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"], check: ["M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474c-6.1-7.7-15.3-12.2-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1 0.4-12.8-6.3-12.8z"], info: ["M512 224m-64 0a64 64 0 1 0 128 0 64 64 0 1 0-128 0Z", "M544 392h-64c-4.4 0-8 3.6-8 8v464c0 4.4 3.6 8 8 8h64c4.4 0 8-3.6 8-8V400c0-4.4-3.6-8-8-8z"] }, Gt = ({ type: t, props: e }) => h("i", { ...e, children: h("svg", { viewBox: "0 0 1024 1024", width: "1em", height: "1em", fill: "currentColor", children: (li[t] || li.info).map((i, n) => h("path", { d: i }, n)) }) }), vi = ({ className: t, content: e, icon: i, $close: n }) => A(E.Fragment, { children: [i && h("div", { className: O("ff-notification-icon", t), children: h(Gt, { type: i }) }), e] }), xn = ({}) => h(Y, { children: "Confirm" }); +var Se, We; const de = class de { constructor() { - S(this, Be, /* @__PURE__ */ new Map()); - N(this, "init", (e) => W(this, Be, new Map(e))); - N(this, "check", (e) => !c(this, Be).has(e) || c(this, Be).get(e)); - if (c(de, xe)) return c(de, xe); + v(this, We, /* @__PURE__ */ new Map()); + x(this, "init", (e) => B(this, We, new Map(e))); + x(this, "check", (e) => !c(this, We).has(e) || c(this, We).get(e)); + if (c(de, Se)) return c(de, Se); } }; -xe = new WeakMap(), Be = new WeakMap(), S(de, xe, null), N(de, "getInstance", () => (c(de, xe) || W(de, xe, new de()), c(de, xe))); +Se = new WeakMap(), We = new WeakMap(), v(de, Se, null), x(de, "getInstance", () => (c(de, Se) || B(de, Se, new de()), c(de, Se))); let Vt = de; -const Si = Vt.getInstance(), Pn = (t, e, i = "children") => { +const Ni = Vt.getInstance(), Pn = (t, e, i = "children") => { if (m.isEmpty(t)) return {}; const n = m.find(t, ["value", e]); if (!m.isEmpty(n)) return n; @@ -98,19 +98,19 @@ const Si = Vt.getInstance(), Pn = (t, e, i = "children") => { if (!m.isEmpty(s)) return s; } return {}; -}, vi = (t = "Input", e = "@pkg/ff/grid-layout-forms") => t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`; -var Se, Xe; +}, xi = (t = "Input", e = "@pkg/ff/grid-layout-forms") => t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`; +var ve, Xe; const ue = class ue { constructor() { - S(this, Xe, null); - N(this, "init", (e) => W(this, Xe, e)); - N(this, "get", (e, i) => m.get(c(this, Xe), e, i)); - if (c(ue, Se)) return c(ue, Se); + v(this, Xe, null); + x(this, "init", (e) => B(this, Xe, e)); + x(this, "get", (e, i) => m.get(c(this, Xe), e, i)); + if (c(ue, ve)) return c(ue, ve); } }; -Se = new WeakMap(), Xe = new WeakMap(), S(ue, Se, null), N(ue, "getInstance", () => (c(ue, Se) || W(ue, Se, new ue()), c(ue, Se))); -let Mt = ue; -const Me = Mt.getInstance(), li = { null2json: (t) => Object.create(), null2array: (t) => [], null2number: (t) => 0, null2bool: (t) => !1, null2string: (t) => "", null2integer: (t) => 0, null2float: (t) => 0, string2json: (t) => t ? JSON.parse(t) : "{}", string2array: (t) => t.substr(0, 1) === "[" && t.substr(-1) === "]" ? JSON.parse(t) : t.split(","), string2number: (t) => t == "" ? 0 : +t, string2integer: (t) => t == "" ? 0 : +t, string2float: (t) => t == "" ? 0 : +t, string2bool: (t) => { +ve = new WeakMap(), Xe = new WeakMap(), v(ue, ve, null), x(ue, "getInstance", () => (c(ue, ve) || B(ue, ve, new ue()), c(ue, ve))); +let Dt = ue; +const Ve = Dt.getInstance(), ci = { null2json: (t) => Object.create(), null2array: (t) => [], null2number: (t) => 0, null2bool: (t) => !1, null2string: (t) => "", null2integer: (t) => 0, null2float: (t) => 0, string2json: (t) => t ? JSON.parse(t) : "{}", string2array: (t) => t.substr(0, 1) === "[" && t.substr(-1) === "]" ? JSON.parse(t) : t.split(","), string2number: (t) => t == "" ? 0 : +t, string2integer: (t) => t == "" ? 0 : +t, string2float: (t) => t == "" ? 0 : +t, string2bool: (t) => { switch (`${t}`.toLowerCase()) { case "0": case "false": @@ -123,8 +123,8 @@ const Me = Mt.getInstance(), li = { null2json: (t) => Object.create(), null2arra let i = "string"; i = Array.isArray(t) ? "array" : typeof t, m.isObject(t) && (i = "json"); const n = `${i}2${e}`; - return Reflect.has(li, n) ? li[n](t) : t; -}, Tn = (t) => t === null ? "null" : Array.isArray(t) ? "array" : typeof t == "object" ? "json" : typeof t == "boolean" ? "bool" : typeof t == "string" ? "string" : typeof t == "number" ? Number.isInteger(t) ? "integer" : "float" : typeof t, lt = (t = {}, e = {}, i = {}, n = "") => Ni(t, (r, a) => a === "type" && r === "code") ? Pi(t, e, i, n) : Ti(t, e, n), Ni = (t, e = () => !1) => m.some(t, (i) => !!m.some(i, e) || (m.isEmpty(i) || !m.isPlainObject(i) && !m.isArray(i) ? void 0 : Ni(i, e))), Pi = async (t = {}, e = {}, i = {}, n = "") => { + return Reflect.has(ci, n) ? ci[n](t) : t; +}, Tn = (t) => t === null ? "null" : Array.isArray(t) ? "array" : typeof t == "object" ? "json" : typeof t == "boolean" ? "bool" : typeof t == "string" ? "string" : typeof t == "number" ? Number.isInteger(t) ? "integer" : "float" : typeof t, lt = (t = {}, e = {}, i = {}, n = "") => Pi(t, (r, a) => a === "type" && r === "code") ? Ti(t, e, i, n) : Oi(t, e, n), Pi = (t, e = () => !1) => m.some(t, (i) => !!m.some(i, e) || (m.isEmpty(i) || !m.isPlainObject(i) && !m.isArray(i) ? void 0 : Pi(i, e))), Ti = async (t = {}, e = {}, i = {}, n = "") => { let r = /* @__PURE__ */ Object.create(null); for (let a in t) { let o; @@ -143,17 +143,17 @@ const Me = Mt.getInstance(), li = { null2json: (t) => Object.create(), null2arra break; case "router": case "query": - o = Ee.getPageParams(l); + o = $e.getPageParams(l); break; case "string": o = l; } o ?? (o = u); - } else o = await Pi(t[a], e, i, n); + } else o = await Ti(t[a], e, i, n); m.set(r, a, o); } return r; -}, Ti = (t = {}, e = {}, i = "") => Object.keys(t || {}).reduce((n, r) => { +}, Oi = (t = {}, e = {}, i = "") => Object.keys(t || {}).reduce((n, r) => { if (m.isPlainObject(t[r])) { let a; if (Reflect.has(t[r], "type") && ["field", "router", "query", "string"].includes(t[r].type)) { @@ -164,34 +164,34 @@ const Me = Mt.getInstance(), li = { null2json: (t) => Object.create(), null2arra break; case "router": case "query": - a = Ee.getPageParams(s); + a = $e.getPageParams(s); break; case "string": a = s; } a ?? (a = l); - } else a = Ti(t[r], e, i); + } else a = Oi(t[r], e, i); m.set(n, r, a); } return n; -}, {}), Ft = (t, e) => t && typeof t == "object" ? Array.isArray(t) ? t.map((i) => Ft(i, e)) : Object.keys(t).reduce((i, n) => (e[n] ? i[e[n]] = Ft(t[n], e) : i[n] = Ft(t[n], e), i), {}) : t, Gr = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (t) => { +}, {}), Ft = (t, e) => t && typeof t == "object" ? Array.isArray(t) ? t.map((i) => Ft(i, e)) : Object.keys(t).reduce((i, n) => (e[n] ? i[e[n]] = Ft(t[n], e) : i[n] = Ft(t[n], e), i), {}) : t, Xr = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (t) => { const e = 16 * Math.random() | 0; return (t === "x" ? e : 3 & e | 8).toString(16); -}), Xr = (t) => { +}), Qr = (t) => { var e, i; return t ? (i = (e = t.match(/^@pkg(?:[^\/]*\/){3}(?[^\/]+)/)) == null ? void 0 : e.groups) == null ? void 0 : i.name : ""; -}, Qr = (t) => { +}, Zr = (t) => { var e, i; return t ? (i = (e = t.match(/^@pkg(?:[^\/]*\/){2}(?[^\/]+)/)) == null ? void 0 : e.groups) == null ? void 0 : i.category : ""; -}, Zr = (t) => { +}, ea = (t) => { var e, i; return t ? (i = (e = t.match(/^@pkg(?:[^\/]*\/){1}(?[^\/]+)/)) == null ? void 0 : e.groups) == null ? void 0 : i.owner : ""; }, On = (t, e = 32, i = "auto") => { - const n = Dt(t), r = i === "auto" ? "x64" : i; + const n = zt(t), r = i === "auto" ? "x64" : i; if (e === 32) return Rt.x86.hash32(n).toString(); if (e === 128) return r === "x64" ? Rt.x64.hash128(n) : Rt.x86.hash128(n); throw new Error("bits 只能是 32 或 128"); -}, Dt = (t) => t == null ? "null" : typeof t == "string" ? t : typeof t == "number" || typeof t == "boolean" ? String(t) : typeof t == "function" ? t.toString() : Array.isArray(t) ? "[" + t.map(Dt).join(",") + "]" : typeof t == "object" ? "{" + Object.keys(t).sort().map((e) => `${e}:${Dt(t[e])}`).join(",") + "}" : String(t), Rn = () => { +}, zt = (t) => t == null ? "null" : typeof t == "string" ? t : typeof t == "number" || typeof t == "boolean" ? String(t) : typeof t == "function" ? t.toString() : Array.isArray(t) ? "[" + t.map(zt).join(",") + "]" : typeof t == "object" ? "{" + Object.keys(t).sort().map((e) => `${e}:${zt(t[e])}`).join(",") + "}" : String(t), Rn = () => { let t = 1; const e = /* @__PURE__ */ new WeakMap(), i = /* @__PURE__ */ new Map(); return (...n) => n.length === 0 ? "" : n.map((r) => { @@ -206,20 +206,20 @@ const Me = Mt.getInstance(), li = { null2json: (t) => Object.create(), null2arra } catch { return !1; } -}, ea = (t, e = "") => { +}, ta = (t, e = "") => { if (!t || typeof t != "string" || Fn(t)) return t; let i = e; return !i && typeof window < "u" && window.location && (i = `${window.location.protocol}//${window.location.host}`), t.startsWith("/") ? i ? `${i}${t}` : t : i ? `${i}/${t}` : t; }; -var kt, Qe, Ze, Et; -const $t = class $t { +var kt, Qe, Ze, $t; +const Et = class Et { constructor(...e) { - S(this, Qe, []); - S(this, Ze, (e) => { + v(this, Qe, []); + v(this, Ze, (e) => { var i; - for (let n of e) Array.isArray(n[0]) ? c(this, Ze).call(this, n) : c(this, Qe).push(c(i = $t, kt).call(i, n[0], n[1])); + for (let n of e) Array.isArray(n[0]) ? c(this, Ze).call(this, n) : c(this, Qe).push(c(i = Et, kt).call(i, n[0], n[1])); }); - N(this, "toValue", async (e, i = null) => { + x(this, "toValue", async (e, i = null) => { const n = { getValue: () => e, getRecord: () => i }; let r = e; for (const a of c(this, Qe)) try { @@ -234,9 +234,9 @@ const $t = class $t { } return r; }); - N(this, "toRender", (e, i, n = null) => E.createElement(c(this, Et), { value: e, record: i }, n)); - S(this, Et, ({ value: e, record: i, children: n }) => { - const [r, a] = j(n); + x(this, "toRender", (e, i, n = null) => E.createElement(c(this, $t), { value: e, record: i }, n)); + v(this, $t, ({ value: e, record: i, children: n }) => { + const [r, a] = I(n); return dt(() => { let o = !1; return a(n), this.toValue(e, i).then((s) => !o && a(s)).catch((s) => !o && a(`${s}`)), () => o = !0; @@ -245,7 +245,7 @@ const $t = class $t { c(this, Ze).call(this, e); } }; -kt = new WeakMap(), Qe = new WeakMap(), Ze = new WeakMap(), Et = new WeakMap(), S($t, kt, m.memoize((e, i) => { +kt = new WeakMap(), Qe = new WeakMap(), Ze = new WeakMap(), $t = new WeakMap(), v(Et, kt, m.memoize((e, i) => { if (typeof e == "function") return e(i); if (typeof e == "string") return se.getWidgetComponent(e).then((n) => { var r; @@ -253,7 +253,7 @@ kt = new WeakMap(), Qe = new WeakMap(), Ze = new WeakMap(), Et = new WeakMap(), }); throw new TypeError("middleware must be a string or a function"); }, Rn())); -let bt = $t; +let bt = Et; const ne = E.createContext({ listCode: "", classNames: {}, getBase62params: (t, e) => { }, onReload: () => { }, onClickCallback: () => { @@ -270,68 +270,68 @@ const ne = E.createContext({ listCode: "", classNames: {}, getBase62params: (t, }, setSider: () => { }, setKeyword: () => { }, setCondition: () => { -} }), ci = ({ className: t, record: e, column: i, ...n }) => { +} }), di = ({ className: t, record: e, column: i, ...n }) => { if (i != null && i.editableByJs && (i != null && i.uuid)) { const { formSetting: r = { primaryKey: "id" }, widgetSetting: a = {}, widgetContainerSetting: o = {} } = (i == null ? void 0 : i.editableByJsSetting) || {}; return h(P.Popover, { widget: An, widgetData: { record: e, column: i }, widgetSetting: { widgetSetting: a, formSetting: r }, widgetContainerProps: { title: i != null && i.title ? `${i.title} - 编辑` : "编辑", ...o, width: (o == null ? void 0 : o.width) || 260, arrow: !0 }, children: h("td", { className: O("ff-data-list-cell-editable", t), ...n }) }); } return h("td", { className: t, ...n }); }, An = ({ record: t, column: e, $close: i, $setting: n }) => { - const r = _(Tn(m.get(t, e == null ? void 0 : e.dataIndex))), { listCode: a, onClickCallback: o } = le(ne), [s] = ie.useForm(), { formSetting: l, widgetSetting: u } = n, d = (l == null ? void 0 : l.primaryKey) || "id", p = () => { + const r = H(Tn(m.get(t, e == null ? void 0 : e.dataIndex))), { listCode: a, onClickCallback: o } = le(ne), [s] = ie.useForm(), { formSetting: l, widgetSetting: u } = n, d = (l == null ? void 0 : l.primaryKey) || "id", p = () => { s.setFieldsValue({ value: m.get(t, e == null ? void 0 : e.dataIndex), __PROPS__: t }); }; - return dt(() => p(), [t, e == null ? void 0 : e.dataIndex, a]), h(G, { actions: A(E.Fragment, { children: [h(P, { size: "small", onClick: p, children: "重置" }), A(cn.Compact, { block: !0, children: [h(P, { size: "small", widget: i, children: "取消" }), h(P, { type: "primary", size: "small", widget: () => s.validateFields().then(({ value: f }) => { + return dt(() => p(), [t, e == null ? void 0 : e.dataIndex, a]), h(Y, { actions: A(E.Fragment, { children: [h(P, { size: "small", onClick: p, children: "重置" }), A(dn.Compact, { block: !0, children: [h(P, { size: "small", widget: i, children: "取消" }), h(P, { type: "primary", size: "small", widget: () => s.validateFields().then(({ value: f }) => { const g = m.get(t, d.substring(d.indexOf(".") + 1)); if (!g) throw "获取更新主键失败!"; - I.put(`/api/${a}-storeBy-${e == null ? void 0 : e.uuid}/${g}`, { value: f }).msg(() => o(2, t)).then(i); - }).catch(console.warn), children: "保存" })] })] }), children: A(ie, { form: s, children: [h(Xt, { label: "", type: r.current, code: "value", widget: e == null ? void 0 : e.editableByJs, extras: u }), h(Ht, { noStyle: !0, name: ["__PROPS__"], children: () => { + j.put(`/api/${a}-storeBy-${e == null ? void 0 : e.uuid}/${g}`, { value: f }).msg(() => o(2, t)).then(i); + }).catch(console.warn), children: "保存" })] })] }), children: A(ie, { form: s, children: [h(Qt, { label: "", type: r.current, code: "value", widget: e == null ? void 0 : e.editableByJs, extras: u }), h(Jt, { noStyle: !0, name: ["__PROPS__"], children: () => { } })] }) }); }, Ln = (t) => function(e) { return t(e, getRecord()); -}, jn = (t, e = {}) => K(() => { +}, In = (t, e = {}) => K(() => { var i; return (i = t == null ? void 0 : t.filter(Boolean)) == null ? void 0 : i.map(({ widgetByJs: n, widgetByJsSetting: r, ...a }, o) => { const s = (u) => ({ record: u, column: a }); let l = []; return n && l.push([n, r]), l.length > 0 ? (a != null && a.render && l.push([Ln, a.render]), { ...a, onCell: s, render: (u, d) => new bt(l).toRender(u, d, "-") }) : { ...a, onCell: s }; }); -}, [t, e]), In = (t = {}) => K(() => { +}, [t, e]), jn = (t = {}) => K(() => { var e; - return t.body ?? (t.body = { cell: ci }), (e = t.body).cell ?? (e.cell = ci), t; -}, [t]), ta = (t) => { - const [e, i] = j({}); - return V(() => { + return t.body ?? (t.body = { cell: di }), (e = t.body).cell ?? (e.cell = di), t; +}, [t]), ia = (t) => { + const [e, i] = I({}); + return M(() => { let n = !1; - return t && I.get(`/api/_/${t}`).then((r) => m.pick(r, ["uuid", "name", "code", "resource", "marginX", "marginY", "cols", "rowHeight", "primaryKey", "columns", "itemOperations", "batchOperations", "isConditionFormLayout", "layout", "tabs", "pageSize", "layoutConfig"])).then((r) => !n && i(r)), () => n = !0; + return t && j.get(`/api/_/${t}`).then((r) => m.pick(r, ["uuid", "name", "code", "resource", "marginX", "marginY", "cols", "rowHeight", "primaryKey", "columns", "itemOperations", "batchOperations", "isConditionFormLayout", "layout", "tabs", "pageSize", "layoutConfig"])).then((r) => !n && i(r)), () => n = !0; }, [t]), e; -}, ia = (t, e = {}) => { - const [i, n] = j({ dataSource: [] }); +}, na = (t, e = {}) => { + const [i, n] = I({ dataSource: [] }); return ct(() => { let r = !1; - return t && I.get(`/api/${t}/${I.encode({ page: 1, ...e })}`).then((a) => !r && n(a)), () => r = !0; + return t && j.get(`/api/${t}/${j.encode({ page: 1, ...e })}`).then((a) => !r && n(a)), () => r = !0; }, [t, e]), i; -}, Oi = (t = [], e = /* @__PURE__ */ new Map(), i = "id", n) => { +}, Ri = (t = [], e = /* @__PURE__ */ new Map(), i = "id", n) => { const r = X(n ? (a) => m.get(a, i, m.get(a, [n, i])) : (a) => m.get(a, i), [i, n]); return X((a) => t == null ? void 0 : t.filter((o) => !o.uuid || !e.has(o.uuid) || e.get(o.uuid).some((s) => s == r(a))), [t, e, r]); -}, zt = (t = [], e = /* @__PURE__ */ new Map(), i = [], n = "id", r) => { +}, Bt = (t = [], e = /* @__PURE__ */ new Map(), i = [], n = "id", r) => { const a = X(r ? (o) => m.get(o, n, m.get(o, [r, n])) : (o) => m.get(o, n), [n, r]); return K(() => { - if (m.isEmpty(t) || !t.some(({ uuid: s }) => Si.check(s))) return !1; + if (m.isEmpty(t) || !t.some(({ uuid: s }) => Ni.check(s))) return !1; if (m.isEmpty(e) || m.isEmpty(i)) return !0; const o = i.map((s) => a(s)); return t.some(({ uuid: s }) => !s || !e.has(s) || e.get(s).some((l) => o.some((u) => u == l))); }, [t, i, e, a]); -}, Vn = (t, e, i = "id", n = null) => { - const r = Nt(), a = _(!1), o = _(t.dataSource), s = _(t.itemOperationsAccess); - return V(() => (o.current = t.dataSource, s.current = t.itemOperationsAccess, () => a.current = !1), [t.dataSource, t.itemOperationsAccess]), a.current && (t.dataSource = o.current, t.itemOperationsAccess = s.current), [t, (l = 0, u = null) => { +}, Mn = (t, e, i = "id", n = null) => { + const r = xt(), a = H(!1), o = H(t.dataSource), s = H(t.itemOperationsAccess); + return M(() => (o.current = t.dataSource, s.current = t.itemOperationsAccess, () => a.current = !1), [t.dataSource, t.itemOperationsAccess]), a.current && (t.dataSource = o.current, t.itemOperationsAccess = s.current), [t, (l = 0, u = null) => { var d, p; if (a.current = !1, l === 1) return (d = t.onReload) == null ? void 0 : d.call(t); if (l === 2) { const f = m.get(u, "__PARENT_ID__", ""), g = m.get(u, i, m.get(u, [n, i], "")), y = m.findIndex(o.current, ["__PARENT_ID__", f]), w = m.findIndex(y > -1 ? m.get(o.current, [y, "children"]) : o.current, [i, g]); if (w === -1) return (p = t.onReload) == null ? void 0 : p.call(t); - Promise.all([I.get(`/api/${e}/detail/${g}`), I.post(`/api/${e}/list-operations-access`, { ids: g })]).then(([C, k]) => { - const x = m.get(o.current, y > -1 ? [y, "children", w, "children"] : [w, "children"]); - o.current = Ci(o.current, y > -1 ? { [y]: { children: { $splice: [[w, 1, { ...C, children: x }]] } } } : { $splice: [[w, 1, { ...C, children: x }]] }); + Promise.all([j.get(`/api/${e}/detail/${g}`), j.post(`/api/${e}/list-operations-access`, { ids: g })]).then(([C, k]) => { + const S = m.get(o.current, y > -1 ? [y, "children", w, "children"] : [w, "children"]); + o.current = ki(o.current, y > -1 ? { [y]: { children: { $splice: [[w, 1, { ...C, children: S }]] } } } : { $splice: [[w, 1, { ...C, children: S }]] }); const $ = new Map(k); s.current.forEach((T, F) => { var L; @@ -344,9 +344,9 @@ const ne = E.createContext({ listCode: "", classNames: {}, getBase62params: (t, }); } }]; -}, Mn = (t, e) => { - const i = Nt(), n = _(e), r = _(/* @__PURE__ */ new Map()), a = _([]), o = m.throttle((l) => { - a.current = [], I.list(t, m.pick({ ...n.current, ...l }, ["tab", "page", "pageSize", "condition", "sider", "keyword"])).then(({ keyword: u, condition: d, total: p, tab: f, sider: g, page: y, pageSize: w, operationsAccess: C, dataSource: k }) => { +}, Vn = (t, e) => { + const i = xt(), n = H(e), r = H(/* @__PURE__ */ new Map()), a = H([]), o = m.throttle((l) => { + a.current = [], j.list(t, m.pick({ ...n.current, ...l }, ["tab", "page", "pageSize", "condition", "sider", "keyword"])).then(({ keyword: u, condition: d, total: p, tab: f, sider: g, page: y, pageSize: w, operationsAccess: C, dataSource: k }) => { n.current = { tab: f, condition: d, sider: g, keyword: u, total: p, pageSize: w, page: k != null && k.length ? y : 1 }, a.current = k, r.current = new Map(C), i(); }); }, 380, { leading: !1, trailing: !0 }); @@ -354,165 +354,165 @@ const ne = E.createContext({ listCode: "", classNames: {}, getBase62params: (t, a.current = [], t && o(e); }, [t, e]); const s = K(() => m.pick(n.current, ["total", "tab", "page", "pageSize", "condition", "sider", "keyword"]), [n.current]); - return Object.assign(s, { onTabChange: (l) => o({ tab: l, page: 1 }), onPageChange: (l, u) => o({ page: l, pageSize: u }), onPageSizeChange: (l) => o({ pageSize: l, page: 1 }), onConditionChange: (l, u) => o({ keyword: u, condition: Ci(n.current.condition || {}, { $merge: l || {} }), page: 1 }), onSiderChange: (l) => o({ sider: l, page: 1 }), onKeywordChange: (l) => o({ keyword: l, page: 1 }), itemOperationsAccess: r.current, dataSource: a.current, onReload: o, payload: e == null ? void 0 : e.payload }); -}, Dn = ({ listCode: t, className: e, layouts: i = {}, dataSource: n, isPaginate: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: u, resource: d, primaryKey: p, title: f, itemGridLayout: g, $setting: y, tabs: w, isConditionFormLayout: C, isTreeSider: k, treeSiderConfig: x }) => { - const { classNames: $, onClickCallback: T } = le(ne), F = m.pick(y, ["column", "colWidth", "beforeRender", "afterRender", "style"]), L = Oi(l, u, p, d), D = X((U, R, M) => h(zn, { className: O("ff-data-list-framework-item", $.item), operations: a ? L(R) : [], data: d ? { [d]: R } : R, children: U, onClickCallback: T }), [d, p, a, T, l, u]); - return A("div", { className: O("ff-data-list-framework", e), children: [h(i.sider, { isTreeSider: k, ...x }), A("div", { className: O("ff-data-list-container", $ == null ? void 0 : $.container), children: [h(i.filter, { isConditionFormLayout: C }), h(i.toolbar, { title: f, tabs: w }), h(Zn, { ...F, ...g, primaryKey: p, itemRender: D, dataSource: n }), h(i.footer, { isPaginate: r, isOperations: o, operations: s })] })] }); -}, zn = ({ className: t, operations: e, children: i, data: n, onClickCallback: r }) => A("div", { className: O("data-list-grid-layout-item", t), children: [h("div", { className: "data-list-grid-layout-item-container", children: i }), !!(e != null && e.length) && h("div", { className: "data-list-grid-layout-item-actions", children: e.map((a) => h("span", { className: "data-list-grid-layout-item-action", children: h(P.Link, { uuid: a.uuid, type: a.type, name: a.name, widget: a.widget, widgetType: a.widgetType, widgetProps: a.widgetProps, widgetSetting: a.widgetSetting, widgetContainerProps: a.widgetContainerSetting, data: n, confirm: a.confirm, onAfterClick: (o) => o !== !1 && (r == null ? void 0 : r(a.isRefresh, n)) }, a.uuid || jt()) }, (a == null ? void 0 : a.uuid) || jt())) })] }), Wn = ({ listCode: t, className: e, layouts: i = {}, dataSource: n, columns: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: u, resource: d, primaryKey: p, title: f, tabs: g, isPaginate: y, isTreeSider: w, treeSiderConfig: C, isConditionFormLayout: k, ...x }) => { - const { classNames: $, onClickCallback: T } = le(ne), F = Oi(l, u, p, d), L = zt(l, u, n, p, d); - return A("div", { className: O("ff-data-table-framework", e), children: [h(i.sider, { isTreeSider: w, ...C }), A("div", { className: O("ff-data-table-container", $ == null ? void 0 : $.container), children: [h(i.filter, { isConditionFormLayout: k }), h(i.toolbar, { title: f, tabs: g }), h(Hn, { ...x, primaryKey: p, className: "ff-data-table-content", columns: r, dataSource: n, operationRender: L ? (D) => { + return Object.assign(s, { onTabChange: (l) => o({ tab: l, page: 1 }), onPageChange: (l, u) => o({ page: l, pageSize: u }), onPageSizeChange: (l) => o({ pageSize: l, page: 1 }), onConditionChange: (l, u) => o({ keyword: u, condition: ki(n.current.condition || {}, { $merge: l || {} }), page: 1 }), onSiderChange: (l) => o({ sider: l, page: 1 }), onKeywordChange: (l) => o({ keyword: l, page: 1 }), itemOperationsAccess: r.current, dataSource: a.current, onReload: o, payload: e == null ? void 0 : e.payload }); +}, Dn = ({ listCode: t, className: e, layouts: i = {}, dataSource: n, isPaginate: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: u, resource: d, primaryKey: p, title: f, itemGridLayout: g, $setting: y, tabs: w, isConditionFormLayout: C, isTreeSider: k, treeSiderConfig: S }) => { + const { classNames: $, onClickCallback: T } = le(ne), F = m.pick(y, ["column", "colWidth", "beforeRender", "afterRender", "style"]), L = Ri(l, u, p, d), D = X((U, R, V) => h(zn, { className: O("ff-data-list-framework-item", $ == null ? void 0 : $.item), operations: a ? L(R) : [], data: d ? { [d]: R } : R, children: U, onClickCallback: T }), [d, p, a, T, l, u]); + return A("div", { className: O("ff-data-list-framework", e), children: [h(i.sider, { isTreeSider: k, ...S }), A("div", { className: O("ff-data-list-container", $ == null ? void 0 : $.container), children: [h(i.filter, { isConditionFormLayout: C }), h(i.toolbar, { title: f, tabs: w }), h(er, { ...F, ...g, empty: h(i.empty, { className: $ == null ? void 0 : $.empty }), primaryKey: p, itemRender: D, dataSource: n }), h(i.footer, { isPaginate: r, isOperations: o, operations: s })] })] }); +}, zn = ({ className: t, operations: e, children: i, data: n, onClickCallback: r }) => A("div", { className: O("data-list-grid-layout-item", t), children: [h("div", { className: "data-list-grid-layout-item-container", children: i }), !!(e != null && e.length) && h("div", { className: "data-list-grid-layout-item-actions", children: e.map((a) => h("span", { className: "data-list-grid-layout-item-action", children: h(P.Link, { uuid: a.uuid, type: a.type, name: a.name, widget: a.widget, widgetType: a.widgetType, widgetProps: a.widgetProps, widgetSetting: a.widgetSetting, widgetContainerProps: a.widgetContainerSetting, data: n, confirm: a.confirm, onAfterClick: (o) => o !== !1 && (r == null ? void 0 : r(a.isRefresh, n)) }, a.uuid || It()) }, (a == null ? void 0 : a.uuid) || It())) })] }), Bn = ({ listCode: t, className: e, layouts: i = {}, dataSource: n, columns: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: u, resource: d, primaryKey: p, title: f, tabs: g, isPaginate: y, isTreeSider: w, treeSiderConfig: C, isConditionFormLayout: k, ...S }) => { + const { classNames: $, onClickCallback: T } = le(ne), F = Ri(l, u, p, d), L = Bt(l, u, n, p, d); + return A("div", { className: O("ff-data-table-framework", e), children: [h(i.sider, { isTreeSider: w, ...C }), A("div", { className: O("ff-data-table-container", $ == null ? void 0 : $.container), children: [h(i.filter, { isConditionFormLayout: k }), h(i.toolbar, { title: f, tabs: g }), h(Jn, { ...S, primaryKey: p, className: "ff-data-table-content", columns: r, dataSource: n, operationRender: L ? (D) => { var U; - return h("div", { className: "ff-data-table-actions", children: (U = F(D)) == null ? void 0 : U.map((R, M) => h(P.Link, { size: "small", uuid: R.uuid, type: R.type, name: R.name, widget: R.widget, widgetType: R.widgetType, widgetProps: R.widgetProps, widgetData: R.widgetData, widgetSetting: R.widgetSetting, widgetContainerProps: R.widgetContainerSetting, data: D, confirm: R.confirm, onAfterClick: (v) => v !== !1 && (T == null ? void 0 : T(R.isRefresh, D)) }, R.uuid || M)) }); + return h("div", { className: "ff-data-table-actions", children: (U = F(D)) == null ? void 0 : U.map((R, V) => h(P.Link, { size: "small", uuid: R.uuid, type: R.type, name: R.name, widget: R.widget, widgetType: R.widgetType, widgetProps: R.widgetProps, widgetData: R.widgetData, widgetSetting: R.widgetSetting, widgetContainerProps: R.widgetContainerSetting, data: D, confirm: R.confirm, onAfterClick: (N) => N !== !1 && (T == null ? void 0 : T(R.isRefresh, D)) }, R.uuid || V)) }); } : null }), h(i.footer, { isPaginate: y, isOperations: o, operations: s })] })] }); }, Yt = (t = [], e, i = null) => { var n; - return (n = m.sortBy(t, ["y", "x"])) == null ? void 0 : n.map(({ i: r, x: a, y: o, w: s, h: l, field: { boxStyle: u, ...d } = {} }, p) => h("div", { className: "grid-layout-item", style: Ri(a, o, s, l, u), children: h(e, { ...d, basicForm: i }) }, r ?? p)); -}, Ri = (t, e, i, n, r = {}, a = 0) => { + return (n = m.sortBy(t, ["y", "x"])) == null ? void 0 : n.map(({ i: r, x: a, y: o, w: s, h: l, field: { boxStyle: u, ...d } = {} }, p) => h("div", { className: "grid-layout-item", style: Fi(a, o, s, l, u), children: h(e, { ...d, basicForm: i }) }, r ?? p)); +}, Fi = (t, e, i, n, r = {}, a = 0) => { const o = { "--grid-layout-h": `${n}`, "--grid-layout-w": `${i}`, "--grid-layout-x": `${t}`, "--grid-layout-y": `${e}`, "--grid-layout-row-height-offset": "0px" }; - return r != null && r.autoHeight ? o.height = "fit-content" : o["--grid-layout-row"] = `${n}`, r != null && r.alignItems && (o["--grid-layout-box-align-items"] = r.alignItems), r != null && r.justifyContent && (o["--grid-layout-box-justify-content"] = r.justifyContent), o["--grid-layout-box-margin"] = di(r == null ? void 0 : r.marginTop, r == null ? void 0 : r.marginRight, r == null ? void 0 : r.marginBottom, r == null ? void 0 : r.marginLeft), o["--grid-layout-box-padding"] = di(r == null ? void 0 : r.paddingTop, r == null ? void 0 : r.paddingRight, r == null ? void 0 : r.paddingBottom, r == null ? void 0 : r.paddingLeft), a && (o.height = `${a}px`), o; -}, di = (t, e, i, n) => `${t || 0}px ${e || 0}px ${i || 0}px ${n || 0}px`, na = (t = "Text", e = "@pkg/ff/grid-layouts") => t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`, Fi = ({ className: t, isConditionFormLayout: e }) => { + return r != null && r.autoHeight ? o.height = "fit-content" : o["--grid-layout-row"] = `${n}`, r != null && r.alignItems && (o["--grid-layout-box-align-items"] = r.alignItems), r != null && r.justifyContent && (o["--grid-layout-box-justify-content"] = r.justifyContent), o["--grid-layout-box-margin"] = ui(r == null ? void 0 : r.marginTop, r == null ? void 0 : r.marginRight, r == null ? void 0 : r.marginBottom, r == null ? void 0 : r.marginLeft), o["--grid-layout-box-padding"] = ui(r == null ? void 0 : r.paddingTop, r == null ? void 0 : r.paddingRight, r == null ? void 0 : r.paddingBottom, r == null ? void 0 : r.paddingLeft), a && (o.height = `${a}px`), o; +}, ui = (t, e, i, n) => `${t || 0}px ${e || 0}px ${i || 0}px ${n || 0}px`, ra = (t = "Text", e = "@pkg/ff/grid-layouts") => t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`, Ai = ({ className: t, isConditionFormLayout: e }) => { var f, g; - const [i, n] = j({}), { listCode: r, onKeywordChange: a, onConditionChange: o, getBase62params: s, classNames: l } = E.useContext(ne), { keyword: u, condition: d } = (s == null ? void 0 : s()) || {}, [p] = ft.useForm(); - return V(() => { - r && e && I.get(`/api/_/${r}/list-condition-form-layout`).then(({ resource: y, marginX: w, marginY: C, rowHeight: k, cols: x, fields: $ }) => { - n({ resource: y, itemMargin: [w, C], rowHeight: k, cols: x, fields: $ }); + const [i, n] = I({}), { listCode: r, onKeywordChange: a, onConditionChange: o, getBase62params: s, classNames: l } = E.useContext(ne), { keyword: u, condition: d } = (s == null ? void 0 : s()) || {}, [p] = ft.useForm(); + return M(() => { + r && e && j.get(`/api/_/${r}/list-condition-form-layout`).then(({ resource: y, marginX: w, marginY: C, rowHeight: k, cols: S, fields: $ }) => { + n({ resource: y, itemMargin: [w, C], rowHeight: k, cols: S, fields: $ }); }).catch(() => n({})); - }, [r, e]), V(() => { + }, [r, e]), M(() => { p.setFieldsValue({ keyword: u, ...d }); }, [JSON.stringify([u, d])]), h("div", { className: O("ff-data-list-filter", l.filter, t), children: h(ft, { form: p, layout: "vertical", autoComplete: "off", onFinish: ((f = i.fields) == null ? void 0 : f.length) > 1 ? (y) => o({ [i.resource]: y[i.resource] }, y.keyword) : () => { }, onValuesChange: (y) => { m.isEmpty(m.omit(y, ["keyword"])) || p.submit(); - }, children: ((g = i.fields) == null ? void 0 : g.length) > 1 ? h(Qt, { ...i, children: h(Bn, { onReset: () => { + }, children: ((g = i.fields) == null ? void 0 : g.length) > 1 ? h(Zt, { ...i, children: h(Wn, { onReset: () => { const { keyword: y, condition: w } = s("init") || {}; p.setFieldsValue({ keyword: y, ...w }); - } }) }) : h("div", { className: "ff-data-list-filter-default-form ff-grid-layout-form", children: h("div", { className: "grid-layout-item", style: Ri(20, 0, 5, 2), children: h(ft.Item, { name: ["keyword"], children: h(dn.Search, { allowClear: !0, enterButton: "搜索", placeholder: "多关键字 | 分割", onSearch: (y) => a(y) }) }) }) }) }) }); -}, Bn = ({ cols: t, fields: e, onReset: i }) => { - const [n, r] = j(!1), a = K(() => e == null ? void 0 : e.toReversed().some((o) => o.y > 1 || o.x + o.w >= t - 5), [t, e]); + } }) }) : h("div", { className: "ff-data-list-filter-default-form ff-grid-layout-form", children: h("div", { className: "grid-layout-item", style: Fi(20, 0, 5, 2), children: h(ft.Item, { name: ["keyword"], children: h(un.Search, { allowClear: !0, enterButton: "搜索", placeholder: "多关键字 | 分割", onSearch: (y) => a(y) }) }) }) }) }) }); +}, Wn = ({ cols: t, fields: e, onReset: i }) => { + const [n, r] = I(!1), a = K(() => e == null ? void 0 : e.toReversed().some((o) => o.y > 1 || o.x + o.w >= t - 5), [t, e]); return A(ft.Item, { label: " ", style: { "--item-span": 5 }, className: O("ff-data-list-filter-actions", { expanded: n }), children: [h(wt, { onClick: i, children: "重置" }), h(wt, { type: "primary", htmlType: "submit", children: "查询" }), a && h(P.Link, { className: "ff-data-list-filter-expanded-button", widget: () => r((o) => !o), type: "primary", name: n ? "关闭" : "展开", icon: n ? "icon-up" : "icon-down", iconPosition: "end" })] }); }; -Fi.reservedFields = [{ x: 0, y: 0, h: 3, w: 5, field: { isVirtual: !0, widgetPrefix: "@pkg/ff/grid-layout-forms", widget: "Input", code: "keyword", label: "关键字", placeholder: "多关键字 | 分割", extras: { prefix: "icon-search" } } }]; +Ai.reservedFields = [{ x: 0, y: 0, h: 3, w: 5, field: { isVirtual: !0, widgetPrefix: "@pkg/ff/grid-layout-forms", widget: "Input", code: "keyword", label: "关键字", placeholder: "多关键字 | 分割", extras: { prefix: "icon-search" } } }]; const Un = ({ className: t, operations: e, isOperations: i, isPaginate: n }) => { const { onPageChange: r, onPageSizeChange: a, onClickCallback: o, getBase62params: s } = E.useContext(ne), { total: l, page: u, pageSize: d } = (s == null ? void 0 : s()) || {}; - return i && !m.isEmpty(e) || n ? A("div", { className: O("ff-data-list-footer", t), children: [h("div", { className: "ff-data-list-actions", children: e == null ? void 0 : e.map((p, f) => h(P, { uuid: p.uuid, type: p.type, name: p.name, widget: p.widget, widgetType: p.widgetType, widgetProps: p.widgetProps, widgetData: p.widgetData, widgetSetting: p.widgetSetting, widgetContainerProps: p.widgetContainerSetting, onAfterClick: (g) => g !== !1 && (o == null ? void 0 : o(p.isRefresh, null)) }, p.uuid || f)) }), n && h(un, { size: "small", total: l, pageSize: d, showSizeChanger: !1, showTotal: (p) => `第 ${u} 页 / 总共 ${p} 条`, onChange: r, onShowSizeChange: a })] }) : null; + return i && !m.isEmpty(e) || n ? A("div", { className: O("ff-data-list-footer", t), children: [h("div", { className: "ff-data-list-actions", children: e == null ? void 0 : e.map((p, f) => h(P, { uuid: p.uuid, type: p.type, name: p.name, widget: p.widget, widgetType: p.widgetType, widgetProps: p.widgetProps, widgetData: p.widgetData, widgetSetting: p.widgetSetting, widgetContainerProps: p.widgetContainerSetting, onAfterClick: (g) => g !== !1 && (o == null ? void 0 : o(p.isRefresh, null)) }, p.uuid || f)) }), n && h(pn, { size: "small", total: l, pageSize: d, showSizeChanger: !1, showTotal: (p) => `第 ${u} 页 / 总共 ${p} 条`, onChange: r, onShowSizeChange: a })] }) : null; }, qn = [{ title: "parent 1", key: "0-0", children: [{ title: "parent 1-0", key: "0-0-0", disabled: !0, children: [{ title: "leaf", key: "0-0-0-0", disableCheckbox: !0 }, { title: "leaf", key: "0-0-0-1" }] }, { title: "parent 1-1", key: "0-0-1", children: [{ title: h("span", { style: { color: "#1677ff" }, children: "sss" }), key: "0-0-1-0" }] }] }], Kn = ({ className: t, width: e = 280, isTreeSider: i }) => { const { classNames: n } = le(ne); - return i ? h(pn.DirectoryTree, { className: O("ff-data-list-sider", n.sider, t), style: { "--sider-width": e }, showLine: !0, showIcon: !1, treeData: qn }) : null; -}, _n = ({ className: t, title: e, tabs: i }) => { + return i ? h(gn.DirectoryTree, { className: O("ff-data-list-sider", n.sider, t), style: { "--sider-width": e }, showLine: !0, showIcon: !1, treeData: qn }) : null; +}, Hn = ({ className: t, title: e, tabs: i }) => { const { getBase62params: n, onTabChange: r, onReload: a, classNames: o } = le(ne), { tab: s } = (n == null ? void 0 : n()) || {}, [l, u] = bn((i == null ? void 0 : i[0].value) ?? (i == null ? void 0 : i[0].code), { value: s, onChange: r }); - return A("div", { className: O("ff-data-list-toolbar", o.toolbar, t), children: [h("div", { className: "ff-data-list-title", children: e }), h(gn, { className: "ff-data-list-tabs", itemRender: ({ label: d, code: p, value: f }) => h("span", { onClick: () => u(f ?? p), className: O("ff-data-list-tab", { active: (f ?? p) == l }), children: d }), items: i }), A("div", { className: "ff-data-list-actions", children: [h(P.Link, { icon: "icon-reload", widget: () => a() }), h(P.Link, { icon: "icon-setting" })] })] }); -}, Ai = ({ isItemGridLayout: t, theme: e, themeProps: i, onClickCallback: n, onReload: r, listCode: a, total: o = 0, page: s = 0, onPageChange: l, pageSize: u = 30, onPageSizeChange: d, tab: p, onTabChange: f, keyword: g, onKeywordChange: y, condition: w, onConditionChange: C, sider: k, onSiderChange: x, layouts: $, classNames: T = {}, payload: F = {}, ...L }) => { - const [D, U] = j(), R = X((v, B) => { + return A("div", { className: O("ff-data-list-toolbar", o.toolbar, t), children: [h("div", { className: "ff-data-list-title", children: e }), h(hn, { className: "ff-data-list-tabs", itemRender: ({ label: d, code: p, value: f }) => h("span", { onClick: () => u(f ?? p), className: O("ff-data-list-tab", { active: (f ?? p) == l }), children: d }), items: i }), A("div", { className: "ff-data-list-actions", children: [h(P.Link, { icon: "icon-reload", widget: () => a() }), h(P.Link, { icon: "icon-setting" })] })] }); +}, _n = ({ className: t, ...e }) => h(Mt, { className: O(t, "ff-data-list-empty"), image: Mt.PRESENTED_IMAGE_SIMPLE, ...e }), Li = ({ isItemGridLayout: t, theme: e, themeProps: i, onClickCallback: n, onReload: r, listCode: a, total: o = 0, page: s = 0, onPageChange: l, pageSize: u = 30, onPageSizeChange: d, tab: p, onTabChange: f, keyword: g, onKeywordChange: y, condition: w, onConditionChange: C, sider: k, onSiderChange: S, layouts: $, classNames: T = {}, payload: F = {}, ...L }) => { + const [D, U] = I(), R = X((N, W) => { const z = { tab: p, page: s, pageSize: u, keyword: g, sider: k, condition: w, total: o, payload: F }; - return v && v != "init" ? m.get(z, v, B) : z; - }, [JSON.stringify(w), JSON.stringify(F), p, s, u, g, k, o]), M = K(() => { - let v = { sider: Kn, filter: Fi, footer: Un, toolbar: _n }; - $ === !1 ? v = { sider: null, filter: null, footer: null, toolbar: null } : m.isPlainObject($) && (v = Object.assign({}, v, $)); - for (const B in v) if (v[B]) { - if (rn(v[B])) { - const z = v[B]; - v[B] = ($e) => E.cloneElement(z, $e); + return N && N != "init" ? m.get(z, N, W) : z; + }, [JSON.stringify(w), JSON.stringify(F), p, s, u, g, k, o]), V = K(() => { + let N = { sider: Kn, filter: Ai, footer: Un, toolbar: Hn, empty: _n }; + $ === !1 ? N = { sider: null, filter: null, footer: null, toolbar: null, empty: null } : m.isPlainObject($) && (N = Object.assign({}, N, $)); + for (const W in N) if (N[W]) { + if (an(N[W])) { + const z = N[W]; + N[W] = (Ee) => E.cloneElement(z, Ee); } - } else v[B] = () => h(E.Fragment, {}); - return v; + } else N[W] = () => h(E.Fragment, {}); + return N; }, [$]); - return V(() => { - e ? se.getWidgetComponent(e).then((v) => { - if (!v) throw `${e} not found`; - return v; - }).catch((v) => ({ default: () => `${v}` })).then((v) => U(E.createElement(v.default, { ...L, layouts: M, $setting: i }))) : U(h(t ? Dn : Wn, { ...L, layouts: M, $setting: i })); - }, [e, i]), h(ne.Provider, { value: { classNames: T, listCode: a, onClickCallback: n, onReload: r, getBase62params: R, onPageChange: l, onPageSizeChange: d, onTabChange: f, onSiderChange: x, onKeywordChange: y, onConditionChange: C, setPage: l, setPageSize: d, setTab: f, setSider: x, setKeyword: y, setCondition: C }, children: D && E.cloneElement(D, L) }); + return M(() => { + e ? se.getWidgetComponent(e).then((N) => { + if (!N) throw `${e} not found`; + return N; + }).catch((N) => ({ default: () => `${N}` })).then((N) => U(E.createElement(N.default, { ...L, layouts: V, $setting: i }))) : U(h(t ? Dn : Bn, { ...L, layouts: V, $setting: i })); + }, [e, i]), h(ne.Provider, { value: { classNames: T, listCode: a, onClickCallback: n, onReload: r, getBase62params: R, onPageChange: l, onPageSizeChange: d, onTabChange: f, onSiderChange: S, onKeywordChange: y, onConditionChange: C, setPage: l, setPageSize: d, setTab: f, setSider: S, setKeyword: y, setCondition: C }, children: D && E.cloneElement(D, L) }); }; -Ai.propTypes = { classNames: b.exact({ sider: b.string, filter: b.string, footer: b.string, toolbar: b.string, container: b.string, content: b.string, item: b.string }), layouts: b.oneOfType([b.exact({ sider: b.oneOfType([b.elementType, b.element]), filter: b.oneOfType([b.elementType, b.element]), footer: b.oneOfType([b.elementType, b.element]), toolbar: b.oneOfType([b.elementType, b.element]) }), b.bool]) }; -var ve, be, Ie, xt; +Li.propTypes = { classNames: b.exact({ sider: b.string, filter: b.string, footer: b.string, toolbar: b.string, container: b.string, content: b.string, item: b.string, empty: b.string }), layouts: b.oneOfType([b.exact({ sider: b.oneOfType([b.elementType, b.element]), filter: b.oneOfType([b.elementType, b.element]), footer: b.oneOfType([b.elementType, b.element]), toolbar: b.oneOfType([b.elementType, b.element]), empty: b.oneOfType([b.elementType, b.element]) }), b.bool]) }; +var Ne, be, je, St; const pe = class pe { constructor() { - S(this, be, null); - S(this, Ie, /* @__PURE__ */ new Map()); - S(this, xt, () => { + v(this, be, null); + v(this, je, /* @__PURE__ */ new Map()); + v(this, St, () => { if (c(this, be)) return c(this, be).port.postMessage({ command: "status", data: [] }); - W(this, be, new SharedWorker(new URL("/ff-worker/res-ws.js", self.location))), c(this, be).port.onmessage = (e) => { + B(this, be, new SharedWorker(new URL("/ff-worker/res-ws.js", self.location))), c(this, be).port.onmessage = (e) => { var i, n; - (i = e.data) != null && i.uuid ? c(this, Ie).forEach((r, a) => { + (i = e.data) != null && i.uuid ? c(this, je).forEach((r, a) => { var o; (r == "*" || (o = r == null ? void 0 : r.includes) != null && o.call(r, e.data.uuid)) && a(e.data); - }) : ((n = e.data) == null ? void 0 : n.readyState) == WebSocket.CLOSED && I.get("/api/user-api-token").then(({ token: r, expire_at: a }) => { - c(this, be).port.postMessage({ command: "initWs", data: [`ws${m.trimStart(I.appUrl, "http")}api/user-resource-status-ws?token=${r}`] }); + }) : ((n = e.data) == null ? void 0 : n.readyState) == WebSocket.CLOSED && j.get("/api/user-api-token").then(({ token: r, expire_at: a }) => { + c(this, be).port.postMessage({ command: "initWs", data: [`ws${m.trimStart(j.appUrl, "http")}api/user-resource-status-ws?token=${r}`] }); }); }, c(this, be).port.postMessage({ command: "status", data: [] }); }); - N(this, "subscribe", (e, i = []) => (i ? Array.isArray(i) && i.length == 0 ? i = "*" : Array.isArray(i) || (i = [i].flat()) : i = "*", c(this, Ie).set(e, i), c(this, Ie).size == 1 && c(this, xt).call(this), () => this.unsubscribe(e))); - N(this, "unsubscribe", (e) => c(this, Ie).delete(e)); - if (c(pe, ve)) return c(pe, ve); + x(this, "subscribe", (e, i = []) => (i ? Array.isArray(i) && i.length == 0 ? i = "*" : Array.isArray(i) || (i = [i].flat()) : i = "*", c(this, je).set(e, i), c(this, je).size == 1 && c(this, St).call(this), () => this.unsubscribe(e))); + x(this, "unsubscribe", (e) => c(this, je).delete(e)); + if (c(pe, Ne)) return c(pe, Ne); } }; -ve = new WeakMap(), be = new WeakMap(), Ie = new WeakMap(), xt = new WeakMap(), S(pe, ve, null), N(pe, "getInstance", () => (c(pe, ve) || W(pe, ve, new pe()), c(pe, ve))); +Ne = new WeakMap(), be = new WeakMap(), je = new WeakMap(), St = new WeakMap(), v(pe, Ne, null), x(pe, "getInstance", () => (c(pe, Ne) || B(pe, Ne, new pe()), c(pe, Ne))); let Wt = pe; -const Li = Wt.getInstance(), Gt = E.forwardRef(({ listCode: t, base62params: e, className: i, theme: n, themeProps: r, layouts: a, classNames: o }, s) => { - const [{ resource: l, primaryKey: u, batchOperations: d = [], itemOperations: p = [], columns: f = [], themeConfig: g, theme: y, isConditionFormLayout: w = !1, isTreeSider: C, treeSiderConfig: k, isItemGridLayout: x, itemGridLayout: { themeConfig: $, ...T } = {}, title: F, isPaginate: L, tabs: D }, U] = j({ isItemGridLayout: !1, itemGridLayout: {} }), R = Mn(t, e), [{ dataSource: M, itemOperationsAccess: v, condition: B, tab: z, keyword: $e, page: pt, total: gt, pageSize: Tt, sider: te, onConditionChange: qi, onTabChange: Ki, onKeywordChange: _i, onPageChange: Hi, onPageSizeChange: Ji, onSiderChange: Yi, onReload: Ot, payload: Gi }, ii] = Vn(R, t, u, l), Xi = zt(p, v, M, u), Qi = zt(d); - V(() => { +const Ii = Wt.getInstance(), Xt = E.forwardRef(({ listCode: t, base62params: e, className: i, theme: n, themeProps: r, layouts: a, classNames: o }, s) => { + const [{ resource: l, primaryKey: u, batchOperations: d = [], itemOperations: p = [], columns: f = [], themeConfig: g, theme: y, isConditionFormLayout: w = !1, isTreeSider: C, treeSiderConfig: k, isItemGridLayout: S, itemGridLayout: { themeConfig: $, ...T } = {}, title: F, isPaginate: L, tabs: D }, U] = I({ isItemGridLayout: !1, itemGridLayout: {} }), R = Vn(t, e), [{ dataSource: V, itemOperationsAccess: N, condition: W, tab: z, keyword: Ee, page: pt, total: gt, pageSize: Tt, sider: te, onConditionChange: Ki, onTabChange: Hi, onKeywordChange: _i, onPageChange: Ji, onPageSizeChange: Gi, onSiderChange: Yi, onReload: Ot, payload: Xi }, ni] = Mn(R, t, u, l), Qi = Bt(p, N, V, u), Zi = Bt(d); + M(() => { let re = null; - return t && I.get(`/api/_/${t}`).resp(({ data: ht, res: en }) => { - ht != null && ht.isDynamicRefresh && (re = Li.subscribe(() => Ot(), en)), U(ht); + return t && j.get(`/api/_/${t}`).resp(({ data: ht, res: tn }) => { + ht != null && ht.isDynamicRefresh && (re = Ii.subscribe(() => Ot(), tn)), U(ht); }).catch(() => U({})), () => re == null ? void 0 : re(); - }, [t]), E.useImperativeHandle(s, () => ({ onReload: Ot, onClickCallback: ii })); - const Zi = { listCode: t, title: F, classNames: o, layouts: a, resource: l, primaryKey: u, theme: n || y, themeProps: r || g, isTreeSider: C, treeSiderConfig: k, isPaginate: L, tabs: D, isItemOperations: Xi, itemOperations: p == null ? void 0 : p.map((re) => m.isEmpty(re == null ? void 0 : re.confirm) ? re : { ...re, confirm: Object.assign({}, re.confirm, { getPopupContainer: () => document.body }) }), isBatchOperations: Qi, batchOperations: d, isItemGridLayout: x, columns: f, itemGridLayout: { ...T, themeProps: $ }, isConditionFormLayout: w, itemOperationsAccess: v, dataSource: M, onConditionChange: qi, onTabChange: Ki, onKeywordChange: _i, onPageChange: Hi, onPageSizeChange: Ji, onSiderChange: Yi, condition: B, tab: z, keyword: $e, page: pt, total: gt, pageSize: Tt, sider: te, payload: Gi }; - return h(Ai, { ...Zi, className: O("ff-data-list-helper", i), onReload: Ot, onClickCallback: ii }); -}), ji = (t, e, i = !0) => i !== !0 && i-- <= 0 ? [] : m.isArray(t) && !m.isEmpty(t) ? t.reduce((n, r) => (Reflect.has(r, e) && Reflect.has(r, "children") && n.push(r[e]), Reflect.has(r, "children") && !m.isEmpty(r.children) ? n.concat(ji(r.children, e, i)) : n), []) : [], Hn = ({ className: t, primaryKey: e, columns: i = [], dataSource: n = [], operationRender: r, operationWidth: a = 180, components: o = {}, ...s }) => { - const { classNames: l } = le(ne), u = _(null), d = _(null), [p, f] = j([]), [g, y] = j({ width: 0, height: 0 }); - V(() => { + }, [t]), E.useImperativeHandle(s, () => ({ onReload: Ot, onClickCallback: ni })); + const en = { listCode: t, title: F, classNames: o, layouts: a, resource: l, primaryKey: u, theme: n || y, themeProps: r || g, isTreeSider: C, treeSiderConfig: k, isPaginate: L, tabs: D, isItemOperations: Qi, itemOperations: p == null ? void 0 : p.map((re) => m.isEmpty(re == null ? void 0 : re.confirm) ? re : { ...re, confirm: Object.assign({}, re.confirm, { getPopupContainer: () => document.body }) }), isBatchOperations: Zi, batchOperations: d, isItemGridLayout: S, columns: f, itemGridLayout: { ...T, themeProps: $ }, isConditionFormLayout: w, itemOperationsAccess: N, dataSource: V, onConditionChange: Ki, onTabChange: Hi, onKeywordChange: _i, onPageChange: Ji, onPageSizeChange: Gi, onSiderChange: Yi, condition: W, tab: z, keyword: Ee, page: pt, total: gt, pageSize: Tt, sider: te, payload: Xi }; + return h(Li, { ...en, className: O("ff-data-list-helper", i), onReload: Ot, onClickCallback: ni }); +}), ji = (t, e, i = !0) => i !== !0 && i-- <= 0 ? [] : m.isArray(t) && !m.isEmpty(t) ? t.reduce((n, r) => (Reflect.has(r, e) && Reflect.has(r, "children") && n.push(r[e]), Reflect.has(r, "children") && !m.isEmpty(r.children) ? n.concat(ji(r.children, e, i)) : n), []) : [], Jn = ({ className: t, primaryKey: e, columns: i = [], dataSource: n = [], operationRender: r, operationWidth: a = 180, components: o = {}, ...s }) => { + const { classNames: l } = le(ne), u = H(null), d = H(null), [p, f] = I([]), [g, y] = I({ width: 0, height: 0 }); + M(() => { f(ji(n, e)); - }, [n, e]), an(() => { + }, [n, e]), on(() => { const k = new ResizeObserver(() => { - var x; - y({ width: ((x = u.current) == null ? void 0 : x.nativeElement.querySelector(".ant-table-body").scrollWidth) || d.current.offsetWidth, height: d.current.offsetHeight }); + var S; + y({ width: ((S = u.current) == null ? void 0 : S.nativeElement.querySelector(".ant-table-body").scrollWidth) || d.current.offsetWidth, height: d.current.offsetHeight }); }); return d.current && k.observe(d.current), () => { d.current && k.unobserve(d.current); }; }, []); - const w = jn(i), C = In(o); - return h("div", { ref: d, className: O("ff-data-list-table", l.content, t), children: g.height ? h(hn, { bordered: !0, ...s, components: C, ref: u, rowKey: (k) => (k == null ? void 0 : k[e]) ?? Math.random(), columns: w == null ? void 0 : w.concat(r ? [{ title: "操作", align: "center", fixed: "right", width: `${Math.ceil(a / g.width * 100).toFixed(2)}%`, render: (k, x, $) => r(x, $) }] : []), dataSource: n, size: "middle", scroll: { x: "max-content", y: g.height - 50 }, pagination: !1, expandable: { defaultExpandAllRows: !0, expandRowByClick: !0, onExpandedRowsChange: f, expandedRowKeys: p } }) : null }); -}, Jn = "RC_FORM_INTERNAL_HOOKS", Yn = (t) => { + const w = In(i), C = jn(o); + return h("div", { ref: d, className: O("ff-data-list-table", l.content, t), children: g.height ? h(mn, { bordered: !0, ...s, components: C, ref: u, rowKey: (k) => (k == null ? void 0 : k[e]) ?? Math.random(), columns: w == null ? void 0 : w.concat(r ? [{ title: "操作", align: "center", fixed: "right", width: `${Math.ceil(a / g.width * 100).toFixed(2)}%`, render: (k, S, $) => r(S, $) }] : []), dataSource: n, size: "middle", scroll: { x: "max-content", y: g.height - 50 }, pagination: !1, expandable: { defaultExpandAllRows: !0, expandRowByClick: !0, onExpandedRowsChange: f, expandedRowKeys: p } }) : null }); +}, Gn = "RC_FORM_INTERNAL_HOOKS", Yn = (t) => { const [e, i] = E.useState({ items: [] }); - return V(() => { - t && I.get(`/api/_/${t}`).then(({ uuid: n, code: r, name: a, resource: o, primaryKey: s, marginX: l, marginY: u, cols: d, rowHeight: p, fields: f, theme: g, themeSetting: y, groups: w }) => ({ uuid: n, code: r, name: a, resource: o, primaryKey: s, marginX: l, marginY: u, cols: d, rowHeight: p, theme: g, themeProps: y, groups: w, items: f })).then(i); + return M(() => { + t && j.get(`/api/_/${t}`).then(({ uuid: n, code: r, name: a, resource: o, primaryKey: s, marginX: l, marginY: u, cols: d, rowHeight: p, fields: f, theme: g, themeSetting: y, groups: w }) => ({ uuid: n, code: r, name: a, resource: o, primaryKey: s, marginX: l, marginY: u, cols: d, rowHeight: p, theme: g, themeProps: y, groups: w, items: f })).then(i); }, [t]), e; -}, Gn = (t, { initialValue: e, initialValueLanguage: i, convertJs: n, convertJsSetting: r, type: a = "string" }, o = null) => { - const s = _(!1), l = le(bi), [u, d] = j(), [p, f] = j(i != "javascript" && t ? l.getFieldValue(t) : void 0), { registerWatch: g } = l.getInternalHooks(Jn) || {}; - return V(() => g == null ? void 0 : g((y, w, C) => { +}, Xn = (t, { initialValue: e, initialValueLanguage: i, convertJs: n, convertJsSetting: r, type: a = "string" }, o = null) => { + const s = H(!1), l = le(Ci), [u, d] = I(), [p, f] = I(i != "javascript" && t ? l.getFieldValue(t) : void 0), { registerWatch: g } = l.getInternalHooks(Gn) || {}; + return M(() => g == null ? void 0 : g((y, w, C) => { if (!s.current) return; const k = m.get(w, t); m.isEqual(k, p) || f(oe(k, a)); - }), [p]), V(() => { + }), [p]), M(() => { i == "javascript" && e ? Fe.exec(e, {}, { getFieldValueForBasicForm: (y) => o ? o.getFieldValue(y) : l.getFieldValue(y), getFieldValue: (y) => l.getFieldValue(y) }).then((y) => f(oe(y, a))).catch((y) => notification.error({ message: `布局数据错误: ${JSON.stringify(y)}` })).finally(() => s.current = !0) : (e && f(oe(e ?? l.getFieldValue(t), a)), s.current = !0); }, [e, i]), ct(() => { s.current && n && new bt([n, r]).toValue(p, l.getFieldsValue(!0)).then(d).catch((y) => { d(y), console.error("布局数据转换错误: ", y, n); }); }, [p, n, r]), [u ?? p, p]; -}, ra = (t, e, i = null) => K(() => Yt(t, e, i), [t]), Ii = (t, e, i = {}, n = {}, r = {}, a = null) => { - const o = le(bi), s = Nt(), l = _(!0), u = _([]), [d, p] = j(e), [f, g] = j(), y = ie.useWatch((w) => JSON.stringify(m.pick(w, u.current)), o) || "{}"; +}, aa = (t, e, i = null) => K(() => Yt(t, e, i), [t]), Mi = (t, e, i = {}, n = {}, r = {}, a = null) => { + const o = le(Ci), s = xt(), l = H(!0), u = H([]), [d, p] = I(e), [f, g] = I(), y = ie.useWatch((w) => JSON.stringify(m.pick(w, u.current)), o) || "{}"; return dt(() => { t && Fe.exec(t, i, { ...n, getFieldValueForBasicForm: (w) => r ? r.getFieldValue(w) : null, getFieldValue: m.wrap(o.getFieldValue, (w, C) => (u.current.some((k) => m.isEqual(k, C)) || (u.current.push(C), s()), w == null ? void 0 : w(C))), isFieldTouched: o.isFieldTouched, isFieldsTouched: o.isFieldsTouched }).then((w) => { l.current && (p(w), g(null)); }).catch((w) => { l.current && (p(e), g(w)); }); - }, [t, y, o, i, n]), V(() => () => l.current = !1, []), t ? [a ? oe(d, a) : d, f] : [a ? oe(e, a) : e, null]; -}, Xn = ({ widget: t, widgetPrefix: e = "@pkg/ff/grid-layouts", basicForm: i, ...n }) => { - const r = t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`, [a, o] = j(); - return V(() => { - r && se.getWidgetComponent(r).then(({ defaultProps: s = {}, default: l }) => ({ default: Qn(l, s, i) })).catch((s) => ({ default: () => `${s}` })).then((s) => o(E.createElement(s.default, n))); + }, [t, y, o, i, n]), M(() => () => l.current = !1, []), t ? [a ? oe(d, a) : d, f] : [a ? oe(e, a) : e, null]; +}, Qn = ({ widget: t, widgetPrefix: e = "@pkg/ff/grid-layouts", basicForm: i, ...n }) => { + const r = t != null && t.startsWith("@") || t != null && t.startsWith("blob:") ? t : `${e}/${t}`, [a, o] = I(); + return M(() => { + r && se.getWidgetComponent(r).then(({ defaultProps: s = {}, default: l }) => ({ default: Zn(l, s, i) })).catch((s) => ({ default: () => `${s}` })).then((s) => o(E.createElement(s.default, n))); }, [r]), a; -}, Qn = (t, e = {}, i = null) => (n) => { - const { code: r, label: a, extras: o, isVirtual: s, initialValue: l, initialValueLanguage: u, convertJs: d, convertJsSetting: p, value: f, ...g } = m.merge({}, e, n), [y, w] = Gn(s ? null : r, { initialValue: l, initialValueLanguage: u, convertJs: d, convertJsSetting: p, type: (g == null ? void 0 : g.type) || "string" }, i), C = K(() => { +}, Zn = (t, e = {}, i = null) => (n) => { + const { code: r, label: a, extras: o, isVirtual: s, initialValue: l, initialValueLanguage: u, convertJs: d, convertJsSetting: p, value: f, ...g } = m.merge({}, e, n), [y, w] = Xn(s ? null : r, { initialValue: l, initialValueLanguage: u, convertJs: d, convertJsSetting: p, type: (g == null ? void 0 : g.type) || "string" }, i), C = K(() => { const $ = Object.keys((e == null ? void 0 : e.extras) || {}); return m.over([m.partialRight(m.pick, $), m.partialRight(m.omit, $)]); - }, [e == null ? void 0 : e.extras]), [k, x] = C(g); - return h(t, { ...x, value: y, rawValue: w, $setting: Object.assign({}, o, k) }); + }, [e == null ? void 0 : e.extras]), [k, S] = C(g); + return h(t, { ...S, value: y, rawValue: w, $setting: Object.assign({}, o, k) }); }, Vi = ({ theme: t, basicForm: e, items: i = [{ key: "default", label: "默认" }], fields: n = [], itemRender: r, chunks: a = [], children: o, $setting: s = {}, ...l }) => { - const [u, d] = j(); - V(() => { + const [u, d] = I(); + M(() => { t ? se.getWidgetComponent(t).then((f) => { if (!(f != null && f.default)) throw "not found"; return f; @@ -520,64 +520,64 @@ const Li = Wt.getInstance(), Gt = E.forwardRef(({ listCode: t, base62params: e, }, [t]); const p = K(() => i == null ? void 0 : i.map((f) => ({ ...f, children: r(f, n == null ? void 0 : n.filter((g) => !(g != null && g.group) && f.key == "default" || g.group == f.key), f.key == "default" ? o : null) })).concat(a), [i, o, a]); return u && E.cloneElement(u, { items: p, basicForm: e, $setting: { ...s, ...l } }); -}, Mi = ({ name: t, form: e = null, basicForm: i = null, style: n = {}, className: r, cols: a = 12, rowHeight: o = 21, containerPadding: s = [0, 0], itemMargin: l = [4, 0], formProps: u = {}, formFields: d = [], fields: p = [], data: f, theme: g, themeProps: y = {}, groups: w = [{ key: "default", label: "默认" }], children: C, ...k }) => { - const [x] = ie.useForm(e), $ = K(() => [{ name: "__PROPS__", value: u }].concat(d), [u, d]); - ct(() => (x.setFieldsValue(f), () => x.resetFields()), [f]); +}, Di = ({ name: t, form: e = null, basicForm: i = null, style: n = {}, className: r, cols: a = 12, rowHeight: o = 21, containerPadding: s = [0, 0], itemMargin: l = [4, 0], formProps: u = {}, formFields: d = [], fields: p = [], data: f, theme: g, themeProps: y = {}, groups: w = [{ key: "default", label: "默认" }], children: C, ...k }) => { + const [S] = ie.useForm(e), $ = K(() => [{ name: "__PROPS__", value: u }].concat(d), [u, d]); + ct(() => (S.setFieldsValue(f), () => S.resetFields()), [f]); const T = (F, L, D) => { - const U = Yt(L, Xn, i); + const U = Yt(L, Qn, i); return A("div", { className: O("ff-grid-layout", r), style: { ...n, "--grid-layout-item-margin-y": `${(l == null ? void 0 : l[0]) || 0}px`, "--grid-layout-item-margin-x": `${(l == null ? void 0 : l[1]) || 0}px`, "--grid-layout-container-padding-y": `${(s == null ? void 0 : s[0]) || 0}px`, "--grid-layout-container-padding-x": `${(s == null ? void 0 : s[1]) || 0}px`, "--grid-layout-cols": a, "--grid-layout-row-height": `${o}px` }, children: [U, D && E.cloneElement(D, { cols: a, rowHeight: o, itemMargin: l, containerPadding: s, fields: L, basicForm: i })] }); }; - return h(ie, { ...k, fields: $, form: x, component: !1, children: g ? h(Vi, { ...y, items: w, theme: g, itemRender: T, fields: p, children: C, basicForm: i }) : T(0, p, C) }); -}, aa = /* @__PURE__ */ ((t) => function({ code: e, data: i, ...n }) { + return h(ie, { ...k, fields: $, form: S, component: !1, children: g ? h(Vi, { ...y, items: w, theme: g, itemRender: T, fields: p, children: C, basicForm: i }) : T(0, p, C) }); +}, oa = /* @__PURE__ */ ((t) => function({ code: e, data: i, ...n }) { const { uuid: r, resource: a, items: o, hides: s, rowHeight: l, marginX: u, marginY: d, cols: p, theme: f, themeProps: g, groups: y } = Yn(e) || {}, w = K(() => [{ name: "__RESOURCE__", value: a }, { name: "__LAYOUT_KEY__", value: e }, { name: "__LAYOUT_UUID__", value: r }], [e, r, a]); return a && h(t, { name: e, theme: f, themeProps: g, groups: y, ...n, fields: o, formFields: w, rowHeight: l, cols: p, itemMargin: [u, d], data: a ? { [a]: i } : i }); -})(Mi), Zn = ({ column: t = 0, colWidth: e = 0, cols: i, rowHeight: n, itemMargin: r, fields: a, primaryKey: o, dataSource: s, itemClassName: l, beforeRender: u = null, afterRender: d = null, itemRender: p = (x, $, T) => x, empty: f = h(mn, { description: null }), className: g, style: y = {}, theme: w, themeProps: C = {}, groups: k = [{ key: "default", label: "默认" }] }) => { - const { classNames: x } = le(ne), $ = K(() => h(Mi, { groups: k, theme: w, themeProps: C, cols: i, rowHeight: n, itemMargin: r, fields: a, className: l }), [a, i, n, r, k, w, C]), T = m.isEmpty(s); - return A("div", { className: O("ff-data-list-content", x.content, g), style: Object.assign({}, y, t && { "--col-num": t }, e && { "--col-width": e }), children: [u == null ? void 0 : u(s), T ? f : s.map((F, L) => { +})(Di), er = ({ column: t = 0, colWidth: e = 0, cols: i, rowHeight: n, itemMargin: r, fields: a, primaryKey: o, dataSource: s, beforeRender: l = null, afterRender: u = null, itemClassName: d, itemRender: p = (S, $, T) => S, empty: f = h(Mt, { description: null }), className: g, style: y = {}, theme: w, themeProps: C = {}, groups: k = [{ key: "default", label: "默认" }] }) => { + const { classNames: S } = le(ne), $ = K(() => h(Di, { groups: k, theme: w, themeProps: C, cols: i, rowHeight: n, itemMargin: r, fields: a, className: d }), [a, i, n, r, k, w, C]), T = m.isEmpty(s); + return A("div", { className: O("ff-data-list-content", S.content, g), style: Object.assign({}, y, t && { "--col-num": t }, e && { "--col-width": e }), children: [l == null ? void 0 : l(s), T ? f : s.map((F, L) => { const D = p(E.cloneElement($, { data: F }), F, L); return E.cloneElement(D, { key: `${(F == null ? void 0 : F[o]) ?? L}-${On(F)}` }); - }), d == null ? void 0 : d(s)] }); -}, er = ({ component: t, $props: e }) => { + }), u == null ? void 0 : u(s)] }); +}, tr = ({ component: t, $props: e }) => { const { base62params: i } = lt(e, {}); - return h(G, { children: h(Gt, { listCode: t, base62params: I.decode(i) }) }); -}, oa = () => h(Di, {}), Di = () => "Empty", tr = ({ component: t, $setting: e, $props: i }) => { - const [n, r] = j(); - V(() => { - if (!t) return r(h(Di, { description: null })); + return h(Y, { children: h(Xt, { listCode: t, base62params: j.decode(i) }) }); +}, sa = () => h(zi, {}), zi = () => "Empty", ir = ({ component: t, $setting: e, $props: i }) => { + const [n, r] = I(); + M(() => { + if (!t) return r(h(zi, { description: null })); se.getWidgetComponent(t).catch((o) => ({ default: () => `${o}` })).then((o) => E.createElement(o.default, { $setting: e })).then(r); }, [t]); const a = lt(i, {}); return n ? E.cloneElement(n, a) : null; -}, sa = () => "NotFoundPage"; -var Ne, ae, Pe, Te, et, tt; +}, la = () => "NotFoundPage"; +var xe, ae, Pe, Te, et, tt; const ge = class ge { constructor() { - S(this, ae, /* @__PURE__ */ new Map()); - S(this, Pe, {}); - S(this, Te, null); - N(this, "init", (e, i) => { - W(this, ae, e), W(this, Pe, i); + v(this, ae, /* @__PURE__ */ new Map()); + v(this, Pe, {}); + v(this, Te, null); + x(this, "init", (e, i) => { + B(this, ae, e), B(this, Pe, i); }); - N(this, "get", (e) => (c(this, ae).has(e) || (e = Array.from(c(this, ae).keys()).find((i) => c(this, ae).get(i).uri === e)), c(this, ae).get(e) || {})); - N(this, "redirect", (e, i, n = {}) => { + x(this, "get", (e) => (c(this, ae).has(e) || (e = Array.from(c(this, ae).keys()).find((i) => c(this, ae).get(i).uri === e)), c(this, ae).get(e) || {})); + x(this, "redirect", (e, i, n = {}) => { const { uri: r, type: a, widgetProps: o } = this.get(e) || {}, { router: s, query: l, ...u } = i || {}, d = Object.assign({}, u, s), p = Object.assign({}, u, l); - a == "list" && (d.base62params = I.encode(d != null && d.base62params ? d.base62params : d)); + a == "list" && (d.base62params = j.encode(d != null && d.base62params ? d.base62params : d)); let f = Cn(r || e, d); const g = new URLSearchParams(); for (const y in o || {}) (o == null ? void 0 : o.type) == "query" && Object.has(p, y) && g.append(y, JSON.stringify(p[y])); return g.size > 0 && (f = `${f}?${g.toString()}`), n != null && n.isOpenWindow ? window.open(f) : c(this, Te).navigate(f, { replace: !!(n != null && n.isReplaceRouteHistory) }); }); - N(this, "getMenus", (e) => { + x(this, "getMenus", (e) => { var i; return ((i = c(this, Pe)) == null ? void 0 : i[e]) || []; }); - N(this, "findMenuPathByUuid", (e) => { + x(this, "findMenuPathByUuid", (e) => { let i = []; for (const n in c(this, Pe)) if (i = c(this, et).call(this, c(this, Pe)[n], e, [n]), i.length > 1) return i; return i; }); - N(this, "getMenusByRouteUuid", (e) => c(this, tt).call(this, e, Object.values(c(this, Pe)).flat())); - S(this, et, (e, i, n = []) => { + x(this, "getMenusByRouteUuid", (e) => c(this, tt).call(this, e, Object.values(c(this, Pe)).flat())); + v(this, et, (e, i, n = []) => { if (m.isEmpty(e)) return n; for (const { uuid: r, children: a } of e) { if (r == i) return n.concat(r); @@ -585,29 +585,29 @@ const ge = class ge { } return n; }); - S(this, tt, (e, i) => { + v(this, tt, (e, i) => { var r; let n = []; for (const a of i) a.widgetType == "redirect" && (a.uuid == e || a.widget == e ? n.push(a) : (r = a.children) != null && r.length && (n = n.concat(c(this, tt).call(this, e, a.children)))); return n; }); - N(this, "getCurrentMenu", () => { + x(this, "getCurrentMenu", () => { const { uuid: e } = this.getCurrentRoute() || {}; if (!e) return; const i = this.getMenusByRouteUuid(e); return m.isEmpty(i) ? void 0 : i[0]; }); - N(this, "getCurrentRoute", (e = 0) => { + x(this, "getCurrentRoute", (e = 0) => { var n; const i = (n = c(this, Te).state.matches[c(this, Te).state.matches.length - 1 - e]) == null ? void 0 : n.route; if (!i) return null; for (let [r, a] of c(this, ae)) if (a.uri === i.path) return a; return null; }); - N(this, "getPageParams", (e) => { + x(this, "getPageParams", (e) => { var r, a, o; let i = "", n = {}; - if (ki()) n = kn(), i = (r = En()) == null ? void 0 : r.search; + if ($i()) n = kn(), i = (r = $n()) == null ? void 0 : r.search; else { const { location: s = {}, matches: l = [] } = ((a = c(this, Te)) == null ? void 0 : a.state) || {}; n = ((o = l[l.length - 1]) == null ? void 0 : o.params) || {}, i = s.search; @@ -616,51 +616,51 @@ const ge = class ge { n[l] = s; }), e ? m.get(n, e) : n; }); - N(this, "createBrowserRouter", (e = {}) => { + x(this, "createBrowserRouter", (e = {}) => { if (c(this, ae).size == 0) return null; - const i = Me.get("Common.WEBSITE_DEFAULT_THEME", "@pkg/ff/frameworks/DefaultTheme"), n = Me.get(se.checkUserToken() ? "Common.WEBSITE_LOGIN_REDIRECT" : "Common.WEBSITE_DEFAULT", "/index"), r = { [i]: 0 }, a = (s, l) => () => Promise.all([se.getWidgetComponent(s), lt(l)]).then(([u, d]) => [u.default || function() { + const i = Ve.get("Common.WEBSITE_DEFAULT_THEME", "@pkg/ff/frameworks/DefaultTheme"), n = Ve.get(se.checkUserToken() ? "Common.WEBSITE_LOGIN_REDIRECT" : "Common.WEBSITE_DEFAULT", "/index"), r = { [i]: 0 }, a = (s, l) => () => Promise.all([se.getWidgetComponent(s), lt(l)]).then(([u, d]) => [u.default || function() { return `${s}`; - }, d]).then(([u, d]) => ({ Component: () => E.createElement($i, {}, E.createElement(u, { $setting: d })) })), o = Array.from(c(this, ae).values()).reduce((s, { uuid: l, uri: u, name: d, type: p, component: f, widgetSetting: g, widgetProps: y, isLogin: w, isLayout: C, extra: k }) => { - let x = {}, $ = 0; + }, d]).then(([u, d]) => ({ Component: () => E.createElement(Si, {}, E.createElement(u, { $setting: d })) })), o = Array.from(c(this, ae).values()).reduce((s, { uuid: l, uri: u, name: d, type: p, component: f, widgetSetting: g, widgetProps: y, isLogin: w, isLayout: C, extra: k }) => { + let S = {}, $ = 0; switch (p) { case "list": - x.element = E.createElement(er, { component: f, $props: y }); + S.element = E.createElement(tr, { component: f, $props: y }); break; case "fsdpf-component": - x.element = E.createElement(tr, { key: f, component: f, $setting: g, $props: y }); + S.element = E.createElement(ir, { key: f, component: f, $setting: g, $props: y }); } const T = (k == null ? void 0 : k.theme) ?? (k == null ? void 0 : k.layout); if (T) { const F = (k == null ? void 0 : k.themeProps) ?? (k == null ? void 0 : k.layoutProps); - if (!r[T]) return r[T] = s.length, [...s, { path: "/", lazy: a(T, F), children: [{ path: u, ...x }] }]; + if (!r[T]) return r[T] = s.length, [...s, { path: "/", lazy: a(T, F), children: [{ path: u, ...S }] }]; $ = r[T]; } - return C && $ > -1 ? (s[$].children.push({ path: u, ...x }), s) : [...s, { path: u, ...x }]; + return C && $ > -1 ? (s[$].children.push({ path: u, ...S }), s) : [...s, { path: u, ...S }]; }, [{ path: "/", lazy: a(i, {}), children: [] }]); - return o.push({ index: !0, element: E.createElement(ir, { to: n, replace: !0 }) }), W(this, Te, $n(o, e)); + return o.push({ index: !0, element: E.createElement(nr, { to: n, replace: !0 }) }), B(this, Te, En(o, e)); }); - if (c(ge, Ne)) return c(ge, Ne); + if (c(ge, xe)) return c(ge, xe); } }; -Ne = new WeakMap(), ae = new WeakMap(), Pe = new WeakMap(), Te = new WeakMap(), et = new WeakMap(), tt = new WeakMap(), S(ge, Ne, null), N(ge, "getInstance", () => (c(ge, Ne) || W(ge, Ne, new ge()), c(ge, Ne))); -let Bt = ge; -const ir = ({ to: t, replace: e }) => ki() ? E.createElement(xn, { to: t, replace: e }) : (window.document.location = t, "redirect"), Ee = Bt.getInstance(), De = new Worker(new URL("/ff-worker/index.js", self.location)), ui = { getConfigure: (t) => Me.get(t), route: { redirect: (...t) => Ee.redirect(...t), getPageParams: (...t) => Ee.getPageParams(...t), getCurrentRoute: () => Ee.getCurrentRoute() }, popup: { notification: (...t) => ee.notification(...t), success: (...t) => ee.success(...t), error: (...t) => ee.error(...t), form: (...t) => ee.form(...t), modal: (...t) => ee.modal(...t), confirm: (...t) => ee.confirm(...t) } }; -var St, Ue, Oe; +xe = new WeakMap(), ae = new WeakMap(), Pe = new WeakMap(), Te = new WeakMap(), et = new WeakMap(), tt = new WeakMap(), v(ge, xe, null), x(ge, "getInstance", () => (c(ge, xe) || B(ge, xe, new ge()), c(ge, xe))); +let Ut = ge; +const nr = ({ to: t, replace: e }) => $i() ? E.createElement(Sn, { to: t, replace: e }) : (window.document.location = t, "redirect"), $e = Ut.getInstance(), De = new Worker(new URL("/ff-worker/index.js", self.location)), pi = { getConfigure: (t) => Ve.get(t), route: { redirect: (...t) => $e.redirect(...t), getPageParams: (...t) => $e.getPageParams(...t), getCurrentRoute: () => $e.getCurrentRoute() }, popup: { notification: (...t) => ee.notification(...t), success: (...t) => ee.success(...t), error: (...t) => ee.error(...t), form: (...t) => ee.form(...t), modal: (...t) => ee.modal(...t), confirm: (...t) => ee.confirm(...t) } }; +var vt, Ue, Oe; const q = class q { constructor() { - N(this, "exec", (e, i = {}, n = {}, r = "") => new Promise((a, o) => { + x(this, "exec", (e, i = {}, n = {}, r = "") => new Promise((a, o) => { if (!/^(?!\s*(\/\/|\/\*|\*)).*?\S+/m.test(e)) return a(); - const s = ai(q, St)._++; + const s = oi(q, vt)._++; c(q, Ue).set(s, n), q.mQueue.set(s, [a, o]), De.postMessage({ id: s, session: r, category: "eval", method: e, args: i }); })); - N(this, "clear", (e) => De.postMessage({ session: e, category: "clear" })); + x(this, "clear", (e) => De.postMessage({ session: e, category: "clear" })); if (c(q, Oe)) return c(q, Oe); - Promise.resolve().then(() => Pr).then((e) => { - ui.http = e.http; + Promise.resolve().then(() => Tr).then((e) => { + pi.http = e.http; }), De.addEventListener("message", ({ data: { id: e, task_id: i, method: n, args: r, category: a, data: o, error: s, session: l } }) => { if (a === "eval" && q.mQueue.has(e)) s !== null ? q.mQueue.get(e)[1](s) : q.mQueue.get(e)[0](o), c(q, Ue).delete(e), q.mQueue.delete(e); else if (a === "util") try { - const u = m.get(ui, n.split("/")) || m.get(c(q, Ue).get(i), n.split("/")); + const u = m.get(pi, n.split("/")) || m.get(c(q, Ue).get(i), n.split("/")); if (!m.isFunction(u)) throw `${n} not found`; Promise.resolve(Reflect.apply(u, void 0, r)).then((d) => { De.postMessage({ id: e, task_id: i, category: a, method: n, args: r, session: l, data: d, error: null }); @@ -673,60 +673,60 @@ const q = class q { }, !1); } }; -St = new WeakMap(), Ue = new WeakMap(), Oe = new WeakMap(), N(q, "mQueue", /* @__PURE__ */ new Map()), S(q, St, 0), S(q, Ue, /* @__PURE__ */ new Map()), S(q, Oe, null), N(q, "getInstance", () => (c(q, Oe) || W(q, Oe, new q()), c(q, Oe))); -let Ut = q; -const Fe = Ut.getInstance(), Nt = () => { - const t = _(!0), [, e] = E.useReducer((i) => i + 1, 0); - return V(() => () => t.current = !1, []), () => t.current && e(); -}, la = (t) => { - const e = _(); - return V(() => { +vt = new WeakMap(), Ue = new WeakMap(), Oe = new WeakMap(), x(q, "mQueue", /* @__PURE__ */ new Map()), v(q, vt, 0), v(q, Ue, /* @__PURE__ */ new Map()), v(q, Oe, null), x(q, "getInstance", () => (c(q, Oe) || B(q, Oe, new q()), c(q, Oe))); +let qt = q; +const Fe = qt.getInstance(), xt = () => { + const t = H(!0), [, e] = E.useReducer((i) => i + 1, 0); + return M(() => () => t.current = !1, []), () => t.current && e(); +}, ca = (t) => { + const e = H(); + return M(() => { e.current = t; }, [t]), e.current; -}, ca = (t) => { - const [e, i] = j(t), n = _(null), r = X((a, o) => { +}, da = (t) => { + const [e, i] = I(t), n = H(null), r = X((a, o) => { n.current = o, i(a); }, []); - return V(() => { + return M(() => { n.current && (n.current(e), n.current = null); }, [e]), [e, r]; }, ct = (t = (n) => { }, e, i = m.isEqual) => { const n = E.useRef(); i(e, n.current) || (n.current = m.cloneDeep(e)), E.useEffect(t, [n.current]); -}, dt = ct, zi = (t, e = "string") => { +}, dt = ct, Bi = (t, e = "string") => { var i; if (!Array.isArray(t)) return t; - for (let n = 0; n < t.length; n++) t[n].value = oe((i = t[n]) == null ? void 0 : i.value, e), t[n] && Reflect.has(t[n], "children") && (t[n].children = zi(t[n].children, e)); + for (let n = 0; n < t.length; n++) t[n].value = oe((i = t[n]) == null ? void 0 : i.value, e), t[n] && Reflect.has(t[n], "children") && (t[n].children = Bi(t[n].children, e)); return t; -}, da = (t, e = "json", i = "string", n, r = null) => { - const [a] = ie.useForm(n), [o, s] = j([{ label: "无", value: "", disabled: !0 }]), l = _([]), u = ie.useWatch((d) => l.current.length === 0 ? null : m.pick(d, l.current), a) || null; - return V(() => { +}, ua = (t, e = "json", i = "string", n, r = null) => { + const [a] = ie.useForm(n), [o, s] = I([{ label: "无", value: "", disabled: !0 }]), l = H([]), u = ie.useWatch((d) => l.current.length === 0 ? null : m.pick(d, l.current), a) || null; + return M(() => { Array.isArray(t) ? s(t) : e === "javascript" && t ? Fe.exec(t, {}, { getFieldValue: (d) => (l.current.includes(d) || l.current.push(d), a.getFieldValue(d)), getFieldValueForBasicForm: (d) => (l.current.includes(d) || l.current.push(d), r ? r.getFieldValue(d) : a.getFieldValue(d)) }).then((d) => { s(oe(d, "array")); }).catch((d) => console.error("useOptions", d)) : t && s(oe(t, "array")); - }, [t, e, u]), zi(o, i); -}, ua = (t) => { - const [e, i] = j(), n = { type: "GET" }; + }, [t, e, u]), Bi(o, i); +}, pa = (t) => { + const [e, i] = I(), n = { type: "GET" }; if (typeof t == "string" ? n.url = t : m.isPlainObject(t) && Object.assign(n, t), !(n != null && n.url)) throw "url is required"; - const r = (a) => I.request(n, !1).resp((o) => (console.log("useSubscribeRequest", a), i(o), o)); + const r = (a) => j.request(n, !1).resp((o) => (console.log("useSubscribeRequest", a), i(o), o)); return ct(() => { let a = null; return r().then((o) => { - a = Li.subscribe(m.throttle(r, 180, { leading: !1, trailing: !0 }), o.res); + a = Ii.subscribe(m.throttle(r, 180, { leading: !1, trailing: !0 }), o.res); }), () => a == null ? void 0 : a(); }, n), e; -}, nr = (t) => { +}, rr = (t) => { const [e, i] = E.useState({ items: [], hides: [] }); return E.useEffect(() => { - t && I.get(`/api/_/${t}`).then(({ pk: n, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: u, marginX: d, marginY: p, listenChangeFields: f, listenChangeFieldsFunc: g, fields: y, theme: w, themeSetting: C, groups: k }) => ({ pk: n, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: u, marginX: d, marginY: p, theme: w, themeProps: C, groups: k, listenChangeFields: f, listenChangeFieldsFunc: g, ...y.reduce((x, $) => { + t && j.get(`/api/_/${t}`).then(({ pk: n, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: u, marginX: d, marginY: p, listenChangeFields: f, listenChangeFieldsFunc: g, fields: y, theme: w, themeSetting: C, groups: k }) => ({ pk: n, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: u, marginX: d, marginY: p, theme: w, themeProps: C, groups: k, listenChangeFields: f, listenChangeFieldsFunc: g, ...y.reduce((S, $) => { var T; - return (T = $ == null ? void 0 : $.field) != null && T.hidden ? x.hides.push($ == null ? void 0 : $.field) : x.items.push($), x; + return (T = $ == null ? void 0 : $.field) != null && T.hidden ? S.hides.push($ == null ? void 0 : $.field) : S.items.push($), S; }, { items: [], hides: [] }) })).then(i); }, [t]), e; -}, rr = ({ max: t = 0, min: e = 0, type: i = "", message: n, pattern: r, required: a = !1, validator: o } = {}, s, l) => { - const [u, d] = j([]); - return V(() => { +}, ar = ({ max: t = 0, min: e = 0, type: i = "", message: n, pattern: r, required: a = !1, validator: o } = {}, s, l) => { + const [u, d] = I([]); + return M(() => { const p = []; if (a) { let f = l; @@ -758,223 +758,223 @@ const Fe = Ut.getInstance(), Nt = () => { } d(p); }, [t, e, i, n, r, a, o]), u; -}, ar = (t, e, i) => { - const [n, r] = j(null); - return V(() => { +}, or = (t, e, i) => { + const [n, r] = I(null); + return M(() => { const { initDataUri: a = `/api/${t}`, initDataMethod: o = "GET" } = i || {}; - e && I.request({ method: o, url: m.trimEnd(`${a}/${e}`, "/") }).then((s) => { + e && j.request({ method: o, url: m.trimEnd(`${a}/${e}`, "/") }).then((s) => { r(s); }); }, [t, e, i]), n; -}, or = (t, e, i) => X((n, r = { serialize: (a) => a, onSuccess: () => { +}, sr = (t, e, i) => X((n, r = { serialize: (a) => a, onSuccess: () => { }, onFail: (a) => (a == null ? void 0 : a.errorFields) && ee.error("请先完善表单信息", { duration: 2e3 }) }) => { const a = n.getFieldValue("__RESOURCE__"), { submitDataUri: o = `/api/${t}`, submitDataMethod: s = "POST" } = i || {}; - return n.validateFields().then((l) => a ? m.pick(l, [a]) : l).then(r.serialize).then((l) => I.request({ method: s, url: m.trimEnd(`${o}/${e || ""}`, "/"), data: l }).msg(r.onSuccess)).catch(r.onFail); -}, [t, e, i]), sr = (t, e, i, n) => { - const r = ar(e, i, n); - V(() => { + return n.validateFields().then((l) => a ? m.pick(l, [a]) : l).then(r.serialize).then((l) => j.request({ method: s, url: m.trimEnd(`${o}/${e || ""}`, "/"), data: l }).msg(r.onSuccess)).catch(r.onFail); +}, [t, e, i]), lr = (t, e, i, n) => { + const r = or(e, i, n); + M(() => { r ? t.setFieldsValue(r) : t.resetFields(); }, [t, r]); - const a = or(e, i, n); + const a = sr(e, i, n); return m.partial(a, t); -}, lr = (t, e, i = [], n = {}) => { - const r = _({}), a = _(), o = m.debounce(Nt(), 180), s = ["disabled", "required"], l = (f, g) => { +}, cr = (t, e, i = [], n = {}) => { + const r = H({}), a = H(), o = m.debounce(xt(), 180), s = ["disabled", "required"], l = (f, g) => { s.includes(f) && (r.current[f] = g), o(); - }, u = K(() => ({ setDisabled: (f) => l("disabled", f), setRequired: (f) => l("required", f), getDisabled: () => r.current.disabled, getRequired: () => r.current.required }), [e]), [d, p] = Ii(e, -1, {}, u, n); + }, u = K(() => ({ setDisabled: (f) => l("disabled", f), setRequired: (f) => l("required", f), getDisabled: () => r.current.disabled, getRequired: () => r.current.required }), [e]), [d, p] = Mi(e, -1, {}, u, n); if (!p && a.current != d && (d >= 0 || !m.isEmpty(i == null ? void 0 : i[d]))) { a.current = d; const { widget: f, widgetPrefix: g, props: y } = i == null ? void 0 : i[d]; - t = vi(f, g), r.current = m.merge(y, m.pick(r.current, s)); + t = xi(f, g), r.current = m.merge(y, m.pick(r.current, s)); } return [t, r.current]; -}, pi = (t) => t === void 0 || t === !1 ? "" : (Array.isArray(t) ? t : [t]).join("_"), pa = ({ value: t, onChange: e }, i = null) => { - const n = _(), [r] = ie.useForm(i), a = _({}); +}, gi = (t) => t === void 0 || t === !1 ? "" : (Array.isArray(t) ? t : [t]).join("_"), ga = ({ value: t, onChange: e }, i = null) => { + const n = H(), [r] = ie.useForm(i), a = H({}); return dt(() => { m.isEqual(n.current, t) || r.setFieldsValue(t); - }, [t]), V(() => () => r.resetFields(), []), [K(() => r.__INTERNAL__ ? r : { ...r, __INTERNAL__: { itemRef: (o) => (s) => { - const l = pi(o); + }, [t]), M(() => () => r.resetFields(), []), [K(() => r.__INTERNAL__ ? r : { ...r, __INTERNAL__: { itemRef: (o) => (s) => { + const l = gi(o); s ? a.current[l] = s : delete a.current[l]; } }, scrollToField: (o, s = {}) => { console.warn("useMergedFormValuesChange scrollToField not work, unreferenced antd form"); }, focusField: (o) => { console.warn("useMergedFormValuesChange focusField not work, unreferenced antd form"); }, getFieldInstance: (o) => { - const s = pi(o); + const s = gi(o); return a.current[s]; } }, [r]), (o, s) => { n.current = s, e == null || e(s); }]; -}, Xt = ({ widget: t = "Input", widgetPrefix: e = "@pkg/ff/grid-layout-forms", widgetDecorator: i, subWidgets: n = [], basicForm: r, ...a }) => { - const o = vi(t, e), [s, l] = lr(o, i, n, r), [u, d] = j(); - return V(() => { - s && se.getWidgetComponent(s).then(({ defaultProps: p = {}, default: f }) => ({ default: cr(f, p, r) })).catch((p) => ({ default: () => `${p}` })).then((p) => d(E.createElement(p.default, a))); +}, Qt = ({ widget: t = "Input", widgetPrefix: e = "@pkg/ff/grid-layout-forms", widgetDecorator: i, subWidgets: n = [], basicForm: r, ...a }) => { + const o = xi(t, e), [s, l] = cr(o, i, n, r), [u, d] = I(); + return M(() => { + s && se.getWidgetComponent(s).then(({ defaultProps: p = {}, default: f }) => ({ default: dr(f, p, r) })).catch((p) => ({ default: () => `${p}` })).then((p) => d(E.createElement(p.default, a))); }, [s]), u && E.cloneElement(u, { ...a, ...l }); -}, cr = (t, e = {}, i = null) => (n) => { - const { type: r, code: a, label: o, noStyle: s, style: l, placeholder: u, required: d = !1, extras: p, validators: f, help: g, isVirtual: y, $isReserved: w, initialValue: C, initialValueLanguage: k, ...x } = m.omit(m.merge({}, e, n), ["convertJs", "convertJsSetting", "widget", "widgetPerfix", "widgetDecorator", "subWidgets", "boxStyle"]), $ = rr(Object.assign({}, f, d ? { required: !0 } : {}), a, r), T = K(() => { +}, dr = (t, e = {}, i = null) => (n) => { + const { type: r, code: a, label: o, noStyle: s, style: l, placeholder: u, required: d = !1, extras: p, validators: f, help: g, isVirtual: y, $isReserved: w, initialValue: C, initialValueLanguage: k, ...S } = m.omit(m.merge({}, e, n), ["convertJs", "convertJsSetting", "widget", "widgetPerfix", "widgetDecorator", "subWidgets", "boxStyle"]), $ = ar(Object.assign({}, f, d ? { required: !0 } : {}), a, r), T = K(() => { const R = Object.keys((e == null ? void 0 : e.extras) || {}); return m.over([m.partialRight(m.pick, R), m.partialRight(m.omit, R)]); - }, [e == null ? void 0 : e.extras]), [F, L] = T(x), D = { label: o, noStyle: s, style: l, colon: !1, layout: "vertical" }, U = X((R) => R == null ? void 0 : oe(R, r), [r]); - return h(Ht, { name: a, rules: $, initialValue: U(C), normalize: U, children: (R, M, v) => { - var B; - return h(t, { type: r, rcform: v, basicForm: i, itemProps: { validateStatus: M.errors.length > 0 ? "error" : "success", tooltip: g || null, help: M.errors.length > 0 ? M.errors.join("、") : null, required: ((B = $ == null ? void 0 : $[0]) == null ? void 0 : B.required) || !1, ...D }, fieldProps: { placeholder: u, ...L, ...R }, $setting: Object.assign({}, p, F) }); + }, [e == null ? void 0 : e.extras]), [F, L] = T(S), D = { label: o, noStyle: s, style: l, colon: !1, layout: "vertical" }, U = X((R) => R == null ? void 0 : oe(R, r), [r]); + return h(Jt, { name: a, rules: $, initialValue: U(C), normalize: U, children: (R, V, N) => { + var W; + return h(t, { type: r, rcform: N, basicForm: i, itemProps: { validateStatus: V.errors.length > 0 ? "error" : "success", tooltip: g || null, help: V.errors.length > 0 ? V.errors.join("、") : null, required: ((W = $ == null ? void 0 : $[0]) == null ? void 0 : W.required) || !1, ...D }, fieldProps: { placeholder: u, ...L, ...R }, $setting: Object.assign({}, p, F) }); } }); -}, Qt = ({ name: t, form: e = null, basicForm: i = null, style: n = {}, className: r, cols: a = 24, rowHeight: o = 16, itemMargin: s = [8, 16], containerPadding: l = [0, 0], fields: u = [], hides: d = [], primaryKey: p = 0, formProps: f = {}, formFields: g = [], listenChangeFields: y, listenChangeFieldsFunc: w, onValuesChange: C, theme: k, themeProps: x = {}, groups: $ = [{ key: "default", label: "默认" }], children: T, ...F }) => { - const [L] = ie.useForm(e), D = X((M, v) => { - C == null || C(M, v), w && Array.isArray(y) && Fe.exec(w, { changedValues: M, allValues: v }, { getFieldValue: L.getFieldValue, setFieldValue: L.setFieldValue, setFieldsValue: L.setFieldsValue, isFieldTouched: L.isFieldTouched, isFieldsTouched: L.isFieldsTouched }).catch((B) => console.error("onFormValuesChange", t, B)); - }, [t, L, C, y, w]), U = K(() => [{ name: "__PROPS__", value: f }, { name: "__PRIMARY_KEY__", value: p }].concat(g), [p, f, g]), R = (M, v, B) => { - const z = Yt(v, Xt, i); - return A("div", { className: O("ff-grid-layout-form", r), style: { ...n, "--grid-layout-item-margin-x": `${(s == null ? void 0 : s[0]) ?? 8}px`, "--grid-layout-item-margin-y": `${(s == null ? void 0 : s[1]) ?? 16}px`, "--grid-layout-container-padding-y": `${(l == null ? void 0 : l[0]) || 0}px`, "--grid-layout-container-padding-x": `${(l == null ? void 0 : l[1]) || 0}px`, "--grid-layout-cols": a, "--grid-layout-row-height": `${o}px` }, children: [z, B && E.cloneElement(B, { cols: a, rowHeight: o, itemMargin: s, containerPadding: l, fields: v, basicForm: i })] }); +}, Zt = ({ name: t, form: e = null, basicForm: i = null, style: n = {}, className: r, cols: a = 24, rowHeight: o = 16, itemMargin: s = [8, 16], containerPadding: l = [0, 0], fields: u = [], hides: d = [], primaryKey: p = 0, formProps: f = {}, formFields: g = [], listenChangeFields: y, listenChangeFieldsFunc: w, onValuesChange: C, theme: k, themeProps: S = {}, groups: $ = [{ key: "default", label: "默认" }], children: T, ...F }) => { + const [L] = ie.useForm(e), D = X((V, N) => { + C == null || C(V, N), w && Array.isArray(y) && Fe.exec(w, { changedValues: V, allValues: N }, { getFieldValue: L.getFieldValue, setFieldValue: L.setFieldValue, setFieldsValue: L.setFieldsValue, isFieldTouched: L.isFieldTouched, isFieldsTouched: L.isFieldsTouched }).catch((W) => console.error("onFormValuesChange", t, W)); + }, [t, L, C, y, w]), U = K(() => [{ name: "__PROPS__", value: f }, { name: "__PRIMARY_KEY__", value: p }].concat(g), [p, f, g]), R = (V, N, W) => { + const z = Yt(N, Qt, i); + return A("div", { className: O("ff-grid-layout-form", r), style: { ...n, "--grid-layout-item-margin-x": `${(s == null ? void 0 : s[0]) ?? 8}px`, "--grid-layout-item-margin-y": `${(s == null ? void 0 : s[1]) ?? 16}px`, "--grid-layout-container-padding-y": `${(l == null ? void 0 : l[0]) || 0}px`, "--grid-layout-container-padding-x": `${(l == null ? void 0 : l[1]) || 0}px`, "--grid-layout-cols": a, "--grid-layout-row-height": `${o}px` }, children: [z, W && E.cloneElement(W, { cols: a, rowHeight: o, itemMargin: s, containerPadding: l, fields: N, basicForm: i })] }); }; - return A(ie, { ...F, form: L, fields: U, onValuesChange: D, children: [k ? h(Vi, { ...x, items: $, theme: k, itemRender: R, fields: u, children: T, basicForm: i }) : R(0, u, T), d == null ? void 0 : d.map((M) => { - var v; - return h(Ht, { name: M.code, children: h(dr, { form: L, basicForm: i, name: M.code, type: M.type, initialValue: M.initialValue, initialValueLanguage: (v = M.extras) == null ? void 0 : v.initialValueLanguage }) }, JSON.stringify(M.code)); + return A(ie, { ...F, form: L, fields: U, onValuesChange: D, children: [k ? h(Vi, { ...S, items: $, theme: k, itemRender: R, fields: u, children: T, basicForm: i }) : R(0, u, T), d == null ? void 0 : d.map((V) => { + var N; + return h(Jt, { name: V.code, children: h(ur, { form: L, basicForm: i, name: V.code, type: V.type, initialValue: V.initialValue, initialValueLanguage: (N = V.extras) == null ? void 0 : N.initialValueLanguage }) }, JSON.stringify(V.code)); })] }); -}, dr = ({ type: t, initialValue: e, initialValueLanguage: i, onChange: n, basicForm: r }) => { - const [a, o] = Ii(i == "javascript" && e, i == "javascript" ? void 0 : e, {}, {}, r); - return V(() => { +}, ur = ({ type: t, initialValue: e, initialValueLanguage: i, onChange: n, basicForm: r }) => { + const [a, o] = Mi(i == "javascript" && e, i == "javascript" ? void 0 : e, {}, {}, r); + return M(() => { i == "javascript" ? n(oe(a, t)) : e && n(oe(e, t)); }, [t, e, a]), null; }; -Qt.propTypes = { fields: b.array, hides: b.array }; -const ur = /* @__PURE__ */ ((t) => ({ code: e, isPreview: i = !1, ...n }) => { - const { align: r, autoComplete: a, resource: o, items: s, hides: l, rowHeight: u, marginX: d, marginY: p, cols: f, listenChangeFields: g, listenChangeFieldsFunc: y, pk: w, uuid: C, theme: k, themeProps: x, groups: $ } = nr(e), T = K(() => [{ name: "__PK__", value: w }, { name: "__RESOURCE__", value: o }, { name: "__LAYOUT_KEY__", value: e }, { name: "__LAYOUT_UUID__", value: C }], [w, e, C, o]); - return h(t, { name: e, autoComplete: a, theme: k, themeProps: x, groups: $, ...n, formFields: T, listenChangeFields: g, listenChangeFieldsFunc: y, fields: s, hides: l, cols: f, rowHeight: u, itemMargin: [d, p] }); -})(Qt), Wi = ({ $setting: t, $close: e, extras: i, code: n, primaryKey: r, ...a }) => { - const [o] = ie.useForm(), s = sr(o, n, r, t); - return h(G, { actions: A(E.Fragment, { children: [h(P, { name: (t == null ? void 0 : t.okText) || "保存", type: "primary", widget: () => s({ onSuccess: e }) }), h(P, { name: (t == null ? void 0 : t.cancelText) || "取消", widget: () => e(!1) })] }), extras: i, children: h(ur, { form: o, code: n, primaryKey: r, ...a }) }); -}, gi = /* @__PURE__ */ new Set(), qt = (t = [], e = 0) => { +Zt.propTypes = { fields: b.array, hides: b.array }; +const pr = /* @__PURE__ */ ((t) => ({ code: e, isPreview: i = !1, ...n }) => { + const { align: r, autoComplete: a, resource: o, items: s, hides: l, rowHeight: u, marginX: d, marginY: p, cols: f, listenChangeFields: g, listenChangeFieldsFunc: y, pk: w, uuid: C, theme: k, themeProps: S, groups: $ } = rr(e), T = K(() => [{ name: "__PK__", value: w }, { name: "__RESOURCE__", value: o }, { name: "__LAYOUT_KEY__", value: e }, { name: "__LAYOUT_UUID__", value: C }], [w, e, C, o]); + return h(t, { name: e, autoComplete: a, theme: k, themeProps: S, groups: $, ...n, formFields: T, listenChangeFields: g, listenChangeFieldsFunc: y, fields: s, hides: l, cols: f, rowHeight: u, itemMargin: [d, p] }); +})(Zt), Wi = ({ $setting: t, $close: e, extras: i, code: n, primaryKey: r, ...a }) => { + const [o] = ie.useForm(), s = lr(o, n, r, t); + return h(Y, { actions: A(E.Fragment, { children: [h(P, { name: (t == null ? void 0 : t.okText) || "保存", type: "primary", widget: () => s({ onSuccess: e }) }), h(P, { name: (t == null ? void 0 : t.cancelText) || "取消", widget: () => e(!1) })] }), extras: i, children: h(pr, { form: o, code: n, primaryKey: r, ...a }) }); +}, hi = /* @__PURE__ */ new Set(), Kt = (t = [], e = 0) => { const i = t[e]; - if (i.length && !gi.has(i)) { + if (i.length && !hi.has(i)) { const n = document.createElement("script"); n.setAttribute("src", i), n.setAttribute("data-namespace", i), t.length > e + 1 && (n.onload = () => { - qt(t, e + 1); + Kt(t, e + 1); }, n.onerror = () => { - qt(t, e + 1); - }), gi.add(i), document.body.appendChild(n); + Kt(t, e + 1); + }), hi.add(i), document.body.appendChild(n); } }, Ct = ({ className: t, type: e, style: i = {}, ...n }) => h("span", { role: "img", className: O("ff-iconfont", t), style: i, ...n, children: h("svg", { style: { width: "1em", height: "1em", fill: "currentColor", overflow: "hidden" }, viewBox: "0 0 1024 1024", children: h("use", { xlinkHref: `#${e}` }) }) }); -Ct.propTypes = { className: b.string, type: b.string.isRequired, style: b.object }, Ct.init = qt; -const pr = (t, e, i, n) => Ee.redirect(i, e, n), gr = (t, e = {}, i, n = {}) => { +Ct.propTypes = { className: b.string, type: b.string.isRequired, style: b.object }, Ct.init = Kt; +const gr = (t, e, i, n) => $e.redirect(i, e, n), hr = (t, e = {}, i, n = {}) => { var a; const r = (a = n.router) == null ? void 0 : a.reduce((o, [s, l, u]) => { const d = m.get(e, ["router", s]); if (!d && d !== 0 && l) throw `请传入 ${u}`; return `${o}/${d}`; }, `/api/${i}`); - return I.del(r, e.param).msg(); -}, hi = (t, e, i, { status: { loading: n, disabled: r }, setStatus: a }) => { + return j.del(r, e.param).msg(); +}, mi = (t, e, i, { status: { loading: n, disabled: r }, setStatus: a }) => { const o = { loading: (s) => s === void 0 ? n : a((l) => ({ ...l, loading: s })), disabled: (s) => s === void 0 ? r : a((l) => ({ ...l, disabled: s })) }; return m.isFunction(i) ? i.call(null, { ...e, ...o }) : m.isString(i) && i ? Fe.exec(i, e, o) : null; -}, mi = (t, e, i, n, r) => m.isString(i) && i ? se.getWidgetComponent(i).then(({ default: a }) => ee.modal(a, { ...e, $setting: n }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r)).catch((a) => { +}, fi = (t, e, i, n, r) => m.isString(i) && i ? se.getWidgetComponent(i).then(({ default: a }) => ee.modal(a, { ...e, $setting: n }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r)).catch((a) => { ee.error(i, { content: a.toString() }); -}) : ee.modal(i, { ...e, $setting: n }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), hr = (t, e, i, n, r) => ee.modal(Wi, { ...e, $setting: n, code: i }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), mr = (t, e, i, n, r) => ee.modal(Gt, { base62params: e, $setting: n, listCode: i }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), fr = ({ widget: t, widgetType: e, widgetData: i, widgetProps: n, widgetSetting: r, widgetContainerProps: a }, { onAfterClick: o, onBeforeClick: s } = {}) => { - const l = le(ne), [u, d] = j({ leading: !0, trailing: !1 }), p = K(() => { +}) : ee.modal(i, { ...e, $setting: n }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), mr = (t, e, i, n, r) => ee.modal(Wi, { ...e, $setting: n, code: i }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), fr = (t, e, i, n, r) => ee.modal(Xt, { base62params: e, $setting: n, listCode: i }, r != null && r.title ? { ...r, title: m.template(r.title)(t) } : r), yr = ({ widget: t, widgetType: e, widgetData: i, widgetProps: n, widgetSetting: r, widgetContainerProps: a }, { onAfterClick: o, onBeforeClick: s } = {}) => { + const l = le(ne), [u, d] = I({ leading: !0, trailing: !1 }), p = K(() => { switch (e) { case "redirect": - return m.partialRight(pr, t, r); + return m.partialRight(gr, t, r); case "func": - return m.partialRight(hi, (r == null ? void 0 : r.code) ?? t, { status: u, setStatus: d }); + return m.partialRight(mi, (r == null ? void 0 : r.code) ?? t, { status: u, setStatus: d }); case "component": case "fsdpf-component": - return m.partialRight(mi, t, r, a); + return m.partialRight(fi, t, r, a); case "grid-layout-form": - return m.partialRight(hr, t, r, a); - case "data-list": return m.partialRight(mr, t, r, a); + case "data-list": + return m.partialRight(fr, t, r, a); case "destroy": - return m.partialRight(gr, t, r, a); + return m.partialRight(hr, t, r, a); default: - if (ei(t) || E.isValidElement(t)) return m.partialRight(mi, t, r, a); - if (m.isFunction(t)) return m.partialRight(hi, (r == null ? void 0 : r.code) || t, { status: u, setStatus: d }); + if (ti(t) || E.isValidElement(t)) return m.partialRight(fi, t, r, a); + if (m.isFunction(t)) return m.partialRight(mi, (r == null ? void 0 : r.code) || t, { status: u, setStatus: d }); } return (...f) => console.error("useButton unknown widgetType", e, ...f); }, [t, e]); return [m.debounce((f) => (s == null || s(f), Promise.resolve(lt(n, f, { list: l })).then((g) => p(f, { ...i, ...g })).then((g) => o == null ? void 0 : o(g)).catch(console.error)), 300, { leading: !0, trailing: !1 }), u]; -}, Bi = ({ type: t, name: e, className: i, icon: n, iconPosition: r, size: a }, o = "default") => K(() => { +}, Ui = ({ type: t, name: e, className: i, icon: n, iconPosition: r, size: a }, o = "default") => K(() => { const s = { type: "primary", className: O("ff-button", i), iconPosition: r, size: a }; return t === "danger" ? s.danger = !0 : t === "default" && (s.type = t), o === "link" || o === "dashed" ? (s.type = o, t === "default" && (s.className = O(s.className, "ff-default"))) : o !== "circle" && o !== "round" || (s.shape = o), n && (s.icon = h(Ct, { type: n })), e && (s.children = e), s; }, [o, t, i, n, r]), Pt = ({ data: t, widget: e, widgetType: i = "fsdpf-component", widgetData: n, widgetProps: r, widgetSetting: a, widgetContainerProps: o, onAfterClick: s, onBeforeClick: l, children: u, extras: d }) => { - const p = le(ne), [f, g] = j(!1), [y, w] = j("hover"), [C, k] = j({}), [x, $] = j(), { placement: T, align: F, zIndex: L, arrow: D = { pointAtCenter: !0 }, getPopupContainer: U, isPopupMountBodyContainer: R = !0, ...M } = o || {}; - V(() => { - i == "grid-layout-form" ? $(E.createElement(Wi, { ...n, $setting: a, code: e })) : i == "data-list" ? $(E.createElement(Gt, { base62params: t, $setting: a, listCode: e })) : m.isString(e) ? se.getWidgetComponent(e).then(({ default: z }) => { + const p = le(ne), [f, g] = I(!1), [y, w] = I("hover"), [C, k] = I({}), [S, $] = I(), { placement: T, align: F, zIndex: L, arrow: D = { pointAtCenter: !0 }, getPopupContainer: U, isPopupMountBodyContainer: R = !0, ...V } = o || {}; + M(() => { + i == "grid-layout-form" ? $(E.createElement(Wi, { ...n, $setting: a, code: e })) : i == "data-list" ? $(E.createElement(Xt, { base62params: t, $setting: a, listCode: e })) : m.isString(e) ? se.getWidgetComponent(e).then(({ default: z }) => { $(E.createElement(z, { ...n, $setting: a })); - }).catch((z) => $(z.toString())) : ei(e) ? $(E.createElement(e, { ...n, $setting: a })) : E.isValidElement(e) && $(E.cloneElement(e, { ...n, $setting: a })); - }, [e, i, n]), V(() => { + }).catch((z) => $(z.toString())) : ti(e) ? $(E.createElement(e, { ...n, $setting: a })) : E.isValidElement(e) && $(E.cloneElement(e, { ...n, $setting: a })); + }, [e, i, n]), M(() => { Promise.resolve(lt(r, t, { list: p })).then(k); }, [r, t, p.getBase62params]); - const v = (z, $e = !1) => (g(z), !z && w("hover"), z ? l == null ? void 0 : l(C) : s == null ? void 0 : s($e)), B = (z) => { + const N = (z, Ee = !1) => (g(z), !z && w("hover"), z ? l == null ? void 0 : l(C) : s == null ? void 0 : s(Ee)), W = (z) => { g(!0), w("click"); }; - return h(fn, { zIndex: L, placement: T, onPopupClick: B, onClick: B, open: f, align: F, arrow: D, trigger: y, getPopupContainer: U || R ? void 0 : (z) => z, content: h(yr, { ...M, extras: d, children: x && E.cloneElement(x, { ...C, $close: (z) => v(!1, z) }) }), children: u, onOpenChange: v }); -}, yr = ({ title: t, className: e, classNames: i, children: n, extras: r, width: a, height: o, ...s }) => { - const [l, u] = j({}), d = X((y, w) => u((C) => ({ ...C, [y]: w })), []), p = X((y) => u((w) => ({ ...w, [y]: void 0 })), []), f = t ? E.createElement("div", { className: "ff-popup-title" }, t) : l == null ? void 0 : l.title, g = r ?? E.createElement("div", { className: "ff-popup-reserved-extras" }, r); + return h(fn, { zIndex: L, placement: T, onPopupClick: W, onClick: W, open: f, align: F, arrow: D, trigger: y, getPopupContainer: U || R ? void 0 : (z) => z, content: h(wr, { ...V, extras: d, children: S && E.cloneElement(S, { ...C, $close: (z) => N(!1, z) }) }), children: u, onOpenChange: N }); +}, wr = ({ title: t, className: e, classNames: i, children: n, extras: r, width: a, height: o, ...s }) => { + const [l, u] = I({}), d = X((y, w) => u((C) => ({ ...C, [y]: w })), []), p = X((y) => u((w) => ({ ...w, [y]: void 0 })), []), f = t ? E.createElement("div", { className: "ff-popup-title" }, t) : l == null ? void 0 : l.title, g = r ?? E.createElement("div", { className: "ff-popup-reserved-extras" }, r); return h(st.Provider, { value: { ele: l, mount: d, unmount: p }, children: A("div", { className: O("ff-popup ff-popover", e, l.rootClassName), style: { width: a ?? 260, height: o }, ...s, children: [A("div", { className: O("ff-popup-header", "ff-popover-header", i == null ? void 0 : i.header), children: [f, l == null ? void 0 : l["sub-title"]] }), h("div", { className: O("ff-popup-body", "ff-popover-body", i == null ? void 0 : i.body), children: n }), A("div", { className: O("ff-popup-footer", "ff-popover-footer", i == null ? void 0 : i.footer), children: [g, l == null ? void 0 : l.extras, l == null ? void 0 : l.actions] })] }) }); }; Pt.propTypes = { widgetType: b.oneOf(["fsdpf-component", "grid-layout-form", "data-list"]) }; const ut = (t) => function({ className: e, variant: i, children: n, name: r, icon: a, type: o = "default", iconPosition: s = "start", noAuthType: l, onAfterClick: u, onBeforeClick: d, data: p, loading: f, disabled: g, tooltip: y, confirm: w, widget: C = () => { -}, widgetType: k, widgetData: x, widgetProps: $, widgetSetting: T, widgetContainerProps: F, ...L }) { - const { mode: D, ...U } = F || {}, R = Bi({ className: e, name: r, type: o, icon: a, iconPosition: s }, i ?? t), M = h(wt, { ...R, ...L, children: n || r }); - if (D === "popover" && !["destroy", "redirect", "func"].includes(k)) return h(Pt, { data: p, widget: C, widgetType: k, widgetData: x, widgetProps: $, widgetSetting: T, widgetContainerProps: U, onAfterClick: u, onBeforeClick: d, children: M }); - const v = m.isEmpty(y) || !y.enabled ? {} : y, B = m.isEmpty(w) ? { enabled: !1 } : Object.assign({ enabled: !0 }, w), [z, $e] = j(!1), [pt, { disabled: gt, loading: Tt }] = fr({ widget: C, widgetType: k, widgetData: x, widgetProps: $, widgetSetting: T, widgetContainerProps: U }, { onAfterClick: u, onBeforeClick: d }); - return h(yn, { okText: "确定", cancelText: "取消", getPopupContainer: (te) => te, ...B, disabled: gt || g, open: z, onOpenChange: (te) => { - if (!te) return $e(te); - B.enabled ? $e(te) : pt(p); +}, widgetType: k, widgetData: S, widgetProps: $, widgetSetting: T, widgetContainerProps: F, ...L }) { + const { mode: D, ...U } = F || {}, R = Ui({ className: e, name: r, type: o, icon: a, iconPosition: s }, i ?? t), V = h(wt, { ...R, ...L, children: n || r }); + if (D === "popover" && !["destroy", "redirect", "func"].includes(k)) return h(Pt, { data: p, widget: C, widgetType: k, widgetData: S, widgetProps: $, widgetSetting: T, widgetContainerProps: U, onAfterClick: u, onBeforeClick: d, children: V }); + const N = m.isEmpty(y) || !y.enabled ? {} : y, W = m.isEmpty(w) ? { enabled: !1 } : Object.assign({ enabled: !0 }, w), [z, Ee] = I(!1), [pt, { disabled: gt, loading: Tt }] = yr({ widget: C, widgetType: k, widgetData: S, widgetProps: $, widgetSetting: T, widgetContainerProps: U }, { onAfterClick: u, onBeforeClick: d }); + return h(yn, { okText: "确定", cancelText: "取消", getPopupContainer: (te) => te, ...W, disabled: gt || g, open: z, onOpenChange: (te) => { + if (!te) return Ee(te); + W.enabled ? Ee(te) : pt(p); }, onConfirm: (te) => { pt(p, te); }, onClick: (te) => { te.stopPropagation(); - }, children: h(wn, { getPopupContainer: (te) => te, ...v, title: z ? null : v == null ? void 0 : v.title, trigger: ["hover", "click"], children: E.cloneElement(M, { loading: Tt || f, disabled: gt || g }) }) }); + }, children: h(wn, { getPopupContainer: (te) => te, ...N, title: z ? null : N == null ? void 0 : N.title, trigger: ["hover", "click"], children: E.cloneElement(V, { loading: Tt || f, disabled: gt || g }) }) }); }, P = ut("default"); P.propTypes = { type: b.oneOf(["primary", "default", "danger", ""]), size: b.oneOf(["large", "middle", "small"]), name: b.string, icon: b.string, iconPosition: b.oneOf(["start", "end"]), data: b.any, widget: b.any, widgetType: b.oneOf(["destroy", "redirect", "func", "component", "fsdpf-component", "grid-layout-form", "grid-layout", "data-list"]), widgetData: b.object, widgetProps: b.object, widgetSetting: b.object, widgetContainerProps: b.object, tooltip: b.exact({ title: b.string.isRequired, placement: b.oneOf(["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight", "leftTop", "leftBottom", "rightTop", "rightBottom"]), enabled: b.oneOfType([b.bool, b.number]), getPopupContainer: b.func }), confirm: b.exact({ title: b.string.isRequired, cancelText: b.string, okText: b.string, okType: b.oneOf(["primary", "default", "danger", ""]), placement: b.oneOf(["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight", "leftTop", "leftBottom", "rightTop", "rightBottom"]), enabled: b.oneOfType([b.bool, b.number]), getPopupContainer: b.func, arrow: b.oneOfType([b.bool, b.exact({ pointAtCenter: b.bool })]) }) }; -const wr = ut("link"), br = ut("circle"), Cr = ut("round"), kr = ut("dashed"), fi = ({ options: t = [], triggerWeights: e = ["grid-layout-form", "grid-layout", "fsdpf-component", "print"], onAfterClick: i = (g, y, w) => { +const br = ut("link"), Cr = ut("circle"), kr = ut("round"), $r = ut("dashed"), yi = ({ options: t = [], triggerWeights: e = ["grid-layout-form", "grid-layout", "fsdpf-component", "print"], onAfterClick: i = (g, y, w) => { }, onBeforeClick: n = (g, y, w) => { -}, labelVariant: r = "link", labelSize: a, labelRender: o, btnVariant: s, btnSize: l, btnRender: u = (g, y) => h(P, { ...g, data: y }, g.uuid || jt()), widgetContainerProps: d = {}, children: p, data: f }) => { +}, labelVariant: r = "link", labelSize: a, labelRender: o, btnVariant: s, btnSize: l, btnRender: u = (g, y) => h(P, { ...g, data: y }, g.uuid || It()), widgetContainerProps: d = {}, children: p, data: f }) => { if (m.isEmpty(t)) return p; const [g, y] = K(() => (t || []).reduce((C, k) => { - const x = e.indexOf(k.widgetType); - return x === -1 ? C[1].push(k) : C[0] ? x < e.indexOf(C[0].widgetType) ? (C[1].push(C[0]), C[0] = k) : C[1].push(k) : C[0] = k, C; + const S = e.indexOf(k.widgetType); + return S === -1 ? C[1].push(k) : C[0] ? S < e.indexOf(C[0].widgetType) ? (C[1].push(C[0]), C[0] = k) : C[1].push(k) : C[0] = k, C; }, [null, []]), [t, e]); - o ? p = o(g, f) || p : p || (p = h(wt, { ...Bi(Object.assign(g != null && g.name || g != null && g.icon ? {} : { icon: "icon-location" }, g, { size: a }), r) })); + o ? p = o(g, f) || p : p || (p = h(wt, { ...Ui(Object.assign(g != null && g.name || g != null && g.icon ? {} : { icon: "icon-location" }, g, { size: a }), r) })); const w = y.map((C) => u(Object.assign({ uuid: C.uuid, type: C.type, name: C.name, widget: C.widget, widgetType: C.widgetType, widgetProps: C.widgetProps, widgetData: C.widgetData, widgetSetting: C.widgetSetting, widgetContainerProps: C.widgetContainerSetting, confirm: C.confirm, onAfterClick: m.partialRight(i, C, f), onBeforeClick: m.partialRight(n, C, f) }, { size: l, variant: s }), f)); return h(Pt, { widget: g == null ? void 0 : g.widget, widgetType: g == null ? void 0 : g.widgetType, widgetProps: g == null ? void 0 : g.widgetProps, widgetSetting: g == null ? void 0 : g.widgetSetting, widgetContainerProps: Object.assign({}, d, g == null ? void 0 : g.widgetContainerProps), data: f, widgetData: g == null ? void 0 : g.widgetData, extras: w, onAfterClick: m.partialRight(i, g, f), onBeforeClick: m.partialRight(n, g, f), children: p }); }; -fi.propTypes = { triggerWeights: b.array, options: b.arrayOf(b.shape({ ...P.propTypes, widgetType: P.propTypes.widgetType.isRequired })), btnSize: P.propTypes.size, btnRender: b.func, btnVariant: b.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelVariant: b.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelRender: b.func, labelSize: P.propTypes.size, onAfterClick: b.func, onBeforeClick: b.func, widgetContainerProps: P.propTypes.widgetContainerProps, data: P.propTypes.data }, P.Link = wr, P.Link.defaultProps = P.defaultProps, P.Link.propTypes = P.propTypes, P.Circle = br, P.Circle.defaultProps = P.defaultProps, P.Circle.propTypes = P.propTypes, P.Round = Cr, P.Round.defaultProps = P.defaultProps, P.Round.propTypes = P.propTypes, P.Dashed = kr, P.Dashed.defaultProps = P.defaultProps, P.Dashed.propTypes = P.propTypes, P.Popover = Pt, P.GroupPopover = fi; +yi.propTypes = { triggerWeights: b.array, options: b.arrayOf(b.shape({ ...P.propTypes, widgetType: P.propTypes.widgetType.isRequired })), btnSize: P.propTypes.size, btnRender: b.func, btnVariant: b.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelVariant: b.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelRender: b.func, labelSize: P.propTypes.size, onAfterClick: b.func, onBeforeClick: b.func, widgetContainerProps: P.propTypes.widgetContainerProps, data: P.propTypes.data }, P.Link = br, P.Link.defaultProps = P.defaultProps, P.Link.propTypes = P.propTypes, P.Circle = Cr, P.Circle.defaultProps = P.defaultProps, P.Circle.propTypes = P.propTypes, P.Round = kr, P.Round.defaultProps = P.defaultProps, P.Round.propTypes = P.propTypes, P.Dashed = $r, P.Dashed.defaultProps = P.defaultProps, P.Dashed.propTypes = P.propTypes, P.Popover = Pt, P.GroupPopover = yi; const Er = ({ fields: t, formProps: e, $close: i }) => { const [n] = ie.useForm(), r = K(() => [{ name: "__PROPS__", value: e }], [e]); - return h(G, { actions: A(E.Fragment, { children: [h(P, { name: "取消", widget: () => i(!1) }), h(P, { name: "确定", type: "primary", widget: () => n.validateFields(!0).then(i) })] }), children: h(ie, { fields: r, form: n, className: "ff-modal-form", children: t == null ? void 0 : t.map(({ code: a, ...o }) => h(Xt, { code: a, ...o }, a)) }) }); -}, $r = ({ className: t, classNames: e, $close: i, children: n, title: r, subTitle: a, actions: o, extras: s, ...l }) => A(Sn, { ...l, prefixCls: "ff-drawer", className: O("ff-popup", t), maskMotion: { motionAppear: !0, motionName: "mask-motion" }, motion: (u) => ({ motionAppear: !0, motionName: `panel-motion-${u}` }), children: [A("div", { className: O("ff-popup-header", "ff-drawer-header", e == null ? void 0 : e.header), children: [h("button", { "aria-label": "Close", className: O("ff-popup-close", "ff-drawer-close", e == null ? void 0 : e.close), onClick: l.onClose, children: h(Jt, { type: "close" }) }), r, a] }), h("div", { className: O("ff-popup-body", "ff-drawer-body", e == null ? void 0 : e.body), children: n }), A("div", { className: O("ff-popup-footer", "ff-drawer-footer", e == null ? void 0 : e.footer), children: [s, o] })] }), xr = ({ className: t, classNames: e, $close: i, $event: n, children: r, title: a, subTitle: o, actions: s, extras: l, placement: u, ...d }) => { + return h(Y, { actions: A(E.Fragment, { children: [h(P, { name: "取消", widget: () => i(!1) }), h(P, { name: "确定", type: "primary", widget: () => n.validateFields(!0).then(i) })] }), children: h(ie, { fields: r, form: n, className: "ff-modal-form", children: t == null ? void 0 : t.map(({ code: a, ...o }) => h(Qt, { code: a, ...o }, a)) }) }); +}, Sr = ({ className: t, classNames: e, $close: i, children: n, title: r, subTitle: a, actions: o, extras: s, ...l }) => A(vn, { ...l, prefixCls: "ff-drawer", className: O("ff-popup", t), maskMotion: { motionAppear: !0, motionName: "mask-motion" }, motion: (u) => ({ motionAppear: !0, motionName: `panel-motion-${u}` }), children: [A("div", { className: O("ff-popup-header", "ff-drawer-header", e == null ? void 0 : e.header), children: [h("button", { "aria-label": "Close", className: O("ff-popup-close", "ff-drawer-close", e == null ? void 0 : e.close), onClick: l.onClose, children: h(Gt, { type: "close" }) }), r, a] }), h("div", { className: O("ff-popup-body", "ff-drawer-body", e == null ? void 0 : e.body), children: n }), A("div", { className: O("ff-popup-footer", "ff-drawer-footer", e == null ? void 0 : e.footer), children: [s, o] })] }), vr = ({ className: t, classNames: e, $close: i, $event: n, children: r, title: a, subTitle: o, actions: s, extras: l, placement: u, ...d }) => { const p = (n == null ? void 0 : n.pageX) === void 0 ? { animation: null, maskAnimation: null, mousePosition: { x: null, y: null } } : { animation: "zoom", maskAnimation: "fade", mousePosition: { x: n == null ? void 0 : n.pageX, y: n == null ? void 0 : n.pageY } }; - return h(vn, { ...d, ...p, prefixCls: "ff-modal", modalRender: () => A("div", { className: O("ff-modal-content ff-popup", t), children: [A("div", { className: O("ff-popup-header", "ff-modal-header", e == null ? void 0 : e.header), children: [h("button", { "aria-label": "Close", className: O("ff-popup-close", "ff-modal-close", e == null ? void 0 : e.close), onClick: d.onClose, children: h(Jt, { type: "close" }) }), a, o] }), h("div", { className: O("ff-popup-body", "ff-modal-body", e == null ? void 0 : e.body), children: r }), A("div", { className: O("ff-popup-footer", "ff-modal-footer", e == null ? void 0 : e.footer), children: [l, s] })] }) }); -}, Ui = ({ placement: t, $close: e, $event: i, children: n, title: r, ...a }) => { - const [o, s] = j({}), [l, u] = j(!0), d = X((y, w) => s((C) => ({ ...C, [y]: w })), []), p = X((y) => s((w) => ({ ...w, [y]: void 0 })), []); + return h(Nn, { ...d, ...p, prefixCls: "ff-modal", modalRender: () => A("div", { className: O("ff-modal-content ff-popup", t), children: [A("div", { className: O("ff-popup-header", "ff-modal-header", e == null ? void 0 : e.header), children: [h("button", { "aria-label": "Close", className: O("ff-popup-close", "ff-modal-close", e == null ? void 0 : e.close), onClick: d.onClose, children: h(Gt, { type: "close" }) }), a, o] }), h("div", { className: O("ff-popup-body", "ff-modal-body", e == null ? void 0 : e.body), children: r }), A("div", { className: O("ff-popup-footer", "ff-modal-footer", e == null ? void 0 : e.footer), children: [l, s] })] }) }); +}, qi = ({ placement: t, $close: e, $event: i, children: n, title: r, ...a }) => { + const [o, s] = I({}), [l, u] = I(!0), d = X((y, w) => s((C) => ({ ...C, [y]: w })), []), p = X((y) => s((w) => ({ ...w, [y]: void 0 })), []); let f = { ...a, className: o.rootClassName, title: o.title || r && E.createElement("div", { className: O("ff-popup-title") }, r), subTitle: o["sub-title"], actions: o.actions, extras: o.extras, children: n, $close: e, $event: i, onClose: () => u(!1) }; const g = () => { e(!1); }; - return h(st.Provider, { value: { ele: o, mount: d, unmount: p }, children: t && t !== "center" ? h($r, { ...f, placement: t, open: l, afterOpenChange: (y) => !y && g() }) : h(xr, { ...f, visible: l, afterClose: g }) }); + return h(st.Provider, { value: { ele: o, mount: d, unmount: p }, children: t && t !== "center" ? h(Sr, { ...f, placement: t, open: l, afterOpenChange: (y) => !y && g() }) : h(vr, { ...f, visible: l, afterClose: g }) }); }; -Ui.propTypes = { placement: b.oneOf(["center", "left", "top", "right", "bottom"]) }; +qi.propTypes = { placement: b.oneOf(["center", "left", "top", "right", "bottom"]) }; const Z = () => { - const [t, e] = on({ maxCount: 6, motion: { motionName: "ff-notification-fade", motionAppear: !0, motionEnter: !0, motionLeave: !0, onLeaveStart: (a) => { + const [t, e] = sn({ maxCount: 6, motion: { motionName: "ff-notification-fade", motionAppear: !0, motionEnter: !0, motionLeave: !0, onLeaveStart: (a) => { const { offsetHeight: o } = a; return { height: o }; }, onLeaveActive: () => ({ height: 0, opacity: 0, margin: 0 }) }, prefixCls: "ff-notification" }), [, i] = E.useReducer((a) => a + 1, 0); - V(() => { + M(() => { Z.$onClick = n, Z.$queue.forEach(([a, o, s], l, u) => { r([o, s], ...a), delete u[l]; }); }, []); const n = (a, o = {}, s = {}) => new Promise((l, u) => r([l, u], a, o, s)), r = ([a, o], s, l = {}, u = {}) => { const d = Z.$index++, p = (f) => ((g, y) => (Z.$popups.delete(g), i(), y == null ? void 0 : y()))(d, () => a(f)); - if (s === xi) return t.open({ ...u, key: d, content: E.createElement(s, { ...l, $close: () => t.close(d) }) }); - Z.$popups.set(d, E.createElement(Ui, { maskClosable: !1, $event: l == null ? void 0 : l.$event, ...u, key: d, $close: p }, E.isValidElement(s) ? E.cloneElement(s, { ...l, $close: p }) : s != null && s.name || oi.isForwardRef(s) || (s == null ? void 0 : s.$$typeof) === oi.ForwardRef ? E.createElement(s, { ...l, $close: p }) : s)), i(); + if (s === vi) return t.open({ ...u, key: d, content: E.createElement(s, { ...l, $close: () => t.close(d) }) }); + Z.$popups.set(d, E.createElement(qi, { maskClosable: !1, $event: l == null ? void 0 : l.$event, ...u, key: d, $close: p }, E.isValidElement(s) ? E.cloneElement(s, { ...l, $close: p }) : s != null && s.name || si.isForwardRef(s) || (s == null ? void 0 : s.$$typeof) === si.ForwardRef ? E.createElement(s, { ...l, $close: p }) : s)), i(); }; return A(E.Fragment, { children: [Array.from(Z.$popups).map(([a, o]) => o), e] }); }; Z.$popups = /* @__PURE__ */ new Map(), Z.$index = 0, Z.$queue = [], Z.$onClick = (...t) => new Promise((e, i) => { Z.$queue.push([t, e, i]); }); -const yi = (t, e, i = {}) => Z.$onClick(t, e, i), At = (t, { showProgress: e, duration: i, ...n } = { duration: 1.5 }) => Z.$onClick(xi, { content: t, ...n }, { showProgress: e, duration: i }), ee = { modal: yi, confirm: (t, e = {}) => Z.$onClick(Nn, { content: t, ...e }, { placement: "center" }), form: (t, e = {}, i = {}) => yi(Er, { formProps: i, fields: t }, { placement: "center", ...e }).then((n) => { +const wi = (t, e, i = {}) => Z.$onClick(t, e, i), At = (t, { showProgress: e, duration: i, ...n } = { duration: 1.5 }) => Z.$onClick(vi, { content: t, ...n }, { showProgress: e, duration: i }), ee = { modal: wi, confirm: (t, e = {}) => Z.$onClick(xn, { content: t, ...e }, { placement: "center" }), form: (t, e = {}, i = {}) => wi(Er, { formProps: i, fields: t }, { placement: "center", ...e }).then((n) => { if (n === !1) throw !1; return n; }), notification: At, success: (t, e = { duration: 1.5 }) => At(t, { ...e, className: "ff-notification-success", icon: "check" }), error: (t, e = { duration: 1.5 }) => At(t, { ...e, className: "ff-notification-error", icon: "close" }) }; @@ -984,13 +984,13 @@ Je.configure({ showSpinner: !1 }), Ae.interceptors.request.use((t) => { return t.headers.Authorization = e ? `Bearer ${e} ` : void 0, Je.inc(), t; }, (t) => (Je.done(), Promise.reject({ code: -1, msg: t }))), Ae.interceptors.response.use(({ data: t, headers: e }) => (Je.done(), { ...t, res: e == null ? void 0 : e.res }), function(t) { return Je.done(), Promise.reject(t.message); -}), window.addEventListener("unhandledrejection", It.onUnhandledRejection), It.onMsg = (t, e) => ee[[0, 1].includes(t) ? "success" : "error"](e).then(() => t === 20300 && Ee.redirect(Me.get("Common.WEBSITE_LOGIN_PAGE"))); -var qe, Ve, Ke; +}), window.addEventListener("unhandledrejection", jt.onUnhandledRejection), jt.onMsg = (t, e) => ee[[0, 1].includes(t) ? "success" : "error"](e).then(() => t === 20300 && $e.redirect(Ve.get("Common.WEBSITE_LOGIN_PAGE"))); +var qe, Me, Ke; const J = class J { constructor() { - N(this, "appUrl", ""); - S(this, qe, null); - return c(J, Ve) || (W(J, Ke, new It()), W(J, Ve, new Proxy(this, { get: (e, i) => i in e ? typeof e[i] == "function" ? e[i].bind(e) : e[i] : c(J, Ke)[i] }))), c(J, Ve); + x(this, "appUrl", ""); + v(this, qe, null); + return c(J, Me) || (B(J, Ke, new jt()), B(J, Me, new Proxy(this, { get: (e, i) => i in e ? typeof e[i] == "function" ? e[i].bind(e) : e[i] : c(J, Ke)[i] }))), c(J, Me); } init(e, i, n) { Ae.defaults.baseURL = this.appUrl = n, Ae.defaults.timeout = 15e3, c(J, Ke).init(e, i, Ae); @@ -999,32 +999,32 @@ const J = class J { return Ae; } mock(e = {}) { - return c(this, qe) ?? W(this, qe, new sn(Ae, { onNoMatch: "passthrough", ...e })); + return c(this, qe) ?? B(this, qe, new ln(Ae, { onNoMatch: "passthrough", ...e })); } unmock() { var e; - (e = c(this, qe)) == null || e.restore(), W(this, qe, null); + (e = c(this, qe)) == null || e.restore(), B(this, qe, null); } }; -qe = new WeakMap(), Ve = new WeakMap(), Ke = new WeakMap(), S(J, Ve), S(J, Ke), N(J, "getInstance", () => c(J, Ve) ?? W(J, Ve, new J())); -let Kt = J; -const I = Kt.getInstance(); -class Zt extends Error { +qe = new WeakMap(), Me = new WeakMap(), Ke = new WeakMap(), v(J, Me), v(J, Ke), x(J, "getInstance", () => c(J, Me) ?? B(J, Me, new J())); +let Ht = J; +const j = Ht.getInstance(); +class ei extends Error { constructor(e, i) { - super(i), Error.captureStackTrace && Error.captureStackTrace(this, Zt), !i instanceof Ye && (this.name = `${e} Error Runtime`); + super(i), Error.captureStackTrace && Error.captureStackTrace(this, ei), !i instanceof Ge && (this.name = `${e} Error Runtime`); } } -class Ye extends Error { +class Ge extends Error { constructor(e, ...i) { - super(...i), Error.captureStackTrace && Error.captureStackTrace(this, Ye), this.name = `${e} Not Found`; + super(...i), Error.captureStackTrace && Error.captureStackTrace(this, Ge), this.name = `${e} Not Found`; } } const Lt = "mine", yt = "token"; -var Re, _e; +var Re, He; const he = class he { constructor() { - S(this, _e, /* @__PURE__ */ new Map()); - N(this, "setVendor", (e, i) => c(this, _e).set(e, new Ei(i, async (n, r) => { + v(this, He, /* @__PURE__ */ new Map()); + x(this, "setVendor", (e, i) => c(this, He).set(e, new Ei(i, async (n, r) => { var o, s; if (!(n != null && n.default)) throw "@pkg not found"; let a = () => r; @@ -1033,25 +1033,25 @@ const he = class he { case typeof (a = (s = n.default) == null ? void 0 : s[`./${r}/index.js`]): return a(); } - throw new Ye(r); + throw new Ge(r); }))); - N(this, "getWidgetComponent", async (e) => { + x(this, "getWidgetComponent", async (e) => { if (!e) throw "getWidgetComponent widget is required"; if (e != null && e.startsWith("blob:") || e != null && e.startsWith("http:") || e != null && e.startsWith("https:")) return await import(e); const [, i] = e == null ? void 0 : e.split("@pkg/"); - if (!i) throw new Ye(e); + if (!i) throw new Ge(e); try { - return c(this, _e).has("pkg") ? await c(this, _e).get("pkg").get(i) : await import(`${I.appUrl}/api/pkg-import/web?name=${e}`); + return c(this, He).has("pkg") ? await c(this, He).get("pkg").get(i) : await import(`${j.appUrl}/api/pkg-import/web?name=${e}`); } catch (n) { - throw new Zt(e, n); + throw new ei(e, n); } }); - N(this, "getRoutes", () => I.get("/api/my-router").then((e) => [...e, { uuid: "data-list-setting", isLayout: !0, uri: "/data-list-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/DataListSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "grid-layout-setting", isLayout: !0, uri: "/grid-layout-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/GridLayoutSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "grid-layout-form-setting", isLayout: !0, uri: "/grid-layout-form-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/GridLayoutFormSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "resource-api-setting", isLayout: !0, uri: "/resource-api-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ResourceApiSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "charts-setting", isLayout: !0, uri: "/resource-api-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ChartsSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "fsm-setting", isLayout: !0, uri: "/fsm-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/FsmSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "component-setting", isLayout: !0, uri: "/component-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ComponentSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "login", uri: "/login", name: "登录", type: "fsdpf-component", isLogin: !1, component: "@pkg/ff/components/Login" }, { uuid: "not-found", uri: "*", name: "Not Found", type: "fsdpf-component", isLogin: !1, component: "@pkg/ff/components/NotFound" }].map(({ uuid: i, ...n }) => [i, { uuid: i, ...n }])).then((e) => new Map(e))); - N(this, "getMenus", () => I.get("/api/my-menu")); - N(this, "getConfigure", () => I.get("api/init-configure")); - N(this, "getWidgetOperationAuth", () => I.get("/api/init-widget-operation-auth").then((e) => e.reduce((i, { uuid: n, auth: r }) => [...i, [n, r]], []))); - N(this, "getPhoneNumber", (e) => I.get(`/api/user-wx-phone-number/${e}`)); - N(this, "getUserToken", () => { + x(this, "getRoutes", () => j.get("/api/my-router").then((e) => [...e, { uuid: "data-list-setting", isLayout: !0, uri: "/data-list-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/DataListSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "grid-layout-setting", isLayout: !0, uri: "/grid-layout-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/GridLayoutSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "grid-layout-form-setting", isLayout: !0, uri: "/grid-layout-form-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/GridLayoutFormSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "resource-api-setting", isLayout: !0, uri: "/resource-api-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ResourceApiSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "charts-setting", isLayout: !0, uri: "/resource-api-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ChartsSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "fsm-setting", isLayout: !0, uri: "/fsm-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/FsmSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "component-setting", isLayout: !0, uri: "/component-setting/:category/:categoryUuid", type: "fsdpf-component", component: "@pkg/ff-design/components/ComponentSetting", extra: { layout: "@pkg/ff-design/frameworks/DesignTheme" } }, { uuid: "login", uri: "/login", name: "登录", type: "fsdpf-component", isLogin: !1, component: "@pkg/ff/components/Login" }, { uuid: "not-found", uri: "*", name: "Not Found", type: "fsdpf-component", isLogin: !1, component: "@pkg/ff/components/NotFound" }].map(({ uuid: i, ...n }) => [i, { uuid: i, ...n }])).then((e) => new Map(e))); + x(this, "getMenus", () => j.get("/api/my-menu")); + x(this, "getConfigure", () => j.get("api/init-configure")); + x(this, "getWidgetOperationAuth", () => j.get("/api/init-widget-operation-auth").then((e) => e.reduce((i, { uuid: n, auth: r }) => [...i, [n, r]], []))); + x(this, "getPhoneNumber", (e) => j.get(`/api/user-wx-phone-number/${e}`)); + x(this, "getUserToken", () => { const e = window.localStorage.getItem(yt); if (!e) return ""; const i = e.split("."); @@ -1060,80 +1060,80 @@ const he = class he { if (Math.floor((/* @__PURE__ */ new Date()).getTime() / 1e3) - n > 2592e3) throw "登录令牌已过期, 请重新登录!"; return e; }); - N(this, "checkUserToken", () => { + x(this, "checkUserToken", () => { try { return !!this.getUserToken(); } catch { return !1; } }); - N(this, "getUserInfo", (e = !0) => { + x(this, "getUserInfo", (e = !0) => { var i; try { const n = this.getUserToken(); if (!n) return Promise.resolve(null); - const { iat: r } = JSON.parse(window.atob((i = n == null ? void 0 : n.split(".")) == null ? void 0 : i[1])), { iat: a, ...o } = I.decode(window.localStorage.getItem(Lt) || "", {}); - return a === r ? Promise.resolve(o) : I.get("/api/mine-info").then(({ User: s = null }) => (window.localStorage.setItem(Lt, I.encode({ ...s, iat: r })), s)); + const { iat: r } = JSON.parse(window.atob((i = n == null ? void 0 : n.split(".")) == null ? void 0 : i[1])), { iat: a, ...o } = j.decode(window.localStorage.getItem(Lt) || "", {}); + return a === r ? Promise.resolve(o) : j.get("/api/mine-info").then(({ User: s = null }) => (window.localStorage.setItem(Lt, j.encode({ ...s, iat: r })), s)); } catch (n) { console.error(n), e && ee.error("请登录").then(this.logout); } return Promise.resolve(null); }); - N(this, "login", (e, i, n = {}) => I.post("/api/user-token", { username: e, passwd: ln.hash(i), platform: "web", ...n }).then(({ token: r }) => (window.localStorage.setItem(yt, r), r)).then(async (r) => (await this.initAppEnv(), r))); - N(this, "logout", (e) => (window.localStorage.removeItem(Lt), window.localStorage.removeItem(yt), e == null ? void 0 : e())); - N(this, "initAppEnv", async () => { + x(this, "login", (e, i, n = {}) => j.post("/api/user-token", { username: e, passwd: cn.hash(i), platform: "web", ...n }).then(({ token: r }) => (window.localStorage.setItem(yt, r), r)).then(async (r) => (await this.initAppEnv(), r))); + x(this, "logout", (e) => (window.localStorage.removeItem(Lt), window.localStorage.removeItem(yt), e == null ? void 0 : e())); + x(this, "initAppEnv", async () => { const [e, i, n, r] = await Promise.all([this.getWidgetOperationAuth(), this.getRoutes(), this.getMenus(), this.getConfigure()]); - return Si.init(e), Me.init(r), Ee.init(i, n), Ct.init(Me.get("Common.ICONFONT")), { widgetOperationAuth: e, routes: i, menus: n, configures: r }; + return Ni.init(e), Ve.init(r), $e.init(i, n), Ct.init(Ve.get("Common.ICONFONT")), { widgetOperationAuth: e, routes: i, menus: n, configures: r }; }); if (c(he, Re)) return c(he, Re); } }; -Re = new WeakMap(), _e = new WeakMap(), S(he, Re, null), N(he, "getInstance", () => (c(he, Re) || W(he, Re, new he()), c(he, Re))); +Re = new WeakMap(), He = new WeakMap(), v(he, Re, null), x(he, "getInstance", () => (c(he, Re) || B(he, Re, new he()), c(he, Re))); let _t = he; -const se = _t.getInstance(), Sr = E.createContext({ user: {}, initUser: () => { -}, initUserComplete: !1 }), vr = E.createContext({ set: () => { +const se = _t.getInstance(), Nr = E.createContext({ user: {}, initUser: () => { +}, initUserComplete: !1 }), xr = E.createContext({ set: () => { }, get: () => { }, assign: () => { }, currentRoute: () => { -} }), ei = (t) => !!(t != null && t.name) && (t.prototype instanceof E.Component || /^[A-Z]/.test(t.name)), Nr = (t, e) => { +} }), ti = (t) => !!(t != null && t.name) && (t.prototype instanceof E.Component || /^[A-Z]/.test(t.name)), Pr = (t, e) => { if (!t || typeof window > "u") return; let i = document.querySelector(`style[ff-style-token="${e}"]`); return i ? (i.innerHTML = t, t) : (i = document.createElement("style"), i.setAttribute("ff-style-token", e), i.setAttribute("type", "text/css"), i.innerHTML = t, document.head.appendChild(i), t); -}, Pr = Object.freeze(Object.defineProperty({ __proto__: null, AppContext: Sr, AppGlobalParamsContext: vr, cache: Ei, configure: Me, default: se, func: Fe, http: I, insertStyle: Nr, isReactComponent: ei, route: Ee }, Symbol.toStringTag, { value: "Module" })); -var Ce, He, ke, me, fe, Q, Y, H, ye, it, nt, rt, at, vt, ot; -const ti = class ti { +}, Tr = Object.freeze(Object.defineProperty({ __proto__: null, AppContext: Nr, AppGlobalParamsContext: xr, cache: Ei, configure: Ve, default: se, func: Fe, http: j, insertStyle: Pr, isReactComponent: ti, route: $e }, Symbol.toStringTag, { value: "Module" })); +var Ce, _e, ke, me, fe, Q, G, _, ye, it, nt, rt, at, Nt, ot; +const ii = class ii { constructor(e, i = "/") { - S(this, Ce, "/"); - S(this, He, /* @__PURE__ */ new Set()); - S(this, ke, (e) => { - for (const i of c(this, He)) try { + v(this, Ce, "/"); + v(this, _e, /* @__PURE__ */ new Set()); + v(this, ke, (e) => { + for (const i of c(this, _e)) try { i(e); } catch (n) { console.error("Error in VirtualFS event listener:", n); } }); - S(this, me, (e) => { + v(this, me, (e) => { const i = Date.now(); if (e && (e.lastModified = i), c(this, Ce) != "/") { - const n = c(this, H).call(this, c(this, Ce)); + const n = c(this, _).call(this, c(this, Ce)); n && (n.lastModified = i); } this.root.lastModified = i; }); - S(this, fe, (e) => { + v(this, fe, (e) => { let i = ce.normalize(e); return i.startsWith("/") || (i = "/" + i), i.length > 1 && i.endsWith("/") && (i = i.slice(0, -1)), i; }); - S(this, Q, (e) => { + v(this, Q, (e) => { const i = ce.join(c(this, Ce), e); return c(this, fe).call(this, i); }); - S(this, Y, (e) => { + v(this, G, (e) => { if (!e || typeof e != "string") return !1; const i = c(this, fe).call(this, e); return !i.includes("..") && i.startsWith("/"); }); - S(this, H, (e) => { + v(this, _, (e) => { var a; const i = c(this, fe).call(this, e); if (i === "/") return this.root; @@ -1147,13 +1147,13 @@ const ti = class ti { } return r; }); - S(this, ye, (e) => { + v(this, ye, (e) => { const i = c(this, fe).call(this, e), n = ce.basename(i), r = ce.dirname(i); - return { parent: c(this, H).call(this, r), name: n }; + return { parent: c(this, _).call(this, r), name: n }; }); - S(this, it, (e, i, n) => n === !1 ? e : n === "root" ? e.map((r) => ce.join(i, r)) : n === !0 || n === "working" ? e.map((r) => ce.relative(c(this, Ce), ce.join(i, r))) : e); - S(this, nt, async (e, i, n, r = "") => { - const a = [], o = c(this, H).call(this, e); + v(this, it, (e, i, n) => n === !1 ? e : n === "root" ? e.map((r) => ce.join(i, r)) : n === !0 || n === "working" ? e.map((r) => ce.relative(c(this, Ce), ce.join(i, r))) : e); + v(this, nt, async (e, i, n, r = "") => { + const a = [], o = c(this, _).call(this, e); if (!o || o.type !== "dir") return a; const s = o.children; for (const l of s) { @@ -1170,16 +1170,16 @@ const ti = class ti { } return a; }); - S(this, rt, async (e, i, n, r = "") => { - const a = [], o = Array.isArray(i) ? i : [i], s = c(this, H).call(this, e); + v(this, rt, async (e, i, n, r = "") => { + const a = [], o = Array.isArray(i) ? i : [i], s = c(this, _).call(this, e); if (!s || s.type !== "dir") return a; if (!n) { for (const u of o) if (c(this, at).call(this, u)) { - const d = await c(this, vt).call(this, e, u); + const d = await c(this, Nt).call(this, e, u); a.push(...d); } else { const d = ce.join(e, u), p = c(this, fe).call(this, d); - c(this, H).call(this, p) && a.push(u); + c(this, _).call(this, p) && a.push(u); } return a; } @@ -1204,47 +1204,47 @@ const ti = class ti { } return a; }); - S(this, at, (e) => /[*?[\]{}]/.test(e)); - S(this, vt, async (e, i) => { - const n = [], r = c(this, H).call(this, e); + v(this, at, (e) => /[*?[\]{}]/.test(e)); + v(this, Nt, async (e, i) => { + const n = [], r = c(this, _).call(this, e); if (!r || r.type !== "dir") return n; const a = r.children.map((o) => o.name); for (const o of a) c(this, ot).call(this, o, i) && n.push(o); return n; }); - S(this, ot, (e, i) => { + v(this, ot, (e, i) => { const n = i.replace(/\./g, "\\.").replace(/\*/g, ".*").replace(/\?/g, ".").replace(/\{([^}]+)\}/g, (r, a) => "(" + a.split(",").join("|") + ")"); return new RegExp(`^${n}$`).test(e); }); var n, r, a; - W(this, Ce, i), this.root = { name: "/", type: "dir", children: [], lastModified: Date.now() }, Array.isArray(e) ? this.root.children = e : e && typeof e == "object" && (e.name && e.name !== "/" ? this.root.children.push(e) : (this.root = e, (n = this.root).name ?? (n.name = "/"), (r = this.root).children ?? (r.children = []), (a = this.root).lastModified ?? (a.lastModified = Date.now()))); + B(this, Ce, i), this.root = { name: "/", type: "dir", children: [], lastModified: Date.now() }, Array.isArray(e) ? this.root.children = e : e && typeof e == "object" && (e.name && e.name !== "/" ? this.root.children.push(e) : (this.root = e, (n = this.root).name ?? (n.name = "/"), (r = this.root).children ?? (r.children = []), (a = this.root).lastModified ?? (a.lastModified = Date.now()))); } async stat(e) { const i = c(this, Q).call(this, e); - if (!c(this, Y).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); - const n = c(this, H).call(this, i); + if (!c(this, G).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); + const n = c(this, _).call(this, i); if (!n) throw new Error(`ENOENT: no such file or directory, stat '${e}'`); return { isFile: () => n.type === "file", isDirectory: () => n.type === "dir", lastModified: n.lastModified }; } async dir(e) { const i = c(this, Q).call(this, e); - if (!c(this, Y).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); - const n = c(this, H).call(this, i); + if (!c(this, G).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); + const n = c(this, _).call(this, i); if (!n) throw new Error(`ENOENT: no such file or directory, scandir '${e}'`); if (n.type !== "dir") throw new Error(`ENOTDIR: not a directory, scandir '${e}'`); return n.children.map((r) => r.name); } async readFile(e) { const i = c(this, Q).call(this, e); - if (!c(this, Y).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); - const n = c(this, H).call(this, i); + if (!c(this, G).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); + const n = c(this, _).call(this, i); if (!n) throw new Error(`ENOENT: no such file or directory, open '${e}'`); if (n.type !== "file") throw new Error("EISDIR: illegal operation on a directory, read"); return n.content || ""; } async writeFile(e, i) { const n = c(this, Q).call(this, e); - if (!c(this, Y).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); + if (!c(this, G).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); const { parent: r, name: a } = c(this, ye).call(this, n); if (!r) throw new Error(`ENOENT: no such file or directory, open '${e}'`); if (r.type !== "dir") throw new Error("ENOTDIR: not a directory"); @@ -1253,13 +1253,13 @@ const ti = class ti { } async mkdir(e, i = {}) { const n = c(this, Q).call(this, e); - if (!c(this, Y).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); + if (!c(this, G).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); const { recursive: r } = i; if (r) { const a = n.split("/").filter((s) => s); let o = "/"; for (const s of a) - if (o = ce.join(o, s), !c(this, H).call(this, o)) { + if (o = ce.join(o, s), !c(this, _).call(this, o)) { const { parent: l, name: u } = c(this, ye).call(this, o); if (l && l.type === "dir") { const d = { name: u, type: "dir", children: [], lastModified: Date.now() }; @@ -1277,7 +1277,7 @@ const ti = class ti { } async unlink(e) { const i = c(this, Q).call(this, e); - if (!c(this, Y).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); + if (!c(this, G).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); const { parent: n, name: r } = c(this, ye).call(this, i); if (!n) throw new Error(`ENOENT: no such file or directory, unlink '${e}'`); const a = n.children.findIndex((o) => o.name === r); @@ -1287,7 +1287,7 @@ const ti = class ti { } async rmdir(e, i = {}) { const n = c(this, Q).call(this, e); - if (!c(this, Y).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); + if (!c(this, G).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); const { parent: r, name: a } = c(this, ye).call(this, n); if (!r) throw new Error(`ENOENT: no such file or directory, rmdir '${e}'`); const o = r.children.findIndex((l) => l.name === a); @@ -1299,26 +1299,26 @@ const ti = class ti { } async rename(e, i) { const n = c(this, Q).call(this, e), r = c(this, Q).call(this, i); - if (!c(this, Y).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); - if (!c(this, Y).call(this, r)) throw new Error(`EINVAL: invalid path '${i}'`); - if (!c(this, H).call(this, n)) throw new Error(`ENOENT: no such file or directory, rename '${e}' -> '${i}'`); + if (!c(this, G).call(this, n)) throw new Error(`EINVAL: invalid path '${e}'`); + if (!c(this, G).call(this, r)) throw new Error(`EINVAL: invalid path '${i}'`); + if (!c(this, _).call(this, n)) throw new Error(`ENOENT: no such file or directory, rename '${e}' -> '${i}'`); const { parent: a, name: o } = c(this, ye).call(this, n), { parent: s, name: l } = c(this, ye).call(this, r); if (!s) throw new Error(`ENOENT: no such file or directory, rename '${e}' -> '${i}'`); - if (c(this, H).call(this, r)) throw new Error(`EEXIST: file already exists, rename '${e}' -> '${i}'`); + if (c(this, _).call(this, r)) throw new Error(`EEXIST: file already exists, rename '${e}' -> '${i}'`); const u = a.children.findIndex((p) => p.name === o), d = { ...a.children[u], name: l, lastModified: Date.now() }; a.children.splice(u, 1), s.children.push(d), c(this, me).call(this, a), a !== s && c(this, me).call(this, s), c(this, ke).call(this, { action: "rename", path: r, oldPath: n, type: d.type, timestamp: Date.now() }); } async exists(e) { const i = c(this, Q).call(this, e); - return c(this, Y).call(this, i) ? c(this, H).call(this, i) !== null : !1; + return c(this, G).call(this, i) ? c(this, _).call(this, i) !== null : !1; } getLastModified() { return this.root.lastModified; } subscribe(e) { if (typeof e != "function") throw new Error("Callback must be a function"); - return c(this, He).add(e), () => { - c(this, He).delete(e); + return c(this, _e).add(e), () => { + c(this, _e).delete(e); }; } getWorkingDirectory() { @@ -1326,16 +1326,16 @@ const ti = class ti { } scope(e = "/") { const i = c(this, fe).call(this, e); - if (!c(this, Y).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); - const n = c(this, H).call(this, i); + if (!c(this, G).call(this, i)) throw new Error(`EINVAL: invalid path '${e}'`); + const n = c(this, _).call(this, i); if (!n) throw new Error(`ENOENT: no such file or directory '${e}'`); if (n.type !== "dir") throw new Error(`ENOTDIR: not a directory '${e}'`); - return n.children ?? (n.children = []), n.lastModified ?? (n.lastModified = Date.now()), new ti(this.root, i); + return n.children ?? (n.children = []), n.lastModified ?? (n.lastModified = Date.now()), new ii(this.root, i); } async findFiles(e, i, n = {}) { const r = c(this, Q).call(this, e); - if (!c(this, Y).call(this, r)) throw new Error(`EINVAL: invalid path '${e}'`); - const a = c(this, H).call(this, r); + if (!c(this, G).call(this, r)) throw new Error(`EINVAL: invalid path '${e}'`); + const a = c(this, _).call(this, r); if (!a) throw new Error(`ENOENT: no such file or directory '${e}'`); if (a.type !== "dir") throw new Error(`ENOTDIR: not a directory '${e}'`); const { recursive: o = !1, fullPath: s = !1 } = n; @@ -1347,9 +1347,9 @@ const ti = class ti { return c(this, it).call(this, l, r, s); } }; -Ce = new WeakMap(), He = new WeakMap(), ke = new WeakMap(), me = new WeakMap(), fe = new WeakMap(), Q = new WeakMap(), Y = new WeakMap(), H = new WeakMap(), ye = new WeakMap(), it = new WeakMap(), nt = new WeakMap(), rt = new WeakMap(), at = new WeakMap(), vt = new WeakMap(), ot = new WeakMap(); -let wi = ti; -const Tr = async (t, e = "/", i = "") => { +Ce = new WeakMap(), _e = new WeakMap(), ke = new WeakMap(), me = new WeakMap(), fe = new WeakMap(), Q = new WeakMap(), G = new WeakMap(), _ = new WeakMap(), ye = new WeakMap(), it = new WeakMap(), nt = new WeakMap(), rt = new WeakMap(), at = new WeakMap(), Nt = new WeakMap(), ot = new WeakMap(); +let bi = ii; +const Or = async (t, e = "/", i = "") => { try { const n = await t.stat(e), r = e === "/" ? "/" : ce.basename(e), a = { title: r, key: i ? `${i}${e}` : e, isLeaf: n.isFile() }; if (n.isDirectory()) { @@ -1369,7 +1369,7 @@ const Tr = async (t, e = "/", i = "") => { for (const u of [...s, ...l]) { const d = e === "/" ? `/${u}` : `${e}/${u}`; try { - const p = await Tr(t, d, i); + const p = await Or(t, d, i); a.children.push(p); } catch (p) { console.warn(`Failed to process ${d}:`, p.message); @@ -1383,99 +1383,99 @@ const Tr = async (t, e = "/", i = "") => { } }; export { - Nt as $, - Ai as A, - Fi as B, - _n as C, + xt as $, + Li as A, + Ai as B, + Hn as C, bt as D, Kn as E, Un as F, - aa as G, - Jn as H, - Gt as I, + oa as G, + Gn as H, + Xt as I, ne as J, - Hn as K, - Zn as L, + Jn as K, + er as L, Dn as M, - Wn as N, - jn as O, - In as P, - ta as Q, - Li as R, - ia as S, - Oi as T, - zt as U, - Vn as V, - Mn as W, - er as X, - tr as Y, - oa as Z, - sa as _, - vi as a, - la as a0, - ca as a1, + Bn as N, + In as O, + jn as P, + ia as Q, + Ii as R, + na as S, + Ri as T, + Bt as U, + Mn as V, + Vn as W, + tr as X, + ir as Y, + sa as Z, + la as _, + xi as a, + ca as a0, + da as a1, ct as a2, dt as a3, - da as a4, - ua as a5, - ur as a6, - Qt as a7, - Xt as a8, + ua as a4, + pa as a5, + pr as a6, + Zt as a7, + Qt as a8, Wi as a9, - Ee as aA, - Sr as aB, - vr as aC, - wi as aD, - Tr as aE, - nr as aa, - rr as ab, - ar as ac, - or as ad, - sr as ae, - lr as af, - pa as ag, + $e as aA, + Nr as aB, + xr as aC, + bi as aD, + Or as aE, + rr as aa, + ar as ab, + or as ac, + sr as ad, + lr as ae, + cr as af, + ga as ag, Ct as ah, P as ai, - Si as aj, - fr as ak, - G as al, + Ni as aj, + yr as ak, + Y as al, st as am, - $i as an, + Si as an, Z as ao, ee as ap, - Hr as aq, - Jr as ar, + Jr as aq, + Gr as ar, Yr as as, se as at, - ei as au, - Nr as av, - I as aw, + ti as au, + Pr as av, + j as aw, Ei as ax, - Me as ay, + Ve as ay, Fe as az, Tn as b, lt as c, - Ni as d, - Xr as e, - Qr as f, + Pi as d, + Qr as e, + Zr as f, Pn as g, - Zr as h, + ea as h, On as i, Fn as j, - ea as k, - Ri as l, + ta as k, + Fi as l, Rn as m, - na as n, + ra as n, Yt as o, ji as p, - Mi as q, + Di as q, Ft as r, - Xn as s, + Qn as s, oe as t, - Gr as u, + Xr as u, Vi as v, Yn as w, - Gn as x, - ra as y, - Ii as z + Xn as x, + aa as y, + Mi as z }; diff --git a/dist/components.js b/dist/components.js index e46d6bd..51c40f7 100644 --- a/dist/components.js +++ b/dist/components.js @@ -1,4 +1,4 @@ -import { aq as s, ah as p, ar as n, as as r, ap as t } from "./common/main-Dtr3vSp2.js"; +import { aq as s, ah as p, ar as n, as as r, ap as t } from "./common/main-BNMEkn4Y.js"; export { s as Empty, p as Icon, diff --git a/dist/container.js b/dist/container.js index 3313b78..bf6c23b 100644 --- a/dist/container.js +++ b/dist/container.js @@ -1,4 +1,4 @@ -import { am as s, aq as e, ar as p, as as n, an as t, ap as d, ao as r, al as u } from "./common/main-Dtr3vSp2.js"; +import { am as s, aq as e, ar as p, as as n, an as t, ap as d, ao as r, al as u } from "./common/main-BNMEkn4Y.js"; export { s as Context, e as Empty, diff --git a/dist/data-converter.js b/dist/data-converter.js index d1dba41..0d023a7 100644 --- a/dist/data-converter.js +++ b/dist/data-converter.js @@ -1,6 +1,6 @@ import "lodash"; import "react"; -import { D as p } from "./common/main-Dtr3vSp2.js"; +import { D as p } from "./common/main-BNMEkn4Y.js"; export { p as default }; diff --git a/dist/data-list.js b/dist/data-list.js index 37fb4f1..b17c9f0 100644 --- a/dist/data-list.js +++ b/dist/data-list.js @@ -1,4 +1,4 @@ -import { L as t, J as e, B as r, F as o, M as i, I as l, E as u, K as D, C as n, N as L, A as C, P as m, O as p, W as b, S as c, U as F, T as d, V as O, Q as S } from "./common/main-Dtr3vSp2.js"; +import { L as t, J as e, B as r, F as o, M as i, I as l, E as u, K as D, C as n, N as L, A as C, P as m, O as p, W as b, S as c, U as F, T as d, V as O, Q as S } from "./common/main-BNMEkn4Y.js"; export { t as DataListContent, e as DataListContext, diff --git a/dist/data-list/utils.js b/dist/data-list/utils.js index 10b9297..d60bbc9 100644 --- a/dist/data-list/utils.js +++ b/dist/data-list/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { p as t } from "../common/main-Dtr3vSp2.js"; +import { p as t } from "../common/main-BNMEkn4Y.js"; export { t as getDefaultExpandRowKeys }; diff --git a/dist/grid-layout-form.js b/dist/grid-layout-form.js index aa641d6..cdcbfa7 100644 --- a/dist/grid-layout-form.js +++ b/dist/grid-layout-form.js @@ -1,4 +1,4 @@ -import { a7 as s, a9 as r, a8 as u, a6 as o, z as t, ae as m, ac as d, ad as F, ag as i, ab as g, aa as c, af as l } from "./common/main-Dtr3vSp2.js"; +import { a7 as s, a9 as r, a8 as u, a6 as o, z as t, ae as m, ac as d, ad as F, ag as i, ab as g, aa as c, af as l } from "./common/main-BNMEkn4Y.js"; export { s as GridLayoutForm, r as GridLayoutFormHelper, diff --git a/dist/grid-layout-form/utils.js b/dist/grid-layout-form/utils.js index 065c34e..4477559 100644 --- a/dist/grid-layout-form/utils.js +++ b/dist/grid-layout-form/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { a as o, g } from "../common/main-Dtr3vSp2.js"; +import { a as o, g } from "../common/main-BNMEkn4Y.js"; export { o as getNormalizeWidget, g as getOptionItemByValue diff --git a/dist/grid-layout.js b/dist/grid-layout.js index 91c5cc3..212d151 100644 --- a/dist/grid-layout.js +++ b/dist/grid-layout.js @@ -1,4 +1,4 @@ -import { q as u, v as e, s as r, H as t, G as d, x as i, z as o, y, w as G } from "./common/main-Dtr3vSp2.js"; +import { q as u, v as e, s as r, H as t, G as d, x as i, z as o, y, w as G } from "./common/main-BNMEkn4Y.js"; export { u as GridLayout, e as GridLayoutFramework, diff --git a/dist/grid-layout/utils.js b/dist/grid-layout/utils.js index 9253a3d..b6fe0de 100644 --- a/dist/grid-layout/utils.js +++ b/dist/grid-layout/utils.js @@ -1,4 +1,4 @@ -import { l as t, o as a, n as l } from "../common/main-Dtr3vSp2.js"; +import { l as t, o as a, n as l } from "../common/main-BNMEkn4Y.js"; export { t as getBoxStyle, a as getNormalizeFields, diff --git a/dist/hooks.js b/dist/hooks.js index 1b10866..1455911 100644 --- a/dist/hooks.js +++ b/dist/hooks.js @@ -1,7 +1,7 @@ import "lodash"; import "rc-field-form"; import "react"; -import { a3 as r, a2 as o, a4 as p, a0 as f, a1 as i, a5 as m, $ as c } from "./common/main-Dtr3vSp2.js"; +import { a3 as r, a2 as o, a4 as p, a0 as f, a1 as i, a5 as m, $ as c } from "./common/main-BNMEkn4Y.js"; import { default as b } from "rc-util/lib/hooks/useMergedState"; export { r as useDeepEffect, diff --git a/dist/iconfont.js b/dist/iconfont.js index 1deb4eb..ce7e146 100644 --- a/dist/iconfont.js +++ b/dist/iconfont.js @@ -2,7 +2,7 @@ import "react/jsx-runtime"; import "react"; import "prop-types"; import "classnames"; -import { ah as a } from "./common/main-Dtr3vSp2.js"; +import { ah as a } from "./common/main-BNMEkn4Y.js"; export { a as default }; diff --git a/dist/index.js b/dist/index.js index ae21567..2247961 100644 --- a/dist/index.js +++ b/dist/index.js @@ -1,4 +1,4 @@ -import { aB as s, aC as e, ax as o, ay as n, at as p, az as r, aw as c, av as u, au as f, aA as l } from "./common/main-Dtr3vSp2.js"; +import { aB as s, aC as e, ax as o, ay as n, at as p, az as r, aw as c, av as u, au as f, aA as l } from "./common/main-BNMEkn4Y.js"; export { s as AppContext, e as AppGlobalParamsContext, diff --git a/dist/pages.js b/dist/pages.js index 91e2ec5..38a72be 100644 --- a/dist/pages.js +++ b/dist/pages.js @@ -1,4 +1,4 @@ -import { Y as t, X as e, Z as o, _ as g } from "./common/main-Dtr3vSp2.js"; +import { Y as t, X as e, Z as o, _ as g } from "./common/main-BNMEkn4Y.js"; export { t as CustomPage, e as DataListPage, diff --git a/dist/res-ws.js b/dist/res-ws.js index b50cf9a..942107a 100644 --- a/dist/res-ws.js +++ b/dist/res-ws.js @@ -1,5 +1,5 @@ import "lodash"; -import { R as a } from "./common/main-Dtr3vSp2.js"; +import { R as a } from "./common/main-BNMEkn4Y.js"; export { a as default }; diff --git a/dist/style.css b/dist/style.css index 2777552..6c80af0 100644 --- a/dist/style.css +++ b/dist/style.css @@ -1 +1 @@ -#nprogress{pointer-events:none}#nprogress .bar{background:#29d;position:fixed;z-index:1031;top:0;left:0;width:100%;height:2px}#nprogress .peg{display:block;position:absolute;right:0;width:100px;height:100%;box-shadow:0 0 10px #29d,0 0 5px #29d;opacity:1;-webkit-transform:rotate(3deg) translate(0px,-4px);-ms-transform:rotate(3deg) translate(0px,-4px);transform:rotate(3deg) translateY(-4px)}#nprogress .spinner{display:block;position:fixed;z-index:1031;top:15px;right:15px}#nprogress .spinner-icon{width:18px;height:18px;box-sizing:border-box;border:solid 2px transparent;border-top-color:#29d;border-left-color:#29d;border-radius:50%;-webkit-animation:nprogress-spinner .4s linear infinite;animation:nprogress-spinner .4s linear infinite}.nprogress-custom-parent{overflow:hidden;position:relative}.nprogress-custom-parent #nprogress .spinner,.nprogress-custom-parent #nprogress .bar{position:absolute}@-webkit-keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes nprogress-spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.react-grid-layout .react-grid-item{box-sizing:border-box!important}.monaco-editor .parameter-hints-widget{border:0px}.monaco-editor .parameter-hints-widget .signature{padding:0}.monaco-editor .suggest-widget,.monaco-editor.vs-dark .suggest-widget{border:0px}.monaco-editor .rename-box{top:0}.ant-divider:has(+.ant-form .ant-divider:first-child){display:none}input:-webkit-autofill,textarea:-webkit-autofill,select:-webkit-autofill{-webkit-box-shadow:0 0 0 1000px #fff inset!important;-webkit-text-fill-color:#000!important;transition:background-color 9999s ease-in-out 0s}:root{--padding-lg: 24px;--padding-md: 16px;--padding-sm: 12px;--padding-xs: 8px;--padding-xss: 4px;--margin-lg: 24px;--margin-md: 16px;--margin-sm: 12px;--margin-xs: 8px;--margin-xss: 4px;--border-color: #f2f2f2;--bg-color: rgba(0, 0, 0, .02)}#root{height:100vh;background-color:#f0f2f5}*::-webkit-scrollbar-thumb{background:#aaa;border-radius:5px}*::-webkit-scrollbar-thumb:hover{background:#999}*::-webkit-scrollbar-track{background-color:#ddd}*::-webkit-scrollbar-corner{background-color:#ddd}*::-webkit-scrollbar{width:5px;height:5px}.ff-container{height:100%}.ff-loading{height:100vh;width:100%;background-color:#f0f2f5;display:flex;justify-content:center;align-items:center}.ff-loading .loader{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);width:128px;height:80px}.ff-loading .loader .square{position:relative}.ff-loading .loader .square:nth-child(1){margin-left:0}.ff-loading .loader .square:nth-child(1) span{-webkit-animation:animsquare1 2s infinite ease-in;animation:animsquare1 2s infinite ease-in}.ff-loading .loader .square:nth-child(2){margin-left:44px}.ff-loading .loader .square:nth-child(2) span{-webkit-animation:animsquare2 2s infinite ease-in;animation:animsquare2 2s infinite ease-in}.ff-loading .loader .square:nth-child(3){margin-left:88px}.ff-loading .loader .square:nth-child(3) span{-webkit-animation:animsquare3 2s infinite ease-in;animation:animsquare3 2s infinite ease-in}.ff-loading .loader .square:nth-child(4){margin-left:132px}.ff-loading .loader .square:nth-child(4) span{-webkit-animation:animsquare4 2s infinite ease-in;animation:animsquare4 2s infinite ease-in}.ff-loading .loader .square span{position:absolute;top:0;left:20px;height:36px;width:36px;border-radius:2px;background-color:#fff}.ff-loading .loader .square span:nth-child(1){top:0;-webkit-animation-delay:0s;animation-delay:0s}.ff-loading .loader .square span:nth-child(2){top:44px;-webkit-animation-delay:.15s;animation-delay:.15s}.ff-loading .loader .square span:nth-child(3){top:88px;-webkit-animation-delay:.3s;animation-delay:.3s}@media (max-width: 550px){.ff-loading .loader{-webkit-transform:scale(.75);transform:scale(.75)}}@media (max-width: 440px){.ff-loading .loader{-webkit-transform:scale(.5);transform:scale(.5)}}@keyframes animsquare4{0%,5%,95%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}30%,70%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare3{0%,10%,90%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}35%,65%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare2{0%,15%,85%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}40%,60%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare1{0%,20%,80%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}45%,55%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}.ff-notification{position:fixed;z-index:2000;display:flex;max-height:100vh;padding:20px;align-items:flex-end;width:380px;overflow-x:hidden;overflow-y:clip;height:100vh;box-sizing:content-box;pointer-events:none;flex-direction:column;gap:24px}.ff-notification-top,.ff-notification-topLeft,.ff-notification-topRight{top:0}.ff-notification-bottom,.ff-notification-bottomRight,.ff-notification-bottomLeft{bottom:0}.ff-notification-bottomRight,.ff-notification-topRight{right:0}.ff-notification-notice{position:relative;display:block;box-sizing:border-box;line-height:1.5;width:100%}.ff-notification-notice-wrapper{z-index:2000;pointer-events:auto;position:relative;display:block;box-sizing:border-box;border-radius:8px;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d;width:calc(100% - 40px);background-color:#fff;right:0}.ff-notification-notice-content{padding:14px 18px;display:flex;gap:8px;white-space:pre-wrap}.ff-notification-notice-content .ff-notification-icon.ff-notification-error{--bg-color: #ff4d4f}.ff-notification-notice-content .ff-notification-icon.ff-notification-success{--bg-color: #52c41a}.ff-notification-notice-content .ff-notification-icon.ff-notification-info{--bg-color: #1677ff}.ff-notification-notice-content .ff-notification-icon>*:first-child{width:24px;height:24px;display:inline-flex;align-items:center;justify-content:center;border-radius:50%;color:#fff;background-color:var(--bg-color)}.ff-notification-notice-progress{position:absolute;left:3px;right:3px;border-radius:1px;overflow:hidden;-moz-appearance:none;appearance:none;-webkit-appearance:none;display:block;inline-size:100%;block-size:2px;border:0}.ff-notification-notice-progress,.ff-notification-notice-progress::-webkit-progress-bar{background-color:#0000000a}.ff-notification-notice-progress::-moz-progress-bar{background-color:#31afff}.ff-notification-notice-progress::-webkit-progress-value{background-color:#31afff}.ff-notification-fade{overflow:hidden;transition:all .3s}.ff-notification-fade-appear-prepare{pointer-events:none;opacity:0!important}.ff-notification-fade-appear-start{transform:translate(100%);opacity:0}.ff-notification-fade-appear-active{transform:translate(0);opacity:1}.ff-data-list-cell-editable:after{content:" ";display:block;position:absolute;width:0px;height:0px;bottom:0;right:0;border-style:solid;border-color:rgba(0,0,0,.45) transparent;border-width:0 0 var(--padding-xs, 8px) var(--padding-xs, 8px)}.ff-data-list-framework{height:100%;--sider-width: 280px;--col-num: 1;--col-width: 200px;--gap: 8px;display:flex;gap:var(--gap)}.ff-data-list-framework .ff-data-list-container{width:100%;height:100%;row-gap:var(--gap);display:flex;flex-direction:column}.ff-data-list-framework .ff-data-list-container .ff-data-list-content{flex:1;overflow-y:auto;padding:calc(var(--gap) / 2)}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item{display:flex;flex-direction:column;justify-content:space-between;row-gap:var(--gap);border-radius:4px;background-color:#fff;box-shadow:0 0 8px #00000014}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-container{padding:var(--gap)}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #f0f0f0;height:32px}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions .data-list-grid-layout-item-action{text-align:center;margin:2px 0;flex:1}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions .data-list-grid-layout-item-action:not(:last-child){border-right:1px solid #f0f0f0}.ff-data-table-framework{height:100%;--sider-width: 280px;--col-num: 1;--gap: 8px;display:flex;gap:var(--gap)}.ff-data-table-framework .ff-data-table-container{width:100%;height:100%;display:flex;flex-direction:column;row-gap:var(--gap)}.ff-data-list-filter:has(.ff-data-list-filter-actions:not(.expanded)){height:60px;overflow-y:hidden}.ff-data-list-filter .ff-data-list-filter-default-form.ff-grid-layout-form{--grid-layout-cols: 25;--grid-layout-item-margin-x: 8px;--grid-layout-item-margin-y: 16px}.ff-data-list-filter .ff-data-list-filter-actions{grid-column:span var(--itemp-span, 5) / calc(var(--grid-layout-cols, 25) + 1)}.ff-data-list-filter .ff-data-list-filter-actions:not(.expanded){grid-row:1}.ff-data-list-filter .ff-data-list-filter-actions .ff-data-list-filter-expanded-button{margin-left:8px}.ff-data-list-filter .ff-data-list-filter-actions .ant-form-item-control-input-content{display:flex;justify-content:flex-end;align-items:center;gap:8px}.ff-data-list-footer{padding-block-start:8px;display:flex;justify-content:space-between}.ff-data-list-footer .ff-data-list-actions{display:flex;justify-content:center;gap:8px}.ff-data-list-sider{width:var(--sider-width, 280px);overflow-y:auto;box-shadow:8px 0 4px -8px #0000000d}.ff-data-list-sider+.ff-data-list-container{width:calc(100% - var(--sider-width, 280px))}.ff-data-list-toolbar{gap:8px;display:flex;justify-content:space-between;align-items:center}.ff-data-list-toolbar .ff-data-list-title{color:#000000e0;font-weight:600;font-size:14px}.ff-data-list-toolbar .ff-data-list-actions{display:flex;justify-content:center;gap:8px}.ff-data-list-toolbar .ff-data-list-tabs{cursor:pointer}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab{color:#00000073}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab:hover{font-weight:600}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab.active{color:#1677ff;font-weight:600}.ff-data-list-item-operations{max-width:180px;display:flex;flex-wrap:wrap;gap:var(--margin-xss, 4px)}.ff-data-list-item-operations>.ant-btn:not(.ant-btn-circle){flex-grow:1}.ff-data-list-helper{height:100%}.ff-data-list-table{height:100%;overflow-y:hidden}.ff-data-list-table .ant-table *{scrollbar-width:auto;scrollbar-color:auto}.ff-grid-layout{--grid-layout-h: 1;--grid-layout-row: none;--grid-layout-row-height: 18px;--grid-layout-row-height-offset: 0px;--grid-layout-cols: 12;display:grid;grid-template-columns:repeat(var(--grid-layout-cols),1fr);grid-auto-rows:minmax(min-content,max-content);padding:var(--grid-layout-container-padding-y, 0) var(--grid-layout-container-padding-x, 0);padding-bottom:calc(var(--grid-layout-container-padding-y, 0) + var(--grid-layout-item-margin-y));column-gap:var(--grid-layout-item-margin-x);row-gap:var(--grid-layout-item-margin-y)}.ff-grid-layout .grid-layout-item{grid-row:span var(--grid-layout-h, 1);grid-column:calc(var(--grid-layout-x, 1) + 1)/calc(var(--grid-layout-x, 1) + var(--grid-layout-w, 1) + 1);height:calc(var(--grid-layout-row-height) * var(--grid-layout-h) + var(--grid-layout-row-height-offset));padding:var(--grid-layout-box-paddin);margin:var(--grid-layout-box-margin);display:var(--grid-layout-box-display, flex);align-items:var(--grid-layout-box-align-items, center);justify-content:var(--grid-layout-box-justify-content, normal)}.ff-data-list-content{display:grid;gap:var(--gap, 8px);grid-template-columns:repeat(var(--col-num, 5),1fr);grid-auto-rows:min-content}.ff-data-list-content[style*=--col-width]{grid-template-columns:repeat(auto-fill,minmax(var(--col-width, 280px),1fr))}.ff-grid-layout-form{--grid-layout-h: 1;--grid-layout-row: none;--grid-layout-row-height: 18px;--grid-layout-row-height-offset: 0px;--grid-layout-cols: 12;display:grid;grid-template-columns:repeat(var(--grid-layout-cols),1fr);grid-auto-rows:minmax(min-content,max-content);padding:var(--grid-layout-container-padding-y, 0) var(--grid-layout-container-padding-x, 0);padding-bottom:calc(var(--grid-layout-container-padding-y, 0) + var(--grid-layout-item-margin-y, 16px));column-gap:var(--grid-layout-item-margin-x, 8px);row-gap:var(--grid-layout-item-margin-y, 16px)}.ff-grid-layout-form .grid-layout-item{grid-row:span var(--grid-layout-h, 1);grid-column:calc(var(--grid-layout-x, 1) + 1)/calc(var(--grid-layout-x, 1) + var(--grid-layout-w, 1) + 1);height:calc(var(--grid-layout-row-height) * var(--grid-layout-h) + var(--grid-layout-row-height-offset));padding:var(--grid-layout-box-padding-y, 0) var(--grid-layout-box-padding-x, 0);margin:var(--grid-layout-box-margin)}.ff-iconfont{transform:scale(1.14);vertical-align:-.125em;display:inline-flex;align-items:center;justify-content:center}.ff-iconfont:not(:last-child){margin-right:8px}.ff-popover-header{margin-bottom:calc(var(--margin-sm) / 2)}.ff-popover-header:empty{display:none}.ff-popover-footer{padding-top:12px}.ff-button.ant-btn-link,.ff-button.ant-btn-text{width:initial;padding:0;height:auto}.ff-default.ant-btn-link{color:#000000e0}.ant-btn-link.ant-btn:not(:disabled):focus-visible{outline:initial;outline-offset:initial;transition:initial}.ff-modal-form{display:flex;flex-direction:column;gap:var(--modal-form-gap, 8px)}.mask-motion-enter-active,.mask-motion-appear-active,.mask-motion-leave-active{transition:all .3s}.mask-motion-enter,.mask-motion-appear{opacity:0}.mask-motion-enter-active,.mask-motion-appear-active,.mask-motion-leave{opacity:1}.mask-motion-leave-active{opacity:0}.panel-motion-left-enter-start,.panel-motion-left-appear-start,.panel-motion-left-leave-start{transition:none!important}.panel-motion-left-enter-active,.panel-motion-left-appear-active,.panel-motion-left-leave-active{transition:all .3s}.panel-motion-left-enter,.panel-motion-left-appear{transform:translate(-100%)}.panel-motion-left-enter-active,.panel-motion-left-appear-active,.panel-motion-left-leave{transform:translate(0)}.panel-motion-left-leave-active{transform:translate(-100%)!important}.panel-motion-right-enter-start,.panel-motion-right-appear-start,.panel-motion-right-leave-start{transition:none!important}.panel-motion-right-enter-active,.panel-motion-right-appear-active,.panel-motion-right-leave-active{transition:all .3s}.panel-motion-right-enter,.panel-motion-right-appear{transform:translate(100%)}.panel-motion-right-enter-active,.panel-motion-right-appear-active,.panel-motion-right-leave{transform:translate(0)}.panel-motion-right-leave-active{transform:translate(100%)!important}.panel-motion-top-enter-start,.panel-motion-top-appear-start,.panel-motion-top-leave-start{transition:none!important}.panel-motion-top-enter-active,.panel-motion-top-appear-active,.panel-motion-top-leave-active{transition:all .3s}.panel-motion-top-enter,.panel-motion-top-appear{transform:translateY(-100%)}.panel-motion-top-enter-active,.panel-motion-top-appear-active,.panel-motion-top-leave{transform:translateY(0)}.panel-motion-top-leave-active{transform:translateY(-100%)!important}.panel-motion-bottom-enter-start,.panel-motion-bottom-appear-start,.panel-motion-bottom-leave-start{transition:none!important}.panel-motion-bottom-enter-active,.panel-motion-bottom-appear-active,.panel-motion-bottom-leave-active{transition:all .3s}.panel-motion-bottom-enter,.panel-motion-bottom-appear{transform:translateY(100%)}.panel-motion-bottom-enter-active,.panel-motion-bottom-appear-active,.panel-motion-bottom-leave{transform:translateY(0)}.panel-motion-bottom-leave-active{transform:translateY(100%)!important}.ff-drawer-mask{top:0;right:0;bottom:0;left:0;position:absolute;z-index:1050;pointer-events:auto;background-color:var(--popup-mask-bg-color, rgba(0, 0, 0, .45))}.ff-drawer{top:0;right:0;bottom:0;left:0;position:fixed;z-index:1050;pointer-events:none}.ff-drawer-close{top:14px;right:0}.ff-drawer-inline{position:absolute}.ff-drawer-left .ff-drawer-content-wrapper{inset:0 auto 0 0;box-shadow:6px 0 16px #00000014,3px 0 6px -4px #0000001f,9px 0 28px 8px #0000000d}.ff-drawer-right .ff-drawer-content-wrapper{inset:0 0 0 auto;box-shadow:-6px 0 16px #00000014,-3px 0 6px -4px #0000001f,-9px 0 28px 8px #0000000d}.ff-drawer-top .ff-drawer-content-wrapper{top:0;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d}.ff-drawer-bottom .ff-drawer-content-wrapper{bottom:0;box-shadow:0 -6px 16px #00000014,0 -3px 6px -4px #0000001f,0 -9px 28px 8px #0000000d}.ff-drawer-top .ff-drawer-content-wrapper,.ff-drawer-bottom .ff-drawer-content-wrapper{inset-inline:0}.ff-drawer-content{width:100%;height:100%;overflow:auto;background-color:var(--popup-bg-color, #fff);pointer-events:auto}.ff-drawer-header{padding:16px 8px;border-bottom:1px solid rgba(5,5,5,.06)}.ff-drawer-footer{border-top:1px solid rgba(5,5,5,.06);padding:12px 8px}.ff-drawer-body{padding:8px}.ff-drawer-content-wrapper{position:absolute;z-index:1050;overflow:hidden;transition:transform .3s;max-width:100vw}.ff-drawer-content-wrapper-hidden{display:none}.ff-modal-mask{position:fixed;top:0;right:0;left:0;bottom:0;pointer-events:auto;background-color:var(--popup-mask-bg-color, rgba(0, 0, 0, .45));height:100%;filter:alpha(opacity=50);z-index:1050}.ff-modal-mask-hidden{display:none}.ff-modal-fade-enter,.ff-modal-fade-appear{opacity:0;animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-play-state:paused}.ff-modal-fade-leave{animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-play-state:paused}.ff-modal-fade-enter.ff-modal-fade-enter-active,.ff-modal-fade-appear.ff-modal-fade-appear-active{animation-name:rcDialogFadeIn;animation-play-state:running}.ff-modal-fade-leave.ff-modal-fade-leave-active{animation-name:rcDialogFadeOut;animation-play-state:running}@keyframes rcDialogFadeIn{0%{opacity:0}to{opacity:1}}@keyframes rcDialogFadeOut{0%{opacity:1}to{opacity:0}}.ff-modal{position:relative;top:100px;width:fit-content;min-width:max(35vw,248px);padding:0;margin:0 auto}.ff-modal-close{position:absolute;top:14px;right:8px}.ff-modal-header:has(.ff-popup-title),.ff-modal-header:has(.ff-popup-sub-title){margin-bottom:8px}.ff-modal-footer:not(:empty){margin-top:12px}.ff-modal-wrap{position:fixed;overflow:auto;top:0;right:0;bottom:0;left:0;z-index:1050;-webkit-overflow-scrolling:touch;outline:0}.ff-modal-title{margin:0;font-size:14px;line-height:21px;font-weight:700}.ff-modal-content{position:relative;background-color:var(--popup-bg-color, #fff);border-radius:8px;background-clip:padding-box;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d;padding:20px 24px;max-height:calc(100vh - 150px)}.ff-modal-zoom-enter,.ff-modal-zoom-appear{opacity:0;animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.08,.82,.17,1);animation-play-state:paused}.ff-modal-zoom-leave{animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.6,.04,.98,.34);animation-play-state:paused}.ff-modal-zoom-enter.ff-modal-zoom-enter-active,.ff-modal-zoom-appear.ff-modal-zoom-appear-active{animation-name:rcDialogZoomIn;animation-play-state:running}.ff-modal-zoom-leave.ff-modal-zoom-leave-active{animation-name:rcDialogZoomOut;animation-play-state:running}@keyframes rcDialogZoomIn{0%{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}@keyframes rcDialogZoomOut{0%{transform:scale(1)}to{opacity:0;transform:scale(0)}}.ff-popup-close{cursor:pointer;border:0;background:transparent;font-size:24px;position:absolute;line-height:1;color:#000;opacity:.5}.ff-popup-close:disabled{pointer-events:none}.ff-popup-close:hover{opacity:.65}.ff-popup{display:flex;flex-direction:column}.ff-popup-title,.ff-popup-sub-title{display:inline}.ff-popup-title{font-size:16px;font-weight:600}.ff-popup-footer{display:flex;gap:8px;justify-content:flex-end}.ff-popup-footer:empty{display:none}.ff-popup-reserved-extras,.ff-popup-extras,.ff-popup-actions{display:flex;align-items:center;gap:8px}.ff-popup-reserved-extras:empty,.ff-popup-extras:empty,.ff-popup-actions:empty{display:none}.ff-popup-actions{margin-left:auto}.ff-popup-body{flex:1;overflow-y:auto} +#nprogress{pointer-events:none}#nprogress .bar{background:#29d;position:fixed;z-index:1031;top:0;left:0;width:100%;height:2px}#nprogress .peg{display:block;position:absolute;right:0;width:100px;height:100%;box-shadow:0 0 10px #29d,0 0 5px #29d;opacity:1;-webkit-transform:rotate(3deg) translate(0px,-4px);-ms-transform:rotate(3deg) translate(0px,-4px);transform:rotate(3deg) translateY(-4px)}#nprogress .spinner{display:block;position:fixed;z-index:1031;top:15px;right:15px}#nprogress .spinner-icon{width:18px;height:18px;box-sizing:border-box;border:solid 2px transparent;border-top-color:#29d;border-left-color:#29d;border-radius:50%;-webkit-animation:nprogress-spinner .4s linear infinite;animation:nprogress-spinner .4s linear infinite}.nprogress-custom-parent{overflow:hidden;position:relative}.nprogress-custom-parent #nprogress .spinner,.nprogress-custom-parent #nprogress .bar{position:absolute}@-webkit-keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes nprogress-spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.react-grid-layout .react-grid-item{box-sizing:border-box!important}.monaco-editor .parameter-hints-widget{border:0px}.monaco-editor .parameter-hints-widget .signature{padding:0}.monaco-editor .suggest-widget,.monaco-editor.vs-dark .suggest-widget{border:0px}.monaco-editor .rename-box{top:0}.ant-divider:has(+.ant-form .ant-divider:first-child){display:none}input:-webkit-autofill,textarea:-webkit-autofill,select:-webkit-autofill{-webkit-box-shadow:0 0 0 1000px #fff inset!important;-webkit-text-fill-color:#000!important;transition:background-color 9999s ease-in-out 0s}:root{--padding-lg: 24px;--padding-md: 16px;--padding-sm: 12px;--padding-xs: 8px;--padding-xss: 4px;--margin-lg: 24px;--margin-md: 16px;--margin-sm: 12px;--margin-xs: 8px;--margin-xss: 4px;--border-color: #f2f2f2;--bg-color: rgba(0, 0, 0, .02)}#root{height:100vh;background-color:#f0f2f5}*::-webkit-scrollbar-thumb{background:#aaa;border-radius:5px}*::-webkit-scrollbar-thumb:hover{background:#999}*::-webkit-scrollbar-track{background-color:#ddd}*::-webkit-scrollbar-corner{background-color:#ddd}*::-webkit-scrollbar{width:5px;height:5px}.ff-container{height:100%}.ff-loading{height:100vh;width:100%;background-color:#f0f2f5;display:flex;justify-content:center;align-items:center}.ff-loading .loader{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);width:128px;height:80px}.ff-loading .loader .square{position:relative}.ff-loading .loader .square:nth-child(1){margin-left:0}.ff-loading .loader .square:nth-child(1) span{-webkit-animation:animsquare1 2s infinite ease-in;animation:animsquare1 2s infinite ease-in}.ff-loading .loader .square:nth-child(2){margin-left:44px}.ff-loading .loader .square:nth-child(2) span{-webkit-animation:animsquare2 2s infinite ease-in;animation:animsquare2 2s infinite ease-in}.ff-loading .loader .square:nth-child(3){margin-left:88px}.ff-loading .loader .square:nth-child(3) span{-webkit-animation:animsquare3 2s infinite ease-in;animation:animsquare3 2s infinite ease-in}.ff-loading .loader .square:nth-child(4){margin-left:132px}.ff-loading .loader .square:nth-child(4) span{-webkit-animation:animsquare4 2s infinite ease-in;animation:animsquare4 2s infinite ease-in}.ff-loading .loader .square span{position:absolute;top:0;left:20px;height:36px;width:36px;border-radius:2px;background-color:#fff}.ff-loading .loader .square span:nth-child(1){top:0;-webkit-animation-delay:0s;animation-delay:0s}.ff-loading .loader .square span:nth-child(2){top:44px;-webkit-animation-delay:.15s;animation-delay:.15s}.ff-loading .loader .square span:nth-child(3){top:88px;-webkit-animation-delay:.3s;animation-delay:.3s}@media (max-width: 550px){.ff-loading .loader{-webkit-transform:scale(.75);transform:scale(.75)}}@media (max-width: 440px){.ff-loading .loader{-webkit-transform:scale(.5);transform:scale(.5)}}@keyframes animsquare4{0%,5%,95%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}30%,70%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare3{0%,10%,90%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}35%,65%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare2{0%,15%,85%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}40%,60%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}@keyframes animsquare1{0%,20%,80%,to{-webkit-transform:translate(0px,0px) rotate(0deg);transform:translate(0) rotate(0)}45%,55%{-webkit-transform:translate(40px,0px) rotate(90deg);transform:translate(40px) rotate(90deg)}}.ff-notification{position:fixed;z-index:2000;display:flex;max-height:100vh;padding:20px;align-items:flex-end;width:380px;overflow-x:hidden;overflow-y:clip;height:100vh;box-sizing:content-box;pointer-events:none;flex-direction:column;gap:24px}.ff-notification-top,.ff-notification-topLeft,.ff-notification-topRight{top:0}.ff-notification-bottom,.ff-notification-bottomRight,.ff-notification-bottomLeft{bottom:0}.ff-notification-bottomRight,.ff-notification-topRight{right:0}.ff-notification-notice{position:relative;display:block;box-sizing:border-box;line-height:1.5;width:100%}.ff-notification-notice-wrapper{z-index:2000;pointer-events:auto;position:relative;display:block;box-sizing:border-box;border-radius:8px;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d;width:calc(100% - 40px);background-color:#fff;right:0}.ff-notification-notice-content{padding:14px 18px;display:flex;gap:8px;white-space:pre-wrap}.ff-notification-notice-content .ff-notification-icon.ff-notification-error{--bg-color: #ff4d4f}.ff-notification-notice-content .ff-notification-icon.ff-notification-success{--bg-color: #52c41a}.ff-notification-notice-content .ff-notification-icon.ff-notification-info{--bg-color: #1677ff}.ff-notification-notice-content .ff-notification-icon>*:first-child{width:24px;height:24px;display:inline-flex;align-items:center;justify-content:center;border-radius:50%;color:#fff;background-color:var(--bg-color)}.ff-notification-notice-progress{position:absolute;left:3px;right:3px;border-radius:1px;overflow:hidden;-moz-appearance:none;appearance:none;-webkit-appearance:none;display:block;inline-size:100%;block-size:2px;border:0}.ff-notification-notice-progress,.ff-notification-notice-progress::-webkit-progress-bar{background-color:#0000000a}.ff-notification-notice-progress::-moz-progress-bar{background-color:#31afff}.ff-notification-notice-progress::-webkit-progress-value{background-color:#31afff}.ff-notification-fade{overflow:hidden;transition:all .3s}.ff-notification-fade-appear-prepare{pointer-events:none;opacity:0!important}.ff-notification-fade-appear-start{transform:translate(100%);opacity:0}.ff-notification-fade-appear-active{transform:translate(0);opacity:1}.ff-data-list-cell-editable:after{content:" ";display:block;position:absolute;width:0px;height:0px;bottom:0;right:0;border-style:solid;border-color:rgba(0,0,0,.45) transparent;border-width:0 0 var(--padding-xs, 8px) var(--padding-xs, 8px)}.ff-data-list-framework{height:100%;--sider-width: 280px;--col-num: 1;--col-width: 200px;--gap: 8px;display:flex;gap:var(--gap)}.ff-data-list-framework .ff-data-list-container{width:100%;height:100%;row-gap:var(--gap);display:flex;flex-direction:column}.ff-data-list-framework .ff-data-list-container .ff-data-list-content{flex:1;overflow-y:auto;padding:calc(var(--gap) / 2)}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item{display:flex;flex-direction:column;justify-content:space-between;row-gap:var(--gap);border-radius:4px;background-color:#fff;box-shadow:0 0 8px #00000014}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-container{padding:var(--gap)}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #f0f0f0;height:32px}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions .data-list-grid-layout-item-action{text-align:center;margin:2px 0;flex:1}.ff-data-list-framework .ff-data-list-container .ff-data-list-content .data-list-grid-layout-item .data-list-grid-layout-item-actions .data-list-grid-layout-item-action:not(:last-child){border-right:1px solid #f0f0f0}.ff-data-table-framework{height:100%;--sider-width: 280px;--col-num: 1;--gap: 8px;display:flex;gap:var(--gap)}.ff-data-table-framework .ff-data-table-container{width:100%;height:100%;display:flex;flex-direction:column;row-gap:var(--gap)}.ff-data-list-filter:has(.ff-data-list-filter-actions:not(.expanded)){height:60px;overflow-y:hidden}.ff-data-list-filter .ff-data-list-filter-default-form.ff-grid-layout-form{--grid-layout-cols: 25;--grid-layout-item-margin-x: 8px;--grid-layout-item-margin-y: 16px}.ff-data-list-filter .ff-data-list-filter-actions{grid-column:span var(--itemp-span, 5) / calc(var(--grid-layout-cols, 25) + 1)}.ff-data-list-filter .ff-data-list-filter-actions:not(.expanded){grid-row:1}.ff-data-list-filter .ff-data-list-filter-actions .ff-data-list-filter-expanded-button{margin-left:8px}.ff-data-list-filter .ff-data-list-filter-actions .ant-form-item-control-input-content{display:flex;justify-content:flex-end;align-items:center;gap:8px}.ff-data-list-footer{padding-block-start:8px;display:flex;justify-content:space-between}.ff-data-list-footer .ff-data-list-actions{display:flex;justify-content:center;gap:8px}.ff-data-list-sider{width:var(--sider-width, 280px);overflow-y:auto;box-shadow:8px 0 4px -8px #0000000d}.ff-data-list-sider+.ff-data-list-container{width:calc(100% - var(--sider-width, 280px))}.ff-data-list-toolbar{gap:8px;display:flex;justify-content:space-between;align-items:center}.ff-data-list-toolbar .ff-data-list-title{color:#000000e0;font-weight:600;font-size:14px}.ff-data-list-toolbar .ff-data-list-actions{display:flex;justify-content:center;gap:8px}.ff-data-list-toolbar .ff-data-list-tabs{cursor:pointer}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab{color:#00000073}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab:hover{font-weight:600}.ff-data-list-toolbar .ff-data-list-tabs .ff-data-list-tab.active{color:#1677ff;font-weight:600}.ff-data-list-empty{display:flex;align-items:center;justify-content:center}.ff-data-list-item-operations{max-width:180px;display:flex;flex-wrap:wrap;gap:var(--margin-xss, 4px)}.ff-data-list-item-operations>.ant-btn:not(.ant-btn-circle){flex-grow:1}.ff-data-list-helper{height:100%}.ff-data-list-table{height:100%;overflow-y:hidden}.ff-data-list-table .ant-table *{scrollbar-width:auto;scrollbar-color:auto}.ff-grid-layout{--grid-layout-h: 1;--grid-layout-row: none;--grid-layout-row-height: 18px;--grid-layout-row-height-offset: 0px;--grid-layout-cols: 12;display:grid;grid-template-columns:repeat(var(--grid-layout-cols),1fr);grid-auto-rows:minmax(min-content,max-content);padding:var(--grid-layout-container-padding-y, 0) var(--grid-layout-container-padding-x, 0);padding-bottom:calc(var(--grid-layout-container-padding-y, 0) + var(--grid-layout-item-margin-y));column-gap:var(--grid-layout-item-margin-x);row-gap:var(--grid-layout-item-margin-y)}.ff-grid-layout .grid-layout-item{grid-row:span var(--grid-layout-h, 1);grid-column:calc(var(--grid-layout-x, 1) + 1)/calc(var(--grid-layout-x, 1) + var(--grid-layout-w, 1) + 1);height:calc(var(--grid-layout-row-height) * var(--grid-layout-h) + var(--grid-layout-row-height-offset));padding:var(--grid-layout-box-paddin);margin:var(--grid-layout-box-margin);display:var(--grid-layout-box-display, flex);align-items:var(--grid-layout-box-align-items, center);justify-content:var(--grid-layout-box-justify-content, normal)}.ff-data-list-content{display:grid;gap:var(--gap, 8px);grid-template-columns:repeat(var(--col-num, 5),1fr);grid-auto-rows:min-content}.ff-data-list-content[style*=--col-width]{grid-template-columns:repeat(auto-fill,minmax(var(--col-width, 280px),1fr))}.ff-grid-layout-form{--grid-layout-h: 1;--grid-layout-row: none;--grid-layout-row-height: 18px;--grid-layout-row-height-offset: 0px;--grid-layout-cols: 12;display:grid;grid-template-columns:repeat(var(--grid-layout-cols),1fr);grid-auto-rows:minmax(min-content,max-content);padding:var(--grid-layout-container-padding-y, 0) var(--grid-layout-container-padding-x, 0);padding-bottom:calc(var(--grid-layout-container-padding-y, 0) + var(--grid-layout-item-margin-y, 16px));column-gap:var(--grid-layout-item-margin-x, 8px);row-gap:var(--grid-layout-item-margin-y, 16px)}.ff-grid-layout-form .grid-layout-item{grid-row:span var(--grid-layout-h, 1);grid-column:calc(var(--grid-layout-x, 1) + 1)/calc(var(--grid-layout-x, 1) + var(--grid-layout-w, 1) + 1);height:calc(var(--grid-layout-row-height) * var(--grid-layout-h) + var(--grid-layout-row-height-offset));padding:var(--grid-layout-box-padding-y, 0) var(--grid-layout-box-padding-x, 0);margin:var(--grid-layout-box-margin)}.ff-iconfont{transform:scale(1.14);vertical-align:-.125em;display:inline-flex;align-items:center;justify-content:center}.ff-iconfont:not(:last-child){margin-right:8px}.ff-popover-header{margin-bottom:calc(var(--margin-sm) / 2)}.ff-popover-header:empty{display:none}.ff-popover-footer{padding-top:12px}.ff-button.ant-btn-link,.ff-button.ant-btn-text{width:initial;padding:0;height:auto}.ff-default.ant-btn-link{color:#000000e0}.ant-btn-link.ant-btn:not(:disabled):focus-visible{outline:initial;outline-offset:initial;transition:initial}.ff-modal-form{display:flex;flex-direction:column;gap:var(--modal-form-gap, 8px)}.mask-motion-enter-active,.mask-motion-appear-active,.mask-motion-leave-active{transition:all .3s}.mask-motion-enter,.mask-motion-appear{opacity:0}.mask-motion-enter-active,.mask-motion-appear-active,.mask-motion-leave{opacity:1}.mask-motion-leave-active{opacity:0}.panel-motion-left-enter-start,.panel-motion-left-appear-start,.panel-motion-left-leave-start{transition:none!important}.panel-motion-left-enter-active,.panel-motion-left-appear-active,.panel-motion-left-leave-active{transition:all .3s}.panel-motion-left-enter,.panel-motion-left-appear{transform:translate(-100%)}.panel-motion-left-enter-active,.panel-motion-left-appear-active,.panel-motion-left-leave{transform:translate(0)}.panel-motion-left-leave-active{transform:translate(-100%)!important}.panel-motion-right-enter-start,.panel-motion-right-appear-start,.panel-motion-right-leave-start{transition:none!important}.panel-motion-right-enter-active,.panel-motion-right-appear-active,.panel-motion-right-leave-active{transition:all .3s}.panel-motion-right-enter,.panel-motion-right-appear{transform:translate(100%)}.panel-motion-right-enter-active,.panel-motion-right-appear-active,.panel-motion-right-leave{transform:translate(0)}.panel-motion-right-leave-active{transform:translate(100%)!important}.panel-motion-top-enter-start,.panel-motion-top-appear-start,.panel-motion-top-leave-start{transition:none!important}.panel-motion-top-enter-active,.panel-motion-top-appear-active,.panel-motion-top-leave-active{transition:all .3s}.panel-motion-top-enter,.panel-motion-top-appear{transform:translateY(-100%)}.panel-motion-top-enter-active,.panel-motion-top-appear-active,.panel-motion-top-leave{transform:translateY(0)}.panel-motion-top-leave-active{transform:translateY(-100%)!important}.panel-motion-bottom-enter-start,.panel-motion-bottom-appear-start,.panel-motion-bottom-leave-start{transition:none!important}.panel-motion-bottom-enter-active,.panel-motion-bottom-appear-active,.panel-motion-bottom-leave-active{transition:all .3s}.panel-motion-bottom-enter,.panel-motion-bottom-appear{transform:translateY(100%)}.panel-motion-bottom-enter-active,.panel-motion-bottom-appear-active,.panel-motion-bottom-leave{transform:translateY(0)}.panel-motion-bottom-leave-active{transform:translateY(100%)!important}.ff-drawer-mask{top:0;right:0;bottom:0;left:0;position:absolute;z-index:1050;pointer-events:auto;background-color:var(--popup-mask-bg-color, rgba(0, 0, 0, .45))}.ff-drawer{top:0;right:0;bottom:0;left:0;position:fixed;z-index:1050;pointer-events:none}.ff-drawer-close{top:14px;right:0}.ff-drawer-inline{position:absolute}.ff-drawer-left .ff-drawer-content-wrapper{inset:0 auto 0 0;box-shadow:6px 0 16px #00000014,3px 0 6px -4px #0000001f,9px 0 28px 8px #0000000d}.ff-drawer-right .ff-drawer-content-wrapper{inset:0 0 0 auto;box-shadow:-6px 0 16px #00000014,-3px 0 6px -4px #0000001f,-9px 0 28px 8px #0000000d}.ff-drawer-top .ff-drawer-content-wrapper{top:0;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d}.ff-drawer-bottom .ff-drawer-content-wrapper{bottom:0;box-shadow:0 -6px 16px #00000014,0 -3px 6px -4px #0000001f,0 -9px 28px 8px #0000000d}.ff-drawer-top .ff-drawer-content-wrapper,.ff-drawer-bottom .ff-drawer-content-wrapper{inset-inline:0}.ff-drawer-content{width:100%;height:100%;overflow:auto;background-color:var(--popup-bg-color, #fff);pointer-events:auto}.ff-drawer-header{padding:16px 8px;border-bottom:1px solid rgba(5,5,5,.06)}.ff-drawer-footer{border-top:1px solid rgba(5,5,5,.06);padding:12px 8px}.ff-drawer-body{padding:8px}.ff-drawer-content-wrapper{position:absolute;z-index:1050;overflow:hidden;transition:transform .3s;max-width:100vw}.ff-drawer-content-wrapper-hidden{display:none}.ff-modal-mask{position:fixed;top:0;right:0;left:0;bottom:0;pointer-events:auto;background-color:var(--popup-mask-bg-color, rgba(0, 0, 0, .45));height:100%;filter:alpha(opacity=50);z-index:1050}.ff-modal-mask-hidden{display:none}.ff-modal-fade-enter,.ff-modal-fade-appear{opacity:0;animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-play-state:paused}.ff-modal-fade-leave{animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-play-state:paused}.ff-modal-fade-enter.ff-modal-fade-enter-active,.ff-modal-fade-appear.ff-modal-fade-appear-active{animation-name:rcDialogFadeIn;animation-play-state:running}.ff-modal-fade-leave.ff-modal-fade-leave-active{animation-name:rcDialogFadeOut;animation-play-state:running}@keyframes rcDialogFadeIn{0%{opacity:0}to{opacity:1}}@keyframes rcDialogFadeOut{0%{opacity:1}to{opacity:0}}.ff-modal{position:relative;top:100px;width:fit-content;min-width:max(35vw,248px);padding:0;margin:0 auto}.ff-modal-close{position:absolute;top:14px;right:8px}.ff-modal-header:has(.ff-popup-title),.ff-modal-header:has(.ff-popup-sub-title){margin-bottom:8px}.ff-modal-footer:not(:empty){margin-top:12px}.ff-modal-wrap{position:fixed;overflow:auto;top:0;right:0;bottom:0;left:0;z-index:1050;-webkit-overflow-scrolling:touch;outline:0}.ff-modal-title{margin:0;font-size:14px;line-height:21px;font-weight:700}.ff-modal-content{position:relative;background-color:var(--popup-bg-color, #fff);border-radius:8px;background-clip:padding-box;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d;padding:20px 24px;max-height:calc(100vh - 150px)}.ff-modal-zoom-enter,.ff-modal-zoom-appear{opacity:0;animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.08,.82,.17,1);animation-play-state:paused}.ff-modal-zoom-leave{animation-duration:.3s;animation-fill-mode:both;animation-timing-function:cubic-bezier(.6,.04,.98,.34);animation-play-state:paused}.ff-modal-zoom-enter.ff-modal-zoom-enter-active,.ff-modal-zoom-appear.ff-modal-zoom-appear-active{animation-name:rcDialogZoomIn;animation-play-state:running}.ff-modal-zoom-leave.ff-modal-zoom-leave-active{animation-name:rcDialogZoomOut;animation-play-state:running}@keyframes rcDialogZoomIn{0%{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}@keyframes rcDialogZoomOut{0%{transform:scale(1)}to{opacity:0;transform:scale(0)}}.ff-popup-close{cursor:pointer;border:0;background:transparent;font-size:24px;position:absolute;line-height:1;color:#000;opacity:.5}.ff-popup-close:disabled{pointer-events:none}.ff-popup-close:hover{opacity:.65}.ff-popup{display:flex;flex-direction:column}.ff-popup-title,.ff-popup-sub-title{display:inline}.ff-popup-title{font-size:16px;font-weight:600}.ff-popup-footer{display:flex;gap:8px;justify-content:flex-end}.ff-popup-footer:empty{display:none}.ff-popup-reserved-extras,.ff-popup-extras,.ff-popup-actions{display:flex;align-items:center;gap:8px}.ff-popup-reserved-extras:empty,.ff-popup-extras:empty,.ff-popup-actions:empty{display:none}.ff-popup-actions{margin-left:auto}.ff-popup-body{flex:1;overflow-y:auto} diff --git a/dist/utils.js b/dist/utils.js index d72e605..e7db01d 100644 --- a/dist/utils.js +++ b/dist/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { d as s, f as i, e as g, h as m, b as o, k as P, c as p, j as d, i as h, m as k, r as f, t as u, u as l } from "./common/main-Dtr3vSp2.js"; +import { d as s, f as i, e as g, h as m, b as o, k as P, c as p, j as d, i as h, m as k, r as f, t as u, u as l } from "./common/main-BNMEkn4Y.js"; import "./common/vender-BkiRbACr.js"; export { s as deepSome, diff --git a/dist/virtual-fs.js b/dist/virtual-fs.js index 32d05a7..738d372 100644 --- a/dist/virtual-fs.js +++ b/dist/virtual-fs.js @@ -1,5 +1,5 @@ import "pathe"; -import { aD as o, aE as r } from "./common/main-Dtr3vSp2.js"; +import { aD as o, aE as r } from "./common/main-BNMEkn4Y.js"; export { o as default, r as toTreePaths diff --git a/package.json b/package.json index fe22c6a..7a47ab4 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "ff", "private": true, - "version": "0.6.26", + "version": "0.6.27", "author": "www.fsdpf.com", "type": "module", "main": "./dist/index.js",