x
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<div class="contents" data-controller="popover"> <button data-popover-target="button" popovertarget="my-action-menu" class="hover:bg-neutral"><!-- Source: Iconoir, added via `bin/add_icon` --> <svg width="24" height="24" stroke-width="1.5" viewbox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" class="shrink-0" aria-hidden="true"> <path d="M6 9L12 15L18 9" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path> </svg> </button> <div popover="auto" class="absolute -left-full -top-full m-0 bg-white rounded-sm border border-subdued popover-open:block px-0 py-1 border border-subdued shadow-sm" data-action="toggle->popover#positionPopover" data-popover-target="popover" data-testid="action-menu" id="my-action-menu"> <ul> <li class="whitespace-nowrap hover:bg-gray-100 [&_a]:px-3 [&_a]:py-1 [&_a]:w-full [&_a]:block [&_a]:text-left [&_button]:px-3 [&_button]:py-1 [&_button]:w-full [&_button]:block [&_button]:text-left" data-testid="action-menu-item" data-action="click->popover#hide"> <p>Select all</p> </li> <li class="whitespace-nowrap hover:bg-gray-100 [&_a]:px-3 [&_a]:py-1 [&_a]:w-full [&_a]:block [&_a]:text-left [&_button]:px-3 [&_button]:py-1 [&_button]:w-full [&_button]:block [&_button]:text-left" data-testid="action-menu-item" data-action="click->popover#hide"> <p>Clear selection</p> </li> </ul> </div></div>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<%= anchor_action_menu(id: "my-action-menu") do |c| %> <% c.with_trigger do %> <%= tag.button( anchor_icon(icon: "nav-arrow-down"), **popover_trigger_attributes(popovertarget: "my-action-menu"), class: "hover:bg-neutral" ) %> <% end %> <% c.with_item do %> <%= tag.p "Select all" %> <% end %> <% c.with_item do %> <%= tag.p "Clear selection" %> <% end %><% end %>No notes provided.
No params configured.