<.header> Listing Items <:actions> <.button phx-click={ JS.push("toggle_view_state") |> JS.dispatch("toggle_view_state", detail: %{"grid" => !@grid}) }> Toggle Display <%= if @grid do %>
{item.title} <%= if item.received do %>
<.icon name="hero-check-circle" />Received
<% end %>
<%= item.title %>
<.icon name="hero-ellipsis-vertical" class="w-7 h-7" />
<% else %>
{item.title} <%= if item.received do %>
<.icon name="hero-check-circle" />Received
<% end %>
<%= item.title %>
<.icon name="hero-ellipsis-vertical" class="w-7 h-7" />
<% end %>