@aplus-frontend/ui 0.1.15 → 0.1.16

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.
Files changed (57) hide show
  1. package/es/index.mjs +56 -54
  2. package/es/src/ap-table/ap-table.vue.mjs +132 -129
  3. package/es/src/ap-table/interface.d.ts +20 -13
  4. package/es/src/ap-table/utils.d.ts +8340 -1
  5. package/es/src/ap-table/utils.mjs +135 -79
  6. package/es/src/business/index.d.ts +2 -0
  7. package/es/src/business/index.mjs +20 -18
  8. package/es/src/config-provider/config-provider-props.d.ts +5 -1
  9. package/es/src/config-provider/config-provider-props.mjs +4 -0
  10. package/es/src/config-provider/config-provider.d.ts +10 -1
  11. package/es/src/config-provider/config-provider.mjs +18 -17
  12. package/es/src/config-provider/constants.d.ts +6 -2
  13. package/es/src/config-provider/hooks/use-global-config.d.ts +5 -1
  14. package/es/src/config-provider/index.d.ts +20 -1
  15. package/es/src/editable-table/form-item.vue.mjs +85 -72
  16. package/es/src/editable-table/index.vue.mjs +99 -86
  17. package/es/src/editable-table/utils.mjs +31 -30
  18. package/es/src/index.mjs +45 -43
  19. package/es/src/theme/antd-global-overwrite/admin/form.css +10 -5
  20. package/es/src/theme/antd-global-overwrite/admin/index.css +117 -38
  21. package/es/src/theme/antd-global-overwrite/admin/pagination.css +54 -16
  22. package/es/src/theme/antd-global-overwrite/admin/table.css +53 -17
  23. package/es/src/theme/antd-global-overwrite/aplus/form.css +28 -14
  24. package/es/src/theme/antd-global-overwrite/aplus/index.css +159 -67
  25. package/es/src/theme/antd-global-overwrite/aplus/pagination.css +66 -20
  26. package/es/src/theme/antd-global-overwrite/aplus/table.css +65 -33
  27. package/es/src/utils/ap-trans-data/index.d.ts +9 -10
  28. package/es/src/utils/ap-trans-data/index.mjs +20 -0
  29. package/lib/index.js +1 -1
  30. package/lib/src/ap-table/ap-table.vue.js +1 -1
  31. package/lib/src/ap-table/interface.d.ts +20 -13
  32. package/lib/src/ap-table/utils.d.ts +8340 -1
  33. package/lib/src/ap-table/utils.js +1 -1
  34. package/lib/src/business/index.d.ts +2 -0
  35. package/lib/src/business/index.js +1 -1
  36. package/lib/src/config-provider/config-provider-props.d.ts +5 -1
  37. package/lib/src/config-provider/config-provider-props.js +1 -1
  38. package/lib/src/config-provider/config-provider.d.ts +10 -1
  39. package/lib/src/config-provider/config-provider.js +1 -1
  40. package/lib/src/config-provider/constants.d.ts +6 -2
  41. package/lib/src/config-provider/hooks/use-global-config.d.ts +5 -1
  42. package/lib/src/config-provider/index.d.ts +20 -1
  43. package/lib/src/editable-table/form-item.vue.js +1 -1
  44. package/lib/src/editable-table/index.vue.js +1 -1
  45. package/lib/src/editable-table/utils.js +1 -1
  46. package/lib/src/index.js +1 -1
  47. package/lib/src/theme/antd-global-overwrite/admin/form.css +10 -5
  48. package/lib/src/theme/antd-global-overwrite/admin/index.css +117 -38
  49. package/lib/src/theme/antd-global-overwrite/admin/pagination.css +54 -16
  50. package/lib/src/theme/antd-global-overwrite/admin/table.css +53 -17
  51. package/lib/src/theme/antd-global-overwrite/aplus/form.css +28 -14
  52. package/lib/src/theme/antd-global-overwrite/aplus/index.css +159 -67
  53. package/lib/src/theme/antd-global-overwrite/aplus/pagination.css +66 -20
  54. package/lib/src/theme/antd-global-overwrite/aplus/table.css +65 -33
  55. package/lib/src/utils/ap-trans-data/index.d.ts +9 -10
  56. package/lib/src/utils/ap-trans-data/index.js +1 -0
  57. package/package.json +1 -1
@@ -1,110 +1,166 @@
1
- import { isObject as s, isArray as c, isUndefined as f, isFunction as l, omit as d, isBoolean as p } from "lodash-unified";
2
- const m = (e, t, n) => {
3
- let o = {};
4
- return s(e) ? Object.keys(e).forEach((u) => {
5
- s(e[u]) ? o[u] = m(e[u], t[u], n) : o[u] = n(e[u], t);
6
- }) : o = n(e, t), o;
7
- }, h = (e, t) => {
8
- switch (e) {
1
+ import { isVNode as m, createVNode as c, mergeProps as i, cloneVNode as p } from "vue";
2
+ import { isObject as s, isArray as l, isUndefined as d, isFunction as b, omit as T, isBoolean as y } from "lodash-unified";
3
+ import { apTableRenderItemMap as j, apTableFormItemMap as h } from "./constants.mjs";
4
+ import { isType as g } from "@fruits-chain/utils";
5
+ import "../ap-form/index.mjs";
6
+ import E from "../ap-form/ap-form-item.vue.mjs";
7
+ function F(t) {
8
+ return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !m(t);
9
+ }
10
+ const O = (t, e, n) => {
11
+ let r = {};
12
+ return s(t) ? Object.keys(t).forEach((o) => {
13
+ s(t[o]) ? r[o] = O(t[o], e[o], n) : r[o] = n(t[o], e);
14
+ }) : r = n(t, e), r;
15
+ }, _ = (t, e) => {
16
+ switch (t) {
9
17
  case "dayjs":
10
- return t.valueOf();
18
+ return e.valueOf();
11
19
  case "dayjsRange":
12
- return t.map((n) => n.valueOf());
20
+ return e.map((n) => n.valueOf());
13
21
  case "dayjsDayRange": {
14
- const [n, o] = t;
15
- return [n.startOf("day").valueOf(), o.endOf("day").valueOf()];
22
+ const [n, r] = e;
23
+ return [n.startOf("day").valueOf(), r.endOf("day").valueOf()];
16
24
  }
17
25
  case "multiple":
18
26
  case "multipleNumber":
19
- return c(t) ? t : [t];
27
+ return l(e) ? e : [e];
20
28
  case "boolean":
21
- return t;
29
+ return e;
22
30
  case "object":
23
- return t;
31
+ return e;
24
32
  default:
25
- return t;
33
+ return e;
26
34
  }
27
35
  };
28
- function y(e) {
29
- return c(e) ? e.join(".") : e;
36
+ function C(t) {
37
+ return l(t) ? t.join(".") : t;
30
38
  }
31
- function x(e) {
32
- const t = Object.prototype.toString.call(e).match(/^\[object (.*)\]$/)[1].toLowerCase();
33
- return t === "string" && typeof e == "object" ? "object" : e === null ? "null" : e === void 0 ? "undefined" : t;
39
+ function N(t) {
40
+ const e = Object.prototype.toString.call(t).match(/^\[object (.*)\]$/)[1].toLowerCase();
41
+ return e === "string" && typeof t == "object" ? "object" : t === null ? "null" : t === void 0 ? "undefined" : e;
34
42
  }
35
- const T = (e) => x(e) === "map" ? e : new Map(Object.entries(e || {})), a = (e) => {
36
- const t = [], n = T(e);
37
- return n.forEach((o, u) => {
38
- const r = n.get(u) || n.get(`${u}`);
39
- if (r) {
40
- if (typeof r == "object" && (r != null && r.text)) {
41
- t.push({
42
- text: r == null ? void 0 : r.text,
43
- value: u,
44
- label: r == null ? void 0 : r.text,
45
- disabled: r.disabled
43
+ const S = (t) => N(t) === "map" ? t : new Map(Object.entries(t || {})), f = (t) => {
44
+ const e = [], n = S(t);
45
+ return n.forEach((r, o) => {
46
+ const u = n.get(o) || n.get(`${o}`);
47
+ if (u) {
48
+ if (typeof u == "object" && (u != null && u.text)) {
49
+ e.push({
50
+ text: u == null ? void 0 : u.text,
51
+ value: o,
52
+ label: u == null ? void 0 : u.text,
53
+ disabled: u.disabled
46
54
  });
47
55
  return;
48
56
  }
49
- t.push({
50
- text: r,
51
- label: r,
52
- value: u
57
+ e.push({
58
+ text: u,
59
+ label: u,
60
+ value: o
53
61
  });
54
62
  }
55
- }), t;
56
- }, E = (e) => f(e) || e < 0 ? 0 : e, j = (e, t, n) => {
63
+ }), e;
64
+ }, R = (t) => d(t) || t < 0 ? 0 : t, $ = (t, e, n) => {
57
65
  if (n)
58
66
  return n;
59
- const o = ["select", "date"], u = [
60
- "text",
61
- "textArea",
62
- "number"
63
- ];
64
- if (t === "dateRange")
65
- return [e("ap.common.chooseText"), e("ap.common.chooseText")];
66
- if (o.includes(t))
67
- return e("ap.common.chooseText");
68
- if (u.includes(t))
69
- return e("ap.common.inputText");
67
+ const r = ["select", "date"], o = ["text", "textArea", "number"];
68
+ if (e === "dateRange")
69
+ return [t("ap.common.chooseText"), t("ap.common.chooseText")];
70
+ if (r.includes(e))
71
+ return t("ap.common.chooseText");
72
+ if (o.includes(e))
73
+ return t("ap.common.inputText");
70
74
  };
71
- function b(e, t) {
72
- return !e || !l(e) ? e : e(t);
75
+ function x(t, e) {
76
+ return !t || !b(t) ? t : t(e);
77
+ }
78
+ function q(t) {
79
+ let e = t.valueType || "text";
80
+ return t.valueEnum && (e = "status"), e;
73
81
  }
74
- function O(e) {
75
- let t = e.valueType || "text";
76
- return e.valueEnum && (t = "status"), t;
82
+ function B(t, e, n) {
83
+ var u;
84
+ const r = j[t];
85
+ if (r)
86
+ return c(r, i(e, {
87
+ mode: "read"
88
+ }), null);
89
+ const o = n == null ? void 0 : n[t];
90
+ return ((u = o == null ? void 0 : o.render) == null ? void 0 : u.call(o, e.value, e)) || e.value;
77
91
  }
78
- function F(e, t) {
79
- const n = b(e.fieldProps, t), o = (n == null ? void 0 : n.field) || n || {}, u = e.valueType === "switch", r = e.valueType === "index", i = u ? { checked: t.value } : { value: r ? t.index + 1 : t.value };
80
- return e.valueEnum && (o.valueEnum = e.valueEnum), {
81
- ...d(o, ["request"]),
82
- ...i
92
+ function D(t, e) {
93
+ if (t.customRenderFormItem)
94
+ return () => {
95
+ const o = t.customRenderFormItem(t);
96
+ return p(o, {
97
+ ...t.fieldProps,
98
+ span: t.span,
99
+ ...o.props || {}
100
+ });
101
+ };
102
+ const n = h[t.valueType];
103
+ if (n)
104
+ return n;
105
+ const r = e == null ? void 0 : e[t.valueType];
106
+ return () => {
107
+ var u;
108
+ const o = (u = r == null ? void 0 : r.renderFormItem) == null ? void 0 : u.call(r, t.fieldProps.field);
109
+ return o ? c(E, i(t.fieldProps, {
110
+ span: t.span
111
+ }), F(o) ? o : {
112
+ default: () => [o]
113
+ }) : null;
83
114
  };
84
115
  }
85
- function v(e) {
86
- const t = { ...e };
87
- return p(e.filters) && e.filters && e.valueEnum && (t.filters = a(e.valueEnum)), t;
116
+ function J(t, e) {
117
+ const n = x(t.fieldProps, e), r = (n == null ? void 0 : n.field) || n || {}, o = t.valueType === "switch", u = t.valueType === "index", a = o ? {
118
+ checked: e.value
119
+ } : {
120
+ value: u ? e.index + 1 : e.value
121
+ };
122
+ return t.valueEnum && (r.valueEnum = t.valueEnum), {
123
+ ...T(r, ["request"]),
124
+ ...a
125
+ };
126
+ }
127
+ function L(t) {
128
+ const e = {
129
+ ...t
130
+ };
131
+ return y(t.filters) && t.filters && t.valueEnum && (e.filters = f(t.valueEnum)), e;
88
132
  }
89
- function w(e, t) {
90
- var o;
91
- const n = t || {};
92
- return e.valueEnum && !((o = n.field) != null && o.options) && (n.field = {
133
+ function U(t, e) {
134
+ var r;
135
+ const n = e || {};
136
+ return t.valueEnum && !((r = n.field) != null && r.options) && (n.field = {
93
137
  ...n.field,
94
- options: a(e.valueEnum)
138
+ options: f(t.valueEnum)
95
139
  }), n;
96
140
  }
141
+ function z(t) {
142
+ if (!g("Object")(t))
143
+ return t;
144
+ try {
145
+ return JSON.stringify(t);
146
+ } catch {
147
+ return t;
148
+ }
149
+ }
97
150
  export {
98
- v as apColumnToColumn,
99
- y as dataIndexToStr,
100
- m as formatParamsValueType,
101
- E as getColumnOrder,
102
- b as getFieldProps,
103
- j as getPlaceholder,
104
- F as getTableRenderProps,
105
- O as getTableRenderType,
106
- T as objectToMap,
107
- h as parseFieldValue,
108
- w as updateFormProps,
109
- a as valueEnumToArray
151
+ L as apColumnToColumn,
152
+ C as dataIndexToStr,
153
+ O as formatParamsValueType,
154
+ R as getColumnOrder,
155
+ x as getFieldProps,
156
+ $ as getPlaceholder,
157
+ D as getSearchFormItemRenderNode,
158
+ B as getTableCellRenderNode,
159
+ J as getTableRenderProps,
160
+ q as getTableRenderType,
161
+ S as objectToMap,
162
+ z as objectToString,
163
+ _ as parseFieldValue,
164
+ U as updateFormProps,
165
+ f as valueEnumToArray
110
166
  };
@@ -1,3 +1,4 @@
1
+ import { ApTransformDataHelper } from '../utils/ap-trans-data';
1
2
  import { CreateComponentPublicInstance, ExtractPropTypes, PropType, ComponentOptionsMixin, VNodeProps, AllowedComponentProps, ComponentCustomProps, ComponentOptionsBase, Plugin, CSSProperties, PublicProps, ShallowUnwrapRef, VNode, RendererNode, RendererElement, DefineComponent } from 'vue';
2
3
  import { TooltipPlacement } from 'ant-design-vue/es/tooltip';
3
4
  import { LiteralUnion } from 'ant-design-vue/es/_util/type';
@@ -1311,3 +1312,4 @@ export declare const ApLabelGroup: DefineComponent<{
1311
1312
  record: any;
1312
1313
  tagValue: string | number | undefined;
1313
1314
  }, {}>;
1315
+ export { ApTransformDataHelper };
@@ -9,25 +9,27 @@ import "./ap-select-layout/select-layout.vue.mjs";
9
9
  import "./ap-export-group/ApExportGroup.vue.mjs";
10
10
  import "./ap-input-radio/ApInputRadio.vue.mjs";
11
11
  import "./ap-batch-action/ApBatchAction.vue.mjs";
12
- import m from "./title/ApTitle.vue2.mjs";
13
- import p from "./expandAlert/ApExpandAlert.vue2.mjs";
14
- import r from "./ap-label/ApLabel.vue2.mjs";
12
+ import { ApTransformDataHelper as M } from "../utils/ap-trans-data/index.mjs";
13
+ import r from "./title/ApTitle.vue2.mjs";
14
+ import m from "./expandAlert/ApExpandAlert.vue2.mjs";
15
+ import p from "./ap-label/ApLabel.vue2.mjs";
15
16
  import i from "./ap-status/ApStatus.vue2.mjs";
16
17
  import n from "./ap-status/ApStatusGroup.vue2.mjs";
17
- import c from "./ap-select-layout/select-layout.vue2.mjs";
18
- import s from "./ap-export-group/ApExportGroup.vue2.mjs";
19
- import f from "./ap-input-radio/ApInputRadio.vue2.mjs";
20
- import a from "./ap-batch-action/ApBatchAction.vue2.mjs";
21
- const g = o(m), j = p, k = o(r), q = o(i), v = o(n), z = o(c), C = o(s), D = f, F = a, H = t;
18
+ import s from "./ap-select-layout/select-layout.vue2.mjs";
19
+ import a from "./ap-export-group/ApExportGroup.vue2.mjs";
20
+ import c from "./ap-input-radio/ApInputRadio.vue2.mjs";
21
+ import f from "./ap-batch-action/ApBatchAction.vue2.mjs";
22
+ const H = o(r), R = m, g = o(p), j = o(i), k = o(n), q = o(s), v = o(a), z = c, C = f, F = t;
22
23
  export {
23
- F as ApBatchAction,
24
- j as ApExpandAlert,
25
- C as ApExportGroup,
26
- D as ApInputRadio,
27
- k as ApLabel,
28
- H as ApLabelGroup,
29
- z as ApSelectLayout,
30
- q as ApStatus,
31
- v as ApStatusGroup,
32
- g as ApTitle
24
+ C as ApBatchAction,
25
+ R as ApExpandAlert,
26
+ v as ApExportGroup,
27
+ z as ApInputRadio,
28
+ g as ApLabel,
29
+ F as ApLabelGroup,
30
+ q as ApSelectLayout,
31
+ j as ApStatus,
32
+ k as ApStatusGroup,
33
+ H as ApTitle,
34
+ M as ApTransformDataHelper
33
35
  };
@@ -1,6 +1,6 @@
1
1
  import { ExtractPropTypes, PropType } from 'vue';
2
2
  import { LocaleType } from '../locale/interface';
3
- import { ApiType, ScrollbarGlobalConfig, TableDefaultConfig, ApUploadConfig, ApDescriptionsConfig } from './constants';
3
+ import { ApiType, ScrollbarGlobalConfig, TableDefaultConfig, ApUploadConfig, ApDescriptionsConfig, ValueTypeRenderConfig } from './constants';
4
4
  import { default as __DTS_DEFAULT_0__ } from 'ant-design-vue/es/config-provider/renderEmpty';
5
5
  import { TransformCellTextProps } from 'ant-design-vue/es/table/interface';
6
6
  import { CSPConfig, SizeType, ThemeConfig } from 'ant-design-vue/es/config-provider/context';
@@ -155,5 +155,9 @@ export declare const configProviderProps: () => {
155
155
  type: PropType<ApDescriptionsConfig>;
156
156
  default: () => {};
157
157
  };
158
+ valueTypeMap: {
159
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
160
+ default: () => {};
161
+ };
158
162
  };
159
163
  export type ConfigProviderProps = Partial<ExtractPropTypes<ReturnType<typeof configProviderProps>>>;
@@ -33,6 +33,10 @@ const p = () => ({
33
33
  type: Object,
34
34
  default: () => ({})
35
35
  },
36
+ valueTypeMap: {
37
+ type: Object,
38
+ default: () => ({})
39
+ },
36
40
  ...e()
37
41
  });
38
42
  export {
@@ -9,7 +9,7 @@ import { ValidateMessages } from 'ant-design-vue/es/form/interface';
9
9
  import { RequiredMark } from 'ant-design-vue/es/form/Form';
10
10
  import { ThemeConfig } from 'ant-design-vue/es/config-provider/context';
11
11
  import { LocaleType } from '..';
12
- import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig } from './constants';
12
+ import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig, ValueTypeRenderConfig } from './constants';
13
13
  export declare const globalConfigCached: Ref<ConfigProviderProps>;
14
14
  export declare const ConfigProvider: DefineComponent<{
15
15
  iconPrefixCls: StringConstructor;
@@ -156,6 +156,10 @@ export declare const ConfigProvider: DefineComponent<{
156
156
  type: PropType<ApDescriptionsConfig>;
157
157
  default: () => {};
158
158
  };
159
+ valueTypeMap: {
160
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
161
+ default: () => {};
162
+ };
159
163
  }, () => import("vue/jsx-runtime").JSX.Element, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
160
164
  iconPrefixCls: StringConstructor;
161
165
  getTargetContainer: {
@@ -301,6 +305,10 @@ export declare const ConfigProvider: DefineComponent<{
301
305
  type: PropType<ApDescriptionsConfig>;
302
306
  default: () => {};
303
307
  };
308
+ valueTypeMap: {
309
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
310
+ default: () => {};
311
+ };
304
312
  }>>, {
305
313
  input: {
306
314
  autocomplete?: string;
@@ -339,5 +347,6 @@ export declare const ConfigProvider: DefineComponent<{
339
347
  uiMode: "aplus" | "admin";
340
348
  apUpload: ApUploadConfig;
341
349
  apDescriptions: ApDescriptionsConfig;
350
+ valueTypeMap: Record<string, ValueTypeRenderConfig>;
342
351
  }, {}>;
343
352
  export type ConfigProviderInstance = InstanceType<typeof ConfigProvider>;
@@ -1,20 +1,20 @@
1
- import { isVNode as n, ref as d, defineComponent as f, computed as m, watch as r, createVNode as c, renderSlot as u } from "vue";
2
- import { ConfigProvider as s } from "ant-design-vue";
3
- import { provideGlobalConfig as p } from "./hooks/use-global-config.mjs";
1
+ import { isVNode as n, ref as u, defineComponent as d, computed as f, watch as a, createVNode as m, renderSlot as c } from "vue";
2
+ import { ConfigProvider as p } from "ant-design-vue";
3
+ import { provideGlobalConfig as s } from "./hooks/use-global-config.mjs";
4
4
  import { configProviderProps as g } from "./config-provider-props.mjs";
5
5
  import { tableDefaultConfig as C } from "./constants.mjs";
6
- import { mergeAntdProvideConfig as b } from "../utils/config-provider-preset.mjs";
7
- import { setCSSVariables as v, aplusCssVar as P, adminCssVar as S } from "../theme/css-var/index.mjs";
8
- function V(e) {
6
+ import { mergeAntdProvideConfig as v } from "../utils/config-provider-preset.mjs";
7
+ import { setCSSVariables as b, aplusCssVar as P, adminCssVar as M } from "../theme/css-var/index.mjs";
8
+ function S(e) {
9
9
  return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !n(e);
10
10
  }
11
- const a = d({}), N = /* @__PURE__ */ f({
11
+ const i = u({}), N = /* @__PURE__ */ d({
12
12
  name: "AplusConfigProvider",
13
13
  props: g(),
14
14
  setup(e, {
15
- slots: i
15
+ slots: r
16
16
  }) {
17
- const l = m(() => ({
17
+ const l = f(() => ({
18
18
  namespace: e.namespace,
19
19
  aplusLocale: e.aplusLocale,
20
20
  api: e.api,
@@ -25,20 +25,21 @@ const a = d({}), N = /* @__PURE__ */ f({
25
25
  scrollbar: e.scrollbar,
26
26
  uiMode: e.uiMode,
27
27
  apUpload: e.apUpload,
28
- apDescriptions: e.apDescriptions
29
- })), t = p(l);
30
- return r(() => e, (o) => {
31
- a.value = b(o);
28
+ apDescriptions: e.apDescriptions,
29
+ valueTypeMap: e.valueTypeMap
30
+ })), t = s(l);
31
+ return a(() => e, (o) => {
32
+ i.value = v(o);
32
33
  }, {
33
34
  deep: !0,
34
35
  immediate: !0
35
- }), r(() => e.uiMode, (o) => {
36
- v(o === "aplus" ? P : S);
36
+ }), a(() => e.uiMode, (o) => {
37
+ b(o === "aplus" ? P : M);
37
38
  }, {
38
39
  immediate: !0
39
40
  }), () => {
40
41
  let o;
41
- return c(s, a.value, V(o = u(i, "default", {
42
+ return m(p, i.value, S(o = c(r, "default", {
42
43
  config: t == null ? void 0 : t.value
43
44
  })) ? o : {
44
45
  default: () => [o]
@@ -48,5 +49,5 @@ const a = d({}), N = /* @__PURE__ */ f({
48
49
  });
49
50
  export {
50
51
  N as ConfigProvider,
51
- a as globalConfigCached
52
+ i as globalConfigCached
52
53
  };
@@ -1,7 +1,7 @@
1
1
  import { ConfigProviderProps } from './config-provider-props';
2
- import { InjectionKey, Ref } from 'vue';
2
+ import { InjectionKey, Ref, VNode } from 'vue';
3
3
  import { SizeType, SorterResult } from '../pro-table/types/table';
4
- import { Fn } from '../type';
4
+ import { Fn, Recordable } from '../type';
5
5
  import { CommonOptionItem, ApiSelectOption } from '../pro-form/components/interface';
6
6
  import { client } from '@aplus-frontend/oss';
7
7
  export type ConfigProviderContext = Partial<ConfigProviderProps>;
@@ -38,6 +38,10 @@ export type ApUploadConfig = {
38
38
  };
39
39
  accept?: string;
40
40
  };
41
+ export type ValueTypeRenderConfig = {
42
+ render?: (text: any, renderProps: Recordable) => VNode;
43
+ renderFormItem?: (fieldProps: Recordable) => VNode;
44
+ };
41
45
  export type ApDescriptionsConfig = {
42
46
  downloadFile?: (url: string, name: string) => void;
43
47
  };
@@ -1,6 +1,6 @@
1
1
  import { MaybeRef } from '@aplus-frontend/utils';
2
2
  import { App, Ref, ComputedRef, ExtractPropTypes, PropType } from 'vue';
3
- import { ConfigProviderContext, ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig } from '../constants';
3
+ import { ConfigProviderContext, ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig, ValueTypeRenderConfig } from '../constants';
4
4
  import { default as __DTS_DEFAULT_0__ } from 'ant-design-vue/es/config-provider/renderEmpty';
5
5
  import { TransformCellTextProps } from 'ant-design-vue/es/table/interface';
6
6
  import { CSPConfig } from 'ant-design-vue/es/config-provider';
@@ -158,4 +158,8 @@ export declare const provideGlobalConfig: (config: MaybeRef<ConfigProviderContex
158
158
  type: PropType<ApDescriptionsConfig>;
159
159
  default: () => {};
160
160
  };
161
+ valueTypeMap: {
162
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
163
+ default: () => {};
164
+ };
161
165
  }>>>> | undefined;
@@ -8,7 +8,7 @@ import { ValidateMessages } from 'ant-design-vue/es/form/interface';
8
8
  import { RequiredMark } from 'ant-design-vue/es/form/Form';
9
9
  import { ThemeConfig } from 'ant-design-vue/es/config-provider/context';
10
10
  import { LocaleType } from '..';
11
- import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig } from './constants';
11
+ import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig, ValueTypeRenderConfig } from './constants';
12
12
  export * from './config-provider-props';
13
13
  export * from './constants';
14
14
  export * from './hooks/use-global-config';
@@ -161,6 +161,10 @@ export declare const APConfigProvider: {
161
161
  type: PropType<ApDescriptionsConfig>;
162
162
  default: () => {};
163
163
  };
164
+ valueTypeMap: {
165
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
166
+ default: () => {};
167
+ };
164
168
  }>>, () => import("vue/jsx-runtime").JSX.Element, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, VNodeProps & AllowedComponentProps & ComponentCustomProps & Readonly< ExtractPropTypes<{
165
169
  iconPrefixCls: StringConstructor;
166
170
  getTargetContainer: {
@@ -306,6 +310,10 @@ export declare const APConfigProvider: {
306
310
  type: PropType<ApDescriptionsConfig>;
307
311
  default: () => {};
308
312
  };
313
+ valueTypeMap: {
314
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
315
+ default: () => {};
316
+ };
309
317
  }>>, {
310
318
  input: {
311
319
  autocomplete?: string;
@@ -344,6 +352,7 @@ export declare const APConfigProvider: {
344
352
  uiMode: "aplus" | "admin";
345
353
  apUpload: ApUploadConfig;
346
354
  apDescriptions: ApDescriptionsConfig;
355
+ valueTypeMap: Record<string, ValueTypeRenderConfig>;
347
356
  }, true, {}, {}, {
348
357
  P: {};
349
358
  B: {};
@@ -496,6 +505,10 @@ export declare const APConfigProvider: {
496
505
  type: PropType<ApDescriptionsConfig>;
497
506
  default: () => {};
498
507
  };
508
+ valueTypeMap: {
509
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
510
+ default: () => {};
511
+ };
499
512
  }>>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, {
500
513
  input: {
501
514
  autocomplete?: string;
@@ -534,6 +547,7 @@ export declare const APConfigProvider: {
534
547
  uiMode: "aplus" | "admin";
535
548
  apUpload: ApUploadConfig;
536
549
  apDescriptions: ApDescriptionsConfig;
550
+ valueTypeMap: Record<string, ValueTypeRenderConfig>;
537
551
  }>;
538
552
  __isFragment?: never;
539
553
  __isTeleport?: never;
@@ -683,6 +697,10 @@ export declare const APConfigProvider: {
683
697
  type: PropType<ApDescriptionsConfig>;
684
698
  default: () => {};
685
699
  };
700
+ valueTypeMap: {
701
+ type: PropType<Record<string, ValueTypeRenderConfig>>;
702
+ default: () => {};
703
+ };
686
704
  }>>, () => import("vue/jsx-runtime").JSX.Element, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {
687
705
  input: {
688
706
  autocomplete?: string;
@@ -721,6 +739,7 @@ export declare const APConfigProvider: {
721
739
  uiMode: "aplus" | "admin";
722
740
  apUpload: ApUploadConfig;
723
741
  apDescriptions: ApDescriptionsConfig;
742
+ valueTypeMap: Record<string, ValueTypeRenderConfig>;
724
743
  }, {}, string, {}> & ( VNodeProps & ( AllowedComponentProps & ComponentCustomProps & ( Plugin & (new (...args: any[]) => {
725
744
  $props: {
726
745
  onClick?: () => void;