Skip to main content

tooltip

Description

Optional. Sets the tooltip text shown on hover when the control is wrapped in a Tooltip component

Usage

tooltip?: string;

Details

The tooltip prop sets data-tooltip-text on the control's root element. The tooltip is shown automatically when the control is wrapped in <Tooltip> component. The tooltip is independent of the title prop. Both can be set simultaneously when each displays its own tooltip (the browser's native one and the SVAR one) but make sure it's not redundant in your case.

Example

<Tooltip at="top-center" arrow>
<Icon css="wxi-star" tooltip="Favorite" />
</Tooltip>

Related article: Using the tooltip prop on built-in controls

Related sample: Icon