mirror of
https://github.com/aljazceru/hypergolic.git
synced 2025-12-17 05:24:21 +01:00
solution: trigger the `toggleDataPointSelection` method when the table row is hovered resolve https://github.com/nostrocket/hypergolic/issues/76
26 lines
490 B
Svelte
26 lines
490 B
Svelte
<script lang="ts">
|
|
import type { HTMLAttributes } from 'svelte/elements';
|
|
import { cn } from '$lib/utils.js';
|
|
|
|
type $$Props = HTMLAttributes<HTMLTableRowElement> & {
|
|
'data-state'?: unknown;
|
|
};
|
|
|
|
let className: $$Props['class'] = undefined;
|
|
export { className as class };
|
|
</script>
|
|
|
|
<tr
|
|
class={cn(
|
|
'border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted',
|
|
className
|
|
)}
|
|
{...$$restProps}
|
|
on:click
|
|
on:keydown
|
|
on:mouseenter
|
|
on:mouseleave
|
|
>
|
|
<slot />
|
|
</tr>
|