@aplus-frontend/ui 0.1.35 → 0.1.37

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 (75) hide show
  1. package/es/index.mjs +136 -133
  2. package/es/src/ap-button/ap-action-button.vue.d.ts +5 -0
  3. package/es/src/ap-button/ap-action-button.vue.mjs +8 -8
  4. package/es/src/ap-form/ap-form.vue2.mjs +93 -93
  5. package/es/src/ap-form/index.d.ts +3 -1
  6. package/es/src/ap-form/index.mjs +5 -1
  7. package/es/src/ap-form/interface.d.ts +4 -0
  8. package/es/src/ap-form/set/index.vue.d.ts +43 -0
  9. package/es/src/ap-form/set/index.vue.mjs +35 -0
  10. package/es/src/ap-form/set/index.vue2.mjs +4 -0
  11. package/es/src/ap-table/ap-table.vue.d.ts +1 -0
  12. package/es/src/ap-table/ap-table.vue.mjs +109 -107
  13. package/es/src/ap-table/components/setting/utils.d.ts +1 -1
  14. package/es/src/ap-table/components/setting/utils.mjs +12 -21
  15. package/es/src/ap-table/components/style/setting/modal.css +15 -3
  16. package/es/src/ap-table/interface.d.ts +5 -0
  17. package/es/src/ap-table/utils.mjs +14 -13
  18. package/es/src/ap-upload/apUpload.vue.mjs +40 -39
  19. package/es/src/business/ap-button-group/ApButtonGroup.vue.d.ts +21 -0
  20. package/es/src/business/ap-button-group/ApButtonGroup.vue.mjs +4 -0
  21. package/es/src/business/ap-button-group/ApButtonGroup.vue2.mjs +71 -0
  22. package/es/src/business/ap-button-group/interface.d.ts +29 -0
  23. package/es/src/business/ap-button-group/interface.mjs +1 -0
  24. package/es/src/business/ap-table-modal/hooks/use-create-table-modal.d.ts +1 -1
  25. package/es/src/business/ap-table-modal/hooks/use-create-table-modal.mjs +11 -11
  26. package/es/src/business/hooks/usePageListApTable.d.ts +1 -0
  27. package/es/src/business/index.d.ts +607 -4
  28. package/es/src/business/index.mjs +27 -23
  29. package/es/src/editable-table/form-item.vue.mjs +76 -97
  30. package/es/src/editable-table/hooks/use-get-columns.mjs +41 -35
  31. package/es/src/editable-table/index.vue.mjs +79 -100
  32. package/es/src/editable-table/style/index.css +12 -0
  33. package/es/src/editable-table/utils.d.ts +8 -1
  34. package/es/src/editable-table/utils.mjs +103 -69
  35. package/es/src/index.mjs +220 -217
  36. package/es/src/theme/ap-table/setting/modal.css +15 -3
  37. package/es/src/theme/editable-table/index.css +12 -0
  38. package/lib/index.js +1 -1
  39. package/lib/src/ap-button/ap-action-button.vue.d.ts +5 -0
  40. package/lib/src/ap-button/ap-action-button.vue.js +1 -1
  41. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  42. package/lib/src/ap-form/index.d.ts +3 -1
  43. package/lib/src/ap-form/index.js +1 -1
  44. package/lib/src/ap-form/interface.d.ts +4 -0
  45. package/lib/src/ap-form/set/index.vue.d.ts +43 -0
  46. package/lib/src/ap-form/set/index.vue.js +1 -0
  47. package/lib/src/ap-form/set/index.vue2.js +1 -0
  48. package/lib/src/ap-table/ap-table.vue.d.ts +1 -0
  49. package/lib/src/ap-table/ap-table.vue.js +1 -1
  50. package/lib/src/ap-table/components/setting/utils.d.ts +1 -1
  51. package/lib/src/ap-table/components/setting/utils.js +1 -1
  52. package/lib/src/ap-table/components/style/setting/modal.css +15 -3
  53. package/lib/src/ap-table/interface.d.ts +5 -0
  54. package/lib/src/ap-table/utils.js +1 -1
  55. package/lib/src/ap-upload/apUpload.vue.js +1 -1
  56. package/lib/src/business/ap-button-group/ApButtonGroup.vue.d.ts +21 -0
  57. package/lib/src/business/ap-button-group/ApButtonGroup.vue.js +1 -0
  58. package/lib/src/business/ap-button-group/ApButtonGroup.vue2.js +1 -0
  59. package/lib/src/business/ap-button-group/interface.d.ts +29 -0
  60. package/lib/src/business/ap-button-group/interface.js +1 -0
  61. package/lib/src/business/ap-table-modal/hooks/use-create-table-modal.d.ts +1 -1
  62. package/lib/src/business/ap-table-modal/hooks/use-create-table-modal.js +1 -1
  63. package/lib/src/business/hooks/usePageListApTable.d.ts +1 -0
  64. package/lib/src/business/index.d.ts +607 -4
  65. package/lib/src/business/index.js +1 -1
  66. package/lib/src/editable-table/form-item.vue.js +1 -1
  67. package/lib/src/editable-table/hooks/use-get-columns.js +1 -1
  68. package/lib/src/editable-table/index.vue.js +1 -1
  69. package/lib/src/editable-table/style/index.css +12 -0
  70. package/lib/src/editable-table/utils.d.ts +8 -1
  71. package/lib/src/editable-table/utils.js +1 -1
  72. package/lib/src/index.js +1 -1
  73. package/lib/src/theme/ap-table/setting/modal.css +15 -3
  74. package/lib/src/theme/editable-table/index.css +12 -0
  75. package/package.json +5 -5
@@ -1,19 +1,17 @@
1
- import { defineComponent as J, useSlots as X, ref as b, watch as R, unref as o, openBlock as p, createBlock as F, withCtx as m, createVNode as x, mergeProps as Y, createSlots as Z, createElementBlock as ee, normalizeClass as te, createCommentVNode as B, createElementVNode as ae, toDisplayString as ne, normalizeStyle as oe, renderList as le, renderSlot as re, normalizeProps as ue, guardReactiveProps as se } from "vue";
2
- import { Table as ie, Tooltip as de } from "ant-design-vue";
3
- import { ApForm as y } from "../ap-form/index.mjs";
4
- import { isEqual as me, isArray as k, isNumber as g, cloneDeep as h, omit as fe } from "lodash-unified";
1
+ import { defineComponent as W, useSlots as $, ref as w, watch as C, unref as o, openBlock as q, createBlock as J, withCtx as c, createVNode as b, mergeProps as Q, createSlots as X, renderList as Y, renderSlot as Z, normalizeProps as ee, guardReactiveProps as te } from "vue";
2
+ import { Table as ae } from "ant-design-vue";
3
+ import { ApForm as p } from "../ap-form/index.mjs";
4
+ import { isEqual as ne, isArray as R, isNumber as x, cloneDeep as h, omit as F } from "lodash-unified";
5
5
  import "../config-provider/index.mjs";
6
6
  import "../hooks/index.mjs";
7
- import { isDef as C } from "../utils/index.mjs";
8
- import { scrollToRowIndex as ce, getColumnIsRequired as pe } from "./utils.mjs";
9
- import xe from "./hooks/use-get-columns.mjs";
7
+ import { isDef as g } from "../utils/index.mjs";
8
+ import { scrollToRowIndex as oe } from "./utils.mjs";
9
+ import le from "./hooks/use-get-columns.mjs";
10
10
  import "./style/index.css";
11
- import { useToken as ye } from "ant-design-vue/es/theme/internal";
12
- import { QuestionCircleOutlined as ge } from "@ant-design/icons-vue";
13
- import { useNamespace as he } from "../config-provider/hooks/use-namespace.mjs";
14
- import { useControllableValue as Ce } from "../hooks/useControllableValue.mjs";
15
- import { useGlobalConfig as ve } from "../config-provider/hooks/use-global-config.mjs";
16
- const ze = /* @__PURE__ */ J({
11
+ import { useNamespace as re } from "../config-provider/hooks/use-namespace.mjs";
12
+ import { useControllableValue as ue } from "../hooks/useControllableValue.mjs";
13
+ import { useGlobalConfig as se } from "../config-provider/hooks/use-global-config.mjs";
14
+ const be = /* @__PURE__ */ W({
17
15
  name: "EditableTable",
18
16
  __name: "index",
19
17
  props: {
@@ -112,147 +110,128 @@ const ze = /* @__PURE__ */ J({
112
110
  onFieldChange: {}
113
111
  },
114
112
  emits: ["update:value"],
115
- setup(V, {
116
- expose: T,
113
+ setup(B, {
114
+ expose: V,
117
115
  emit: D
118
116
  }) {
119
- const l = V, {
120
- b: E,
121
- em: L
122
- } = he("editable-table"), N = X(), _ = D, v = b(), {
117
+ const n = B, {
118
+ b: L
119
+ } = re("editable-table"), T = $(), _ = D, v = w(), {
123
120
  value: u,
124
- updateValue: S
125
- } = Ce(l, _), s = b(), [, A] = ye(), z = ve("valueTypeMap"), c = y.useWatch(l.name, s);
126
- R(() => c.value, (e) => {
121
+ updateValue: E
122
+ } = ue(n, _), s = w(), N = se("valueTypeMap"), m = p.useWatch(n.name, s);
123
+ C(() => m.value, (e) => {
127
124
  var t;
128
- S(e), (t = l.onChange) == null || t.call(l, e);
125
+ E(e), (t = n.onChange) == null || t.call(n, e);
129
126
  }, {
130
127
  deep: !0
131
- }), R(u, (e) => {
128
+ }), C(u, (e) => {
132
129
  var t;
133
- e !== o(c) && (me(e, o(c)) || (t = s.value) == null || t.setFieldValue(l.name, e));
130
+ e !== o(m) && (ne(e, o(m)) || (t = s.value) == null || t.setFieldValue(n.name, e));
134
131
  }, {
135
132
  deep: !0
136
133
  });
137
- const P = xe(l, z);
138
- function I() {
134
+ const k = le(n, N);
135
+ function A() {
139
136
  var e;
140
137
  (e = s.value) == null || e.resetFields();
141
138
  }
142
- function O(e) {
143
- return e ? (k(e) ? e : [e]).map((n) => k(n) ? [l.name, ...n] : [l.name, n]) : void 0;
139
+ function S(e) {
140
+ return e ? (R(e) ? e : [e]).map((l) => R(l) ? [n.name, ...l] : [n.name, l]) : void 0;
144
141
  }
145
- async function j(e, t) {
142
+ async function P(e, t) {
146
143
  var a;
147
- const n = await ((a = s.value) == null ? void 0 : a.validateFields(O(e), t));
148
- return n == null ? void 0 : n[l.name];
144
+ const l = await ((a = s.value) == null ? void 0 : a.validateFields(S(e), t));
145
+ return l == null ? void 0 : l[n.name];
149
146
  }
150
- function q(e, t) {
151
- var r, i, d;
152
- const n = ((r = o(u)) == null ? void 0 : r.length) || 0;
153
- if (C(l.maxLength) && n >= l.maxLength)
147
+ function j(e, t) {
148
+ var r, d, i;
149
+ const l = ((r = o(u)) == null ? void 0 : r.length) || 0;
150
+ if (g(n.maxLength) && l >= n.maxLength)
154
151
  return;
155
152
  const a = [...o(u) || []];
156
- C(t) ? a.splice(t, 0, {
153
+ g(t) ? a.splice(t, 0, {
157
154
  ...e || {}
158
155
  }) : a.push({
159
156
  ...e || {}
160
- }), (d = (i = s.value) == null ? void 0 : i.setFieldValue) == null || d.call(i, l.name, a);
157
+ }), (i = (d = s.value) == null ? void 0 : d.setFieldValue) == null || i.call(d, n.name, a);
161
158
  }
162
- function K(e, t = "suffix") {
163
- var d, f, w;
164
- const n = ((d = o(u)) == null ? void 0 : d.length) || 0, a = g(e) ? e : e.length;
165
- if (C(l.maxLength) && n + a > l.maxLength)
159
+ function z(e, t = "suffix") {
160
+ var i, f, y;
161
+ const l = ((i = o(u)) == null ? void 0 : i.length) || 0, a = x(e) ? e : e.length;
162
+ if (g(n.maxLength) && l + a > n.maxLength)
166
163
  return;
167
- const r = [...o(u) || []], i = g(e) ? new Array(e).fill({}) : h(e);
168
- t === "suffix" ? r.push(...i) : r.unshift(...i), (w = (f = s.value) == null ? void 0 : f.setFieldValue) == null || w.call(f, l.name, r);
164
+ const r = [...o(u) || []], d = x(e) ? new Array(e).fill({}) : h(e);
165
+ t === "suffix" ? r.push(...d) : r.unshift(...d), (y = (f = s.value) == null ? void 0 : f.setFieldValue) == null || y.call(f, n.name, r);
169
166
  }
170
- function M(e) {
167
+ function I(e) {
171
168
  var a, r;
172
169
  let t = h(o(u) || []);
173
- const n = g(e) ? [e] : e;
174
- t = t.filter((i, d) => !n.includes(d)), (r = (a = s.value) == null ? void 0 : a.setFieldValue) == null || r.call(a, l.name, t);
170
+ const l = x(e) ? [e] : e;
171
+ t = t.filter((d, i) => !l.includes(i)), (r = (a = s.value) == null ? void 0 : a.setFieldValue) == null || r.call(a, n.name, t);
175
172
  }
176
- function G() {
173
+ function O() {
177
174
  return o(u);
178
175
  }
179
- function H(e) {
176
+ function K(e) {
180
177
  var t;
181
- (t = s.value) == null || t.setFieldValue(l.name, e);
178
+ (t = s.value) == null || t.setFieldValue(n.name, e);
182
179
  }
183
- function U(e) {
180
+ function M(e) {
184
181
  var t;
185
182
  return (t = o(u)) == null ? void 0 : t[e];
186
183
  }
187
- function W(e, t, n = !0) {
188
- var r, i;
184
+ function G(e, t, l = !0) {
185
+ var r, d;
189
186
  const a = h(o(u));
190
187
  a[e] && (a[e] = {
191
- ...n ? a[e] : {},
188
+ ...l ? a[e] : {},
192
189
  ...t
193
- }, (i = (r = s.value) == null ? void 0 : r.setFieldValue) == null || i.call(r, l.name, [...a]));
190
+ }, (d = (r = s.value) == null ? void 0 : r.setFieldValue) == null || d.call(r, n.name, [...a]));
194
191
  }
195
- function $(e, t) {
192
+ function H(e, t) {
196
193
  var a;
197
- const n = e === "end" ? u.value.length - 1 : e;
198
- ce(n, (a = v.value) == null ? void 0 : a.$el, t);
194
+ const l = e === "end" ? u.value.length - 1 : e;
195
+ oe(l, (a = v.value) == null ? void 0 : a.$el, t);
199
196
  }
200
- function Q() {
197
+ function U() {
201
198
  var e, t;
202
- (t = (e = s.value) == null ? void 0 : e.setFieldValue) == null || t.call(e, l.name, []);
199
+ (t = (e = s.value) == null ? void 0 : e.setFieldValue) == null || t.call(e, n.name, []);
203
200
  }
204
- return T({
205
- resetFields: I,
206
- validateFields: j,
207
- add: q,
208
- remove: M,
209
- getRowData: U,
210
- getRowsData: G,
211
- setRowData: W,
212
- addMultiple: K,
213
- scrollTo: $,
214
- clear: Q,
215
- setTableData: H
216
- }), (e, t) => (p(), F(o(y), {
201
+ return V({
202
+ resetFields: A,
203
+ validateFields: P,
204
+ add: j,
205
+ remove: I,
206
+ getRowData: M,
207
+ getRowsData: O,
208
+ setRowData: G,
209
+ addMultiple: z,
210
+ scrollTo: H,
211
+ clear: U,
212
+ setTableData: K
213
+ }), (e, t) => (q(), J(o(p), {
217
214
  "initial-values": {
218
- [l.name]: o(u)
215
+ [n.name]: o(u)
219
216
  },
220
217
  ref_key: "formRef",
221
218
  ref: s
222
219
  }, {
223
- default: m(() => [x(o(y).FormItem, {
220
+ default: c(() => [b(o(p).FormItem, {
224
221
  name: e.name,
225
222
  "no-style": ""
226
223
  }, {
227
- default: m(() => [x(o(ie), Y(o(fe)(l, ["name", "value", "onUpdate:value", "maxLength", "onChange"]), {
228
- class: o(E)(),
229
- columns: o(P),
224
+ default: c(() => [b(o(ae), Q(o(F)(n, ["name", "value", "onUpdate:value", "maxLength", "onChange"]), {
225
+ class: o(L)(),
226
+ columns: o(k),
230
227
  "data-source": o(u),
231
228
  ref_key: "tableRef",
232
229
  ref: v
233
- }), Z({
234
- headerCell: m(({
235
- column: n
236
- }) => [o(pe)(n) ? (p(), ee("span", {
237
- key: 0,
238
- class: te(o(L)("header-cell", "required"))
239
- }, "*", 2)) : B("", !0), ae("span", null, ne(n.title), 1), n.tooltip ? (p(), F(o(de), {
240
- key: 1,
241
- title: n.tooltip,
242
- placement: "bottom"
243
- }, {
244
- default: m(() => [x(o(ge), {
245
- style: oe({
246
- paddingLeft: "4px",
247
- color: o(A).colorPrimary
248
- })
249
- }, null, 8, ["style"])]),
250
- _: 2
251
- }, 1032, ["title"])) : B("", !0)]),
230
+ }), X({
252
231
  _: 2
253
- }, [le(N, (n, a) => ({
232
+ }, [Y(o(F)(T, ["headerCell"]), (l, a) => ({
254
233
  name: a,
255
- fn: m((r) => [re(e.$slots, a, ue(se(r || {})))])
234
+ fn: c((r) => [Z(e.$slots, a, ee(te(r || {})))])
256
235
  }))]), 1040, ["class", "columns", "data-source"])]),
257
236
  _: 3
258
237
  }, 8, ["name"])]),
@@ -261,5 +240,5 @@ const ze = /* @__PURE__ */ J({
261
240
  }
262
241
  });
263
242
  export {
264
- ze as default
243
+ be as default
265
244
  };
@@ -44,3 +44,15 @@
44
44
  .aplus-editable-table .ant-form-item-explain-error {
45
45
  text-align: left;
46
46
  }
47
+ .aplus-editable-table-table-header__title {
48
+ display: -webkit-inline-box;
49
+ -webkit-line-clamp: 2;
50
+ -webkit-box-orient: vertical;
51
+ overflow: hidden;
52
+ text-overflow: ellipsis;
53
+ white-space: normal;
54
+ max-width: 100%;
55
+ vertical-align: middle;
56
+ word-break: break-all;
57
+ flex: 1;
58
+ }
@@ -1,6 +1,7 @@
1
1
  import { EditableColumnType } from './interface';
2
2
  import { StandardBehaviorOptions } from '../../node_modules/scroll-into-view-if-needed';
3
3
  import { ValueTypeRenderConfig } from '../config-provider';
4
+ import { VNode, RendererNode, RendererElement } from 'vue';
4
5
  /**
5
6
  * 获取编辑模式下默认映射的组件
6
7
  * @param valueType
@@ -13,7 +14,7 @@ export declare function getEditableComponent(valueType: EditableColumnType['valu
13
14
  * @param column
14
15
  * @returns
15
16
  */
16
- export declare function getColumnIsRequired(column: EditableColumnType<any, 'tex', 'text'>): boolean;
17
+ export declare function getColumnIsRequired(column: EditableColumnType<any, 'text', 'text'>): boolean;
17
18
  /**
18
19
  * 获取ellipsis模式下最终需要渲染的字符串
19
20
  * @param column
@@ -40,3 +41,9 @@ export declare function scrollToRowIndex(index: number, container?: HTMLElement,
40
41
  * @returns
41
42
  */
42
43
  export declare function getFinalNode(column: EditableColumnType, editable: boolean, innerProps: Record<string, any>, value: any, record: any, extraRenderMap?: Record<string, ValueTypeRenderConfig>): any;
44
+ export declare function getEditableTableTitle(column: EditableColumnType<any>, titleNodeClassName: string, requiredNodeClassName: string, slot?: (props: {
45
+ title: any;
46
+ column: EditableColumnType<any>;
47
+ }) => any, tooltipColor?: string): VNode< RendererNode, RendererElement, {
48
+ [key: string]: any;
49
+ }>[] | import("vue/jsx-runtime").JSX.Element;
@@ -1,100 +1,134 @@
1
- import { isVNode as F, createVNode as f, mergeProps as g } from "vue";
2
- import { isFunction as T, isArray as I, isBoolean as h, omit as P } from "lodash-unified";
3
- import { apTableFormItemMap as V, noRenderAsFormItemValueList as j, apTableRenderItemMap as q } from "../ap-table/constants.mjs";
4
- import { isDef as w } from "../utils/index.mjs";
5
- import { getValueStr as S } from "../ap-field/number/helper.mjs";
6
- import A from "scroll-into-view-if-needed";
7
- import { Typography as v } from "ant-design-vue";
1
+ import { isVNode as h, createVNode as s, mergeProps as I, createTextVNode as F, Fragment as S } from "vue";
2
+ import { isFunction as m, isArray as g, isBoolean as w, omit as P, isString as V } from "lodash-unified";
3
+ import { apTableFormItemMap as q, noRenderAsFormItemValueList as v, apTableRenderItemMap as C } from "../ap-table/constants.mjs";
4
+ import { isDef as j } from "../utils/index.mjs";
5
+ import { getValueStr as A } from "../ap-field/number/helper.mjs";
6
+ import N from "scroll-into-view-if-needed";
7
+ import { Typography as O, Tooltip as W } from "ant-design-vue";
8
8
  import "../ap-form/index.mjs";
9
- import { objectToString as C } from "../ap-table/utils.mjs";
10
- import y from "../ap-form/ap-form-item.vue.mjs";
11
- function b(e) {
12
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !F(e);
9
+ import { objectToString as _ } from "../ap-table/utils.mjs";
10
+ import { QuestionCircleOutlined as D } from "@ant-design/icons-vue";
11
+ import T from "../ap-form/ap-form-item.vue.mjs";
12
+ function b(t) {
13
+ return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !h(t);
13
14
  }
14
- function N(e) {
15
- return V[e];
15
+ function E(t) {
16
+ return q[t];
16
17
  }
17
- function Q(e) {
18
- if (!e.fieldProps)
18
+ function k(t) {
19
+ if (!t.fieldProps)
19
20
  return !1;
20
- const t = T(e.fieldProps) ? e.fieldProps({}) : e.fieldProps;
21
- return w(t.required) ? t.required : (I(t.rules) ? t.rules : t.rules ? [t.rules] : []).some((r) => r.required);
21
+ const e = m(t.fieldProps) ? t.fieldProps({}) : t.fieldProps;
22
+ return j(e.required) ? e.required : (g(e.rules) ? e.rules : e.rules ? [e.rules] : []).some((o) => o.required);
22
23
  }
23
- function _(e, t) {
24
- if (e.valueType === "text" || e.valueType === "textArea")
25
- return t || "--";
26
- if (e.valueType === "number") {
27
- const o = e.fieldProps ? T(e.fieldProps) ? e.fieldProps({}) : e.fieldProps : {};
28
- return S(t, o) || "--";
24
+ function B(t, e) {
25
+ if (t.valueType === "text" || t.valueType === "textArea")
26
+ return e || "--";
27
+ if (t.valueType === "number") {
28
+ const i = t.fieldProps ? m(t.fieldProps) ? t.fieldProps({}) : t.fieldProps : {};
29
+ return A(e, i) || "--";
29
30
  }
30
- return C(t);
31
+ return _(e);
31
32
  }
32
- function R(e, t) {
33
- const o = [e];
34
- if (t) {
35
- const r = I(t) ? t : [t];
36
- o.unshift(...r);
33
+ function Z(t, e) {
34
+ const i = [t];
35
+ if (e) {
36
+ const o = g(e) ? e : [e];
37
+ i.unshift(...o);
37
38
  }
38
- return o.join(" ");
39
+ return i.join(" ");
39
40
  }
40
- function U(e, t = document.body, o = {}) {
41
- const r = t.querySelectorAll("tr.ant-table-row")[e];
42
- r && A(r, {
41
+ function $(t, e = document.body, i = {}) {
42
+ const o = e.querySelectorAll("tr.ant-table-row")[t];
43
+ o && N(o, {
43
44
  scrollMode: "if-needed",
44
45
  block: "nearest",
45
46
  behavior: "smooth",
46
- ...o
47
+ ...i
47
48
  });
48
49
  }
49
- function D(e, t, o) {
50
- return j.includes(e.valueType) ? o : e.copyable || e.ellipsis ? f(v.Paragraph, {
51
- copyable: e.copyable ? {
52
- text: t,
50
+ function H(t, e, i) {
51
+ return v.includes(t.valueType) ? i : t.copyable || t.ellipsis ? s(O.Paragraph, {
52
+ copyable: t.copyable ? {
53
+ text: e,
53
54
  tooltip: !1
54
55
  } : !1,
55
- ellipsis: e.ellipsis ? h(e.ellipsis) ? {
56
- tooltip: t
56
+ ellipsis: t.ellipsis ? w(t.ellipsis) ? {
57
+ tooltip: e
57
58
  } : {
58
- ...e.ellipsis,
59
- tooltip: t
59
+ ...t.ellipsis,
60
+ tooltip: e
60
61
  } : !1,
61
- content: e.ellipsis ? _(e, t) : o
62
- }, null) : o;
62
+ content: t.ellipsis ? B(t, e) : i
63
+ }, null) : i;
63
64
  }
64
- function W(e, t, o, r, d, i) {
65
- var a, m;
66
- if (t) {
67
- if (e.customRenderFormItem) {
68
- const n = e.customRenderFormItem(e, o.field, t, d);
69
- return f(y, P(o, ["field"]), b(n) ? n : {
70
- default: () => [n]
65
+ function M(t, e, i, o, d, l) {
66
+ var c, a;
67
+ if (e) {
68
+ if (t.customRenderFormItem) {
69
+ const y = t.customRenderFormItem(t, i.field, e, d);
70
+ return s(T, P(i, ["field"]), b(y) ? y : {
71
+ default: () => [y]
71
72
  });
72
73
  }
73
- const l = N(e.valueType);
74
- if (l)
75
- return f(l, o, null);
76
- const s = i == null ? void 0 : i[e.valueType], u = (a = s == null ? void 0 : s.renderFormItem) == null ? void 0 : a.call(s, o.field);
77
- return u ? f(y, o, b(u) ? u : {
78
- default: () => [u]
74
+ const r = E(t.valueType);
75
+ if (r)
76
+ return s(r, i, null);
77
+ const n = l == null ? void 0 : l[t.valueType], f = (c = n == null ? void 0 : n.renderFormItem) == null ? void 0 : c.call(n, i.field);
78
+ return f ? s(T, i, b(f) ? f : {
79
+ default: () => [f]
79
80
  }) : null;
80
81
  }
81
82
  let p;
82
- const c = q[e.valueType];
83
- if (c)
84
- p = f(c, g(o.field, {
83
+ const u = C[t.valueType];
84
+ if (u)
85
+ p = s(u, I(i.field, {
85
86
  mode: "read"
86
87
  }), null);
87
88
  else {
88
- const l = i == null ? void 0 : i[e.valueType];
89
- p = (m = l == null ? void 0 : l.render) == null ? void 0 : m.call(l, r, d, o.field);
89
+ const r = l == null ? void 0 : l[t.valueType];
90
+ p = (a = r == null ? void 0 : r.render) == null ? void 0 : a.call(r, o, d, i.field);
90
91
  }
91
- return p ? D(e, r, p) : null;
92
+ return p ? H(t, o, p) : null;
93
+ }
94
+ function tt(t, e, i, o, d) {
95
+ const l = o == null ? void 0 : o({
96
+ title: t.title,
97
+ column: t
98
+ });
99
+ if (l && (l.length > 1 || l[0].children && l[0].children !== "v-if"))
100
+ return l;
101
+ const u = k(t), a = V(t.title) ? {
102
+ class: e,
103
+ title: t.title
104
+ } : {}, r = s("div", a, [u ? s("span", {
105
+ class: i
106
+ }, [F("*")]) : null, t.title]), n = t.tooltip ? m(t.tooltip) ? t.tooltip(t) : s(S, null, [t.tooltip]) : null;
107
+ return n ? s("span", {
108
+ style: {
109
+ display: "inline-flex",
110
+ alignItems: "center",
111
+ maxWidth: "100%"
112
+ }
113
+ }, [r, s(W, {
114
+ title: n,
115
+ placement: "bottom"
116
+ }, {
117
+ default: () => [s(D, {
118
+ style: {
119
+ padding: "4px",
120
+ color: d,
121
+ verticalAlign: "middle"
122
+ }
123
+ }, null)]
124
+ })]) : r;
92
125
  }
93
126
  export {
94
- Q as getColumnIsRequired,
95
- N as getEditableComponent,
96
- W as getFinalNode,
97
- _ as getRawDisplayValue,
98
- R as mergeClass,
99
- U as scrollToRowIndex
127
+ k as getColumnIsRequired,
128
+ E as getEditableComponent,
129
+ tt as getEditableTableTitle,
130
+ M as getFinalNode,
131
+ B as getRawDisplayValue,
132
+ Z as mergeClass,
133
+ $ as scrollToRowIndex
100
134
  };