aboutsummaryrefslogtreecommitdiffstats
path: root/app/views/pdfresources/index.html.erb
blob: 158e505cd2e654ff08b4d76596600ec4e60b4498 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<div class="w-full">
  <% if notice.present? %>
    <p class="py-2 px-3 bg-green-50 mb-5 text-green-500 font-medium rounded-lg inline-block" id="notice"><%= notice %></p>
  <% end %>

  <% content_for :title, "Alphabet Learning - Resources" %>

  <div class="text-center">
    <h1 class="font-bold text-4xl m-12">Featured Resources</h1>
  </div>
  
  <div id="pdfresources" class="flex flex-wrap justify-between">
    <% @pdfresources.where("feature_slot < 4").each do |pdfresource| %>
        <%= render pdfresource %>
    <% end %>
  </div>
  
  <% if Current.session.user.is_admin %>
    <%= link_to "Add new resource", new_pdfresource_path, class: "rounded-lg py-3 px-5 bg-blue-600 text-white block font-medium" %>
  <% end %>

</div>