Tooltip

A popup that displays information related to an element when the element receives keyboard focus or the mouse hovers over it.

Was this example helpful?

Usage#

Code
import { Tooltip, TooltipProvider } from "@medusajs/ui"
Code
<Tooltip content="Tooltip content">Trigger</Tooltip>

API Reference#


This component is based on the Radix UI Tooltip primitive.

PropTypeDefault
content
ReactReactNode
-
onClick
ReactMouseEventHandler
-
side
"bottom"
|"left"
|"top"
|"right"
-
maxWidth
number
220
sideOffset
8
Was this page helpful?

Usage Outside Medusa Admin#


If you're using the Tooltip component in a project other than the Medusa Admin, make sure to include the TooltipProvider somewhere up in your component tree:

Code
1<TooltipProvider>2  <Tooltip content="Tooltip content">Trigger</Tooltip>3</TooltipProvider>

TooltipProvider Reference#


PropTypeDefault
delayDuration
100
skipDelayDuration
300
Was this page helpful?