{{ table?.tableApi?.getFilteredSelectedRowModel().rows.length || 0 }} of
diff --git a/src/runtime/components/Table.vue b/src/runtime/components/Table.vue
index f50001cc..00b67008 100644
--- a/src/runtime/components/Table.vue
+++ b/src/runtime/components/Table.vue
@@ -165,6 +165,7 @@ export interface TableProps extends TableOption
*/
facetedOptions?: FacetedOptions
onSelect?: (row: TableRow, e?: Event) => void
+ onHover?: (e: Event, row: TableRow | null) => void
onContextmenu?: ((e: Event, row: TableRow) => void) | Array<((e: Event, row: TableRow) => void)>
class?: any
ui?: Table['slots']
@@ -331,6 +332,14 @@ function onRowSelect(e: Event, row: TableRow) {
props.onSelect(row, e)
}
+function onRowHover(e: Event, row: TableRow | null) {
+ if (!props.onHover) {
+ return
+ }
+
+ props.onHover(e, row)
+}
+
function onRowContextmenu(e: Event, row: TableRow) {
if (!props.onContextmenu) {
return
@@ -396,7 +405,7 @@ defineExpose({
|