hy-dispatch-ui-v3 0.2.30 → 0.2.32

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 (54) hide show
  1. package/dist/tailwind.css +8 -8
  2. package/es/components/hyAudioPlayer/audioPlayer.vue.mjs +7 -7
  3. package/es/components/hyAudioPlayer/js/index.mjs +3 -3
  4. package/es/components/hyButton/button.vue.mjs +112 -65
  5. package/es/components/hyButton/style/button.scss +282 -237
  6. package/es/components/hyForm/index.mjs +1 -1
  7. package/es/components/hyForm/js/useAppForm.mjs +1 -2
  8. package/es/components/hyIcon/style/icon.scss +6 -0
  9. package/es/components/hyMenu/menu.vue.mjs +1 -1
  10. package/es/components/hyMenu/style/menu.scss +1 -1
  11. package/es/components/hyNoPermissions/noPermissions.vue.mjs +1 -1
  12. package/es/components/hyNoPermissionsMap/noPermissionsMap.vue.mjs +1 -1
  13. package/es/components/hySearch/index.mjs +1 -1
  14. package/es/components/hyTable/cpns/virtualTable.vue.mjs +331 -319
  15. package/es/components/hyTable/js/index.mjs +7 -3
  16. package/es/components/hyTable/js/useAppTable.mjs +1 -1
  17. package/es/components/hyTable/table.vue.mjs +11 -7
  18. package/es/components/hyTree/tree.vue.mjs +6 -7
  19. package/es/components/hyUserAvatar/userAvatar.vue.mjs +2 -2
  20. package/es/components/hyVideoPlayer/js/index.mjs +3 -3
  21. package/es/components/hyVideoPlayer/videoPlayer.vue.mjs +11 -11
  22. package/es/components/index.mjs +2 -2
  23. package/es/index.mjs +2 -2
  24. package/es/static/hy-svg-icons/hy-icon-dispatch-linear-map-treelist.js +8 -0
  25. package/es/static/hy-svg-icons/hy-icon-dispatch-share-guidao.js +8 -0
  26. package/es/utils/handler.mjs +4 -4
  27. package/es/version.mjs +1 -1
  28. package/lib/components/hyAudioPlayer/audioPlayer.vue.js +7 -7
  29. package/lib/components/hyAudioPlayer/js/index.js +3 -3
  30. package/lib/components/hyButton/button.vue.js +111 -64
  31. package/lib/components/hyButton/style/button.scss +282 -237
  32. package/lib/components/hyForm/index.js +1 -0
  33. package/lib/components/hyForm/js/useAppForm.js +1 -2
  34. package/lib/components/hyIcon/style/icon.scss +6 -0
  35. package/lib/components/hyMenu/menu.vue.js +1 -1
  36. package/lib/components/hyMenu/style/menu.scss +1 -1
  37. package/lib/components/hyNoPermissions/noPermissions.vue.js +1 -1
  38. package/lib/components/hyNoPermissionsMap/noPermissionsMap.vue.js +1 -1
  39. package/lib/components/hySearch/index.js +1 -0
  40. package/lib/components/hyTable/cpns/virtualTable.vue.js +329 -317
  41. package/lib/components/hyTable/js/index.js +7 -3
  42. package/lib/components/hyTable/js/useAppTable.js +1 -1
  43. package/lib/components/hyTable/table.vue.js +11 -7
  44. package/lib/components/hyTree/tree.vue.js +5 -6
  45. package/lib/components/hyUserAvatar/userAvatar.vue.js +2 -2
  46. package/lib/components/hyVideoPlayer/js/index.js +3 -3
  47. package/lib/components/hyVideoPlayer/videoPlayer.vue.js +11 -11
  48. package/lib/components/index.js +2 -0
  49. package/lib/index.js +2 -0
  50. package/lib/static/hy-svg-icons/hy-icon-dispatch-linear-map-treelist.js +8 -0
  51. package/lib/static/hy-svg-icons/hy-icon-dispatch-share-guidao.js +8 -0
  52. package/lib/utils/handler.js +4 -4
  53. package/lib/version.js +1 -1
  54. package/package.json +1 -1
@@ -1,10 +1,10 @@
1
- import { ref, computed, openBlock, createBlock, unref, withCtx, renderSlot, createCommentVNode, createElementBlock, Fragment, createElementVNode, normalizeClass, renderList, normalizeStyle, withModifiers, createVNode, mergeProps, createTextVNode, toDisplayString, normalizeProps, guardReactiveProps } from 'vue';
1
+ import { computed, ref, openBlock, createBlock, unref, withCtx, renderSlot, createCommentVNode, createElementBlock, Fragment, renderList, normalizeStyle, withModifiers, normalizeClass, createVNode, mergeProps, createTextVNode, toDisplayString, createElementVNode, normalizeProps, guardReactiveProps } from 'vue';
2
2
  import { ElTableV2, ElIcon, ElCheckbox, ElDropdown, ElDropdownMenu, ElDropdownItem } from 'element-plus';
3
3
  import { ArrowRight, MoreFilled } from '@element-plus/icons-vue';
4
4
  import { operatorFilterHandler, operatorClickHandler, operatorDisabledHandler, operatorDisableTextdHandler, renderContentHandler, renderHeaderHandler } from '../js/index.mjs';
5
5
  import _sfc_main$1 from './headerItem.vue.mjs';
6
6
  import { useLocale } from '../../../hooks/useLocale.mjs';
7
- import { isNumber, isEmpty, isBoolean, isArray, isFunction } from '../../../utils/is.mjs';
7
+ import { isNumber, isEmpty, isBoolean, isArray, isString, isFunction } from '../../../utils/is.mjs';
8
8
  import { HyTooltip } from '../../hyTooltip/index.mjs';
9
9
  import { HyIcon } from '../../hyIcon/index.mjs';
10
10
 
@@ -12,7 +12,8 @@ const _sfc_main = {
12
12
  __name: "virtualTable",
13
13
  props: {
14
14
  rowKey: {
15
- type: [String, Number]
15
+ type: [String, Number],
16
+ default: "id"
16
17
  },
17
18
  width: {
18
19
  type: Number
@@ -44,6 +45,9 @@ const _sfc_main = {
44
45
  type: Object,
45
46
  default: () => ({})
46
47
  },
48
+ rowClassName: {
49
+ type: [String, Function]
50
+ },
47
51
  onRowClick: {
48
52
  type: Function
49
53
  },
@@ -51,25 +55,11 @@ const _sfc_main = {
51
55
  type: Function
52
56
  }
53
57
  },
54
- emits: ["search", "select", "select-all"],
58
+ emits: ["search", "select", "select-all", "expand-change"],
55
59
  setup(__props, { expose: __expose, emit: __emit }) {
56
60
  const props = __props;
57
61
  const emits = __emit;
58
62
  const { t } = useLocale();
59
- const expandedKeys = ref([]);
60
- const expandedMap = computed(() => {
61
- return expandedKeys.value.reduce((keyMap, key, index) => {
62
- keyMap.set(key, index);
63
- return keyMap;
64
- }, /* @__PURE__ */ new Map());
65
- });
66
- function onRowExpandSwitch({ rowKey }) {
67
- if (expandedMap.value.has(rowKey)) {
68
- expandedKeys.value.splice(expandedMap.value.get(rowKey), 1);
69
- } else {
70
- expandedKeys.value.push(rowKey);
71
- }
72
- }
73
63
  const avgWidth = computed(() => {
74
64
  const { total, totalWidth } = props.columns.reduce(
75
65
  ({ total: total2, totalWidth: totalWidth2 }, column) => {
@@ -109,7 +99,7 @@ const _sfc_main = {
109
99
  return props.data.map((item) => {
110
100
  item.children = [
111
101
  {
112
- id: /* @__PURE__ */ Symbol("expandKey"),
102
+ [props.rowKey]: /* @__PURE__ */ Symbol("expandKey"),
113
103
  rowType: "expand",
114
104
  dataKey: getRowKey(item)
115
105
  }
@@ -125,6 +115,15 @@ const _sfc_main = {
125
115
  function getRowKey(row) {
126
116
  return row[props.rowKey];
127
117
  }
118
+ function rowClass({ rowData: row, rowIndex }) {
119
+ let className = [];
120
+ if (isString(props.rowClassName)) {
121
+ className.push(props.rowClassName);
122
+ } else if (isFunction(props.rowClassName)) {
123
+ className.push(props.rowClassName({ row, rowIndex }));
124
+ }
125
+ return className.filter(Boolean).join(" ");
126
+ }
128
127
  function generateDataSourceMap(list, dataMap = /* @__PURE__ */ new Map()) {
129
128
  return (list || []).reduce((dataMap2, data) => {
130
129
  if (data.children) {
@@ -247,22 +246,42 @@ const _sfc_main = {
247
246
  const { allChecked } = handler(list, checkedNodeMap, indeterminateKeys2);
248
247
  return { checkedNodeMap, indeterminateKeys: indeterminateKeys2, allChecked };
249
248
  }
249
+ const expandedKeys = ref([]);
250
+ const expandedMap = computed(() => {
251
+ return expandedKeys.value.reduce((keyMap, key, index) => {
252
+ keyMap.set(key, index);
253
+ return keyMap;
254
+ }, /* @__PURE__ */ new Map());
255
+ });
256
+ function toggleRowExpansion(row, expanded) {
257
+ const index = expandedMap.value.get(getRowKey(row));
258
+ const isExpanded = isBoolean(expanded) ? expanded : !isNumber(index);
259
+ if (isExpanded) {
260
+ if (!isNumber(index)) {
261
+ expandedKeys.value.push(getRowKey(row));
262
+ }
263
+ } else {
264
+ if (isNumber(index)) {
265
+ expandedKeys.value.splice(index, 1);
266
+ }
267
+ }
268
+ if (isExpandTable.value) {
269
+ const expandedList = expandedKeys.value.reduce((list, key) => {
270
+ list.push(dataSourceMap.value.get(key));
271
+ return list;
272
+ }, []);
273
+ emits("expand-change", row, expandedList);
274
+ } else {
275
+ emits("expand-change", row, isExpanded);
276
+ }
277
+ }
278
+ function onRowExpandSwitch({ row, rowKey }) {
279
+ toggleRowExpansion(row, !expandedMap.value.has(rowKey));
280
+ }
250
281
  __expose({
251
282
  toggleRowSelection,
252
283
  toggleAllSelection,
253
- toggleRowExpansion(row, expanded) {
254
- const index = expandedMap.value.get(getRowKey(row));
255
- const isExpanded = isBoolean(expanded) ? expanded : !isNumber(index);
256
- if (isExpanded) {
257
- if (!isNumber(index)) {
258
- expandedKeys.value.push(getRowKey(row));
259
- }
260
- } else {
261
- if (isNumber(index)) {
262
- expandedKeys.value.splice(index, 1);
263
- }
264
- }
265
- },
284
+ toggleRowExpansion,
266
285
  clearSelection: () => {
267
286
  isAllChecked.value = false;
268
287
  selectedMap.value.clear();
@@ -283,6 +302,7 @@ const _sfc_main = {
283
302
  "estimated-row-height": 50,
284
303
  "expand-column-key": expandColumn.value?.key,
285
304
  fixed: "",
305
+ "row-class": rowClass,
286
306
  "row-event-handlers": {
287
307
  onClick: onRowClickHandler,
288
308
  onContextmenu: onContextmenuHandler
@@ -332,308 +352,300 @@ const _sfc_main = {
332
352
  { key: 1 },
333
353
  [
334
354
  createCommentVNode(" \u5355\u5143\u683C\u5185\u5BB9 "),
335
- createElementVNode("div", {
336
- class: normalizeClass(["hy-el-table-v2__row is-customized", [
337
- `hy-el-table-v2__row-depth-${depth}`,
338
- { "is-expanded": expandedMap.value.has(getRowKey(row)) }
339
- ]]),
340
- role: "row",
341
- rowkey: getRowKey(row)
342
- }, [
343
- (openBlock(true), createElementBlock(
344
- Fragment,
345
- null,
346
- renderList(columns, (column, cellIndex) => {
347
- return openBlock(), createElementBlock(
348
- "div",
349
- {
350
- key: cellIndex,
351
- class: "hy-el-table-v2__row-cell",
352
- role: "cell",
353
- style: normalizeStyle([{ "flex": "0 0 auto" }, { width: `${column.width}px` }])
354
- },
355
- [
356
- column.type === "expand" ? (openBlock(), createElementBlock(
355
+ (openBlock(true), createElementBlock(
356
+ Fragment,
357
+ null,
358
+ renderList(columns, (column, cellIndex) => {
359
+ return openBlock(), createElementBlock(
360
+ "div",
361
+ {
362
+ key: cellIndex,
363
+ class: "hy-el-table-v2__row-cell",
364
+ role: "cell",
365
+ style: normalizeStyle([{ "flex": "0 0 auto" }, { width: `${column.width}px` }])
366
+ },
367
+ [
368
+ column.type === "expand" ? (openBlock(), createElementBlock(
369
+ Fragment,
370
+ { key: 0 },
371
+ [
372
+ row.children && row.children.length ? (openBlock(), createElementBlock("button", {
373
+ key: 0,
374
+ type: "button",
375
+ "aria-label": "\u5C55\u5F00\u5F53\u524D\u884C",
376
+ "aria-expanded": "false",
377
+ class: normalizeClass(["hy-el-table-v2__expand-icon", { "is-expanded": expandedMap.value.has(getRowKey(row)) }]),
378
+ onClick: withModifiers(($event) => onRowExpandSwitch({
379
+ rowData: _ctx.rowData,
380
+ row,
381
+ rowKey: getRowKey(row)
382
+ }), ["stop"])
383
+ }, [
384
+ createVNode(unref(ElIcon), {
385
+ style: normalizeStyle({ "margin-inline-start": `${depth * 12}px` })
386
+ }, {
387
+ default: withCtx(() => [
388
+ createVNode(unref(ArrowRight))
389
+ ]),
390
+ _: 1
391
+ /* STABLE */
392
+ }, 8, ["style"])
393
+ ], 10, ["onClick"])) : (openBlock(), createElementBlock(
394
+ "div",
395
+ {
396
+ key: 1,
397
+ class: "w-3 h-3",
398
+ style: normalizeStyle({ "margin-inline-start": `${(depth + 1) * 12}px` })
399
+ },
400
+ null,
401
+ 4
402
+ /* STYLE */
403
+ ))
404
+ ],
405
+ 64
406
+ /* STABLE_FRAGMENT */
407
+ )) : createCommentVNode("v-if", true),
408
+ column.type === "selection" ? (openBlock(), createBlock(unref(ElCheckbox), {
409
+ key: 1,
410
+ "model-value": selectedMap.value.has(getRowKey(row)),
411
+ indeterminate: indeterminateKeys.value.has(getRowKey(row)),
412
+ disabled: !isSelectable(row),
413
+ onClick: withModifiers(($event) => switchCheckHandler(row), ["stop"])
414
+ }, null, 8, ["model-value", "indeterminate", "disabled", "onClick"])) : column?.slot && (column.type !== "expand" || !isExpandTable.value) ? renderSlot(_ctx.$slots, column?.slot, mergeProps({
415
+ key: 2,
416
+ ref_for: true
417
+ }, { column, row, $index, cellIndex })) : column.type === "index" ? (openBlock(), createElementBlock(
418
+ Fragment,
419
+ { key: 3 },
420
+ [
421
+ createTextVNode(
422
+ toDisplayString(columnIndexHandler({ column, row, $index, cellIndex })),
423
+ 1
424
+ /* TEXT */
425
+ )
426
+ ],
427
+ 64
428
+ /* STABLE_FRAGMENT */
429
+ )) : column.type === "operator" ? (openBlock(), createElementBlock("div", {
430
+ key: 4,
431
+ class: "w-full flex items-center justify-between text-main",
432
+ onClick: withModifiers(() => {
433
+ }, ["stop"]),
434
+ onContextmenu: withModifiers(() => {
435
+ }, ["stop"])
436
+ }, [
437
+ (openBlock(true), createElementBlock(
357
438
  Fragment,
358
- { key: 0 },
359
- [
360
- row.children && row.children.length ? (openBlock(), createElementBlock("button", {
361
- key: 0,
362
- type: "button",
363
- "aria-label": "\u5C55\u5F00\u5F53\u524D\u884C",
364
- "aria-expanded": "false",
365
- class: normalizeClass(["hy-el-table-v2__expand-icon", { "is-expanded": expandedMap.value.has(getRowKey(row)) }]),
366
- onClick: withModifiers(($event) => onRowExpandSwitch({
367
- rowData: _ctx.rowData,
368
- rowKey: getRowKey(row)
369
- }), ["stop"])
370
- }, [
371
- createVNode(unref(ElIcon), {
372
- style: normalizeStyle({ "margin-inline-start": `${depth * 12}px` })
373
- }, {
439
+ null,
440
+ renderList(unref(operatorFilterHandler)(
441
+ column,
442
+ { column, row, $index, cellIndex },
443
+ "default"
444
+ ), (citem, cindex) => {
445
+ return openBlock(), createBlock(unref(HyTooltip), {
446
+ key: cindex,
447
+ "is-always": "",
448
+ overLine: 1,
449
+ content: citem.label
450
+ }, {
451
+ default: withCtx(() => [
452
+ createElementVNode("div", {
453
+ class: normalizeClass(["w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer", citem.className]),
454
+ onClick: ($event) => unref(operatorClickHandler)(
455
+ cindex,
456
+ column,
457
+ { column, row, $index, cellIndex },
458
+ "default"
459
+ )
460
+ }, [
461
+ createVNode(unref(HyIcon), {
462
+ "svg-name": citem.svgName,
463
+ "class-name": "!w-4 !h-4"
464
+ }, null, 8, ["svg-name"]),
465
+ citem.subLabel ? (openBlock(), createElementBlock(
466
+ "div",
467
+ {
468
+ key: 0,
469
+ class: "mt-1 whitespace-nowrap"
470
+ },
471
+ toDisplayString(citem.subLabel),
472
+ 1
473
+ /* TEXT */
474
+ )) : (openBlock(), createElementBlock("div", {
475
+ key: 1,
476
+ class: "mt-1 whitespace-nowrap"
477
+ }, "\xA0"))
478
+ ], 10, ["onClick"])
479
+ ]),
480
+ _: 2
481
+ /* DYNAMIC */
482
+ }, 1032, ["content"]);
483
+ }),
484
+ 128
485
+ /* KEYED_FRAGMENT */
486
+ )),
487
+ unref(operatorFilterHandler)(
488
+ column,
489
+ { column, row, $index, cellIndex },
490
+ "more"
491
+ )?.length ? (openBlock(), createBlock(unref(ElDropdown), {
492
+ key: 0,
493
+ ref_for: true,
494
+ ref: "operatorDropdownRef",
495
+ trigger: "click",
496
+ "popper-style": "min-width: 150px",
497
+ placement: "bottom",
498
+ onCommand: ($event) => unref(operatorClickHandler)(
499
+ $event,
500
+ column,
501
+ { column, row, $index, cellIndex },
502
+ "more"
503
+ )
504
+ }, {
505
+ dropdown: withCtx(() => [
506
+ createVNode(
507
+ unref(ElDropdownMenu),
508
+ null,
509
+ {
374
510
  default: withCtx(() => [
375
- createVNode(unref(ArrowRight))
511
+ (openBlock(true), createElementBlock(
512
+ Fragment,
513
+ null,
514
+ renderList(unref(operatorFilterHandler)(
515
+ column,
516
+ { column, row, $index, cellIndex },
517
+ "more"
518
+ ), (citem, cindex) => {
519
+ return openBlock(), createBlock(unref(ElDropdownItem), {
520
+ key: cindex,
521
+ command: cindex,
522
+ disabled: unref(operatorDisabledHandler)(citem, {
523
+ column,
524
+ row,
525
+ $index,
526
+ cellIndex
527
+ })
528
+ }, {
529
+ default: withCtx(() => [
530
+ createElementVNode("span", null, [
531
+ createElementVNode(
532
+ "span",
533
+ null,
534
+ toDisplayString(citem.label),
535
+ 1
536
+ /* TEXT */
537
+ ),
538
+ unref(operatorDisabledHandler)(citem, {
539
+ column,
540
+ row,
541
+ $index,
542
+ cellIndex
543
+ }) ? (openBlock(), createElementBlock(
544
+ "span",
545
+ {
546
+ key: 0,
547
+ class: "text-xs leading-1"
548
+ },
549
+ "\uFF08" + toDisplayString(unref(operatorDisableTextdHandler)(citem, {
550
+ column,
551
+ row,
552
+ $index,
553
+ cellIndex
554
+ })) + "\uFF09",
555
+ 1
556
+ /* TEXT */
557
+ )) : createCommentVNode("v-if", true)
558
+ ])
559
+ ]),
560
+ _: 2
561
+ /* DYNAMIC */
562
+ }, 1032, ["command", "disabled"]);
563
+ }),
564
+ 128
565
+ /* KEYED_FRAGMENT */
566
+ ))
376
567
  ]),
377
- _: 1
378
- /* STABLE */
379
- }, 8, ["style"])
380
- ], 10, ["onClick"])) : (openBlock(), createElementBlock(
381
- "div",
382
- {
383
- key: 1,
384
- class: "w-3 h-3",
385
- style: normalizeStyle({ "margin-inline-start": `${(depth + 1) * 12}px` })
568
+ _: 2
569
+ /* DYNAMIC */
386
570
  },
387
- null,
388
- 4
389
- /* STYLE */
390
- ))
391
- ],
392
- 64
393
- /* STABLE_FRAGMENT */
394
- )) : createCommentVNode("v-if", true),
395
- column.type === "selection" ? (openBlock(), createBlock(unref(ElCheckbox), {
396
- key: 1,
397
- "model-value": selectedMap.value.has(getRowKey(row)),
398
- indeterminate: indeterminateKeys.value.has(getRowKey(row)),
399
- disabled: !isSelectable(row),
400
- onClick: withModifiers(($event) => switchCheckHandler(row), ["stop"])
401
- }, null, 8, ["model-value", "indeterminate", "disabled", "onClick"])) : column?.slot && (column.type !== "expand" || !isExpandTable.value) ? renderSlot(_ctx.$slots, column?.slot, mergeProps({
402
- key: 2,
403
- ref_for: true
404
- }, { column, row, $index, cellIndex })) : column.type === "index" ? (openBlock(), createElementBlock(
405
- Fragment,
406
- { key: 3 },
407
- [
408
- createTextVNode(
409
- toDisplayString(columnIndexHandler({ column, row, $index, cellIndex })),
410
- 1
411
- /* TEXT */
571
+ 1024
572
+ /* DYNAMIC_SLOTS */
412
573
  )
413
- ],
414
- 64
415
- /* STABLE_FRAGMENT */
416
- )) : column.type === "operator" ? (openBlock(), createElementBlock("div", {
417
- key: 4,
418
- class: "w-full flex items-center justify-between text-main",
419
- onClick: withModifiers(() => {
420
- }, ["stop"]),
421
- onContextmenu: withModifiers(() => {
422
- }, ["stop"])
423
- }, [
424
- (openBlock(true), createElementBlock(
425
- Fragment,
426
- null,
427
- renderList(unref(operatorFilterHandler)(
428
- column,
429
- { column, row, $index, cellIndex },
430
- "default"
431
- ), (citem, cindex) => {
432
- return openBlock(), createBlock(unref(HyTooltip), {
433
- key: cindex,
574
+ ]),
575
+ default: withCtx(() => [
576
+ createElementVNode("span", null, [
577
+ createVNode(unref(HyTooltip), {
434
578
  "is-always": "",
435
579
  overLine: 1,
436
- content: citem.label
580
+ content: unref(t)("table.moreOperations")
437
581
  }, {
438
582
  default: withCtx(() => [
439
- createElementVNode("div", {
440
- class: normalizeClass(["w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer", citem.className]),
441
- onClick: ($event) => unref(operatorClickHandler)(
442
- cindex,
443
- column,
444
- { column, row, $index, cellIndex },
445
- "default"
446
- )
447
- }, [
448
- createVNode(unref(HyIcon), {
449
- "svg-name": citem.svgName,
450
- "class-name": "!w-4 !h-4"
451
- }, null, 8, ["svg-name"]),
452
- citem.subLabel ? (openBlock(), createElementBlock(
583
+ createElementVNode("div", { class: "w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-main text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer" }, [
584
+ createElementVNode("div", { class: "w-4 h-4" }, [
585
+ createVNode(unref(ElIcon), {
586
+ size: "16",
587
+ color: "rgba(var(--hy-main))"
588
+ }, {
589
+ default: withCtx(() => [
590
+ createVNode(unref(MoreFilled))
591
+ ]),
592
+ _: 1
593
+ /* STABLE */
594
+ })
595
+ ]),
596
+ createElementVNode(
453
597
  "div",
454
- {
455
- key: 0,
456
- class: "mt-1 whitespace-nowrap"
457
- },
458
- toDisplayString(citem.subLabel),
598
+ { class: "mt-1" },
599
+ toDisplayString(unref(t)("table.more")),
459
600
  1
460
601
  /* TEXT */
461
- )) : (openBlock(), createElementBlock("div", {
462
- key: 1,
463
- class: "mt-1 whitespace-nowrap"
464
- }, "\xA0"))
465
- ], 10, ["onClick"])
602
+ )
603
+ ])
466
604
  ]),
467
- _: 2
468
- /* DYNAMIC */
469
- }, 1032, ["content"]);
470
- }),
471
- 128
472
- /* KEYED_FRAGMENT */
473
- )),
474
- unref(operatorFilterHandler)(
475
- column,
476
- { column, row, $index, cellIndex },
477
- "more"
478
- )?.length ? (openBlock(), createBlock(unref(ElDropdown), {
479
- key: 0,
480
- ref_for: true,
481
- ref: "operatorDropdownRef",
482
- trigger: "click",
483
- "popper-style": "min-width: 150px",
484
- placement: "bottom",
485
- onCommand: ($event) => unref(operatorClickHandler)(
486
- $event,
605
+ _: 1
606
+ /* STABLE */
607
+ }, 8, ["content"])
608
+ ])
609
+ ]),
610
+ _: 2
611
+ /* DYNAMIC */
612
+ }, 1032, ["onCommand"])) : createCommentVNode("v-if", true)
613
+ ], 40, ["onClick", "onContextmenu"])) : column.type === "default" ? (openBlock(), createElementBlock(
614
+ Fragment,
615
+ { key: 5 },
616
+ [
617
+ !unref(isEmpty)(
618
+ unref(renderContentHandler)(column, {
487
619
  column,
488
- { column, row, $index, cellIndex },
489
- "more"
490
- )
491
- }, {
492
- dropdown: withCtx(() => [
493
- createVNode(
494
- unref(ElDropdownMenu),
495
- null,
496
- {
497
- default: withCtx(() => [
498
- (openBlock(true), createElementBlock(
499
- Fragment,
500
- null,
501
- renderList(unref(operatorFilterHandler)(
502
- column,
503
- { column, row, $index, cellIndex },
504
- "more"
505
- ), (citem, cindex) => {
506
- return openBlock(), createBlock(unref(ElDropdownItem), {
507
- key: cindex,
508
- command: cindex,
509
- disabled: unref(operatorDisabledHandler)(citem, {
510
- column,
511
- row,
512
- $index,
513
- cellIndex
514
- })
515
- }, {
516
- default: withCtx(() => [
517
- createElementVNode("span", null, [
518
- createElementVNode(
519
- "span",
520
- null,
521
- toDisplayString(citem.label),
522
- 1
523
- /* TEXT */
524
- ),
525
- unref(operatorDisabledHandler)(citem, {
526
- column,
527
- row,
528
- $index,
529
- cellIndex
530
- }) ? (openBlock(), createElementBlock(
531
- "span",
532
- {
533
- key: 0,
534
- class: "text-xs leading-1"
535
- },
536
- "\uFF08" + toDisplayString(unref(operatorDisableTextdHandler)(citem, {
537
- column,
538
- row,
539
- $index,
540
- cellIndex
541
- })) + "\uFF09",
542
- 1
543
- /* TEXT */
544
- )) : createCommentVNode("v-if", true)
545
- ])
546
- ]),
547
- _: 2
548
- /* DYNAMIC */
549
- }, 1032, ["command", "disabled"]);
550
- }),
551
- 128
552
- /* KEYED_FRAGMENT */
553
- ))
554
- ]),
555
- _: 2
556
- /* DYNAMIC */
557
- },
558
- 1024
559
- /* DYNAMIC_SLOTS */
560
- )
561
- ]),
562
- default: withCtx(() => [
563
- createElementVNode("span", null, [
564
- createVNode(unref(HyTooltip), {
565
- "is-always": "",
566
- overLine: 1,
567
- content: unref(t)("table.moreOperations")
568
- }, {
569
- default: withCtx(() => [
570
- createElementVNode("div", { class: "w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-main text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer" }, [
571
- createElementVNode("div", { class: "w-4 h-4" }, [
572
- createVNode(unref(ElIcon), {
573
- size: "16",
574
- color: "rgba(var(--hy-main))"
575
- }, {
576
- default: withCtx(() => [
577
- createVNode(unref(MoreFilled))
578
- ]),
579
- _: 1
580
- /* STABLE */
581
- })
582
- ]),
583
- createElementVNode(
584
- "div",
585
- { class: "mt-1" },
586
- toDisplayString(unref(t)("table.more")),
587
- 1
588
- /* TEXT */
589
- )
590
- ])
591
- ]),
592
- _: 1
593
- /* STABLE */
594
- }, 8, ["content"])
595
- ])
596
- ]),
597
- _: 2
598
- /* DYNAMIC */
599
- }, 1032, ["onCommand"])) : createCommentVNode("v-if", true)
600
- ], 40, ["onClick", "onContextmenu"])) : column.type === "default" ? (openBlock(), createElementBlock(
601
- Fragment,
602
- { key: 5 },
603
- [
604
- !unref(isEmpty)(
605
- unref(renderContentHandler)(column, {
606
- column,
607
- row,
608
- $index,
609
- cellIndex
610
- })
611
- ) ? (openBlock(), createBlock(unref(HyTooltip), {
612
- key: 0,
613
- "is-always": false,
614
- "over-line": 2,
615
- content: unref(renderContentHandler)(column, { column, row, $index, cellIndex })
616
- }, null, 8, ["content"])) : (openBlock(), createElementBlock("span", {
617
- key: 1,
618
- class: "text-auxiliary"
619
- }, "- -"))
620
- ],
621
- 64
622
- /* STABLE_FRAGMENT */
623
- )) : createCommentVNode("v-if", true)
624
- ],
625
- 4
626
- /* STYLE */
627
- );
628
- }),
629
- 128
630
- /* KEYED_FRAGMENT */
631
- ))
632
- ], 10, ["rowkey"])
620
+ row,
621
+ $index,
622
+ cellIndex
623
+ })
624
+ ) ? (openBlock(), createBlock(unref(HyTooltip), {
625
+ key: 0,
626
+ "is-always": false,
627
+ "over-line": 2,
628
+ content: unref(renderContentHandler)(column, { column, row, $index, cellIndex })
629
+ }, null, 8, ["content"])) : (openBlock(), createElementBlock("span", {
630
+ key: 1,
631
+ class: "text-auxiliary"
632
+ }, "- -"))
633
+ ],
634
+ 64
635
+ /* STABLE_FRAGMENT */
636
+ )) : createCommentVNode("v-if", true)
637
+ ],
638
+ 4
639
+ /* STYLE */
640
+ );
641
+ }),
642
+ 128
643
+ /* KEYED_FRAGMENT */
644
+ ))
633
645
  ],
634
- 2112
635
- /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
636
- ))
646
+ 64
647
+ /* STABLE_FRAGMENT */
648
+ ))
637
649
  ]),
638
650
  empty: withCtx(() => [
639
651
  renderSlot(_ctx.$slots, "empty")