dres.html 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <%- head_tpl({site_title = site_title, title = title}) %>
  5. </head>
  6. <body>
  7. <%- header_tpl({site_title = site_title}) %>
  8. <main>
  9. <h1><%= breadcrumbs[#breadcrumbs][2] %>:&ensp;<%= title %></h1>
  10. <section id="res_lineage">
  11. <h2>Classification</h2>
  12. <p>
  13. <% for i, bc in ipairs(breadcrumbs) do %>
  14. <% cls, label = table.unpack(bc) %>
  15. <% if i ~= 1 then %>
  16. <span class="breadcrump_sep">&ensp;&#x27B3;&ensp;</span>
  17. <% end %>
  18. <a
  19. class="breadcrumb<%if i == #breadcrumbs then %> current<% end %>"
  20. href="../class/<%= cls -%>">
  21. <%= label -%>
  22. </a>
  23. <% end %>
  24. </p>
  25. </section>
  26. <section id="res_dmd">
  27. <h2>Metadata</h2>
  28. <p><a href="<%= rdf_href %>">Download RDF document</a></p>
  29. <dl class="res_md">
  30. <% for _, ol in ipairs(dmd) do %>
  31. <dt>
  32. <% if ol.label then %><%= ol.label %>
  33. <% else %><code><%= ol.uri %></code><% end %>
  34. <% if ol.description then %><span
  35. title="<%= ol.description -%>"
  36. >&nbsp;&#x1F6C8;</span>
  37. <% end %>
  38. </dt>
  39. <% for _, o in ipairs(ol) do %>
  40. <dd><%= o %></dd>
  41. <% end %>
  42. <% end %>
  43. </dl>
  44. </section>
  45. <% if #rel > 0 then %>
  46. <section id="res_rel">
  47. <h2>Relationships</h2>
  48. <dl class="res_md">
  49. <% for p, ol in pairs(rel) do %>
  50. <dt>
  51. <% if ol.label then %><%= ol.label %>
  52. <% else %><code><%= ol.uri %></code><% end %>
  53. </dt>
  54. <% for _, o in ipairs(ol) do %>
  55. <dd><a href="/res/<%= o.data %>.html"><%= o.data %></a></dd>
  56. <% end %>
  57. <% end %>
  58. </dl>
  59. </section>
  60. <% end %>
  61. <% if #children > 0 then %>
  62. <section id="res_children">
  63. <h2>Contains</h2>
  64. <ul>
  65. <% for _, ll in ipairs(children) do %>
  66. <li>Sequence (<%= #ll %> items):<ol>
  67. <% for i, el in ipairs(ll) do %>
  68. <li><a href="<%= el.href %>">
  69. <% if el.tn then %>
  70. <img src="<%= el.tn %>" alt="<%= el.label %>" />
  71. <% else %>
  72. <%= el.label %>
  73. <% end %>
  74. </a></li>
  75. <%end %>
  76. </ol></li>
  77. <% end %>
  78. </ul>
  79. </section>
  80. <% end %>
  81. </main>
  82. <footer></footer>
  83. </body>
  84. </html>