-
Notifications
You must be signed in to change notification settings - Fork 0
Fragments
Luke edited this page Jan 3, 2023
·
1 revision
We created an item card fragment to unify the UI of search results and dashboard. To use the card, you can use something like the following (@results
is the list containing the items):
<div class="row row-cols-1 row-cols-md-4 g-3">
<% @results.each do |result| %>
<%= render :partial => "partials/itemcard", :locals => { :item => result } %>
<% end %>
</div>
If you need to change the styling, you can find the relevant classes here. Be aware that these classes change the styling on every page using this fragment.