Files
nairobi/app/components/admin/widget/cards/row_component.html.erb
Javi Martín 9cc0ad0ba9 Allow cards table actions to receive options
Just like we sometimes override options in the generic table actions
component, we're going to do the same thing with the cards table
actions.
2021-02-26 16:17:18 +01:00

23 lines
569 B
Plaintext

<tr id="<%= dom_id(card) %>" class="homepage-card">
<td>
<%= card.label %><br>
<%= card.title %>
</td>
<td><%= card.description %></td>
<td>
<%= card.link_text %><br>
<%= card.link_url %>
</td>
<!-- remove conditional once specs have image validations -->
<td>
<% if card.image.present? %>
<%= link_to t("admin.shared.show_image"), card.image_url(:large),
title: card.image.title, target: "_blank" %>
<% end %>
</td>
<td>
<%= render Admin::TableActionsComponent.new(card, options) %>
</td>
</tr>