@farris/ui-vue 1.7.2-beta.1 → 1.7.2-beta.2

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 (128) hide show
  1. package/components/avatar/index.esm.js +155 -148
  2. package/components/avatar/index.umd.cjs +1 -1
  3. package/components/button-edit/index.esm.js +1 -1
  4. package/components/button-edit/index.umd.cjs +1 -1
  5. package/components/calendar/index.esm.js +226 -224
  6. package/components/calendar/index.umd.cjs +3 -3
  7. package/components/collection-property-editor/index.esm.js +225 -223
  8. package/components/collection-property-editor/index.umd.cjs +2 -2
  9. package/components/combo-list/index.esm.js +76 -71
  10. package/components/combo-list/index.umd.cjs +1 -1
  11. package/components/comment/index.esm.js +169 -167
  12. package/components/comment/index.umd.cjs +6 -6
  13. package/components/component/index.esm.js +3691 -3043
  14. package/components/component/index.umd.cjs +2 -2
  15. package/components/condition/index.esm.js +2015 -1352
  16. package/components/condition/index.umd.cjs +2 -2
  17. package/components/data-grid/index.esm.js +407 -430
  18. package/components/data-grid/index.umd.cjs +1 -1
  19. package/components/data-view/index.esm.js +3082 -3196
  20. package/components/data-view/index.umd.cjs +1 -1
  21. package/components/designer-canvas/index.esm.js +3364 -2713
  22. package/components/designer-canvas/index.umd.cjs +1 -1
  23. package/components/drawer/index.esm.js +66 -64
  24. package/components/drawer/index.umd.cjs +2 -2
  25. package/components/dynamic-form/index.esm.js +1176 -524
  26. package/components/dynamic-form/index.umd.cjs +1 -1
  27. package/components/dynamic-resolver/index.esm.js +182 -180
  28. package/components/dynamic-resolver/index.umd.cjs +2 -2
  29. package/components/dynamic-view/index.esm.js +531 -455
  30. package/components/dynamic-view/index.umd.cjs +1 -1
  31. package/components/events-editor/index.esm.js +2352 -1700
  32. package/components/events-editor/index.umd.cjs +3 -3
  33. package/components/expression-editor/index.esm.js +8 -3
  34. package/components/expression-editor/index.umd.cjs +2 -2
  35. package/components/filter-bar/index.esm.js +422 -413
  36. package/components/filter-bar/index.umd.cjs +2 -2
  37. package/components/filter-condition-editor/index.esm.js +8 -3
  38. package/components/filter-condition-editor/index.umd.cjs +1 -1
  39. package/components/image/index.esm.js +363 -354
  40. package/components/image/index.umd.cjs +2 -2
  41. package/components/language-textbox/index.esm.js +189 -187
  42. package/components/language-textbox/index.umd.cjs +2 -2
  43. package/components/list-view/index.esm.js +388 -389
  44. package/components/list-view/index.umd.cjs +5 -5
  45. package/components/mapping-editor/index.esm.js +1465 -1488
  46. package/components/mapping-editor/index.umd.cjs +1 -1
  47. package/components/number-range/index.esm.js +180 -173
  48. package/components/number-range/index.umd.cjs +1 -1
  49. package/components/order/index.esm.js +815 -811
  50. package/components/order/index.umd.cjs +5 -5
  51. package/components/property-panel/index.esm.js +429 -420
  52. package/components/property-panel/index.umd.cjs +3 -3
  53. package/components/query-solution/index.esm.js +4746 -4085
  54. package/components/query-solution/index.umd.cjs +7 -7
  55. package/components/schema-selector/index.esm.js +1401 -1402
  56. package/components/schema-selector/index.umd.cjs +5 -5
  57. package/components/section/index.esm.js +102 -100
  58. package/components/section/index.umd.cjs +2 -2
  59. package/components/sort-condition-editor/index.esm.js +8 -3
  60. package/components/sort-condition-editor/index.umd.cjs +1 -1
  61. package/components/transfer/index.esm.js +537 -538
  62. package/components/transfer/index.umd.cjs +5 -5
  63. package/components/tree-grid/index.esm.js +280 -283
  64. package/components/tree-grid/index.umd.cjs +1 -1
  65. package/components/tree-view/index.esm.js +200 -202
  66. package/components/tree-view/index.umd.cjs +1 -1
  67. package/components/uploader/index.esm.js +533 -519
  68. package/components/uploader/index.umd.cjs +2 -2
  69. package/designer/data-grid/index.esm.js +3806 -3905
  70. package/designer/data-grid/index.umd.cjs +9 -9
  71. package/designer/drawer/index.esm.js +188 -186
  72. package/designer/drawer/index.umd.cjs +2 -2
  73. package/designer/dynamic-form/index.esm.js +1562 -1073
  74. package/designer/dynamic-form/index.umd.cjs +2 -2
  75. package/designer/farris-designer.all.esm.js +9793 -8613
  76. package/designer/farris-designer.all.umd.cjs +8 -8
  77. package/designer/list-view/index.esm.js +564 -564
  78. package/designer/list-view/index.umd.cjs +6 -6
  79. package/designer/radio-group/index.esm.js +236 -229
  80. package/designer/radio-group/index.umd.cjs +1 -1
  81. package/designer/response-layout-editor/index.esm.js +178 -171
  82. package/designer/response-layout-editor/index.umd.cjs +1 -1
  83. package/designer/tabs/index.esm.js +3154 -2508
  84. package/designer/tabs/index.umd.cjs +2 -2
  85. package/designer/time-picker/index.esm.js +193 -186
  86. package/designer/time-picker/index.umd.cjs +1 -1
  87. package/designer/tree-grid/index.esm.js +444 -447
  88. package/designer/tree-grid/index.umd.cjs +1 -1
  89. package/farris.all.esm.js +60126 -59649
  90. package/farris.all.umd.cjs +30 -30
  91. package/index.css +1 -1
  92. package/package.json +1 -1
  93. package/types/components.d.ts +1 -1
  94. package/types/condition/src/composition/condition-value/dropdown-value.d.ts +4 -0
  95. package/types/data-grid/index.d.ts +2 -5
  96. package/types/data-grid/src/data-grid.component.d.ts +1 -2
  97. package/types/data-view/components/row/hierarchy-row.component.d.ts +2 -2
  98. package/types/data-view/composition/appearance/use-cell-position.d.ts +1 -1
  99. package/types/data-view/composition/types.d.ts +0 -4
  100. package/types/data-view/composition/visualization/use-virtual-scroll.d.ts +2 -2
  101. package/types/data-view/composition/visualization/use-visual-data-bound.d.ts +2 -3
  102. package/types/data-view/composition/visualization/use-visual-data-row.d.ts +1 -2
  103. package/types/designer-canvas/src/composition/dg-control.d.ts +24 -0
  104. package/types/dynamic-form/designer.d.ts +0 -1
  105. package/types/dynamic-form/index.d.ts +4 -3
  106. package/types/dynamic-form/src/designer/dynamic-form.design.component.d.ts +8 -0
  107. package/types/dynamic-form/src/designer/response-form.design.props.d.ts +14 -0
  108. package/types/dynamic-form/src/designer/use-dynamic-form-rules.d.ts +2 -0
  109. package/types/dynamic-form/src/dynamic-form.component.d.ts +8 -0
  110. package/types/dynamic-form/src/response-form.props.d.ts +13 -1
  111. package/types/dynamic-form/src/schema/response-form-schema-resolver.d.ts +1 -0
  112. package/types/dynamic-form/src/types.d.ts +1 -0
  113. package/types/dynamic-resolver/src/types.d.ts +1 -0
  114. package/types/dynamic-view/index.d.ts +43 -3
  115. package/types/dynamic-view/src/components/maps.d.ts +6 -6
  116. package/types/dynamic-view/src/composition/index.d.ts +5 -0
  117. package/types/dynamic-view/src/composition/use-utils.d.ts +12 -0
  118. package/types/dynamic-view/src/dynamic-view.component.d.ts +6 -6
  119. package/types/language-textbox/index.d.ts +3 -3
  120. package/types/language-textbox/src/components/language-contents.component.d.ts +1 -1
  121. package/types/language-textbox/src/language-textbox.component.d.ts +1 -1
  122. package/types/lookup/src/components/favorite/lookup-favorite.component.d.ts +1 -1
  123. package/types/lookup/src/components/popup-container.component.d.ts +3 -3
  124. package/types/property-panel/src/property-panel.component.d.ts +3 -3
  125. package/types/tree-grid/src/components/data/data-area.component.d.ts +2 -2
  126. package/types/tree-grid/src/tree-grid.props.d.ts +0 -1
  127. package/types/tree-view/src/components/data/tree-area.component.d.ts +1 -1
  128. package/types/tree-view/src/tree-view.props.d.ts +0 -1
@@ -1,10 +1,10 @@
1
- import { getCustomClass as bt, withInstall as It } from "../common/index.esm.js";
2
- import { createVNode as h, defineComponent as Bt, ref as v, computed as w, onMounted as Dt, nextTick as Ot, onUnmounted as Ft, watch as ye, createTextVNode as Rt } from "vue";
3
- import { useResizeObserver as xt } from "@vueuse/core";
4
- import { isUndefined as I } from "lodash-es";
5
- import { LocaleService as Ht } from "../locale/index.esm.js";
6
- import { getHierarchyRow as Gt, useIdentify as jt, useGroupData as Pt, useFilter as Vt, useHierarchy as Nt, useLoading as kt, useDataView as _t, useSelection as Tt, useSelectHierarchyItem as zt, usePagination as Mt, useDataViewContainerStyle as At, useCommandColumn as Lt, useSettingColumn as Et, useColumn as Wt, useSort as Ut, useGroupColumn as qt, useRow as Yt, useEdit as $t, useVisualDataBound as Jt, useVisualDataCell as Kt, useVisualDataRow as Qt, useVisualData as Xt, useCellPosition as Zt, useSidebar as ea, useVirtualScroll as ta, useFitColumn as aa, useFilterHistory as la, useColumnFilter as na, useDragColumn as oa, getColumnHeader as ia, getSidebar as ua, getDisableMask as sa, getHorizontalScrollbar as ra, getVerticalScrollbar as da, getEmpty as ca, getPagination as fa, getSummary as ma } from "../data-view/index.esm.js";
7
- const Ba = {
1
+ import { getCustomClass as St, withInstall as bt } from "../common/index.esm.js";
2
+ import { createVNode as g, defineComponent as It, ref as h, computed as C, onMounted as Bt, nextTick as Dt, onUnmounted as Ot, watch as ce, createTextVNode as Rt } from "vue";
3
+ import { useResizeObserver as Ft } from "@vueuse/core";
4
+ import { isUndefined as b } from "lodash-es";
5
+ import { LocaleService as xt } from "../locale/index.esm.js";
6
+ import { getHierarchyRow as Ht, useIdentify as Gt, useGroupData as jt, useFilter as Pt, useHierarchy as Vt, useLoading as Nt, useDataView as kt, useSelection as _t, useSelectHierarchyItem as Tt, usePagination as zt, useDataViewContainerStyle as Mt, useCommandColumn as At, useSettingColumn as Lt, useColumn as Et, useSort as Wt, useGroupColumn as Ut, useRow as qt, useEdit as Yt, useVisualDataBound as $t, useVisualDataCell as Jt, useVisualDataRow as Kt, useVisualData as Qt, useCellPosition as Xt, useSidebar as Zt, useVirtualScroll as ea, useFitColumn as ta, useFilterHistory as aa, useColumnFilter as la, useDragColumn as na, getColumnHeader as oa, getSidebar as ia, getDisableMask as ua, getHorizontalScrollbar as ra, getVerticalScrollbar as sa, getEmpty as da, getPagination as ca, getSummary as fa } from "../data-view/index.esm.js";
7
+ const Ia = {
8
8
  /** 启用分页 */
9
9
  enable: { type: Boolean, default: !1 },
10
10
  /** 当前页码 */
@@ -25,7 +25,7 @@ const Ba = {
25
25
  sizeLimits: { type: Array, default: [10, 20, 30, 50, 100] },
26
26
  /** 总记录数 */
27
27
  total: { type: Number, default: 0 }
28
- }, Da = {
28
+ }, Ba = {
29
29
  /** 启用排序 */
30
30
  enable: { type: Boolean, default: !1 },
31
31
  /** 排序字段集合 */
@@ -34,7 +34,7 @@ const Ba = {
34
34
  mode: { type: String, default: "client" },
35
35
  /** 多列排序 */
36
36
  multiSort: { type: Boolean, default: !1 }
37
- }, Oa = {
37
+ }, Da = {
38
38
  /** 自定义分组合计内容 */
39
39
  customGroupRow: { type: Function, default: () => {
40
40
  } },
@@ -58,7 +58,7 @@ const Ba = {
58
58
  showSummary: { type: Boolean, default: !1 },
59
59
  /** 显示合计行位置; */
60
60
  summaryPosition: { type: String, default: "separate" }
61
- }, Fa = {
61
+ }, Oa = {
62
62
  /** 启用筛选 */
63
63
  enable: { type: Boolean, default: !1 },
64
64
  /** DataGrid筛选风格 */
@@ -70,7 +70,7 @@ const Ba = {
70
70
  }, Ra = {
71
71
  /** 允许折行显示列标题 */
72
72
  wrapHeadings: { type: Boolean, default: !1 }
73
- }, xa = {
73
+ }, Fa = {
74
74
  /** 自定义行样式 */
75
75
  customRowStyle: { type: Function, default: () => {
76
76
  } },
@@ -85,7 +85,7 @@ const Ba = {
85
85
  showHovering: { type: Boolean, default: !0 },
86
86
  /** 禁止数据折行 */
87
87
  wrapContent: { type: Boolean, default: !1 }
88
- }, Ha = {
88
+ }, xa = {
89
89
  /** 显示合计信息 */
90
90
  enable: { type: Boolean, default: !1 },
91
91
  /** 合计行自定义样式,对启用合计行模板无效 */
@@ -97,7 +97,7 @@ const Ba = {
97
97
  mode: { type: String, default: "client" },
98
98
  /** 合计行显示位置, top: 顶部 bottom: 底部, both: 顶部与底部同时显示 */
99
99
  position: { type: String, default: "bottom" }
100
- }, Ga = {
100
+ }, Ha = {
101
101
  /** 自动列宽。设为true后,所有列将填满表格并不会出现横向滚动条。 */
102
102
  fitColumns: { type: Boolean, default: !1 },
103
103
  /** 自动适配列宽度模式 */
@@ -109,17 +109,17 @@ const Ba = {
109
109
  resizeColumn: { type: Boolean, default: !0 },
110
110
  /** 双击表头列自适应内容宽度 */
111
111
  resizeColumnOnDoubleClick: { type: Boolean, default: !0 }
112
- }, ja = {
112
+ }, Ga = {
113
113
  /** 编辑时选中文本 */
114
114
  selectOnEditing: { type: Boolean, default: !1 },
115
115
  /** 编辑模式; row:整行编辑,cell: 单元格编辑 */
116
116
  editMode: { type: String, default: "cell" }
117
- }, Pa = {
117
+ }, ja = {
118
118
  /** show loading */
119
119
  show: { type: Boolean, default: !1 },
120
120
  /** message on display when loading */
121
- message: { type: String, default: `${Ht.getLocaleValue("datagrid.loadingMessage")}...` }
122
- }, ya = {
121
+ message: { type: String, default: `${xt.getLocaleValue("datagrid.loadingMessage")}...` }
122
+ }, ma = {
123
123
  /** 自定义样式 */
124
124
  customClass: { type: String, default: "" },
125
125
  /** 排序配置 */
@@ -268,379 +268,376 @@ const Ba = {
268
268
  }
269
269
  },
270
270
  /** 自动高度 **/
271
- autoHeight: { type: Boolean, default: !1 },
272
- /** 是否可见, 为了适配低代码表单,该属性不应该属于表格组件的行为 */
273
- /** 复选框位置 */
274
- checkboxPosition: { type: String, default: "after-expand" }
271
+ autoHeight: { type: Boolean, default: !1 }
275
272
  };
276
- function va(a, d, T, S, C, B, g, y, D, A, n, O, L, P, o, F, E, Q, W) {
273
+ function ya(a, c, fe, T, I, v, y, B, z, n, D, M, V, o, O, J, A) {
277
274
  const {
278
- calculateCellPositionInRow: V
279
- } = B, {
280
- columnContext: R,
281
- hasLeftFixedColumn: X,
282
- hasRightFixedColumn: Z
283
- } = g, {
284
- gridDataStyle: l,
285
- leftFixedGridDataStyle: ee,
286
- rightFixedGridDataStyle: u
287
- } = P, {
288
- renderDataRow: N
289
- } = Gt(a, d, R, E, y, D, A, n, O, L, P, o, F, Q, W), te = [N];
290
- function p(c, le) {
291
- const Y = V(c);
292
- return E.value.filter((x) => x.visible !== !1).map((x, ne) => te[x.type](x, Y, le, ne));
275
+ calculateCellPositionInRow: L
276
+ } = v, {
277
+ columnContext: p,
278
+ hasLeftFixedColumn: E,
279
+ hasRightFixedColumn: K
280
+ } = y, {
281
+ gridDataStyle: Q,
282
+ leftFixedGridDataStyle: l,
283
+ rightFixedGridDataStyle: X
284
+ } = o, {
285
+ renderDataRow: u
286
+ } = Ht(a, c, p, A, B, z, n, D, M, V, o, O, J), G = [u];
287
+ function N(d, ee) {
288
+ const te = L(d);
289
+ return A.value.filter((R) => R.visible !== !1).map((R, U) => G[R.type](R, te, ee, U));
293
290
  }
294
- function ae() {
295
- return h("div", {
296
- ref: S,
291
+ function w() {
292
+ return g("div", {
293
+ ref: T,
297
294
  class: "fv-grid-content-left-fixed"
298
- }, [h("div", {
295
+ }, [g("div", {
299
296
  class: "fv-grid-data",
300
- style: ee.value
301
- }, [p(R.value.leftColumns.filter((c) => c.visible), "left")])]);
297
+ style: l.value
298
+ }, [N(p.value.leftColumns.filter((d) => d.visible), "left")])]);
302
299
  }
303
- function b() {
304
- return h("div", {
305
- ref: T,
300
+ function Z() {
301
+ return g("div", {
302
+ ref: fe,
306
303
  class: "fv-grid-content-primary"
307
- }, [h("div", {
304
+ }, [g("div", {
308
305
  class: "fv-grid-data",
309
- style: l.value
310
- }, [p(R.value.primaryColumns.filter((c) => c.visible), "primary")])]);
306
+ style: Q.value
307
+ }, [N(p.value.primaryColumns.filter((d) => d.visible), "primary")])]);
311
308
  }
312
- function U() {
313
- return h("div", {
314
- ref: C,
309
+ function S() {
310
+ return g("div", {
311
+ ref: I,
315
312
  class: "fv-grid-content-right-fixed"
316
- }, [h("div", {
313
+ }, [g("div", {
317
314
  class: "fv-grid-data",
318
- style: u.value
319
- }, [p(R.value.rightColumns.filter((c) => c.visible), "right")])]);
315
+ style: X.value
316
+ }, [N(p.value.rightColumns.filter((d) => d.visible), "right")])]);
320
317
  }
321
- function q() {
322
- const c = [];
323
- return X.value && c.push(ae()), c.push(b()), Z.value && c.push(U()), c;
318
+ function W() {
319
+ const d = [];
320
+ return E.value && d.push(w()), d.push(Z()), K.value && d.push(S()), d;
324
321
  }
325
322
  return {
326
- renderDataArea: q
323
+ renderDataArea: W
327
324
  };
328
325
  }
329
- const ga = /* @__PURE__ */ Bt({
326
+ const va = /* @__PURE__ */ It({
330
327
  name: "FTreeGrid",
331
- props: ya,
328
+ props: ma,
332
329
  emits: ["selectionChange", "clickRow", "expandNode", "unSelectItem", "dblclickNode", "doubleClickRow", "unSelectItem", "selectItem", "filterChanged", "sortChanged", "selectionUpdate"],
333
- setup(a, d) {
334
- var Se, be;
335
- const T = v(!1), S = 0, C = v(((Se = a.rowOption) == null ? void 0 : Se.height) || 28), B = v(20), g = v(a.columns), y = jt(a), {
336
- idField: D
337
- } = y, A = v(), n = v(), O = v(), L = v(), P = v(), o = v([]), F = v(!1), E = v(((be = a.rowOption) == null ? void 0 : be.wrapContent) || !1), Q = Pt(a, y), W = Vt(a, d), V = Nt(a), {
338
- collapseField: R
339
- } = V, {
340
- showLoading: X,
341
- renderLoading: Z
342
- } = kt(a, A), l = _t(a, /* @__PURE__ */ new Map(), W, V, y), {
343
- dataView: ee
344
- } = l, u = Tt(a, l, y, o, d), {
345
- showSelection: N,
346
- selectedValues: te
347
- } = u, p = zt(a, o, l, y, u, d), ae = w(() => a.disabled), b = w(() => a.virtualized ? Math.min(l.dataView.value.length, B.value) : l.dataView.value.length), U = Mt(a, l), {
348
- shouldRenderPagination: q
349
- } = U, {
350
- containerStyleObject: c
351
- } = At(a), le = Lt(a), {
352
- applyCommands: Y
353
- } = le;
354
- Y(g);
330
+ setup(a, c) {
331
+ var Ce, we;
332
+ const T = ((Ce = a.rowOption) == null ? void 0 : Ce.height) || 28, I = h(20), v = h(a.columns), y = Gt(a), {
333
+ idField: B
334
+ } = y, z = h(), n = h(), D = h(), M = h(), V = h(), o = h([]), O = h(!1), J = h(((we = a.rowOption) == null ? void 0 : we.wrapContent) || !1), A = jt(a, y), L = Pt(a, c), p = Vt(a), {
335
+ collapseField: E
336
+ } = p, {
337
+ showLoading: K,
338
+ renderLoading: Q
339
+ } = Nt(a, z), l = kt(a, /* @__PURE__ */ new Map(), L, p, y), {
340
+ dataView: X
341
+ } = l, u = _t(a, l, y, o, c), {
342
+ showSelection: G,
343
+ selectedValues: N
344
+ } = u, w = Tt(a, o, l, y, u, c), Z = C(() => a.disabled), S = C(() => a.virtualized ? Math.min(l.dataView.value.length, I.value) : l.dataView.value.length), W = zt(a, l), {
345
+ shouldRenderPagination: d
346
+ } = W, {
347
+ containerStyleObject: ee
348
+ } = Mt(a), te = At(a), {
349
+ applyCommands: R
350
+ } = te;
351
+ R(v);
355
352
  const {
356
- applyColumnSetting: x,
357
- removeColumnSetting: ne
358
- } = Et(a);
359
- a.showSetting && x(g);
360
- const z = Wt(a, d), oe = Ut(a), {
361
- applyColumnSorter: ve,
362
- columnContext: $,
363
- updateColumnRenderContext: Be
364
- } = z;
365
- ve(l, oe);
366
- const ie = qt(a, $), k = Yt(a, d, u, y), _ = $t(a, d, y, k, o), ue = Jt(a, l, C), De = Kt(a, _, ue), Oe = Qt(a, l, _, V, y, ue, De, C), se = Xt(a, g, l, b, S, Oe), {
367
- getVisualData: J
368
- } = se, Fe = Zt(a, $, C, T), re = ea(a, u), {
353
+ applyColumnSetting: U,
354
+ removeColumnSetting: be
355
+ } = Lt(a);
356
+ a.showSetting && U(v);
357
+ const k = Et(a, c), ae = Wt(a), {
358
+ applyColumnSorter: me,
359
+ columnContext: q,
360
+ updateColumnRenderContext: Ie
361
+ } = k;
362
+ me(l, ae);
363
+ const le = Ut(a, q), j = qt(a, c, u, y), P = Yt(a, c, y, j, o), ne = $t(a), Be = Jt(a, P, ne), De = Kt(a, l, P, p, y, ne, Be), oe = Qt(a, v, l, S, 0, De), {
364
+ getVisualData: Y
365
+ } = oe, Oe = Xt(a, q), ie = Zt(a, u), {
369
366
  sidebarWidth: Re
370
- } = re, f = ta(a, l, o, $, se, b, S, Re, C, T), {
371
- onWheel: xe,
372
- dataGridWidth: ge,
373
- viewPortHeight: he,
374
- viewPortWidth: K,
375
- resetScroll: de,
376
- updateVisibleRowsOnLatestVisibleScope: He
377
- } = f, pe = aa(a, $, n, K, ie), {
378
- calculateColumnsSize: M
379
- } = pe, Ce = la(), Ge = na(n, P, l, Ce, f), je = oa(a, d, z, l, ie, Q, f), Pe = w(() => {
367
+ } = ie, f = ea(a, l, o, q, oe, S, 0, Re), {
368
+ onWheel: Fe,
369
+ dataGridWidth: ye,
370
+ viewPortHeight: ve,
371
+ viewPortWidth: $,
372
+ resetScroll: ue,
373
+ updateVisibleRowsOnLatestVisibleScope: xe
374
+ } = f, ge = ta(a, q, n, $, le), {
375
+ calculateColumnsSize: _
376
+ } = ge, he = aa(), He = la(n, V, l, he, f), Ge = na(a, c, k, l, le, A, f), je = C(() => {
380
377
  const e = {
381
378
  "fv-grid": !0,
382
379
  "fv-grid-bordered": a.showBorder,
383
380
  "fv-grid-horizontal-bordered": a.showHorizontalLines,
384
381
  "fv-datagrid-strip": a.showStripe
385
382
  };
386
- return bt(e, a.customClass);
387
- }), Ve = w(() => ({
383
+ return St(e, a.customClass);
384
+ }), Pe = C(() => ({
388
385
  "fv-grid-content": !0,
389
- "fv-grid-content-hover": F.value,
390
- "fv-grid-wrap-content": E.value
386
+ "fv-grid-content-hover": O.value,
387
+ "fv-grid-wrap-content": J.value
391
388
  })), {
392
- renderDataArea: Ne
393
- } = va(a, d, O, L, P, Fe, z, l, _, V, k, u, p, f, se, ue, o, C, T), {
394
- renderGridHeader: ke,
395
- renderGridColumnResizeOverlay: _e,
396
- shouldShowHeader: Te
397
- } = ia(a, d, n, L, P, z, l, je, Ge, W, Ce, pe, ie, u, re, oe, f, K, o), {
398
- renderDataGridSidebar: ze
399
- } = ua(a, k, u, re, f), {
400
- renderDisableMask: Me
401
- } = sa(), {
402
- renderHorizontalScrollbar: Ae
389
+ renderDataArea: Ve
390
+ } = ya(a, c, D, M, V, Oe, k, l, P, p, j, u, w, f, oe, ne, o), {
391
+ renderGridHeader: Ne,
392
+ renderGridColumnResizeOverlay: ke,
393
+ shouldShowHeader: _e
394
+ } = oa(a, c, n, M, V, k, l, Ge, He, L, he, ge, le, u, ie, ae, f, $, o), {
395
+ renderDataGridSidebar: Te
396
+ } = ia(a, j, u, ie, f), {
397
+ renderDisableMask: ze
398
+ } = ua(), {
399
+ renderHorizontalScrollbar: Me
403
400
  } = ra(a, n, f), {
404
- renderVerticalScrollbar: Le
405
- } = da(a, n, f);
406
- function Ee() {
401
+ renderVerticalScrollbar: Ae
402
+ } = sa(a, n, f);
403
+ function Le() {
407
404
  var e, t, i;
408
405
  if (n.value && n.value.clientHeight > 0 && ((e = n.value) == null ? void 0 : e.clientWidth) > 0) {
409
- const r = Math.ceil(n.value.clientHeight / C.value);
410
- r > B.value && (B.value = r, He()), he.value = ((t = O.value) == null ? void 0 : t.clientHeight) || 0, ge.value = ((i = n.value) == null ? void 0 : i.clientWidth) || 0;
406
+ const s = Math.ceil(n.value.clientHeight / T);
407
+ s > I.value && (I.value = s, xe()), ve.value = ((t = D.value) == null ? void 0 : t.clientHeight) || 0, ye.value = ((i = n.value) == null ? void 0 : i.clientWidth) || 0;
411
408
  }
412
- n.value && (n.value.clientHeight > 0 || n.value.clientWidth > 0) && M();
413
- }
414
- Dt(() => {
415
- n.value && (B.value = Math.max(Math.ceil(n.value.clientHeight / C.value), B.value), o.value = J(0, b.value + S - 1), xt(n.value, Ee), M(), Ot(() => {
416
- n.value && (ge.value = n.value.clientWidth), O.value && (K.value = O.value.clientWidth, he.value = O.value.clientHeight);
417
- })), X.value && Z();
418
- }), Ft(() => {
419
- }), ye(K, () => {
420
- n.value && M();
409
+ n.value && (n.value.clientHeight > 0 || n.value.clientWidth > 0) && _();
410
+ }
411
+ Bt(() => {
412
+ n.value && (I.value = Math.max(Math.ceil(n.value.clientHeight / T), I.value), o.value = Y(0, S.value + 0 - 1), Ft(n.value, Le), _(), Dt(() => {
413
+ n.value && (ye.value = n.value.clientWidth), D.value && ($.value = D.value.clientWidth, ve.value = D.value.clientHeight);
414
+ })), K.value && Q();
415
+ }), Ot(() => {
416
+ }), ce($, () => {
417
+ n.value && _();
421
418
  });
422
- function We(e) {
423
- l.collapseTo(e), l.reOrderVisibleIndex(), de();
419
+ function Ee(e) {
420
+ l.collapseTo(e), l.reOrderVisibleIndex(), ue();
424
421
  }
425
- function Ue(e) {
426
- l.expandTo(e), l.reOrderVisibleIndex(), de();
422
+ function We(e) {
423
+ l.expandTo(e), l.reOrderVisibleIndex(), ue();
427
424
  }
428
- function ce() {
425
+ function re() {
429
426
  const e = u.getSelectionRow();
430
427
  return e ? e.dataIndex - 1 : -1;
431
428
  }
432
- function qe(e) {
433
- const t = e !== void 0 ? e : ce(), i = l.insertNewDataItem(t === -1 ? 0 : t);
434
- return o.value = J(0, b.value + S - 1), i;
429
+ function Ue(e) {
430
+ const t = e !== void 0 ? e : re(), i = l.insertNewDataItem(t === -1 ? 0 : t);
431
+ return o.value = Y(0, S.value + 0 - 1), i;
435
432
  }
436
- function Ye() {
437
- const e = ce();
438
- l.insertNewChildDataItem(e), o.value = J(0, b.value + S - 1);
433
+ function qe() {
434
+ const e = re();
435
+ l.insertNewChildDataItem(e), o.value = Y(0, S.value + 0 - 1);
439
436
  }
440
- function $e(e, t) {
441
- const i = o.value.find((m) => m.raw[D.value] === t), r = i ? i.dataIndex - 1 : -1;
442
- l.insertNewChildDataItems(e, r);
437
+ function Ye(e, t) {
438
+ const i = o.value.find((m) => m.raw[B.value] === t), s = i ? i.dataIndex - 1 : -1;
439
+ l.insertNewChildDataItems(e, s);
443
440
  }
444
- function Je() {
445
- const e = ce(), t = p.getNextSelectableHierarchyItemId(e);
446
- l.removeHierarchyDataItem(e), o.value = J(0, b.value + S - 1), t && p.selectItemById(t);
441
+ function $e() {
442
+ const e = re(), t = w.getNextSelectableHierarchyItemId(e);
443
+ l.removeHierarchyDataItem(e), o.value = Y(0, S.value + 0 - 1), t && w.selectItemById(t);
444
+ }
445
+ function Je(e) {
446
+ P.onEditingRow(e);
447
447
  }
448
448
  function Ke(e) {
449
- _.onEditingRow(e);
449
+ P.acceptEditingRow(e);
450
450
  }
451
451
  function Qe(e) {
452
- _.acceptEditingRow(e);
453
- }
454
- function Xe(e) {
455
- _.cancelEditingRow(e);
452
+ P.cancelEditingRow(e);
456
453
  }
457
- function fe(e) {
458
- e && (g.value = e, Y(g), Be(g.value), ve(l, oe), M());
454
+ function se(e) {
455
+ e && (v.value = e, R(v), Ie(v.value), me(l, ae), _());
459
456
  }
460
- ye(() => a.columns, (e) => {
461
- fe(e);
457
+ ce(() => a.columns, (e) => {
458
+ se(e);
462
459
  });
463
- function Ze(e, t) {
464
- e && (l.load(e), l.reOrderVisibleIndex(), t != null && t.keepScrollPosition ? f.scrollTo(f.offsetY.value) : de());
460
+ function Xe(e, t) {
461
+ e && (l.load(e), l.reOrderVisibleIndex(), t != null && t.keepScrollPosition ? f.scrollTo(f.offsetY.value) : ue());
465
462
  }
466
- function me(e) {
467
- k.activeRowById(e);
463
+ function de(e) {
464
+ j.activeRowById(e);
468
465
  }
469
- function et(e, t = {
466
+ function Ze(e, t = {
470
467
  isCurrent: !0
471
468
  }) {
472
- t != null && t.isCurrent && me(e), p.selectItemById(e);
469
+ t != null && t.isCurrent && de(e), w.selectItemById(e);
473
470
  }
474
- function tt(e) {
471
+ function et(e) {
475
472
  const t = o.value.find((i) => i.raw[y.idField.value] === e);
476
- t && k.clickRowItem(t);
473
+ t && j.clickRowItem(t);
477
474
  }
478
- function at(e) {
479
- p.selectItemByIds(e);
475
+ function tt(e) {
476
+ w.selectItemByIds(e);
480
477
  }
481
- function lt() {
478
+ function at() {
482
479
  return u.getSelectedItems();
483
480
  }
484
- function we() {
481
+ function pe() {
485
482
  u.clearSelection();
486
483
  }
487
- function nt() {
484
+ function lt() {
488
485
  u.emptyCurrentRowId();
489
486
  }
490
- const ot = w(() => !o.value || !o.value.length), {
491
- renderEmpty: it
492
- } = ca(a, d);
493
- function ut() {
487
+ const nt = C(() => !o.value || !o.value.length), {
488
+ renderEmpty: ot
489
+ } = da(a, c);
490
+ function it() {
494
491
  return u.getSelectionRow();
495
492
  }
496
- function st(e, t = {
493
+ function ut(e, t = {
497
494
  clearCurrent: !0
498
495
  }) {
499
- t != null && t.clearCurrent && me(""), p.unSelectItemByIds(e);
496
+ t != null && t.clearCurrent && de(""), w.unSelectItemByIds(e);
500
497
  }
501
498
  function rt() {
502
499
  return u.currentSelectedDataId.value;
503
500
  }
504
- function dt(e, t, i) {
505
- const r = ee.value.find((m) => m[D.value] === e);
506
- if (r) {
507
- if (Object.keys(r).forEach((s) => {
508
- Object.prototype.hasOwnProperty.call(t, s) && (r[s] = t[s]);
501
+ function st(e, t, i) {
502
+ const s = X.value.find((m) => m[B.value] === e);
503
+ if (s) {
504
+ if (Object.keys(s).forEach((r) => {
505
+ Object.prototype.hasOwnProperty.call(t, r) && (s[r] = t[r]);
509
506
  }), i) {
510
507
  const {
511
- collapseField: s,
512
- disabledField: H,
513
- checkedField: G,
514
- visibleField: j
508
+ collapseField: r,
509
+ disabledField: F,
510
+ checkedField: x,
511
+ visibleField: H
515
512
  } = i;
516
- s && !I(t[s]) && (r.__fv_collapse__ = t[s]), G && !I(t[G]) && (r.__fv_checked__ = t[G]), H && !I(t[H]) && (r.__fv_disabled__ = t[H]), j && !I(t[j]) && (r.__fv_visible__ = t[j]);
513
+ r && !b(t[r]) && (s.__fv_collapse__ = t[r]), x && !b(t[x]) && (s.__fv_checked__ = t[x]), F && !b(t[F]) && (s.__fv_disabled__ = t[F]), H && !b(t[H]) && (s.__fv_visible__ = t[H]);
517
514
  }
518
- const m = o.value.find((s) => s.raw[D.value] === e), Ie = o.value.findIndex((s) => s.raw[D.value] === e);
515
+ const m = o.value.find((r) => r.raw[B.value] === e), Se = o.value.findIndex((r) => r.raw[B.value] === e);
519
516
  if (m) {
520
- if (m.raw = r, Object.keys(m.data).forEach((s) => {
521
- m.data[s].updateData(r);
517
+ if (m.raw = s, Object.keys(m.data).forEach((r) => {
518
+ m.data[r].updateData(s);
522
519
  }), i) {
523
520
  const {
524
- collapseField: s,
525
- disabledField: H,
526
- checkedField: G,
527
- visibleField: j
521
+ collapseField: r,
522
+ disabledField: F,
523
+ checkedField: x,
524
+ visibleField: H
528
525
  } = i;
529
- s && !I(t[s]) && (m.collapse = t[s]), G && !I(t[G]) && (m.checked = t[G]), H && !I(t[H]) && (m.disabled = t[H]), j && !I(t[j]) && (m.visible = t[j]);
526
+ r && !b(t[r]) && (m.collapse = t[r]), x && !b(t[x]) && (m.checked = t[x]), F && !b(t[F]) && (m.disabled = t[F]), H && !b(t[H]) && (m.visible = t[H]);
530
527
  }
531
- o.value = [...o.value.slice(0, Ie), m, ...o.value.slice(Ie + 1)], l.updateSummary();
528
+ o.value = [...o.value.slice(0, Se), m, ...o.value.slice(Se + 1)], l.updateSummary();
532
529
  }
533
530
  }
534
531
  }
535
- function ct(e) {
532
+ function dt(e) {
536
533
  return Object.prototype.hasOwnProperty.call(e, "raw") ? l.hasRealChildren(e.raw) : l.hasRealChildren(e);
537
534
  }
538
- function ft(e) {
539
- const t = l.dataView.value.find((i) => i[D.value] === e);
540
- return t ? t[R.value] : "";
535
+ function ct(e) {
536
+ const t = l.dataView.value.find((i) => i[B.value] === e);
537
+ return t ? t[E.value] : "";
541
538
  }
542
- function mt() {
543
- return R.value;
539
+ function ft() {
540
+ return E.value;
544
541
  }
545
- ye(() => a.showSetting, (e, t) => {
546
- e !== t && (e ? x(g) : ne(g), fe(g.value));
542
+ ce(() => a.showSetting, (e, t) => {
543
+ e !== t && (e ? U(v) : be(v), se(v.value));
547
544
  });
548
- function yt(e) {
545
+ function mt(e) {
549
546
  return o.value.filter((t) => e.includes(t.raw[a.idField]));
550
547
  }
551
- function vt(e) {
552
- const t = y.idField.value, i = o.value.find((r) => r.raw[t] === e);
553
- i && k.changeRow(i);
554
- }
555
- function gt() {
556
- u.keepSelectingOnPaging.value || we(), l.updateVisibleDataSummary(o.value);
557
- }
558
- d.expose({
559
- activeRowById: me,
560
- addNewDataItem: qe,
561
- addNewChildDataItem: Ye,
562
- addChildrenToNode: $e,
563
- collapseTo: We,
564
- expandTo: Ue,
565
- removeDataItem: Je,
566
- editDataItem: Ke,
567
- acceptDataItem: Qe,
568
- cancelDataItem: Xe,
569
- updateColumns: fe,
570
- updateDataSource: Ze,
571
- selectItemById: et,
572
- selectItemByIds: at,
573
- getSelectedItems: lt,
574
- clearSelection: we,
575
- getSelectionRow: ut,
576
- clickRowItemById: tt,
577
- unSelectItemByIds: st,
548
+ function yt(e) {
549
+ const t = y.idField.value, i = o.value.find((s) => s.raw[t] === e);
550
+ i && j.changeRow(i);
551
+ }
552
+ function vt() {
553
+ u.keepSelectingOnPaging.value || pe(), l.updateVisibleDataSummary(o.value);
554
+ }
555
+ c.expose({
556
+ activeRowById: de,
557
+ addNewDataItem: Ue,
558
+ addNewChildDataItem: qe,
559
+ addChildrenToNode: Ye,
560
+ collapseTo: Ee,
561
+ expandTo: We,
562
+ removeDataItem: $e,
563
+ editDataItem: Je,
564
+ acceptDataItem: Ke,
565
+ cancelDataItem: Qe,
566
+ updateColumns: se,
567
+ updateDataSource: Xe,
568
+ selectItemById: Ze,
569
+ selectItemByIds: tt,
570
+ getSelectedItems: at,
571
+ clearSelection: pe,
572
+ getSelectionRow: it,
573
+ clickRowItemById: et,
574
+ unSelectItemByIds: ut,
578
575
  getCurrentRowId: rt,
579
- reassignRowData: dt,
580
- hasChildren: ct,
581
- getCollapseField: mt,
582
- getCollapseStatusById: ft,
583
- getVisibleDataByIds: yt,
584
- selectRowById: vt,
585
- updateDerivedData: gt,
586
- emptyCurrentRowId: nt,
587
- calculateColumnsSize: M
576
+ reassignRowData: st,
577
+ hasChildren: dt,
578
+ getCollapseField: ft,
579
+ getCollapseStatusById: ct,
580
+ getVisibleDataByIds: mt,
581
+ selectRowById: yt,
582
+ updateDerivedData: vt,
583
+ emptyCurrentRowId: lt,
584
+ calculateColumnsSize: _
588
585
  });
589
- const ht = w(() => {
586
+ const gt = C(() => {
590
587
  const e = {};
591
588
  return f.shouldShowHorizontalScrollbar.value && (e.paddingBottom = "10px"), f.shouldShowVirticalScrollbar.value && (e.paddingRight = "10px"), e;
592
- }), pt = w(() => ({
593
- ...c.value,
589
+ }), ht = C(() => ({
590
+ ...ee.value,
594
591
  borderRadius: "5px"
595
592
  })), {
596
- renderDataGridPagination: ha
597
- } = fa(a, d, l, f, U, u), Ct = w(() => ({
593
+ renderDataGridPagination: ga
594
+ } = ca(a, c, l, f, W, u), pt = C(() => ({
598
595
  "d-flex": !0,
599
- "justify-content-between": q.value && N.value,
600
- "justify-content-end": q.value && !N.value,
596
+ "justify-content-between": d.value && G.value,
597
+ "justify-content-end": d.value && !G.value,
601
598
  "position-relative": !0
602
- })), wt = w(() => ({
599
+ })), Ct = C(() => ({
603
600
  "d-flex": !0,
604
601
  "align-items-center": !0
605
602
  })), {
606
- renderDataGridSummary: St
607
- } = ma(a, l, z);
608
- return () => h("div", {
609
- ref: A,
610
- class: Pe.value,
611
- style: pt.value,
612
- onWheel: xe
613
- }, [n.value && Te.value && ke(), h("div", {
603
+ renderDataGridSummary: wt
604
+ } = fa(a, l, k);
605
+ return () => g("div", {
606
+ ref: z,
607
+ class: je.value,
608
+ style: ht.value,
609
+ onWheel: Fe
610
+ }, [n.value && _e.value && Ne(), g("div", {
614
611
  ref: n,
615
- class: Ve.value,
616
- onMouseover: () => F.value = !0,
617
- onMouseleave: () => F.value = !1,
612
+ class: Pe.value,
613
+ onMouseover: () => O.value = !0,
614
+ onMouseleave: () => O.value = !1,
618
615
  onTouchstart: (e) => {
619
- e.stopPropagation(), F.value = !0, f.onTouchstartScrollThumb(e, n);
616
+ e.stopPropagation(), O.value = !0, f.onTouchstartScrollThumb(e, n);
620
617
  },
621
618
  onTouchend: (e) => {
622
- F.value = !1;
619
+ O.value = !1;
623
620
  },
624
- style: ht.value
625
- }, [n.value && ze(o), n.value && Ne(), n.value && ot.value && it(), n.value && Ae(), n.value && Le()]), n.value && St(), N.value && h("div", {
621
+ style: gt.value
622
+ }, [n.value && Te(o), n.value && Ve(), n.value && nt.value && ot(), n.value && Me(), n.value && Ae()]), n.value && wt(), G.value && g("div", {
623
+ class: pt.value
624
+ }, [G.value && g("div", {
626
625
  class: Ct.value
627
- }, [N.value && h("div", {
628
- class: wt.value
629
- }, [h("div", null, ["已选:" + te.value.length, Rt(" 条")])])]), _e(), ae.value && Me()]);
626
+ }, [g("div", null, ["已选:" + N.value.length, Rt(" 条")])])]), ke(), Z.value && ze()]);
630
627
  }
631
- }), Va = It(ga);
628
+ }), Pa = bt(va);
632
629
  export {
633
- ga as FTreeGrid,
634
- Ga as columnOptions,
635
- Va as default,
636
- ja as editOptions,
637
- Fa as filterOptions,
638
- Oa as groupOptions,
630
+ va as FTreeGrid,
631
+ Ha as columnOptions,
632
+ Pa as default,
633
+ Ga as editOptions,
634
+ Oa as filterOptions,
635
+ Da as groupOptions,
639
636
  Ra as headerOptions,
640
- Pa as loadingOptions,
641
- Ba as paginationOptions,
642
- xa as rowOptions,
643
- Da as sortOptions,
644
- Ha as summaryOptions,
645
- ya as treeGridProps
637
+ ja as loadingOptions,
638
+ Ia as paginationOptions,
639
+ Fa as rowOptions,
640
+ Ba as sortOptions,
641
+ xa as summaryOptions,
642
+ ma as treeGridProps
646
643
  };