Components
Tooltip
Contextual helper bubble explaining technical terms, mandatory requirements, and field guidance tips
Contextual helper bubble explaining technical terms, mandatory requirements, and field guidance tips.
Import from com.ux4g.designsystemv1.components.tooltip.Ux4gTooltip.
Interactive Preview
Ux4gTooltipJetpack Compose

Kotlin Usage
import androidx.compose.runtime.Composable
import androidx.compose.material3.Icon
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.outlined.Info
import com.ux4g.designsystemv1.components.tooltip.Ux4gTooltip
import com.ux4g.designsystemv1.theme.Ux4gTheme
@Composable
fun TooltipExample() {
Ux4gTooltip(tooltipText = "Mandatory document for direct benefit bank transfer") {
Icon(Icons.Outlined.Info, contentDescription = "Help", tint = Ux4gTheme.colorScheme.primary)
}
}Parameters
| Prop | Type | Description | Default |
|---|---|---|---|
tooltipText * | String | Guidance explanation text displayed inside the tooltip bubble. | — |
content * | @Composable () -> Unit | Anchor composable trigger that opens the tooltip on tap or hover. | — |
modifier | Modifier | Compose layout modifier. | Modifier |
backgroundColor | Color | Tooltip bubble background container color. | Ux4gTheme.colorScheme.onSurface |
textColor | Color | Tooltip text font color. | Ux4gTheme.colorScheme.surface |