diff --git a/mathesar_ui/src/systems/table-view/row/CellErrors.svelte b/mathesar_ui/src/systems/table-view/row/CellErrors.svelte index 87cb62e581..5a793ea7d5 100644 --- a/mathesar_ui/src/systems/table-view/row/CellErrors.svelte +++ b/mathesar_ui/src/systems/table-view/row/CellErrors.svelte @@ -8,12 +8,17 @@ let errorIndicatorElement: SVGSVGElement | undefined; let cellElementIsHovered = false; + let hiderTimeoutId: number; function setHover() { + window.clearTimeout(hiderTimeoutId); cellElementIsHovered = true; } + function unsetHover() { - cellElementIsHovered = false; + hiderTimeoutId = window.setTimeout(() => { + cellElementIsHovered = false; + }, 1); } onMount(() => { const cell = errorIndicatorElement?.parentElement; @@ -47,6 +52,8 @@ reference: cellElement, options: { placement: 'top-start' }, }} + on:mouseenter={() => setHover()} + on:mouseleave={() => unsetHover()} > {errors.join(' ')}