lotusui the ikaito design language for Gio — desktop, mobile, web
GitHub

Tooltip

The hover label: inverted chrome, a rest delay, pass-through events.

Wrap any widget; hold the pointer for a beat and the label floats in beneath it on the portal layer. The hover area passes events through — the child keeps its own interactions. One Tooltip struct per wrapped instance.

Installation

Use the module import (the default), or own the source: lotusui add vendors the component into your app and lotusui update keeps the copy mergeable — see Registry.

Go
go get github.com/ikaito-com/lotusui

# or vendor the source into your app:
go run github.com/ikaito-com/lotusui/cmd/lotusui add tooltip

Usage

Go
var tip lotusui.Tooltip
tip.Layout(th, gtx, "Add to library",
	lotusui.Button(th, &btn, "Hover me", lotusui.ButtonOpts{Variant: lotusui.ButtonOutline}))

Sides

Side floats the label above, below, or beside the child.

Go
tip := lotusui.Tooltip{Side: lotusui.TooltipTop}

API

OptionTypeDescription
Layout(th, gtx, text, child)methodWrap any widget; label floats in after a rest delay.

Every demo on this site is the real Go component compiled to WebAssembly — one gallery app, one bundle, addressed by URL hash.