res.html 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>
  5. <%= title %>&emsp;❁&emsp;<%= ((dmd["dc:title"] or {})[1] or {}).data or uri.data %>
  6. </title>
  7. </head>
  8. <body>
  9. <header>
  10. <h1>
  11. <%= ((dmd["dc:title"] or {})[1] or {}).data or uri.data %>
  12. </h1>
  13. </header>
  14. <main>
  15. <section id="res_dmd">
  16. <h2>Metadata</h2>
  17. <dl class="res_md">
  18. <% for p, ol in pairs(dmd) do %>
  19. <dt><%= p %></dt>
  20. <% for _, o in ipairs(ol) do %>
  21. <dd><%= o %></dd>
  22. <% end %>
  23. <% end %>
  24. </dl>
  25. </section>
  26. <% if #rel then %>
  27. <section id="res_rel">
  28. <h2>Relationships</h2>
  29. <dl class="res_md">
  30. <% for p, ol in pairs(rel) do %>
  31. <dt><%= p.data %></dt>
  32. <% for _, o in ipairs(ol) do %>
  33. <dd><a href="res/<%= o.data %>.html"><%= o.data %></a></dd>
  34. <% end %>
  35. <% end %>
  36. </dl>
  37. </section>
  38. <% end %>
  39. <% if #children then %>
  40. <section id="res_children">
  41. <h2>Children</h2>
  42. <ul>
  43. <% for _, child in ipairs(children) do %>
  44. <li><a href = "<%= child %>"><%= child %></li>
  45. <% end %>
  46. </ul>
  47. </section>
  48. <% end %>
  49. </main>
  50. <footer></footer>
  51. </body>
  52. </html>