ui icon indicating copy to clipboard operation
ui copied to clipboard

Tooltip within Sheet is displayed when Sheet is opening

Open lacymorrow opened this issue 2 years ago • 6 comments

When the user clicks the trigger to open a Sheet

A nested tooltip is triggered

And displays during the opening animation, even though the user is not hovering over it (glitching back and forth across the screen)

lacymorrow avatar Sep 29 '23 18:09 lacymorrow

have the same issue, happening with a tooltip nested in a dialog

brianyu20 avatar Oct 06 '23 18:10 brianyu20

I have same issue with tooltip and dialog here

Sotatek-HiepNguyen2 avatar Nov 13 '23 09:11 Sotatek-HiepNguyen2

Unfortunately my "workaround" was "Not using shadcn/tooltip"

I'm using Tremor.so for dashboard components and their Icon component has built-in tooltip support

lacymorrow avatar Nov 13 '23 17:11 lacymorrow

Hello @lacymorrow @brianyu20 @Sotatek-HiepNguyen2 I have the same issue and solve it adding :

 <SheetContent onOpenAutoFocus={(event) => event.preventDefault()}>

to my Sheet content component to avoid it

LongJohnSilver1504 avatar Jan 17 '24 21:01 LongJohnSilver1504

@shadcn I think we could close this issue ;)

LongJohnSilver1504 avatar Feb 07 '24 16:02 LongJohnSilver1504

This should be added to the docs first.

lacymorrow avatar Feb 08 '24 20:02 lacymorrow

I have the same issue using the Tooltip as an info icon within the DialogHeader. Using defaultOpen={false} on Tooltip doesn't do anything. Interestingly enough switching it to defaultOpen="false" does do the job, but throws a typescript error for using a string.

JohannSiemens avatar Feb 17 '24 16:02 JohannSiemens

@ts-ignore

But you may also try moving the tooltipprovider higher up the DOM

lacymorrow avatar Feb 18 '24 06:02 lacymorrow

This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.

shadcn avatar Jun 04 '24 23:06 shadcn