screenshots.ejs 815 B

1234567891011121314151617
  1. <% var size = 4; %>
  2. <% if(screenshots.length > 0) { %>
  3. <div class="row up-spacer">
  4. <% for (let i = 0; i < screenshots.length; i++) { %>
  5. <% if(screenshots.length == 4 && i == 0) { size = 12 } %>
  6. <% if(screenshots.length == 5 && i == 0) { size = 6 } %>
  7. <% if(screenshots.length == 5 && i == 1) { size = 6 } %>
  8. <% if(screenshots.length == 4 && i >= 1) { size = 4 } %>
  9. <% if(screenshots.length == 5 && i >= 2) { size = 4 } %>
  10. <div class="col-<%= size %>" style="margin-bottom: 20px;">
  11. <a href="<%= url_for(screenshots[i].url) %>" class="">
  12. <img class="img-fluid thumbnail figure-img rounded" src="<%= screenshots[i].url %>">
  13. </a>
  14. </div>
  15. <% } %>
  16. </div>
  17. <% } %>