File tree 1 file changed +13
-12
lines changed
src/ocamlorg_frontend/pages
1 file changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -24,17 +24,18 @@ let render_books books =
24
24
<% ); %>
25
25
<div class="font-semibold text-base mb-6 uppercase"><%s item.authors |> String.concat ", " %></div>
26
26
<div class="prose prose-orange mb-6"><%s! item.body_html %></div>
27
- <% let link = List.hd item.links in %>
28
- <a href="<%s link.uri %>">
29
- <button class="btn btn-secondary">
30
- <span><%s link.description %></span>
31
- <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" fill="none" viewBox="0 0 24 24"
32
- stroke="currentColor">
33
- <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
34
- d="M9 5l7 7-7 7" />
35
- </svg>
36
- </button>
37
- </a>
27
+ <% item.links |> List.iter (fun (link : Ood.Book.link) -> %>
28
+ <a href="<%s link.uri %>">
29
+ <button class="btn btn-secondary">
30
+ <span><%s link.description %></span>
31
+ <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" fill="none" viewBox="0 0 24 24"
32
+ stroke="currentColor">
33
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
34
+ d="M9 5l7 7-7 7" />
35
+ </svg>
36
+ </button>
37
+ </a>
38
+ <% ); %>
38
39
</div>
39
40
</div>
40
41
<% ); %>
@@ -90,4 +91,4 @@ Layout.render
90
91
</div>
91
92
</div>
92
93
</div>
93
- </div>
94
+ </div>
You can’t perform that action at this time.
0 commit comments