1. Overlays
  2. Popover

Components

Tailwind CSS Popover

A simple and compact dialog of an action.

Requires JS

Note that this component requires the use of our Tooltip plugin, else you can skip this message if you are already using Preline UI as a package.

Purpose of content

A simple popup menu to provide extra information or operations.

Image Description

Comparing with Tooltip, besides information Popover card can include a header and provide action elements like links and buttons.

Interactions

Popover are typically dismissable, whether by click on other parts of the page or second clicking the popover target (depending on implementation), for that reason you can set up a popover to allow you to interact with other elements on the page while still being able to read it's content.

On top of that, since popover will remain open when mousing out of their target you can add additional buttons or interactions within them:

Image Description

Conclusion

If you want to add any additional content, interactions, or content more than about a line; or if you need the content to remain open without the target being mousedover use a popover.

Although it should be noted due to accessibility problems, potential SEO issues, and lack of discovery of the popover, it's not recommended unless you absolutely need it.

Four directions

Four options are available: top, right, bottom, and left aligned.

Focus event

Use [--trigger:focus] class for focus event.

Hover event

Use [--trigger:hover] class for hover event.

With content

Example with content.

Review popover example New

Review popover example.

User popover example New

User popover example.

Image Description

Amanda Harvey

amanda@email.com