hfn-components 0.6.6 → 0.6.8

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 (46) hide show
  1. package/dist/index.css +1 -1
  2. package/es/components/chart/index.mjs +1 -0
  3. package/es/components/htTable/index.d.ts +135 -5
  4. package/es/components/htTable/index.mjs +1 -0
  5. package/es/components/htTable/src/columnDeal.vue.d.ts +1 -1
  6. package/es/components/htTable/src/columnDeal.vue.mjs +18 -11
  7. package/es/components/htTable/src/composables/index.d.ts +3 -0
  8. package/es/components/htTable/src/composables/index.mjs +3 -0
  9. package/es/components/htTable/src/composables/use-copy.d.ts +3 -0
  10. package/es/components/htTable/src/composables/use-copy.mjs +24 -0
  11. package/es/components/htTable/src/composables/use-pagination.d.ts +13 -0
  12. package/es/components/htTable/src/composables/use-pagination.mjs +33 -0
  13. package/es/components/htTable/src/composables/use-selection.d.ts +12 -0
  14. package/es/components/htTable/src/composables/use-selection.mjs +58 -0
  15. package/es/components/htTable/src/htTable.d.ts +37 -2
  16. package/es/components/htTable/src/htTable.mjs +22 -0
  17. package/es/components/htTable/src/htTable.vue.d.ts +57 -3
  18. package/es/components/htTable/src/htTable.vue.mjs +200 -95
  19. package/es/components/htTable/src/htTable.vue2.mjs +55 -25
  20. package/es/components/htTarget/index.mjs +1 -0
  21. package/es/components/htTarget/src/htTarget.vue.mjs +53 -58
  22. package/es/components/htTarget/src/htTarget.vue2.mjs +23 -24
  23. package/es/components/index.mjs +1 -1
  24. package/es/components/pieChart/index.mjs +1 -0
  25. package/es/constants/icons.d.ts +1 -0
  26. package/es/constants/icons.mjs +3 -0
  27. package/es/constants/index.d.ts +1 -0
  28. package/es/constants/index.mjs +3 -1
  29. package/es/constants/table.d.ts +102 -83
  30. package/es/constants/table.mjs +73 -45
  31. package/es/constants/target.d.ts +166 -15
  32. package/es/icons/index.d.ts +1 -0
  33. package/es/icons/index.mjs +1 -0
  34. package/es/icons/svg/empty-simple.svg.mjs +3 -0
  35. package/es/index.mjs +1 -1
  36. package/es/utils/index.mjs +1 -1
  37. package/es/utils/table.d.ts +11 -2
  38. package/es/utils/table.mjs +36 -26
  39. package/es/utils/tool.d.ts +1 -1
  40. package/es/utils/tool.mjs +8 -36
  41. package/package.json +29 -3
  42. package/theme-chalk/ht-table.css +1 -1
  43. package/theme-chalk/ht-target.css +1 -1
  44. package/theme-chalk/index.css +1 -1
  45. package/theme-chalk/src/table.scss +61 -4
  46. package/theme-chalk/src/target.scss +23 -3
@@ -1,109 +1,214 @@
1
1
  import _sfc_main from './htTable.vue2.mjs';
2
- import { withDirectives, openBlock, createBlock, withCtx, createElementBlock, Fragment, renderList, createElementVNode, toDisplayString, createCommentVNode, renderSlot, createVNode } from 'vue';
2
+ import { openBlock, createElementBlock, withDirectives, createBlock, withCtx, createCommentVNode, Fragment, renderList, createElementVNode, normalizeClass, toDisplayString, renderSlot, createVNode, withModifiers } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.mjs';
4
4
 
5
- const _hoisted_1 = {
6
- key: 0,
7
- class: "header-text-wrap"
8
- };
5
+ const _hoisted_1 = { class: "ht-table-wrapper" };
9
6
  const _hoisted_2 = { key: 0 };
10
7
  const _hoisted_3 = { key: 1 };
11
- const _hoisted_4 = {
12
- key: 1,
13
- class: "header-text-wrap"
8
+ const _hoisted_4 = { key: 2 };
9
+ const _hoisted_5 = { key: 0 };
10
+ const _hoisted_6 = { style: { "padding": "20px 0", "text-align": "center" } };
11
+ const _hoisted_7 = ["src"];
12
+ const _hoisted_8 = /* @__PURE__ */ createElementVNode(
13
+ "p",
14
+ { style: { "margin": "8px 0 0", "color": "#999", "font-size": "14px" } },
15
+ "\u6682\u65E0\u6570\u636E",
16
+ -1
17
+ /* HOISTED */
18
+ );
19
+ const _hoisted_9 = {
20
+ key: 0,
21
+ class: "ht-table-pagination"
14
22
  };
15
23
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
16
- return withDirectives((openBlock(), createBlock($setup["ElTable"], {
17
- data: $setup.props.dataSource,
18
- style: { "width": "100%" },
19
- height: "100%",
20
- "header-cell-style": {
21
- background: $setup.props.headerColor,
22
- color: "#000",
23
- "font-weight": 500,
24
- "font-size": "12px"
25
- }
26
- }, {
27
- default: withCtx(() => [
28
- (openBlock(true), createElementBlock(
29
- Fragment,
30
- null,
31
- renderList($setup.props.tableColumn, (item) => {
32
- return openBlock(), createBlock($setup["ElTableColumn"], {
33
- key: item.key,
34
- prop: item.key,
35
- width: item.width
36
- }, {
37
- header: withCtx(() => [
38
- item.customizeLabel ? (openBlock(), createElementBlock("span", _hoisted_1, [
39
- item.customizeLabel === "target" ? (openBlock(), createElementBlock("div", _hoisted_2, [
40
- createElementVNode(
41
- "div",
42
- null,
43
- toDisplayString($setup.targetHead.filter((items) => items.key === item.key.split("_")[0])[0].name),
44
- 1
45
- /* TEXT */
46
- ),
47
- createElementVNode(
48
- "div",
49
- null,
50
- toDisplayString($setup.TARGET_END_KEY.filter((items) => items.key === item.key.split("_")[1])[0].name),
51
- 1
52
- /* TEXT */
53
- )
54
- ])) : (openBlock(), createElementBlock(
55
- "div",
56
- _hoisted_3,
57
- toDisplayString($setup.wrapText(item.customizeLabel)),
24
+ return openBlock(), createElementBlock("div", _hoisted_1, [
25
+ withDirectives((openBlock(), createBlock($setup["ElTable"], {
26
+ ref: "tableRef",
27
+ data: $setup.props.dataSource,
28
+ "row-key": $setup.props.rowKey || void 0,
29
+ style: { "width": "100%" },
30
+ height: "100%",
31
+ "header-cell-style": {
32
+ background: $setup.props.headerColor,
33
+ color: "#000",
34
+ "font-weight": 500,
35
+ "font-size": "12px"
36
+ },
37
+ onSortChange: $setup.handleSortChange,
38
+ onFilterChange: $setup.handleFilterChange,
39
+ onSelectionChange: $setup.handleSelectionChange
40
+ }, {
41
+ empty: withCtx(() => [
42
+ createElementVNode("div", _hoisted_6, [
43
+ createElementVNode("img", {
44
+ src: $setup.EmptySimple,
45
+ alt: "\u6682\u65E0\u6570\u636E"
46
+ }, null, 8, _hoisted_7),
47
+ _hoisted_8
48
+ ])
49
+ ]),
50
+ default: withCtx(() => [
51
+ $setup.props.selectable ? (openBlock(), createBlock($setup["ElTableColumn"], {
52
+ key: 0,
53
+ type: "selection",
54
+ width: "32",
55
+ "reserve-selection": true
56
+ })) : createCommentVNode("v-if", true),
57
+ (openBlock(true), createElementBlock(
58
+ Fragment,
59
+ null,
60
+ renderList($setup.props.tableColumn, (item) => {
61
+ return openBlock(), createBlock($setup["ElTableColumn"], {
62
+ key: item.key,
63
+ prop: item.dataKey || item.key,
64
+ "column-key": item.dataKey || item.key,
65
+ width: item.width,
66
+ sortable: item.sortable || false,
67
+ filters: item.filters,
68
+ "filter-multiple": true,
69
+ "header-align": item.headerAlign || "left",
70
+ "show-overflow-tooltip": ""
71
+ }, {
72
+ header: withCtx(() => [
73
+ createCommentVNode(" \u81EA\u5B9A\u4E49\u8868\u5934\u63D2\u69FD "),
74
+ item.headerSlot ? renderSlot(_ctx.$slots, item.headerSlot, { key: 0 }) : item.customizeLabel ? (openBlock(), createElementBlock(
75
+ Fragment,
76
+ { key: 1 },
77
+ [
78
+ createCommentVNode(" \u539F\u6709\u8868\u5934\u903B\u8F91 "),
79
+ createElementVNode("span", null, [
80
+ item.customizeLabel === "target" ? (openBlock(), createElementBlock("div", _hoisted_2, [
81
+ createElementVNode(
82
+ "div",
83
+ null,
84
+ toDisplayString($setup.targetHead.filter((items) => items.key === item.key.split("_")[0])[0].name),
85
+ 1
86
+ /* TEXT */
87
+ ),
88
+ createElementVNode(
89
+ "div",
90
+ null,
91
+ toDisplayString($setup.TARGET_END_KEY.filter((items) => items.key === item.key.split("_")[1])[0].name),
92
+ 1
93
+ /* TEXT */
94
+ )
95
+ ])) : (openBlock(), createElementBlock(
96
+ "div",
97
+ _hoisted_3,
98
+ toDisplayString(item.customizeLabel),
99
+ 1
100
+ /* TEXT */
101
+ ))
102
+ ])
103
+ ],
104
+ 2112
105
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
106
+ )) : (openBlock(), createElementBlock(
107
+ "span",
108
+ _hoisted_4,
109
+ toDisplayString($setup.TABLE_KEY[item.key]),
58
110
  1
59
111
  /* TEXT */
60
112
  ))
61
- ])) : (openBlock(), createElementBlock(
62
- "span",
63
- _hoisted_4,
64
- toDisplayString($setup.wrapText($setup.TABLE_KEY[item.key])),
65
- 1
66
- /* TEXT */
67
- ))
68
- ]),
69
- default: withCtx((scope) => [
70
- createCommentVNode(" \u81EA\u5B9A\u4E49\u63D2\u69FD\uFF1A\u76F4\u63A5\u5728 HtTable \u5904\u7406\uFF0C\u4E0D\u7ECF\u8FC7 ColumnDeal "),
71
- item.dealType === "customSlot" ? renderSlot(_ctx.$slots, item.slot, {
72
- key: 0,
73
- text: $setup.convertKey(scope.row, item.key),
74
- row: scope.row
75
- }) : item.dealType === "other" ? (openBlock(), createElementBlock(
76
- Fragment,
77
- { key: 1 },
78
- [
79
- createCommentVNode(" \u5176\u4ED6\u7C7B\u578B\uFF1A\u901A\u8FC7 ColumnDeal \u5904\u7406 "),
80
- createVNode($setup["ColumnDeal"], {
81
- dealType: scope.row.dealType,
82
- text: $setup.convertKey(scope.row, item.key)
83
- }, null, 8, ["dealType", "text"])
84
- ],
85
- 2112
86
- /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
87
- )) : (openBlock(), createBlock($setup["ColumnDeal"], {
88
- key: 2,
89
- dealType: item.dealType,
90
- text: $setup.convertKey(scope.row, item.key),
91
- row: scope.row,
92
- "deal-function": item.dealFunction
93
- }, null, 8, ["dealType", "text", "row", "deal-function"]))
94
- ]),
95
- _: 2
96
- /* DYNAMIC */
97
- }, 1032, ["prop", "width"]);
98
- }),
99
- 128
100
- /* KEYED_FRAGMENT */
101
- ))
113
+ ]),
114
+ default: withCtx((scope) => [
115
+ createElementVNode(
116
+ "span",
117
+ {
118
+ class: normalizeClass({ "ht-table-cell-copy": item.copyable })
119
+ },
120
+ [
121
+ createElementVNode(
122
+ "span",
123
+ {
124
+ class: normalizeClass({ "ht-table-cell-text": item.copyable })
125
+ },
126
+ [
127
+ item.key === "index" ? (openBlock(), createElementBlock(
128
+ "span",
129
+ _hoisted_5,
130
+ toDisplayString($setup.getRowIndex(scope.$index)),
131
+ 1
132
+ /* TEXT */
133
+ )) : item.dealType === "customSlot" ? renderSlot(_ctx.$slots, item.slot, {
134
+ key: 1,
135
+ text: item.dataKey ? scope.row[item.dataKey] : scope.row[item.key],
136
+ row: scope.row
137
+ }) : item.dealType === "other" ? (openBlock(), createBlock($setup["ColumnDeal"], {
138
+ key: 2,
139
+ dealType: scope.row.dealType,
140
+ text: item.dataKey ? scope.row[item.dataKey] : $setup.convertKey(scope.row, item.key)
141
+ }, null, 8, ["dealType", "text"])) : (openBlock(), createBlock($setup["ColumnDeal"], {
142
+ key: 3,
143
+ dealType: item.dealType || "notProcessed",
144
+ text: item.dataKey ? scope.row[item.dataKey] : $setup.convertKey(scope.row, item.key),
145
+ row: scope.row,
146
+ "deal-function": item.dealFunction
147
+ }, null, 8, ["dealType", "text", "row", "deal-function"]))
148
+ ],
149
+ 2
150
+ /* CLASS */
151
+ ),
152
+ item.copyable ? (openBlock(), createBlock(
153
+ $setup["ElTooltip"],
154
+ {
155
+ key: 0,
156
+ content: "\u590D\u5236",
157
+ placement: "top",
158
+ "show-after": 300
159
+ },
160
+ {
161
+ default: withCtx(() => [
162
+ createVNode($setup["ElIcon"], {
163
+ class: "ht-copy-icon",
164
+ onClick: withModifiers(($event) => $setup.handleCopy(item.dataKey ? scope.row[item.dataKey] : scope.row[item.key]), ["stop"]),
165
+ onMouseenter: _cache[0] || (_cache[0] = withModifiers(() => {
166
+ }, ["stop"]))
167
+ }, {
168
+ default: withCtx(() => [
169
+ createVNode($setup["CopyDocument"])
170
+ ]),
171
+ _: 2
172
+ /* DYNAMIC */
173
+ }, 1032, ["onClick"])
174
+ ]),
175
+ _: 2
176
+ /* DYNAMIC */
177
+ },
178
+ 1024
179
+ /* DYNAMIC_SLOTS */
180
+ )) : createCommentVNode("v-if", true)
181
+ ],
182
+ 2
183
+ /* CLASS */
184
+ )
185
+ ]),
186
+ _: 2
187
+ /* DYNAMIC */
188
+ }, 1032, ["prop", "column-key", "width", "sortable", "filters", "header-align"]);
189
+ }),
190
+ 128
191
+ /* KEYED_FRAGMENT */
192
+ ))
193
+ ]),
194
+ _: 3
195
+ /* FORWARDED */
196
+ }, 8, ["data", "row-key", "header-cell-style", "onSelectionChange"])), [
197
+ [$setup["vLoading"], $setup.props.loading]
102
198
  ]),
103
- _: 3
104
- /* FORWARDED */
105
- }, 8, ["data", "header-cell-style"])), [
106
- [$setup["vLoading"], $setup.props.loading]
199
+ createCommentVNode(" \u5206\u9875\u5668 "),
200
+ $setup.props.pagination ? (openBlock(), createElementBlock("div", _hoisted_9, [
201
+ createVNode($setup["ElPagination"], {
202
+ background: "",
203
+ "current-page": $setup.currentPage,
204
+ "page-size": $setup.pageSize,
205
+ "page-sizes": $setup.props.pagination.pageSizes || [10, 20, 30, 50, 100],
206
+ layout: $setup.props.pagination.layout || "total, prev, pager, next, sizes, jumper",
207
+ total: $setup.total,
208
+ onCurrentChange: $setup.handleCurrentChange,
209
+ onSizeChange: $setup.handleSizeChange
210
+ }, null, 8, ["current-page", "page-size", "page-sizes", "layout", "total"])
211
+ ])) : createCommentVNode("v-if", true)
107
212
  ]);
108
213
  }
109
214
  var elTable = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__file", "/Users/libiluo/Desktop/company/component-library/packages/components/htTable/src/htTable.vue"]]);
@@ -1,11 +1,16 @@
1
- import { defineComponent, ref, onMounted } from 'vue';
2
- import { ElTable, ElTableColumn, vLoading } from 'element-plus';
3
- import { TABLE_KEY, convertKey } from '../../../constants/table.mjs';
4
- import { TARGET_HEAD_KEY, TARGET_END_KEY } from '../../../constants/target.mjs';
1
+ import { defineComponent, ref } from 'vue';
2
+ import { vLoading, ElTooltip, ElIcon, ElPagination, ElTableColumn, ElTable } from 'element-plus';
3
+ import { CopyDocument } from '@element-plus/icons-vue';
4
+ import { TABLE_KEY } from '../../../constants/table.mjs';
5
+ import { TARGET_END_KEY } from '../../../constants/target.mjs';
5
6
  import '../../../constants/chartConfig.mjs';
6
- import cloneDeep from 'lodash.clonedeep';
7
+ import EmptySimple from '../../../icons/svg/empty-simple.svg.mjs';
8
+ import { getTargetHeadWithYears, convertKey } from '../../../utils/table.mjs';
7
9
  import ColumnDeal from './columnDeal.vue.mjs';
8
10
  import { elTableProps } from './htTable.mjs';
11
+ import { useSelection } from './composables/use-selection.mjs';
12
+ import { usePagination } from './composables/use-pagination.mjs';
13
+ import { useCopy } from './composables/use-copy.mjs';
9
14
 
10
15
  var _sfc_main = /* @__PURE__ */ defineComponent({
11
16
  ...{
@@ -13,38 +18,63 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
13
18
  },
14
19
  __name: "htTable",
15
20
  props: elTableProps,
16
- setup(__props, { expose: __expose }) {
21
+ emits: ["sort-change", "filter-change", "selection-change", "page-change", "size-change"],
22
+ setup(__props, { expose: __expose, emit: __emit }) {
17
23
  __expose();
18
- const targetHead = ref(cloneDeep(TARGET_HEAD_KEY));
19
- onMounted(() => {
20
- let startYear = 2018;
21
- const nowYear = (/* @__PURE__ */ new Date()).getFullYear();
22
- while (startYear <= nowYear) {
23
- targetHead.value.push({
24
- name: `${startYear}`,
25
- key: `${startYear}`
26
- });
27
- startYear++;
28
- }
29
- });
24
+ const emit = __emit;
30
25
  const props = __props;
31
- const wrapText = (text, charsPerLine = 6) => {
32
- if (!text) return "";
33
- const regex = new RegExp(`.{1,${charsPerLine}}`, "g");
34
- return text.match(regex)?.join("\n") || text;
26
+ const tableRef = ref();
27
+ const handleSortChange = ({ prop, order }) => {
28
+ emit("sort-change", { field: prop, order });
29
+ };
30
+ const handleFilterChange = (filters) => {
31
+ emit("filter-change", filters);
35
32
  };
36
- const __returned__ = { targetHead, props, wrapText, get ElTable() {
33
+ const targetHead = getTargetHeadWithYears();
34
+ const {
35
+ currentPage,
36
+ pageSize,
37
+ total,
38
+ getRowIndex,
39
+ handleCurrentChange: onCurrentChange,
40
+ handleSizeChange: onSizeChange
41
+ } = usePagination({
42
+ pagination: () => props.pagination
43
+ });
44
+ const { handleSelectionChange } = useSelection(
45
+ {
46
+ tableRef,
47
+ dataSource: () => props.dataSource,
48
+ selectedRows: () => props.selectedRows,
49
+ rowKey: () => props.rowKey
50
+ },
51
+ (rows) => emit("selection-change", rows)
52
+ );
53
+ const handleCurrentChange = (page) => onCurrentChange(page, emit);
54
+ const handleSizeChange = (size) => onSizeChange(size, emit);
55
+ const { handleCopy } = useCopy();
56
+ const __returned__ = { emit, props, tableRef, handleSortChange, handleFilterChange, targetHead, currentPage, pageSize, total, getRowIndex, onCurrentChange, onSizeChange, handleSelectionChange, handleCurrentChange, handleSizeChange, handleCopy, get ElTable() {
37
57
  return ElTable;
38
58
  }, get ElTableColumn() {
39
59
  return ElTableColumn;
60
+ }, get ElPagination() {
61
+ return ElPagination;
62
+ }, get ElIcon() {
63
+ return ElIcon;
64
+ }, get ElTooltip() {
65
+ return ElTooltip;
40
66
  }, get vLoading() {
41
67
  return vLoading;
68
+ }, get CopyDocument() {
69
+ return CopyDocument;
42
70
  }, get TABLE_KEY() {
43
71
  return TABLE_KEY;
44
- }, get convertKey() {
45
- return convertKey;
46
72
  }, get TARGET_END_KEY() {
47
73
  return TARGET_END_KEY;
74
+ }, get EmptySimple() {
75
+ return EmptySimple;
76
+ }, get convertKey() {
77
+ return convertKey;
48
78
  }, ColumnDeal };
49
79
  Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true });
50
80
  return __returned__;
@@ -1,5 +1,6 @@
1
1
  import htTarget from './src/htTarget.vue.mjs';
2
2
  import { withInstall } from '../../utils/common.mjs';
3
+ import '../../constants/chartConfig.mjs';
3
4
 
4
5
  const HtTarget = withInstall(htTarget);
5
6
 
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './htTarget.vue2.mjs';
2
- import { openBlock, createElementBlock, createVNode, withCtx, createElementVNode, createTextVNode, createBlock, createCommentVNode, Fragment, renderList, toDisplayString } from 'vue';
2
+ import { openBlock, createElementBlock, createVNode, withCtx, createBlock, createCommentVNode, Fragment, renderList, createTextVNode, toDisplayString, createElementVNode } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.mjs';
4
4
 
5
5
  const _hoisted_1 = {
@@ -12,43 +12,17 @@ const _hoisted_3 = {
12
12
  style: { "width": "100%" }
13
13
  };
14
14
  const _hoisted_4 = { class: "factor-content" };
15
- const _hoisted_5 = ["onClick"];
16
- const _hoisted_6 = /* @__PURE__ */ createElementVNode(
17
- "svg",
18
- {
19
- t: "1736836637226",
20
- class: "icon",
21
- viewBox: "0 0 1024 1024",
22
- version: "1.1",
23
- xmlns: "http://www.w3.org/2000/svg",
24
- "p-id": "8732",
25
- width: "15",
26
- height: "15"
27
- },
28
- [
29
- /* @__PURE__ */ createElementVNode("path", {
30
- d: "M912.064 187.984L583.968 516.064l316.768 316.8-67.872 67.872-316.768-316.8-328.112 328.128-67.888-67.888 328.112-328.112L108.784 176.672l67.888-67.888 339.424 339.392L844.16 120.096l67.888 67.888z",
31
- fill: "#bfbfbf",
32
- "p-id": "8733"
33
- })
34
- ],
35
- -1
36
- /* HOISTED */
37
- );
38
- const _hoisted_7 = [
39
- _hoisted_6
40
- ];
41
- const _hoisted_8 = { class: "dialog-footer" };
15
+ const _hoisted_5 = { class: "dialog-footer" };
42
16
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
43
17
  return openBlock(), createElementBlock("div", null, [
44
18
  createVNode($setup["ElDialog"], {
45
19
  modelValue: $setup.dialogShow,
46
- "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => $setup.dialogShow = $event),
20
+ "onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => $setup.dialogShow = $event),
47
21
  class: "dialog",
48
- onClose: _cache[5] || (_cache[5] = ($event) => $setup.emit("choiceCancel"))
22
+ onClose: _cache[6] || (_cache[6] = ($event) => $setup.emit("choiceCancel"))
49
23
  }, {
50
24
  footer: withCtx(() => [
51
- createElementVNode("div", _hoisted_8, [
25
+ createElementVNode("div", _hoisted_5, [
52
26
  createVNode($setup["ElButton"], {
53
27
  onClick: $setup.confirmTarge,
54
28
  type: "primary"
@@ -138,7 +112,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
138
112
  }, [
139
113
  createVNode($setup["ElCheckbox"], {
140
114
  onChange: ($event) => $setup.selectedTarget(item.key, $setup.selectedHead, "target"),
141
- disabled: $setup.checkList.includes(item.key),
115
+ disabled: $setup.checkListSet.has(item.key),
142
116
  label: item.name,
143
117
  value: item.key
144
118
  }, null, 8, ["onChange", "disabled", "label", "value"])
@@ -162,14 +136,14 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
162
136
  (openBlock(true), createElementBlock(
163
137
  Fragment,
164
138
  null,
165
- renderList($setup.BASIC_KEY.filter((v) => v.type === _ctx.fundType), (item) => {
139
+ renderList($setup.filteredBasicKey, (item) => {
166
140
  return openBlock(), createElementBlock("div", {
167
141
  class: "factor_item",
168
142
  key: item.key
169
143
  }, [
170
144
  createVNode($setup["ElCheckbox"], {
171
145
  onChange: ($event) => $setup.selectedTarget(item.key, $setup.selectedHead, "basic"),
172
- disabled: $setup.checkList.includes(item.key),
146
+ disabled: $setup.checkListSet.has(item.key),
173
147
  label: item.name,
174
148
  value: item.key
175
149
  }, null, 8, ["onChange", "disabled", "label", "value"])
@@ -197,30 +171,51 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
197
171
  class: "flow-col"
198
172
  }, {
199
173
  default: withCtx(() => [
200
- (openBlock(true), createElementBlock(
201
- Fragment,
202
- null,
203
- renderList($setup.selectedList, (item) => {
204
- return openBlock(), createElementBlock("div", {
205
- key: item.key,
206
- class: "check_item"
207
- }, [
208
- createElementVNode(
209
- "span",
210
- null,
211
- toDisplayString(item.name),
212
- 1
213
- /* TEXT */
214
- ),
215
- createElementVNode("span", {
216
- class: "flex-alignCnter",
217
- onClick: ($event) => $setup.deleteItem(item.key)
218
- }, [..._hoisted_7], 8, _hoisted_5)
219
- ]);
220
- }),
221
- 128
222
- /* KEYED_FRAGMENT */
223
- ))
174
+ createVNode($setup["VueDraggable"], {
175
+ modelValue: $setup.selectedList,
176
+ "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => $setup.selectedList = $event),
177
+ animation: 150,
178
+ "force-fallback": true,
179
+ "ghost-class": "ghost",
180
+ class: "drag-list"
181
+ }, {
182
+ default: withCtx(() => [
183
+ (openBlock(true), createElementBlock(
184
+ Fragment,
185
+ null,
186
+ renderList($setup.selectedList, (item) => {
187
+ return openBlock(), createElementBlock("div", {
188
+ key: item.key,
189
+ class: "check_item"
190
+ }, [
191
+ createElementVNode(
192
+ "span",
193
+ null,
194
+ toDisplayString(item.name),
195
+ 1
196
+ /* TEXT */
197
+ ),
198
+ createVNode($setup["ElIcon"], {
199
+ size: 15,
200
+ color: "#bfbfbf",
201
+ class: "close-icon",
202
+ onClick: ($event) => $setup.deleteItem(item.key)
203
+ }, {
204
+ default: withCtx(() => [
205
+ createVNode($setup["Close"])
206
+ ]),
207
+ _: 2
208
+ /* DYNAMIC */
209
+ }, 1032, ["onClick"])
210
+ ]);
211
+ }),
212
+ 128
213
+ /* KEYED_FRAGMENT */
214
+ ))
215
+ ]),
216
+ _: 1
217
+ /* STABLE */
218
+ }, 8, ["modelValue"])
224
219
  ]),
225
220
  _: 1
226
221
  /* STABLE */