A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://flowbite-svelte.com/docs/components/tooltip below:

Svelte Tooltip - Flowbite

flowbite-svelte allows you to show extra information when hovering or focusing over an element in multiple positions, styles, and animations.

For interactive elements that need to display additional content on click, use the popover component.

Setup # Default tooltip example #

To get started with using tooltips all you need to do is to place Tooltip element directly after tiggering element (usually Button). In the following example you can see the tooltip that will be trigger by the adjacent element to be shown when hovered or focused.

If you have anything else between the button and tooltip, they won’t find each other and you will need to specify the link between them by setting the property triggeredBy to the CSS query of the element that triggers the tooltip. Most of the time you will want to use the id attribute of the element to link them, but you can use any CSS query you want. See the examples further down.

hi mom

lorem ipsum, content blah blah, other stuff

Tooltip types #

You can use choose between dark and light version styles for the tooltip component by changing the utility classes from Tailwind CSS and by applying the type={light|dark|auto} data attribute.

A11y #

Use Tab and Shift+Tab to navigate between buttons or links in the tooltip. Press ESC to close it.

Placement #

The positioning of the tooltip element relative to the triggering element (eg. button, link) can be set using the placement={top|right|bottom|left} attribute.

Note! This examples shows you also how to share one tooltip between multiple triggering elements using advanced CSS query.

Triggering # Disable arrow # External reference #

If you need the tooltip to be attached to the other element then the tiggering one you can pass a CSS query to reference prop.

Animations #

Use svelte transistions to configure tooltip animations.

Custom type #

Various color palettes can be set for a tooltip by using the color property. (Setting color prop sets the type to custom implicitly.)

When you want to add a fully custom styles, use type="custom", defaultClass, and class to modify the tooltip styling.

See also #

Loading related links...

Component data #

The component has the following props, type, and default values. See types page for type information.

References #

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4