aboutsummaryrefslogtreecommitdiff
path: root/views/owner.eta
diff options
context:
space:
mode:
Diffstat (limited to 'views/owner.eta')
-rw-r--r--views/owner.eta107
1 files changed, 48 insertions, 59 deletions
diff --git a/views/owner.eta b/views/owner.eta
index e5667fb..b3304fb 100644
--- a/views/owner.eta
+++ b/views/owner.eta
@@ -1,65 +1,54 @@
-<!DOCTYPE html>
-<html lang="en">
-<head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title><%= it.name ? `${it.name} (${it.login})` : it.login %></title>
- <link rel="stylesheet" href="/static/style.css">
-</head>
-<body>
- <div class="box">
- <% if (it.avatarUrl) { %>
- <img class="avatar" src="<%= it.avatarUrl %>" alt="" width="64" height="64">
- <% } %>
- <div class="repo"><%= it.name || it.login %></div>
- <div><%= it.login %><%= it.type === "organization" ? " (organization)" : "" %></div>
- <% if (it.location) { %>
- <div><%= it.location %></div>
- <% } %>
- <% if (it.nav.length > 0) { %>
- <nav>
- <% for (const item of it.nav) { %>
- <a href="<%= item.href %>"><%= item.text %></a>
- <% } %>
- </nav>
- <% } %>
- </div>
+<% layout("/layouts/base.eta", { title: it.name ? `${it.name} (${it.login})` : it.login }) %>
- <% if (it.bio || it.links.length > 0 || it.followers || it.company) { %>
- <div class="box repo-info">
- <% if (it.bio) { %>
- <div class="description"><%= it.bio %></div>
- <% } %>
- <% for (const link of it.links) { %>
- <div class="detail"><img src="/static/icons/link.svg" alt="" class="icon"> <a href="<%= link.href %>" rel="noopener noreferrer"><%= link.text %></a></div>
- <% } %>
- <% if (it.followers) { %>
- <div class="detail"><img src="/static/icons/eye.svg" alt="" class="icon"> <%= it.followers %> followers<%= it.following ? ` · ${it.following} following` : "" %></div>
- <% } %>
- <% if (it.company) { %>
- <div class="detail"><%= it.company %></div>
- <% } %>
- </div>
+<div class="box">
+ <% if (it.avatarUrl) { %>
+ <img class="avatar" src="<%= it.avatarUrl %>" alt="" width="64" height="64">
<% } %>
-
- <% if (it.pinned.length > 0) { %>
- <section>
- <h2>Pinned</h2>
- <% for (const repo of it.pinned) { %>
- <%~ include("./_ownerRepo", { repo, login: it.login }) %>
- <% } %>
- </section>
+ <div class="repo"><%= it.name || it.login %></div>
+ <div><%= it.login %><%= it.type === "organization" ? " (organization)" : "" %></div>
+ <% if (it.location) { %>
+ <div><%= it.location %></div>
<% } %>
-
- <% if (it.repos.length > 0) { %>
- <section>
- <h2>Repositories</h2>
- <% for (const repo of it.repos) { %>
- <%~ include("./_ownerRepo", { repo, login: it.login }) %>
+ <% if (it.nav.length > 0) { %>
+ <nav>
+ <% for (const item of it.nav) { %>
+ <a href="<%= item.href %>"><%= item.text %></a>
<% } %>
- </section>
+ </nav>
<% } %>
+</div>
+
+<% if (it.bio || it.links.length > 0 || it.followers || it.company) { %>
+ <div class="box repo-info">
+ <% if (it.bio) { %>
+ <div class="description"><%= it.bio %></div>
+ <% } %>
+ <% for (const link of it.links) { %>
+ <div class="detail"><img src="/static/icons/link.svg" alt="" class="icon"> <a href="<%= link.href %>" rel="noopener noreferrer"><%= link.text %></a></div>
+ <% } %>
+ <% if (it.followers) { %>
+ <div class="detail"><img src="/static/icons/eye.svg" alt="" class="icon"> <%= it.followers %> followers<%= it.following ? ` · ${it.following} following` : "" %></div>
+ <% } %>
+ <% if (it.company) { %>
+ <div class="detail"><%= it.company %></div>
+ <% } %>
+ </div>
+<% } %>
- <footer>Generated by cgithub</footer>
-</body>
-</html>
+<% if (it.pinned.length > 0) { %>
+ <section>
+ <h2>Pinned</h2>
+ <% for (const repo of it.pinned) { %>
+ <%~ include("./_ownerRepo", { repo, login: it.login }) %>
+ <% } %>
+ </section>
+<% } %>
+
+<% if (it.repos.length > 0) { %>
+ <section>
+ <h2>Repositories</h2>
+ <% for (const repo of it.repos) { %>
+ <%~ include("./_ownerRepo", { repo, login: it.login }) %>
+ <% } %>
+ </section>
+<% } %>