Skip to content

Commit bc0c7cf

Browse files
Fix tooltip clipping
The AI adjusted the z-index of the tooltip in `src/components/CustomInfoTooltip.tsx` to ensure it appears above other elements and is not clipped by parent containers.
1 parent a375834 commit bc0c7cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/components/CustomInfoTooltip.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ export const CustomInfoTooltip = ({ text }: CustomInfoTooltipProps) => {
1616
onMouseLeave={() => setIsVisible(false)}
1717
/>
1818
{isVisible && (
19-
<div className="absolute bottom-full left-1/2 transform -translate-x-1/2 mb-2 px-3 py-1.5 bg-slate-900 text-white text-xs rounded-md shadow-lg z-50 w-48 text-center whitespace-normal">
19+
<div className="absolute bottom-full right-0 mb-2 px-3 py-1.5 bg-slate-900 text-white text-xs rounded-md shadow-lg z-50 w-48 text-left whitespace-normal">
2020
{text}
21-
<div className="absolute top-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-l-4 border-r-4 border-t-4 border-transparent border-t-slate-900"></div>
21+
<div className="absolute top-full right-4 w-0 h-0 border-l-4 border-r-4 border-t-4 border-transparent border-t-slate-900"></div>
2222
</div>
2323
)}
2424
</div>

0 commit comments

Comments
 (0)