vueye-table 3.0.0-beta.6 → 3.0.0-beta.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.
- package/README.md +60 -16
- package/dist/index.d.ts +187 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +99 -22
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
# vueye-table
|
|
2
2
|
|
|
3
|
-
`VueyeTable` and `VueyeGrid` support opt-in virtualization through `virtual`, `height`, `rowHeight` and `overscan`; grids also expose `virtualColumns` and `columnWidth`. Virtual tables default to no paging, with `paginate` available for large pages. The guide and runnable 100k-record example live in `docs/guide/virtualization.md` and `docs/examples/virtual-components.md`.
|
|
4
|
-
|
|
5
3
|
A Vue framework for data, data tables, and spreadsheets.
|
|
6
4
|
|
|
7
5
|
vueye-table began as a single table component. Version 3 is a rewrite around one idea: a table is
|
|
@@ -21,17 +19,42 @@ undo, clipboard, and export. Vue layers sit on top of it, and you pick the one t
|
|
|
21
19
|
Each layer depends only on the layers beneath it, and `vueye-table` re-exports all of them, so
|
|
22
20
|
one install covers every level.
|
|
23
21
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
>
|
|
22
|
+
<!-- current-release:start -->
|
|
23
|
+
|
|
24
|
+
> **Status:** `3.0.0-beta.8`, published on npm's `beta` and `latest` channels. The beta is for application
|
|
25
|
+
> feedback: documented import paths, options, events and slot scopes are kept stable, and a
|
|
26
|
+
> necessary breaking change ships with an ADR and migration notes. It is not production ready.
|
|
27
|
+
> See [the beta contract](https://github.com/boussadjra/vueye-table/blob/main/docs/guide/beta.md). The 2.x component lives on the
|
|
28
|
+
> [`legacy`](https://github.com/boussadjra/vueye-table/tree/legacy) branch; see
|
|
29
|
+
> [Upgrading from 2.x](https://github.com/boussadjra/vueye-table/blob/main/docs/guide/upgrading-from-2.md).
|
|
27
30
|
|
|
28
31
|
## Install
|
|
29
32
|
|
|
30
33
|
```bash
|
|
31
|
-
pnpm add vueye-table
|
|
34
|
+
pnpm add vueye-table@beta
|
|
32
35
|
```
|
|
33
36
|
|
|
34
|
-
|
|
37
|
+
Install an exact version such as `3.0.0-beta.8` to pin a release. Both `pnpm add vueye-table` and
|
|
38
|
+
`pnpm add vueye-table@beta` follow the current beta. Vue 3.5 or newer is a peer dependency.
|
|
39
|
+
|
|
40
|
+
<!-- current-release:end -->
|
|
41
|
+
|
|
42
|
+
## What the beta covers
|
|
43
|
+
|
|
44
|
+
- **Tables and spreadsheets**: search, column filters, multi-column sorting, pagination,
|
|
45
|
+
selection, column visibility, CSV/TSV export, and a spreadsheet grid with clipboard and undo.
|
|
46
|
+
- **Editing and validation**: inline cell and row editing in `VueyeTable`, typed and custom
|
|
47
|
+
editors, validation issues, dirty rows, revert, and a saved baseline you acknowledge.
|
|
48
|
+
- **Expansion and trees**: detail rows, nested and lazy-loaded children, tree search that keeps
|
|
49
|
+
matching branches.
|
|
50
|
+
- **Grouping and layout**: nested group rows, aggregate headers or footers, column resizing,
|
|
51
|
+
sticky columns and top/bottom row regions, including virtualized tables and grids.
|
|
52
|
+
- **Large data**: opt-in row and column virtualization for tables and grids, and incremental
|
|
53
|
+
streams, cursor loading, and cancellable sources.
|
|
54
|
+
- **Language and themes**: every word shown or announced comes from `messages`, numbers and
|
|
55
|
+
ordering follow `locale`, search ignores case and accents, and host design tokens win over
|
|
56
|
+
the defaults.
|
|
57
|
+
- **Server data**: `manual` mode hands searching, sorting and paging to your API.
|
|
35
58
|
|
|
36
59
|
## Full table
|
|
37
60
|
|
|
@@ -75,9 +98,16 @@ const selected = ref<readonly RowKey[]>([]);
|
|
|
75
98
|
Column ids are typed paths into your rows, so `format` above receives a `number`. Without
|
|
76
99
|
`columns`, columns are inferred from the data.
|
|
77
100
|
|
|
78
|
-
|
|
79
|
-
`hiddenColumns`,
|
|
80
|
-
|
|
101
|
+
The full components expose `v-model` bindings for `page`, `pageSize`, `sorting`, `search`,
|
|
102
|
+
`filters`, `hiddenColumns`, `selected`, `expanded`, `columnSizing`, `columnPinning`, `grouping`,
|
|
103
|
+
`expandedGroups` and `rowPinning`. Add `manual` and `row-count` to let a server search, sort,
|
|
104
|
+
and page, with the table presenting whatever page it returns.
|
|
105
|
+
|
|
106
|
+
Use `resizable-columns` for resize handles and `groupable` for ordered grouping controls.
|
|
107
|
+
`aggregate-position="footer"` moves group totals below their expanded leaves;
|
|
108
|
+
`row-pinning-controls` enables pin actions without enabling editing. See
|
|
109
|
+
[grouping](https://github.com/boussadjra/vueye-table/blob/main/docs/guide/grouping.md), [column layout](https://github.com/boussadjra/vueye-table/blob/main/docs/guide/columns.md) and
|
|
110
|
+
[row pinning](https://github.com/boussadjra/vueye-table/blob/main/docs/guide/row-pinning.md) for examples and model shapes.
|
|
81
111
|
|
|
82
112
|
## Spreadsheet
|
|
83
113
|
|
|
@@ -111,7 +141,8 @@ const table = useDataTable({ data: users, columns });
|
|
|
111
141
|
|
|
112
142
|
Headless components render semantic, accessible markup (`aria-sort`, `aria-selected`,
|
|
113
143
|
`aria-rowindex`, a polite live status, grid keyboard navigation) with `data-*` state attributes
|
|
114
|
-
and no styles.
|
|
144
|
+
and no styles. Components expose slot props and `data-*` state; primitives with an `as` prop
|
|
145
|
+
let you choose their element. Structural group and pinned-row composition retain native rows.
|
|
115
146
|
|
|
116
147
|
## Engine
|
|
117
148
|
|
|
@@ -152,21 +183,34 @@ The styled layer is driven by CSS custom properties on `.vt-surface`:
|
|
|
152
183
|
}
|
|
153
184
|
```
|
|
154
185
|
|
|
155
|
-
Dark colors follow `prefers-color-scheme`; `theme="dark"` or `theme="light"` forces one
|
|
156
|
-
|
|
186
|
+
Dark colors follow `prefers-color-scheme`; `theme="dark"` or `theme="light"` forces one, and
|
|
187
|
+
`theme="inherit"` declares no colors so the host's own tokens apply. The defaults have zero
|
|
188
|
+
specificity, so your tokens always win. Density is `compact`, `comfortable`, or `spacious`.
|
|
189
|
+
|
|
190
|
+
## Language
|
|
191
|
+
|
|
192
|
+
```vue
|
|
193
|
+
<VueyeTable :data="rows" :columns="columns" locale="fr" :messages="{ columns: 'Colonnes' }" />
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
Every word a table shows or announces comes from `TableMessages`; whatever you leave out keeps its
|
|
197
|
+
English default. `app.use(VueyeTablePlugin, { locale, messages })` sets them for the whole
|
|
198
|
+
application. Arrow keys and chevrons mirror in right-to-left layouts.
|
|
157
199
|
|
|
158
200
|
## Development
|
|
159
201
|
|
|
160
202
|
```bash
|
|
161
203
|
pnpm install
|
|
162
204
|
pnpm playground # every layer, side by side
|
|
205
|
+
pnpm docs:dev # the documentation site
|
|
163
206
|
pnpm test # every Vitest project
|
|
164
207
|
pnpm check # format, lint, types, tests with coverage, build, boundaries, packages
|
|
208
|
+
pnpm docs:sync # sync current-release copy and the npm README from the package version
|
|
165
209
|
```
|
|
166
210
|
|
|
167
|
-
Architecture lives in [ARCHITECTURE.md](
|
|
168
|
-
[docs/adr](
|
|
211
|
+
Architecture lives in [ARCHITECTURE.md](https://github.com/boussadjra/vueye-table/blob/main/ARCHITECTURE.md) and decisions in
|
|
212
|
+
[docs/adr](https://github.com/boussadjra/vueye-table/blob/main/docs/adr).
|
|
169
213
|
|
|
170
214
|
## License
|
|
171
215
|
|
|
172
|
-
[MIT](
|
|
216
|
+
[MIT](https://github.com/boussadjra/vueye-table/blob/main/LICENSE)
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CellChange, EditResult, RowKey, SortInfo, TableIssue, TableRow, TableState } from "@vueye-table/core";
|
|
2
|
-
import { CellEditorSlotProps, DetailSlotProps, GridCellSlotProps, TableStatusSlotProps } from "@vueye-table/headless";
|
|
2
|
+
import { AggregateSlotProps, CellEditorSlotProps, DetailSlotProps, GridCellSlotProps, GroupSlotProps, TableStatusSlotProps } from "@vueye-table/headless";
|
|
3
3
|
import { DataTableBinding, TableLocaleOptions } from "@vueye-table/vue";
|
|
4
4
|
import { Plugin, PropType, SlotsType, VNode } from "vue";
|
|
5
5
|
export * from "@vueye-table/core";
|
|
@@ -223,6 +223,42 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
223
223
|
readonly type: BooleanConstructor;
|
|
224
224
|
readonly default: false;
|
|
225
225
|
};
|
|
226
|
+
groupable: {
|
|
227
|
+
readonly type: BooleanConstructor;
|
|
228
|
+
readonly default: false;
|
|
229
|
+
};
|
|
230
|
+
rowPinningControls: {
|
|
231
|
+
readonly type: BooleanConstructor;
|
|
232
|
+
readonly default: false;
|
|
233
|
+
};
|
|
234
|
+
grouping: {
|
|
235
|
+
readonly type: PropType<readonly string[] | undefined>;
|
|
236
|
+
readonly default: undefined;
|
|
237
|
+
};
|
|
238
|
+
expandedGroups: {
|
|
239
|
+
readonly type: PropType<TableState["expandedGroups"] | undefined>;
|
|
240
|
+
readonly default: undefined;
|
|
241
|
+
};
|
|
242
|
+
rowPinning: {
|
|
243
|
+
readonly type: PropType<import("@vueye-table/core").RowPinning | undefined>;
|
|
244
|
+
readonly default: undefined;
|
|
245
|
+
};
|
|
246
|
+
resizableColumns: {
|
|
247
|
+
readonly type: BooleanConstructor;
|
|
248
|
+
readonly default: false;
|
|
249
|
+
};
|
|
250
|
+
columnSizing: {
|
|
251
|
+
readonly type: PropType<Readonly<Record<string, number>> | undefined>;
|
|
252
|
+
readonly default: undefined;
|
|
253
|
+
};
|
|
254
|
+
columnPinning: {
|
|
255
|
+
readonly type: PropType<import("@vueye-table/core").ColumnPinning | undefined>;
|
|
256
|
+
readonly default: undefined;
|
|
257
|
+
};
|
|
258
|
+
aggregatePosition: {
|
|
259
|
+
readonly type: PropType<"group" | "footer">;
|
|
260
|
+
readonly default: "group";
|
|
261
|
+
};
|
|
226
262
|
virtual: {
|
|
227
263
|
readonly type: PropType<boolean | import("@vueye-table/headless").ComponentVirtualOptions>;
|
|
228
264
|
readonly default: false;
|
|
@@ -289,6 +325,11 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
289
325
|
export: (_csv: string) => true;
|
|
290
326
|
expand: (_item: unknown, _row: TableRow<unknown>) => true;
|
|
291
327
|
collapse: (_item: unknown, _row: TableRow<unknown>) => true;
|
|
328
|
+
"update:grouping": (_grouping: readonly string[]) => boolean;
|
|
329
|
+
"update:expandedGroups": (_expanded: TableState["expandedGroups"]) => boolean;
|
|
330
|
+
"update:rowPinning": (_pinning: import("@vueye-table/core").RowPinning) => boolean;
|
|
331
|
+
"update:columnSizing": (_sizing: Readonly<Record<string, number>>) => boolean;
|
|
332
|
+
"update:columnPinning": (_pinning: import("@vueye-table/core").ColumnPinning) => boolean;
|
|
292
333
|
"update:page": (_page: number) => boolean;
|
|
293
334
|
"update:pageSize": (_pageSize: number) => boolean;
|
|
294
335
|
"update:sorting": (_sorting: readonly import("@vueye-table/core").SortRule[]) => boolean;
|
|
@@ -501,6 +542,42 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
501
542
|
readonly type: BooleanConstructor;
|
|
502
543
|
readonly default: false;
|
|
503
544
|
};
|
|
545
|
+
groupable: {
|
|
546
|
+
readonly type: BooleanConstructor;
|
|
547
|
+
readonly default: false;
|
|
548
|
+
};
|
|
549
|
+
rowPinningControls: {
|
|
550
|
+
readonly type: BooleanConstructor;
|
|
551
|
+
readonly default: false;
|
|
552
|
+
};
|
|
553
|
+
grouping: {
|
|
554
|
+
readonly type: PropType<readonly string[] | undefined>;
|
|
555
|
+
readonly default: undefined;
|
|
556
|
+
};
|
|
557
|
+
expandedGroups: {
|
|
558
|
+
readonly type: PropType<TableState["expandedGroups"] | undefined>;
|
|
559
|
+
readonly default: undefined;
|
|
560
|
+
};
|
|
561
|
+
rowPinning: {
|
|
562
|
+
readonly type: PropType<import("@vueye-table/core").RowPinning | undefined>;
|
|
563
|
+
readonly default: undefined;
|
|
564
|
+
};
|
|
565
|
+
resizableColumns: {
|
|
566
|
+
readonly type: BooleanConstructor;
|
|
567
|
+
readonly default: false;
|
|
568
|
+
};
|
|
569
|
+
columnSizing: {
|
|
570
|
+
readonly type: PropType<Readonly<Record<string, number>> | undefined>;
|
|
571
|
+
readonly default: undefined;
|
|
572
|
+
};
|
|
573
|
+
columnPinning: {
|
|
574
|
+
readonly type: PropType<import("@vueye-table/core").ColumnPinning | undefined>;
|
|
575
|
+
readonly default: undefined;
|
|
576
|
+
};
|
|
577
|
+
aggregatePosition: {
|
|
578
|
+
readonly type: PropType<"group" | "footer">;
|
|
579
|
+
readonly default: "group";
|
|
580
|
+
};
|
|
504
581
|
virtual: {
|
|
505
582
|
readonly type: PropType<boolean | import("@vueye-table/headless").ComponentVirtualOptions>;
|
|
506
583
|
readonly default: false;
|
|
@@ -562,6 +639,11 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
562
639
|
onExpand?: (_item: unknown, _row: TableRow<unknown>) => any;
|
|
563
640
|
onCollapse?: (_item: unknown, _row: TableRow<unknown>) => any;
|
|
564
641
|
onCancel?: (_key: import("@vueye-table/core").RowKey) => any;
|
|
642
|
+
"onUpdate:grouping"?: (_grouping: readonly string[]) => any;
|
|
643
|
+
"onUpdate:expandedGroups"?: (_expanded: true | readonly string[]) => any;
|
|
644
|
+
"onUpdate:rowPinning"?: (_pinning: import("@vueye-table/core").RowPinning) => any;
|
|
645
|
+
"onUpdate:columnSizing"?: (_sizing: Readonly<Record<string, number>>) => any;
|
|
646
|
+
"onUpdate:columnPinning"?: (_pinning: import("@vueye-table/core").ColumnPinning) => any;
|
|
565
647
|
"onUpdate:page"?: (_page: number) => any;
|
|
566
648
|
"onUpdate:pageSize"?: (_pageSize: number) => any;
|
|
567
649
|
"onUpdate:sorting"?: (_sorting: readonly import("@vueye-table/core").SortRule[]) => any;
|
|
@@ -579,6 +661,8 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
579
661
|
}>, {
|
|
580
662
|
validateRow: ((next: any, previous: any) => import("@vueye-table/core").ValidationResult | Promise<import("@vueye-table/core").ValidationResult>) | undefined;
|
|
581
663
|
setParentKey: ((row: any, parent: import("@vueye-table/core").RowKey | undefined) => any) | undefined;
|
|
664
|
+
expandedGroups: true | readonly string[] | undefined;
|
|
665
|
+
columnSizing: Readonly<Record<string, number>> | undefined;
|
|
582
666
|
getChildren: ((row: any) => readonly any[] | undefined) | undefined;
|
|
583
667
|
setChildren: ((row: any, children: readonly any[]) => any) | undefined;
|
|
584
668
|
getParentKey: ((row: any) => import("@vueye-table/core").RowKey | null | undefined) | undefined;
|
|
@@ -625,6 +709,13 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
625
709
|
selectScope: import("@vueye-table/core").SelectScope;
|
|
626
710
|
treeColumn: string | undefined;
|
|
627
711
|
keepAliveDetail: boolean;
|
|
712
|
+
groupable: boolean;
|
|
713
|
+
rowPinningControls: boolean;
|
|
714
|
+
grouping: readonly string[] | undefined;
|
|
715
|
+
rowPinning: import("@vueye-table/core").RowPinning | undefined;
|
|
716
|
+
resizableColumns: boolean;
|
|
717
|
+
columnPinning: import("@vueye-table/core").ColumnPinning | undefined;
|
|
718
|
+
aggregatePosition: "group" | "footer";
|
|
628
719
|
virtual: boolean | import("@vueye-table/headless").ComponentVirtualOptions;
|
|
629
720
|
height: string | undefined;
|
|
630
721
|
rowHeight: number;
|
|
@@ -645,10 +736,12 @@ declare const VueyeGrid: import("vue").DefineComponent<import("vue").ExtractProp
|
|
|
645
736
|
readonly item: unknown;
|
|
646
737
|
};
|
|
647
738
|
[key: `editor.${string}`]: CellEditorSlotProps;
|
|
739
|
+
[key: `aggregate.${string}`]: AggregateSlotProps;
|
|
648
740
|
} & {
|
|
649
741
|
default?: (props: Record<string, unknown>) => VNode[];
|
|
650
742
|
status?: (props: TableStatusSlotProps) => VNode[];
|
|
651
743
|
expanded?: (props: DetailSlotProps) => VNode[];
|
|
744
|
+
group?: (props: GroupSlotProps) => VNode[];
|
|
652
745
|
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
653
746
|
//#endregion
|
|
654
747
|
//#region src/vueye-table.d.ts
|
|
@@ -885,6 +978,42 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
885
978
|
readonly type: BooleanConstructor;
|
|
886
979
|
readonly default: false;
|
|
887
980
|
};
|
|
981
|
+
groupable: {
|
|
982
|
+
readonly type: BooleanConstructor;
|
|
983
|
+
readonly default: false;
|
|
984
|
+
};
|
|
985
|
+
rowPinningControls: {
|
|
986
|
+
readonly type: BooleanConstructor;
|
|
987
|
+
readonly default: false;
|
|
988
|
+
};
|
|
989
|
+
grouping: {
|
|
990
|
+
readonly type: PropType<readonly string[] | undefined>;
|
|
991
|
+
readonly default: undefined;
|
|
992
|
+
};
|
|
993
|
+
expandedGroups: {
|
|
994
|
+
readonly type: PropType<TableState["expandedGroups"] | undefined>;
|
|
995
|
+
readonly default: undefined;
|
|
996
|
+
};
|
|
997
|
+
rowPinning: {
|
|
998
|
+
readonly type: PropType<import("@vueye-table/core").RowPinning | undefined>;
|
|
999
|
+
readonly default: undefined;
|
|
1000
|
+
};
|
|
1001
|
+
resizableColumns: {
|
|
1002
|
+
readonly type: BooleanConstructor;
|
|
1003
|
+
readonly default: false;
|
|
1004
|
+
};
|
|
1005
|
+
columnSizing: {
|
|
1006
|
+
readonly type: PropType<Readonly<Record<string, number>> | undefined>;
|
|
1007
|
+
readonly default: undefined;
|
|
1008
|
+
};
|
|
1009
|
+
columnPinning: {
|
|
1010
|
+
readonly type: PropType<import("@vueye-table/core").ColumnPinning | undefined>;
|
|
1011
|
+
readonly default: undefined;
|
|
1012
|
+
};
|
|
1013
|
+
aggregatePosition: {
|
|
1014
|
+
readonly type: PropType<"group" | "footer">;
|
|
1015
|
+
readonly default: "group";
|
|
1016
|
+
};
|
|
888
1017
|
virtual: {
|
|
889
1018
|
readonly type: PropType<boolean | import("@vueye-table/headless").ComponentVirtualOptions>;
|
|
890
1019
|
readonly default: false;
|
|
@@ -948,6 +1077,11 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
948
1077
|
"row-click": (_item: unknown, _row: TableRow<unknown>) => true;
|
|
949
1078
|
expand: (_item: unknown, _row: TableRow<unknown>) => true;
|
|
950
1079
|
collapse: (_item: unknown, _row: TableRow<unknown>) => true;
|
|
1080
|
+
"update:grouping": (_grouping: readonly string[]) => boolean;
|
|
1081
|
+
"update:expandedGroups": (_expanded: TableState["expandedGroups"]) => boolean;
|
|
1082
|
+
"update:rowPinning": (_pinning: import("@vueye-table/core").RowPinning) => boolean;
|
|
1083
|
+
"update:columnSizing": (_sizing: Readonly<Record<string, number>>) => boolean;
|
|
1084
|
+
"update:columnPinning": (_pinning: import("@vueye-table/core").ColumnPinning) => boolean;
|
|
951
1085
|
"update:page": (_page: number) => boolean;
|
|
952
1086
|
"update:pageSize": (_pageSize: number) => boolean;
|
|
953
1087
|
"update:sorting": (_sorting: readonly import("@vueye-table/core").SortRule[]) => boolean;
|
|
@@ -1158,6 +1292,42 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1158
1292
|
readonly type: BooleanConstructor;
|
|
1159
1293
|
readonly default: false;
|
|
1160
1294
|
};
|
|
1295
|
+
groupable: {
|
|
1296
|
+
readonly type: BooleanConstructor;
|
|
1297
|
+
readonly default: false;
|
|
1298
|
+
};
|
|
1299
|
+
rowPinningControls: {
|
|
1300
|
+
readonly type: BooleanConstructor;
|
|
1301
|
+
readonly default: false;
|
|
1302
|
+
};
|
|
1303
|
+
grouping: {
|
|
1304
|
+
readonly type: PropType<readonly string[] | undefined>;
|
|
1305
|
+
readonly default: undefined;
|
|
1306
|
+
};
|
|
1307
|
+
expandedGroups: {
|
|
1308
|
+
readonly type: PropType<TableState["expandedGroups"] | undefined>;
|
|
1309
|
+
readonly default: undefined;
|
|
1310
|
+
};
|
|
1311
|
+
rowPinning: {
|
|
1312
|
+
readonly type: PropType<import("@vueye-table/core").RowPinning | undefined>;
|
|
1313
|
+
readonly default: undefined;
|
|
1314
|
+
};
|
|
1315
|
+
resizableColumns: {
|
|
1316
|
+
readonly type: BooleanConstructor;
|
|
1317
|
+
readonly default: false;
|
|
1318
|
+
};
|
|
1319
|
+
columnSizing: {
|
|
1320
|
+
readonly type: PropType<Readonly<Record<string, number>> | undefined>;
|
|
1321
|
+
readonly default: undefined;
|
|
1322
|
+
};
|
|
1323
|
+
columnPinning: {
|
|
1324
|
+
readonly type: PropType<import("@vueye-table/core").ColumnPinning | undefined>;
|
|
1325
|
+
readonly default: undefined;
|
|
1326
|
+
};
|
|
1327
|
+
aggregatePosition: {
|
|
1328
|
+
readonly type: PropType<"group" | "footer">;
|
|
1329
|
+
readonly default: "group";
|
|
1330
|
+
};
|
|
1161
1331
|
virtual: {
|
|
1162
1332
|
readonly type: PropType<boolean | import("@vueye-table/headless").ComponentVirtualOptions>;
|
|
1163
1333
|
readonly default: false;
|
|
@@ -1220,6 +1390,11 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1220
1390
|
onExpand?: (_item: unknown, _row: TableRow<unknown>) => any;
|
|
1221
1391
|
onCollapse?: (_item: unknown, _row: TableRow<unknown>) => any;
|
|
1222
1392
|
onCancel?: (_key: RowKey) => any;
|
|
1393
|
+
"onUpdate:grouping"?: (_grouping: readonly string[]) => any;
|
|
1394
|
+
"onUpdate:expandedGroups"?: (_expanded: true | readonly string[]) => any;
|
|
1395
|
+
"onUpdate:rowPinning"?: (_pinning: import("@vueye-table/core").RowPinning) => any;
|
|
1396
|
+
"onUpdate:columnSizing"?: (_sizing: Readonly<Record<string, number>>) => any;
|
|
1397
|
+
"onUpdate:columnPinning"?: (_pinning: import("@vueye-table/core").ColumnPinning) => any;
|
|
1223
1398
|
"onUpdate:page"?: (_page: number) => any;
|
|
1224
1399
|
"onUpdate:pageSize"?: (_pageSize: number) => any;
|
|
1225
1400
|
"onUpdate:sorting"?: (_sorting: readonly import("@vueye-table/core").SortRule[]) => any;
|
|
@@ -1236,6 +1411,8 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1236
1411
|
}>, {
|
|
1237
1412
|
validateRow: ((next: any, previous: any) => import("@vueye-table/core").ValidationResult | Promise<import("@vueye-table/core").ValidationResult>) | undefined;
|
|
1238
1413
|
setParentKey: ((row: any, parent: RowKey | undefined) => any) | undefined;
|
|
1414
|
+
expandedGroups: true | readonly string[] | undefined;
|
|
1415
|
+
columnSizing: Readonly<Record<string, number>> | undefined;
|
|
1239
1416
|
getChildren: ((row: any) => readonly any[] | undefined) | undefined;
|
|
1240
1417
|
setChildren: ((row: any, children: readonly any[]) => any) | undefined;
|
|
1241
1418
|
getParentKey: ((row: any) => RowKey | null | undefined) | undefined;
|
|
@@ -1286,6 +1463,13 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1286
1463
|
selectScope: import("@vueye-table/core").SelectScope;
|
|
1287
1464
|
treeColumn: string | undefined;
|
|
1288
1465
|
keepAliveDetail: boolean;
|
|
1466
|
+
groupable: boolean;
|
|
1467
|
+
rowPinningControls: boolean;
|
|
1468
|
+
grouping: readonly string[] | undefined;
|
|
1469
|
+
rowPinning: import("@vueye-table/core").RowPinning | undefined;
|
|
1470
|
+
resizableColumns: boolean;
|
|
1471
|
+
columnPinning: import("@vueye-table/core").ColumnPinning | undefined;
|
|
1472
|
+
aggregatePosition: "group" | "footer";
|
|
1289
1473
|
virtual: boolean | import("@vueye-table/headless").ComponentVirtualOptions;
|
|
1290
1474
|
height: string | undefined;
|
|
1291
1475
|
rowHeight: number;
|
|
@@ -1300,6 +1484,7 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1300
1484
|
[key: `cell.${string}`]: CellSlotProps;
|
|
1301
1485
|
[key: `editor.${string}`]: CellEditorSlotProps;
|
|
1302
1486
|
[key: `header.${string}`]: HeaderSlotProps;
|
|
1487
|
+
[key: `aggregate.${string}`]: AggregateSlotProps;
|
|
1303
1488
|
} & {
|
|
1304
1489
|
toolbar: {
|
|
1305
1490
|
table: unknown;
|
|
@@ -1311,6 +1496,7 @@ declare const VueyeTable: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
1311
1496
|
};
|
|
1312
1497
|
status: StatusSlotProps;
|
|
1313
1498
|
expanded: DetailSlotProps;
|
|
1499
|
+
group: GroupSlotProps;
|
|
1314
1500
|
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
1315
1501
|
//#endregion
|
|
1316
1502
|
//#region src/index.d.ts
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/plugin.ts","../src/vueye-grid.ts","../src/vueye-table.ts","../src/index.ts"],"mappings":";;;;;;;;;;KAOY,0BAA0B;;;;;cAMzB,kBAAkB,QAAQ;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/plugin.ts","../src/vueye-grid.ts","../src/vueye-table.ts","../src/index.ts"],"mappings":";;;;;;;;;;KAOY,0BAA0B;;;;;cAMzB,kBAAkB,QAAQ;;;;;;;;;cCyC1B,yBAAS,8BAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA0BO,MAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAXF,MAAA;;;;;;EAkBE,iBAAA,QAAA;EACF,gBAAA;EACN,OAAA,mBAAS;EACF,eAAA,kBAAS;EAClB,SAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAXR,MAAA;;;;;;EAgBE,iBAAA,QAAA;EACJ,cAAA,gBAAO,MAAQ;EACpB,SAAA,gBAAO,MAAQ;EACb,WAAA,gBAAO,MAAQ;;;;;;;;;;;;;;;;;;;;;;IAjBL,MAAA;;;;;IAGC,MAAA;;;;IAGF,MAAA,kBAAkB;;;;;;IAGd,MAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAXR,MAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BZ;IAAE;;EACJ,OAAA;EACE,SAAA;EACD;IAAE;;EACF,QAAA;EACE,UAAA;EACH,OAAA;kCA8YX;;;;YChhBiB;IACf,mBAAmB;IACnB,kBAAkB"}
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { inferColumns } from "@vueye-table/core";
|
|
2
|
-
import { DataTableBody, DataTableCaption, DataTableCell, DataTableEditCell, DataTableEditRoot, DataTableRoot, DataTableRow, DataTableSelectAll, DataTableSelectRow, DataTableViewport, hierarchyProps, resolveTreeColumn, rowAttributes, virtualProps } from "@vueye-table/headless";
|
|
3
|
-
import { VtColumnVisibility, VtEmpty, VtExpandToggle, VtGrid, VtHeader, VtLoadMore, VtPageSize, VtPagination, VtRowActions, VtSearch, VtStatus, VtToolbar, VtTreeCell } from "@vueye-table/styled";
|
|
2
|
+
import { DataTableBody, DataTableCaption, DataTableCell, DataTableEditCell, DataTableEditRoot, DataTableLeadingCell, DataTableRoot, DataTableRow, DataTableSelectAll, DataTableSelectRow, DataTableViewport, DataTableVirtualColumns, groupingProps, hierarchyProps, resolveTreeColumn, rowAttributes, virtualProps } from "@vueye-table/headless";
|
|
3
|
+
import { VtColumnVisibility, VtEmpty, VtExpandToggle, VtGrid, VtGroupBy, VtHeader, VtLoadMore, VtPageSize, VtPagination, VtRowActions, VtSearch, VtStatus, VtToolbar, VtTreeCell } from "@vueye-table/styled";
|
|
4
4
|
import { provideDataTable, provideTableLocale, tableLocaleKey, useDataTable, useTableLocale } from "@vueye-table/vue";
|
|
5
5
|
import { computed, defineComponent, h, mergeProps } from "vue";
|
|
6
6
|
|
|
@@ -88,6 +88,39 @@ const commonProps = {
|
|
|
88
88
|
default: false
|
|
89
89
|
},
|
|
90
90
|
...virtualProps,
|
|
91
|
+
...groupingProps,
|
|
92
|
+
groupable: {
|
|
93
|
+
type: Boolean,
|
|
94
|
+
default: false
|
|
95
|
+
},
|
|
96
|
+
rowPinningControls: {
|
|
97
|
+
type: Boolean,
|
|
98
|
+
default: false
|
|
99
|
+
},
|
|
100
|
+
grouping: {
|
|
101
|
+
type: Array,
|
|
102
|
+
default: void 0
|
|
103
|
+
},
|
|
104
|
+
expandedGroups: {
|
|
105
|
+
type: [Boolean, Array],
|
|
106
|
+
default: void 0
|
|
107
|
+
},
|
|
108
|
+
rowPinning: {
|
|
109
|
+
type: Object,
|
|
110
|
+
default: void 0
|
|
111
|
+
},
|
|
112
|
+
resizableColumns: {
|
|
113
|
+
type: Boolean,
|
|
114
|
+
default: false
|
|
115
|
+
},
|
|
116
|
+
columnSizing: {
|
|
117
|
+
type: Object,
|
|
118
|
+
default: void 0
|
|
119
|
+
},
|
|
120
|
+
columnPinning: {
|
|
121
|
+
type: Object,
|
|
122
|
+
default: void 0
|
|
123
|
+
},
|
|
91
124
|
...hierarchyProps,
|
|
92
125
|
rowCanExpand: {
|
|
93
126
|
type: Function,
|
|
@@ -301,6 +334,11 @@ function editingOptions(props) {
|
|
|
301
334
|
}
|
|
302
335
|
/** The `v-model` events of table state, typed by the value each carries. */
|
|
303
336
|
const stateEmitValidators = {
|
|
337
|
+
"update:grouping": (_grouping) => true,
|
|
338
|
+
"update:expandedGroups": (_expanded) => true,
|
|
339
|
+
"update:rowPinning": (_pinning) => true,
|
|
340
|
+
"update:columnSizing": (_sizing) => true,
|
|
341
|
+
"update:columnPinning": (_pinning) => true,
|
|
304
342
|
"update:page": (_page) => true,
|
|
305
343
|
"update:pageSize": (_pageSize) => true,
|
|
306
344
|
"update:sorting": (_sorting) => true,
|
|
@@ -314,6 +352,11 @@ const stateEmits = Object.keys(stateEmitValidators);
|
|
|
314
352
|
/** The state a parent controls through `v-model`, as a table state patch. */
|
|
315
353
|
function controlledState(props, current) {
|
|
316
354
|
return {
|
|
355
|
+
grouping: props.grouping,
|
|
356
|
+
expandedGroups: props.expandedGroups,
|
|
357
|
+
rowPinning: props.rowPinning,
|
|
358
|
+
columnSizing: props.columnSizing,
|
|
359
|
+
columnPinning: props.columnPinning,
|
|
317
360
|
sorting: props.sorting,
|
|
318
361
|
search: props.search,
|
|
319
362
|
filters: props.filters,
|
|
@@ -331,6 +374,11 @@ function controlledState(props, current) {
|
|
|
331
374
|
* piece by piece, so identity tells what changed.
|
|
332
375
|
*/
|
|
333
376
|
function emitStateChanges(emit, state, previous) {
|
|
377
|
+
if (state.grouping !== previous.grouping) emit("update:grouping", state.grouping);
|
|
378
|
+
if (state.expandedGroups !== previous.expandedGroups) emit("update:expandedGroups", state.expandedGroups);
|
|
379
|
+
if (state.rowPinning !== previous.rowPinning) emit("update:rowPinning", state.rowPinning);
|
|
380
|
+
if (state.columnSizing !== previous.columnSizing) emit("update:columnSizing", state.columnSizing);
|
|
381
|
+
if (state.columnPinning !== previous.columnPinning) emit("update:columnPinning", state.columnPinning);
|
|
334
382
|
if (state.pagination.page !== previous.pagination.page) emit("update:page", state.pagination.page);
|
|
335
383
|
if (state.pagination.pageSize !== previous.pagination.pageSize) emit("update:pageSize", state.pagination.pageSize);
|
|
336
384
|
if (state.sorting !== previous.sorting) emit("update:sorting", state.sorting);
|
|
@@ -528,7 +576,7 @@ const VueyeGrid = defineComponent({
|
|
|
528
576
|
const gridSlots = () => {
|
|
529
577
|
const forwarded = {};
|
|
530
578
|
if (slots.expanded) forwarded["expanded"] = slots.expanded;
|
|
531
|
-
for (const [name, slot] of Object.entries(slots)) if (name === "default" && slot) forwarded[name] = slot;
|
|
579
|
+
for (const [name, slot] of Object.entries(slots)) if ((name === "default" || name === "group" || name.startsWith("aggregate.")) && slot) forwarded[name] = slot;
|
|
532
580
|
else if (name.startsWith("cell.")) {
|
|
533
581
|
const cellSlot = slots[name];
|
|
534
582
|
forwarded[name] = (cellProps) => cellSlot ? h(CellContent, {
|
|
@@ -548,12 +596,13 @@ const VueyeGrid = defineComponent({
|
|
|
548
596
|
class: "vt-theme vueye-grid",
|
|
549
597
|
"data-vt-theme": props.theme
|
|
550
598
|
}, [
|
|
551
|
-
props.toolbar || props.searchable || props.addRow ? h(VtToolbar, () => [
|
|
599
|
+
props.toolbar || props.searchable || props.addRow || props.groupable ? h(VtToolbar, () => [
|
|
552
600
|
props.searchable ? h(VtSearch, { placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder }) : null,
|
|
553
601
|
props.addRow ? button(locale().messages.addRow, false, () => {
|
|
554
602
|
table.insertRows();
|
|
555
603
|
}) : null,
|
|
556
604
|
h("div", { class: "vt-toolbar-spacer" }),
|
|
605
|
+
props.groupable ? h(VtGroupBy) : null,
|
|
557
606
|
props.toolbar ? [
|
|
558
607
|
button(locale().messages.undo, !table.canUndo, () => table.undo()),
|
|
559
608
|
button(locale().messages.redo, !table.canRedo, () => table.redo()),
|
|
@@ -565,8 +614,10 @@ const VueyeGrid = defineComponent({
|
|
|
565
614
|
label: props.label ?? locale().messages.spreadsheet,
|
|
566
615
|
"aria-describedby": attrs["aria-describedby"],
|
|
567
616
|
rowNumbers: props.rowNumbers,
|
|
617
|
+
resizableColumns: props.resizableColumns,
|
|
618
|
+
aggregatePosition: props.aggregatePosition,
|
|
568
619
|
rowAttrs: props.rowAttrs,
|
|
569
|
-
rowActions: props.editable || props.removeRows,
|
|
620
|
+
rowActions: props.editable || props.removeRows || props.rowPinningControls,
|
|
570
621
|
removable: props.removeRows,
|
|
571
622
|
onSave: (result) => emit("save", result),
|
|
572
623
|
onCancel: (key) => emit("cancel", key),
|
|
@@ -722,7 +773,7 @@ const VueyeTable = defineComponent({
|
|
|
722
773
|
});
|
|
723
774
|
};
|
|
724
775
|
const hasDetails = () => !!slots.expanded && !table.tree;
|
|
725
|
-
const hasActions = () => !!props.editMode || props.removeRows;
|
|
776
|
+
const hasActions = () => !!props.editMode || props.removeRows || props.rowPinningControls;
|
|
726
777
|
const leadingColumns = () => Number(hasActions()) + Number(hasDetails()) + Number(selectable());
|
|
727
778
|
const width = () => table.columns.length + (selectable() ? 1 : 0) + (hasDetails() ? 1 : 0) + (hasActions() ? 1 : 0);
|
|
728
779
|
const emptyBody = () => {
|
|
@@ -734,25 +785,28 @@ const VueyeTable = defineComponent({
|
|
|
734
785
|
};
|
|
735
786
|
const cells = (row, rowIndex) => {
|
|
736
787
|
return [
|
|
737
|
-
hasActions() ? h(
|
|
788
|
+
hasActions() ? h(DataTableLeadingCell, {
|
|
738
789
|
class: "vt-row-controls",
|
|
790
|
+
index: 0,
|
|
739
791
|
"aria-colindex": 1,
|
|
740
792
|
onClick: (event) => event.stopPropagation()
|
|
741
|
-
}, [h(VtRowActions, {
|
|
793
|
+
}, { default: () => [h(VtRowActions, {
|
|
742
794
|
row,
|
|
743
795
|
editable: props.editMode === "row",
|
|
744
796
|
removable: props.removeRows
|
|
745
|
-
})]) : null,
|
|
746
|
-
hasDetails() ? h(
|
|
797
|
+
})] }) : null,
|
|
798
|
+
hasDetails() ? h(DataTableLeadingCell, {
|
|
799
|
+
index: Number(hasActions()),
|
|
747
800
|
class: "vt-expansion-cell",
|
|
748
801
|
"aria-colindex": Number(hasActions()) + 1
|
|
749
|
-
}, [h(VtExpandToggle, { row })]) : null,
|
|
750
|
-
selectable() ? h(
|
|
802
|
+
}, { default: () => [h(VtExpandToggle, { row })] }) : null,
|
|
803
|
+
selectable() ? h(DataTableLeadingCell, {
|
|
751
804
|
class: "vt-selection-cell",
|
|
805
|
+
index: Number(hasActions()) + Number(hasDetails()),
|
|
752
806
|
"aria-colindex": Number(hasActions()) + Number(hasDetails()) + 1,
|
|
753
807
|
onClick: (event) => event.stopPropagation()
|
|
754
|
-
}, [h(DataTableSelectRow, { row })]) : null,
|
|
755
|
-
...table.columns.map((column) => cell(row, column, rowIndex))
|
|
808
|
+
}, { default: () => [h(DataTableSelectRow, { row })] }) : null,
|
|
809
|
+
...props.virtual && props.virtualColumns ? [h(DataTableVirtualColumns, { as: "td" }, { default: ({ column }) => cell(row, column, rowIndex) })] : table.columns.map((column) => cell(row, column, rowIndex))
|
|
756
810
|
];
|
|
757
811
|
};
|
|
758
812
|
const bodyRow = ({ row, rowIndex }) => h(DataTableRow, {
|
|
@@ -769,22 +823,28 @@ const VueyeTable = defineComponent({
|
|
|
769
823
|
return {
|
|
770
824
|
header: (header) => slots[`header.${header.column.id}`]?.(header) ?? header.column.header,
|
|
771
825
|
before: () => [
|
|
772
|
-
hasActions() ? h(
|
|
826
|
+
hasActions() ? h(DataTableLeadingCell, {
|
|
827
|
+
as: "th",
|
|
828
|
+
index: 0,
|
|
773
829
|
class: "vt-row-controls",
|
|
774
830
|
scope: "col",
|
|
775
831
|
"aria-colindex": 1
|
|
776
|
-
}, locale().messages.rowActions) : null,
|
|
777
|
-
hasDetails() ? h(
|
|
832
|
+
}, { default: () => locale().messages.rowActions }) : null,
|
|
833
|
+
hasDetails() ? h(DataTableLeadingCell, {
|
|
834
|
+
as: "th",
|
|
835
|
+
index: Number(hasActions()),
|
|
778
836
|
class: "vt-expansion-cell",
|
|
779
837
|
scope: "col",
|
|
780
838
|
"aria-colindex": Number(hasActions()) + 1,
|
|
781
839
|
"aria-label": locale().messages.details
|
|
782
840
|
}) : null,
|
|
783
|
-
selectable() ? h(
|
|
841
|
+
selectable() ? h(DataTableLeadingCell, {
|
|
784
842
|
class: "vt-selection-cell",
|
|
843
|
+
as: "th",
|
|
844
|
+
index: Number(hasActions()) + Number(hasDetails()),
|
|
785
845
|
scope: "col",
|
|
786
846
|
"aria-colindex": Number(hasActions()) + Number(hasDetails()) + 1
|
|
787
|
-
}, selectionMode.value === "multiple" ? [h(DataTableSelectAll)] : []) : null
|
|
847
|
+
}, { default: () => selectionMode.value === "multiple" ? [h(DataTableSelectAll)] : [] }) : null
|
|
788
848
|
]
|
|
789
849
|
};
|
|
790
850
|
};
|
|
@@ -796,7 +856,8 @@ const VueyeTable = defineComponent({
|
|
|
796
856
|
class: "vt-body",
|
|
797
857
|
colspan: width()
|
|
798
858
|
}, {
|
|
799
|
-
...table.
|
|
859
|
+
...table.renderItems.length === 0 && !table.topRows.length && !table.bottomRows.length ? { default: emptyBody } : {},
|
|
860
|
+
...Object.fromEntries(Object.entries(slots).filter(([name]) => name === "group" || name.startsWith("aggregate."))),
|
|
800
861
|
row: bodyRow,
|
|
801
862
|
detail: slots.expanded ? (detail) => slots.expanded?.(detail) : void 0
|
|
802
863
|
})
|
|
@@ -809,7 +870,15 @@ const VueyeTable = defineComponent({
|
|
|
809
870
|
table,
|
|
810
871
|
class: "vt-table",
|
|
811
872
|
leadingColumns: leadingColumns(),
|
|
873
|
+
leadingColumnWidths: [
|
|
874
|
+
...hasActions() ? [120] : [],
|
|
875
|
+
...hasDetails() ? [44] : [],
|
|
876
|
+
...selectable() ? [44] : []
|
|
877
|
+
],
|
|
878
|
+
resizableColumns: props.resizableColumns,
|
|
879
|
+
aggregatePosition: props.aggregatePosition,
|
|
812
880
|
virtual: props.virtual,
|
|
881
|
+
virtualColumns: props.virtualColumns,
|
|
813
882
|
rowHeight: props.rowHeight,
|
|
814
883
|
overscan: props.overscan,
|
|
815
884
|
treeColumn: props.treeColumn,
|
|
@@ -820,6 +889,13 @@ const VueyeTable = defineComponent({
|
|
|
820
889
|
keepAliveDetail: props.keepAliveDetail,
|
|
821
890
|
class: "vt-table",
|
|
822
891
|
leadingColumns: leadingColumns(),
|
|
892
|
+
leadingColumnWidths: [
|
|
893
|
+
...hasActions() ? [120] : [],
|
|
894
|
+
...hasDetails() ? [44] : [],
|
|
895
|
+
...selectable() ? [44] : []
|
|
896
|
+
],
|
|
897
|
+
resizableColumns: props.resizableColumns,
|
|
898
|
+
aggregatePosition: props.aggregatePosition,
|
|
823
899
|
"aria-busy": busy() ? "true" : void 0
|
|
824
900
|
}, children)]);
|
|
825
901
|
};
|
|
@@ -836,7 +912,7 @@ const VueyeTable = defineComponent({
|
|
|
836
912
|
"aria-busy": props.loading ? "true" : void 0,
|
|
837
913
|
style: props.maxHeight ? { "--vt-max-height": props.maxHeight } : void 0
|
|
838
914
|
}), [h("div", { class: "vt-root" }, [
|
|
839
|
-
props.searchable || props.columnToggle || slots.toolbar || props.addRow ? h(VtToolbar, () => [
|
|
915
|
+
props.searchable || props.columnToggle || slots.toolbar || props.addRow || props.groupable ? h(VtToolbar, () => [
|
|
840
916
|
props.searchable ? h(VtSearch, { placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder }) : null,
|
|
841
917
|
props.addRow ? h("button", {
|
|
842
918
|
type: "button",
|
|
@@ -845,7 +921,8 @@ const VueyeTable = defineComponent({
|
|
|
845
921
|
}, locale().messages.addRow) : null,
|
|
846
922
|
h("div", { class: "vt-toolbar-spacer" }),
|
|
847
923
|
slots.toolbar?.({ table }),
|
|
848
|
-
props.columnToggle ? h(VtColumnVisibility) : null
|
|
924
|
+
props.columnToggle ? h(VtColumnVisibility) : null,
|
|
925
|
+
props.groupable ? h(VtGroupBy) : null
|
|
849
926
|
]) : null,
|
|
850
927
|
h("div", {
|
|
851
928
|
class: "vt-progress",
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/shared.ts","../src/vueye-grid.ts","../src/vueye-table.ts","../src/plugin.ts"],"sourcesContent":["import {\n inferColumns,\n type AnyColumnDef,\n type PaginationState,\n type RowKey,\n type SelectScope,\n type SortRule,\n type TableState,\n type TableStatePatch,\n type ExpandedState,\n type ExpandMode,\n type TreeOptions,\n type TableRow,\n type TableColumn,\n type TableOptions,\n type EditResult,\n type TableIssue,\n type CellChange,\n type TableMessages,\n type TextNormalizer,\n} from \"@vueye-table/core\";\nimport { virtualProps } from \"@vueye-table/headless\";\nimport { hierarchyProps, type AnyRowAttrs } from \"@vueye-table/headless\";\nimport type { Density } from \"@vueye-table/styled\";\nimport type { TableSource, LoadMore } from \"@vueye-table/vue\";\nimport { defineComponent, type PropType, type VNodeChild } from \"vue\";\n\ninterface ContentProps {\n readonly item: unknown;\n readonly row: TableRow<unknown>;\n readonly column: TableColumn<unknown>;\n readonly value: unknown;\n readonly display: string;\n readonly editable: boolean;\n}\n/** Isolate application cell slots from unrelated table/grid navigation updates. */\nexport const CellContent = defineComponent({\n name: \"VueyeCellContent\",\n props: {\n row: { type: Object as PropType<TableRow<unknown>>, required: true },\n column: { type: Object as PropType<TableColumn<unknown>>, required: true },\n value: { type: null as unknown as PropType<unknown>, required: true },\n display: { type: String, required: true },\n editable: { type: Boolean, default: false },\n render: { type: Function as PropType<(props: ContentProps) => VNodeChild>, required: true },\n },\n setup(props) {\n return () =>\n props.render({\n item: props.row.original,\n row: props.row,\n column: props.column,\n value: props.value,\n display: props.display,\n editable: props.editable,\n });\n },\n});\n\n/** Props both full components share. */\nexport const commonProps = {\n /**\n * `(item, row) => attributes`: a class, a style, and `data-*` and `aria-*` attributes for each\n * body row, read on every render. The row's own attributes win, and handlers are left out.\n */\n rowAttrs: { type: Function as PropType<AnyRowAttrs | undefined>, default: undefined },\n validateRow: { type: Function as PropType<TableOptions<any>[\"validateRow\"]>, default: undefined },\n asyncValidation: {\n type: String as PropType<\"held\" | \"optimistic\" | undefined>,\n default: undefined,\n },\n createRow: { type: Function as PropType<(() => any) | undefined>, default: undefined },\n setParentKey: {\n type: Function as PropType<TableOptions<any>[\"setParentKey\"]>,\n default: undefined,\n },\n addRow: { type: Boolean, default: false },\n removeRows: { type: Boolean, default: false },\n ...virtualProps,\n ...hierarchyProps,\n rowCanExpand: {\n type: Function as PropType<((row: any) => boolean) | undefined>,\n default: undefined,\n },\n expandMode: { type: String as PropType<ExpandMode>, default: \"multiple\" },\n expanded: { type: [Boolean, Array] as PropType<ExpandedState | undefined>, default: undefined },\n getChildren: { type: Function as PropType<TreeOptions<any>[\"getChildren\"]>, default: undefined },\n setChildren: { type: Function as PropType<TreeOptions<any>[\"setChildren\"]>, default: undefined },\n getParentKey: {\n type: Function as PropType<TreeOptions<any>[\"getParentKey\"]>,\n default: undefined,\n },\n hasChildren: { type: Function as PropType<TreeOptions<any>[\"hasChildren\"]>, default: undefined },\n loadChildren: {\n type: Function as PropType<TreeOptions<any, AbortSignal>[\"loadChildren\"]>,\n default: undefined,\n },\n treeFilter: { type: String as PropType<TreeOptions<unknown>[\"treeFilter\"]>, default: undefined },\n paginateBy: { type: String as PropType<TreeOptions<unknown>[\"paginateBy\"]>, default: undefined },\n source: {\n type: [Object, Function] as PropType<TableSource<unknown> | undefined>,\n default: undefined,\n },\n loadMore: { type: Function as PropType<LoadMore<unknown> | undefined>, default: undefined },\n endThreshold: { type: Number, default: 5 },\n manual: { type: Boolean as PropType<boolean | undefined>, default: undefined },\n rowCount: { type: Number as PropType<number | undefined>, default: undefined },\n /** Override the virtual default of no pagination; permits virtualizing a large page. */\n paginate: { type: Boolean as PropType<boolean | undefined>, default: undefined },\n /** Column definitions. Without them, columns are inferred from the data. */\n columns: { type: Array as PropType<readonly AnyColumnDef[]>, default: undefined },\n /** A path into each row, or a function, giving its key. Defaults to `id`, then position. */\n rowKey: {\n type: [String, Function] as PropType<string | ((row: any, index: number) => RowKey)>,\n default: undefined,\n },\n caption: { type: String, default: undefined },\n loading: { type: Boolean, default: false },\n density: { type: String as PropType<Density>, default: \"comfortable\" },\n striped: { type: Boolean, default: false },\n bordered: { type: Boolean, default: false },\n hover: { type: Boolean, default: true },\n stickyHeader: { type: Boolean, default: false },\n /**\n * `\"light\"` or `\"dark\"` forces a palette; by default the table follows `prefers-color-scheme`.\n * `\"inherit\"` uses no built-in palette: the host declares the `--vt-*` tokens on an ancestor,\n * in its own light and dark themes.\n */\n theme: { type: String as PropType<\"light\" | \"dark\" | \"inherit\">, default: undefined },\n /**\n * The BCP 47 locale numbers are written and text is ordered in, such as `\"fr\"` or `\"ar-DZ\"`.\n * Defaults to the plugin's, then the runtime's. Ordering reads it once, when the table is\n * created; give the table a new `key` to change it.\n */\n locale: { type: String as PropType<string | undefined>, default: undefined },\n /** The host's words for what the table shows and announces, over the plugin's and English. */\n messages: { type: Object as PropType<Partial<TableMessages> | undefined>, default: undefined },\n /**\n * How search and text filters read text. Defaults to `foldText`: case, accents and Arabic\n * letter shapes ignored. Read once, when the table is created.\n */\n normalizeText: { type: Function as PropType<TextNormalizer | undefined>, default: undefined },\n /** A CSS height that makes the body scroll, such as `\"24rem\"`. */\n maxHeight: { type: String, default: undefined },\n\n searchable: { type: Boolean, default: true },\n /** Defaults to the messages' `searchPlaceholder`. */\n searchPlaceholder: { type: String as PropType<string | undefined>, default: undefined },\n columnToggle: { type: Boolean, default: true },\n pagination: { type: Boolean, default: true },\n pageSizeOptions: { type: Array as PropType<readonly number[]>, default: () => [5, 10, 20, 50] },\n\n page: { type: Number, default: undefined },\n pageSize: { type: Number, default: undefined },\n sorting: { type: Array as PropType<readonly SortRule[]>, default: undefined },\n search: { type: String, default: undefined },\n filters: { type: Object as PropType<Readonly<Record<string, unknown>>>, default: undefined },\n hiddenColumns: { type: Array as PropType<readonly string[]>, default: undefined },\n selectScope: { type: String as PropType<SelectScope>, default: \"all\" },\n} as const;\n\nexport const editingEmits = {\n \"update:data\": (_data: readonly unknown[]) => true,\n edit: (_changes: readonly CellChange<unknown>[]) => true,\n save: (_result: EditResult<unknown>) => true,\n cancel: (_key: RowKey) => true,\n \"edit-issues\": (_issues: readonly TableIssue[]) => true,\n \"edit-error\": (_issues: readonly TableIssue[]) => true,\n};\n\nexport function editingOptions(\n props: Pick<\n TableOptions<unknown>,\n \"validateRow\" | \"asyncValidation\" | \"createRow\" | \"setParentKey\"\n >,\n): Pick<TableOptions<unknown>, \"validateRow\" | \"asyncValidation\" | \"createRow\" | \"setParentKey\"> {\n return {\n validateRow: props.validateRow,\n asyncValidation: props.asyncValidation,\n createRow: props.createRow,\n setParentKey: props.setParentKey,\n };\n}\n\n/** The `v-model` events of table state, typed by the value each carries. */\nexport const stateEmitValidators = {\n \"update:page\": (_page: number) => true,\n \"update:pageSize\": (_pageSize: number) => true,\n \"update:sorting\": (_sorting: readonly SortRule[]) => true,\n \"update:search\": (_search: string) => true,\n \"update:filters\": (_filters: Readonly<Record<string, unknown>>) => true,\n \"update:hiddenColumns\": (_hiddenColumns: readonly string[]) => true,\n \"update:selected\": (_selected: readonly RowKey[]) => true,\n \"update:expanded\": (_expanded: ExpandedState) => true,\n};\n\nexport const stateEmits = Object.keys(\n stateEmitValidators,\n) as readonly (keyof typeof stateEmitValidators)[];\n\ninterface ControlledProps {\n readonly page: number | undefined;\n readonly pageSize: number | undefined;\n readonly sorting: readonly SortRule[] | undefined;\n readonly search: string | undefined;\n readonly filters: Readonly<Record<string, unknown>> | undefined;\n readonly hiddenColumns: readonly string[] | undefined;\n readonly selected?: readonly RowKey[] | undefined;\n readonly expanded?: ExpandedState | undefined;\n}\n\n/** The state a parent controls through `v-model`, as a table state patch. */\nexport function controlledState(props: ControlledProps, current: PaginationState): TableStatePatch {\n return {\n sorting: props.sorting,\n search: props.search,\n filters: props.filters,\n hiddenColumns: props.hiddenColumns,\n selection: props.selected,\n expanded: props.expanded,\n pagination:\n props.page !== undefined || props.pageSize !== undefined\n ? { page: props.page ?? current.page, pageSize: props.pageSize ?? current.pageSize }\n : undefined,\n };\n}\n\n/**\n * Emit a `v-model` update for each piece of state that changed. The state is frozen and replaced\n * piece by piece, so identity tells what changed.\n */\nexport function emitStateChanges(\n emit: (event: (typeof stateEmits)[number], value: unknown) => void,\n state: TableState,\n previous: TableState,\n): void {\n if (state.pagination.page !== previous.pagination.page) {\n emit(\"update:page\", state.pagination.page);\n }\n if (state.pagination.pageSize !== previous.pagination.pageSize) {\n emit(\"update:pageSize\", state.pagination.pageSize);\n }\n if (state.sorting !== previous.sorting) {\n emit(\"update:sorting\", state.sorting);\n }\n if (state.search !== previous.search) {\n emit(\"update:search\", state.search);\n }\n if (state.filters !== previous.filters) {\n emit(\"update:filters\", state.filters);\n }\n if (state.hiddenColumns !== previous.hiddenColumns) {\n emit(\"update:hiddenColumns\", state.hiddenColumns);\n }\n if (state.selection !== previous.selection) {\n emit(\"update:selected\", state.selection);\n }\n if (state.expanded !== previous.expanded) emit(\"update:expanded\", state.expanded);\n}\n\nexport function expansionOptions(\n props: {\n readonly rowCanExpand: ((row: any) => boolean) | undefined;\n readonly expandMode: ExpandMode;\n } & TreeOptions<unknown, AbortSignal>,\n detail: boolean,\n): Omit<TreeOptions<unknown, AbortSignal>, \"treeFilter\"> & {\n readonly treeFilter: () => TreeOptions<unknown>[\"treeFilter\"];\n readonly getRowCanExpand: ((row: unknown) => boolean) | undefined;\n readonly expandMode: ExpandMode;\n} {\n return {\n getRowCanExpand: props.rowCanExpand ?? (detail ? () => true : undefined),\n expandMode: props.expandMode,\n getChildren: props.getChildren,\n setChildren: props.setChildren,\n getParentKey: props.getParentKey,\n hasChildren: props.hasChildren,\n loadChildren: props.loadChildren,\n treeFilter: () => props.treeFilter,\n paginateBy: props.paginateBy,\n };\n}\n\nexport function emitExpansionChanges(\n emit: {\n (event: \"expand\", item: unknown, row: TableRow<unknown>): void;\n (event: \"collapse\", item: unknown, row: TableRow<unknown>): void;\n },\n state: TableState,\n previous: TableState,\n table:\n | {\n readonly processedRows: readonly TableRow<unknown>[];\n getRow(key: RowKey): TableRow<unknown> | undefined;\n }\n | undefined,\n): void {\n if (!table || state.expanded === previous.expanded) return;\n const keys = new Set([\n ...table.processedRows.map((row) => row.key),\n ...(state.expanded === true ? [] : state.expanded),\n ...(previous.expanded === true ? [] : previous.expanded),\n ]);\n for (const key of keys) {\n const before = previous.expanded === true || previous.expanded.includes(key);\n const after = state.expanded === true || state.expanded.includes(key);\n const row = table.getRow(key);\n if (row?.canExpand && before !== after) {\n if (after) emit(\"expand\", row.original, row);\n else emit(\"collapse\", row.original, row);\n }\n }\n}\n\n/**\n * The given columns, or columns inferred from the data. Inferred columns are reused while the\n * data keeps the same fields, so an edit that replaces the array does not rebuild every row.\n */\nexport function createColumnResolver(): (\n columns: readonly AnyColumnDef[] | undefined,\n data: readonly unknown[],\n) => readonly AnyColumnDef[] {\n let inferred:\n | { readonly signature: string; readonly columns: readonly AnyColumnDef[] }\n | undefined;\n return (columns, data) => {\n if (columns) {\n return columns;\n }\n const next = inferColumns(data);\n const signature = next.map((column) => column.id).join(\"\\u0000\");\n if (inferred?.signature !== signature) {\n inferred = { signature, columns: next };\n }\n return inferred.columns;\n };\n}\n","import type {\n CellChange,\n ColumnDef,\n TableIssue,\n TableState,\n TableRow,\n EditResult,\n} from \"@vueye-table/core\";\nimport type {\n GridCellSlotProps,\n TableStatusSlotProps,\n DetailSlotProps,\n CellEditorSlotProps,\n} from \"@vueye-table/headless\";\nimport {\n VtGrid,\n VtPageSize,\n VtPagination,\n VtSearch,\n VtStatus,\n VtLoadMore,\n VtToolbar,\n} from \"@vueye-table/styled\";\nimport {\n provideDataTable,\n provideTableLocale,\n useDataTable,\n useTableLocale,\n type DataTableBinding,\n} from \"@vueye-table/vue\";\nimport { computed, defineComponent, h, type PropType, type SlotsType, type VNode } from \"vue\";\n\nimport {\n commonProps,\n controlledState,\n createColumnResolver,\n emitStateChanges,\n stateEmitValidators,\n expansionOptions,\n emitExpansionChanges,\n CellContent,\n editingOptions,\n editingEmits,\n} from \"./shared\";\n\n/**\n * An editable spreadsheet over an array. Cells are edited in place with the keyboard or a double\n * click, ranges are selected with Shift or by dragging, and copy, cut, paste, clear, undo, and\n * redo work like a spreadsheet application. Every edit produces a new array through\n * `update:data`; the array passed in is never mutated.\n */\nexport const VueyeGrid = defineComponent({\n name: \"VueyeGrid\",\n slots: Object as SlotsType<\n {\n [key: `cell.${string}`]: GridCellSlotProps & { readonly item: unknown };\n [key: `editor.${string}`]: CellEditorSlotProps;\n } & {\n default?: (props: Record<string, unknown>) => VNode[];\n status?: (props: TableStatusSlotProps) => VNode[];\n expanded?: (props: DetailSlotProps) => VNode[];\n }\n >,\n props: {\n data: { type: Array as PropType<readonly unknown[]>, default: () => [] },\n ...commonProps,\n searchable: { type: Boolean, default: false },\n columnToggle: { type: Boolean, default: false },\n /** Page the grid. By default every row is on one page. */\n pagination: { type: Boolean, default: false },\n /** Columns are editable unless their definition says otherwise. Set `false` to lock all. */\n editable: { type: Boolean, default: true },\n rowNumbers: { type: Boolean, default: true },\n columnLetters: { type: Boolean, default: false },\n /** The grid's accessible name. Defaults to the messages' `spreadsheet`. */\n label: { type: String as PropType<string | undefined>, default: undefined },\n /** Show undo, redo, and CSV export buttons. */\n toolbar: { type: Boolean, default: true },\n },\n emits: {\n ...editingEmits,\n ...stateEmitValidators,\n \"state-change\": (_state: TableState) => true,\n \"update:data\": (_data: readonly unknown[]) => true,\n edit: (_changes: readonly CellChange<unknown>[]) => true,\n \"edit-error\": (_issues: readonly TableIssue[]) => true,\n export: (_csv: string) => true,\n expand: (_item: unknown, _row: TableRow<unknown>) => true,\n collapse: (_item: unknown, _row: TableRow<unknown>) => true,\n },\n setup(props, { emit, slots, expose, attrs }) {\n const inherited = useTableLocale();\n const locale = provideTableLocale(() => ({ locale: props.locale, messages: props.messages }));\n const resolveColumns = createColumnResolver();\n let previousColumns:\n | { source: readonly unknown[]; editable: boolean; columns: readonly ColumnDef<unknown>[] }\n | undefined;\n const columns = computed(() => {\n const source = resolveColumns(props.columns, props.data);\n if (previousColumns?.source === source && previousColumns.editable === props.editable)\n return previousColumns.columns;\n const resolved = source.map(\n (column) =>\n ({\n ...column,\n editable: props.editable ? (column.editable ?? true) : false,\n }) as ColumnDef<unknown>,\n );\n previousColumns = { source, editable: props.editable, columns: resolved };\n return resolved;\n });\n const everyRow = (): number => Math.max(1, props.data.length);\n const initialPagination = {\n page: props.page ?? 1,\n pageSize: props.pagination ? (props.pageSize ?? props.pageSizeOptions[0] ?? 10) : everyRow(),\n };\n let binding: DataTableBinding<unknown> | undefined;\n const table = useDataTable<unknown>({\n ...expansionOptions(props, !!slots.expanded),\n ...editingOptions(props),\n data: () => props.data,\n source: computed(() => props.source),\n loadMore: computed(() => props.loadMore),\n endThreshold: props.endThreshold,\n manual: props.manual,\n rowCount: () => props.rowCount,\n columns,\n rowKey: props.rowKey as never,\n locale: props.locale ?? inherited().locale,\n normalizeText: props.normalizeText,\n paginate:\n props.paginate ??\n (props.source || props.loadMore ? false : props.virtual ? props.pagination : true),\n selectionMode: \"none\",\n initialState: { pagination: initialPagination },\n state: () => {\n const controlled = controlledState(\n props,\n binding?.table.getState().pagination ?? initialPagination,\n );\n return {\n ...controlled,\n selection: undefined,\n pagination: props.pagination ? controlled.pagination : { page: 1, pageSize: everyRow() },\n };\n },\n onEditIssues(issues) {\n emit(\"edit-error\", issues);\n emit(\"edit-issues\", issues);\n },\n onDataChange(data, changes) {\n emit(\"update:data\", data);\n emit(\"edit\", changes);\n },\n onStateChange(state, previous) {\n emitStateChanges(emit as never, state, previous);\n emitExpansionChanges(emit, state, previous, binding?.table.getSnapshot());\n emit(\"state-change\", state);\n },\n });\n binding = table;\n provideDataTable(table);\n expose({ table });\n\n // `cell.<id>` slots also receive the row's data as `item`, as they do on `<VueyeTable>`.\n const gridSlots = (): Record<string, unknown> => {\n const forwarded: Record<string, unknown> = {};\n if (slots.expanded) forwarded[\"expanded\"] = slots.expanded;\n for (const [name, slot] of Object.entries(slots)) {\n if (name === \"default\" && slot) {\n forwarded[name] = slot;\n } else if (name.startsWith(\"cell.\")) {\n const cellSlot = slots[name as `cell.${string}`];\n forwarded[name] = (cellProps: GridCellSlotProps) =>\n cellSlot ? h(CellContent, { ...cellProps, render: cellSlot }) : cellProps.display;\n } else if (name.startsWith(\"editor.\")) {\n forwarded[name] = slot;\n }\n }\n return forwarded;\n };\n\n const button = (label: string, disabled: boolean, onClick: () => void) =>\n h(\"button\", { type: \"button\", class: \"vt-button\", disabled, onClick }, label);\n\n return () =>\n h(\"div\", { class: \"vt-theme vueye-grid\", \"data-vt-theme\": props.theme }, [\n props.toolbar || props.searchable || props.addRow\n ? h(VtToolbar, () => [\n props.searchable\n ? h(VtSearch, {\n placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder,\n })\n : null,\n props.addRow\n ? button(locale().messages.addRow, false, () => {\n table.insertRows();\n })\n : null,\n h(\"div\", { class: \"vt-toolbar-spacer\" }),\n props.toolbar\n ? [\n button(locale().messages.undo, !table.canUndo, () => table.undo()),\n button(locale().messages.redo, !table.canRedo, () => table.redo()),\n button(locale().messages.exportCsv, false, () =>\n emit(\"export\", table.exportRows()),\n ),\n ]\n : null,\n ])\n : null,\n h(\n VtGrid,\n {\n table,\n label: props.label ?? locale().messages.spreadsheet,\n \"aria-describedby\": attrs[\"aria-describedby\"],\n rowNumbers: props.rowNumbers,\n rowAttrs: props.rowAttrs,\n rowActions: props.editable || props.removeRows,\n removable: props.removeRows,\n onSave: (result: unknown) => emit(\"save\", result as EditResult<unknown>),\n onCancel: (key: unknown) => emit(\"cancel\", key as string | number),\n columnLetters: props.columnLetters,\n density: props.density,\n striped: props.striped,\n bordered: props.bordered,\n hover: false,\n stickyHeader: props.stickyHeader,\n loading:\n props.loading || table.loadState === \"loading\" || table.loadState === \"streaming\",\n theme: props.theme,\n virtual: props.virtual,\n virtualColumns: props.virtualColumns,\n height: props.height,\n rowHeight: props.rowHeight,\n overscan: props.overscan,\n columnWidth: props.columnWidth,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n ...(props.maxHeight ? { style: { \"--vt-max-height\": props.maxHeight } } : {}),\n },\n gridSlots(),\n ),\n props.pagination || table.loadingMode || slots.status || table.tree\n ? h(VtToolbar, { class: \"vt-footer\" }, () => [\n h(\n VtStatus,\n null,\n slots.status\n ? { default: (status: TableStatusSlotProps) => slots.status?.(status) }\n : undefined,\n ),\n ...(table.loadingMode ? [h(VtLoadMore)] : []),\n props.pagination && table.paginate\n ? h(\"div\", { class: \"vt-footer-controls\" }, [\n h(VtPageSize, { options: props.pageSizeOptions }),\n h(VtPagination),\n ])\n : null,\n ])\n : null,\n ]);\n },\n});\n","import type {\n ColumnDef,\n RowKey,\n SortInfo,\n TableRow,\n TableState,\n EditResult,\n} from \"@vueye-table/core\";\nimport {\n DataTableBody,\n DataTableCaption,\n DataTableCell,\n DataTableRow,\n DataTableSelectAll,\n DataTableSelectRow,\n DataTableRoot,\n DataTableViewport,\n type TableStatusSlotProps,\n type DetailSlotProps,\n resolveTreeColumn,\n DataTableEditRoot,\n DataTableEditCell,\n type CellEditorSlotProps,\n rowAttributes,\n} from \"@vueye-table/headless\";\nimport {\n VtColumnVisibility,\n VtEmpty,\n VtHeader,\n VtPageSize,\n VtPagination,\n VtSearch,\n VtStatus,\n VtLoadMore,\n VtToolbar,\n VtExpandToggle,\n VtTreeCell,\n VtRowActions,\n} from \"@vueye-table/styled\";\nimport {\n provideDataTable,\n provideTableLocale,\n useDataTable,\n useTableLocale,\n type DataTableBinding,\n} from \"@vueye-table/vue\";\nimport {\n computed,\n defineComponent,\n h,\n mergeProps,\n type PropType,\n type SlotsType,\n type VNodeChild,\n} from \"vue\";\n\nimport {\n commonProps,\n controlledState,\n createColumnResolver,\n emitStateChanges,\n stateEmitValidators,\n expansionOptions,\n emitExpansionChanges,\n CellContent,\n editingEmits,\n editingOptions,\n} from \"./shared\";\n\n/** Slot props of `cell.<column id>` and `cell`. */\nexport interface CellSlotProps {\n readonly item: unknown;\n readonly row: TableRow<unknown>;\n readonly value: unknown;\n readonly display: string;\n readonly column: { readonly id: string; readonly header: string };\n}\n\n/**\n * What a `<VueyeTable>` exposes on its template ref: the table binding, with every snapshot field\n * and operation. `useTemplateRef<VueyeTableExposed>(\"table\")` reads it typed.\n */\nexport interface VueyeTableExposed {\n readonly table: DataTableBinding<unknown>;\n}\n\n/** Slot props of `status`, the \"1–10 of 57 rows\" line. */\nexport type StatusSlotProps = TableStatusSlotProps;\n\n/**\n * Slot props of `header.<column id>`. The slot fills the header cell; on a sortable column it sits\n * inside the sort button, so the header still sorts on click and shows its indicator.\n */\nexport interface HeaderSlotProps {\n readonly column: { readonly id: string; readonly header: string };\n readonly sort: SortInfo | undefined;\n readonly toggleSort: (multi?: boolean) => void;\n}\n\n/**\n * A complete data table: search, column visibility, sorting, selection, pagination, a live\n * status line, loading and empty states, and theming. Every piece of state is available as a\n * `v-model`, and `manual` hands searching, sorting, and paging to a server.\n */\nexport const VueyeTable = defineComponent({\n name: \"VueyeTable\",\n inheritAttrs: false,\n props: {\n data: { type: Array as PropType<readonly unknown[]>, default: () => [] },\n ...commonProps,\n editMode: { type: String as PropType<\"cell\" | \"row\" | undefined>, default: undefined },\n /** `true` or `\"multiple\"` for checkboxes, `\"single\"` for one row at a time. */\n selectable: {\n type: [Boolean, String] as PropType<boolean | \"single\" | \"multiple\">,\n default: false,\n },\n selected: { type: Array as PropType<readonly RowKey[]>, default: undefined },\n /** The data is one page from a server; `rowCount` is the total. */\n /** Shown instead of the empty state while `loading` and there are no rows yet. */\n loadingText: { type: String as PropType<string | undefined>, default: undefined },\n },\n emits: {\n ...editingEmits,\n ...stateEmitValidators,\n \"state-change\": (_state: TableState) => true,\n \"row-click\": (_item: unknown, _row: TableRow<unknown>) => true,\n expand: (_item: unknown, _row: TableRow<unknown>) => true,\n collapse: (_item: unknown, _row: TableRow<unknown>) => true,\n },\n slots: Object as SlotsType<\n {\n [key: `cell.${string}`]: CellSlotProps;\n [key: `editor.${string}`]: CellEditorSlotProps;\n [key: `header.${string}`]: HeaderSlotProps;\n } & {\n toolbar: { table: unknown };\n empty: Record<string, never>;\n loading: Record<string, never>;\n footer: { table: unknown };\n status: StatusSlotProps;\n expanded: DetailSlotProps;\n }\n >,\n setup(props, { emit, slots, expose, attrs }) {\n const inherited = useTableLocale();\n const locale = provideTableLocale(() => ({ locale: props.locale, messages: props.messages }));\n const loadingText = (): string => props.loadingText ?? locale().messages.loading;\n const selectionMode = computed(() =>\n props.selectable === false ? \"none\" : props.selectable === \"single\" ? \"single\" : \"multiple\",\n );\n const initialPagination = {\n page: props.page ?? 1,\n pageSize: props.pageSize ?? props.pageSizeOptions[0] ?? 10,\n };\n const resolveColumns = createColumnResolver();\n let binding: DataTableBinding<unknown> | undefined;\n const table = useDataTable<unknown>({\n ...expansionOptions(props, !!slots.expanded),\n ...editingOptions(props),\n data: () => props.data,\n source: computed(() => props.source),\n loadMore: computed(() => props.loadMore),\n endThreshold: props.endThreshold,\n columns: () => resolveColumns(props.columns, props.data) as readonly ColumnDef<unknown>[],\n rowKey: props.rowKey as never,\n locale: props.locale ?? inherited().locale,\n normalizeText: props.normalizeText,\n manual: props.manual,\n paginate: props.paginate ?? !(props.virtual || props.source || props.loadMore),\n rowCount: () => props.rowCount,\n selectionMode: selectionMode.value,\n selectScope: props.selectScope,\n initialState: { pagination: initialPagination },\n onDataChange(data, changes) {\n emit(\"update:data\", data);\n emit(\"edit\", changes);\n },\n onEditIssues(issues) {\n emit(\"edit-issues\", issues);\n emit(\"edit-error\", issues);\n },\n state: () =>\n controlledState(props, binding?.table.getState().pagination ?? initialPagination),\n onStateChange(state, previous) {\n emitStateChanges(emit as never, state, previous);\n emitExpansionChanges(emit, state, previous, binding?.table.getSnapshot());\n emit(\"state-change\", state);\n },\n });\n binding = table;\n provideDataTable(table);\n expose({ table } satisfies VueyeTableExposed);\n const busy = (): boolean =>\n props.loading || table.loadState === \"loading\" || table.loadState === \"streaming\";\n\n const selectable = (): boolean => selectionMode.value !== \"none\";\n\n const cell = (\n row: TableRow<unknown>,\n column: (typeof table.columns)[number],\n rowIndex: number,\n ): VNodeChild => {\n const slot = slots[`cell.${column.id}`];\n const treeCell = table.tree && column.id === resolveTreeColumn(table, props.treeColumn);\n return h(\n props.editMode ? DataTableEditCell : DataTableCell,\n {\n key: column.id,\n row,\n column,\n tree: false,\n ...(props.editMode\n ? {\n rowIndex,\n onSave: (result: EditResult<unknown>) => emit(\"save\", result),\n onCancel: (key: RowKey) => emit(\"cancel\", key),\n }\n : {}),\n },\n {\n editor: slots[`editor.${column.id}`],\n default: ({ value, display }: { value: unknown; display: string }) => {\n const content = () =>\n slot ? h(CellContent, { row, column, value, display, render: slot }) : display;\n return treeCell ? h(VtTreeCell, { row }, { default: content }) : content();\n },\n $stable: true,\n },\n );\n };\n\n const hasDetails = (): boolean => !!slots.expanded && !table.tree;\n const hasActions = (): boolean => !!props.editMode || props.removeRows;\n const leadingColumns = (): number =>\n Number(hasActions()) + Number(hasDetails()) + Number(selectable());\n const width = (): number =>\n table.columns.length +\n (selectable() ? 1 : 0) +\n (hasDetails() ? 1 : 0) +\n (hasActions() ? 1 : 0);\n const emptyBody = (): VNodeChild => {\n if (table.rows.length === 0) {\n // While the first page is loading there is nothing to match yet, so say that instead.\n const content = busy()\n ? (slots.loading?.({}) ?? h(VtEmpty, { text: loadingText() }))\n : (slots.empty?.({}) ??\n h(VtEmpty, {\n text:\n table.loadingMode && table.loadState === \"error\"\n ? locale().messages.couldNotLoadRows\n : locale().messages.noMatchingRows,\n }));\n return h(\"tr\", { \"data-empty\": \"\" }, [h(\"td\", { colspan: Math.max(1, width()) }, content)]);\n }\n return null;\n };\n const cells = (row: TableRow<unknown>, rowIndex: number): VNodeChild[] => {\n const result = [\n hasActions()\n ? h(\n \"td\",\n {\n class: \"vt-row-controls\",\n \"aria-colindex\": 1,\n onClick: (event: Event) => event.stopPropagation(),\n },\n [\n h(VtRowActions, {\n row,\n editable: props.editMode === \"row\",\n removable: props.removeRows,\n }),\n ],\n )\n : null,\n hasDetails()\n ? h(\"td\", { class: \"vt-expansion-cell\", \"aria-colindex\": Number(hasActions()) + 1 }, [\n h(VtExpandToggle, { row }),\n ])\n : null,\n selectable()\n ? h(\n \"td\",\n {\n class: \"vt-selection-cell\",\n \"aria-colindex\": Number(hasActions()) + Number(hasDetails()) + 1,\n onClick: (event: Event) => event.stopPropagation(),\n },\n [h(DataTableSelectRow, { row })],\n )\n : null,\n ...table.columns.map((column) => cell(row, column, rowIndex)),\n ];\n return result;\n };\n const bodyRow = ({ row, rowIndex }: DetailSlotProps): VNodeChild =>\n h(\n DataTableRow,\n {\n key: row.key,\n row,\n rowIndex,\n attributes: rowAttributes(props.rowAttrs, row),\n onClick: () => emit(\"row-click\", row.original, row),\n },\n { default: () => cells(row, rowIndex), $stable: true },\n );\n\n const headerSlots = () => {\n return {\n header: (header: HeaderSlotProps) =>\n slots[`header.${header.column.id}`]?.(header) ?? header.column.header,\n before: () => [\n hasActions()\n ? h(\n \"th\",\n { class: \"vt-row-controls\", scope: \"col\", \"aria-colindex\": 1 },\n locale().messages.rowActions,\n )\n : null,\n hasDetails()\n ? h(\"th\", {\n class: \"vt-expansion-cell\",\n scope: \"col\",\n \"aria-colindex\": Number(hasActions()) + 1,\n \"aria-label\": locale().messages.details,\n })\n : null,\n selectable()\n ? h(\n \"th\",\n {\n class: \"vt-selection-cell\",\n scope: \"col\",\n \"aria-colindex\": Number(hasActions()) + Number(hasDetails()) + 1,\n },\n selectionMode.value === \"multiple\" ? [h(DataTableSelectAll)] : [],\n )\n : null,\n ],\n };\n };\n\n const tableContent = (): VNodeChild => {\n const children = () => [\n props.caption ? h(DataTableCaption, () => props.caption) : null,\n h(VtHeader, null, headerSlots()),\n h(\n DataTableBody,\n { class: \"vt-body\", colspan: width() },\n {\n ...(table.rows.length === 0 ? { default: emptyBody } : {}),\n row: bodyRow,\n detail: slots.expanded\n ? (detail: DetailSlotProps) => slots.expanded?.(detail)\n : undefined,\n },\n ),\n ];\n return props.virtual\n ? h(\n DataTableViewport,\n {\n class: \"vt-scroll\",\n height: props.height ?? \"24rem\",\n style: { \"--vt-row-height\": `${props.rowHeight}px` },\n },\n {\n default: () =>\n h(\n DataTableRoot,\n {\n table,\n class: \"vt-table\",\n leadingColumns: leadingColumns(),\n virtual: props.virtual,\n rowHeight: props.rowHeight,\n overscan: props.overscan,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n },\n children,\n ),\n },\n )\n : h(\"div\", { class: \"vt-scroll\" }, [\n h(\n DataTableRoot,\n {\n table,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n class: \"vt-table\",\n leadingColumns: leadingColumns(),\n \"aria-busy\": busy() ? \"true\" : undefined,\n },\n children,\n ),\n ]);\n };\n\n const surface = () =>\n h(\n \"div\",\n mergeProps(attrs, {\n class: \"vt-surface vueye-table\",\n \"data-density\": props.density,\n \"data-striped\": props.striped ? \"\" : undefined,\n \"data-bordered\": props.bordered ? \"\" : undefined,\n \"data-hover\": props.hover ? \"\" : undefined,\n \"data-sticky-header\": props.stickyHeader || props.virtual ? \"\" : undefined,\n \"data-virtual\": props.virtual ? \"\" : undefined,\n \"data-loading\": busy() ? \"\" : undefined,\n \"data-vt-theme\": props.theme,\n \"aria-busy\": props.loading ? \"true\" : undefined,\n style: props.maxHeight ? { \"--vt-max-height\": props.maxHeight } : undefined,\n }),\n [\n h(\"div\", { class: \"vt-root\" }, [\n props.searchable || props.columnToggle || slots.toolbar || props.addRow\n ? h(VtToolbar, () => [\n props.searchable\n ? h(VtSearch, {\n placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder,\n })\n : null,\n props.addRow\n ? h(\n \"button\",\n { type: \"button\", class: \"vt-button\", onClick: () => table.insertRows() },\n locale().messages.addRow,\n )\n : null,\n h(\"div\", { class: \"vt-toolbar-spacer\" }),\n slots.toolbar?.({ table }),\n props.columnToggle ? h(VtColumnVisibility) : null,\n ])\n : null,\n h(\"div\", { class: \"vt-progress\", role: \"presentation\" }),\n tableContent(),\n (props.pagination && (!props.virtual || table.paginate)) ||\n slots.footer ||\n slots.status ||\n table.tree ||\n table.loadingMode\n ? h(VtToolbar, { class: \"vt-footer\" }, () => [\n h(\n VtStatus,\n null,\n slots.status\n ? { default: (status: StatusSlotProps) => slots.status?.(status) }\n : props.loading && table.rows.length === 0\n ? { default: () => loadingText() }\n : undefined,\n ),\n ...(table.loadingMode ? [h(VtLoadMore)] : []),\n slots.footer?.({ table }),\n props.pagination && table.paginate && (!props.virtual || table.paginate)\n ? h(\"div\", { class: \"vt-footer-controls\" }, [\n h(VtPageSize, { options: props.pageSizeOptions }),\n h(VtPagination),\n ])\n : null,\n ])\n : null,\n ]),\n ],\n );\n return () =>\n props.editMode\n ? h(\n DataTableEditRoot,\n {\n table,\n mode: props.editMode,\n onSave: (result) => emit(\"save\", result),\n onCancel: (key) => emit(\"cancel\", key),\n },\n surface,\n )\n : surface();\n },\n});\n","import { tableLocaleKey, type TableLocaleOptions } from \"@vueye-table/vue\";\nimport type { App, Plugin } from \"vue\";\n\nimport { VueyeGrid } from \"./vueye-grid\";\nimport { VueyeTable } from \"./vueye-table\";\n\n/** Options of `VueyeTablePlugin`: the application's language, which every table speaks. */\nexport type VueyeTablePluginOptions = TableLocaleOptions;\n\n/**\n * Register `<VueyeTable>` and `<VueyeGrid>` globally. A `locale` and `messages` given here are\n * the default of every table in the application; a table's own props win over them.\n */\nexport const VueyeTablePlugin: Plugin<[VueyeTablePluginOptions?]> = {\n install(app: App, options?: VueyeTablePluginOptions): void {\n app.component(\"VueyeTable\", VueyeTable);\n app.component(\"VueyeGrid\", VueyeGrid);\n if (options?.locale !== undefined || options?.messages !== undefined) {\n const language: TableLocaleOptions = { locale: options.locale, messages: options.messages };\n app.provide(tableLocaleKey, () => language);\n }\n },\n};\n"],"mappings":";;;;;;;;;;;;;;;;AAoCA,MAAa,cAAc,gBAAgB;CACzC,MAAM;CACN,OAAO;EACL,KAAK;G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Q;CAChB;AACF,CAAC;;;;;;;;ACrdD,MAAa,mBAAuD,EAClE,QAAQ,KAAU,SAAyC;CACzD,IAAI,UAAU,cAAc,UAAU;CACtC,IAAI,UAAU,aAAa,SAAS;CACpC,IAAI,SAAS,WAAW,UAAa,SAAS,aAAa,QAAW;EACpE,MAAM,WAA+B;GAAE,QAAQ,QAAQ;GAAQ,UAAU,QAAQ;EAAS;EAC1F,IAAI,QAAQ,sBAAsB,QAAQ;CAC5C;AACF,EACF"}
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/shared.ts","../src/vueye-grid.ts","../src/vueye-table.ts","../src/plugin.ts"],"sourcesContent":["import {\n inferColumns,\n type AnyColumnDef,\n type PaginationState,\n type RowKey,\n type SelectScope,\n type SortRule,\n type TableState,\n type TableStatePatch,\n type ExpandedState,\n type ExpandMode,\n type TreeOptions,\n type TableRow,\n type TableColumn,\n type TableOptions,\n type EditResult,\n type TableIssue,\n type CellChange,\n type TableMessages,\n type TextNormalizer,\n type ColumnPinning,\n type RowPinning,\n} from \"@vueye-table/core\";\nimport { virtualProps, groupingProps } from \"@vueye-table/headless\";\nimport { hierarchyProps, type AnyRowAttrs } from \"@vueye-table/headless\";\nimport type { Density } from \"@vueye-table/styled\";\nimport type { TableSource, LoadMore } from \"@vueye-table/vue\";\nimport { defineComponent, type PropType, type VNodeChild } from \"vue\";\n\ntype ColumnSizing = TableState[\"columnSizing\"];\n\ninterface ContentProps {\n readonly item: unknown;\n readonly row: TableRow<unknown>;\n readonly column: TableColumn<unknown>;\n readonly value: unknown;\n readonly display: string;\n readonly editable: boolean;\n}\n/** Isolate application cell slots from unrelated table/grid navigation updates. */\nexport const CellContent = defineComponent({\n name: \"VueyeCellContent\",\n props: {\n row: { type: Object as PropType<TableRow<unknown>>, required: true },\n column: { type: Object as PropType<TableColumn<unknown>>, required: true },\n value: { type: null as unknown as PropType<unknown>, required: true },\n display: { type: String, required: true },\n editable: { type: Boolean, default: false },\n render: { type: Function as PropType<(props: ContentProps) => VNodeChild>, required: true },\n },\n setup(props) {\n return () =>\n props.render({\n item: props.row.original,\n row: props.row,\n column: props.column,\n value: props.value,\n display: props.display,\n editable: props.editable,\n });\n },\n});\n\n/** Props both full components share. */\nexport const commonProps = {\n /**\n * `(item, row) => attributes`: a class, a style, and `data-*` and `aria-*` attributes for each\n * body row, read on every render. The row's own attributes win, and handlers are left out.\n */\n rowAttrs: { type: Function as PropType<AnyRowAttrs | undefined>, default: undefined },\n validateRow: { type: Function as PropType<TableOptions<any>[\"validateRow\"]>, default: undefined },\n asyncValidation: {\n type: String as PropType<\"held\" | \"optimistic\" | undefined>,\n default: undefined,\n },\n createRow: { type: Function as PropType<(() => any) | undefined>, default: undefined },\n setParentKey: {\n type: Function as PropType<TableOptions<any>[\"setParentKey\"]>,\n default: undefined,\n },\n addRow: { type: Boolean, default: false },\n removeRows: { type: Boolean, default: false },\n ...virtualProps,\n ...groupingProps,\n groupable: { type: Boolean, default: false },\n rowPinningControls: { type: Boolean, default: false },\n grouping: { type: Array as PropType<readonly string[] | undefined>, default: undefined },\n expandedGroups: {\n type: [Boolean, Array] as PropType<TableState[\"expandedGroups\"] | undefined>,\n default: undefined,\n },\n rowPinning: { type: Object as PropType<RowPinning | undefined>, default: undefined },\n resizableColumns: { type: Boolean, default: false },\n columnSizing: { type: Object as PropType<ColumnSizing | undefined>, default: undefined },\n columnPinning: { type: Object as PropType<ColumnPinning | undefined>, default: undefined },\n ...hierarchyProps,\n rowCanExpand: {\n type: Function as PropType<((row: any) => boolean) | undefined>,\n default: undefined,\n },\n expandMode: { type: String as PropType<ExpandMode>, default: \"multiple\" },\n expanded: { type: [Boolean, Array] as PropType<ExpandedState | undefined>, default: undefined },\n getChildren: { type: Function as PropType<TreeOptions<any>[\"getChildren\"]>, default: undefined },\n setChildren: { type: Function as PropType<TreeOptions<any>[\"setChildren\"]>, default: undefined },\n getParentKey: {\n type: Function as PropType<TreeOptions<any>[\"getParentKey\"]>,\n default: undefined,\n },\n hasChildren: { type: Function as PropType<TreeOptions<any>[\"hasChildren\"]>, default: undefined },\n loadChildren: {\n type: Function as PropType<TreeOptions<any, AbortSignal>[\"loadChildren\"]>,\n default: undefined,\n },\n treeFilter: { type: String as PropType<TreeOptions<unknown>[\"treeFilter\"]>, default: undefined },\n paginateBy: { type: String as PropType<TreeOptions<unknown>[\"paginateBy\"]>, default: undefined },\n source: {\n type: [Object, Function] as PropType<TableSource<unknown> | undefined>,\n default: undefined,\n },\n loadMore: { type: Function as PropType<LoadMore<unknown> | undefined>, default: undefined },\n endThreshold: { type: Number, default: 5 },\n manual: { type: Boolean as PropType<boolean | undefined>, default: undefined },\n rowCount: { type: Number as PropType<number | undefined>, default: undefined },\n /** Override the virtual default of no pagination; permits virtualizing a large page. */\n paginate: { type: Boolean as PropType<boolean | undefined>, default: undefined },\n /** Column definitions. Without them, columns are inferred from the data. */\n columns: { type: Array as PropType<readonly AnyColumnDef[]>, default: undefined },\n /** A path into each row, or a function, giving its key. Defaults to `id`, then position. */\n rowKey: {\n type: [String, Function] as PropType<string | ((row: any, index: number) => RowKey)>,\n default: undefined,\n },\n caption: { type: String, default: undefined },\n loading: { type: Boolean, default: false },\n density: { type: String as PropType<Density>, default: \"comfortable\" },\n striped: { type: Boolean, default: false },\n bordered: { type: Boolean, default: false },\n hover: { type: Boolean, default: true },\n stickyHeader: { type: Boolean, default: false },\n /**\n * `\"light\"` or `\"dark\"` forces a palette; by default the table follows `prefers-color-scheme`.\n * `\"inherit\"` uses no built-in palette: the host declares the `--vt-*` tokens on an ancestor,\n * in its own light and dark themes.\n */\n theme: { type: String as PropType<\"light\" | \"dark\" | \"inherit\">, default: undefined },\n /**\n * The BCP 47 locale numbers are written and text is ordered in, such as `\"fr\"` or `\"ar-DZ\"`.\n * Defaults to the plugin's, then the runtime's. Ordering reads it once, when the table is\n * created; give the table a new `key` to change it.\n */\n locale: { type: String as PropType<string | undefined>, default: undefined },\n /** The host's words for what the table shows and announces, over the plugin's and English. */\n messages: { type: Object as PropType<Partial<TableMessages> | undefined>, default: undefined },\n /**\n * How search and text filters read text. Defaults to `foldText`: case, accents and Arabic\n * letter shapes ignored. Read once, when the table is created.\n */\n normalizeText: { type: Function as PropType<TextNormalizer | undefined>, default: undefined },\n /** A CSS height that makes the body scroll, such as `\"24rem\"`. */\n maxHeight: { type: String, default: undefined },\n\n searchable: { type: Boolean, default: true },\n /** Defaults to the messages' `searchPlaceholder`. */\n searchPlaceholder: { type: String as PropType<string | undefined>, default: undefined },\n columnToggle: { type: Boolean, default: true },\n pagination: { type: Boolean, default: true },\n pageSizeOptions: { type: Array as PropType<readonly number[]>, default: () => [5, 10, 20, 50] },\n\n page: { type: Number, default: undefined },\n pageSize: { type: Number, default: undefined },\n sorting: { type: Array as PropType<readonly SortRule[]>, default: undefined },\n search: { type: String, default: undefined },\n filters: { type: Object as PropType<Readonly<Record<string, unknown>>>, default: undefined },\n hiddenColumns: { type: Array as PropType<readonly string[]>, default: undefined },\n selectScope: { type: String as PropType<SelectScope>, default: \"all\" },\n} as const;\n\nexport const editingEmits = {\n \"update:data\": (_data: readonly unknown[]) => true,\n edit: (_changes: readonly CellChange<unknown>[]) => true,\n save: (_result: EditResult<unknown>) => true,\n cancel: (_key: RowKey) => true,\n \"edit-issues\": (_issues: readonly TableIssue[]) => true,\n \"edit-error\": (_issues: readonly TableIssue[]) => true,\n};\n\nexport function editingOptions(\n props: Pick<\n TableOptions<unknown>,\n \"validateRow\" | \"asyncValidation\" | \"createRow\" | \"setParentKey\"\n >,\n): Pick<TableOptions<unknown>, \"validateRow\" | \"asyncValidation\" | \"createRow\" | \"setParentKey\"> {\n return {\n validateRow: props.validateRow,\n asyncValidation: props.asyncValidation,\n createRow: props.createRow,\n setParentKey: props.setParentKey,\n };\n}\n\n/** The `v-model` events of table state, typed by the value each carries. */\nexport const stateEmitValidators = {\n \"update:grouping\": (_grouping: readonly string[]) => true,\n \"update:expandedGroups\": (_expanded: TableState[\"expandedGroups\"]) => true,\n \"update:rowPinning\": (_pinning: RowPinning) => true,\n \"update:columnSizing\": (_sizing: ColumnSizing) => true,\n \"update:columnPinning\": (_pinning: ColumnPinning) => true,\n \"update:page\": (_page: number) => true,\n \"update:pageSize\": (_pageSize: number) => true,\n \"update:sorting\": (_sorting: readonly SortRule[]) => true,\n \"update:search\": (_search: string) => true,\n \"update:filters\": (_filters: Readonly<Record<string, unknown>>) => true,\n \"update:hiddenColumns\": (_hiddenColumns: readonly string[]) => true,\n \"update:selected\": (_selected: readonly RowKey[]) => true,\n \"update:expanded\": (_expanded: ExpandedState) => true,\n};\n\nexport const stateEmits = Object.keys(\n stateEmitValidators,\n) as readonly (keyof typeof stateEmitValidators)[];\n\ninterface ControlledProps {\n readonly grouping?: readonly string[] | undefined;\n readonly expandedGroups?: TableState[\"expandedGroups\"] | undefined;\n readonly rowPinning?: RowPinning | undefined;\n readonly columnSizing?: ColumnSizing | undefined;\n readonly columnPinning?: ColumnPinning | undefined;\n readonly page: number | undefined;\n readonly pageSize: number | undefined;\n readonly sorting: readonly SortRule[] | undefined;\n readonly search: string | undefined;\n readonly filters: Readonly<Record<string, unknown>> | undefined;\n readonly hiddenColumns: readonly string[] | undefined;\n readonly selected?: readonly RowKey[] | undefined;\n readonly expanded?: ExpandedState | undefined;\n}\n\n/** The state a parent controls through `v-model`, as a table state patch. */\nexport function controlledState(props: ControlledProps, current: PaginationState): TableStatePatch {\n return {\n grouping: props.grouping,\n expandedGroups: props.expandedGroups,\n rowPinning: props.rowPinning,\n columnSizing: props.columnSizing,\n columnPinning: props.columnPinning,\n sorting: props.sorting,\n search: props.search,\n filters: props.filters,\n hiddenColumns: props.hiddenColumns,\n selection: props.selected,\n expanded: props.expanded,\n pagination:\n props.page !== undefined || props.pageSize !== undefined\n ? { page: props.page ?? current.page, pageSize: props.pageSize ?? current.pageSize }\n : undefined,\n };\n}\n\n/**\n * Emit a `v-model` update for each piece of state that changed. The state is frozen and replaced\n * piece by piece, so identity tells what changed.\n */\nexport function emitStateChanges(\n emit: (event: (typeof stateEmits)[number], value: unknown) => void,\n state: TableState,\n previous: TableState,\n): void {\n if (state.grouping !== previous.grouping) emit(\"update:grouping\", state.grouping);\n if (state.expandedGroups !== previous.expandedGroups)\n emit(\"update:expandedGroups\", state.expandedGroups);\n if (state.rowPinning !== previous.rowPinning) emit(\"update:rowPinning\", state.rowPinning);\n if (state.columnSizing !== previous.columnSizing) emit(\"update:columnSizing\", state.columnSizing);\n if (state.columnPinning !== previous.columnPinning)\n emit(\"update:columnPinning\", state.columnPinning);\n if (state.pagination.page !== previous.pagination.page) {\n emit(\"update:page\", state.pagination.page);\n }\n if (state.pagination.pageSize !== previous.pagination.pageSize) {\n emit(\"update:pageSize\", state.pagination.pageSize);\n }\n if (state.sorting !== previous.sorting) {\n emit(\"update:sorting\", state.sorting);\n }\n if (state.search !== previous.search) {\n emit(\"update:search\", state.search);\n }\n if (state.filters !== previous.filters) {\n emit(\"update:filters\", state.filters);\n }\n if (state.hiddenColumns !== previous.hiddenColumns) {\n emit(\"update:hiddenColumns\", state.hiddenColumns);\n }\n if (state.selection !== previous.selection) {\n emit(\"update:selected\", state.selection);\n }\n if (state.expanded !== previous.expanded) emit(\"update:expanded\", state.expanded);\n}\n\nexport function expansionOptions(\n props: {\n readonly rowCanExpand: ((row: any) => boolean) | undefined;\n readonly expandMode: ExpandMode;\n } & TreeOptions<unknown, AbortSignal>,\n detail: boolean,\n): Omit<TreeOptions<unknown, AbortSignal>, \"treeFilter\"> & {\n readonly treeFilter: () => TreeOptions<unknown>[\"treeFilter\"];\n readonly getRowCanExpand: ((row: unknown) => boolean) | undefined;\n readonly expandMode: ExpandMode;\n} {\n return {\n getRowCanExpand: props.rowCanExpand ?? (detail ? () => true : undefined),\n expandMode: props.expandMode,\n getChildren: props.getChildren,\n setChildren: props.setChildren,\n getParentKey: props.getParentKey,\n hasChildren: props.hasChildren,\n loadChildren: props.loadChildren,\n treeFilter: () => props.treeFilter,\n paginateBy: props.paginateBy,\n };\n}\n\nexport function emitExpansionChanges(\n emit: {\n (event: \"expand\", item: unknown, row: TableRow<unknown>): void;\n (event: \"collapse\", item: unknown, row: TableRow<unknown>): void;\n },\n state: TableState,\n previous: TableState,\n table:\n | {\n readonly processedRows: readonly TableRow<unknown>[];\n getRow(key: RowKey): TableRow<unknown> | undefined;\n }\n | undefined,\n): void {\n if (!table || state.expanded === previous.expanded) return;\n const keys = new Set([\n ...table.processedRows.map((row) => row.key),\n ...(state.expanded === true ? [] : state.expanded),\n ...(previous.expanded === true ? [] : previous.expanded),\n ]);\n for (const key of keys) {\n const before = previous.expanded === true || previous.expanded.includes(key);\n const after = state.expanded === true || state.expanded.includes(key);\n const row = table.getRow(key);\n if (row?.canExpand && before !== after) {\n if (after) emit(\"expand\", row.original, row);\n else emit(\"collapse\", row.original, row);\n }\n }\n}\n\n/**\n * The given columns, or columns inferred from the data. Inferred columns are reused while the\n * data keeps the same fields, so an edit that replaces the array does not rebuild every row.\n */\nexport function createColumnResolver(): (\n columns: readonly AnyColumnDef[] | undefined,\n data: readonly unknown[],\n) => readonly AnyColumnDef[] {\n let inferred:\n | { readonly signature: string; readonly columns: readonly AnyColumnDef[] }\n | undefined;\n return (columns, data) => {\n if (columns) {\n return columns;\n }\n const next = inferColumns(data);\n const signature = next.map((column) => column.id).join(\"\\u0000\");\n if (inferred?.signature !== signature) {\n inferred = { signature, columns: next };\n }\n return inferred.columns;\n };\n}\n","import type {\n CellChange,\n ColumnDef,\n TableIssue,\n TableState,\n TableRow,\n EditResult,\n} from \"@vueye-table/core\";\nimport type {\n GridCellSlotProps,\n TableStatusSlotProps,\n DetailSlotProps,\n CellEditorSlotProps,\n GroupSlotProps,\n AggregateSlotProps,\n} from \"@vueye-table/headless\";\nimport {\n VtGrid,\n VtPageSize,\n VtPagination,\n VtSearch,\n VtStatus,\n VtLoadMore,\n VtToolbar,\n VtGroupBy,\n} from \"@vueye-table/styled\";\nimport {\n provideDataTable,\n provideTableLocale,\n useDataTable,\n useTableLocale,\n type DataTableBinding,\n} from \"@vueye-table/vue\";\nimport { computed, defineComponent, h, type PropType, type SlotsType, type VNode } from \"vue\";\n\nimport {\n commonProps,\n controlledState,\n createColumnResolver,\n emitStateChanges,\n stateEmitValidators,\n expansionOptions,\n emitExpansionChanges,\n CellContent,\n editingOptions,\n editingEmits,\n} from \"./shared\";\n\n/**\n * An editable spreadsheet over an array. Cells are edited in place with the keyboard or a double\n * click, ranges are selected with Shift or by dragging, and copy, cut, paste, clear, undo, and\n * redo work like a spreadsheet application. Every edit produces a new array through\n * `update:data`; the array passed in is never mutated.\n */\nexport const VueyeGrid = defineComponent({\n name: \"VueyeGrid\",\n slots: Object as SlotsType<\n {\n [key: `cell.${string}`]: GridCellSlotProps & { readonly item: unknown };\n [key: `editor.${string}`]: CellEditorSlotProps;\n [key: `aggregate.${string}`]: AggregateSlotProps;\n } & {\n default?: (props: Record<string, unknown>) => VNode[];\n status?: (props: TableStatusSlotProps) => VNode[];\n expanded?: (props: DetailSlotProps) => VNode[];\n group?: (props: GroupSlotProps) => VNode[];\n }\n >,\n props: {\n data: { type: Array as PropType<readonly unknown[]>, default: () => [] },\n ...commonProps,\n searchable: { type: Boolean, default: false },\n columnToggle: { type: Boolean, default: false },\n /** Page the grid. By default every row is on one page. */\n pagination: { type: Boolean, default: false },\n /** Columns are editable unless their definition says otherwise. Set `false` to lock all. */\n editable: { type: Boolean, default: true },\n rowNumbers: { type: Boolean, default: true },\n columnLetters: { type: Boolean, default: false },\n /** The grid's accessible name. Defaults to the messages' `spreadsheet`. */\n label: { type: String as PropType<string | undefined>, default: undefined },\n /** Show undo, redo, and CSV export buttons. */\n toolbar: { type: Boolean, default: true },\n },\n emits: {\n ...editingEmits,\n ...stateEmitValidators,\n \"state-change\": (_state: TableState) => true,\n \"update:data\": (_data: readonly unknown[]) => true,\n edit: (_changes: readonly CellChange<unknown>[]) => true,\n \"edit-error\": (_issues: readonly TableIssue[]) => true,\n export: (_csv: string) => true,\n expand: (_item: unknown, _row: TableRow<unknown>) => true,\n collapse: (_item: unknown, _row: TableRow<unknown>) => true,\n },\n setup(props, { emit, slots, expose, attrs }) {\n const inherited = useTableLocale();\n const locale = provideTableLocale(() => ({ locale: props.locale, messages: props.messages }));\n const resolveColumns = createColumnResolver();\n let previousColumns:\n | { source: readonly unknown[]; editable: boolean; columns: readonly ColumnDef<unknown>[] }\n | undefined;\n const columns = computed(() => {\n const source = resolveColumns(props.columns, props.data);\n if (previousColumns?.source === source && previousColumns.editable === props.editable)\n return previousColumns.columns;\n const resolved = source.map(\n (column) =>\n ({\n ...column,\n editable: props.editable ? (column.editable ?? true) : false,\n }) as ColumnDef<unknown>,\n );\n previousColumns = { source, editable: props.editable, columns: resolved };\n return resolved;\n });\n const everyRow = (): number => Math.max(1, props.data.length);\n const initialPagination = {\n page: props.page ?? 1,\n pageSize: props.pagination ? (props.pageSize ?? props.pageSizeOptions[0] ?? 10) : everyRow(),\n };\n let binding: DataTableBinding<unknown> | undefined;\n const table = useDataTable<unknown>({\n ...expansionOptions(props, !!slots.expanded),\n ...editingOptions(props),\n data: () => props.data,\n source: computed(() => props.source),\n loadMore: computed(() => props.loadMore),\n endThreshold: props.endThreshold,\n manual: props.manual,\n rowCount: () => props.rowCount,\n columns,\n rowKey: props.rowKey as never,\n locale: props.locale ?? inherited().locale,\n normalizeText: props.normalizeText,\n paginate:\n props.paginate ??\n (props.source || props.loadMore ? false : props.virtual ? props.pagination : true),\n selectionMode: \"none\",\n initialState: { pagination: initialPagination },\n state: () => {\n const controlled = controlledState(\n props,\n binding?.table.getState().pagination ?? initialPagination,\n );\n return {\n ...controlled,\n selection: undefined,\n pagination: props.pagination ? controlled.pagination : { page: 1, pageSize: everyRow() },\n };\n },\n onEditIssues(issues) {\n emit(\"edit-error\", issues);\n emit(\"edit-issues\", issues);\n },\n onDataChange(data, changes) {\n emit(\"update:data\", data);\n emit(\"edit\", changes);\n },\n onStateChange(state, previous) {\n emitStateChanges(emit as never, state, previous);\n emitExpansionChanges(emit, state, previous, binding?.table.getSnapshot());\n emit(\"state-change\", state);\n },\n });\n binding = table;\n provideDataTable(table);\n expose({ table });\n\n // `cell.<id>` slots also receive the row's data as `item`, as they do on `<VueyeTable>`.\n const gridSlots = (): Record<string, unknown> => {\n const forwarded: Record<string, unknown> = {};\n if (slots.expanded) forwarded[\"expanded\"] = slots.expanded;\n for (const [name, slot] of Object.entries(slots)) {\n if ((name === \"default\" || name === \"group\" || name.startsWith(\"aggregate.\")) && slot) {\n forwarded[name] = slot;\n } else if (name.startsWith(\"cell.\")) {\n const cellSlot = slots[name as `cell.${string}`];\n forwarded[name] = (cellProps: GridCellSlotProps) =>\n cellSlot ? h(CellContent, { ...cellProps, render: cellSlot }) : cellProps.display;\n } else if (name.startsWith(\"editor.\")) {\n forwarded[name] = slot;\n }\n }\n return forwarded;\n };\n\n const button = (label: string, disabled: boolean, onClick: () => void) =>\n h(\"button\", { type: \"button\", class: \"vt-button\", disabled, onClick }, label);\n\n return () =>\n h(\"div\", { class: \"vt-theme vueye-grid\", \"data-vt-theme\": props.theme }, [\n props.toolbar || props.searchable || props.addRow || props.groupable\n ? h(VtToolbar, () => [\n props.searchable\n ? h(VtSearch, {\n placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder,\n })\n : null,\n props.addRow\n ? button(locale().messages.addRow, false, () => {\n table.insertRows();\n })\n : null,\n h(\"div\", { class: \"vt-toolbar-spacer\" }),\n props.groupable ? h(VtGroupBy) : null,\n props.toolbar\n ? [\n button(locale().messages.undo, !table.canUndo, () => table.undo()),\n button(locale().messages.redo, !table.canRedo, () => table.redo()),\n button(locale().messages.exportCsv, false, () =>\n emit(\"export\", table.exportRows()),\n ),\n ]\n : null,\n ])\n : null,\n h(\n VtGrid,\n {\n table,\n label: props.label ?? locale().messages.spreadsheet,\n \"aria-describedby\": attrs[\"aria-describedby\"],\n rowNumbers: props.rowNumbers,\n resizableColumns: props.resizableColumns,\n aggregatePosition: props.aggregatePosition,\n rowAttrs: props.rowAttrs,\n rowActions: props.editable || props.removeRows || props.rowPinningControls,\n removable: props.removeRows,\n onSave: (result: unknown) => emit(\"save\", result as EditResult<unknown>),\n onCancel: (key: unknown) => emit(\"cancel\", key as string | number),\n columnLetters: props.columnLetters,\n density: props.density,\n striped: props.striped,\n bordered: props.bordered,\n hover: false,\n stickyHeader: props.stickyHeader,\n loading:\n props.loading || table.loadState === \"loading\" || table.loadState === \"streaming\",\n theme: props.theme,\n virtual: props.virtual,\n virtualColumns: props.virtualColumns,\n height: props.height,\n rowHeight: props.rowHeight,\n overscan: props.overscan,\n columnWidth: props.columnWidth,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n ...(props.maxHeight ? { style: { \"--vt-max-height\": props.maxHeight } } : {}),\n },\n gridSlots(),\n ),\n props.pagination || table.loadingMode || slots.status || table.tree\n ? h(VtToolbar, { class: \"vt-footer\" }, () => [\n h(\n VtStatus,\n null,\n slots.status\n ? { default: (status: TableStatusSlotProps) => slots.status?.(status) }\n : undefined,\n ),\n ...(table.loadingMode ? [h(VtLoadMore)] : []),\n props.pagination && table.paginate\n ? h(\"div\", { class: \"vt-footer-controls\" }, [\n h(VtPageSize, { options: props.pageSizeOptions }),\n h(VtPagination),\n ])\n : null,\n ])\n : null,\n ]);\n },\n});\n","import type {\n ColumnDef,\n RowKey,\n SortInfo,\n TableRow,\n TableColumn,\n TableState,\n EditResult,\n} from \"@vueye-table/core\";\nimport {\n DataTableBody,\n DataTableCaption,\n DataTableCell,\n DataTableRow,\n DataTableSelectAll,\n DataTableSelectRow,\n DataTableRoot,\n DataTableLeadingCell,\n DataTableVirtualColumns,\n DataTableViewport,\n type TableStatusSlotProps,\n type DetailSlotProps,\n type GroupSlotProps,\n type AggregateSlotProps,\n resolveTreeColumn,\n DataTableEditRoot,\n DataTableEditCell,\n type CellEditorSlotProps,\n rowAttributes,\n} from \"@vueye-table/headless\";\nimport {\n VtColumnVisibility,\n VtGroupBy,\n VtEmpty,\n VtHeader,\n VtPageSize,\n VtPagination,\n VtSearch,\n VtStatus,\n VtLoadMore,\n VtToolbar,\n VtExpandToggle,\n VtTreeCell,\n VtRowActions,\n} from \"@vueye-table/styled\";\nimport {\n provideDataTable,\n provideTableLocale,\n useDataTable,\n useTableLocale,\n type DataTableBinding,\n} from \"@vueye-table/vue\";\nimport {\n computed,\n defineComponent,\n h,\n mergeProps,\n type PropType,\n type SlotsType,\n type VNodeChild,\n} from \"vue\";\n\nimport {\n commonProps,\n controlledState,\n createColumnResolver,\n emitStateChanges,\n stateEmitValidators,\n expansionOptions,\n emitExpansionChanges,\n CellContent,\n editingEmits,\n editingOptions,\n} from \"./shared\";\n\n/** Slot props of `cell.<column id>` and `cell`. */\nexport interface CellSlotProps {\n readonly item: unknown;\n readonly row: TableRow<unknown>;\n readonly value: unknown;\n readonly display: string;\n readonly column: { readonly id: string; readonly header: string };\n}\n\n/**\n * What a `<VueyeTable>` exposes on its template ref: the table binding, with every snapshot field\n * and operation. `useTemplateRef<VueyeTableExposed>(\"table\")` reads it typed.\n */\nexport interface VueyeTableExposed {\n readonly table: DataTableBinding<unknown>;\n}\n\n/** Slot props of `status`, the \"1–10 of 57 rows\" line. */\nexport type StatusSlotProps = TableStatusSlotProps;\n\n/**\n * Slot props of `header.<column id>`. The slot fills the header cell; on a sortable column it sits\n * inside the sort button, so the header still sorts on click and shows its indicator.\n */\nexport interface HeaderSlotProps {\n readonly column: { readonly id: string; readonly header: string };\n readonly sort: SortInfo | undefined;\n readonly toggleSort: (multi?: boolean) => void;\n}\n\n/**\n * A complete data table: search, column visibility, sorting, selection, pagination, a live\n * status line, loading and empty states, and theming. Every piece of state is available as a\n * `v-model`, and `manual` hands searching, sorting, and paging to a server.\n */\nexport const VueyeTable = defineComponent({\n name: \"VueyeTable\",\n inheritAttrs: false,\n props: {\n data: { type: Array as PropType<readonly unknown[]>, default: () => [] },\n ...commonProps,\n editMode: { type: String as PropType<\"cell\" | \"row\" | undefined>, default: undefined },\n /** `true` or `\"multiple\"` for checkboxes, `\"single\"` for one row at a time. */\n selectable: {\n type: [Boolean, String] as PropType<boolean | \"single\" | \"multiple\">,\n default: false,\n },\n selected: { type: Array as PropType<readonly RowKey[]>, default: undefined },\n /** The data is one page from a server; `rowCount` is the total. */\n /** Shown instead of the empty state while `loading` and there are no rows yet. */\n loadingText: { type: String as PropType<string | undefined>, default: undefined },\n },\n emits: {\n ...editingEmits,\n ...stateEmitValidators,\n \"state-change\": (_state: TableState) => true,\n \"row-click\": (_item: unknown, _row: TableRow<unknown>) => true,\n expand: (_item: unknown, _row: TableRow<unknown>) => true,\n collapse: (_item: unknown, _row: TableRow<unknown>) => true,\n },\n slots: Object as SlotsType<\n {\n [key: `cell.${string}`]: CellSlotProps;\n [key: `editor.${string}`]: CellEditorSlotProps;\n [key: `header.${string}`]: HeaderSlotProps;\n [key: `aggregate.${string}`]: AggregateSlotProps;\n } & {\n toolbar: { table: unknown };\n empty: Record<string, never>;\n loading: Record<string, never>;\n footer: { table: unknown };\n status: StatusSlotProps;\n expanded: DetailSlotProps;\n group: GroupSlotProps;\n }\n >,\n setup(props, { emit, slots, expose, attrs }) {\n const inherited = useTableLocale();\n const locale = provideTableLocale(() => ({ locale: props.locale, messages: props.messages }));\n const loadingText = (): string => props.loadingText ?? locale().messages.loading;\n const selectionMode = computed(() =>\n props.selectable === false ? \"none\" : props.selectable === \"single\" ? \"single\" : \"multiple\",\n );\n const initialPagination = {\n page: props.page ?? 1,\n pageSize: props.pageSize ?? props.pageSizeOptions[0] ?? 10,\n };\n const resolveColumns = createColumnResolver();\n let binding: DataTableBinding<unknown> | undefined;\n const table = useDataTable<unknown>({\n ...expansionOptions(props, !!slots.expanded),\n ...editingOptions(props),\n data: () => props.data,\n source: computed(() => props.source),\n loadMore: computed(() => props.loadMore),\n endThreshold: props.endThreshold,\n columns: () => resolveColumns(props.columns, props.data) as readonly ColumnDef<unknown>[],\n rowKey: props.rowKey as never,\n locale: props.locale ?? inherited().locale,\n normalizeText: props.normalizeText,\n manual: props.manual,\n paginate: props.paginate ?? !(props.virtual || props.source || props.loadMore),\n rowCount: () => props.rowCount,\n selectionMode: selectionMode.value,\n selectScope: props.selectScope,\n initialState: { pagination: initialPagination },\n onDataChange(data, changes) {\n emit(\"update:data\", data);\n emit(\"edit\", changes);\n },\n onEditIssues(issues) {\n emit(\"edit-issues\", issues);\n emit(\"edit-error\", issues);\n },\n state: () =>\n controlledState(props, binding?.table.getState().pagination ?? initialPagination),\n onStateChange(state, previous) {\n emitStateChanges(emit as never, state, previous);\n emitExpansionChanges(emit, state, previous, binding?.table.getSnapshot());\n emit(\"state-change\", state);\n },\n });\n binding = table;\n provideDataTable(table);\n expose({ table } satisfies VueyeTableExposed);\n const busy = (): boolean =>\n props.loading || table.loadState === \"loading\" || table.loadState === \"streaming\";\n\n const selectable = (): boolean => selectionMode.value !== \"none\";\n\n const cell = (\n row: TableRow<unknown>,\n column: (typeof table.columns)[number],\n rowIndex: number,\n ): VNodeChild => {\n const slot = slots[`cell.${column.id}`];\n const treeCell = table.tree && column.id === resolveTreeColumn(table, props.treeColumn);\n return h(\n props.editMode ? DataTableEditCell : DataTableCell,\n {\n key: column.id,\n row,\n column,\n tree: false,\n ...(props.editMode\n ? {\n rowIndex,\n onSave: (result: EditResult<unknown>) => emit(\"save\", result),\n onCancel: (key: RowKey) => emit(\"cancel\", key),\n }\n : {}),\n },\n {\n editor: slots[`editor.${column.id}`],\n default: ({ value, display }: { value: unknown; display: string }) => {\n const content = () =>\n slot ? h(CellContent, { row, column, value, display, render: slot }) : display;\n return treeCell ? h(VtTreeCell, { row }, { default: content }) : content();\n },\n $stable: true,\n },\n );\n };\n\n const hasDetails = (): boolean => !!slots.expanded && !table.tree;\n const hasActions = (): boolean =>\n !!props.editMode || props.removeRows || props.rowPinningControls;\n const leadingColumns = (): number =>\n Number(hasActions()) + Number(hasDetails()) + Number(selectable());\n const width = (): number =>\n table.columns.length +\n (selectable() ? 1 : 0) +\n (hasDetails() ? 1 : 0) +\n (hasActions() ? 1 : 0);\n const emptyBody = (): VNodeChild => {\n if (table.rows.length === 0) {\n // While the first page is loading there is nothing to match yet, so say that instead.\n const content = busy()\n ? (slots.loading?.({}) ?? h(VtEmpty, { text: loadingText() }))\n : (slots.empty?.({}) ??\n h(VtEmpty, {\n text:\n table.loadingMode && table.loadState === \"error\"\n ? locale().messages.couldNotLoadRows\n : locale().messages.noMatchingRows,\n }));\n return h(\"tr\", { \"data-empty\": \"\" }, [h(\"td\", { colspan: Math.max(1, width()) }, content)]);\n }\n return null;\n };\n const cells = (row: TableRow<unknown>, rowIndex: number): VNodeChild[] => {\n const result = [\n hasActions()\n ? h(\n DataTableLeadingCell,\n {\n class: \"vt-row-controls\",\n index: 0,\n \"aria-colindex\": 1,\n onClick: (event: Event) => event.stopPropagation(),\n },\n {\n default: () => [\n h(VtRowActions, {\n row,\n editable: props.editMode === \"row\",\n removable: props.removeRows,\n }),\n ],\n },\n )\n : null,\n hasDetails()\n ? h(\n DataTableLeadingCell,\n {\n index: Number(hasActions()),\n class: \"vt-expansion-cell\",\n \"aria-colindex\": Number(hasActions()) + 1,\n },\n { default: () => [h(VtExpandToggle, { row })] },\n )\n : null,\n selectable()\n ? h(\n DataTableLeadingCell,\n {\n class: \"vt-selection-cell\",\n index: Number(hasActions()) + Number(hasDetails()),\n \"aria-colindex\": Number(hasActions()) + Number(hasDetails()) + 1,\n onClick: (event: Event) => event.stopPropagation(),\n },\n { default: () => [h(DataTableSelectRow, { row })] },\n )\n : null,\n ...(props.virtual && props.virtualColumns\n ? [\n h(\n DataTableVirtualColumns,\n { as: \"td\" },\n {\n default: ({ column }: { column: TableColumn<unknown> }) =>\n cell(row, column, rowIndex),\n },\n ),\n ]\n : table.columns.map((column) => cell(row, column, rowIndex))),\n ];\n return result;\n };\n const bodyRow = ({ row, rowIndex }: DetailSlotProps): VNodeChild =>\n h(\n DataTableRow,\n {\n key: row.key,\n row,\n rowIndex,\n attributes: rowAttributes(props.rowAttrs, row),\n onClick: () => emit(\"row-click\", row.original, row),\n },\n { default: () => cells(row, rowIndex), $stable: true },\n );\n\n const headerSlots = () => {\n return {\n header: (header: HeaderSlotProps) =>\n slots[`header.${header.column.id}`]?.(header) ?? header.column.header,\n before: () => [\n hasActions()\n ? h(\n DataTableLeadingCell,\n { as: \"th\", index: 0, class: \"vt-row-controls\", scope: \"col\", \"aria-colindex\": 1 },\n { default: () => locale().messages.rowActions },\n )\n : null,\n hasDetails()\n ? h(DataTableLeadingCell, {\n as: \"th\",\n index: Number(hasActions()),\n class: \"vt-expansion-cell\",\n scope: \"col\",\n \"aria-colindex\": Number(hasActions()) + 1,\n \"aria-label\": locale().messages.details,\n })\n : null,\n selectable()\n ? h(\n DataTableLeadingCell,\n {\n class: \"vt-selection-cell\",\n as: \"th\",\n index: Number(hasActions()) + Number(hasDetails()),\n scope: \"col\",\n \"aria-colindex\": Number(hasActions()) + Number(hasDetails()) + 1,\n },\n {\n default: () =>\n selectionMode.value === \"multiple\" ? [h(DataTableSelectAll)] : [],\n },\n )\n : null,\n ],\n };\n };\n\n const tableContent = (): VNodeChild => {\n const children = () => [\n props.caption ? h(DataTableCaption, () => props.caption) : null,\n h(VtHeader, null, headerSlots()),\n h(\n DataTableBody,\n { class: \"vt-body\", colspan: width() },\n {\n ...(table.renderItems.length === 0 && !table.topRows.length && !table.bottomRows.length\n ? { default: emptyBody }\n : {}),\n ...Object.fromEntries(\n Object.entries(slots).filter(\n ([name]) => name === \"group\" || name.startsWith(\"aggregate.\"),\n ),\n ),\n row: bodyRow,\n detail: slots.expanded\n ? (detail: DetailSlotProps) => slots.expanded?.(detail)\n : undefined,\n },\n ),\n ];\n return props.virtual\n ? h(\n DataTableViewport,\n {\n class: \"vt-scroll\",\n height: props.height ?? \"24rem\",\n style: { \"--vt-row-height\": `${props.rowHeight}px` },\n },\n {\n default: () =>\n h(\n DataTableRoot,\n {\n table,\n class: \"vt-table\",\n leadingColumns: leadingColumns(),\n leadingColumnWidths: [\n ...(hasActions() ? [120] : []),\n ...(hasDetails() ? [44] : []),\n ...(selectable() ? [44] : []),\n ],\n resizableColumns: props.resizableColumns,\n aggregatePosition: props.aggregatePosition,\n virtual: props.virtual,\n virtualColumns: props.virtualColumns,\n rowHeight: props.rowHeight,\n overscan: props.overscan,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n },\n children,\n ),\n },\n )\n : h(\"div\", { class: \"vt-scroll\" }, [\n h(\n DataTableRoot,\n {\n table,\n treeColumn: props.treeColumn,\n keepAliveDetail: props.keepAliveDetail,\n class: \"vt-table\",\n leadingColumns: leadingColumns(),\n leadingColumnWidths: [\n ...(hasActions() ? [120] : []),\n ...(hasDetails() ? [44] : []),\n ...(selectable() ? [44] : []),\n ],\n resizableColumns: props.resizableColumns,\n aggregatePosition: props.aggregatePosition,\n \"aria-busy\": busy() ? \"true\" : undefined,\n },\n children,\n ),\n ]);\n };\n\n const surface = () =>\n h(\n \"div\",\n mergeProps(attrs, {\n class: \"vt-surface vueye-table\",\n \"data-density\": props.density,\n \"data-striped\": props.striped ? \"\" : undefined,\n \"data-bordered\": props.bordered ? \"\" : undefined,\n \"data-hover\": props.hover ? \"\" : undefined,\n \"data-sticky-header\": props.stickyHeader || props.virtual ? \"\" : undefined,\n \"data-virtual\": props.virtual ? \"\" : undefined,\n \"data-loading\": busy() ? \"\" : undefined,\n \"data-vt-theme\": props.theme,\n \"aria-busy\": props.loading ? \"true\" : undefined,\n style: props.maxHeight ? { \"--vt-max-height\": props.maxHeight } : undefined,\n }),\n [\n h(\"div\", { class: \"vt-root\" }, [\n props.searchable ||\n props.columnToggle ||\n slots.toolbar ||\n props.addRow ||\n props.groupable\n ? h(VtToolbar, () => [\n props.searchable\n ? h(VtSearch, {\n placeholder: props.searchPlaceholder ?? locale().messages.searchPlaceholder,\n })\n : null,\n props.addRow\n ? h(\n \"button\",\n { type: \"button\", class: \"vt-button\", onClick: () => table.insertRows() },\n locale().messages.addRow,\n )\n : null,\n h(\"div\", { class: \"vt-toolbar-spacer\" }),\n slots.toolbar?.({ table }),\n props.columnToggle ? h(VtColumnVisibility) : null,\n props.groupable ? h(VtGroupBy) : null,\n ])\n : null,\n h(\"div\", { class: \"vt-progress\", role: \"presentation\" }),\n tableContent(),\n (props.pagination && (!props.virtual || table.paginate)) ||\n slots.footer ||\n slots.status ||\n table.tree ||\n table.loadingMode\n ? h(VtToolbar, { class: \"vt-footer\" }, () => [\n h(\n VtStatus,\n null,\n slots.status\n ? { default: (status: StatusSlotProps) => slots.status?.(status) }\n : props.loading && table.rows.length === 0\n ? { default: () => loadingText() }\n : undefined,\n ),\n ...(table.loadingMode ? [h(VtLoadMore)] : []),\n slots.footer?.({ table }),\n props.pagination && table.paginate && (!props.virtual || table.paginate)\n ? h(\"div\", { class: \"vt-footer-controls\" }, [\n h(VtPageSize, { options: props.pageSizeOptions }),\n h(VtPagination),\n ])\n : null,\n ])\n : null,\n ]),\n ],\n );\n return () =>\n props.editMode\n ? h(\n DataTableEditRoot,\n {\n table,\n mode: props.editMode,\n onSave: (result) => emit(\"save\", result),\n onCancel: (key) => emit(\"cancel\", key),\n },\n surface,\n )\n : surface();\n },\n});\n","import { tableLocaleKey, type TableLocaleOptions } from \"@vueye-table/vue\";\nimport type { App, Plugin } from \"vue\";\n\nimport { VueyeGrid } from \"./vueye-grid\";\nimport { VueyeTable } from \"./vueye-table\";\n\n/** Options of `VueyeTablePlugin`: the application's language, which every table speaks. */\nexport type VueyeTablePluginOptions = TableLocaleOptions;\n\n/**\n * Register `<VueyeTable>` and `<VueyeGrid>` globally. A `locale` and `messages` given here are\n * the default of every table in the application; a table's own props win over them.\n */\nexport const VueyeTablePlugin: Plugin<[VueyeTablePluginOptions?]> = {\n install(app: App, options?: VueyeTablePluginOptions): void {\n app.component(\"VueyeTable\", VueyeTable);\n app.component(\"VueyeGrid\", VueyeGrid);\n if (options?.locale !== undefined || options?.messages !== undefined) {\n const language: TableLocaleOptions = { locale: options.locale, messages: options.messages };\n app.provide(tableLocaleKey, () => language);\n }\n },\n};\n"],"m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QAAQ;EAAS;EAC1F,IAAI,QAAQ,sBAAsB,QAAQ;CAC5C;AACF,EACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vueye-table",
|
|
3
|
-
"version": "3.0.0-beta.
|
|
3
|
+
"version": "3.0.0-beta.8",
|
|
4
4
|
"description": "A Vue framework for data tables and spreadsheets: a complete, themeable data table and grid, plus every layer beneath them.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"data-grid",
|
|
@@ -42,10 +42,10 @@
|
|
|
42
42
|
"provenance": true
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@vueye-table/
|
|
46
|
-
"@vueye-table/
|
|
47
|
-
"@vueye-table/
|
|
48
|
-
"@vueye-table/styled": "3.0.0-beta.
|
|
45
|
+
"@vueye-table/vue": "3.0.0-beta.8",
|
|
46
|
+
"@vueye-table/core": "3.0.0-beta.8",
|
|
47
|
+
"@vueye-table/headless": "3.0.0-beta.8",
|
|
48
|
+
"@vueye-table/styled": "3.0.0-beta.8"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
51
|
"vue": "3.5.43",
|