@vef-framework-react/approval 2.24.1 → 2.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/detail/admin.cjs +1 -1
- package/dist/cjs/components/detail/index.cjs +1 -1
- package/dist/cjs/components/form-panel/index.cjs +1 -1
- package/dist/cjs/pages/flow-page/designer/flow-step.cjs +1 -1
- package/dist/cjs/pages/flow-page/designer/form-step.cjs +1 -1
- package/dist/cjs/pages/flow-page/designer/index.cjs +1 -1
- package/dist/cjs/pages/initiate-page/start-drawer.cjs +1 -1
- package/dist/cjs/plugins/form-context.cjs +1 -0
- package/dist/es/api/admin-api.js +1 -1
- package/dist/es/api/category-api.js +1 -1
- package/dist/es/api/delegation-api.js +1 -1
- package/dist/es/api/flow-api.js +1 -1
- package/dist/es/api/index.js +1 -1
- package/dist/es/api/instance-api.js +1 -1
- package/dist/es/api/my-api.js +1 -1
- package/dist/es/api/query.js +1 -1
- package/dist/es/components/action-dialog/index.js +1 -1
- package/dist/es/components/detail/action-modals.js +1 -1
- package/dist/es/components/detail/admin.js +3 -1
- package/dist/es/components/detail/drawer.js +1 -1
- package/dist/es/components/detail/index.js +3 -1
- package/dist/es/components/flow-graph/index.js +1 -1
- package/dist/es/components/flow-graph/node.js +1 -1
- package/dist/es/components/flow-graph/people-overlay.js +1 -1
- package/dist/es/components/flow-graph/people.js +1 -1
- package/dist/es/components/form-panel/index.js +23 -20
- package/dist/es/components/format.js +1 -1
- package/dist/es/components/icon.js +1 -1
- package/dist/es/components/index.js +1 -1
- package/dist/es/components/principal/index.js +1 -1
- package/dist/es/components/status/colors.js +1 -1
- package/dist/es/components/status/index.js +1 -1
- package/dist/es/components/status/labels.js +1 -1
- package/dist/es/components/timeline/index.js +1 -1
- package/dist/es/components/user/index.js +1 -1
- package/dist/es/index.js +1 -1
- package/dist/es/pages/admin-page/index.js +1 -1
- package/dist/es/pages/admin-page/instances.js +1 -1
- package/dist/es/pages/admin-page/metrics.js +1 -1
- package/dist/es/pages/admin-page/projections.js +1 -1
- package/dist/es/pages/admin-page/tasks.js +1 -1
- package/dist/es/pages/category-page/columns.js +1 -1
- package/dist/es/pages/category-page/form.js +1 -1
- package/dist/es/pages/category-page/index.js +1 -1
- package/dist/es/pages/delegation-page/columns.js +1 -1
- package/dist/es/pages/delegation-page/form.js +1 -1
- package/dist/es/pages/delegation-page/index.js +1 -1
- package/dist/es/pages/flow-page/columns.js +1 -1
- package/dist/es/pages/flow-page/designer/basic-step.js +1 -1
- package/dist/es/pages/flow-page/designer/flow-step.js +16 -34
- package/dist/es/pages/flow-page/designer/form-step.js +54 -65
- package/dist/es/pages/flow-page/designer/index.js +197 -186
- package/dist/es/pages/flow-page/designer/review-step.js +1 -1
- package/dist/es/pages/flow-page/designer/types.js +1 -1
- package/dist/es/pages/flow-page/index.js +1 -1
- package/dist/es/pages/flow-page/search.js +1 -1
- package/dist/es/pages/flow-page/versions.js +1 -1
- package/dist/es/pages/index.js +1 -1
- package/dist/es/pages/initiate-page/index.js +1 -1
- package/dist/es/pages/initiate-page/start-drawer.js +3 -1
- package/dist/es/pages/my-instances-page/index.js +1 -1
- package/dist/es/pages/task-center-page/index.js +1 -1
- package/dist/es/pages/task-center-page/search.js +1 -1
- package/dist/es/permissions.js +1 -1
- package/dist/es/plugins/form-context.js +34 -0
- package/dist/es/plugins/index.js +1 -1
- package/dist/es/types/enums.js +1 -1
- package/dist/es/types/index.js +1 -1
- package/dist/types/components/form-panel/index.d.ts +15 -3
- package/dist/types/index.d.ts +1 -0
- package/dist/types/pages/flow-page/designer/flow-step.d.ts +6 -5
- package/dist/types/pages/flow-page/designer/form-step.d.ts +9 -10
- package/dist/types/plugins/form-context.d.ts +30 -0
- package/dist/types/plugins/index.d.ts +25 -5
- package/dist/types/types/admin.d.ts +5 -0
- package/dist/types/types/my.d.ts +15 -0
- package/package.json +7 -7
|
@@ -1,41 +1,23 @@
|
|
|
1
|
-
/*! @vef-framework-react/approval v2.
|
|
2
|
-
import {
|
|
3
|
-
import { jsx as
|
|
4
|
-
import { ApprovalFlowEditor as
|
|
1
|
+
/*! @vef-framework-react/approval v2.25.0 made by Venus | 2026-10-13T08:59:38.583Z */
|
|
2
|
+
import { globalCssVars as e } from "@vef-framework-react/components";
|
|
3
|
+
import { jsx as t } from "@emotion/react/jsx-runtime";
|
|
4
|
+
import { ApprovalFlowEditor as n } from "@vef-framework-react/approval-flow-editor";
|
|
5
5
|
//#region src/pages/flow-page/designer/flow-step.tsx
|
|
6
|
-
function
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
-
gap: 8,
|
|
6
|
+
function r({ value: r, plugins: i, onChange: a }) {
|
|
7
|
+
return /* @__PURE__ */ t("div", {
|
|
9
8
|
style: {
|
|
10
9
|
height: "100%",
|
|
11
|
-
minHeight: 0
|
|
10
|
+
minHeight: 0,
|
|
11
|
+
border: `1px solid ${e.colorBorderSecondary}`,
|
|
12
|
+
borderRadius: 8,
|
|
13
|
+
overflow: "hidden"
|
|
12
14
|
},
|
|
13
|
-
children:
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
style: {
|
|
19
|
-
margin: 0,
|
|
20
|
-
paddingInlineStart: 18
|
|
21
|
-
},
|
|
22
|
-
children: c.map((e, t) => /* @__PURE__ */ r("li", { children: e.message }, t))
|
|
23
|
-
})
|
|
24
|
-
}), /* @__PURE__ */ r("div", {
|
|
25
|
-
style: {
|
|
26
|
-
flex: 1,
|
|
27
|
-
minHeight: 0,
|
|
28
|
-
border: `1px solid ${n.colorBorderSecondary}`,
|
|
29
|
-
borderRadius: 8,
|
|
30
|
-
overflow: "hidden"
|
|
31
|
-
},
|
|
32
|
-
children: /* @__PURE__ */ r(a, {
|
|
33
|
-
plugins: s,
|
|
34
|
-
value: o,
|
|
35
|
-
onChange: l
|
|
36
|
-
})
|
|
37
|
-
})]
|
|
15
|
+
children: /* @__PURE__ */ t(n, {
|
|
16
|
+
plugins: i,
|
|
17
|
+
value: r,
|
|
18
|
+
onChange: a
|
|
19
|
+
})
|
|
38
20
|
});
|
|
39
21
|
}
|
|
40
22
|
//#endregion
|
|
41
|
-
export {
|
|
23
|
+
export { r as FlowStep };
|
|
@@ -1,87 +1,76 @@
|
|
|
1
|
-
/*! @vef-framework-react/approval v2.
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
/*! @vef-framework-react/approval v2.25.0 made by Venus | 2026-10-13T08:59:38.583Z */
|
|
2
|
+
import { useApprovalPlugins as e } from "../../../plugins/index.js";
|
|
3
|
+
import { toFormContextSources as t } from "../../../plugins/form-context.js";
|
|
4
|
+
import { useMemo as n } from "react";
|
|
5
|
+
import { Flex as r, Segmented as i, Stack as a, Text as o, globalCssVars as s } from "@vef-framework-react/components";
|
|
6
|
+
import { validateApprovalProjection as c } from "@vef-framework-react/approval-form-bridge";
|
|
7
|
+
import { jsx as l, jsxs as u } from "@emotion/react/jsx-runtime";
|
|
8
|
+
import { FormEditor as d } from "@vef-framework-react/form-editor";
|
|
5
9
|
//#region src/pages/flow-page/designer/form-step.tsx
|
|
6
|
-
var
|
|
10
|
+
var f = [{
|
|
7
11
|
label: "JSON 存储",
|
|
8
12
|
value: "json"
|
|
9
13
|
}, {
|
|
10
14
|
label: "独立表存储",
|
|
11
15
|
value: "table"
|
|
12
16
|
}];
|
|
13
|
-
function
|
|
17
|
+
function p(e) {
|
|
14
18
|
return e === "json" || e === "table";
|
|
15
19
|
}
|
|
16
|
-
var
|
|
20
|
+
var m = {
|
|
17
21
|
json: "表单数据以 JSONB 存入实例表,字段可灵活增减,查询能力有限。",
|
|
18
22
|
table: "表单数据投影到按版本生成的独立表(明细表各自成表),适合复杂查询与数据分析。"
|
|
19
23
|
};
|
|
20
|
-
function
|
|
21
|
-
let
|
|
22
|
-
return /* @__PURE__ */
|
|
24
|
+
function h({ storageMode: h, initialSchema: g, registries: _, onStorageModeChange: v, onSchemaChange: y }) {
|
|
25
|
+
let { dataSourceApis: b, dataSourceResolver: x, evaluators: S, formGlobals: C } = e(), w = n(() => t(C), [C]);
|
|
26
|
+
return /* @__PURE__ */ u(a, {
|
|
23
27
|
gap: 8,
|
|
24
28
|
style: {
|
|
25
29
|
height: "100%",
|
|
26
30
|
minHeight: 0
|
|
27
31
|
},
|
|
28
|
-
children: [
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
children: d[f]
|
|
49
|
-
})
|
|
50
|
-
]
|
|
51
|
-
}),
|
|
52
|
-
v.length > 0 && /* @__PURE__ */ o(e, {
|
|
53
|
-
showIcon: !0,
|
|
54
|
-
title: `表单校验未通过(${v.length} 项)`,
|
|
55
|
-
type: "error",
|
|
56
|
-
description: /* @__PURE__ */ o("ul", {
|
|
57
|
-
style: {
|
|
58
|
-
margin: 0,
|
|
59
|
-
paddingInlineStart: 18
|
|
60
|
-
},
|
|
61
|
-
children: v.map((e, t) => /* @__PURE__ */ o("li", { children: e.message }, t))
|
|
62
|
-
})
|
|
63
|
-
}),
|
|
64
|
-
v.length === 0 && y.length > 0 && /* @__PURE__ */ o(e, {
|
|
65
|
-
showIcon: !0,
|
|
66
|
-
title: y.map((e) => e.message).join(";"),
|
|
67
|
-
type: "warning"
|
|
68
|
-
}),
|
|
69
|
-
/* @__PURE__ */ o("div", {
|
|
70
|
-
style: {
|
|
71
|
-
flex: 1,
|
|
72
|
-
minHeight: 0,
|
|
73
|
-
border: `1px solid ${a.colorBorderSecondary}`,
|
|
74
|
-
borderRadius: 8,
|
|
75
|
-
overflow: "hidden"
|
|
76
|
-
},
|
|
77
|
-
children: /* @__PURE__ */ o(c, {
|
|
78
|
-
initialSchema: p,
|
|
79
|
-
registries: h,
|
|
80
|
-
onSchemaChange: _
|
|
32
|
+
children: [/* @__PURE__ */ u(r, {
|
|
33
|
+
align: "center",
|
|
34
|
+
gap: "middle",
|
|
35
|
+
wrap: "wrap",
|
|
36
|
+
children: [
|
|
37
|
+
/* @__PURE__ */ l(o, {
|
|
38
|
+
type: "secondary",
|
|
39
|
+
children: "存储模式"
|
|
40
|
+
}),
|
|
41
|
+
/* @__PURE__ */ l(i, {
|
|
42
|
+
options: f,
|
|
43
|
+
value: h,
|
|
44
|
+
onChange: (e) => {
|
|
45
|
+
p(e) && v(e);
|
|
46
|
+
}
|
|
47
|
+
}),
|
|
48
|
+
/* @__PURE__ */ l(o, {
|
|
49
|
+
style: { fontSize: s.fontSizeSm },
|
|
50
|
+
type: "secondary",
|
|
51
|
+
children: m[h]
|
|
81
52
|
})
|
|
53
|
+
]
|
|
54
|
+
}), /* @__PURE__ */ l("div", {
|
|
55
|
+
style: {
|
|
56
|
+
flex: 1,
|
|
57
|
+
minHeight: 0,
|
|
58
|
+
border: `1px solid ${s.colorBorderSecondary}`,
|
|
59
|
+
borderRadius: 8,
|
|
60
|
+
overflow: "hidden"
|
|
61
|
+
},
|
|
62
|
+
children: /* @__PURE__ */ l(d, {
|
|
63
|
+
contextSources: w,
|
|
64
|
+
dataSourceApis: b,
|
|
65
|
+
dataSourceResolver: x,
|
|
66
|
+
evaluators: S,
|
|
67
|
+
initialSchema: g,
|
|
68
|
+
registries: _,
|
|
69
|
+
validate: c,
|
|
70
|
+
onSchemaChange: y
|
|
82
71
|
})
|
|
83
|
-
]
|
|
72
|
+
})]
|
|
84
73
|
});
|
|
85
74
|
}
|
|
86
75
|
//#endregion
|
|
87
|
-
export {
|
|
76
|
+
export { h as FormStep };
|