Tooltips

The tooltips component (a.k.a. popovers) provides small pop-up messages that appear when users hover over or focus on an element (often an i icon), offering additional context or information.

Great for appending helpful information next to form labels, settings, or other elements.

Installation

Copy
rails g instrumental:tooltips

To insert a component into a view:

Copy
rails g instrumental:tooltips:insert

Or simply add one like this:

Copy
<%= render "shared/components/tooltip" do %>
      This is a tooltip
    <% end %>

Customization

Find all of your customization options (via local variables) in this file:

app/views/shared/components/_tooltip.html.erb

Instrumental Components

I created Instrumental Components to make designing and building professional apps with Ruby on Rails easy, fast, and fun. I use it on all of my projects and I hope it helps you build something great.

Brian Casel
Brian Casel
Creator of Instrumental Components
Learn more Send me a question or request