From a7edde4966170eab01c5b0364838f95ad8e24465 Mon Sep 17 00:00:00 2001 From: what Date: Fri, 5 Sep 2025 16:15:44 +0800 Subject: [PATCH] v0.5.2 --- dist/button.js | 2 +- .../{main-BYs1V3cl.js => main-B7AQyHAp.js} | 324 +++++++++--------- 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/utils.js | 2 +- package.json | 2 +- 18 files changed, 179 insertions(+), 179 deletions(-) rename dist/common/{main-BYs1V3cl.js => main-B7AQyHAp.js} (89%) diff --git a/dist/button.js b/dist/button.js index 7de7bb0..ddb87a6 100644 --- a/dist/button.js +++ b/dist/button.js @@ -1,4 +1,4 @@ -import { a9 as s, a8 as u, aa as e } from "./common/main-BYs1V3cl.js"; +import { a9 as s, a8 as u, aa as e } from "./common/main-B7AQyHAp.js"; export { s as auth, u as default, diff --git a/dist/common/main-BYs1V3cl.js b/dist/common/main-B7AQyHAp.js similarity index 89% rename from dist/common/main-BYs1V3cl.js rename to dist/common/main-B7AQyHAp.js index 06dd0b8..5107259 100644 --- a/dist/common/main-BYs1V3cl.js +++ b/dist/common/main-B7AQyHAp.js @@ -1,9 +1,9 @@ -var Fn = Object.defineProperty; +var Rn = Object.defineProperty; var Ot = (e) => { throw TypeError(e); }; -var Rn = (e, t, n) => t in e ? Fn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n; -var v = (e, t, n) => Rn(e, typeof t != "symbol" ? t + "" : t, n), Lt = (e, t, n) => t.has(e) || Ot("Cannot " + n); +var On = (e, t, n) => t in e ? Rn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n; +var v = (e, t, n) => On(e, typeof t != "symbol" ? t + "" : t, n), Lt = (e, t, n) => t.has(e) || Ot("Cannot " + n); var y = (e, t, n) => (Lt(e, t, "read from private field"), n ? n.call(e) : t.get(e)), O = (e, t, n) => t.has(e) ? Ot("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), H = (e, t, n, i) => (Lt(e, t, "write to private field"), i ? i.call(e, n) : t.set(e, n), n); var jt = (e, t, n, i) => ({ set _(r) { @@ -14,21 +14,21 @@ var jt = (e, t, n, i) => ({ } }); import { jsx as u, jsxs as A } from "react/jsx-runtime"; -import k, { useEffect as V, useState as F, useCallback as X, useMemo as W, useRef as U, useContext as ce, useId as Ae, isValidElement as On, useLayoutEffect as Ln } from "react"; +import k, { useEffect as V, useState as F, useCallback as X, useMemo as W, useRef as U, useContext as ce, useId as Ae, isValidElement as Ln, useLayoutEffect as jn } from "react"; import w from "prop-types"; import M from "classnames"; import * as At from "react-is"; -import { useNotification as jn } from "rc-notification"; +import { useNotification as An } from "rc-notification"; import c from "lodash"; import te, { FieldContext as _t, Field as Gt } from "rc-field-form"; -import { N as Le, a as je, P as pt, S as An } from "./vender-C0IfHU5B.js"; +import { N as Le, a as je, P as pt, S as Vn } from "./vender-C0IfHU5B.js"; import Yt from "immutability-helper"; -import { Form as Xe, Input as Vn, Button as Ze, Pagination as In, Tree as Mn, Breadcrumb as zn, Table as Bn, Empty as qn, Popconfirm as Dn, Tooltip as Un, Popover as Wn } from "antd"; -import { useMergedState as Hn } from "rc-util"; -import { generatePath as Kn, useInRouterContext as Xt, useParams as Jn, useLocation as _n, createBrowserRouter as Gn, Navigate as Yn } from "react-router-dom"; +import { Form as Xe, Input as In, Button as Ze, Pagination as Mn, Tree as zn, Breadcrumb as Bn, Table as qn, Empty as Dn, Popconfirm as Un, Tooltip as Wn, Popover as Hn } from "antd"; +import { useMergedState as Kn } from "rc-util"; +import { generatePath as Jn, useInRouterContext as Xt, useParams as _n, useLocation as Gn, createBrowserRouter as Yn, Navigate as Xn } from "react-router-dom"; import "rc-util/lib/hooks/useMergedState"; -import Xn from "rc-drawer"; -import Qn from "rc-dialog"; +import Qn from "rc-drawer"; +import Zn from "rc-dialog"; var Te, Me, Ee, ue, ve, Se; class Qt { constructor(t, n) { @@ -60,7 +60,7 @@ class Qt { } } Te = new WeakMap(), Me = new WeakMap(), Ee = new WeakMap(), ue = new WeakMap(), ve = new WeakMap(), Se = new WeakMap(); -const lr = () => u("div", { children: "Empty" }), We = k.createContext({ ele: {}, mount: () => { +const cr = () => u("div", { children: "Empty" }), We = k.createContext({ ele: {}, mount: () => { }, unmount: () => { } }), G = ({ rootClassName: e, className: t, children: n, actions: i, title: r, subTitle: a, extras: o, style: s = {} }) => { const { mount: l, unmount: d } = k.useContext(We); @@ -70,12 +70,12 @@ const lr = () => u("div", { children: "Empty" }), We = k.createContext({ ele: {} return V(() => (t && i(e, k.createElement("div", { key: `ff-${e}`, className: M(`ff-popup-${e}`, n) }, t)), () => r(e)), [n, t]), null; }; G.Action = Ye("actions"), G.Title = Ye("title"), G.SubTitle = Ye("sub-title"), G.Extra = Ye("extras"), G.propTypes = { className: w.string, style: w.object, title: w.any, subTitle: w.any, actions: w.any, extras: w.any }; -const cr = () => u(G, { className: "ff-loading", children: A("div", { className: "loader", children: [A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] })] }) }), dr = () => u("div", { children: "NotFound" }), Zt = ({ children: e }) => { +const dr = () => u(G, { className: "ff-loading", children: A("div", { className: "loader", children: [A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] }), A("div", { className: "square", children: [u("span", {}), u("span", {}), u("span", {})] })] }) }), ur = () => u("div", { children: "NotFound" }), Zt = ({ children: e }) => { const [t, n] = F({}), i = X((a, o) => n((s) => ({ ...s, [a]: o })), []), r = X((a) => n((o) => ({ ...o, [a]: void 0 })), []); return typeof (e == null ? void 0 : e.type) == "string" ? e : u(We.Provider, { value: { ele: t, mount: i, unmount: r }, children: k.cloneElement(e, { className: t.rootClassName, title: t.title, subTitle: t["sub-title"], actions: t.actions, extras: t.extras }) }); }; Zt.propTypes = { children: w.element.isRequired }; -const Vt = { 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"] }, St = ({ type: e, props: t }) => u("i", { ...t, children: u("svg", { viewBox: "0 0 1024 1024", width: "1em", height: "1em", fill: "currentColor", children: (Vt[e] || Vt.info).map((n, i) => u("path", { d: n }, i)) }) }), en = ({ className: e, content: t, icon: n, $close: i }) => A(k.Fragment, { children: [n && u("div", { className: M("ff-notification-icon", e), children: u(St, { type: n }) }), t] }), Zn = ({}) => u(G, { children: "Confirm" }); +const Vt = { 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"] }, St = ({ type: e, props: t }) => u("i", { ...t, children: u("svg", { viewBox: "0 0 1024 1024", width: "1em", height: "1em", fill: "currentColor", children: (Vt[e] || Vt.info).map((n, i) => u("path", { d: n }, i)) }) }), en = ({ className: e, content: t, icon: n, $close: i }) => A(k.Fragment, { children: [n && u("div", { className: M("ff-notification-icon", e), children: u(St, { type: n }) }), t] }), ei = ({}) => u(G, { children: "Confirm" }); var pe, Fe; const ie = class ie { constructor() { @@ -87,13 +87,13 @@ const ie = class ie { }; pe = new WeakMap(), Fe = new WeakMap(), O(ie, pe, null), v(ie, "getInstance", () => (y(ie, pe) || H(ie, pe, new ie()), y(ie, pe))); let mt = ie; -const ei = mt.getInstance(), ti = (e, t, n = "children") => { +const ti = mt.getInstance(), ni = (e, t, n = "children") => { if (c.isEmpty(e)) return {}; const i = c.find(e, ["value", t]); if (!c.isEmpty(i)) return i; const r = e.length; for (let a = 0; a < r; a++) { - const { [n]: o } = e[a], s = ti(o, t, n); + const { [n]: o } = e[a], s = ni(o, t, n); if (!c.isEmpty(s)) return s; } return {}; @@ -169,16 +169,16 @@ const Ve = ht.getInstance(), It = { null2json: (e) => Object.create(), null2arra c.set(i, r, a); } return i; -}, {}), dt = (e, t) => e && typeof e == "object" ? Array.isArray(e) ? e.map((n) => dt(n, t)) : Object.keys(e).reduce((n, i) => (t[i] ? n[t[i]] = dt(e[i], t) : n[i] = dt(e[i], t), n), {}) : e, ur = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (e) => { +}, {}), dt = (e, t) => e && typeof e == "object" ? Array.isArray(e) ? e.map((n) => dt(n, t)) : Object.keys(e).reduce((n, i) => (t[i] ? n[t[i]] = dt(e[i], t) : n[i] = dt(e[i], t), n), {}) : e, gr = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (e) => { const t = 16 * Math.random() | 0; return (e === "x" ? t : 3 & t | 8).toString(16); -}), gr = (e) => { +}), pr = (e) => { var t, n; return e ? (n = (t = e.match(/^@pkg(?:[^\/]*\/){3}(?[^\/]+)/)) == null ? void 0 : t.groups) == null ? void 0 : n.name : ""; -}, pr = (e) => { +}, mr = (e) => { var t, n; return e ? (n = (t = e.match(/^@pkg(?:[^\/]*\/){2}(?[^\/]+)/)) == null ? void 0 : t.groups) == null ? void 0 : n.category : ""; -}, mr = (e) => { +}, hr = (e) => { var t, n; return e ? (n = (t = e.match(/^@pkg(?:[^\/]*\/){1}(?[^\/]+)/)) == null ? void 0 : t.groups) == null ? void 0 : n.owner : ""; }, sn = () => J.$index++; @@ -217,13 +217,13 @@ tt = new WeakMap(), Be = new WeakMap(), qe = new WeakMap(), nt = new WeakMap(), return ((r = i.default) == null ? void 0 : r.call(i, n)) || ((a) => a); }), (t, n) => `${t}::${ee(n, "string")}`)); let et = it; -const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, widgetByJsSetting: i, ...r }, a) => n ? { ...r, render: (o, s) => new et([n, i]).toRender(o, s, "-") } : r), [e, t]), hr = (e) => { +const ii = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, widgetByJsSetting: i, ...r }, a) => n ? { ...r, render: (o, s) => new et([n, i]).toRender(o, s, "-") } : r), [e, t]), fr = (e) => { const [t, n] = F({}); return V(() => { let i = !1; return e && j.get(`/api/_/${e}`).then((r) => c.pick(r, ["uuid", "name", "code", "resource", "marginX", "marginY", "cols", "rowHeight", "primaryKey", "columns", "itemOperations", "batchOperations", "isConditionFormLayout", "layout", "tabs", "pageSize", "layoutConfig"])).then((r) => !i && n(r)), () => i = !0; }, [e]), t; -}, fr = (e, t = {}) => { +}, yr = (e, t = {}) => { const [n, i] = F({ dataSource: [] }); return Ke(() => { let r = !1; @@ -235,12 +235,12 @@ const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, w }, ft = (e = [], t = /* @__PURE__ */ new Map(), n = [], i = "id", r) => { const a = X(r ? (o) => c.get(o, i, c.get(o, [r, i])) : (o) => c.get(o, i), [i, r]); return W(() => { - if (c.isEmpty(e) || !e.some(({ uuid: s }) => ei.check(s))) return !1; + if (c.isEmpty(e) || !e.some(({ uuid: s }) => ti.check(s))) return !1; if (c.isEmpty(t) || c.isEmpty(n)) return !0; const o = n.map((s) => a(s)); return e.some(({ uuid: s }) => !s || !t.has(s) || t.get(s).some((l) => o.some((d) => d == l))); }, [e, n, t, a]); -}, ii = (e, t, n = "id", i = null) => { +}, ri = (e, t, n = "id", i = null) => { const r = st(), a = U(!1), o = U(e.dataSource), s = U(e.itemOperationsAccess); return V(() => (o.current = e.dataSource, s.current = e.itemOperationsAccess, () => a.current = !1), [e.dataSource, e.itemOperationsAccess]), a.current && (e.dataSource = o.current, e.itemOperationsAccess = s.current), [e, (l = 0, d = null) => { var p, g; @@ -263,7 +263,7 @@ const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, w }); } }]; -}, ri = (e, t) => { +}, ai = (e, t) => { const n = st(), i = U(t), r = U(/* @__PURE__ */ new Map()), a = U([]), o = c.throttle((l) => { a.current = [], j.list(e, c.pick({ ...i.current, ...l }, ["tab", "page", "pageSize", "condition", "sider", "keyword"])).then(({ keyword: d, condition: p, total: g, tab: f, sider: m, page: h, pageSize: C, operationsAccess: b, dataSource: x }) => { i.current = { tab: f, condition: p, sider: m, keyword: d, total: g, pageSize: C, page: x != null && x.length ? h : 1 }, a.current = x, r.current = new Map(b), n(); @@ -272,14 +272,14 @@ const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, w ot(() => { a.current = [], e && o(t); }, [e, t]); - const s = W(() => c.pick(i.current, ["total", "tab", "page", "pageSize", "condition", "sider", "keyword", "payload"]), [i.current]); - return Object.assign(s, { onTabChange: (l) => o({ tab: l, page: 1 }), onPageChange: (l, d) => o({ page: l, pageSize: d }), onPageSizeChange: (l) => o({ pageSize: l, page: 1 }), onConditionChange: (l, d) => o({ keyword: d, condition: Yt(i.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 }); -}, ai = ({ listCode: e, className: t, layouts: n, dataSource: i, isPaginate: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: d, resource: p, primaryKey: g, title: f, itemGridLayout: m, $setting: h, tabs: C, isConditionFormLayout: b, isTreeSider: x, treeSiderConfig: N }) => { - const { classNames: P, onClickCallback: T } = ce(ne), I = on(l, d, g, p), D = X((z, L, R) => u(si, { className: M("ff-data-list-framework-item", P.item), operations: a ? I(L) : [], data: p ? { [p]: L } : L, children: z, onClickCallback: T }), [p, g, a, T, l, d]); - return A("div", { className: M("ff-data-list-framework", t), children: [u(n.sider, { isTreeSider: x, ...N }), A("div", { className: M("ff-data-list-container", P == null ? void 0 : P.container), children: [u(n.filter, { isConditionFormLayout: b }), u(n.toolbar, { title: f, tabs: C }), u(wi, { ...m, style: { "--col-num": (h == null ? void 0 : h.colNum) || 1 }, primaryKey: g, itemRender: D, dataSource: i }), u(n.footer, { isPaginate: r, isOperations: o, operations: s })] })] }); -}, si = ({ className: e, operations: t, children: n, data: i, onClickCallback: r }) => A("div", { className: M("data-list-grid-layout-item-container", e), children: [n, !!(t != null && t.length) && u("div", { className: "data-list-grid-layout-item-actions", children: t.map((a) => u("span", { className: "data-list-grid-layout-item-action", children: u(S.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: i, confirm: a.confirm, onAfterClick: (o) => o !== !1 && (r == null ? void 0 : r(a.isRefresh, i)) }, a.uuid || Ae()) }, (a == null ? void 0 : a.uuid) || Ae())) })] }), oi = ({ listCode: e, className: t, layouts: n, dataSource: i, columns: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: d, resource: p, primaryKey: g, title: f, tabs: m, isPaginate: h, isTreeSider: C, treeSiderConfig: b, isConditionFormLayout: x, ...N }) => { + const s = W(() => c.pick(i.current, ["total", "tab", "page", "pageSize", "condition", "sider", "keyword"]), [i.current]); + return Object.assign(s, { onTabChange: (l) => o({ tab: l, page: 1 }), onPageChange: (l, d) => o({ page: l, pageSize: d }), onPageSizeChange: (l) => o({ pageSize: l, page: 1 }), onConditionChange: (l, d) => o({ keyword: d, condition: Yt(i.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: t == null ? void 0 : t.payload }); +}, si = ({ listCode: e, className: t, layouts: n, dataSource: i, isPaginate: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: d, resource: p, primaryKey: g, title: f, itemGridLayout: m, $setting: h, tabs: C, isConditionFormLayout: b, isTreeSider: x, treeSiderConfig: N }) => { + const { classNames: P, onClickCallback: T } = ce(ne), I = on(l, d, g, p), D = X((z, L, R) => u(oi, { className: M("ff-data-list-framework-item", P.item), operations: a ? I(L) : [], data: p ? { [p]: L } : L, children: z, onClickCallback: T }), [p, g, a, T, l, d]); + return A("div", { className: M("ff-data-list-framework", t), children: [u(n.sider, { isTreeSider: x, ...N }), A("div", { className: M("ff-data-list-container", P == null ? void 0 : P.container), children: [u(n.filter, { isConditionFormLayout: b }), u(n.toolbar, { title: f, tabs: C }), u(bi, { ...m, style: { "--col-num": (h == null ? void 0 : h.colNum) || 1 }, primaryKey: g, itemRender: D, dataSource: i }), u(n.footer, { isPaginate: r, isOperations: o, operations: s })] })] }); +}, oi = ({ className: e, operations: t, children: n, data: i, onClickCallback: r }) => A("div", { className: M("data-list-grid-layout-item-container", e), children: [n, !!(t != null && t.length) && u("div", { className: "data-list-grid-layout-item-actions", children: t.map((a) => u("span", { className: "data-list-grid-layout-item-action", children: u(S.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: i, confirm: a.confirm, onAfterClick: (o) => o !== !1 && (r == null ? void 0 : r(a.isRefresh, i)) }, a.uuid || Ae()) }, (a == null ? void 0 : a.uuid) || Ae())) })] }), li = ({ listCode: e, className: t, layouts: n, dataSource: i, columns: r, isItemOperations: a, isBatchOperations: o, batchOperations: s, itemOperations: l, itemOperationsAccess: d, resource: p, primaryKey: g, title: f, tabs: m, isPaginate: h, isTreeSider: C, treeSiderConfig: b, isConditionFormLayout: x, ...N }) => { const { classNames: P, onClickCallback: T } = ce(ne), I = on(l, d, g, p), D = ft(l, d, i, g, p); - return A("div", { className: M("ff-data-table-framework", t), children: [u(n.sider, { isTreeSider: C, ...b }), A("div", { className: M("ff-data-table-container", P == null ? void 0 : P.container), children: [u(n.filter, { isConditionFormLayout: x }), u(n.toolbar, { title: f, tabs: m }), u(pi, { ...N, primaryKey: g, className: "ff-data-table-content", columns: r, dataSource: i, operationRender: D ? (z) => { + return A("div", { className: M("ff-data-table-framework", t), children: [u(n.sider, { isTreeSider: C, ...b }), A("div", { className: M("ff-data-table-container", P == null ? void 0 : P.container), children: [u(n.filter, { isConditionFormLayout: x }), u(n.toolbar, { title: f, tabs: m }), u(mi, { ...N, primaryKey: g, className: "ff-data-table-content", columns: r, dataSource: i, operationRender: D ? (z) => { var L; return u("div", { className: "ff-data-table-actions", children: (L = I(z)) == null ? void 0 : L.map((R, B) => u(S.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: z, confirm: R.confirm, onAfterClick: ($) => $ !== !1 && (T == null ? void 0 : T(R.isRefresh, z)) }, R.uuid || B)) }); } : null }), u(n.footer, { isPaginate: h, isOperations: o, operations: s })] })] }); @@ -295,7 +295,7 @@ const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, w } }), ln = (e, t, n, i, r = {}, a = 0) => { const o = { "--grid-layout-h": `${i}`, "--grid-layout-w": `${n}`, "--grid-layout-x": `${e}`, "--grid-layout-y": `${t}`, "--grid-layout-row-height-offset": "0px" }; return r != null && r.autoHeight ? o.height = "fit-content" : o["--grid-layout-row"] = `${i}`, 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"] = Mt(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"] = Mt(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; -}, Mt = (e, t, n, i) => `${e || 0}px ${t || 0}px ${n || 0}px ${i || 0}px`, yr = (e = "Text", t = "@pkg/ff/grid-layouts") => e != null && e.startsWith("@") || e != null && e.startsWith("blob:") ? e : `${t}/${e}`, cn = ({ className: e, isConditionFormLayout: t }) => { +}, Mt = (e, t, n, i) => `${e || 0}px ${t || 0}px ${n || 0}px ${i || 0}px`, wr = (e = "Text", t = "@pkg/ff/grid-layouts") => e != null && e.startsWith("@") || e != null && e.startsWith("blob:") ? e : `${t}/${e}`, cn = ({ className: e, isConditionFormLayout: t }) => { var f, m; const [n, i] = F({}), { listCode: r, onKeywordChange: a, onConditionChange: o, getBase62params: s, classNames: l } = k.useContext(ne), { keyword: d, condition: p } = (s == null ? void 0 : s()) || {}, [g] = Xe.useForm(); return V(() => { @@ -307,33 +307,33 @@ const ni = (e, t = {}) => W(() => e == null ? void 0 : e.map(({ widgetByJs: n, w }, [JSON.stringify([d, p])]), u("div", { className: M("ff-data-list-filter", l.filter, e), children: u(Xe, { form: g, layout: "vertical", autoComplete: "off", onFinish: ((f = n.fields) == null ? void 0 : f.length) > 1 ? (h) => o({ [n.resource]: h[n.resource] }, h.keyword) : () => { }, onValuesChange: (h) => { c.isEmpty(c.omit(h, ["keyword"])) || g.submit(); - }, children: ((m = n.fields) == null ? void 0 : m.length) > 1 ? u($t, { ...n, children: u(li, { onReset: () => { + }, children: ((m = n.fields) == null ? void 0 : m.length) > 1 ? u($t, { ...n, children: u(ci, { onReset: () => { const { keyword: h, condition: C } = s("init") || {}; g.setFieldsValue({ keyword: h, ...C }); - } }) }) : u("div", { className: "ff-data-list-filter-default-form ff-grid-layout-form", children: u("div", { className: "grid-layout-item", style: ln(20, 0, 5, 2), children: u(Xe.Item, { name: ["keyword"], children: u(Vn.Search, { allowClear: !0, enterButton: "搜索", placeholder: "多关键字 | 分割", onSearch: (h) => a(h) }) }) }) }) }) }); -}, li = ({ cols: e, fields: t, onReset: n }) => { + } }) }) : u("div", { className: "ff-data-list-filter-default-form ff-grid-layout-form", children: u("div", { className: "grid-layout-item", style: ln(20, 0, 5, 2), children: u(Xe.Item, { name: ["keyword"], children: u(In.Search, { allowClear: !0, enterButton: "搜索", placeholder: "多关键字 | 分割", onSearch: (h) => a(h) }) }) }) }) }) }); +}, ci = ({ cols: e, fields: t, onReset: n }) => { const [i, r] = F(!1), a = W(() => t == null ? void 0 : t.toReversed().some((o) => o.y > 1 || o.x + o.w >= e - 5), [e, t]); return A(Xe.Item, { label: " ", style: { "--item-span": 5 }, className: M("ff-data-list-filter-actions", { expanded: i }), children: [u(Ze, { onClick: n, children: "重置" }), u(Ze, { type: "primary", htmlType: "submit", children: "查询" }), a && u(S.Link, { className: "ff-data-list-filter-expanded-button", widget: () => r((o) => !o), type: "primary", name: i ? "关闭" : "展开", icon: i ? "icon-up" : "icon-down", iconPosition: "end" })] }); }; cn.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 ci = ({ className: e, operations: t, isOperations: n, isPaginate: i }) => { +const di = ({ className: e, operations: t, isOperations: n, isPaginate: i }) => { const { onPageChange: r, onPageSizeChange: a, onClickCallback: o, getBase62params: s } = k.useContext(ne), { total: l, page: d, pageSize: p } = (s == null ? void 0 : s()) || {}; - return n && !c.isEmpty(t) || i ? A("div", { className: M("ff-data-list-footer", e), children: [u("div", { className: "ff-data-list-actions", children: t == null ? void 0 : t.map((g, f) => u(S, { uuid: g.uuid, type: g.type, name: g.name, widget: g.widget, widgetType: g.widgetType, widgetProps: g.widgetProps, widgetData: g.widgetData, widgetSetting: g.widgetSetting, widgetContainerProps: g.widgetContainerSetting, onAfterClick: (m) => m !== !1 && (o == null ? void 0 : o(g.isRefresh, null)) }, g.uuid || f)) }), i && u(In, { size: "small", total: l, pageSize: p, showSizeChanger: !1, showTotal: (g) => `第 ${d} 页 / 总共 ${g} 条`, onChange: r, onShowSizeChange: a })] }) : null; -}, di = [{ 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: u("span", { style: { color: "#1677ff" }, children: "sss" }), key: "0-0-1-0" }] }] }], ui = ({ className: e, width: t = 280, isTreeSider: n }) => { + return n && !c.isEmpty(t) || i ? A("div", { className: M("ff-data-list-footer", e), children: [u("div", { className: "ff-data-list-actions", children: t == null ? void 0 : t.map((g, f) => u(S, { uuid: g.uuid, type: g.type, name: g.name, widget: g.widget, widgetType: g.widgetType, widgetProps: g.widgetProps, widgetData: g.widgetData, widgetSetting: g.widgetSetting, widgetContainerProps: g.widgetContainerSetting, onAfterClick: (m) => m !== !1 && (o == null ? void 0 : o(g.isRefresh, null)) }, g.uuid || f)) }), i && u(Mn, { size: "small", total: l, pageSize: p, showSizeChanger: !1, showTotal: (g) => `第 ${d} 页 / 总共 ${g} 条`, onChange: r, onShowSizeChange: a })] }) : null; +}, ui = [{ 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: u("span", { style: { color: "#1677ff" }, children: "sss" }), key: "0-0-1-0" }] }] }], gi = ({ className: e, width: t = 280, isTreeSider: n }) => { const { classNames: i } = ce(ne); - return n ? u(Mn.DirectoryTree, { className: M("ff-data-list-sider", i.sider, e), style: { "--sider-width": t }, showLine: !0, showIcon: !1, treeData: di }) : null; -}, gi = ({ className: e, title: t, tabs: n }) => { - const { getBase62params: i, onTabChange: r, onReload: a, classNames: o } = ce(ne), { tab: s } = (i == null ? void 0 : i()) || {}, [l, d] = Hn((n == null ? void 0 : n[0].value) ?? (n == null ? void 0 : n[0].code), { value: s, onChange: r }); - return A("div", { className: M("ff-data-list-toolbar", o.toolbar, e), children: [u("div", { className: "ff-data-list-title", children: t }), u(zn, { className: "ff-data-list-tabs", itemRender: ({ label: p, code: g, value: f }) => u("span", { onClick: () => d(f ?? g), className: M("ff-data-list-tab", { active: (f ?? g) == l }), children: p }), items: n }), A("div", { className: "ff-data-list-actions", children: [u(S.Link, { icon: "icon-reload", widget: () => a() }), u(S.Link, { icon: "icon-setting" })] })] }); + return n ? u(zn.DirectoryTree, { className: M("ff-data-list-sider", i.sider, e), style: { "--sider-width": t }, showLine: !0, showIcon: !1, treeData: ui }) : null; +}, pi = ({ className: e, title: t, tabs: n }) => { + const { getBase62params: i, onTabChange: r, onReload: a, classNames: o } = ce(ne), { tab: s } = (i == null ? void 0 : i()) || {}, [l, d] = Kn((n == null ? void 0 : n[0].value) ?? (n == null ? void 0 : n[0].code), { value: s, onChange: r }); + return A("div", { className: M("ff-data-list-toolbar", o.toolbar, e), children: [u("div", { className: "ff-data-list-title", children: t }), u(Bn, { className: "ff-data-list-tabs", itemRender: ({ label: p, code: g, value: f }) => u("span", { onClick: () => d(f ?? g), className: M("ff-data-list-tab", { active: (f ?? g) == l }), children: p }), items: n }), A("div", { className: "ff-data-list-actions", children: [u(S.Link, { icon: "icon-reload", widget: () => a() }), u(S.Link, { icon: "icon-setting" })] })] }); }, dn = ({ isItemGridLayout: e, theme: t, themeProps: n, onClickCallback: i, onReload: r, listCode: a, total: o = 0, page: s = 0, onPageChange: l, pageSize: d = 30, onPageSizeChange: p, tab: g, onTabChange: f, keyword: m, onKeywordChange: h, condition: C, onConditionChange: b, sider: x, onSiderChange: N, layouts: P, classNames: T = {}, payload: I = {}, ...D }) => { const [z, L] = F(), R = X(($, E) => { const K = { tab: g, page: s, pageSize: d, keyword: m, sider: x, condition: C, total: o, payload: I }; return $ && $ != "init" ? c.get(K, $, E) : K; }, [JSON.stringify(C), JSON.stringify(I), g, s, d, m, x, o]), B = W(() => { - let $ = { sider: ui, filter: cn, footer: ci, toolbar: gi }; + let $ = { sider: gi, filter: cn, footer: di, toolbar: pi }; P === !1 ? $ = { sider: null, filter: null, footer: null, toolbar: null } : c.isPlainObject(P) && ($ = Object.assign({}, $, P)); for (const E in $) if ($[E]) { - if (On($[E])) { + if (Ln($[E])) { const K = $[E]; $[E] = (de) => k.cloneElement(K, de); } @@ -344,7 +344,7 @@ const ci = ({ className: e, operations: t, isOperations: n, isPaginate: i }) => t ? le.getWidgetComponent(t).then(($) => { if (!$) throw `${t} not found`; return $; - }).catch(($) => ({ default: () => `${$}` })).then(($) => L(k.createElement($.default, { ...D, layouts: B, $setting: n }))) : L(u(e ? ai : oi, { ...D, layouts: B, $setting: n })); + }).catch(($) => ({ default: () => `${$}` })).then(($) => L(k.createElement($.default, { ...D, layouts: B, $setting: n }))) : L(u(e ? si : li, { ...D, layouts: B, $setting: n })); }, [t, n]), u(ne.Provider, { value: { classNames: T, listCode: a, onClickCallback: i, onReload: r, getBase62params: R, onPageChange: l, onPageSizeChange: p, onTabChange: f, onSiderChange: N, onKeywordChange: h, onConditionChange: b }, children: z && k.cloneElement(z, D) }); }; dn.propTypes = { classNames: w.exact({ sider: w.string, filter: w.string, footer: w.string, toolbar: w.string, container: w.string, content: w.string, item: w.string }), layouts: w.oneOfType([w.exact({ sider: w.oneOfType([w.elementType, w.element]), filter: w.oneOfType([w.elementType, w.element]), footer: w.oneOfType([w.elementType, w.element]), toolbar: w.oneOfType([w.elementType, w.element]) }), w.bool]) }; @@ -373,22 +373,22 @@ const ae = class ae { he = new WeakMap(), ge = new WeakMap(), Pe = new WeakMap(), rt = new WeakMap(), O(ae, he, null), v(ae, "getInstance", () => (y(ae, he) || H(ae, he, new ae()), y(ae, he))); let yt = ae; const un = yt.getInstance(), Pt = k.forwardRef(({ listCode: e, base62params: t, className: n, theme: i, themeProps: r, layouts: a, classNames: o }, s) => { - const [{ resource: l, primaryKey: d, batchOperations: p = [], itemOperations: g = [], columns: f = [], themeConfig: m, theme: h, isConditionFormLayout: C = !1, isTreeSider: b, treeSiderConfig: x, isItemGridLayout: N, itemGridLayout: P, title: T, isPaginate: I, tabs: D }, z] = F({ isItemGridLayout: !1, itemGridLayout: {} }), L = ri(e, t), [{ dataSource: R, itemOperationsAccess: B, condition: $, tab: E, keyword: K, page: de, total: $e, pageSize: Y, sider: _e, onConditionChange: lt, onTabChange: Ft, onKeywordChange: xn, onPageChange: vn, onPageSizeChange: Sn, onSiderChange: Pn, onReload: ct }, Rt] = ii(L, e, d, l), $n = ft(g, B, R, d), Nn = ft(p); + const [{ resource: l, primaryKey: d, batchOperations: p = [], itemOperations: g = [], columns: f = [], themeConfig: m, theme: h, isConditionFormLayout: C = !1, isTreeSider: b, treeSiderConfig: x, isItemGridLayout: N, itemGridLayout: P, title: T, isPaginate: I, tabs: D }, z] = F({ isItemGridLayout: !1, itemGridLayout: {} }), L = ai(e, t), [{ dataSource: R, itemOperationsAccess: B, condition: $, tab: E, keyword: K, page: de, total: $e, pageSize: Y, sider: _e, onConditionChange: lt, onTabChange: Ft, onKeywordChange: xn, onPageChange: vn, onPageSizeChange: Sn, onSiderChange: Pn, onReload: ct, payload: $n }, Rt] = ri(L, e, d, l), Nn = ft(g, B, R, d), Tn = ft(p); V(() => { let Q = null; - return e && j.get(`/api/_/${e}`).resp(({ data: Ge, res: En }) => { - Ge != null && Ge.isDynamicRefresh && (Q = un.subscribe(() => ct(), En)), z(Ge); + return e && j.get(`/api/_/${e}`).resp(({ data: Ge, res: Fn }) => { + Ge != null && Ge.isDynamicRefresh && (Q = un.subscribe(() => ct(), Fn)), z(Ge); }).catch(() => z({})), () => Q == null ? void 0 : Q(); }, [e]), k.useImperativeHandle(s, () => ({ onReload: ct, onClickCallback: Rt })); - const Tn = { listCode: e, title: T, classNames: o, layouts: a, resource: l, primaryKey: d, theme: i || h, themeProps: r || m, isTreeSider: b, treeSiderConfig: x, isPaginate: I, tabs: D, isItemOperations: $n, itemOperations: g == null ? void 0 : g.map((Q) => c.isEmpty(Q == null ? void 0 : Q.confirm) ? Q : { ...Q, confirm: Object.assign({}, Q.confirm, { getPopupContainer: () => document.body }) }), isBatchOperations: Nn, batchOperations: p, isItemGridLayout: N, columns: f, itemGridLayout: P, isConditionFormLayout: C, itemOperationsAccess: B, dataSource: R, onConditionChange: lt, onTabChange: Ft, onKeywordChange: xn, onPageChange: vn, onPageSizeChange: Sn, onSiderChange: Pn, condition: $, tab: E, keyword: K, page: de, total: $e, pageSize: Y, sider: _e }; - return u(dn, { ...Tn, className: M("ff-data-list-helper", n), onReload: ct, onClickCallback: Rt }); -}), gn = (e, t, n = !0) => n !== !0 && n-- <= 0 ? [] : c.isArray(e) && !c.isEmpty(e) ? e.reduce((i, r) => (Reflect.has(r, t) && Reflect.has(r, "children") && i.push(r[t]), Reflect.has(r, "children") && !c.isEmpty(r.children) ? i.concat(gn(r.children, t, n)) : i), []) : [], pi = ({ className: e, primaryKey: t, columns: n = [], dataSource: i = [], operationRender: r, operationWidth: a = 180, ...o }) => { + const En = { listCode: e, title: T, classNames: o, layouts: a, resource: l, primaryKey: d, theme: i || h, themeProps: r || m, isTreeSider: b, treeSiderConfig: x, isPaginate: I, tabs: D, isItemOperations: Nn, itemOperations: g == null ? void 0 : g.map((Q) => c.isEmpty(Q == null ? void 0 : Q.confirm) ? Q : { ...Q, confirm: Object.assign({}, Q.confirm, { getPopupContainer: () => document.body }) }), isBatchOperations: Tn, batchOperations: p, isItemGridLayout: N, columns: f, itemGridLayout: P, isConditionFormLayout: C, itemOperationsAccess: B, dataSource: R, onConditionChange: lt, onTabChange: Ft, onKeywordChange: xn, onPageChange: vn, onPageSizeChange: Sn, onSiderChange: Pn, condition: $, tab: E, keyword: K, page: de, total: $e, pageSize: Y, sider: _e, payload: $n }; + return u(dn, { ...En, className: M("ff-data-list-helper", n), onReload: ct, onClickCallback: Rt }); +}), gn = (e, t, n = !0) => n !== !0 && n-- <= 0 ? [] : c.isArray(e) && !c.isEmpty(e) ? e.reduce((i, r) => (Reflect.has(r, t) && Reflect.has(r, "children") && i.push(r[t]), Reflect.has(r, "children") && !c.isEmpty(r.children) ? i.concat(gn(r.children, t, n)) : i), []) : [], mi = ({ className: e, primaryKey: t, columns: n = [], dataSource: i = [], operationRender: r, operationWidth: a = 180, ...o }) => { const { classNames: s } = ce(ne); Ae(); const l = U(null), d = U(null), [p, g] = F([]), [f, m] = F({ width: 0, height: 0 }); V(() => { g(gn(i, t)); - }, [i, t]), Ln(() => { + }, [i, t]), jn(() => { const C = new ResizeObserver(() => { var b; m({ width: ((b = l.current) == null ? void 0 : b.nativeElement.querySelector(".ant-table-body").scrollWidth) || d.current.offsetWidth, height: d.current.offsetHeight }); @@ -397,10 +397,10 @@ const un = yt.getInstance(), Pt = k.forwardRef(({ listCode: e, base62params: t, d.current && C.unobserve(d.current); }; }, []); - const h = ni(n); - return u("div", { ref: d, className: M("ff-data-list-table", s.content, e), children: f.height ? u(Bn, { ...o, ref: l, rowKey: (C) => (C == null ? void 0 : C[t]) ?? Math.random(), columns: h == null ? void 0 : h.concat(r ? [{ title: "操作", align: "center", fixed: "right", width: `${Math.ceil(a / f.width * 100).toFixed(2)}%`, render: (C, b, x) => r(b, x) }] : []), dataSource: i, size: "middle", scroll: { x: "max-content", y: f.height - 50 }, pagination: !1, expandable: { defaultExpandAllRows: !0, expandRowByClick: !0, onExpandedRowsChange: g, expandedRowKeys: p } }) : null }); -}, mi = "RC_FORM_INTERNAL_HOOKS", hi = (e, { initialValue: t, initialValueLanguage: n, convertJs: i, convertJsSetting: r, type: a = "string" }, o = null) => { - const s = U(!1), l = ce(_t), [d, p] = F(), [g, f] = F(n != "javascript" && e ? l.getFieldValue(e) : void 0), { registerWatch: m } = l.getInternalHooks(mi) || {}; + const h = ii(n); + return u("div", { ref: d, className: M("ff-data-list-table", s.content, e), children: f.height ? u(qn, { ...o, ref: l, rowKey: (C) => (C == null ? void 0 : C[t]) ?? Math.random(), columns: h == null ? void 0 : h.concat(r ? [{ title: "操作", align: "center", fixed: "right", width: `${Math.ceil(a / f.width * 100).toFixed(2)}%`, render: (C, b, x) => r(b, x) }] : []), dataSource: i, size: "middle", scroll: { x: "max-content", y: f.height - 50 }, pagination: !1, expandable: { defaultExpandAllRows: !0, expandRowByClick: !0, onExpandedRowsChange: g, expandedRowKeys: p } }) : null }); +}, hi = "RC_FORM_INTERNAL_HOOKS", fi = (e, { initialValue: t, initialValueLanguage: n, convertJs: i, convertJsSetting: r, type: a = "string" }, o = null) => { + const s = U(!1), l = ce(_t), [d, p] = F(), [g, f] = F(n != "javascript" && e ? l.getFieldValue(e) : void 0), { registerWatch: m } = l.getInternalHooks(hi) || {}; return V(() => m == null ? void 0 : m((h, C, b) => { if (!s.current) return; const x = c.get(C, e); @@ -415,37 +415,37 @@ const un = yt.getInstance(), Pt = k.forwardRef(({ listCode: e, base62params: t, }, pn = (e, t, n = null) => W(() => { var i; return (i = c.sortBy(e, ["y", "x"])) == null ? void 0 : i.map(({ i: r, x: a, y: o, w: s, h: l, field: { boxStyle: d, ...p } }, g) => u("div", { className: "grid-layout-item", style: ln(a, o, s, l, d), children: u(t, { ...p, basicForm: n }) }, r ?? g)); -}, [e]), fi = ({ widget: e, widgetPrefix: t = "@pkg/ff/grid-layouts", basicForm: n, ...i }) => { +}, [e]), yi = ({ widget: e, widgetPrefix: t = "@pkg/ff/grid-layouts", basicForm: n, ...i }) => { const r = e != null && e.startsWith("@") || e != null && e.startsWith("blob:") ? e : `${t}/${e}`, [a, o] = F(); return V(() => { - r && le.getWidgetComponent(r).then(({ defaultProps: s = {}, default: l }) => ({ default: yi(l, s, n) })).catch((s) => ({ default: () => `${s}` })).then((s) => o(k.createElement(s.default, i))); + r && le.getWidgetComponent(r).then(({ defaultProps: s = {}, default: l }) => ({ default: wi(l, s, n) })).catch((s) => ({ default: () => `${s}` })).then((s) => o(k.createElement(s.default, i))); }, [r]), a; -}, yi = (e, t = {}, n = null) => (i) => { - const { code: r, label: a, extras: o, isVirtual: s, initialValue: l, initialValueLanguage: d, convertJs: p, convertJsSetting: g, value: f, ...m } = c.merge({}, t, i), [h, C] = hi(s ? null : r, { initialValue: l, initialValueLanguage: d, convertJs: p, convertJsSetting: g, type: (m == null ? void 0 : m.type) || "string" }, n), b = W(() => { +}, wi = (e, t = {}, n = null) => (i) => { + const { code: r, label: a, extras: o, isVirtual: s, initialValue: l, initialValueLanguage: d, convertJs: p, convertJsSetting: g, value: f, ...m } = c.merge({}, t, i), [h, C] = fi(s ? null : r, { initialValue: l, initialValueLanguage: d, convertJs: p, convertJsSetting: g, type: (m == null ? void 0 : m.type) || "string" }, n), b = W(() => { const P = Object.keys((t == null ? void 0 : t.extras) || {}); return c.over([c.partialRight(c.pick, P), c.partialRight(c.omit, P)]); }, [t == null ? void 0 : t.extras]), [x, N] = b(m); return u(e, { ...N, value: h, rawValue: C, $setting: Object.assign({}, o, x) }); }, mn = ({ className: e, cols: t = 12, rowHeight: n = 21, containerPadding: i = [0, 0], itemMargin: r = [4, 0], formProps: a = {}, fields: o = [], data: s, basicForm: l = null, ...d }) => { - const [p] = te.useForm(), g = pn(o, fi, l), f = W(() => [{ name: "__PROPS__", value: a }], [a]); + const [p] = te.useForm(), g = pn(o, yi, l), f = W(() => [{ name: "__PROPS__", value: a }], [a]); return Ke(() => (p.setFieldsValue(s), () => p.resetFields()), [s]), u(te, { fields: f, form: p, component: !1, children: u("div", { ...d, className: M("ff-grid-layout", e), style: { "--grid-layout-item-margin-y": `${(r == null ? void 0 : r[0]) || 0}px`, "--grid-layout-item-margin-x": `${(r == null ? void 0 : r[1]) || 0}px`, "--grid-layout-container-padding-y": `${(i == null ? void 0 : i[0]) || 0}px`, "--grid-layout-container-padding-x": `${(i == null ? void 0 : i[1]) || 0}px`, "--grid-layout-cols": t, "--grid-layout-row-height": `${n}px` }, children: g }) }); -}, wr = (zt = mn, function({ code: e, data: t, ...n }) { +}, br = (zt = mn, function({ code: e, data: t, ...n }) { const [i, r] = F({ resource: null, cols: 12, rowHeight: 21, fields: [] }); return V(() => { e && j.get(`/api/_/${e}`).then((a) => r(c.pick(a, ["resource", "cols", "rowHeight", "fields"]))); }, [e]), (i == null ? void 0 : i.resource) && u(zt, { ...n, rowHeight: i.rowHeight, cols: i.cols, fields: i.fields, data: i != null && i.resource ? { [i == null ? void 0 : i.resource]: t } : {} }); }); var zt; -const wi = ({ cols: e, rowHeight: t, itemMargin: n, fields: i, primaryKey: r, dataSource: a, itemClassName: o, itemRender: s = (g, f, m) => g, empty: l = u(qn, { description: null }), className: d, style: p = {} }) => { +const bi = ({ cols: e, rowHeight: t, itemMargin: n, fields: i, primaryKey: r, dataSource: a, itemClassName: o, itemRender: s = (g, f, m) => g, empty: l = u(Dn, { description: null }), className: d, style: p = {} }) => { const { classNames: g } = ce(ne), f = Ae(), m = W(() => u(mn, { cols: e, rowHeight: t, itemMargin: n, fields: i, className: o }), [i, e, t, n]); return u("div", { className: M("ff-data-list-content", g.content, d), style: p, children: c.isEmpty(a) ? l : a.map((h, C) => { const b = s(k.cloneElement(m, { data: h }), h, C); return k.cloneElement(b, { key: `${f}-${(h == null ? void 0 : h[r]) || C}` }); }) }); -}, bi = ({ component: e, $props: t }) => { +}, Ci = ({ component: e, $props: t }) => { const { base62params: n } = He(t, {}); return u(G, { children: u(Pt, { listCode: e, base62params: j.decode(n) }) }); -}, br = () => u(hn, {}), hn = () => "Empty", Ci = ({ component: e, $setting: t, $props: n }) => { +}, Cr = () => u(hn, {}), hn = () => "Empty", ki = ({ component: e, $setting: t, $props: n }) => { const [i, r] = F(); V(() => { if (!e) return r(u(hn, { description: null })); @@ -453,7 +453,7 @@ const wi = ({ cols: e, rowHeight: t, itemMargin: n, fields: i, primaryKey: r, da }, [e]); const a = He(n, {}); return i ? k.cloneElement(i, a) : null; -}, Cr = () => "NotFoundPage"; +}, kr = () => "NotFoundPage"; var fe, Z, ye, we, De, Ue; const se = class se { constructor() { @@ -466,7 +466,7 @@ const se = class se { v(this, "get", (t) => (y(this, Z).has(t) || (t = Array.from(y(this, Z).keys()).find((n) => y(this, Z).get(n).uri === t)), y(this, Z).get(t) || {})); v(this, "redirect", (t, n, i = {}) => { const { uri: r, type: a, widgetProps: o } = this.get(t) || {}; - let s = Kn(r || t, a != "list" ? n : c.mapValues(n, (d) => j.encode(d))); + let s = Jn(r || t, a != "list" ? n : c.mapValues(n, (d) => j.encode(d))); const l = new URLSearchParams(); for (const d in o || {}) (o == null ? void 0 : o.type) == "query" && l.append(d, n[d]); return l.size > 0 && (s = `${s}?${l.toString()}`), y(this, we).navigate(s, i); @@ -511,7 +511,7 @@ const se = class se { v(this, "getPageParams", (t) => { var r, a, o; let n = "", i = {}; - if (Xt()) i = Jn(), n = (r = _n()) == null ? void 0 : r.search; + if (Xt()) i = _n(), n = (r = Gn()) == null ? void 0 : r.search; else { const { location: s = {}, matches: l = [] } = ((a = y(this, we)) == null ? void 0 : a.state) || {}; i = ((o = l[l.length - 1]) == null ? void 0 : o.params) || {}, n = s.search; @@ -528,10 +528,10 @@ const se = class se { let N = {}, P = 0; switch (g) { case "list": - N.element = k.createElement(bi, { component: f, $props: h }); + N.element = k.createElement(Ci, { component: f, $props: h }); break; case "fsdpf-component": - N.element = k.createElement(Ci, { key: f, component: f, $setting: m, $props: h }); + N.element = k.createElement(ki, { key: f, component: f, $setting: m, $props: h }); } const T = (x == null ? void 0 : x.theme) ?? (x == null ? void 0 : x.layout); if (T) { @@ -541,14 +541,14 @@ const se = class se { } return b && P > -1 ? (s[P].children.push({ path: d, ...N }), s) : [...s, { path: d, ...N }]; }, [{ path: "/", lazy: a(n, {}), children: [] }]); - return o.push({ index: !0, element: k.createElement(ki, { to: i, replace: !0 }) }), H(this, we, Gn(o, t)); + return o.push({ index: !0, element: k.createElement(xi, { to: i, replace: !0 }) }), H(this, we, Yn(o, t)); }); if (y(se, fe)) return y(se, fe); } }; fe = new WeakMap(), Z = new WeakMap(), ye = new WeakMap(), we = new WeakMap(), De = new WeakMap(), Ue = new WeakMap(), O(se, fe, null), v(se, "getInstance", () => (y(se, fe) || H(se, fe, new se()), y(se, fe))); let wt = se; -const ki = ({ to: e, replace: t }) => Xt() ? k.createElement(Yn, { to: e, replace: t }) : (window.document.location = e, "redirect"), ke = wt.getInstance(), Ne = new Worker(new URL("/ff-worker/index.js", self.location)), Bt = { getConfigure: (e) => Ve.get(e), route: { redirect: (...e) => ke.redirect(...e), getPageParams: (...e) => ke.getPageParams(...e), getCurrentRoute: () => ke.getCurrentRoute() }, popup: { notification: (...e) => _.notification(...e), success: (...e) => _.success(...e), error: (...e) => _.error(...e), form: (...e) => _.form(...e), modal: (...e) => _.modal(...e), confirm: (...e) => _.confirm(...e) } }; +const xi = ({ to: e, replace: t }) => Xt() ? k.createElement(Xn, { to: e, replace: t }) : (window.document.location = e, "redirect"), ke = wt.getInstance(), Ne = new Worker(new URL("/ff-worker/index.js", self.location)), Bt = { getConfigure: (e) => Ve.get(e), route: { redirect: (...e) => ke.redirect(...e), getPageParams: (...e) => ke.getPageParams(...e), getCurrentRoute: () => ke.getCurrentRoute() }, popup: { notification: (...e) => _.notification(...e), success: (...e) => _.success(...e), error: (...e) => _.error(...e), form: (...e) => _.form(...e), modal: (...e) => _.modal(...e), confirm: (...e) => _.confirm(...e) } }; var at, Re, be; const q = class q { constructor() { @@ -559,7 +559,7 @@ const q = class q { })); v(this, "clear", (t) => Ne.postMessage({ session: t, category: "clear" })); if (y(q, be)) return y(q, be); - Promise.resolve().then(() => Hi).then((t) => { + Promise.resolve().then(() => Ki).then((t) => { Bt.http = t.http; }), Ne.addEventListener("message", ({ data: { id: t, task_id: n, method: i, args: r, category: a, data: o, error: s, session: l } }) => { if (a === "eval" && q.mQueue.has(t)) s !== null ? q.mQueue.get(t)[1](s) : q.mQueue.get(t)[0](o), y(q, Re).delete(t), q.mQueue.delete(t); @@ -582,12 +582,12 @@ let bt = q; const xe = bt.getInstance(), st = () => { const e = U(!0), [, t] = k.useReducer((n) => n + 1, 0); return V(() => () => e.current = !1, []), () => e.current && t(); -}, kr = (e) => { +}, xr = (e) => { const t = U(); return V(() => { t.current = e; }, [e]), t.current; -}, xr = (e) => { +}, vr = (e) => { const [t, n] = F(e), i = U(null), r = X((a, o) => { i.current = o, n(a); }, []); @@ -603,14 +603,14 @@ const xe = bt.getInstance(), st = () => { if (!Array.isArray(e)) return e; for (let i = 0; i < e.length; i++) e[i].value = ee((n = e[i]) == null ? void 0 : n.value, t), e[i] && Reflect.has(e[i], "children") && (e[i].children = fn(e[i].children, t)); return e; -}, vr = (e, t = "json", n = "string", i, r = null) => { +}, Sr = (e, t = "json", n = "string", i, r = null) => { const [a] = te.useForm(i), [o, s] = F([{ label: "无", value: "", disabled: !0 }]), l = U([]), d = te.useWatch((p) => l.current.length === 0 ? null : c.pick(p, l.current), a) || null; return V(() => { Array.isArray(e) ? s(e) : t === "javascript" && e ? xe.exec(e, {}, { getFieldValue: (p) => (l.current.includes(p) || l.current.push(p), a.getFieldValue(p)), getFieldValueForBasicForm: (p) => (l.current.includes(p) || l.current.push(p), r ? r.getFieldValue(p) : a.getFieldValue(p)) }).then((p) => { s(ee(p, "array")); }) : e && s(ee(e, "array")); }, [e, t, d]), fn(o, n); -}, Sr = (e) => { +}, Pr = (e) => { const [t, n] = F(), i = { type: "GET" }; if (typeof e == "string" ? i.url = e : c.isPlainObject(e) && Object.assign(i, e), !(i != null && i.url)) throw "url is required"; const r = (a) => j.request(i, !1).resp((o) => (console.log("useSubscribeRequest", a), n(o), o)); @@ -620,7 +620,7 @@ const xe = bt.getInstance(), st = () => { a = un.subscribe(c.throttle(r, 180, { leading: !1, trailing: !0 }), o.res); }), () => a == null ? void 0 : a(); }, i), t; -}, xi = (e) => { +}, vi = (e) => { const [t, n] = k.useState({ gridItems: [], hideItems: [] }); return k.useEffect(() => { e && j.get(`/api/_/${e}`).then(({ pk: i, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: d, marginX: p, marginY: g, listenChangeFields: f, listenChangeFieldsFunc: m, fields: h }) => ({ pk: i, uuid: r, code: a, resource: o, align: s, cols: l, rowHeight: d, marginX: p, marginY: g, listenChangeFields: f, listenChangeFieldsFunc: m, ...h.reduce((C, b) => { @@ -628,7 +628,7 @@ const xe = bt.getInstance(), st = () => { return (x = b == null ? void 0 : b.field) != null && x.hidden ? C.hides.push(b == null ? void 0 : b.field) : C.items.push(b), C; }, { items: [], hides: [] }) })).then(n); }, [e]), t; -}, vi = ({ max: e = 0, min: t = 0, type: n = "", message: i, pattern: r, required: a = !1, validator: o } = {}, s, l) => { +}, Si = ({ max: e = 0, min: t = 0, type: n = "", message: i, pattern: r, required: a = !1, validator: o } = {}, s, l) => { const [d, p] = F([]); return V(() => { const g = []; @@ -662,7 +662,7 @@ const xe = bt.getInstance(), st = () => { } p(g); }, [e, t, n, i, r, a, o]), d; -}, Si = (e, t, n) => { +}, Pi = (e, t, n) => { const [i, r] = F(null); return V(() => { const { initDataUri: a = `/api/${e}`, initDataMethod: o = "GET" } = n || {}; @@ -675,7 +675,7 @@ const xe = bt.getInstance(), st = () => { return ot(() => { e && xe.exec(e, n, { ...i, getFieldValueForBasicForm: (f) => r ? r.getFieldValue(f) : null, getFieldValue: c.wrap(a.getFieldValue, (f, m) => (l.current.some((h) => c.isEqual(h, m)) || (l.current.push(m), o()), f == null ? void 0 : f(m))), isFieldTouched: a.isFieldTouched, isFieldsTouched: a.isFieldsTouched }).then((f) => s.current && p(f)); }, [e, g, a, n, i]), V(() => () => s.current = !1, []), d; -}, Pi = (e, t, n = [], i = {}) => { +}, $i = (e, t, n = [], i = {}) => { const r = U({}); if (!t) return [e, r.current]; const a = U(), o = c.debounce(st(), 180), s = ["disabled", "required"], l = (g, f) => { @@ -687,7 +687,7 @@ const xe = bt.getInstance(), st = () => { e = tn(g, f), r.current = c.merge(m, c.pick(r.current, s)); } return [e, r.current]; -}, qt = (e) => e === void 0 || e === !1 ? "" : (Array.isArray(e) ? e : [e]).join("_"), Pr = ({ value: e, onChange: t }, n = null) => { +}, qt = (e) => e === void 0 || e === !1 ? "" : (Array.isArray(e) ? e : [e]).join("_"), $r = ({ value: e, onChange: t }, n = null) => { const i = U(), [r] = te.useForm(n), a = U({}); return ot(() => { c.isEqual(i.current, e) || r.setFieldsValue(e); @@ -704,18 +704,18 @@ const xe = bt.getInstance(), st = () => { } }, [r]), (o, s) => { i.current = s, t == null || t(s); }]; -}, $i = ({ type: e, initialValue: t, initialValueLanguage: n, onChange: i, basicForm: r }) => { +}, Ni = ({ type: e, initialValue: t, initialValueLanguage: n, onChange: i, basicForm: r }) => { const a = yn(n == "javascript" && t, n == "javascript" ? void 0 : t, {}, {}, r); return V(() => { n == "javascript" ? i(ee(a, e)) : t && i(ee(t, e)); }, [e, t, a]), null; }, wn = ({ widget: e = "Input", widgetPrefix: t = "@pkg/ff/grid-layout-forms", widgetDecorator: n, subWidgets: i = [], basicForm: r, ...a }) => { - const o = tn(e, t), [s, l] = Pi(o, n, i, r), [d, p] = F(); + const o = tn(e, t), [s, l] = $i(o, n, i, r), [d, p] = F(); return V(() => { - s && le.getWidgetComponent(s).then(({ defaultProps: g = {}, default: f }) => ({ default: Ni(f, g, r) })).catch((g) => ({ default: () => `${g}` })).then((g) => p(k.createElement(g.default, a))); + s && le.getWidgetComponent(s).then(({ defaultProps: g = {}, default: f }) => ({ default: Ti(f, g, r) })).catch((g) => ({ default: () => `${g}` })).then((g) => p(k.createElement(g.default, a))); }, [s]), d && k.cloneElement(d, { ...a, ...l }); -}, Ni = (e, t = {}, n = null) => (i) => { - const { type: r, code: a, label: o, noStyle: s, placeholder: l, required: d = !1, extras: p, validators: g, help: f, isVirtual: m, $isReserved: h, initialValue: C, initialValueLanguage: b, ...x } = c.omit(c.merge({}, t, i), ["convertJs", "convertJsSetting", "widget", "widgetPerfix", "widgetDecorator", "subWidgets", "boxStyle"]), N = vi(Object.assign({}, g, d ? { required: !0 } : {}), a, r), P = W(() => { +}, Ti = (e, t = {}, n = null) => (i) => { + const { type: r, code: a, label: o, noStyle: s, placeholder: l, required: d = !1, extras: p, validators: g, help: f, isVirtual: m, $isReserved: h, initialValue: C, initialValueLanguage: b, ...x } = c.omit(c.merge({}, t, i), ["convertJs", "convertJsSetting", "widget", "widgetPerfix", "widgetDecorator", "subWidgets", "boxStyle"]), N = Si(Object.assign({}, g, d ? { required: !0 } : {}), a, r), P = W(() => { const L = Object.keys((t == null ? void 0 : t.extras) || {}); return c.over([c.partialRight(c.pick, L), c.partialRight(c.omit, L)]); }, [t == null ? void 0 : t.extras]), [T, I] = P(x), D = { label: o, noStyle: s, colon: !1, layout: "vertical" }, z = X((L) => L == null ? void 0 : ee(L, r), [r]); @@ -728,25 +728,25 @@ const xe = bt.getInstance(), st = () => { return A("div", { className: "ff-grid-layout-form", style: { "--grid-layout-item-margin-x": `${(n == null ? void 0 : n[0]) ?? 8}px`, "--grid-layout-item-margin-y": `${(n == null ? void 0 : n[1]) ?? 16}px`, "--grid-layout-container-padding-y": `${(i == null ? void 0 : i[0]) || 0}px`, "--grid-layout-container-padding-x": `${(i == null ? void 0 : i[1]) || 0}px`, "--grid-layout-cols": e, "--grid-layout-row-height": `${t}px` }, children: [s, a && k.cloneElement(a, { cols: e, rowHeight: t, itemMargin: n, containerPadding: i, fields: r })] }); }; $t.propTypes = { fields: w.array }; -const Ti = (Dt = $t, ({ code: e, layout: t, name: n, primaryKey: i = 0, style: r = {}, formProps: a = {}, form: o, basicForm: s, isPreview: l = !1, className: d, onFinish: p, onValuesChange: g = () => { +const Ei = (Dt = $t, ({ code: e, layout: t, name: n, primaryKey: i = 0, style: r = {}, formProps: a = {}, form: o, basicForm: s, isPreview: l = !1, className: d, onFinish: p, onValuesChange: g = () => { }, ...f }) => { - const { align: m, autoComplete: h, resource: C, items: b, hides: x, rowHeight: N, marginX: P, marginY: T, cols: I, listenChangeFields: D, listenChangeFieldsFunc: z, pk: L, uuid: R } = xi(e), [B] = te.useForm(o), $ = W(() => [{ name: "__PK__", value: L }, { name: "__PROPS__", value: a }, { name: "__RESOURCE__", value: C }, { name: "__LAYOUT_KEY__", value: e }, { name: "__LAYOUT_UUID__", value: R }, { name: "__PRIMARY_KEY__", value: i }], [L, e, R, C, i, a]); + const { align: m, autoComplete: h, resource: C, items: b, hides: x, rowHeight: N, marginX: P, marginY: T, cols: I, listenChangeFields: D, listenChangeFieldsFunc: z, pk: L, uuid: R } = vi(e), [B] = te.useForm(o), $ = W(() => [{ name: "__PK__", value: L }, { name: "__PROPS__", value: a }, { name: "__RESOURCE__", value: C }, { name: "__LAYOUT_KEY__", value: e }, { name: "__LAYOUT_UUID__", value: R }, { name: "__PRIMARY_KEY__", value: i }], [L, e, R, C, i, a]); return A(te, { className: d, name: n || e, layout: t || m, fields: $, form: B, autoComplete: h, style: { ...r, position: "relative" }, onFinish: p, onValuesChange: (E, K) => (({ changedValues: de, allValues: $e, listenChangeFields: Y, listenChangeFieldsFunc: _e, onValuesChange: lt, code: Ft }) => { lt(de, $e), _e && Array.isArray(Y) && xe.exec(_e, { changedValues: de, allValues: $e }, { getFieldValue: B.getFieldValue, setFieldValue: B.setFieldValue, setFieldsValue: B.setFieldsValue, isFieldTouched: B.isFieldTouched, isFieldsTouched: B.isFieldsTouched }); })({ changedValues: E, allValues: K, listenChangeFields: D, listenChangeFieldsFunc: z, onValuesChange: g, code: e }), children: [u(Dt, { ...f, form: B, basicForm: s, code: e, fields: b, cols: I, rowHeight: N, itemMargin: [P, T] }), x == null ? void 0 : x.map((E) => { var K; - return u(Gt, { name: E.code, children: u($i, { form: B, basicForm: s, name: E.code, type: E.type, initialValue: E.initialValue, initialValueLanguage: (K = E.extras) == null ? void 0 : K.initialValueLanguage }) }, JSON.stringify(E.code)); + return u(Gt, { name: E.code, children: u(Ni, { form: B, basicForm: s, name: E.code, type: E.type, initialValue: E.initialValue, initialValueLanguage: (K = E.extras) == null ? void 0 : K.initialValueLanguage }) }, JSON.stringify(E.code)); })] }, e); }); var Dt; const bn = ({ $setting: e, $close: t, extras: n, code: i, primaryKey: r, ...a }) => { - const [o] = te.useForm(), s = Si(i, r, e); + const [o] = te.useForm(), s = Pi(i, r, e); return V(() => { s && o.setFieldsValue(s); }, [s]), u(G, { actions: A(k.Fragment, { children: [u(S, { name: "保存", type: "primary", widget: () => { const l = o.getFieldValue("__RESOURCE__"), { initDataUri: d = `/api/${i}` } = e || {}; o.validateFields(!0).then((p) => l ? c.pick(p, [l]) : p).then((p) => j.post(r ? `${d}/${r}` : `${d}`, p).msg(t)).catch(() => _.error("请先完善表单信息", { duration: 2e3 })); - } }), u(S, { name: "取消", widget: () => t(!1) })] }), extras: n, children: u(Ti, { form: o, code: i, primaryKey: r, ...a }) }); + } }), u(S, { name: "取消", widget: () => t(!1) })] }), extras: n, children: u(Ei, { form: o, code: i, primaryKey: r, ...a }) }); }, Ut = /* @__PURE__ */ new Set(), Ct = (e = [], t = 0) => { const n = e[t]; if (n.length && !Ut.has(n)) { @@ -759,10 +759,10 @@ const bn = ({ $setting: e, $close: t, extras: n, code: i, primaryKey: r, ...a }) } }, kt = ({ className: e, type: t, style: n = {}, ...i }) => u("span", { role: "img", className: M("ff-iconfont", e), style: n, ...i, children: u("svg", { style: { width: "1em", height: "1em", fill: "currentColor", overflow: "hidden" }, viewBox: "0 0 1024 1024", children: u("use", { xlinkHref: `#${t}` }) }) }); kt.propTypes = { className: w.string, type: w.string.isRequired, style: w.object }, kt.init = Ct; -const Ei = (e, t, n, i) => { +const Fi = (e, t, n, i) => { const { isReplaceRouteHistory: r = !1 } = i || {}; return ke.redirect(n, t, { replace: r }); -}, Fi = (e, t = {}, n, i = {}) => { +}, Ri = (e, t = {}, n, i = {}) => { var a; const r = (a = i.router) == null ? void 0 : a.reduce((o, [s, l, d]) => { const p = c.get(t, ["router", s]); @@ -775,21 +775,21 @@ const Ei = (e, t, n, i) => { return c.isFunction(n) ? n.call(null, { ...t, ...o }) : c.isString(n) && n ? xe.exec(n, t, o) : null; }, Ht = (e, t, n, i, r) => c.isString(n) && n ? le.getWidgetComponent(n).then(({ default: a }) => _.modal(a, { ...t, $setting: i }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r)).catch((a) => { _.error(n, { content: a.toString() }); -}) : _.modal(n, { ...t, $setting: i }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), Ri = (e, t, n, i, r) => _.modal(bn, { ...t, $setting: i, code: n }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), Oi = (e, t, n, i, r) => _.modal(Pt, { base62params: t, $setting: i, listCode: n }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), Li = ({ widget: e, widgetType: t, widgetData: n, widgetProps: i, widgetSetting: r, widgetContainerProps: a }, { onAfterClick: o, onBeforeClick: s }) => { +}) : _.modal(n, { ...t, $setting: i }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), Oi = (e, t, n, i, r) => _.modal(bn, { ...t, $setting: i, code: n }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), Li = (e, t, n, i, r) => _.modal(Pt, { base62params: t, $setting: i, listCode: n }, r != null && r.title ? { ...r, title: c.template(r.title)(e) } : r), ji = ({ widget: e, widgetType: t, widgetData: n, widgetProps: i, widgetSetting: r, widgetContainerProps: a }, { onAfterClick: o, onBeforeClick: s }) => { const l = ce(ne), [d, p] = F({ leading: !0, trailing: !1 }), g = W(() => { switch (t) { case "redirect": - return c.partialRight(Ei, e, r); + return c.partialRight(Fi, e, r); case "func": return c.partialRight(Wt, (r == null ? void 0 : r.code) ?? e, { status: d, setStatus: p }); case "fsdpf-component": return c.partialRight(Ht, e, r, a); case "grid-layout-form": - return c.partialRight(Ri, e, r, a); - case "data-list": return c.partialRight(Oi, e, r, a); + case "data-list": + return c.partialRight(Li, e, r, a); case "destroy": - return c.partialRight(Fi, e, r, a); + return c.partialRight(Ri, e, r, a); default: if (Et(e) || k.isValidElement(e)) return c.partialRight(Ht, e, r, a); if (c.isFunction(e)) return c.partialRight(Wt, (r == null ? void 0 : r.code) || e, { status: d, setStatus: p }); @@ -802,18 +802,18 @@ const Ei = (e, t, n, i) => { return e === "danger" ? s.danger = !0 : e === "default" && (s.type = e), o === "link" || o === "dashed" ? (s.type = o, e === "default" && (s.className = M(s.className, "ff-default"))) : o !== "circle" && o !== "round" || (s.shape = o), i && (s.icon = u(kt, { type: i })), t && (s.children = t), s; }, [o, e, n, i, r]), Je = (e) => function({ className: t, variant: n, children: i, name: r, icon: a, type: o = "default", iconPosition: s = "start", noAuthType: l, onAfterClick: d, onBeforeClick: p, data: g, loading: f, disabled: m, tooltip: h, confirm: C, widget: b = () => { }, widgetType: x, widgetData: N, widgetProps: P, widgetSetting: T, widgetContainerProps: I, ...D }) { - const z = W(() => sn(), []), L = c.isEmpty(h) || !h.enabled ? {} : h, R = c.isEmpty(C) ? { enabled: !1 } : Object.assign({ enabled: !0 }, C), B = Cn({ className: t, name: r, type: o, icon: a, iconPosition: s }, n ?? e), [$, E] = F(!1), [K, { disabled: de, loading: $e }] = Li({ widget: b, widgetType: x, widgetData: N, widgetProps: P, widgetSetting: T, widgetContainerProps: I }, { onAfterClick: d, onBeforeClick: p }); - return u(Dn, { zIndex: z, okText: "确定", cancelText: "取消", getPopupContainer: (Y) => Y, ...R, disabled: de || m, open: $, onOpenChange: (Y) => { + const z = W(() => sn(), []), L = c.isEmpty(h) || !h.enabled ? {} : h, R = c.isEmpty(C) ? { enabled: !1 } : Object.assign({ enabled: !0 }, C), B = Cn({ className: t, name: r, type: o, icon: a, iconPosition: s }, n ?? e), [$, E] = F(!1), [K, { disabled: de, loading: $e }] = ji({ widget: b, widgetType: x, widgetData: N, widgetProps: P, widgetSetting: T, widgetContainerProps: I }, { onAfterClick: d, onBeforeClick: p }); + return u(Un, { zIndex: z, okText: "确定", cancelText: "取消", getPopupContainer: (Y) => Y, ...R, disabled: de || m, open: $, onOpenChange: (Y) => { if (!Y) return E(Y); R.enabled ? E(Y) : K(g); }, onConfirm: () => { K(g); }, onClick: (Y) => { Y.stopPropagation(); - }, children: u(Un, { zIndex: z, getPopupContainer: (Y) => Y, ...L, title: $ ? null : L == null ? void 0 : L.title, trigger: ["hover", "click"], children: u(Ze, { loading: $e || f, disabled: de || m, ...B, ...D, children: i || r }) }) }); + }, children: u(Wn, { zIndex: z, getPopupContainer: (Y) => Y, ...L, title: $ ? null : L == null ? void 0 : L.title, trigger: ["hover", "click"], children: u(Ze, { loading: $e || f, disabled: de || m, ...B, ...D, children: i || r }) }) }); }, S = Je("default"); S.propTypes = { type: w.oneOf(["primary", "default", "danger", ""]), size: w.oneOf(["large", "middle", "small"]), name: w.string, icon: w.string, iconPosition: w.oneOf(["start", "end"]), data: w.any, widget: w.any, widgetType: w.oneOf(["destroy", "redirect", "func", "fsdpf-component", "grid-layout-form", "grid-layout", "data-list"]), widgetData: w.object, widgetProps: w.object, widgetSetting: w.object, widgetContainerProps: w.object, tooltip: w.exact({ title: w.string.isRequired, placement: w.oneOf(["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight", "leftTop", "leftBottom", "rightTop", "rightBottom"]), enabled: w.oneOfType([w.bool, w.number]), getPopupContainer: w.func }), confirm: w.exact({ title: w.string.isRequired, cancelText: w.string, okText: w.string, okType: w.oneOf(["primary", "default", "danger", ""]), placement: w.oneOf(["top", "left", "right", "bottom", "topLeft", "topRight", "bottomLeft", "bottomRight", "leftTop", "leftBottom", "rightTop", "rightBottom"]), enabled: w.oneOfType([w.bool, w.number]), getPopupContainer: w.func, arrow: w.oneOfType([w.bool, w.exact({ pointAtCenter: w.bool })]) }) }; -const ji = Je("link"), Ai = Je("circle"), Vi = Je("round"), Ii = Je("dashed"), Nt = ({ data: e, widget: t, widgetType: n = "fsdpf-component", widgetData: i, widgetProps: r, widgetSetting: a, widgetContainerProps: o, onAfterClick: s, onBeforeClick: l, children: d, extras: p }) => { +const Ai = Je("link"), Vi = Je("circle"), Ii = Je("round"), Mi = Je("dashed"), Nt = ({ data: e, widget: t, widgetType: n = "fsdpf-component", widgetData: i, widgetProps: r, widgetSetting: a, widgetContainerProps: o, onAfterClick: s, onBeforeClick: l, children: d, extras: p }) => { const g = W(() => sn(), []), f = ce(ne), [m, h] = F(!1), [C, b] = F("hover"), [x, N] = F({}), [P, T] = F(), { placement: I, align: D, arrow: z = { pointAtCenter: !0 }, getPopupContainer: L, ...R } = o || {}; V(() => { n == "grid-layout-form" ? T(k.createElement(bn, { ...i, $setting: a, code: t })) : n == "data-list" ? T(k.createElement(Pt, { base62params: e, $setting: a, listCode: t })) : c.isString(t) ? le.getWidgetComponent(t).then(({ default: E }) => { @@ -825,8 +825,8 @@ const ji = Je("link"), Ai = Je("circle"), Vi = Je("round"), Ii = Je("dashed"), N const B = (E, K = !1) => (h(E), !E && b("hover"), E ? l == null ? void 0 : l(x) : s == null ? void 0 : s(K)), $ = (E) => { h(!0), b("click"); }; - return u(Wn, { zIndex: g, placement: I, onPopupClick: $, onClick: $, open: m, align: D, arrow: z, trigger: C, getPopupContainer: L, content: u(Mi, { ...R, extras: p, children: P && k.cloneElement(P, { ...x, $close: (E) => B(!1, E) }) }), children: d, onOpenChange: B }); -}, Mi = ({ title: e, className: t, children: n, extras: i, width: r, height: a, ...o }) => { + return u(Hn, { zIndex: g, placement: I, onPopupClick: $, onClick: $, open: m, align: D, arrow: z, trigger: C, getPopupContainer: L, content: u(zi, { ...R, extras: p, children: P && k.cloneElement(P, { ...x, $close: (E) => B(!1, E) }) }), children: d, onOpenChange: B }); +}, zi = ({ title: e, className: t, children: n, extras: i, width: r, height: a, ...o }) => { const [s, l] = F({}), d = X((m, h) => l((C) => ({ ...C, [m]: h })), []), p = X((m) => l((h) => ({ ...h, [m]: void 0 })), []), g = e ? k.createElement("div", { className: "ff-popup-title" }, e) : s == null ? void 0 : s.title, f = i ?? k.createElement("div", { className: "ff-popup-reserved-extras" }, i); return u(We.Provider, { value: { ele: s, mount: d, unmount: p }, children: A("div", { className: M("ff-popup ff-popover", t, s.rootClassName), style: { width: r, height: a }, ...o, children: [A("div", { className: "ff-popup-header", children: [g, s == null ? void 0 : s["sub-title"]] }), n, A("div", { className: "ff-popup-footer", children: [f, s == null ? void 0 : s.extras, s == null ? void 0 : s.actions] })] }) }); }; @@ -843,24 +843,24 @@ const Kt = ({ options: e = [], triggerWeights: t = ["grid-layout-form", "grid-la const C = h.map((b) => d(Object.assign({ uuid: b.uuid, type: b.type, name: b.name, widget: b.widget, widgetType: b.widgetType, widgetProps: b.widgetProps, widgetData: b.widgetData, widgetSetting: b.widgetSetting, widgetContainerProps: b.widgetContainerSetting, confirm: b.confirm, onAfterClick: c.partialRight(n, b, f), onBeforeClick: c.partialRight(i, b, f) }, { size: l, variant: s }), f)); return u(Nt, { widget: m == null ? void 0 : m.widget, widgetType: m == null ? void 0 : m.widgetType, widgetProps: m == null ? void 0 : m.widgetProps, widgetSetting: m == null ? void 0 : m.widgetSetting, widgetContainerProps: Object.assign({}, p, m == null ? void 0 : m.widgetContainerProps), data: f, widgetData: m == null ? void 0 : m.widgetData, extras: C, onAfterClick: c.partialRight(n, m, f), onBeforeClick: c.partialRight(i, m, f), children: g }); }; -Kt.propTypes = { triggerWeights: w.array, options: w.arrayOf(w.shape({ ...S.propTypes, widgetType: S.propTypes.widgetType.isRequired })), btnSize: S.propTypes.size, btnRender: w.func, btnVariant: w.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelVariant: w.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelRender: w.func, labelSize: S.propTypes.size, onAfterClick: w.func, onBeforeClick: w.func, widgetContainerProps: S.propTypes.widgetContainerProps, data: S.propTypes.data }, S.Link = ji, S.Link.defaultProps = S.defaultProps, S.Link.propTypes = S.propTypes, S.Circle = Ai, S.Circle.defaultProps = S.defaultProps, S.Circle.propTypes = S.propTypes, S.Round = Vi, S.Round.defaultProps = S.defaultProps, S.Round.propTypes = S.propTypes, S.Dashed = Ii, S.Dashed.defaultProps = S.defaultProps, S.Dashed.propTypes = S.propTypes, S.Popover = Nt, S.GroupPopover = Kt; -const zi = ({ fields: e, formProps: t, $close: n }) => { +Kt.propTypes = { triggerWeights: w.array, options: w.arrayOf(w.shape({ ...S.propTypes, widgetType: S.propTypes.widgetType.isRequired })), btnSize: S.propTypes.size, btnRender: w.func, btnVariant: w.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelVariant: w.oneOf(["", "default", "link", "circle", "round", "dashed"]), labelRender: w.func, labelSize: S.propTypes.size, onAfterClick: w.func, onBeforeClick: w.func, widgetContainerProps: S.propTypes.widgetContainerProps, data: S.propTypes.data }, S.Link = Ai, S.Link.defaultProps = S.defaultProps, S.Link.propTypes = S.propTypes, S.Circle = Vi, S.Circle.defaultProps = S.defaultProps, S.Circle.propTypes = S.propTypes, S.Round = Ii, S.Round.defaultProps = S.defaultProps, S.Round.propTypes = S.propTypes, S.Dashed = Mi, S.Dashed.defaultProps = S.defaultProps, S.Dashed.propTypes = S.propTypes, S.Popover = Nt, S.GroupPopover = Kt; +const Bi = ({ fields: e, formProps: t, $close: n }) => { const [i] = te.useForm(), r = W(() => [{ name: "__PROPS__", value: t }], [t]); return u(G, { actions: A(k.Fragment, { children: [u(S, { name: "取消", widget: () => n(!1) }), u(S, { name: "确定", type: "primary", widget: () => i.validateFields(!0).then(n) })] }), children: u(te, { fields: r, form: i, className: "ff-modal-form", children: e == null ? void 0 : e.map(({ code: a, ...o }) => u(wn, { code: a, ...o }, a)) }) }); -}, Bi = ({ className: e, $close: t, children: n, title: i, subTitle: r, actions: a, extras: o, ...s }) => A(Xn, { ...s, prefixCls: "ff-drawer", className: M("ff-popup", e), maskMotion: { motionAppear: !0, motionName: "mask-motion" }, motion: (l) => ({ motionAppear: !0, motionName: `panel-motion-${l}` }), children: [A("div", { className: "ff-popup-header", children: [u("button", { "aria-label": "Close", className: "ff-popup-close", onClick: s.onClose, children: u(St, { type: "close" }) }), i, r] }), u("div", { className: "ff-popup-body", children: n }), A("div", { className: "ff-popup-footer", children: [o, a] })] }), qi = ({ className: e, $close: t, $event: n, children: i, title: r, subTitle: a, actions: o, extras: s, placement: l, ...d }) => { +}, qi = ({ className: e, $close: t, children: n, title: i, subTitle: r, actions: a, extras: o, ...s }) => A(Qn, { ...s, prefixCls: "ff-drawer", className: M("ff-popup", e), maskMotion: { motionAppear: !0, motionName: "mask-motion" }, motion: (l) => ({ motionAppear: !0, motionName: `panel-motion-${l}` }), children: [A("div", { className: "ff-popup-header", children: [u("button", { "aria-label": "Close", className: "ff-popup-close", onClick: s.onClose, children: u(St, { type: "close" }) }), i, r] }), u("div", { className: "ff-popup-body", children: n }), A("div", { className: "ff-popup-footer", children: [o, a] })] }), Di = ({ className: e, $close: t, $event: n, children: i, title: r, subTitle: a, actions: o, extras: s, placement: l, ...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 u(Qn, { ...d, ...p, prefixCls: "ff-modal", modalRender: () => A("div", { className: M("ff-modal-content ff-popup", e), children: [A("div", { className: "ff-popup-header", children: [u("button", { "aria-label": "Close", className: "ff-popup-close", onClick: d.onClose, children: u(St, { type: "close" }) }), r, a] }), u("div", { className: "ff-popup-body", children: i }), A("div", { className: "ff-popup-footer", children: [s, o] })] }) }); + return u(Zn, { ...d, ...p, prefixCls: "ff-modal", modalRender: () => A("div", { className: M("ff-modal-content ff-popup", e), children: [A("div", { className: "ff-popup-header", children: [u("button", { "aria-label": "Close", className: "ff-popup-close", onClick: d.onClose, children: u(St, { type: "close" }) }), r, a] }), u("div", { className: "ff-popup-body", children: i }), A("div", { className: "ff-popup-footer", children: [s, o] })] }) }); }, kn = ({ placement: e, $close: t, $event: n, children: i, title: r, ...a }) => { const [o, s] = F({}), [l, d] = F(!0), p = X((h, C) => s((b) => ({ ...b, [h]: C })), []), g = X((h) => s((C) => ({ ...C, [h]: void 0 })), []); let f = { ...a, className: o.rootClassName, title: o.title || r && k.createElement("div", { className: M("ff-popup-title") }, r), subTitle: o["sub-title"], actions: o.actions, extras: o.extras, children: i, $close: t, $event: n, onClose: () => d(!1) }; const m = () => { t(!1); }; - return u(We.Provider, { value: { ele: o, mount: p, unmount: g }, children: e && e !== "center" ? u(Bi, { ...f, placement: e, open: l, afterOpenChange: (h) => !h && m() }) : u(qi, { ...f, visible: l, afterClose: m }) }); + return u(We.Provider, { value: { ele: o, mount: p, unmount: g }, children: e && e !== "center" ? u(qi, { ...f, placement: e, open: l, afterOpenChange: (h) => !h && m() }) : u(Di, { ...f, visible: l, afterClose: m }) }); }; kn.propTypes = { placement: w.oneOf(["center", "left", "top", "right", "bottom"]) }; const J = () => { - const [e, t] = jn({ maxCount: 6, motion: { motionName: "ff-notification-fade", motionAppear: !0, motionEnter: !0, motionLeave: !0, onLeaveStart: (a) => { + const [e, t] = An({ 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" }), [, n] = k.useReducer((a) => a + 1, 0); @@ -879,7 +879,7 @@ const J = () => { J.$popups = /* @__PURE__ */ new Map(), J.$index = 9999, J.$queue = [], J.$onClick = (...e) => new Promise((t, n) => { J.$queue.push([e, t, n]); }); -const Jt = (e, t, n = {}) => J.$onClick(e, t, n), ut = (e, { showProgress: t, duration: n, ...i } = { duration: 1.5 }) => J.$onClick(en, { content: e, ...i }, { showProgress: t, duration: n }), _ = { modal: Jt, confirm: (e, t = {}) => J.$onClick(Zn, { content: e, ...t }, { placement: "center" }), form: (e, t = {}, n = {}) => Jt(zi, { formProps: n, fields: e }, { placement: "center", ...t }).then((i) => { +const Jt = (e, t, n = {}) => J.$onClick(e, t, n), ut = (e, { showProgress: t, duration: n, ...i } = { duration: 1.5 }) => J.$onClick(en, { content: e, ...i }, { showProgress: t, duration: n }), _ = { modal: Jt, confirm: (e, t = {}) => J.$onClick(ei, { content: e, ...t }, { placement: "center" }), form: (e, t = {}, n = {}) => Jt(Bi, { formProps: n, fields: e }, { placement: "center", ...t }).then((i) => { if (i === !1) throw !1; return i; }), notification: ut, success: (e, t = { duration: 1.5 }) => ut(e, { ...t, className: "ff-notification-success", icon: "check" }), error: (e, t = { duration: 1.5 }) => ut(e, { ...t, className: "ff-notification-error", icon: "close" }) }; @@ -963,105 +963,105 @@ const oe = class oe { } return Promise.resolve(null); }); - v(this, "login", (t, n, i = {}) => j.post("/api/user-token", { username: t, passwd: An.hash(n), platform: "web", ...i }).then(({ token: r }) => (window.localStorage.setItem(Qe, r), r))); + v(this, "login", (t, n, i = {}) => j.post("/api/user-token", { username: t, passwd: Vn.hash(n), platform: "web", ...i }).then(({ token: r }) => (window.localStorage.setItem(Qe, r), r))); v(this, "logout", (t) => (window.localStorage.removeItem(gt), window.localStorage.removeItem(Qe), t == null ? void 0 : t())); if (y(oe, Ce)) return y(oe, Ce); } }; Ce = new WeakMap(), Oe = new WeakMap(), O(oe, Ce, null), v(oe, "getInstance", () => (y(oe, Ce) || H(oe, Ce, new oe()), y(oe, Ce))); let vt = oe; -const le = vt.getInstance(), Di = k.createContext({ user: {}, initUser: () => { -}, initUserComplete: !1 }), Ui = k.createContext({ set: () => { +const le = vt.getInstance(), Ui = k.createContext({ user: {}, initUser: () => { +}, initUserComplete: !1 }), Wi = k.createContext({ set: () => { }, get: () => { }, assign: () => { }, currentRoute: () => { -} }), Et = (e) => !!(e != null && e.name) && (e.prototype instanceof k.Component || /^[A-Z]/.test(e.name)), Wi = (e, t) => { +} }), Et = (e) => !!(e != null && e.name) && (e.prototype instanceof k.Component || /^[A-Z]/.test(e.name)), Hi = (e, t) => { if (!e || typeof window > "u") return; let n = document.querySelector(`style[ff-style-token="${t}"]`); return n ? (n.innerHTML = e, e) : (n = document.createElement("style"), n.setAttribute("ff-style-token", t), n.setAttribute("type", "text/css"), n.innerHTML = e, document.head.appendChild(n), e); -}, Hi = Object.freeze(Object.defineProperty({ __proto__: null, AppContext: Di, AppGlobalParamsContext: Ui, cache: Qt, configure: Ve, default: le, func: xe, http: j, insertStyle: Wi, isReactComponent: Et, route: ke }, Symbol.toStringTag, { value: "Module" })); +}, Ki = Object.freeze(Object.defineProperty({ __proto__: null, AppContext: Ui, AppGlobalParamsContext: Wi, cache: Qt, configure: Ve, default: le, func: xe, http: j, insertStyle: Hi, isReactComponent: Et, route: ke }, Symbol.toStringTag, { value: "Module" })); export { wn as $, - wi as A, - ai as B, - oi as C, + bi as A, + si as B, + li as C, et as D, - ni as E, - hr as F, - wr as G, - mi as H, - fr as I, + ii as E, + fr as F, + br as G, + hi as H, + yr as I, on as J, ft as K, - ii as L, - ri as M, - bi as N, - Ci as O, - br as P, - Cr as Q, + ri as L, + ai as M, + Ci as N, + ki as O, + Cr as P, + kr as Q, un as R, st as S, - kr as T, - xr as U, + xr as T, + vr as U, Ke as V, ot as W, - vr as X, - Sr as Y, - Ti as Z, + Sr as X, + Pr as Y, + Ei as Z, $t as _, tn as a, bn as a0, - xi as a1, - vi as a2, - Si as a3, + vi as a1, + Si as a2, + Pi as a3, yn as a4, - Pi as a5, - Pr as a6, + $i as a5, + $r as a6, kt as a7, S as a8, - ei as a9, - Li as aa, + ti as a9, + ji as aa, G as ab, We as ac, Zt as ad, J as ae, _ as af, - lr as ag, - cr as ah, - dr as ai, + cr as ag, + dr as ah, + ur as ai, le as aj, Et as ak, - Wi as al, + Hi as al, j as am, Qt as an, Ve as ao, xe as ap, ke as aq, - Di as ar, - Ui as as, + Ui as ar, + Wi as as, He as b, - gr as c, + pr as c, nn as d, - pr as e, - mr as f, - ti as g, + mr as e, + hr as f, + ni as g, sn as h, ln as i, - yr as j, + wr as j, gn as k, mn as l, - fi as m, - hi as n, + yi as m, + fi as n, pn as o, dn as p, cn as q, dt as r, - gi as s, + pi as s, ee as t, - ur as u, - ui as v, - ci as w, + gr as u, + gi as v, + di as w, Pt as x, ne as y, - pi as z + mi as z }; diff --git a/dist/components.js b/dist/components.js index 62bcb67..22a7950 100644 --- a/dist/components.js +++ b/dist/components.js @@ -1,4 +1,4 @@ -import { ag as s, a7 as p, ah as n, ai as t, af as d } from "./common/main-BYs1V3cl.js"; +import { ag as s, a7 as p, ah as n, ai as t, af as d } from "./common/main-B7AQyHAp.js"; export { s as Empty, p as Icon, diff --git a/dist/container.js b/dist/container.js index 03a2c44..0451151 100644 --- a/dist/container.js +++ b/dist/container.js @@ -1,4 +1,4 @@ -import { ac as o, ag as s, ah as d, ai as p, ad as t, af as n, ae as r, ab as u } from "./common/main-BYs1V3cl.js"; +import { ac as o, ag as s, ah as d, ai as p, ad as t, af as n, ae as r, ab as u } from "./common/main-B7AQyHAp.js"; export { o as Context, s as Empty, diff --git a/dist/data-converter.js b/dist/data-converter.js index 08ed9ab..d9f9155 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-BYs1V3cl.js"; +import { D as p } from "./common/main-B7AQyHAp.js"; export { p as default }; diff --git a/dist/data-list.js b/dist/data-list.js index 70f0390..4aaa29a 100644 --- a/dist/data-list.js +++ b/dist/data-list.js @@ -1,4 +1,4 @@ -import { A as t, y as e, q as r, w as o, B as i, x as u, v as D, z as l, s as L, C as n, p, E as m, M as C, I as c, K as F, J as b, L as d, F as k } from "./common/main-BYs1V3cl.js"; +import { A as t, y as e, q as r, w as o, B as i, x as u, v as D, z as l, s as L, C as n, p, E as m, M as C, I as c, K as F, J as b, L as d, F as k } from "./common/main-B7AQyHAp.js"; export { t as DataListContent, e as DataListContext, diff --git a/dist/data-list/utils.js b/dist/data-list/utils.js index 19eef47..6916067 100644 --- a/dist/data-list/utils.js +++ b/dist/data-list/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { k as a } from "../common/main-BYs1V3cl.js"; +import { k as a } from "../common/main-B7AQyHAp.js"; export { a as getDefaultExpandRowKeys }; diff --git a/dist/grid-layout-form.js b/dist/grid-layout-form.js index 10194b5..08d10d3 100644 --- a/dist/grid-layout-form.js +++ b/dist/grid-layout-form.js @@ -1,4 +1,4 @@ -import { _ as s, a0 as r, $ as u, Z as o, a4 as t, a3 as d, a6 as m, a2 as F, a1 as i, a5 as g } from "./common/main-BYs1V3cl.js"; +import { _ as s, a0 as r, $ as u, Z as o, a4 as t, a3 as d, a6 as m, a2 as F, a1 as i, a5 as g } from "./common/main-B7AQyHAp.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 8bba3e8..7e5b602 100644 --- a/dist/grid-layout-form/utils.js +++ b/dist/grid-layout-form/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { g as o, a as g } from "../common/main-BYs1V3cl.js"; +import { g as o, a as g } from "../common/main-B7AQyHAp.js"; export { o as getOptionItemByValue, g as getWidgetByNormalize diff --git a/dist/grid-layout.js b/dist/grid-layout.js index 31dd328..c4891ba 100644 --- a/dist/grid-layout.js +++ b/dist/grid-layout.js @@ -1,4 +1,4 @@ -import { l as d, m as e, H as i, G as o, n as t, o as u } from "./common/main-BYs1V3cl.js"; +import { l as d, m as e, H as i, G as o, n as t, o as u } from "./common/main-B7AQyHAp.js"; export { d as GridLayout, e as GridLayoutWidget, diff --git a/dist/grid-layout/utils.js b/dist/grid-layout/utils.js index 2dd6e15..c89a2b0 100644 --- a/dist/grid-layout/utils.js +++ b/dist/grid-layout/utils.js @@ -1,4 +1,4 @@ -import { i as o, j as a } from "../common/main-BYs1V3cl.js"; +import { i as o, j as a } from "../common/main-B7AQyHAp.js"; export { o as getBoxStyle, a as getWidgetByNormalize diff --git a/dist/hooks.js b/dist/hooks.js index 175e9db..a0cbada 100644 --- a/dist/hooks.js +++ b/dist/hooks.js @@ -1,7 +1,7 @@ import "lodash"; import "rc-field-form"; import "react"; -import { W as r, V as o, X as p, T as f, U as i, Y as m, S as c } from "./common/main-BYs1V3cl.js"; +import { W as r, V as o, X as p, T as f, U as i, Y as m, S as c } from "./common/main-B7AQyHAp.js"; import { default as S } from "rc-util/lib/hooks/useMergedState"; export { r as useDeepEffect, diff --git a/dist/iconfont.js b/dist/iconfont.js index 7cb81be..4a2079e 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 { a7 as a } from "./common/main-BYs1V3cl.js"; +import { a7 as a } from "./common/main-B7AQyHAp.js"; export { a as default }; diff --git a/dist/index.js b/dist/index.js index aa32625..fbf4a21 100644 --- a/dist/index.js +++ b/dist/index.js @@ -1,4 +1,4 @@ -import { ar as t, as as e, an as o, ao as n, aj as p, ap as r, am as c, al as l, ak as f, aq as m } from "./common/main-BYs1V3cl.js"; +import { ar as t, as as e, an as o, ao as n, aj as p, ap as r, am as c, al as l, ak as f, aq as m } from "./common/main-B7AQyHAp.js"; export { t as AppContext, e as AppGlobalParamsContext, diff --git a/dist/pages.js b/dist/pages.js index cc3e25b..e5acd1e 100644 --- a/dist/pages.js +++ b/dist/pages.js @@ -1,4 +1,4 @@ -import { O as t, N as e, P as o, Q as P } from "./common/main-BYs1V3cl.js"; +import { O as t, N as e, P as o, Q as P } from "./common/main-B7AQyHAp.js"; export { t as CustomPage, e as DataListPage, diff --git a/dist/res-ws.js b/dist/res-ws.js index 15865ed..82df8a3 100644 --- a/dist/res-ws.js +++ b/dist/res-ws.js @@ -1,5 +1,5 @@ import "lodash"; -import { R as a } from "./common/main-BYs1V3cl.js"; +import { R as a } from "./common/main-B7AQyHAp.js"; export { a as default }; diff --git a/dist/utils.js b/dist/utils.js index 48dcf4b..8469db1 100644 --- a/dist/utils.js +++ b/dist/utils.js @@ -1,5 +1,5 @@ import "lodash"; -import { d as g, e as o, c as p, f as i, h as m, b as P, r as d, t as u, u as k } from "./common/main-BYs1V3cl.js"; +import { d as g, e as o, c as p, f as i, h as m, b as P, r as d, t as u, u as k } from "./common/main-B7AQyHAp.js"; import "react/jsx-runtime"; import "react"; export { diff --git a/package.json b/package.json index 1610342..786e928 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "ff", "private": true, - "version": "0.5.1", + "version": "0.5.2", "author": "www.fsdpf.com", "type": "module", "main": "./dist/index.js",