flowbite-react icon indicating copy to clipboard operation
flowbite-react copied to clipboard

Tooltip should have a flag for "interactive".

Open m-tse opened this issue 1 year ago • 1 comments

  • [x] I have searched the Issues to see if this bug has already been reported
  • [x] I have tested the latest version

Summary

The Tooltip component should have an "interactive" flag, wherein if interactive=True, mousing over the tooltip will keep the tooltip up. Allowing you to select text in the tooltip, or click on a link in the tooltip. If interactive=False, then once the user moves the mouse off the anchoring element, the tooltip will disappear, and there will be no way to interact with the tooltip.

Context

Currently, the Flowbite React Tooltip is always "interactive", and interestingly, the vanilla Flowbite Tooltip is always "non-interactive". Some other component libraries like Material-Tailwind allow the user to specify interactive or not-interactive.

This is a useful feature to have, because if one's UI has a lot of tooltips, then it can become annoying clicking around on things, where you need to navigate the mouse around the tooltip before you can click on the item underneath.

Would be really nice to have--I'm otherwise really liking this library!

m-tse avatar Mar 08 '24 20:03 m-tse

I guess one similar workaround would be to change trigger="click", and then change the cursor of the anchor element to a help sign.

m-tse avatar Mar 08 '24 20:03 m-tse