@dt-frames/ui 2.0.14 → 2.0.15

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.
@@ -56,7 +56,7 @@ function createPlaceholder(component) {
56
56
  if (component.includes("Input") || component.includes("Complete")) {
57
57
  return t("PLEASE_INPUT");
58
58
  }
59
- if (component.includes("Picker") || component.includes("Select") || component.includes("Cascader") || component.includes("Checkbox") || component.includes("Radio") || component.includes("Switch")) {
59
+ if (component.includes("Picker") || component.includes("Select") || component.includes("Cascader") || component.includes("Checkbox") || component.includes("Radio") || component.includes("Switch") || component.includes("Upload")) {
60
60
  return t("PLEASE_SELECT");
61
61
  }
62
62
  if (component.includes("Icon")) {
@@ -423,7 +423,8 @@ const _sfc_main$2 = {
423
423
  changeEvent = "change",
424
424
  valueField,
425
425
  renderComponent,
426
- props: sProps
426
+ props: sProps,
427
+ extraName
427
428
  } = props.schema;
428
429
  const isCheck = component && ["Switch", "Checkbox"].includes(component);
429
430
  const eventKey = `on${upperFirst(changeEvent)}`;
@@ -493,7 +494,9 @@ const _sfc_main$2 = {
493
494
  if (["DatePicker", "MonthPicker", "RangePicker"].includes(component)) {
494
495
  itemProps.defaultValue = props.formModel[name];
495
496
  }
496
- itemProps.codeName = name;
497
+ if (component === "Upload" && !itemProps.defaultFiles && extraName?.length) {
498
+ itemProps.defaultFiles = unref(getValues).values?.[extraName[0]];
499
+ }
497
500
  itemProps.formValues = unref(getValues);
498
501
  if (["Select", "DatePicker", "MonthPicker", "WeekPicker", "RangePicker"].includes(component)) {
499
502
  itemProps.dropdownClassName += ` ${unref(getUiSize)}`;
@@ -14,7 +14,14 @@
14
14
 
15
15
  &__dialog {
16
16
  .ant-form-item {
17
- margin-bottom: 20px;
17
+ margin-bottom: 22px;
18
+ &.small{
19
+ margin-bottom: 18px;
20
+ }
21
+
22
+ &.ant-form-item-with-help{
23
+ margin-bottom: 0;
24
+ }
18
25
  }
19
26
  }
20
27
 
@@ -102,8 +109,8 @@
102
109
  }
103
110
 
104
111
  .ant-form-item-explain{
105
- height: 16px;
106
- min-height: 16px;
112
+ height: 18px;
113
+ min-height: 18px;
107
114
  }
108
115
  .ant-form-item-explain-error{
109
116
  font-size: 12px;
@@ -218,6 +225,15 @@
218
225
  font-size: 13px;
219
226
  }
220
227
  }
228
+
229
+ .ant-form-item-explain{
230
+ height: 22px;
231
+ min-height: 22px;
232
+ }
233
+ .ant-form-item-explain-error{
234
+ font-size: 13px;
235
+ line-height: 20px;
236
+ }
221
237
  }
222
238
 
223
239
  .ant-form-item.large{
@@ -294,6 +310,15 @@
294
310
  font-size: 14px;
295
311
  }
296
312
  }
313
+
314
+ .ant-form-item-explain{
315
+ height: 22px;
316
+ min-height: 22px;
317
+ }
318
+ .ant-form-item-explain-error{
319
+ font-size: 13px;
320
+ line-height: 20px;
321
+ }
297
322
  }
298
323
 
299
324
  .ant-input-number {
@@ -41,8 +41,8 @@ export declare const BasicProps: {
41
41
  };
42
42
  rowProps: {
43
43
  type: PropType<Partial<import("vue").ExtractPropTypes<{
44
- align: PropType<"middle" | "top" | "bottom" | "stretch">;
45
- justify: PropType<"center" | "space-around" | "space-between" | "end" | "start">;
44
+ align: PropType<"stretch" | "bottom" | "top" | "middle">;
45
+ justify: PropType<"space-around" | "space-between" | "center" | "end" | "start">;
46
46
  prefixCls: StringConstructor;
47
47
  gutter: {
48
48
  type: PropType<import("ant-design-vue/lib/grid/Row").Gutter | [import("ant-design-vue/lib/grid/Row").Gutter, import("ant-design-vue/lib/grid/Row").Gutter]>;
@@ -62,7 +62,7 @@ export declare const BasicProps: {
62
62
  type: NumberConstructor;
63
63
  };
64
64
  size: {
65
- type: PropType<"small" | "large" | "middle">;
65
+ type: PropType<"middle" | "small" | "large">;
66
66
  };
67
67
  disabled: {
68
68
  type: BooleanConstructor;
@@ -1,5 +1,5 @@
1
1
  import { useAppStore, useSlots, error, http, useApp, getDynamicProps, isBoolean, isFunction, getPopupContainer, useI18n, isNumber, isArray, isObject, isString, useMessage, isNullAndUnDef, windowResizeFn, off, on, getDictValueByCode, formatNumber, isVnode } from "@dt-frames/core";
2
- import { useSlots as useSlots$1, unref, ref, watch, onUnmounted, defineComponent, useAttrs, resolveDirective, openBlock, createElementBlock, normalizeClass, Fragment, renderList, toDisplayString, createCommentVNode, createBlock, withCtx, createVNode, withDirectives, createElementVNode, normalizeStyle, provide, inject, h as h$1, computed, mergeProps, nextTick, toRaw as toRaw$1, reactive, createTextVNode, watchEffect, normalizeProps, renderSlot, onMounted, createSlots, guardReactiveProps } from "vue";
2
+ import { useSlots as useSlots$1, unref, ref, watch, onUnmounted, defineComponent, useAttrs, resolveDirective, openBlock, createElementBlock, normalizeClass, Fragment, renderList, toDisplayString, createCommentVNode, createBlock, withCtx, createVNode, withDirectives, createElementVNode, createTextVNode, normalizeStyle, provide, inject, h as h$1, computed, mergeProps, nextTick, toRaw as toRaw$1, reactive, watchEffect, normalizeProps, renderSlot, onMounted, createSlots, guardReactiveProps } from "vue";
3
3
  import { useHeader } from "../../theme";
4
4
  import { MenuItem, Menu, Dropdown, Tooltip, Checkbox as Checkbox$1, Divider, Col, Row, Button, CheckboxGroup, Popover as Popover$1, Table } from "ant-design-vue/es";
5
5
  import "ant-design-vue/es/table/style";
@@ -236,16 +236,16 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
236
236
  key: 0,
237
237
  class: normalizeClass(__props.expandNum ? "dt-expand-has-collapse" : "")
238
238
  }, [
239
- (openBlock(true), createElementBlock(Fragment, null, renderList(actionBtns.value, (item, index2) => {
239
+ (openBlock(true), createElementBlock(Fragment, null, renderList(actionBtns.value, (item, index) => {
240
240
  return openBlock(), createElementBlock(Fragment, null, [
241
241
  item.ifShow ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
242
242
  __props.expandNum ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
243
- index2 < __props.expandNum ? (openBlock(), createElementBlock("span", {
243
+ index < __props.expandNum ? (openBlock(), createElementBlock("span", {
244
244
  key: 0,
245
245
  class: "dt-table-action-btn w-8 inline-block",
246
246
  onClick: ($event) => handleAction(item)
247
- }, toDisplayString(item.label()), 9, _hoisted_1$8)) : createCommentVNode("v-if", true),
248
- index2 >= __props.expandNum && index2 === actionBtns.value.length - 1 ? (openBlock(), createBlock(_component_ADropdown, {
247
+ }, toDisplayString(item.label()), 9, _hoisted_1$8)) : createCommentVNode("", true),
248
+ index >= __props.expandNum && index === actionBtns.value.length - 1 ? (openBlock(), createBlock(_component_ADropdown, {
249
249
  key: 1,
250
250
  getPopupContainer: getPopupContainer$1,
251
251
  trigger: ["click"]
@@ -264,10 +264,10 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
264
264
  createElementVNode("span", _hoisted_4$2, toDisplayString(item1.label()), 1)
265
265
  ]),
266
266
  _: 2
267
- }, 1032, ["onClick"])) : createCommentVNode("v-if", true)
267
+ }, 1032, ["onClick"])) : createCommentVNode("", true)
268
268
  ])), [
269
269
  [_directive_auth, getAuth(item1.auth)]
270
- ]) : createCommentVNode("v-if", true)
270
+ ]) : createCommentVNode("", true)
271
271
  ], 64);
272
272
  }), 256))
273
273
  ]),
@@ -278,26 +278,28 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
278
278
  _hoisted_2$2
279
279
  ]),
280
280
  _: 1
281
- })) : createCommentVNode("v-if", true)
281
+ })) : createCommentVNode("", true)
282
282
  ], 64)) : (openBlock(), createBlock(_component_ATooltip, {
283
283
  key: 1,
284
284
  placement: "bottom"
285
285
  }, {
286
286
  title: withCtx(() => [
287
- createElementVNode("span", _hoisted_5$1, toDisplayString(item.label()), 1)
287
+ createTextVNode(toDisplayString(item.label()), 1)
288
288
  ]),
289
289
  default: withCtx(() => [
290
- createElementVNode("i", {
291
- class: normalizeClass(["i cursor-pointer", item.icon()]),
292
- style: normalizeStyle({
293
- color: item.color
294
- }),
295
- onClick: ($event) => handleAction(item)
296
- }, null, 14, _hoisted_6)
290
+ createElementVNode("span", _hoisted_5$1, [
291
+ createElementVNode("i", {
292
+ class: normalizeClass(["i cursor-pointer", item.icon()]),
293
+ style: normalizeStyle({
294
+ color: item.color
295
+ }),
296
+ onClick: ($event) => handleAction(item)
297
+ }, null, 14, _hoisted_6)
298
+ ])
297
299
  ]),
298
300
  _: 2
299
301
  }, 1024))
300
- ], 64)) : createCommentVNode("v-if", true)
302
+ ], 64)) : createCommentVNode("", true)
301
303
  ], 64);
302
304
  }), 256))
303
305
  ], 2)) : (openBlock(), createBlock(_component_ADropdown, {
@@ -324,7 +326,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
324
326
  createElementVNode("span", _hoisted_8, toDisplayString(item.label()), 1)
325
327
  ]),
326
328
  _: 2
327
- }, 1032, ["onClick"])) : createCommentVNode("v-if", true)
329
+ }, 1032, ["onClick"])) : createCommentVNode("", true)
328
330
  ])), [
329
331
  [_directive_auth, getAuth(item.auth)]
330
332
  ]);
@@ -341,14 +343,6 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
341
343
  };
342
344
  }
343
345
  });
344
- const _export_sfc = (sfc, props2) => {
345
- const target = sfc.__vccOpts || sfc;
346
- for (const [key, val] of props2) {
347
- target[key] = val;
348
- }
349
- return target;
350
- };
351
- const TableAction = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/TableAction.vue"]]);
352
346
  const tableKey = Symbol("dt-page");
353
347
  function createTableInstance(instance) {
354
348
  provide(tableKey, instance);
@@ -443,9 +437,9 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
443
437
  const val = unref(currentValueRef);
444
438
  const value = isCheckValue ? isNumber(val) && isBoolean(val) ? val : !!val : val;
445
439
  let compProps = props2.column?.editComponentProps ?? {};
446
- const { record, column, index: index2 } = props2;
440
+ const { record, column, index } = props2;
447
441
  if (isFunction(compProps)) {
448
- compProps = compProps({ text: val, record, column, index: index2 }) ?? {};
442
+ compProps = compProps({ text: val, record, column, index }) ?? {};
449
443
  }
450
444
  if (unref(getComponent) === "InputNumber") {
451
445
  compProps = {
@@ -525,9 +519,8 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
525
519
  };
526
520
  }
527
521
  });
528
- const EditableCell = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/editTable/EditTableCell.vue"]]);
529
522
  function renderEditCell(column) {
530
- return ({ text: value, record, index: index2 }) => {
523
+ return ({ text: value, record, index }) => {
531
524
  record.onValid = async () => {
532
525
  if (isArray(record?.validCbs)) {
533
526
  const validFns = (record?.validCbs || []).map((fn) => fn());
@@ -555,11 +548,11 @@ function renderEditCell(column) {
555
548
  }
556
549
  return true;
557
550
  };
558
- return h(EditableCell, {
551
+ return h(_sfc_main$8, {
559
552
  value,
560
553
  record,
561
554
  column,
562
- index: index2
555
+ index
563
556
  });
564
557
  };
565
558
  }
@@ -616,17 +609,17 @@ function handleIndexColumn(propsRef, getPaginationRef, columns) {
616
609
  width: unref(getIsZH) ? 50 : 70,
617
610
  title: t("NUMBER"),
618
611
  align: "center",
619
- customRender: ({ index: index2, renderIndex, record }) => {
612
+ customRender: ({ index, renderIndex, record }) => {
620
613
  if (virtual && record?.index)
621
614
  return record?.index;
622
615
  const getPagination = unref(getPaginationRef);
623
616
  const { appConf } = useAppStore();
624
617
  const { defaultPageSize } = appConf.ui.table;
625
618
  if (isBoolean(getPagination)) {
626
- return `${index2 + 1}`;
619
+ return `${index + 1}`;
627
620
  }
628
621
  const { current = 1, pageSize = defaultPageSize } = getPagination;
629
- return ((current < 1 ? 1 : current) - 1) * pageSize + index2 + 1;
622
+ return ((current < 1 ? 1 : current) - 1) * pageSize + index + 1;
630
623
  },
631
624
  ...isFixedLeft ? {
632
625
  fixed: "left"
@@ -664,14 +657,14 @@ function handleActionColumn(propsRef, columns) {
664
657
  };
665
658
  columns.push({
666
659
  ...columnObj,
667
- customRender: ({ record, index: index2 }) => {
660
+ customRender: ({ record, index }) => {
668
661
  return h$1(
669
- TableAction,
662
+ _sfc_main$9,
670
663
  omit({
671
664
  ...columnObj,
672
665
  authPrefix,
673
666
  record,
674
- index: index2
667
+ index
675
668
  }, "align")
676
669
  );
677
670
  }
@@ -708,7 +701,7 @@ function useColumns(propsRef, getPaginationRef, tableElRef) {
708
701
  const getColumnsRef = computed(() => {
709
702
  const columns = cloneDeep(unref(columnsRef));
710
703
  const { ellipsis } = unref(propsRef);
711
- columns.forEach((it, index2) => {
704
+ columns.forEach((it, index) => {
712
705
  it.class = it.class ?? "";
713
706
  if (!it.class.split(" ").includes("__column")) {
714
707
  it.class = `${it.class} __column`;
@@ -842,7 +835,7 @@ function useColumns(propsRef, getPaginationRef, tableElRef) {
842
835
  };
843
836
  }
844
837
  function useCustomRow(propsRef, { setSelectedRowKeys, getSelectedRowKeys, clearSelectedRowKeys, emits }) {
845
- const customRow = (record, index2) => {
838
+ const customRow = (record, index) => {
846
839
  return {
847
840
  onClick: (e) => {
848
841
  e?.stopPropagation();
@@ -896,19 +889,19 @@ function useCustomRow(propsRef, { setSelectedRowKeys, getSelectedRowKeys, clearS
896
889
  }
897
890
  }
898
891
  handleClick();
899
- emits("row-click", record, index2, e);
892
+ emits("row-click", record, index, e);
900
893
  },
901
894
  onDblclick: (event) => {
902
- emits("row-dbClick", record, index2, event);
895
+ emits("row-dbClick", record, index, event);
903
896
  },
904
897
  onContextmenu: (event) => {
905
- emits("row-contextmenu", record, index2, event);
898
+ emits("row-contextmenu", record, index, event);
906
899
  },
907
900
  onMouseenter: (event) => {
908
- emits("row-mouseenter", record, index2, event);
901
+ emits("row-mouseenter", record, index, event);
909
902
  },
910
903
  onMouseleave: (event) => {
911
- emits("row-mouseleave", record, index2, event);
904
+ emits("row-mouseleave", record, index, event);
912
905
  }
913
906
  };
914
907
  };
@@ -1030,7 +1023,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
1030
1023
  const _component_ATooltip = Tooltip;
1031
1024
  return openBlock(), createBlock(_component_ATooltip, { placement: "top" }, {
1032
1025
  title: withCtx(() => [
1033
- !unref(isFullscreen) ? (openBlock(), createElementBlock("span", _hoisted_1$6, toDisplayString(unref(t)("FULLSCREEN")), 1)) : createCommentVNode("v-if", true)
1026
+ !unref(isFullscreen) ? (openBlock(), createElementBlock("span", _hoisted_1$6, toDisplayString(unref(t)("FULLSCREEN")), 1)) : createCommentVNode("", true)
1034
1027
  ]),
1035
1028
  default: withCtx(() => [
1036
1029
  createElementVNode("span", {
@@ -1047,7 +1040,6 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
1047
1040
  };
1048
1041
  }
1049
1042
  });
1050
- const FullscreenSetting = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/tableSetting/Fullscreen.vue"]]);
1051
1043
  const _hoisted_1$5 = { class: "column-select" };
1052
1044
  const _sfc_main$6 = /* @__PURE__ */ defineComponent({
1053
1045
  __name: "DownloadCtrl",
@@ -1119,7 +1111,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
1119
1111
  createVNode(_component_ADivider, { dashed: "" }),
1120
1112
  createVNode(_component_ARow, null, {
1121
1113
  default: withCtx(() => [
1122
- (openBlock(true), createElementBlock(Fragment, null, renderList(modalData.value, (it, index2) => {
1114
+ (openBlock(true), createElementBlock(Fragment, null, renderList(modalData.value, (it, index) => {
1123
1115
  return openBlock(), createBlock(_component_ACol, { span: 8 }, {
1124
1116
  default: withCtx(() => [
1125
1117
  createVNode(_component_ACheckbox, {
@@ -1145,7 +1137,6 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
1145
1137
  };
1146
1138
  }
1147
1139
  });
1148
- const DownloadCtrl = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/tableSetting/DownloadCtrl.vue"]]);
1149
1140
  const _hoisted_1$4 = /* @__PURE__ */ createElementVNode("span", { class: "flex" }, [
1150
1141
  /* @__PURE__ */ createElementVNode("i", { class: "i ic:baseline-download w-7 leading-7 text-center cursor-pointer" })
1151
1142
  ], -1);
@@ -1204,19 +1195,19 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
1204
1195
  createElementVNode("span", null, toDisplayString(unref(t)("EXPORT_CURRENT_PAGE")), 1)
1205
1196
  ]),
1206
1197
  _: 1
1207
- })) : createCommentVNode("v-if", true),
1198
+ })) : createCommentVNode("", true),
1208
1199
  unref(showSelectedDownload) ? (openBlock(), createBlock(_component_AMenuItem, { key: "select" }, {
1209
1200
  default: withCtx(() => [
1210
1201
  createElementVNode("span", null, toDisplayString(unref(t)("EXPORT_SELECT_COLUMN")), 1)
1211
1202
  ]),
1212
1203
  _: 1
1213
- })) : createCommentVNode("v-if", true),
1204
+ })) : createCommentVNode("", true),
1214
1205
  unref(showBackDownload) ? (openBlock(), createBlock(_component_AMenuItem, { key: "all" }, {
1215
1206
  default: withCtx(() => [
1216
1207
  createElementVNode("span", null, toDisplayString(unref(t)("EXPORT_ALL")), 1)
1217
1208
  ]),
1218
1209
  _: 1
1219
- })) : createCommentVNode("v-if", true)
1210
+ })) : createCommentVNode("", true)
1220
1211
  ]),
1221
1212
  _: 1
1222
1213
  })
@@ -1226,14 +1217,13 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
1226
1217
  ]),
1227
1218
  _: 1
1228
1219
  }),
1229
- createVNode(DownloadCtrl, { onRegister: unref(registerDialog) }, null, 8, ["onRegister"])
1220
+ createVNode(_sfc_main$6, { onRegister: unref(registerDialog) }, null, 8, ["onRegister"])
1230
1221
  ]),
1231
1222
  _: 1
1232
1223
  });
1233
1224
  };
1234
1225
  }
1235
1226
  });
1236
- const Download = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/tableSetting/Download.vue"]]);
1237
1227
  const _hoisted_1$3 = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:drag-outlined drag-icon cursor-pointer" }, null, -1);
1238
1228
  const _hoisted_2$1 = ["onClick"];
1239
1229
  const _hoisted_3$1 = ["onClick"];
@@ -1376,9 +1366,9 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
1376
1366
  return;
1377
1367
  const columns = getColumns();
1378
1368
  const isFixed = item.fixed === fixed ? false : fixed;
1379
- const index2 = columns.findIndex((col) => col.dataIndex === item.dataIndex);
1380
- if (index2 !== -1) {
1381
- columns[index2].fixed = isFixed;
1369
+ const index = columns.findIndex((col) => col.dataIndex === item.dataIndex);
1370
+ if (index !== -1) {
1371
+ columns[index].fixed = isFixed;
1382
1372
  }
1383
1373
  item.fixed = isFixed;
1384
1374
  if (isFixed && !item.width) {
@@ -1569,7 +1559,6 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
1569
1559
  };
1570
1560
  }
1571
1561
  });
1572
- const ColumnSetting = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/tableSetting/Column.vue"]]);
1573
1562
  const _hoisted_1$2 = { class: "flex dt-table-setting" };
1574
1563
  const _sfc_main$3 = /* @__PURE__ */ defineComponent({
1575
1564
  __name: "index",
@@ -1595,17 +1584,16 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
1595
1584
  }
1596
1585
  return (_ctx, _cache) => {
1597
1586
  return openBlock(), createElementBlock("div", _hoisted_1$2, [
1598
- unref(getSetting).download ? (openBlock(), createBlock(Download, normalizeProps(mergeProps({ key: 0 }, unref(getSetting))), null, 16)) : createCommentVNode("v-if", true),
1599
- unref(getSetting).setting ? (openBlock(), createBlock(ColumnSetting, {
1587
+ unref(getSetting).download ? (openBlock(), createBlock(_sfc_main$5, normalizeProps(mergeProps({ key: 0 }, unref(getSetting))), null, 16)) : createCommentVNode("", true),
1588
+ unref(getSetting).setting ? (openBlock(), createBlock(_sfc_main$4, {
1600
1589
  key: 1,
1601
1590
  onColumnsChange: handleColumnChange
1602
- })) : createCommentVNode("v-if", true),
1603
- unref(getSetting).fullscreen ? (openBlock(), createBlock(FullscreenSetting, { key: 2 })) : createCommentVNode("v-if", true)
1591
+ })) : createCommentVNode("", true),
1592
+ unref(getSetting).fullscreen ? (openBlock(), createBlock(_sfc_main$7, { key: 2 })) : createCommentVNode("", true)
1604
1593
  ]);
1605
1594
  };
1606
1595
  }
1607
1596
  });
1608
- const DtTableSetting = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/tableSetting/index.vue"]]);
1609
1597
  const _hoisted_1$1 = { class: "dt-table-header" };
1610
1598
  const _hoisted_2 = { class: "flex flex-row justify-between" };
1611
1599
  const _hoisted_3 = { class: "flex flex-row flex-1" };
@@ -1641,21 +1629,20 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
1641
1629
  return openBlock(), createElementBlock("div", _hoisted_1$1, [
1642
1630
  createElementVNode("div", _hoisted_2, [
1643
1631
  createElementVNode("div", _hoisted_3, [
1644
- unref(getActionsProps)?.buttonList.length ? (openBlock(), createBlock(unref(DtFormButtons), normalizeProps(mergeProps({ key: 0 }, unref(getActionsProps))), null, 16)) : createCommentVNode("v-if", true),
1632
+ unref(getActionsProps)?.buttonList.length ? (openBlock(), createBlock(unref(DtFormButtons), normalizeProps(mergeProps({ key: 0 }, unref(getActionsProps))), null, 16)) : createCommentVNode("", true),
1645
1633
  renderSlot(_ctx.$slots, "toolbar")
1646
1634
  ]),
1647
1635
  __props.tableSetting ? (openBlock(), createElementBlock("div", _hoisted_4, [
1648
- createVNode(DtTableSetting, { setting: __props.tableSetting }, null, 8, ["setting"])
1649
- ])) : createCommentVNode("v-if", true)
1636
+ createVNode(_sfc_main$3, { setting: __props.tableSetting }, null, 8, ["setting"])
1637
+ ])) : createCommentVNode("", true)
1650
1638
  ]),
1651
1639
  _ctx.$slots.headerTop ? (openBlock(), createElementBlock("div", _hoisted_5, [
1652
1640
  renderSlot(_ctx.$slots, "headerTop")
1653
- ])) : createCommentVNode("v-if", true)
1641
+ ])) : createCommentVNode("", true)
1654
1642
  ]);
1655
1643
  };
1656
1644
  }
1657
1645
  });
1658
- const TableHeader = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/TableHeader.vue"]]);
1659
1646
  function useTableHeader(propsRef, slots, handlers) {
1660
1647
  const { t } = useI18n("UI");
1661
1648
  const getHeaderProps = computed(() => {
@@ -1668,7 +1655,7 @@ function useTableHeader(propsRef, slots, handlers) {
1668
1655
  const hideTitle = (!toolbar || !toolbar.filter((it) => it.show ?? true).length) && !slots.toolbar && !slots.headerTop && !tableSetting;
1669
1656
  return {
1670
1657
  title: hideTitle ? null : () => h$1(
1671
- TableHeader,
1658
+ _sfc_main$2,
1672
1659
  {
1673
1660
  tableSetting,
1674
1661
  toolbar,
@@ -2048,14 +2035,14 @@ function useTableScroll(propsRef, tableElRef, columnsRef, rowSelectionRef) {
2048
2035
  };
2049
2036
  }
2050
2037
  function useRows(propsRef) {
2051
- function getRowClassName(record, index2) {
2038
+ function getRowClassName(record, index) {
2052
2039
  const { striped, rowClassName } = unref(propsRef);
2053
2040
  const classNames = [];
2054
2041
  if (striped) {
2055
- classNames.push(index2 % 2 === 1 ? "table-striped" : "");
2042
+ classNames.push(index % 2 === 1 ? "table-striped" : "");
2056
2043
  }
2057
2044
  if (rowClassName && isFunction(rowClassName)) {
2058
- classNames.push(rowClassName(record, index2));
2045
+ classNames.push(rowClassName(record, index));
2059
2046
  }
2060
2047
  return classNames.join(" ");
2061
2048
  }
@@ -2085,7 +2072,7 @@ const _sfc_main$1 = {
2085
2072
  const {
2086
2073
  column,
2087
2074
  record,
2088
- index: index2
2075
+ index
2089
2076
  } = props2;
2090
2077
  const {
2091
2078
  render,
@@ -2127,7 +2114,7 @@ const _sfc_main$1 = {
2127
2114
  });
2128
2115
  }
2129
2116
  } else if (isFunction(render)) {
2130
- let afterRenderData = render(record, index2, text);
2117
+ let afterRenderData = render(record, index, text);
2131
2118
  if (afterRenderData.__v_isRef) {
2132
2119
  renderText = afterRenderData;
2133
2120
  } else if (afterRenderData["setup"]) {
@@ -2145,7 +2132,6 @@ const _sfc_main$1 = {
2145
2132
  return () => createVNode("span", null, [unref(renderText)]);
2146
2133
  }
2147
2134
  };
2148
- const TableRender = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/components/TableRender.vue"]]);
2149
2135
  const DEFAULT_SORT_FN = (sortInfo) => {
2150
2136
  const { field, order } = sortInfo;
2151
2137
  return field && order ? { field, order } : {};
@@ -2248,11 +2234,11 @@ const TableProps = {
2248
2234
  },
2249
2235
  onOpenUpdateDialog: {
2250
2236
  type: Function,
2251
- default: (row, index2) => ({})
2237
+ default: (row, index) => ({})
2252
2238
  },
2253
2239
  onDelete: {
2254
2240
  type: Function,
2255
- default: (row, index2) => ({})
2241
+ default: (row, index) => ({})
2256
2242
  },
2257
2243
  onDeletes: {
2258
2244
  type: Function,
@@ -2400,16 +2386,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
2400
2386
  rowClassName: unref(getRowClassName),
2401
2387
  onChange: unref(handleTableChange)
2402
2388
  }), createSlots({
2403
- bodyCell: withCtx(({ column, record, index: index2 }) => [
2404
- _ctx.$slots.bodyCell ? renderSlot(_ctx.$slots, "bodyCell", normalizeProps(mergeProps({ key: 0 }, { column, record, index: index2 }))) : createCommentVNode("v-if", true),
2405
- column.slot ? renderSlot(_ctx.$slots, column.slot, normalizeProps(mergeProps({ key: 1 }, { column, record, index: index2 }))) : createCommentVNode("v-if", true),
2406
- createCommentVNode(" \u9759\u6001\u7684\u6570\u636E\u53EF\u4EE5\u901A\u8FC7customRender, \u4F46\u662F\u54CD\u5E94\u5F0F\u6570\u636E, \u5F02\u6B65\u51FD\u6570,\u7EC4\u4EF6\u7B49\u9700\u8981\u4F7F\u7528bodyCell\u6E32\u67D3 "),
2407
- column?.render && !column.slot && !_ctx.$slots.bodyCell ? (openBlock(), createBlock(TableRender, {
2389
+ bodyCell: withCtx(({ column, record, index }) => [
2390
+ _ctx.$slots.bodyCell ? renderSlot(_ctx.$slots, "bodyCell", normalizeProps(mergeProps({ key: 0 }, { column, record, index }))) : createCommentVNode("", true),
2391
+ column.slot ? renderSlot(_ctx.$slots, column.slot, normalizeProps(mergeProps({ key: 1 }, { column, record, index }))) : createCommentVNode("", true),
2392
+ column?.render && !column.slot && !_ctx.$slots.bodyCell ? (openBlock(), createBlock(_sfc_main$1, {
2408
2393
  key: 2,
2409
2394
  column,
2410
2395
  record,
2411
- index: index2
2412
- }, null, 8, ["column", "record", "index"])) : createCommentVNode("v-if", true)
2396
+ index
2397
+ }, null, 8, ["column", "record", "index"])) : createCommentVNode("", true)
2413
2398
  ]),
2414
2399
  emptyText: withCtx(() => [
2415
2400
  _hoisted_1
@@ -2428,8 +2413,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
2428
2413
  };
2429
2414
  }
2430
2415
  });
2431
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/table/src/index.vue"]]);
2432
2416
  export {
2433
- index as DtTable,
2417
+ _sfc_main as DtTable,
2434
2418
  useTable
2435
2419
  };
@@ -9,6 +9,9 @@ declare const _sfc_main: import("vue").DefineComponent<{
9
9
  type: BooleanConstructor;
10
10
  default: boolean;
11
11
  };
12
+ expandNum: {
13
+ type: NumberConstructor;
14
+ };
12
15
  width: {
13
16
  type: StringConstructor;
14
17
  default: string;
@@ -47,6 +50,9 @@ declare const _sfc_main: import("vue").DefineComponent<{
47
50
  type: BooleanConstructor;
48
51
  default: boolean;
49
52
  };
53
+ expandNum: {
54
+ type: NumberConstructor;
55
+ };
50
56
  width: {
51
57
  type: StringConstructor;
52
58
  default: string;
@@ -75,7 +75,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
75
75
  type: BooleanConstructor;
76
76
  default: boolean;
77
77
  };
78
- expandMethodIcon: {
78
+ expandActions: {
79
79
  type: BooleanConstructor;
80
80
  default: boolean;
81
81
  };
@@ -311,7 +311,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
311
311
  slotsTemplate: {};
312
312
  showIndexColumn: boolean;
313
313
  showCheckboxColumn: boolean;
314
- expandMethodIcon: boolean;
314
+ expandActions: boolean;
315
315
  ellipsis: boolean;
316
316
  canResize: boolean;
317
317
  onTableChange: Function;
@@ -478,7 +478,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
478
478
  type: BooleanConstructor;
479
479
  default: boolean;
480
480
  };
481
- expandMethodIcon: {
481
+ expandActions: {
482
482
  type: BooleanConstructor;
483
483
  default: boolean;
484
484
  };
@@ -607,7 +607,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
607
607
  slotsTemplate: {};
608
608
  showIndexColumn: boolean;
609
609
  showCheckboxColumn: boolean;
610
- expandMethodIcon: boolean;
610
+ expandActions: boolean;
611
611
  ellipsis: boolean;
612
612
  dataSource: import("@dt-frames/core").Recordable<any>[];
613
613
  bordered: boolean;
@@ -79,7 +79,7 @@ export declare const TableProps: {
79
79
  type: BooleanConstructor;
80
80
  default: boolean;
81
81
  };
82
- expandMethodIcon: {
82
+ expandActions: {
83
83
  type: BooleanConstructor;
84
84
  default: boolean;
85
85
  };