@aplus-frontend/ui 0.1.29 → 0.1.31

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 (71) hide show
  1. package/es/index.mjs +154 -149
  2. package/es/src/ap-button/ap-button.vue.d.ts +48 -0
  3. package/es/src/ap-button/ap-button.vue.mjs +116 -0
  4. package/es/src/ap-button/ap-button.vue2.mjs +4 -0
  5. package/es/src/ap-button/index.css +6 -0
  6. package/es/src/ap-button/index.d.ts +3 -0
  7. package/es/src/ap-button/index.mjs +2 -0
  8. package/es/src/ap-button/interface.d.ts +7 -0
  9. package/es/src/ap-button/interface.mjs +1 -0
  10. package/es/src/ap-form/ap-form.vue.d.ts +1 -1
  11. package/es/src/ap-form/dependency/index.vue.d.ts +28 -0
  12. package/es/src/ap-form/dependency/index.vue.mjs +37 -0
  13. package/es/src/ap-form/dependency/index.vue2.mjs +4 -0
  14. package/es/src/ap-form/index.d.ts +3 -1
  15. package/es/src/ap-form/index.mjs +10 -6
  16. package/es/src/ap-form/interface.d.ts +3 -0
  17. package/es/src/ap-form/modal-form/index.vue.d.ts +2 -2
  18. package/es/src/ap-form/search-form/index.vue.d.ts +2 -2
  19. package/es/src/ap-table/ap-table.vue.mjs +1 -1
  20. package/es/src/ap-table/components/setting/sorter/index.vue2.mjs +84 -89
  21. package/es/src/ap-table/utils.mjs +42 -42
  22. package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +52 -50
  23. package/es/src/business/hooks/useTableRefresh.d.ts +1 -1
  24. package/es/src/business/hooks/useTableRefresh.mjs +1 -1
  25. package/es/src/editable-table/form-item.vue.d.ts +1 -1
  26. package/es/src/editable-table/form-item.vue.mjs +41 -41
  27. package/es/src/editable-table/index.vue.d.ts +1 -1
  28. package/es/src/editable-table/index.vue.mjs +29 -29
  29. package/es/src/index.d.ts +1 -0
  30. package/es/src/index.mjs +256 -250
  31. package/es/src/theme/ap-button/ap-button.css +6 -0
  32. package/es/src/work-order-modal/index.mjs +4 -3
  33. package/es/src/work-order-modal/interfaces.d.ts +3 -0
  34. package/es/src/work-order-modal/interfaces.mjs +6 -1
  35. package/es/src/work-order-modal/work-order-modal.vue.mjs +28 -28
  36. package/lib/index.js +1 -1
  37. package/lib/src/ap-button/ap-button.vue.d.ts +48 -0
  38. package/lib/src/ap-button/ap-button.vue.js +1 -0
  39. package/lib/src/ap-button/ap-button.vue2.js +1 -0
  40. package/lib/src/ap-button/index.css +6 -0
  41. package/lib/src/ap-button/index.d.ts +3 -0
  42. package/lib/src/ap-button/index.js +1 -0
  43. package/lib/src/ap-button/interface.d.ts +7 -0
  44. package/lib/src/ap-button/interface.js +1 -0
  45. package/lib/src/ap-form/ap-form.vue.d.ts +1 -1
  46. package/lib/src/ap-form/dependency/index.vue.d.ts +28 -0
  47. package/lib/src/ap-form/dependency/index.vue.js +1 -0
  48. package/lib/src/ap-form/dependency/index.vue2.js +1 -0
  49. package/lib/src/ap-form/index.d.ts +3 -1
  50. package/lib/src/ap-form/index.js +1 -1
  51. package/lib/src/ap-form/interface.d.ts +3 -0
  52. package/lib/src/ap-form/modal-form/index.vue.d.ts +2 -2
  53. package/lib/src/ap-form/search-form/index.vue.d.ts +2 -2
  54. package/lib/src/ap-table/ap-table.vue.js +1 -1
  55. package/lib/src/ap-table/components/setting/sorter/index.vue2.js +1 -1
  56. package/lib/src/ap-table/utils.js +1 -1
  57. package/lib/src/business/ap-export-group/ApExportGroup.vue2.js +1 -1
  58. package/lib/src/business/hooks/useTableRefresh.d.ts +1 -1
  59. package/lib/src/business/hooks/useTableRefresh.js +1 -1
  60. package/lib/src/editable-table/form-item.vue.d.ts +1 -1
  61. package/lib/src/editable-table/form-item.vue.js +1 -1
  62. package/lib/src/editable-table/index.vue.d.ts +1 -1
  63. package/lib/src/editable-table/index.vue.js +1 -1
  64. package/lib/src/index.d.ts +1 -0
  65. package/lib/src/index.js +1 -1
  66. package/lib/src/theme/ap-button/ap-button.css +6 -0
  67. package/lib/src/work-order-modal/index.js +1 -1
  68. package/lib/src/work-order-modal/interfaces.d.ts +3 -0
  69. package/lib/src/work-order-modal/interfaces.js +1 -1
  70. package/lib/src/work-order-modal/work-order-modal.vue.js +1 -1
  71. package/package.json +1 -1
@@ -0,0 +1,28 @@
1
+ import { ApFormDependencyProps } from '../interface';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ type ApFormDependencySlots = {
4
+ default(values: Record<string, any>): any;
5
+ };
6
+ declare function __VLS_template(): {
7
+ slots: Readonly<ApFormDependencySlots> & ApFormDependencySlots;
8
+ refs: {};
9
+ attrs: Partial<{}>;
10
+ };
11
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
12
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<ApFormDependencyProps>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<ApFormDependencyProps>>>, {}, {}>;
13
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
14
+ export default _default;
15
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
16
+ type __VLS_TypePropsToOption<T> = {
17
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
18
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
19
+ } : {
20
+ type: PropType<T[K]>;
21
+ required: true;
22
+ };
23
+ };
24
+ type __VLS_WithTemplateSlots<T, S> = T & {
25
+ new (): {
26
+ $slots: S;
27
+ };
28
+ };
@@ -0,0 +1,37 @@
1
+ import { defineComponent as p, ref as m, watchEffect as y, unref as _, renderSlot as g } from "vue";
2
+ import { useInjectForm as h } from "../context.mjs";
3
+ import { isArray as V, isNumber as d, cloneDeep as b } from "lodash-unified";
4
+ const A = /* @__PURE__ */ p({
5
+ __name: "index",
6
+ props: {
7
+ nameList: {}
8
+ },
9
+ setup(u) {
10
+ function a(t, s) {
11
+ return V(s) ? s.reduce((o, e) => o == null ? void 0 : o[e], t) : t == null ? void 0 : t[s];
12
+ }
13
+ const c = u, {
14
+ model: i
15
+ } = h(), f = m({});
16
+ function l(t, s, o) {
17
+ let e = s;
18
+ for (let r = 0; r < t.length; r++) {
19
+ const n = t[r];
20
+ r === t.length - 1 ? e[n] = o : (d(n) ? (Array.isArray(e) || (e[n] = []), e[n] || (e[n] = {})) : (typeof e[n] != "object" || e[n] === null) && (e[n] = {}), e = e[n]);
21
+ }
22
+ }
23
+ return y(() => {
24
+ const t = b(f.value);
25
+ for (const s of c.nameList) {
26
+ const o = [s].flat(1), e = a(_(i), o);
27
+ l(o, t, e);
28
+ }
29
+ f.value = t;
30
+ }), (t, s) => g(t.$slots, "default", {
31
+ values: f.value
32
+ });
33
+ }
34
+ });
35
+ export {
36
+ A as default
37
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./index.vue.mjs";
2
+ export {
3
+ f as default
4
+ };
@@ -5,6 +5,7 @@ import { default as ApFormList } from './ap-form-list.vue';
5
5
  import { default as ApFormSearchForm } from './search-form/index.vue';
6
6
  import { default as ApFormModalForm } from './modal-form/index.vue';
7
7
  import { default as useWatch } from './hooks/use-watch';
8
+ import { default as ApFormDependency } from './dependency/index.vue';
8
9
  type ApFormMixedProps = typeof _ApForm & {
9
10
  FormItem: typeof ApFormItem;
10
11
  FormItemGroup: typeof ApFormItemGroup;
@@ -12,8 +13,9 @@ type ApFormMixedProps = typeof _ApForm & {
12
13
  SearchForm: typeof ApFormSearchForm;
13
14
  ModalForm: typeof ApFormModalForm;
14
15
  useWatch: typeof useWatch;
16
+ Dependency: typeof ApFormDependency;
15
17
  };
16
18
  declare const ApForm: ApFormMixedProps;
17
19
  export * from './items';
18
20
  export * from './interface';
19
- export { ApForm, ApFormItem, ApFormItemGroup, ApFormList, ApFormSearchForm, ApFormModalForm };
21
+ export { ApForm, ApFormItem, ApFormItemGroup, ApFormList, ApFormSearchForm, ApFormModalForm, ApFormDependency };
@@ -5,25 +5,29 @@ import "./ap-form-list.vue2.mjs";
5
5
  import "./search-form/index.vue2.mjs";
6
6
  import "./modal-form/index.vue2.mjs";
7
7
  import o from "./hooks/use-watch.mjs";
8
+ import "./dependency/index.vue2.mjs";
8
9
  import "./items/index.mjs";
9
10
  import "./interface.mjs";
10
11
  import r from "./ap-form.vue2.mjs";
11
- import t from "./ap-form-item.vue.mjs";
12
- import p from "./ap-form-item-group/index.vue.mjs";
12
+ import p from "./ap-form-item.vue.mjs";
13
+ import t from "./ap-form-item-group/index.vue.mjs";
13
14
  import i from "./ap-form-list.vue.mjs";
14
15
  import a from "./search-form/index.vue.mjs";
15
16
  import s from "./modal-form/index.vue.mjs";
17
+ import e from "./dependency/index.vue.mjs";
16
18
  const m = r;
17
- m.FormItem = t;
18
- m.FormItemGroup = p;
19
+ m.FormItem = p;
20
+ m.FormItemGroup = t;
19
21
  m.FormList = i;
20
22
  m.SearchForm = a;
21
23
  m.ModalForm = s;
22
24
  m.useWatch = o;
25
+ m.Dependency = e;
23
26
  export {
24
27
  m as ApForm,
25
- t as ApFormItem,
26
- p as ApFormItemGroup,
28
+ e as ApFormDependency,
29
+ p as ApFormItem,
30
+ t as ApFormItemGroup,
27
31
  i as ApFormList,
28
32
  s as ApFormModalForm,
29
33
  a as ApFormSearchForm
@@ -126,3 +126,6 @@ export type ApFormItemSlots = {
126
126
  extra: any;
127
127
  default(): VNode[];
128
128
  };
129
+ export type ApFormDependencyProps = {
130
+ nameList: NamePath[];
131
+ };
@@ -428,7 +428,7 @@ declare function __VLS_template(): {
428
428
  };
429
429
  }>>, {
430
430
  resetFields: () => Promise<void>;
431
- clearValidate: (name?: NamePath) => void;
431
+ clearValidate: (name?: NamePath | NamePath[]) => void;
432
432
  validateFields: (nameList?: NamePath[] | string, options?: ValidateOptions) => Promise<{
433
433
  [key: string]: any;
434
434
  }> | undefined;
@@ -620,7 +620,7 @@ declare function __VLS_template(): {
620
620
  };
621
621
  }>>, "validate" | "setFieldsValue" | "resetFields" | "getFieldsValue" | "clearValidate" | "validateFields" | "scrollToField" | "setFieldValue" | "getInternalInstance" | "registerWatch"> & ShallowUnwrapRef<{
622
622
  resetFields: () => Promise<void>;
623
- clearValidate: (name?: NamePath) => void;
623
+ clearValidate: (name?: NamePath | NamePath[]) => void;
624
624
  validateFields: (nameList?: NamePath[] | string, options?: ValidateOptions) => Promise<{
625
625
  [key: string]: any;
626
626
  }> | undefined;
@@ -423,7 +423,7 @@ declare function __VLS_template(): {
423
423
  };
424
424
  }>>, {
425
425
  resetFields: () => Promise<void>;
426
- clearValidate: (name?: NamePath) => void;
426
+ clearValidate: (name?: NamePath | NamePath[]) => void;
427
427
  validateFields: (nameList?: NamePath[] | string, options?: ValidateOptions) => Promise<{
428
428
  [key: string]: any;
429
429
  }> | undefined;
@@ -615,7 +615,7 @@ declare function __VLS_template(): {
615
615
  };
616
616
  }>>, "validate" | "setFieldsValue" | "resetFields" | "getFieldsValue" | "clearValidate" | "validateFields" | "scrollToField" | "setFieldValue" | "getInternalInstance" | "registerWatch"> & ShallowUnwrapRef<{
617
617
  resetFields: () => Promise<void>;
618
- clearValidate: (name?: NamePath) => void;
618
+ clearValidate: (name?: NamePath | NamePath[]) => void;
619
619
  validateFields: (nameList?: NamePath[] | string, options?: ValidateOptions) => Promise<{
620
620
  [key: string]: any;
621
621
  }> | undefined;
@@ -415,7 +415,7 @@ const Ca = /* @__PURE__ */ Re({
415
415
  records: W.value.dataSource
416
416
  })]),
417
417
  _: 2
418
- }, [Q(l(_)(S, ["title", "searchFormExtra", "headerCell"]), (t, r) => ({
418
+ }, [Q(l(_)(S, ["title", "searchFormExtra", "headerCell", "summary"]), (t, r) => ({
419
419
  name: r,
420
420
  fn: b((d) => [w(e.$slots, r, Be(xe(d || {})))])
421
421
  }))]), 1040, ["class", "size", "table-layout", "columns"])], 6)], 2));
@@ -1,14 +1,14 @@
1
- import { defineComponent as O, ref as x, unref as n, computed as $, watch as q, onMounted as G, openBlock as i, createElementBlock as _, normalizeClass as f, createVNode as N, withCtx as h, createElementVNode as g, toDisplayString as k, createTextVNode as H, createBlock as p, createCommentVNode as s } from "vue";
2
- import { Flex as J, Button as K, Divider as P } from "ant-design-vue";
3
- import M from "vuedraggable";
1
+ import { defineComponent as A, ref as L, unref as n, computed as O, watch as $, openBlock as c, createElementBlock as y, normalizeClass as d, createVNode as m, withCtx as v, createElementVNode as g, toDisplayString as k, createTextVNode as q, createBlock as b, createCommentVNode as p } from "vue";
2
+ import { Flex as G, Button as H, Divider as J } from "ant-design-vue";
3
+ import N from "vuedraggable";
4
4
  import "../sortable/index.vue.mjs";
5
5
  import "../../../../config-provider/index.mjs";
6
6
  import "../../style/setting/sorter.css";
7
- import { useProvideSorterMethods as Q } from "./context.mjs";
8
- import { useNamespace as W } from "../../../../config-provider/hooks/use-namespace.mjs";
9
- import { useLocale as X } from "../../../../config-provider/hooks/use-locale.mjs";
7
+ import { useProvideSorterMethods as K } from "./context.mjs";
8
+ import { useNamespace as P } from "../../../../config-provider/hooks/use-namespace.mjs";
9
+ import { useLocale as Q } from "../../../../config-provider/hooks/use-locale.mjs";
10
10
  import R from "../sortable/index.vue2.mjs";
11
- const Y = { key: 0 }, Z = { key: 1 }, ee = { key: 2 }, fe = /* @__PURE__ */ O({
11
+ const W = { key: 0 }, X = { key: 1 }, Y = { key: 2 }, ce = /* @__PURE__ */ A({
12
12
  __name: "index",
13
13
  props: {
14
14
  value: {},
@@ -16,11 +16,11 @@ const Y = { key: 0 }, Z = { key: 1 }, ee = { key: 2 }, fe = /* @__PURE__ */ O({
16
16
  },
17
17
  emits: ["update:value"],
18
18
  setup(V, { emit: B }) {
19
- const u = x([]), r = x([]), c = x([]), y = x(!1), { b: d } = W("column-setting-sorter"), { t: v } = X(), C = V, S = B;
20
- Q({
19
+ const i = L([]), s = L([]), r = L([]), { b: u } = P("column-setting-sorter"), { t: h } = Q(), x = V, S = B;
20
+ K({
21
21
  fixedToLeft: I,
22
- fixedToRight: U,
23
- unFixed: z
22
+ fixedToRight: M,
23
+ unFixed: U
24
24
  });
25
25
  function F(e, t) {
26
26
  const o = t[0].findIndex(
@@ -35,8 +35,8 @@ const Y = { key: 0 }, Z = { key: 1 }, ee = { key: 2 }, fe = /* @__PURE__ */ O({
35
35
  t[1].splice(a, 1);
36
36
  }
37
37
  }
38
- function T(e, t) {
39
- const o = [...n(u.value)], a = [...n(c.value)], l = [...n(r.value)], b = {
38
+ function _(e, t) {
39
+ const o = [...n(i.value)], a = [...n(r.value)], l = [...n(s.value)], w = {
40
40
  left: {
41
41
  target: o,
42
42
  search: [l, a]
@@ -50,154 +50,149 @@ const Y = { key: 0 }, Z = { key: 1 }, ee = { key: 2 }, fe = /* @__PURE__ */ O({
50
50
  search: [o, a]
51
51
  }
52
52
  }[t];
53
- return t === "right" ? b.target.unshift(e) : b.target.push(e), F(
53
+ return t === "right" ? w.target.unshift(e) : w.target.push(e), F(
54
54
  e,
55
- b.search
55
+ w.search
56
56
  ), [...o, ...l, ...a];
57
57
  }
58
58
  function I(e) {
59
- const t = T(e, "left");
60
- m(t);
59
+ const t = _(e, "left");
60
+ f(t);
61
61
  }
62
- function U(e) {
63
- const t = T(e, "right");
64
- m(t);
62
+ function M(e) {
63
+ const t = _(e, "right");
64
+ f(t);
65
65
  }
66
- function z(e) {
67
- const t = T(e, "normal");
68
- m(t);
66
+ function U(e) {
67
+ const t = _(e, "normal");
68
+ f(t);
69
69
  }
70
- function w(e) {
70
+ function C(e) {
71
71
  var t;
72
72
  return (t = e.children) != null && t.length ? e.children.some((o) => o.show) : e.show;
73
73
  }
74
- function L(e, t) {
74
+ function T(e, t) {
75
75
  e.value ? e.value.push(t) : e.value = [t];
76
76
  }
77
- const D = $(() => {
77
+ const z = O(() => {
78
78
  let e = 0;
79
79
  function t(o) {
80
80
  var a;
81
81
  for (const l of o)
82
82
  (a = l.children) != null && a.length ? t(l.children) : l.show && (e += 1);
83
83
  }
84
- return t(C.value), e;
84
+ return t(x.value), e;
85
85
  });
86
+ function D(e) {
87
+ f([...e, ...n(s), ...n(r)]);
88
+ }
86
89
  function E(e) {
87
- m([...e, ...n(r), ...n(c)]);
90
+ f([...n(i), ...e, ...n(r)]);
88
91
  }
89
92
  function j(e) {
90
- m([...n(u), ...e, ...n(c)]);
91
- }
92
- function A(e) {
93
- m([...n(u), ...n(r), ...e]);
93
+ f([...n(i), ...n(s), ...e]);
94
94
  }
95
- function m(e) {
95
+ function f(e) {
96
96
  S("update:value", e);
97
97
  }
98
- return q(
99
- () => C.value,
98
+ return $(
99
+ () => x.value,
100
100
  (e) => {
101
101
  if (e) {
102
- u.value = [], r.value = [], c.value = [];
102
+ i.value = [], s.value = [], r.value = [];
103
103
  for (const t of e)
104
- t.fixed === "left" ? L(u, t) : t.fixed === "right" ? L(c, t) : L(r, t);
104
+ t.fixed === "left" ? T(i, t) : t.fixed === "right" ? T(r, t) : T(s, t);
105
105
  }
106
106
  },
107
107
  { immediate: !0 }
108
- ), G(() => {
109
- y.value = !0;
110
- }), (e, t) => (i(), _("div", {
111
- class: f(n(d)())
108
+ ), (e, t) => (c(), y("div", {
109
+ class: d(n(u)())
112
110
  }, [
113
- N(n(J), {
114
- class: f(n(d)("header")),
111
+ m(n(G), {
112
+ class: d(n(u)("header")),
115
113
  align: "center",
116
114
  justify: "space-between"
117
115
  }, {
118
- default: h(() => [
116
+ default: v(() => [
119
117
  g("span", {
120
- class: f(n(d)("header-title"))
121
- }, k(n(v)("ap.apTable.setting.selectCount", { count: D.value })), 3),
122
- N(n(K), {
118
+ class: d(n(u)("header-title"))
119
+ }, k(n(h)("ap.apTable.setting.selectCount", { count: z.value })), 3),
120
+ m(n(H), {
123
121
  type: "link",
124
122
  size: "small",
125
123
  style: { padding: "0" },
126
- onClick: C.onReset
124
+ onClick: x.onReset
127
125
  }, {
128
- default: h(() => [
129
- H(k(n(v)("ap.apTable.setting.reset")), 1)
126
+ default: v(() => [
127
+ q(k(n(h)("ap.apTable.setting.reset")), 1)
130
128
  ]),
131
129
  _: 1
132
130
  }, 8, ["onClick"])
133
131
  ]),
134
132
  _: 1
135
133
  }, 8, ["class"]),
136
- N(n(P), { style: { margin: "0px" } }),
134
+ m(n(J), { style: { margin: "0px" } }),
137
135
  g("div", {
138
- class: f(n(d)("content"))
136
+ class: d(n(u)("content"))
139
137
  }, [
140
- u.value.length ? (i(), _("div", Y, [
138
+ i.value.length ? (c(), y("div", W, [
141
139
  g("span", {
142
- class: f(n(d)("section-title"))
143
- }, k(n(v)("ap.apTable.setting.fixToLeft")), 3),
144
- y.value ? (i(), p(n(M), {
145
- key: 0,
146
- "model-value": u.value,
147
- "onUpdate:modelValue": E,
140
+ class: d(n(u)("section-title"))
141
+ }, k(n(h)("ap.apTable.setting.fixToLeft")), 3),
142
+ m(n(N), {
143
+ "model-value": i.value,
144
+ "onUpdate:modelValue": D,
148
145
  "item-key": "key"
149
146
  }, {
150
- item: h(({ element: o }) => [
151
- w(o) ? (i(), p(R, {
147
+ item: v(({ element: o }) => [
148
+ C(o) ? (c(), b(R, {
152
149
  key: 0,
153
150
  value: o
154
- }, null, 8, ["value"])) : s("", !0)
151
+ }, null, 8, ["value"])) : p("", !0)
155
152
  ]),
156
153
  _: 1
157
- }, 8, ["model-value"])) : s("", !0)
158
- ])) : s("", !0),
159
- r.value.length ? (i(), _("div", Z, [
154
+ }, 8, ["model-value"])
155
+ ])) : p("", !0),
156
+ s.value.length ? (c(), y("div", X, [
160
157
  g("span", {
161
- class: f(n(d)("section-title"))
162
- }, k(n(v)("ap.apTable.setting.unFixed")), 3),
163
- y.value ? (i(), p(n(M), {
164
- key: 0,
165
- "model-value": r.value,
166
- "onUpdate:modelValue": j,
158
+ class: d(n(u)("section-title"))
159
+ }, k(n(h)("ap.apTable.setting.unFixed")), 3),
160
+ m(n(N), {
161
+ "model-value": s.value,
162
+ "onUpdate:modelValue": E,
167
163
  "item-key": "key"
168
164
  }, {
169
- item: h(({ element: o }) => [
170
- w(o) ? (i(), p(R, {
165
+ item: v(({ element: o }) => [
166
+ C(o) ? (c(), b(R, {
171
167
  key: 0,
172
168
  value: o
173
- }, null, 8, ["value"])) : s("", !0)
169
+ }, null, 8, ["value"])) : p("", !0)
174
170
  ]),
175
171
  _: 1
176
- }, 8, ["model-value"])) : s("", !0)
177
- ])) : s("", !0),
178
- c.value.length ? (i(), _("div", ee, [
172
+ }, 8, ["model-value"])
173
+ ])) : p("", !0),
174
+ r.value.length ? (c(), y("div", Y, [
179
175
  g("span", {
180
- class: f(n(d)("section-title"))
181
- }, k(n(v)("ap.apTable.setting.fixToRight")), 3),
182
- y.value ? (i(), p(n(M), {
183
- key: 0,
184
- "model-value": c.value,
185
- "onUpdate:modelValue": A,
176
+ class: d(n(u)("section-title"))
177
+ }, k(n(h)("ap.apTable.setting.fixToRight")), 3),
178
+ m(n(N), {
179
+ "model-value": r.value,
180
+ "onUpdate:modelValue": j,
186
181
  "item-key": "key"
187
182
  }, {
188
- item: h(({ element: o }) => [
189
- w(o) ? (i(), p(R, {
183
+ item: v(({ element: o }) => [
184
+ C(o) ? (c(), b(R, {
190
185
  key: 0,
191
186
  value: o
192
- }, null, 8, ["value"])) : s("", !0)
187
+ }, null, 8, ["value"])) : p("", !0)
193
188
  ]),
194
189
  _: 1
195
- }, 8, ["model-value"])) : s("", !0)
196
- ])) : s("", !0)
190
+ }, 8, ["model-value"])
191
+ ])) : p("", !0)
197
192
  ], 2)
198
193
  ], 2));
199
194
  }
200
195
  });
201
196
  export {
202
- fe as default
197
+ ce as default
203
198
  };
@@ -1,20 +1,20 @@
1
- import { isVNode as T, createVNode as u, mergeProps as f, cloneVNode as b, Fragment as y } from "vue";
2
- import { isObject as c, isArray as p, isUndefined as g, isFunction as h, omit as j, isBoolean as F, isString as a } from "lodash-unified";
3
- import { apTableRenderItemMap as O, apTableFormItemMap as E } from "./constants.mjs";
4
- import { isType as x } from "@fruits-chain/utils";
1
+ import { isVNode as m, createVNode as u, mergeProps as f, cloneVNode as T, Fragment as b } from "vue";
2
+ import { isObject as c, isArray as p, isUndefined as y, isFunction as g, omit as h, isBoolean as j, isString as a } from "lodash-unified";
3
+ import { apTableRenderItemMap as F, apTableFormItemMap as O } from "./constants.mjs";
4
+ import { isType as E } from "@fruits-chain/utils";
5
5
  import "../ap-form/index.mjs";
6
- import { Tooltip as N } from "ant-design-vue";
7
- import { QuestionCircleOutlined as S } from "@ant-design/icons-vue";
8
- import I from "../ap-form/ap-form-item.vue.mjs";
9
- function v(t) {
10
- return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !T(t);
6
+ import { Tooltip as x } from "ant-design-vue";
7
+ import { QuestionCircleOutlined as N } from "@ant-design/icons-vue";
8
+ import S from "../ap-form/ap-form-item.vue.mjs";
9
+ function I(t) {
10
+ return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !m(t);
11
11
  }
12
- const P = (t, e, n) => {
12
+ const v = (t, e, n) => {
13
13
  let r = {};
14
14
  return c(t) ? Object.keys(t).forEach((o) => {
15
- c(t[o]) ? r[o] = P(t[o], e[o], n) : r[o] = n(t[o], e);
15
+ c(t[o]) ? r[o] = v(t[o], e[o], n) : r[o] = n(t[o], e);
16
16
  }) : r = n(t, e), r;
17
- }, J = (t, e) => {
17
+ }, H = (t, e) => {
18
18
  switch (t) {
19
19
  case "dayjs":
20
20
  return e.valueOf();
@@ -35,15 +35,15 @@ const P = (t, e, n) => {
35
35
  return e;
36
36
  }
37
37
  };
38
- function L(t) {
38
+ function J(t) {
39
39
  return p(t) ? t.join(".") : t;
40
40
  }
41
- function V(t) {
41
+ function P(t) {
42
42
  const e = Object.prototype.toString.call(t).match(/^\[object (.*)\]$/)[1].toLowerCase();
43
43
  return e === "string" && typeof t == "object" ? "object" : t === null ? "null" : t === void 0 ? "undefined" : e;
44
44
  }
45
- const w = (t) => V(t) === "map" ? t : new Map(Object.entries(t || {})), d = (t) => {
46
- const e = [], n = w(t);
45
+ const V = (t) => P(t) === "map" ? t : new Map(Object.entries(t || {})), d = (t) => {
46
+ const e = [], n = V(t);
47
47
  return n.forEach((r, o) => {
48
48
  const i = n.get(o) || n.get(`${o}`);
49
49
  if (i) {
@@ -63,7 +63,7 @@ const w = (t) => V(t) === "map" ? t : new Map(Object.entries(t || {})), d = (t)
63
63
  });
64
64
  }
65
65
  }), e;
66
- }, Q = (t) => g(t) || t < 0 ? 0 : t, U = (t, e, n) => {
66
+ }, L = (t) => y(t) || t < 0 ? 0 : t, Q = (t, e, n) => {
67
67
  if (n)
68
68
  return n;
69
69
  const r = ["select", "date"], o = ["text", "textArea", "number"];
@@ -74,16 +74,16 @@ const w = (t) => V(t) === "map" ? t : new Map(Object.entries(t || {})), d = (t)
74
74
  if (o.includes(e))
75
75
  return t("ap.common.inputText");
76
76
  };
77
- function A(t, e) {
78
- return !t || !h(t) ? t : t(e);
77
+ function w(t, e) {
78
+ return !t || !g(t) ? t : t(e);
79
79
  }
80
- function W(t) {
80
+ function U(t) {
81
81
  let e = t.valueType || "text";
82
82
  return t.valueEnum && (e = "status"), e;
83
83
  }
84
84
  function z(t, e, n, r) {
85
85
  var s;
86
- const o = O[t];
86
+ const o = F[t];
87
87
  if (o)
88
88
  return u(o, f(e, {
89
89
  mode: "read"
@@ -95,34 +95,34 @@ function G(t, e) {
95
95
  if (t.customRenderFormItem)
96
96
  return () => {
97
97
  const o = t.customRenderFormItem(t);
98
- return b(o, {
98
+ return T(o, {
99
99
  ...t.fieldProps,
100
100
  span: t.span,
101
101
  ...o.props || {}
102
102
  });
103
103
  };
104
- const n = E[t.valueType];
104
+ const n = O[t.valueType];
105
105
  if (n)
106
106
  return n;
107
107
  const r = e == null ? void 0 : e[t.valueType];
108
108
  return () => {
109
109
  var i;
110
110
  const o = (i = r == null ? void 0 : r.renderFormItem) == null ? void 0 : i.call(r, t.fieldProps.field);
111
- return o ? u(I, f(t.fieldProps, {
111
+ return o ? u(S, f(t.fieldProps, {
112
112
  span: t.span
113
- }), v(o) ? o : {
113
+ }), I(o) ? o : {
114
114
  default: () => [o]
115
115
  }) : null;
116
116
  };
117
117
  }
118
118
  function K(t, e) {
119
- const n = A(t.fieldProps, e), r = (n == null ? void 0 : n.field) || n || {}, o = t.valueType === "switch", i = t.valueType === "index", s = o ? {
119
+ const n = w(t.fieldProps, e), r = (n == null ? void 0 : n.field) || n || {}, o = t.valueType === "switch", i = t.valueType === "index", s = o ? {
120
120
  checked: e.value
121
121
  } : {
122
122
  value: i ? e.index + 1 : e.value
123
123
  };
124
124
  return t.valueEnum && (r.valueEnum = t.valueEnum), {
125
- ...j(r, ["request"]),
125
+ ...h(r, ["request"]),
126
126
  ...s
127
127
  };
128
128
  }
@@ -130,7 +130,7 @@ function X(t) {
130
130
  const e = {
131
131
  ...t
132
132
  };
133
- return F(t.filters) && t.filters && t.valueEnum && (e.filters = d(t.valueEnum)), e;
133
+ return j(t.filters) && t.filters && t.valueEnum && (e.filters = d(t.valueEnum)), e;
134
134
  }
135
135
  function Y(t, e) {
136
136
  var r;
@@ -141,7 +141,7 @@ function Y(t, e) {
141
141
  }), n;
142
142
  }
143
143
  function Z(t) {
144
- if (!x("Object")(t))
144
+ if (!E("Object")(t))
145
145
  return t;
146
146
  try {
147
147
  return JSON.stringify(t);
@@ -159,40 +159,40 @@ function k(t, e, n, r) {
159
159
  const s = a(t.title) ? u("span", {
160
160
  class: e,
161
161
  title: t.title
162
- }, [t.title]) : t.title, l = t.tooltip ? a(t.tooltip) ? u(y, null, [t.tooltip]) : t.tooltip(t) : null, m = u("span", {
162
+ }, [t.title]) : t.title, l = t.tooltip ? a(t.tooltip) ? u(b, null, [t.tooltip]) : t.tooltip(t) : null;
163
+ return l ? u("span", {
163
164
  style: {
164
165
  display: "inline-flex",
165
166
  alignItems: "center"
166
167
  }
167
- }, [s, u(N, {
168
+ }, [s, u(x, {
168
169
  title: l,
169
170
  placement: "bottom"
170
171
  }, {
171
- default: () => [u(S, {
172
+ default: () => [u(N, {
172
173
  style: {
173
174
  padding: "4px",
174
175
  color: r,
175
176
  verticalAlign: "middle"
176
177
  }
177
178
  }, null)]
178
- })]);
179
- return l ? m : s;
179
+ })]) : s;
180
180
  }
181
181
  export {
182
182
  X as apColumnToColumn,
183
- L as dataIndexToStr,
184
- P as formatParamsValueType,
185
- Q as getColumnOrder,
186
- A as getFieldProps,
187
- U as getPlaceholder,
183
+ J as dataIndexToStr,
184
+ v as formatParamsValueType,
185
+ L as getColumnOrder,
186
+ w as getFieldProps,
187
+ Q as getPlaceholder,
188
188
  G as getSearchFormItemRenderNode,
189
189
  z as getTableCellRenderNode,
190
190
  K as getTableRenderProps,
191
- W as getTableRenderType,
191
+ U as getTableRenderType,
192
192
  k as getTableTitle,
193
- w as objectToMap,
193
+ V as objectToMap,
194
194
  Z as objectToString,
195
- J as parseFieldValue,
195
+ H as parseFieldValue,
196
196
  Y as updateFormProps,
197
197
  d as valueEnumToArray
198
198
  };