@vtable-guild/vtable-guild 2.8.0 → 2.9.0-alpha.0
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.
- package/css/presets/antdv.css +20 -0
- package/css/presets/element-plus.css +20 -0
- package/css/style.css +341 -0
- package/css/tailwind3-utilities.css +301 -0
- package/css/tailwind3.css +40 -0
- package/css/tailwind4.css +40 -0
- package/dist/core/src/components/Tooltip.d.ts +1 -1
- package/dist/core/src/components/Tooltip.d.ts.map +1 -1
- package/dist/core/src/components/Tooltip.mjs +49 -46
- package/dist/core/src/components/Tooltip.test.d.ts +2 -0
- package/dist/core/src/components/Tooltip.test.d.ts.map +1 -0
- package/dist/core/src/components/VirtualList/VirtualList.d.ts +3 -3
- package/dist/core/src/components/VirtualList/VirtualList.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/VirtualList.mjs +183 -177
- package/dist/core/src/components/VirtualList/hooks/useChildren.d.ts +2 -2
- package/dist/core/src/components/VirtualList/hooks/useChildren.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/hooks/useChildren.mjs +12 -12
- package/dist/core/src/components/VirtualList/hooks/useGetSize.d.ts +1 -1
- package/dist/core/src/components/VirtualList/hooks/useGetSize.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/hooks/useGetSize.mjs +1 -1
- package/dist/core/src/components/VirtualList/hooks/useHeights.d.ts +2 -2
- package/dist/core/src/components/VirtualList/hooks/useHeights.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/hooks/useHeights.mjs +36 -36
- package/dist/core/src/components/VirtualList/hooks/useMobileTouchMove.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/hooks/useMobileTouchMove.mjs +11 -11
- package/dist/core/src/components/VirtualList/hooks/useMobileTouchMove.test.d.ts +2 -0
- package/dist/core/src/components/VirtualList/hooks/useMobileTouchMove.test.d.ts.map +1 -0
- package/dist/core/src/components/VirtualList/hooks/useScrollTo.d.ts +1 -1
- package/dist/core/src/components/VirtualList/hooks/useScrollTo.d.ts.map +1 -1
- package/dist/core/src/components/VirtualList/hooks/useScrollTo.mjs +30 -30
- package/dist/core/src/index.d.ts +1 -1
- package/dist/core/src/index.d.ts.map +1 -1
- package/dist/core/src/utils/types.d.ts +39 -1
- package/dist/core/src/utils/types.d.ts.map +1 -1
- package/dist/css/presets/antdv.css +20 -0
- package/dist/css/presets/element-plus.css +20 -0
- package/dist/css/style.css +341 -0
- package/dist/css/tailwind3-utilities.css +301 -0
- package/dist/css/tailwind3.css +40 -0
- package/dist/css/tailwind4.css +40 -0
- package/dist/icons/src/ColumnHeightOutlinedIcon.d.ts +3 -0
- package/dist/icons/src/ColumnHeightOutlinedIcon.d.ts.map +1 -0
- package/dist/icons/src/ColumnHeightOutlinedIcon.mjs +9 -0
- package/dist/icons/src/FullscreenExitOutlinedIcon.d.ts +3 -0
- package/dist/icons/src/FullscreenExitOutlinedIcon.d.ts.map +1 -0
- package/dist/icons/src/FullscreenExitOutlinedIcon.mjs +9 -0
- package/dist/icons/src/FullscreenOutlinedIcon.d.ts +3 -0
- package/dist/icons/src/FullscreenOutlinedIcon.d.ts.map +1 -0
- package/dist/icons/src/FullscreenOutlinedIcon.mjs +9 -0
- package/dist/icons/src/ReloadOutlinedIcon.d.ts +3 -0
- package/dist/icons/src/ReloadOutlinedIcon.d.ts.map +1 -0
- package/dist/icons/src/ReloadOutlinedIcon.mjs +9 -0
- package/dist/icons/src/SettingOutlinedIcon.d.ts +3 -0
- package/dist/icons/src/SettingOutlinedIcon.d.ts.map +1 -0
- package/dist/icons/src/SettingOutlinedIcon.mjs +9 -0
- package/dist/icons/src/index.d.ts +5 -0
- package/dist/icons/src/index.d.ts.map +1 -1
- package/dist/index.d.ts +0 -28
- package/dist/index.full.mjs +6070 -4427
- package/dist/index.mjs +115 -87
- package/dist/table/src/components/FilterDropdown.d.ts +1 -1
- package/dist/table/src/components/Table.d.ts +31 -4
- package/dist/table/src/components/Table.d.ts.map +1 -1
- package/dist/table/src/components/Table.mjs +514 -475
- package/dist/table/src/components/TableBody.d.ts.map +1 -1
- package/dist/table/src/components/TableBody.mjs +37 -36
- package/dist/table/src/components/TableCell.d.ts.map +1 -1
- package/dist/table/src/components/TableCell.mjs +95 -83
- package/dist/table/src/components/TableColumnSettings.d.ts +41 -0
- package/dist/table/src/components/TableColumnSettings.d.ts.map +1 -0
- package/dist/table/src/components/TableColumnSettings.mjs +360 -0
- package/dist/table/src/components/TableColumnSettings.test.d.ts +2 -0
- package/dist/table/src/components/TableColumnSettings.test.d.ts.map +1 -0
- package/dist/table/src/components/TableCopyButton.d.ts +41 -0
- package/dist/table/src/components/TableCopyButton.d.ts.map +1 -0
- package/dist/table/src/components/TableCopyButton.mjs +94 -0
- package/dist/table/src/components/TableEnterprise.test.d.ts +2 -0
- package/dist/table/src/components/TableEnterprise.test.d.ts.map +1 -0
- package/dist/table/src/components/TableHeaderCell.d.ts.map +1 -1
- package/dist/table/src/components/TableHeaderCell.mjs +284 -241
- package/dist/table/src/components/TableSelectionAlert.d.ts +50 -0
- package/dist/table/src/components/TableSelectionAlert.d.ts.map +1 -0
- package/dist/table/src/components/TableSelectionAlert.mjs +86 -0
- package/dist/table/src/components/TableSelectionAlert.test.d.ts +2 -0
- package/dist/table/src/components/TableSelectionAlert.test.d.ts.map +1 -0
- package/dist/table/src/components/TableToolbar.d.ts +87 -0
- package/dist/table/src/components/TableToolbar.d.ts.map +1 -0
- package/dist/table/src/components/TableToolbar.mjs +265 -0
- package/dist/table/src/components/TableToolbar.test.d.ts +2 -0
- package/dist/table/src/components/TableToolbar.test.d.ts.map +1 -0
- package/dist/table/src/components/VTable.vue.d.ts.map +1 -1
- package/dist/table/src/components/VTable.vue.mjs +24 -15
- package/dist/table/src/components/VTableColumnSettings.vue.d.ts +20 -0
- package/dist/table/src/components/VTableColumnSettings.vue.d.ts.map +1 -0
- package/dist/table/src/components/VTableColumnSettings.vue.mjs +42 -0
- package/dist/table/src/components/VTableColumnSettings.vue2.mjs +4 -0
- package/dist/table/src/components/VTableSelectionAlert.vue.d.ts +19 -0
- package/dist/table/src/components/VTableSelectionAlert.vue.d.ts.map +1 -0
- package/dist/table/src/components/VTableSelectionAlert.vue.mjs +54 -0
- package/dist/table/src/components/VTableSelectionAlert.vue2.mjs +4 -0
- package/dist/table/src/components/VTableSummary.d.ts +15 -75
- package/dist/table/src/components/VTableSummary.d.ts.map +1 -1
- package/dist/table/src/components/VTableSummary.mjs +7 -7
- package/dist/table/src/components/VTableToolbar.vue.d.ts +27 -0
- package/dist/table/src/components/VTableToolbar.vue.d.ts.map +1 -0
- package/dist/table/src/components/VTableToolbar.vue.mjs +108 -0
- package/dist/table/src/components/VTableToolbar.vue2.mjs +4 -0
- package/dist/table/src/components/VirtualTableBody.d.ts.map +1 -1
- package/dist/table/src/components/VirtualTableBody.mjs +2 -3
- package/dist/table/src/composables/useColumnState.d.ts +32 -0
- package/dist/table/src/composables/useColumnState.d.ts.map +1 -0
- package/dist/table/src/composables/useColumnState.mjs +107 -0
- package/dist/table/src/composables/useColumnState.test.d.ts +2 -0
- package/dist/table/src/composables/useColumnState.test.d.ts.map +1 -0
- package/dist/table/src/composables/useExpand.d.ts.map +1 -1
- package/dist/table/src/composables/useExpand.mjs +28 -30
- package/dist/table/src/composables/useFilter.d.ts.map +1 -1
- package/dist/table/src/composables/useFilter.mjs +28 -25
- package/dist/table/src/composables/usePagination.d.ts +1 -0
- package/dist/table/src/composables/usePagination.d.ts.map +1 -1
- package/dist/table/src/composables/usePagination.mjs +35 -34
- package/dist/table/src/composables/useSelection.d.ts.map +1 -1
- package/dist/table/src/composables/useSelection.mjs +136 -126
- package/dist/table/src/composables/useTableRequest.d.ts +4 -0
- package/dist/table/src/composables/useTableRequest.d.ts.map +1 -0
- package/dist/table/src/composables/useTableRequest.mjs +127 -0
- package/dist/table/src/composables/useTableRequest.test.d.ts +2 -0
- package/dist/table/src/composables/useTableRequest.test.d.ts.map +1 -0
- package/dist/table/src/context.d.ts +9 -2
- package/dist/table/src/context.d.ts.map +1 -1
- package/dist/table/src/index.d.ts +25 -88
- package/dist/table/src/index.d.ts.map +1 -1
- package/dist/table/src/index.mjs +12 -12
- package/dist/table/src/types/column-settings.d.ts +31 -0
- package/dist/table/src/types/column-settings.d.ts.map +1 -0
- package/dist/table/src/types/column-state.typecheck.d.ts +2 -0
- package/dist/table/src/types/column-state.typecheck.d.ts.map +1 -0
- package/dist/table/src/types/column.d.ts +15 -3
- package/dist/table/src/types/column.d.ts.map +1 -1
- package/dist/table/src/types/index.d.ts +2 -0
- package/dist/table/src/types/index.d.ts.map +1 -1
- package/dist/table/src/types/presentation.d.ts +24 -0
- package/dist/table/src/types/presentation.d.ts.map +1 -0
- package/dist/table/src/types/request.d.ts +65 -0
- package/dist/table/src/types/request.d.ts.map +1 -0
- package/dist/table/src/types/request.typecheck.d.ts +13 -0
- package/dist/table/src/types/request.typecheck.d.ts.map +1 -0
- package/dist/table/src/types/selection-alert.d.ts +30 -0
- package/dist/table/src/types/selection-alert.d.ts.map +1 -0
- package/dist/table/src/types/selection-alert.typecheck.d.ts +12 -0
- package/dist/table/src/types/selection-alert.typecheck.d.ts.map +1 -0
- package/dist/table/src/types/table.d.ts +12 -1
- package/dist/table/src/types/table.d.ts.map +1 -1
- package/dist/table/src/types/toolbar.d.ts +58 -0
- package/dist/table/src/types/toolbar.d.ts.map +1 -0
- package/dist/table/src/utils/cell.d.ts +4 -0
- package/dist/table/src/utils/cell.d.ts.map +1 -1
- package/dist/table/src/utils/cell.mjs +49 -45
- package/dist/table/src/utils/columnSettings.d.ts +22 -0
- package/dist/table/src/utils/columnSettings.d.ts.map +1 -0
- package/dist/table/src/utils/columnSettings.mjs +107 -0
- package/dist/table/src/utils/columnSettings.test.d.ts +2 -0
- package/dist/table/src/utils/columnSettings.test.d.ts.map +1 -0
- package/dist/table/src/utils/manual.d.ts +3 -0
- package/dist/table/src/utils/manual.d.ts.map +1 -0
- package/dist/table/src/utils/manual.mjs +6 -0
- package/dist/table/src/utils/valueEnum.d.ts +7 -0
- package/dist/table/src/utils/valueEnum.d.ts.map +1 -0
- package/dist/table/src/utils/valueEnum.mjs +23 -0
- package/dist/theme/src/augment.d.ts +4 -0
- package/dist/theme/src/augment.d.ts.map +1 -1
- package/dist/theme/src/column-settings.d.ts +160 -0
- package/dist/theme/src/column-settings.d.ts.map +1 -0
- package/dist/theme/src/column-settings.mjs +84 -0
- package/dist/theme/src/index.d.ts +12 -0
- package/dist/theme/src/index.d.ts.map +1 -1
- package/dist/theme/src/presets/antdv/table-locale.d.ts +10 -0
- package/dist/theme/src/presets/antdv/table-locale.d.ts.map +1 -1
- package/dist/theme/src/presets/antdv/table-locale.mjs +2 -0
- package/dist/theme/src/presets/antdv/table.d.ts +4 -0
- package/dist/theme/src/presets/antdv/table.d.ts.map +1 -1
- package/dist/theme/src/presets/antdv/table.mjs +4 -0
- package/dist/theme/src/presets/element-plus/table-locale.d.ts +10 -0
- package/dist/theme/src/presets/element-plus/table-locale.d.ts.map +1 -1
- package/dist/theme/src/presets/element-plus/table-locale.mjs +2 -0
- package/dist/theme/src/presets/element-plus/table.d.ts +4 -0
- package/dist/theme/src/presets/element-plus/table.d.ts.map +1 -1
- package/dist/theme/src/presets/element-plus/table.mjs +4 -0
- package/dist/theme/src/presets/index.d.ts.map +1 -1
- package/dist/theme/src/presets/index.mjs +100 -67
- package/dist/theme/src/presets/types.d.ts +3 -0
- package/dist/theme/src/presets/types.d.ts.map +1 -1
- package/dist/theme/src/selection-alert.d.ts +54 -0
- package/dist/theme/src/selection-alert.d.ts.map +1 -0
- package/dist/theme/src/selection-alert.mjs +36 -0
- package/dist/theme/src/toolbar.d.ts +105 -0
- package/dist/theme/src/toolbar.d.ts.map +1 -0
- package/dist/theme/src/toolbar.mjs +57 -0
- package/dist/vtable-guild/src/augment.d.ts +18 -0
- package/dist/vtable-guild/src/augment.d.ts.map +1 -0
- package/dist/vtable-guild/src/index.d.ts +1 -0
- package/dist/vtable-guild/src/index.d.ts.map +1 -1
- package/package.json +4 -3
|
@@ -1,91 +1,99 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as ll, ref as C, watch as H, onBeforeUnmount as Ke, computed as o, inject as al, provide as Me, onMounted as ol, createVNode as r, Fragment as nl, isVNode as rl, nextTick as il } from "vue";
|
|
2
|
+
import { isManual as ce } from "../utils/manual.mjs";
|
|
2
3
|
import "../../../core/src/utils/tv.mjs";
|
|
3
|
-
import { prefixThemeConfig as
|
|
4
|
-
import { devWarn as
|
|
5
|
-
import { mergeThemeConfigs as
|
|
6
|
-
import { mergeDeep as
|
|
7
|
-
import
|
|
8
|
-
import { VTABLE_GUILD_INJECTION_KEY as
|
|
9
|
-
import { paginationZhCN as
|
|
10
|
-
import { resolveTooltipThemePreset as
|
|
11
|
-
import { antdvTableCompatClasses as
|
|
12
|
-
import { usePagination as
|
|
13
|
-
import
|
|
14
|
-
import { filterVisibleColumns as
|
|
15
|
-
import { getEllipsisConfig as
|
|
16
|
-
import { getRootCompatClass as
|
|
17
|
-
import { resolveRowKey as
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
|
|
45
|
-
function
|
|
46
|
-
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !ll(l);
|
|
4
|
+
import { prefixThemeConfig as dl, prefixVtgClassNames as G } from "../../../core/src/utils/classPrefix.mjs";
|
|
5
|
+
import { devWarn as ul } from "../../../core/src/utils/devWarn.mjs";
|
|
6
|
+
import { mergeThemeConfigs as N, useTheme as sl } from "../../../core/src/composables/useTheme.mjs";
|
|
7
|
+
import { mergeDeep as X } from "../../../core/src/utils/mergeDeep.mjs";
|
|
8
|
+
import je from "../../../core/src/components/Scrollbar.mjs";
|
|
9
|
+
import { VTABLE_GUILD_INJECTION_KEY as Ve } from "../../../core/src/plugin/index.mjs";
|
|
10
|
+
import { paginationZhCN as cl } from "../../../theme/src/pagination.mjs";
|
|
11
|
+
import { resolveTooltipThemePreset as fl, resolveScrollbarThemePreset as ml, resolveRadioThemePreset as pl, resolveInputThemePreset as vl, resolveCheckboxThemePreset as gl, resolveButtonThemePreset as yl, resolveTableThemePreset as hl, resolveTableLocalePreset as wl, resolveBuiltInTableLocale as Cl, resolveBuiltInLocale as xl } from "../../../theme/src/presets/index.mjs";
|
|
12
|
+
import { antdvTableCompatClasses as bl } from "../../../theme/src/compat/antdv-table.mjs";
|
|
13
|
+
import { usePagination as Sl } from "../composables/usePagination.mjs";
|
|
14
|
+
import Dl from "./TablePagination.mjs";
|
|
15
|
+
import { filterVisibleColumns as Rl, applyColumnOrder as El } from "../composables/useColumnDisplay.mjs";
|
|
16
|
+
import { getEllipsisConfig as Il } from "../utils/cell.mjs";
|
|
17
|
+
import { getRootCompatClass as Tl } from "../utils/compat.mjs";
|
|
18
|
+
import { resolveRowKey as Hl } from "../utils/rowKey.mjs";
|
|
19
|
+
import { useScroll as Ll } from "../composables/useScroll.mjs";
|
|
20
|
+
import { useAutoHeight as Bl } from "../composables/useAutoHeight.mjs";
|
|
21
|
+
import { useColumnMetrics as Nl } from "../composables/useColumnMetrics.mjs";
|
|
22
|
+
import { useColumnLayout as Fl } from "../composables/useColumnLayout.mjs";
|
|
23
|
+
import { resolveFixedColumnRanges as Ol } from "../composables/useColumnWindow.mjs";
|
|
24
|
+
import { useExpand as _l } from "../composables/useExpand.mjs";
|
|
25
|
+
import { useResize as Al } from "../composables/useResize.mjs";
|
|
26
|
+
import { useVirtual as Pl, INVALID_SCROLL_Y_FALLBACK as kl } from "../composables/useVirtual.mjs";
|
|
27
|
+
import { useTreeData as Wl } from "../composables/useTreeData.mjs";
|
|
28
|
+
import { useHoverState as zl } from "../composables/useHoverState.mjs";
|
|
29
|
+
import { useRowDragSort as Kl } from "../composables/useRowDragSort.mjs";
|
|
30
|
+
import { TABLE_CONTEXT_KEY as Ml } from "../context.mjs";
|
|
31
|
+
import { EXPAND_COLUMN as jl, SELECTION_COLUMN as Vl } from "../constants.mjs";
|
|
32
|
+
import { resolveTablePresetConfig as Yl } from "../preset-config.mjs";
|
|
33
|
+
import Ye from "./TableHeader.mjs";
|
|
34
|
+
import $e from "./TableBody.mjs";
|
|
35
|
+
import $l from "./VirtualTableBody.mjs";
|
|
36
|
+
import Ue from "./TableLoading.mjs";
|
|
37
|
+
import q from "./ColGroup.mjs";
|
|
38
|
+
import J from "./ColumnWidthRow.mjs";
|
|
39
|
+
import { antdvTableTheme as Ul } from "../../../theme/src/presets/antdv/table.mjs";
|
|
40
|
+
import { useColumns as Ge } from "../composables/useColumns.mjs";
|
|
41
|
+
import { useSorter as Gl } from "../composables/useSorter.mjs";
|
|
42
|
+
import { useFilter as Xl } from "../composables/useFilter.mjs";
|
|
43
|
+
import { useSelection as ql } from "../composables/useSelection.mjs";
|
|
44
|
+
import { cn as S } from "tailwind-variants";
|
|
45
|
+
function Xe(l) {
|
|
46
|
+
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !rl(l);
|
|
47
47
|
}
|
|
48
|
-
const
|
|
49
|
-
function
|
|
48
|
+
const Jl = [["xxxl", 2e3], ["xxl", 1600], ["xl", 1200], ["lg", 992], ["md", 768], ["sm", 576], ["xs", 0]];
|
|
49
|
+
function qe() {
|
|
50
50
|
if (typeof window > "u")
|
|
51
51
|
return /* @__PURE__ */ new Set(["md", "sm", "xs"]);
|
|
52
|
-
const l = window.innerWidth,
|
|
53
|
-
return
|
|
52
|
+
const l = window.innerWidth, i = /* @__PURE__ */ new Set();
|
|
53
|
+
return Jl.forEach(([s, u]) => {
|
|
54
54
|
if (s === "xs") {
|
|
55
|
-
l < 576 &&
|
|
55
|
+
l < 576 && i.add("xs");
|
|
56
56
|
return;
|
|
57
57
|
}
|
|
58
|
-
l >=
|
|
59
|
-
}),
|
|
58
|
+
l >= u && i.add(s);
|
|
59
|
+
}), i;
|
|
60
60
|
}
|
|
61
|
-
function
|
|
62
|
-
return l.reduce((s,
|
|
63
|
-
if (typeof
|
|
64
|
-
return s.push(
|
|
65
|
-
if (
|
|
61
|
+
function Je(l, i) {
|
|
62
|
+
return l.reduce((s, u) => {
|
|
63
|
+
if (typeof u == "symbol")
|
|
64
|
+
return s.push(u), s;
|
|
65
|
+
if (u.responsive?.length && !u.responsive.some((R) => i.has(R)))
|
|
66
66
|
return s;
|
|
67
|
-
const
|
|
68
|
-
if ("children" in
|
|
69
|
-
const
|
|
70
|
-
return
|
|
71
|
-
...
|
|
72
|
-
fixed:
|
|
73
|
-
children:
|
|
67
|
+
const D = u.fixed === !0 ? "left" : u.fixed;
|
|
68
|
+
if ("children" in u && Array.isArray(u.children)) {
|
|
69
|
+
const R = Je(u.children, i);
|
|
70
|
+
return R.length === 0 || s.push({
|
|
71
|
+
...u,
|
|
72
|
+
fixed: D,
|
|
73
|
+
children: R
|
|
74
74
|
}), s;
|
|
75
75
|
}
|
|
76
|
-
return s.push(
|
|
77
|
-
...
|
|
78
|
-
fixed:
|
|
76
|
+
return s.push(D === u.fixed ? u : {
|
|
77
|
+
...u,
|
|
78
|
+
fixed: D
|
|
79
79
|
}), s;
|
|
80
80
|
}, []);
|
|
81
81
|
}
|
|
82
|
-
const
|
|
82
|
+
const ja = /* @__PURE__ */ ll({
|
|
83
83
|
name: "VTable",
|
|
84
84
|
props: {
|
|
85
85
|
pagination: {
|
|
86
86
|
type: [Boolean, Object],
|
|
87
87
|
default: !1
|
|
88
88
|
},
|
|
89
|
+
manual: {
|
|
90
|
+
type: [Boolean, Object],
|
|
91
|
+
default: !1
|
|
92
|
+
},
|
|
93
|
+
columnEmptyText: {
|
|
94
|
+
type: null,
|
|
95
|
+
default: !1
|
|
96
|
+
},
|
|
89
97
|
dataSource: {
|
|
90
98
|
type: Array,
|
|
91
99
|
default: () => []
|
|
@@ -159,7 +167,7 @@ const _o = /* @__PURE__ */ Jt({
|
|
|
159
167
|
default: void 0
|
|
160
168
|
},
|
|
161
169
|
showSorterTooltip: {
|
|
162
|
-
type: Boolean,
|
|
170
|
+
type: [Boolean, Object],
|
|
163
171
|
default: void 0
|
|
164
172
|
},
|
|
165
173
|
sortDirections: {
|
|
@@ -274,338 +282,355 @@ const _o = /* @__PURE__ */ Jt({
|
|
|
274
282
|
}
|
|
275
283
|
},
|
|
276
284
|
emits: {
|
|
277
|
-
change: (l,
|
|
278
|
-
resizeColumn: (l,
|
|
279
|
-
rowDragEnd: (l,
|
|
285
|
+
change: (l, i, s) => !0,
|
|
286
|
+
resizeColumn: (l, i) => !0,
|
|
287
|
+
rowDragEnd: (l, i) => !0
|
|
280
288
|
},
|
|
281
289
|
slots: Object,
|
|
282
290
|
setup(l, {
|
|
283
|
-
slots:
|
|
291
|
+
slots: i,
|
|
284
292
|
emit: s
|
|
285
293
|
}) {
|
|
286
|
-
const
|
|
287
|
-
|
|
294
|
+
const u = C(!1);
|
|
295
|
+
let D;
|
|
296
|
+
H(() => {
|
|
297
|
+
const t = l.loading;
|
|
298
|
+
return [t === !0 || typeof t == "object" && t !== null && t.spinning !== !1, typeof t == "object" && t !== null ? t.delay : 0];
|
|
299
|
+
}, ([t, a]) => {
|
|
300
|
+
clearTimeout(D), t ? !a || !Number.isFinite(a) || a < 0 ? u.value = !0 : u.value || (D = setTimeout(() => {
|
|
301
|
+
u.value = !0;
|
|
302
|
+
}, a)) : u.value = !1;
|
|
303
|
+
}, {
|
|
304
|
+
immediate: !0
|
|
305
|
+
}), Ke(() => clearTimeout(D));
|
|
306
|
+
const R = o(() => typeof l.loading == "object" ? l.loading?.wrapperClassName : void 0), m = al(Ve, null), x = o(() => m?.themePreset ?? "antdv"), E = o(() => m?.cssMode ?? "prebuilt"), I = o(() => m?.classPrefix ?? "vtg"), Ze = o(() => {
|
|
307
|
+
const t = m?.theme ?? {}, a = x.value, n = (d) => dl(d, E.value, I.value);
|
|
288
308
|
return {
|
|
289
309
|
...t,
|
|
290
|
-
button:
|
|
291
|
-
checkbox:
|
|
292
|
-
input:
|
|
293
|
-
radio:
|
|
294
|
-
scrollbar:
|
|
295
|
-
tooltip:
|
|
310
|
+
button: N(n(yl(a)), t.button),
|
|
311
|
+
checkbox: N(n(gl(a)), t.checkbox),
|
|
312
|
+
input: N(n(vl(a)), t.input),
|
|
313
|
+
radio: N(n(pl(a)), t.radio),
|
|
314
|
+
scrollbar: N(n(ml(a)), t.scrollbar),
|
|
315
|
+
tooltip: N(n(fl(a)), t.tooltip)
|
|
296
316
|
};
|
|
297
317
|
});
|
|
298
|
-
|
|
318
|
+
Me(Ve, {
|
|
299
319
|
get themePreset() {
|
|
300
|
-
return
|
|
320
|
+
return x.value;
|
|
301
321
|
},
|
|
302
322
|
get cssMode() {
|
|
303
|
-
return
|
|
323
|
+
return E.value;
|
|
304
324
|
},
|
|
305
325
|
get classPrefix() {
|
|
306
|
-
return
|
|
326
|
+
return I.value;
|
|
307
327
|
},
|
|
308
328
|
get theme() {
|
|
309
|
-
return
|
|
329
|
+
return Ze.value;
|
|
310
330
|
},
|
|
311
331
|
get locale() {
|
|
312
|
-
return
|
|
332
|
+
return m?.locale ?? "zh-CN";
|
|
313
333
|
},
|
|
314
334
|
get locales() {
|
|
315
|
-
return
|
|
335
|
+
return m?.locales ?? {};
|
|
316
336
|
},
|
|
317
337
|
get localeOverrides() {
|
|
318
|
-
return
|
|
338
|
+
return m?.localeOverrides ?? {};
|
|
319
339
|
},
|
|
320
340
|
get compatClass() {
|
|
321
|
-
return
|
|
341
|
+
return m?.compatClass;
|
|
322
342
|
}
|
|
323
343
|
});
|
|
324
|
-
const
|
|
344
|
+
const Qe = o(() => hl(x.value) ?? Ul), {
|
|
325
345
|
slots: e
|
|
326
|
-
} =
|
|
327
|
-
compatClasses:
|
|
328
|
-
}),
|
|
329
|
-
...
|
|
346
|
+
} = sl("table", Qe, l, {
|
|
347
|
+
compatClasses: bl
|
|
348
|
+
}), F = m?.compatClass === !0 ? (t) => `ant-table-${t}` : void 0, O = o(() => l.locale ?? m?.locale ?? "zh-CN"), fe = o(() => ({
|
|
349
|
+
...m?.locales ?? {},
|
|
330
350
|
...l.locales ?? {}
|
|
331
|
-
})),
|
|
332
|
-
const t =
|
|
333
|
-
return
|
|
334
|
-
}),
|
|
335
|
-
function
|
|
336
|
-
|
|
351
|
+
})), et = o(() => {
|
|
352
|
+
const t = wl(x.value), a = Cl(x.value, O.value), n = fe.value[O.value]?.table, d = X(X(t, a), n);
|
|
353
|
+
return X(d, X(m?.localeOverrides?.table ?? {}, l.localeOverrides));
|
|
354
|
+
}), Z = C(qe());
|
|
355
|
+
function Q() {
|
|
356
|
+
Z.value = qe();
|
|
337
357
|
}
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
}),
|
|
341
|
-
window.removeEventListener("resize",
|
|
358
|
+
ol(() => {
|
|
359
|
+
Q(), window.addEventListener("resize", Q);
|
|
360
|
+
}), Ke(() => {
|
|
361
|
+
window.removeEventListener("resize", Q);
|
|
342
362
|
});
|
|
343
|
-
const
|
|
363
|
+
const me = o(() => Je(l.columns, Z.value)), L = o(() => l.sticky === !0 ? {} : typeof l.sticky == "object" ? l.sticky : void 0), {
|
|
344
364
|
leafColumns: W
|
|
345
|
-
} =
|
|
346
|
-
getSortOrder:
|
|
347
|
-
toggleSortOrder:
|
|
348
|
-
sortData:
|
|
349
|
-
sorterState:
|
|
350
|
-
sorterResult:
|
|
351
|
-
sortColumns:
|
|
352
|
-
} =
|
|
365
|
+
} = Ge(() => me.value), {
|
|
366
|
+
getSortOrder: ee,
|
|
367
|
+
toggleSortOrder: tt,
|
|
368
|
+
sortData: lt,
|
|
369
|
+
sorterState: at,
|
|
370
|
+
sorterResult: te,
|
|
371
|
+
sortColumns: ot
|
|
372
|
+
} = Gl({
|
|
353
373
|
columns: () => W.value,
|
|
354
374
|
tableSortDirections: () => l.sortDirections,
|
|
355
375
|
onSorterChange(t) {
|
|
356
|
-
const
|
|
357
|
-
s("change",
|
|
376
|
+
const a = le();
|
|
377
|
+
s("change", z(), t, {
|
|
358
378
|
action: "sort",
|
|
359
|
-
currentDataSource:
|
|
360
|
-
...
|
|
361
|
-
}),
|
|
379
|
+
currentDataSource: a,
|
|
380
|
+
...ae()
|
|
381
|
+
}), oe();
|
|
362
382
|
}
|
|
363
383
|
}), {
|
|
364
|
-
getFilteredValue:
|
|
365
|
-
confirmFilter:
|
|
366
|
-
resetFilter:
|
|
367
|
-
getAllFilters:
|
|
368
|
-
filterData:
|
|
369
|
-
} =
|
|
384
|
+
getFilteredValue: nt,
|
|
385
|
+
confirmFilter: rt,
|
|
386
|
+
resetFilter: it,
|
|
387
|
+
getAllFilters: z,
|
|
388
|
+
filterData: dt
|
|
389
|
+
} = Xl({
|
|
370
390
|
columns: () => W.value,
|
|
371
391
|
onFilterChange(t) {
|
|
372
|
-
const
|
|
373
|
-
s("change", t,
|
|
392
|
+
const a = le(), n = c.resetForFilter();
|
|
393
|
+
s("change", t, te.value, {
|
|
374
394
|
action: "filter",
|
|
375
|
-
currentDataSource:
|
|
376
|
-
...
|
|
377
|
-
}),
|
|
395
|
+
currentDataSource: a,
|
|
396
|
+
...ae(n)
|
|
397
|
+
}), oe();
|
|
378
398
|
}
|
|
379
399
|
});
|
|
380
|
-
function
|
|
400
|
+
function le() {
|
|
381
401
|
let t = l.dataSource;
|
|
382
|
-
return t =
|
|
402
|
+
return ce(l.manual, "filter") || (t = dt(t)), ce(l.manual, "sort") || (t = lt(t)), t;
|
|
383
403
|
}
|
|
384
|
-
const
|
|
404
|
+
const _ = o(() => le()), c = Sl({
|
|
405
|
+
manual: () => ce(l.manual, "pagination"),
|
|
385
406
|
pagination: () => l.pagination,
|
|
386
|
-
data: () =>
|
|
407
|
+
data: () => _.value,
|
|
387
408
|
onChange(t) {
|
|
388
|
-
s("change",
|
|
409
|
+
s("change", z(), te.value, {
|
|
389
410
|
action: "paginate",
|
|
390
|
-
currentDataSource:
|
|
411
|
+
currentDataSource: _.value,
|
|
391
412
|
pagination: t
|
|
392
|
-
}),
|
|
413
|
+
}), oe();
|
|
393
414
|
}
|
|
394
415
|
});
|
|
395
|
-
function
|
|
416
|
+
function ae(t) {
|
|
396
417
|
return c.enabled.value ? {
|
|
397
418
|
pagination: t ?? c.state.value
|
|
398
419
|
} : {};
|
|
399
420
|
}
|
|
400
|
-
const
|
|
401
|
-
...
|
|
402
|
-
...
|
|
403
|
-
...
|
|
404
|
-
...
|
|
421
|
+
const ut = o(() => ({
|
|
422
|
+
...cl,
|
|
423
|
+
...xl(x.value, O.value)?.pagination,
|
|
424
|
+
...fe.value[O.value]?.pagination,
|
|
425
|
+
...m?.localeOverrides?.pagination,
|
|
405
426
|
...c.config.value.locale
|
|
406
|
-
})),
|
|
407
|
-
function
|
|
408
|
-
(l.scroll?.scrollToFirstRowOnChange ?? c.enabled.value) &&
|
|
409
|
-
|
|
427
|
+
})), pe = C(null);
|
|
428
|
+
function oe() {
|
|
429
|
+
(l.scroll?.scrollToFirstRowOnChange ?? c.enabled.value) && il(() => {
|
|
430
|
+
T.value ? pe.value?.scrollToTop() : B.value && (B.value.scrollTop = 0);
|
|
410
431
|
});
|
|
411
432
|
}
|
|
412
|
-
function
|
|
433
|
+
function K(t) {
|
|
413
434
|
if (!c.enabled.value || c.state.value.total === 0) return null;
|
|
414
|
-
const
|
|
415
|
-
if (!
|
|
416
|
-
const
|
|
417
|
-
return
|
|
435
|
+
const n = (c.config.value.position ?? ["bottomRight"]).find((h) => h !== "none" && h.startsWith(t));
|
|
436
|
+
if (!n) return null;
|
|
437
|
+
const d = n.slice(t.length).toLowerCase();
|
|
438
|
+
return r(Dl, {
|
|
418
439
|
key: t,
|
|
419
440
|
config: c.config.value,
|
|
420
441
|
state: c.state.value,
|
|
421
|
-
locale:
|
|
422
|
-
align:
|
|
423
|
-
position:
|
|
442
|
+
locale: ut.value,
|
|
443
|
+
align: d,
|
|
444
|
+
position: n,
|
|
424
445
|
tableSize: l.size,
|
|
425
|
-
narrow:
|
|
446
|
+
narrow: Z.value.has("xs"),
|
|
426
447
|
getPopupContainer: l.getPopupContainer,
|
|
427
448
|
onChange: c.change
|
|
428
|
-
},
|
|
429
|
-
paginationItem:
|
|
449
|
+
}, i.paginationItem ? {
|
|
450
|
+
paginationItem: i.paginationItem
|
|
430
451
|
} : void 0);
|
|
431
452
|
}
|
|
432
|
-
function
|
|
433
|
-
const
|
|
434
|
-
return l.rowKey === void 0 || typeof l.rowKey == "string" && l.rowKey in t,
|
|
453
|
+
function A(t, a) {
|
|
454
|
+
const n = Hl(t, a, l.rowKey);
|
|
455
|
+
return l.rowKey === void 0 || typeof l.rowKey == "string" && l.rowKey in t, n;
|
|
435
456
|
}
|
|
436
457
|
const {
|
|
437
|
-
flattenData:
|
|
438
|
-
rowMetaMap:
|
|
439
|
-
isTreeData:
|
|
440
|
-
toggleTreeExpand:
|
|
441
|
-
isTreeExpanded:
|
|
442
|
-
indentSize:
|
|
443
|
-
} =
|
|
444
|
-
data: () =>
|
|
458
|
+
flattenData: ve,
|
|
459
|
+
rowMetaMap: ge,
|
|
460
|
+
isTreeData: ne,
|
|
461
|
+
toggleTreeExpand: st,
|
|
462
|
+
isTreeExpanded: ct,
|
|
463
|
+
indentSize: ft
|
|
464
|
+
} = Wl({
|
|
465
|
+
data: () => _.value,
|
|
445
466
|
pageData: () => c.pageData.value,
|
|
446
467
|
preserveStateOnDataChange: () => c.enabled.value,
|
|
447
468
|
childrenColumnName: () => l.childrenColumnName,
|
|
448
469
|
indentSize: () => l.indentSize,
|
|
449
|
-
getRowKey:
|
|
470
|
+
getRowKey: A,
|
|
450
471
|
defaultExpandedRowKeys: () => l.defaultExpandedRowKeys,
|
|
451
472
|
expandedRowKeys: () => l.expandedRowKeys,
|
|
452
473
|
defaultExpandAllRows: () => l.defaultExpandAllRows,
|
|
453
474
|
onExpand: l.onExpand,
|
|
454
475
|
onExpandedRowsChange: l.onExpandedRowsChange
|
|
455
476
|
}), {
|
|
456
|
-
hoverRange:
|
|
457
|
-
setHoverRange:
|
|
458
|
-
clearHoverRange:
|
|
459
|
-
} =
|
|
477
|
+
hoverRange: mt,
|
|
478
|
+
setHoverRange: pt,
|
|
479
|
+
clearHoverRange: vt
|
|
480
|
+
} = zl(100), M = Kl({
|
|
460
481
|
enabled: () => l.rowDraggable === !0,
|
|
461
|
-
getRowKey:
|
|
482
|
+
getRowKey: A,
|
|
462
483
|
dataSource: () => l.dataSource,
|
|
463
484
|
childrenColumnName: () => l.childrenColumnName,
|
|
464
|
-
onDrop(t,
|
|
465
|
-
s("rowDragEnd", t,
|
|
485
|
+
onDrop(t, a) {
|
|
486
|
+
s("rowDragEnd", t, a);
|
|
466
487
|
}
|
|
467
|
-
}),
|
|
468
|
-
isSelected:
|
|
469
|
-
isDisabled:
|
|
470
|
-
getSelectionState:
|
|
471
|
-
toggleRow:
|
|
472
|
-
toggleAll:
|
|
473
|
-
allCheckedState:
|
|
474
|
-
invertSelection:
|
|
475
|
-
clearSelection:
|
|
476
|
-
getChangeableRowKeys:
|
|
477
|
-
} =
|
|
488
|
+
}), v = o(() => ne.value ? ve.value.map((t) => t.record) : c.pageData.value), {
|
|
489
|
+
isSelected: gt,
|
|
490
|
+
isDisabled: yt,
|
|
491
|
+
getSelectionState: ht,
|
|
492
|
+
toggleRow: wt,
|
|
493
|
+
toggleAll: Ct,
|
|
494
|
+
allCheckedState: xt,
|
|
495
|
+
invertSelection: bt,
|
|
496
|
+
clearSelection: St,
|
|
497
|
+
getChangeableRowKeys: Dt
|
|
498
|
+
} = ql({
|
|
478
499
|
rowSelection: () => l.rowSelection,
|
|
479
|
-
getRowKey:
|
|
480
|
-
data: () =>
|
|
481
|
-
visibleData: () =>
|
|
500
|
+
getRowKey: A,
|
|
501
|
+
data: () => _.value,
|
|
502
|
+
visibleData: () => v.value,
|
|
482
503
|
paginate: () => c.enabled.value,
|
|
483
504
|
childrenColumnName: () => l.childrenColumnName,
|
|
484
505
|
onSelectionChange() {
|
|
485
|
-
s("change",
|
|
506
|
+
s("change", z(), te.value, {
|
|
486
507
|
action: "select",
|
|
487
|
-
currentDataSource:
|
|
488
|
-
...
|
|
508
|
+
currentDataSource: v.value,
|
|
509
|
+
...ae()
|
|
489
510
|
});
|
|
490
511
|
}
|
|
491
512
|
}), {
|
|
492
|
-
isExpanded:
|
|
493
|
-
toggleExpand:
|
|
494
|
-
} =
|
|
513
|
+
isExpanded: Rt,
|
|
514
|
+
toggleExpand: Et
|
|
515
|
+
} = _l({
|
|
495
516
|
expandable: () => l.expandable,
|
|
496
|
-
getRowKey:
|
|
497
|
-
data: () => c.enabled.value ?
|
|
517
|
+
getRowKey: A,
|
|
518
|
+
data: () => c.enabled.value ? _.value : v.value,
|
|
498
519
|
childrenColumnName: () => l.childrenColumnName,
|
|
499
520
|
initializeNewRows: () => c.enabled.value
|
|
500
|
-
}),
|
|
501
|
-
const
|
|
502
|
-
return
|
|
503
|
-
},
|
|
504
|
-
|
|
505
|
-
},
|
|
506
|
-
const t = l.expandable,
|
|
507
|
-
key:
|
|
508
|
-
title: "",
|
|
521
|
+
}), ye = (t) => {
|
|
522
|
+
const a = l.expandable;
|
|
523
|
+
return a ? a.rowExpandable ? a.rowExpandable(t) : !!a.expandedRowRender : !1;
|
|
524
|
+
}, It = (t, a) => {
|
|
525
|
+
ye(t) && Et(t, a);
|
|
526
|
+
}, he = "__vtg_selection__", we = "__vtg_expand__", Tt = o(() => {
|
|
527
|
+
const t = l.expandable, a = l.rowSelection, n = t && t.showExpandColumn !== !1 ? {
|
|
528
|
+
key: we,
|
|
529
|
+
title: () => i.expandColumnTitle?.() ?? t.columnTitle ?? "",
|
|
509
530
|
width: t.columnWidth ?? 48,
|
|
510
531
|
align: "center",
|
|
511
532
|
fixed: t.fixed === !0 ? "left" : t.fixed
|
|
512
|
-
} : null,
|
|
513
|
-
key:
|
|
533
|
+
} : null, d = a ? {
|
|
534
|
+
key: he,
|
|
514
535
|
title: "",
|
|
515
|
-
width:
|
|
536
|
+
width: a.columnWidth ?? 48,
|
|
516
537
|
align: "center",
|
|
517
|
-
fixed:
|
|
518
|
-
} : null,
|
|
519
|
-
let p = !1,
|
|
520
|
-
for (const
|
|
521
|
-
if (
|
|
522
|
-
|
|
538
|
+
fixed: a.fixed === !0 ? "left" : a.fixed || void 0
|
|
539
|
+
} : null, h = Rl(me.value), g = [];
|
|
540
|
+
let p = !1, y = !1;
|
|
541
|
+
for (const w of h) {
|
|
542
|
+
if (w === jl) {
|
|
543
|
+
n && !p && (g.push(n), p = !0);
|
|
523
544
|
continue;
|
|
524
545
|
}
|
|
525
|
-
if (
|
|
526
|
-
|
|
546
|
+
if (w === Vl) {
|
|
547
|
+
d && !y && (g.push(d), y = !0);
|
|
527
548
|
continue;
|
|
528
549
|
}
|
|
529
|
-
|
|
550
|
+
g.push(w);
|
|
530
551
|
}
|
|
531
|
-
|
|
552
|
+
if (d && !y && g.unshift(d), n && !p) {
|
|
553
|
+
const w = t?.expandIconColumnIndex;
|
|
554
|
+
g.splice(typeof w == "number" && Number.isFinite(w) ? Math.min(g.length, Math.max(0, Math.floor(w)) + (d ? 1 : 0)) : d ? 1 : 0, 0, n);
|
|
555
|
+
}
|
|
556
|
+
return El(g, l.columnOrder, [he, we]);
|
|
532
557
|
}), {
|
|
533
558
|
leafColumns: f,
|
|
534
|
-
headerRows:
|
|
535
|
-
} =
|
|
536
|
-
columnWidths:
|
|
537
|
-
startResize:
|
|
538
|
-
isResizing:
|
|
539
|
-
} =
|
|
559
|
+
headerRows: re
|
|
560
|
+
} = Ge(() => Tt.value), Ht = o(() => re.value.length > 1), {
|
|
561
|
+
columnWidths: j,
|
|
562
|
+
startResize: Lt,
|
|
563
|
+
isResizing: Bt
|
|
564
|
+
} = Al({
|
|
540
565
|
columns: () => f.value,
|
|
541
|
-
onResizeColumn(t,
|
|
542
|
-
s("resizeColumn", t,
|
|
566
|
+
onResizeColumn(t, a) {
|
|
567
|
+
s("resizeColumn", t, a);
|
|
543
568
|
}
|
|
544
569
|
}), {
|
|
545
|
-
headerWrapRef:
|
|
546
|
-
bodyWrapRef:
|
|
547
|
-
scrollState:
|
|
548
|
-
handleBodyScroll:
|
|
549
|
-
fixedOffsets:
|
|
550
|
-
syncHorizontalScroll:
|
|
551
|
-
updateScrollState:
|
|
552
|
-
} =
|
|
570
|
+
headerWrapRef: V,
|
|
571
|
+
bodyWrapRef: B,
|
|
572
|
+
scrollState: Ce,
|
|
573
|
+
handleBodyScroll: xe,
|
|
574
|
+
fixedOffsets: be,
|
|
575
|
+
syncHorizontalScroll: Nt,
|
|
576
|
+
updateScrollState: Ft
|
|
577
|
+
} = Ll({
|
|
553
578
|
displayColumns: () => f.value,
|
|
554
|
-
columnWidths:
|
|
555
|
-
layoutWidths: () =>
|
|
556
|
-
syncElements: () =>
|
|
557
|
-
}),
|
|
558
|
-
compatClass:
|
|
559
|
-
fixedOffsets:
|
|
560
|
-
scrollState:
|
|
561
|
-
empty:
|
|
579
|
+
columnWidths: j,
|
|
580
|
+
layoutWidths: () => b.metrics.value?.widths,
|
|
581
|
+
syncElements: () => U.value ? [U.value] : []
|
|
582
|
+
}), Se = o(() => Tl({
|
|
583
|
+
compatClass: F,
|
|
584
|
+
fixedOffsets: be,
|
|
585
|
+
scrollState: Ce,
|
|
586
|
+
empty: v.value.length === 0,
|
|
562
587
|
fixedHeader: l.scroll?.y !== void 0,
|
|
563
|
-
fixedColumn:
|
|
564
|
-
horizontalScroll:
|
|
565
|
-
layoutFixed:
|
|
566
|
-
})),
|
|
567
|
-
if (
|
|
588
|
+
fixedColumn: Ee.value && Re.value,
|
|
589
|
+
horizontalScroll: Ee.value,
|
|
590
|
+
layoutFixed: $.value === "fixed"
|
|
591
|
+
})), Y = o(() => l.scroll?.y === "auto"), De = o(() => !!l.scroll?.y || l.showHeader !== !1 && !!l.sticky), Re = o(() => f.value.some((t) => t.fixed === "left" || t.fixed === "right")), Ee = o(() => l.scroll?.x !== void 0 || b.overflow.value || !!l.expandable?.fixed), Ot = o(() => W.value.some((t) => Il(t).enabled)), $ = o(() => l.tableLayout ? l.tableLayout : l.scroll?.y || l.scroll?.x || Re.value || Ot.value ? "fixed" : "auto"), _t = o(() => {
|
|
592
|
+
if (L.value)
|
|
568
593
|
return {
|
|
569
594
|
position: "sticky",
|
|
570
|
-
top: `${
|
|
595
|
+
top: `${L.value.offsetHeader ?? 0}px`,
|
|
571
596
|
zIndex: "4"
|
|
572
597
|
};
|
|
573
|
-
}),
|
|
598
|
+
}), Ie = C(null), U = C(null), P = C(null), b = Fl({
|
|
574
599
|
columns: () => f.value,
|
|
575
|
-
columnWidths:
|
|
576
|
-
layout: () =>
|
|
577
|
-
split: () =>
|
|
578
|
-
root: () =>
|
|
579
|
-
viewport: () =>
|
|
600
|
+
columnWidths: j,
|
|
601
|
+
layout: () => $.value,
|
|
602
|
+
split: () => De.value,
|
|
603
|
+
root: () => P.value,
|
|
604
|
+
viewport: () => P.value?.contains(B.value) ? B.value : V.value ?? P.value,
|
|
580
605
|
scrollX: () => l.scroll?.x,
|
|
581
606
|
onMeasure: () => {
|
|
582
|
-
|
|
607
|
+
T.value || Ft();
|
|
583
608
|
}
|
|
584
609
|
}), {
|
|
585
|
-
bodyHeight:
|
|
586
|
-
} =
|
|
587
|
-
enabled: () =>
|
|
588
|
-
wrapperEl: () =>
|
|
589
|
-
headerEl: () =>
|
|
590
|
-
summaryEl: () =>
|
|
591
|
-
hasData: () =>
|
|
592
|
-
}),
|
|
610
|
+
bodyHeight: Te
|
|
611
|
+
} = Bl({
|
|
612
|
+
enabled: () => Y.value,
|
|
613
|
+
wrapperEl: () => Ie.value,
|
|
614
|
+
headerEl: () => V.value,
|
|
615
|
+
summaryEl: () => U.value,
|
|
616
|
+
hasData: () => v.value.length > 0
|
|
617
|
+
}), At = o(() => {
|
|
593
618
|
const t = l.scroll?.y;
|
|
594
619
|
if (t !== void 0)
|
|
595
|
-
return
|
|
620
|
+
return Y.value ? Te.value : typeof t == "number" ? Number.isFinite(t) && t > 0 ? t : void 0 : t;
|
|
596
621
|
}), {
|
|
597
|
-
enabled:
|
|
598
|
-
itemHeight:
|
|
599
|
-
listHeight:
|
|
600
|
-
fixedHeight:
|
|
601
|
-
resolvedScrollY:
|
|
602
|
-
} =
|
|
622
|
+
enabled: T,
|
|
623
|
+
itemHeight: Pt,
|
|
624
|
+
listHeight: kt,
|
|
625
|
+
fixedHeight: Wt,
|
|
626
|
+
resolvedScrollY: zt
|
|
627
|
+
} = Pl({
|
|
603
628
|
virtual: () => l.virtual,
|
|
604
629
|
scrollY: () => l.scroll?.y,
|
|
605
630
|
size: () => l.size,
|
|
606
631
|
rowHeight: () => l.rowHeight,
|
|
607
|
-
measuredHeight: () =>
|
|
608
|
-
}),
|
|
632
|
+
measuredHeight: () => Te.value
|
|
633
|
+
}), He = o(() => W.value.some((t) => !!t.customCell || !!t.customRender)), ie = o(() => !Ht.value || l.bordered ? {
|
|
609
634
|
table: "",
|
|
610
635
|
th: "",
|
|
611
636
|
td: ""
|
|
@@ -613,72 +638,72 @@ const _o = /* @__PURE__ */ Jt({
|
|
|
613
638
|
table: e.groupedHeaderTable(),
|
|
614
639
|
th: e.groupedHeaderTh(),
|
|
615
640
|
td: e.groupedHeaderTd()
|
|
616
|
-
}),
|
|
617
|
-
|
|
641
|
+
}), k = o(() => S(e.table(), ie.value.table) ?? ""), Le = o(() => b.enabled.value ? e.widthLayoutCell() : void 0), Be = o(() => S(e.th(), ie.value.th, Le.value) ?? ""), de = o(() => S(e.td(), ie.value.td, Le.value) ?? "");
|
|
642
|
+
H([T, He], ([t, a]) => {
|
|
618
643
|
}, {
|
|
619
644
|
immediate: !0
|
|
620
|
-
}),
|
|
645
|
+
}), H([() => l.virtual, zt], ([t, a]) => {
|
|
621
646
|
if (!t) return;
|
|
622
|
-
const
|
|
623
|
-
|
|
647
|
+
const n = String(l.scroll?.y);
|
|
648
|
+
a.kind === "compat-px" ? ul("vtable-scroll-y-compat-px", `[VTable] virtual 模式下字符串 scroll.y(${n})按 ${a.value}px 解析,这是兼容行为;请改用数字或 'auto'。`) : a.kind === "invalid-string" || a.kind === "invalid-number" && l.scroll?.y && `${kl}`;
|
|
624
649
|
}, {
|
|
625
650
|
immediate: !0
|
|
626
651
|
});
|
|
627
|
-
const
|
|
628
|
-
|
|
629
|
-
t && (
|
|
630
|
-
}),
|
|
631
|
-
t && (
|
|
652
|
+
const Ne = C(null), Fe = C(null);
|
|
653
|
+
H(() => Ne.value?.wrapRef, (t) => {
|
|
654
|
+
t && (B.value = t);
|
|
655
|
+
}), H(() => Fe.value?.wrapRef, (t) => {
|
|
656
|
+
t && (B.value = t);
|
|
632
657
|
});
|
|
633
|
-
const
|
|
634
|
-
|
|
658
|
+
const Kt = o(() => Ol(f.value)), Oe = o(() => l.virtualColumn ? T.value ? He.value ? "列上有 customCell / customRender,可能返回 colSpan / rowSpan;单元格合并会让某个 td 缺席,进而破坏列宽不变量(虚拟模式本就不支持合并)" : Kt.value.contiguous ? null : "固定列必须分列两端:左固定连成前缀、右固定连成后缀,中间夹着的固定列会被窗口跳过" : "它只作用于虚拟表体,需要同时开启 virtual 与 scroll.y" : null), ue = o(() => l.virtualColumn && Oe.value === null);
|
|
659
|
+
H(Oe, (t) => {
|
|
635
660
|
}, {
|
|
636
661
|
immediate: !0
|
|
637
662
|
});
|
|
638
663
|
const {
|
|
639
|
-
metrics:
|
|
640
|
-
} =
|
|
641
|
-
enabled: () =>
|
|
642
|
-
headerEl: () =>
|
|
664
|
+
metrics: Mt
|
|
665
|
+
} = Nl({
|
|
666
|
+
enabled: () => ue.value && !b.enabled.value,
|
|
667
|
+
headerEl: () => V.value,
|
|
643
668
|
columns: () => f.value,
|
|
644
|
-
columnWidths:
|
|
669
|
+
columnWidths: j,
|
|
645
670
|
hasHeader: () => l.showHeader !== !1
|
|
646
|
-
}),
|
|
647
|
-
|
|
648
|
-
!t ||
|
|
671
|
+
}), _e = o(() => b.metrics.value ?? Mt.value);
|
|
672
|
+
H([ue, _e], ([t, a]) => {
|
|
673
|
+
!t || a || l.showHeader !== !1 || b.enabled.value;
|
|
649
674
|
}, {
|
|
650
675
|
immediate: !0
|
|
651
676
|
});
|
|
652
|
-
function
|
|
653
|
-
return
|
|
677
|
+
function jt(t) {
|
|
678
|
+
return ne.value ? ge.value.get(t)?.level ?? 0 : 0;
|
|
654
679
|
}
|
|
655
|
-
function
|
|
656
|
-
return l.rowClassName ? typeof l.rowClassName == "function" ? l.rowClassName(t,
|
|
680
|
+
function Vt(t, a) {
|
|
681
|
+
return l.rowClassName ? typeof l.rowClassName == "function" ? l.rowClassName(t, a, jt(t)) : l.rowClassName : "";
|
|
657
682
|
}
|
|
658
|
-
function
|
|
659
|
-
return l.customRow?.(t,
|
|
683
|
+
function Yt(t, a) {
|
|
684
|
+
return l.customRow?.(t, a);
|
|
660
685
|
}
|
|
661
|
-
function
|
|
662
|
-
return l.customHeaderRow?.(t,
|
|
686
|
+
function $t(t, a) {
|
|
687
|
+
return l.customHeaderRow?.(t, a);
|
|
663
688
|
}
|
|
664
|
-
function
|
|
689
|
+
function Ut(t) {
|
|
665
690
|
if (typeof t.title != "function")
|
|
666
691
|
return t.title ?? "";
|
|
667
|
-
const
|
|
692
|
+
const a = t, n = ot.value.filter((d) => !!d.column);
|
|
668
693
|
return t.title({
|
|
669
|
-
sortOrder:
|
|
670
|
-
sortColumn:
|
|
671
|
-
sortColumns:
|
|
672
|
-
filters:
|
|
694
|
+
sortOrder: a.sorter ? ee(a) ?? void 0 : void 0,
|
|
695
|
+
sortColumn: at.value.column,
|
|
696
|
+
sortColumns: n.length > 0 ? n : void 0,
|
|
697
|
+
filters: z()
|
|
673
698
|
});
|
|
674
699
|
}
|
|
675
|
-
function
|
|
676
|
-
return !!(t.sorter &&
|
|
700
|
+
function Gt(t) {
|
|
701
|
+
return !!(t.sorter && ee(t));
|
|
677
702
|
}
|
|
678
|
-
const
|
|
703
|
+
const Ae = {
|
|
679
704
|
width: "100%",
|
|
680
705
|
minWidth: "100%"
|
|
681
|
-
},
|
|
706
|
+
}, Xt = {
|
|
682
707
|
widthConstraintCell: e.widthConstraintCell,
|
|
683
708
|
widthConstraintInner: e.widthConstraintInner,
|
|
684
709
|
widthLayoutCell: e.widthLayoutCell,
|
|
@@ -690,6 +715,10 @@ const _o = /* @__PURE__ */ Jt({
|
|
|
690
715
|
sortAreaOuter: e.sortAreaOuter,
|
|
691
716
|
sortAreaWrapper: e.sortAreaWrapper,
|
|
692
717
|
sortAreaTitle: e.sortAreaTitle,
|
|
718
|
+
headerHelp: e.headerHelp,
|
|
719
|
+
cellContent: e.cellContent,
|
|
720
|
+
copyButton: e.copyButton,
|
|
721
|
+
cellStatus: e.cellStatus,
|
|
693
722
|
filterIconWrapper: e.filterIconWrapper,
|
|
694
723
|
filterIcon: e.filterIcon,
|
|
695
724
|
filterDropdown: e.filterDropdown,
|
|
@@ -761,240 +790,250 @@ const _o = /* @__PURE__ */ Jt({
|
|
|
761
790
|
trDragging: e.trDragging,
|
|
762
791
|
trDropAbove: e.trDropAbove,
|
|
763
792
|
trDropBelow: e.trDropBelow
|
|
764
|
-
},
|
|
765
|
-
return
|
|
766
|
-
columnLayout:
|
|
767
|
-
bodyCell:
|
|
768
|
-
headerCell:
|
|
769
|
-
empty:
|
|
770
|
-
getSortOrder:
|
|
771
|
-
toggleSortOrder:
|
|
772
|
-
isColumnSorted:
|
|
773
|
-
getFilteredValue:
|
|
774
|
-
confirmFilter:
|
|
775
|
-
resetFilter:
|
|
776
|
-
customFilterDropdown:
|
|
777
|
-
customFilterIcon:
|
|
778
|
-
showSorterTooltip:
|
|
779
|
-
headerEllipsis:
|
|
780
|
-
subThemeSlots:
|
|
781
|
-
presetConfig:
|
|
782
|
-
themePreset:
|
|
783
|
-
cssMode:
|
|
784
|
-
classPrefix:
|
|
785
|
-
vtgClass: (t) =>
|
|
786
|
-
compatClass:
|
|
787
|
-
localeName:
|
|
788
|
-
locale:
|
|
793
|
+
}, Pe = o(() => Yl(x.value)), ke = C(!1);
|
|
794
|
+
return Me(Ml, {
|
|
795
|
+
columnLayout: b,
|
|
796
|
+
bodyCell: i.bodyCell,
|
|
797
|
+
headerCell: i.headerCell,
|
|
798
|
+
empty: i.empty,
|
|
799
|
+
getSortOrder: ee,
|
|
800
|
+
toggleSortOrder: tt,
|
|
801
|
+
isColumnSorted: Gt,
|
|
802
|
+
getFilteredValue: nt,
|
|
803
|
+
confirmFilter: rt,
|
|
804
|
+
resetFilter: it,
|
|
805
|
+
customFilterDropdown: i.customFilterDropdown,
|
|
806
|
+
customFilterIcon: i.customFilterIcon,
|
|
807
|
+
showSorterTooltip: o(() => l.showSorterTooltip ?? Pe.value.showSorterTooltip),
|
|
808
|
+
headerEllipsis: o(() => l.headerEllipsis),
|
|
809
|
+
subThemeSlots: Xt,
|
|
810
|
+
presetConfig: Pe,
|
|
811
|
+
themePreset: x,
|
|
812
|
+
cssMode: E,
|
|
813
|
+
classPrefix: I,
|
|
814
|
+
vtgClass: (t) => G(t, E.value, I.value),
|
|
815
|
+
compatClass: F,
|
|
816
|
+
localeName: O,
|
|
817
|
+
locale: et,
|
|
789
818
|
rowSelection: () => l.rowSelection,
|
|
790
|
-
isSelected:
|
|
791
|
-
isDisabledRow:
|
|
792
|
-
getSelectionState:
|
|
793
|
-
toggleRow:
|
|
794
|
-
toggleAll:
|
|
795
|
-
allCheckedState: () =>
|
|
796
|
-
getRowKey:
|
|
797
|
-
invertSelection:
|
|
798
|
-
clearSelection:
|
|
799
|
-
getChangeableRowKeys:
|
|
800
|
-
fixedOffsets:
|
|
801
|
-
scrollState:
|
|
802
|
-
leafColumnCount:
|
|
803
|
-
bordered:
|
|
804
|
-
tableLayout:
|
|
805
|
-
sticky:
|
|
806
|
-
getRowProps:
|
|
807
|
-
getRowClassName:
|
|
808
|
-
getHeaderRowProps:
|
|
809
|
-
getColumnTitle:
|
|
819
|
+
isSelected: gt,
|
|
820
|
+
isDisabledRow: yt,
|
|
821
|
+
getSelectionState: ht,
|
|
822
|
+
toggleRow: wt,
|
|
823
|
+
toggleAll: Ct,
|
|
824
|
+
allCheckedState: () => xt.value,
|
|
825
|
+
getRowKey: A,
|
|
826
|
+
invertSelection: bt,
|
|
827
|
+
clearSelection: St,
|
|
828
|
+
getChangeableRowKeys: Dt,
|
|
829
|
+
fixedOffsets: be,
|
|
830
|
+
scrollState: Ce,
|
|
831
|
+
leafColumnCount: o(() => f.value.length),
|
|
832
|
+
bordered: o(() => l.bordered),
|
|
833
|
+
tableLayout: $,
|
|
834
|
+
sticky: o(() => l.sticky),
|
|
835
|
+
getRowProps: Yt,
|
|
836
|
+
getRowClassName: Vt,
|
|
837
|
+
getHeaderRowProps: $t,
|
|
838
|
+
getColumnTitle: Ut,
|
|
810
839
|
getPopupContainer: l.getPopupContainer,
|
|
811
840
|
transformCellText: l.transformCellText,
|
|
841
|
+
columnEmptyText: o(() => l.columnEmptyText),
|
|
812
842
|
expandable: () => l.expandable,
|
|
813
|
-
isExpanded:
|
|
814
|
-
toggleExpand:
|
|
815
|
-
isRowExpandable:
|
|
816
|
-
columnWidths:
|
|
817
|
-
startResize:
|
|
818
|
-
isResizing: () =>
|
|
819
|
-
displayColumns:
|
|
843
|
+
isExpanded: Rt,
|
|
844
|
+
toggleExpand: It,
|
|
845
|
+
isRowExpandable: ye,
|
|
846
|
+
columnWidths: j,
|
|
847
|
+
startResize: Lt,
|
|
848
|
+
isResizing: () => Bt.value,
|
|
849
|
+
displayColumns: o(() => f.value),
|
|
820
850
|
registerSummaryFixed: (t) => {
|
|
821
|
-
|
|
851
|
+
ke.value = t;
|
|
822
852
|
},
|
|
823
|
-
isTreeData:
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
853
|
+
isTreeData: ne,
|
|
854
|
+
treeIndentColumnIndex: o(() => {
|
|
855
|
+
const t = f.value.map((n, d) => ({
|
|
856
|
+
column: n,
|
|
857
|
+
index: d
|
|
858
|
+
})).filter(({
|
|
859
|
+
column: n
|
|
860
|
+
}) => n.key !== "__vtg_selection__" && n.key !== "__vtg_expand__"), a = l.expandable?.expandIconColumnIndex ?? 0;
|
|
861
|
+
return t[Math.max(0, Math.min(t.length - 1, Math.floor(Number.isFinite(a) ? a : 0)))]?.index ?? -1;
|
|
862
|
+
}),
|
|
863
|
+
treeFlattenData: ve,
|
|
864
|
+
getFlattenRow: (t) => ge.value.get(t),
|
|
865
|
+
toggleTreeExpand: st,
|
|
866
|
+
isTreeExpanded: ct,
|
|
867
|
+
treeIndentSize: ft,
|
|
868
|
+
hoverRange: mt,
|
|
869
|
+
setHoverRange: pt,
|
|
870
|
+
clearHoverRange: vt,
|
|
832
871
|
// 拖拽期间抑制 hover 高亮,避免干扰拖放指示线
|
|
833
|
-
hoverable:
|
|
872
|
+
hoverable: o(() => l.hoverable !== !1 && M.draggingKey.value === null),
|
|
834
873
|
rowDrag: {
|
|
835
|
-
enabled:
|
|
836
|
-
draggingKey:
|
|
837
|
-
dropTarget:
|
|
838
|
-
getBindings: (t,
|
|
874
|
+
enabled: o(() => l.rowDraggable === !0),
|
|
875
|
+
draggingKey: M.draggingKey,
|
|
876
|
+
dropTarget: M.dropTarget,
|
|
877
|
+
getBindings: (t, a, n) => M.getBindings(t, a, n)
|
|
839
878
|
}
|
|
840
879
|
}), () => {
|
|
841
880
|
let t;
|
|
842
|
-
const
|
|
843
|
-
data:
|
|
844
|
-
}) : null,
|
|
845
|
-
data:
|
|
846
|
-
}) : null,
|
|
847
|
-
tableLayout:
|
|
881
|
+
const a = l.title ? l.title(v.value) : i.title ? i.title({
|
|
882
|
+
data: v.value
|
|
883
|
+
}) : null, n = l.footer ? l.footer(v.value) : i.footer ? i.footer({
|
|
884
|
+
data: v.value
|
|
885
|
+
}) : null, d = i.summary ? i.summary() : null, h = ke.value !== !1, g = l.scroll, p = {
|
|
886
|
+
tableLayout: $.value
|
|
848
887
|
};
|
|
849
|
-
|
|
850
|
-
const
|
|
888
|
+
g?.x ? (p.width = typeof g.x == "number" ? `${g.x}px` : g.x, p.minWidth = "100%") : p.width = "100%", Object.assign(p, b.tableStyle.value);
|
|
889
|
+
const y = l.loading, w = u.value, qt = typeof y == "object" && y !== null ? y.indicator : void 0, Jt = typeof y == "object" && y !== null ? y.tip : void 0, We = w && (i.loading ? r(Ue, {
|
|
851
890
|
loadingClass: e.loading()
|
|
852
|
-
},
|
|
891
|
+
}, Xe(t = i.loading()) ? t : {
|
|
853
892
|
default: () => [t]
|
|
854
|
-
}) :
|
|
893
|
+
}) : r(Ue, {
|
|
855
894
|
loadingClass: e.loading(),
|
|
856
|
-
indicator:
|
|
857
|
-
tip:
|
|
895
|
+
indicator: qt,
|
|
896
|
+
tip: Jt
|
|
858
897
|
}, null));
|
|
859
|
-
if (
|
|
860
|
-
const
|
|
861
|
-
ref:
|
|
862
|
-
class:
|
|
863
|
-
style:
|
|
864
|
-
}, [
|
|
865
|
-
class:
|
|
866
|
-
}, [
|
|
898
|
+
if (De.value) {
|
|
899
|
+
const Zt = l.showHeader !== !1 ? r("div", {
|
|
900
|
+
ref: V,
|
|
901
|
+
class: S(e.headerWrapper(), L.value && F?.("sticky-holder")),
|
|
902
|
+
style: _t.value
|
|
903
|
+
}, [r("div", {
|
|
904
|
+
class: G("block w-full min-w-full", E.value, I.value)
|
|
905
|
+
}, [r("table", {
|
|
867
906
|
"data-vtg-table": "",
|
|
868
|
-
class:
|
|
907
|
+
class: k.value,
|
|
869
908
|
style: p
|
|
870
|
-
}, [
|
|
909
|
+
}, [r(q, {
|
|
871
910
|
columns: f.value
|
|
872
|
-
}, null),
|
|
873
|
-
rows:
|
|
911
|
+
}, null), r(J, null, null), r(Ye, {
|
|
912
|
+
rows: re.value,
|
|
874
913
|
theadClass: e.thead(),
|
|
875
914
|
rowClass: e.tr(),
|
|
876
|
-
thClass:
|
|
915
|
+
thClass: Be.value,
|
|
877
916
|
headerCellInnerClass: e.headerCellInner()
|
|
878
|
-
}, null)])])]) : null,
|
|
879
|
-
ref:
|
|
880
|
-
dataSource:
|
|
917
|
+
}, null)])])]) : null, Qt = T.value ? r($l, {
|
|
918
|
+
ref: pe,
|
|
919
|
+
dataSource: v.value,
|
|
881
920
|
columns: f.value,
|
|
882
921
|
tbodyClass: e.tbody(),
|
|
883
922
|
rowClass: e.tr(),
|
|
884
|
-
tdClass:
|
|
923
|
+
tdClass: de.value,
|
|
885
924
|
emptyClass: e.empty(),
|
|
886
925
|
bodyCellEllipsisClass: e.bodyCellEllipsis(),
|
|
887
|
-
tableClass:
|
|
926
|
+
tableClass: k.value,
|
|
888
927
|
tableStyle: p,
|
|
889
928
|
rowKey: l.rowKey,
|
|
890
|
-
height:
|
|
891
|
-
itemHeight:
|
|
892
|
-
fixedHeight:
|
|
893
|
-
virtualColumn:
|
|
894
|
-
columnMetrics:
|
|
929
|
+
height: kt.value,
|
|
930
|
+
itemHeight: Pt.value,
|
|
931
|
+
fixedHeight: Wt.value,
|
|
932
|
+
virtualColumn: ue.value,
|
|
933
|
+
columnMetrics: _e.value,
|
|
895
934
|
showScrollBar: "hover",
|
|
896
|
-
onVirtualScroll: (
|
|
897
|
-
|
|
935
|
+
onVirtualScroll: (ze) => {
|
|
936
|
+
Nt(ze.x, ze.maxX);
|
|
898
937
|
}
|
|
899
|
-
}, null) : null,
|
|
900
|
-
ref:
|
|
901
|
-
maxHeight:
|
|
938
|
+
}, null) : null, el = T.value ? null : r(je, {
|
|
939
|
+
ref: Ne,
|
|
940
|
+
maxHeight: At.value,
|
|
902
941
|
wrapClass: e.bodyWrapper(),
|
|
903
|
-
viewStyle:
|
|
904
|
-
onScroll:
|
|
942
|
+
viewStyle: Ae,
|
|
943
|
+
onScroll: xe
|
|
905
944
|
}, {
|
|
906
|
-
default: () => [
|
|
945
|
+
default: () => [r("table", {
|
|
907
946
|
"data-vtg-table": "",
|
|
908
|
-
class:
|
|
947
|
+
class: k.value,
|
|
909
948
|
style: p
|
|
910
|
-
}, [
|
|
949
|
+
}, [r(q, {
|
|
911
950
|
columns: f.value
|
|
912
|
-
}, null),
|
|
913
|
-
dataSource:
|
|
951
|
+
}, null), r(J, null, null), r($e, {
|
|
952
|
+
dataSource: v.value,
|
|
914
953
|
columns: f.value,
|
|
915
954
|
tbodyClass: e.tbody(),
|
|
916
955
|
rowClass: e.tr(),
|
|
917
|
-
tdClass:
|
|
956
|
+
tdClass: de.value,
|
|
918
957
|
emptyClass: e.empty(),
|
|
919
958
|
bodyCellEllipsisClass: e.bodyCellEllipsis(),
|
|
920
959
|
rowKey: l.rowKey
|
|
921
|
-
}, null),
|
|
960
|
+
}, null), d && !h && r("tfoot", {
|
|
922
961
|
class: e.summary()
|
|
923
|
-
}, [
|
|
924
|
-
}),
|
|
925
|
-
ref:
|
|
926
|
-
class:
|
|
927
|
-
style:
|
|
962
|
+
}, [d])])]
|
|
963
|
+
}), tl = d && (h || T.value) ? r("div", {
|
|
964
|
+
ref: U,
|
|
965
|
+
class: S(e.headerWrapper(), F?.("summary"), L.value && h && F?.("sticky-holder")),
|
|
966
|
+
style: h ? {
|
|
928
967
|
position: "sticky",
|
|
929
|
-
bottom: `${
|
|
968
|
+
bottom: `${L.value?.offsetSummary ?? 0}px`,
|
|
930
969
|
zIndex: "4",
|
|
931
970
|
overflow: "hidden"
|
|
932
971
|
} : void 0
|
|
933
|
-
}, [
|
|
934
|
-
class:
|
|
935
|
-
}, [
|
|
972
|
+
}, [r("div", {
|
|
973
|
+
class: G("block w-full min-w-full", E.value, I.value)
|
|
974
|
+
}, [r("table", {
|
|
936
975
|
"data-vtg-table": "",
|
|
937
|
-
class:
|
|
976
|
+
class: k.value,
|
|
938
977
|
style: p
|
|
939
|
-
}, [
|
|
978
|
+
}, [r(q, {
|
|
940
979
|
columns: f.value
|
|
941
|
-
}, null),
|
|
980
|
+
}, null), r(J, null, null), r("tfoot", {
|
|
942
981
|
class: e.summary()
|
|
943
|
-
}, [
|
|
944
|
-
return
|
|
945
|
-
ref:
|
|
946
|
-
class:
|
|
947
|
-
}, [
|
|
982
|
+
}, [d])])])]) : null;
|
|
983
|
+
return r("div", {
|
|
984
|
+
ref: P,
|
|
985
|
+
class: S(e.root(), Y.value && e.rootAutoHeight(), Se.value, R.value)
|
|
986
|
+
}, [K("top"), a && r("div", {
|
|
948
987
|
class: e.title()
|
|
949
|
-
}, [
|
|
950
|
-
ref:
|
|
951
|
-
class:
|
|
952
|
-
}, [
|
|
988
|
+
}, [a]), r("div", {
|
|
989
|
+
ref: Ie,
|
|
990
|
+
class: S(e.wrapper(), Y.value && e.wrapperAutoHeight(), L.value && G("overflow-clip", E.value, I.value))
|
|
991
|
+
}, [Zt, Qt, el, tl, We]), n && r("div", {
|
|
953
992
|
class: e.footer()
|
|
954
|
-
}, [
|
|
993
|
+
}, [n]), K("bottom")]);
|
|
955
994
|
}
|
|
956
|
-
const
|
|
995
|
+
const se = r(nl, null, [r("table", {
|
|
957
996
|
"data-vtg-table": "",
|
|
958
|
-
class:
|
|
997
|
+
class: k.value,
|
|
959
998
|
style: p
|
|
960
|
-
}, [
|
|
999
|
+
}, [r(q, {
|
|
961
1000
|
columns: f.value
|
|
962
|
-
}, null),
|
|
963
|
-
rows:
|
|
1001
|
+
}, null), r(J, null, null), l.showHeader !== !1 && r(Ye, {
|
|
1002
|
+
rows: re.value,
|
|
964
1003
|
theadClass: e.thead(),
|
|
965
1004
|
rowClass: e.tr(),
|
|
966
|
-
thClass:
|
|
1005
|
+
thClass: Be.value,
|
|
967
1006
|
headerCellInnerClass: e.headerCellInner()
|
|
968
|
-
}, null),
|
|
969
|
-
dataSource:
|
|
1007
|
+
}, null), r($e, {
|
|
1008
|
+
dataSource: v.value,
|
|
970
1009
|
columns: f.value,
|
|
971
1010
|
tbodyClass: e.tbody(),
|
|
972
1011
|
rowClass: e.tr(),
|
|
973
|
-
tdClass:
|
|
1012
|
+
tdClass: de.value,
|
|
974
1013
|
emptyClass: e.empty(),
|
|
975
1014
|
bodyCellEllipsisClass: e.bodyCellEllipsis(),
|
|
976
1015
|
rowKey: l.rowKey
|
|
977
|
-
}, null),
|
|
1016
|
+
}, null), d && r("tfoot", {
|
|
978
1017
|
class: e.summary()
|
|
979
|
-
}, [
|
|
980
|
-
return
|
|
981
|
-
ref:
|
|
982
|
-
class:
|
|
983
|
-
}, [
|
|
1018
|
+
}, [d])]), We]);
|
|
1019
|
+
return r("div", {
|
|
1020
|
+
ref: P,
|
|
1021
|
+
class: S(e.root(), Se.value, R.value)
|
|
1022
|
+
}, [K("top"), a && r("div", {
|
|
984
1023
|
class: e.title()
|
|
985
|
-
}, [
|
|
986
|
-
ref:
|
|
1024
|
+
}, [a]), r(je, {
|
|
1025
|
+
ref: Fe,
|
|
987
1026
|
wrapClass: e.wrapper(),
|
|
988
|
-
viewStyle:
|
|
989
|
-
onScroll:
|
|
990
|
-
},
|
|
991
|
-
default: () => [
|
|
992
|
-
}),
|
|
1027
|
+
viewStyle: Ae,
|
|
1028
|
+
onScroll: xe
|
|
1029
|
+
}, Xe(se) ? se : {
|
|
1030
|
+
default: () => [se]
|
|
1031
|
+
}), n && r("div", {
|
|
993
1032
|
class: e.footer()
|
|
994
|
-
}, [
|
|
1033
|
+
}, [n]), K("bottom")]);
|
|
995
1034
|
};
|
|
996
1035
|
}
|
|
997
1036
|
});
|
|
998
1037
|
export {
|
|
999
|
-
|
|
1038
|
+
ja as default
|
|
1000
1039
|
};
|