| 25ab8c73 Andy McCall ↶ |
1 |
{% extends "base.html" %} |
| 2 |
{% block title %}Dashboard{% endblock %} |
| 3 |
{% block content %} |
| 6246d1e5 Andy McCall ↶ |
4 |
<script type="application/json" id="backdrop-data">{{ backdrop|safe }}</script> |
| 0a3b244b Andy McCall ↶ |
5 |
{% include "backdrop.html" %} |
| 25ab8c73 Andy McCall ↶ |
6 |
<div class="head"> |
| 7 |
<h1>Dashboard <small>signed in as {% if let Some(u) = shell.user %}{{ u }}{% endif %}</small></h1> |
| 8 |
</div> |
| 6907a989 Andy McCall ↶ |
9 |
<div class="side-layout rev dash" data-backdrop-avoid> |
| 25ab8c73 Andy McCall ↶ |
10 |
<div> |
| f8cf54e9 Andy McCall ↶ |
11 |
<section class="card-box"> |
| 12 |
<div class="card-head"><h2>Waiting for your review</h2><span class="count-chip">{{ reviews.len() }}</span></div> |
| 25ab8c73 Andy McCall ↶ |
13 |
{% if reviews.is_empty() %} |
| 14 |
<p class="empty small">Nothing waits on you. Proposals by others in your repositories land here until you review them.</p> |
| 15 |
{% else %} |
| 16 |
<ul class="rows"> |
| 17 |
{% for p in reviews %} |
| 18 |
<li> |
| 19 |
<div> |
| 20 |
<a class="name" href="/{{ p.owner }}/{{ p.name }}/proposal/{{ p.number }}"><span class="mute">{{ p.owner }}/{{ p.name }} #{{ p.number }}</span> <strong>{{ p.title }}</strong></a> |
| 21 |
{% if p.conflicted %}<span class="tag bad">conflicts</span>{% endif %} |
| 22 |
<p class="small">by {{ p.author }}</p> |
| 23 |
</div> |
| 24 |
<div class="right small">updated <time title="{{ p.updated_ms|when_i }}">{{ p.updated_ms|ago_i }}</time></div> |
| 25 |
</li> |
| 26 |
{% endfor %} |
| 27 |
</ul> |
| 28 |
{% endif %} |
| f8cf54e9 Andy McCall ↶ |
29 |
</section> |
| 25ab8c73 Andy McCall ↶ |
30 |
|
| 31 |
{% if !authored.is_empty() %} |
| f8cf54e9 Andy McCall ↶ |
32 |
<section class="card-box"> |
| 33 |
<div class="card-head"><h2>Your proposals</h2><span class="count-chip">{{ authored.len() }}</span></div> |
| 25ab8c73 Andy McCall ↶ |
34 |
<ul class="rows"> |
| 35 |
{% for p in authored %} |
| 36 |
<li> |
| 37 |
<div> |
| 38 |
<a class="name" href="/{{ p.owner }}/{{ p.name }}/proposal/{{ p.number }}"><span class="mute">{{ p.owner }}/{{ p.name }} #{{ p.number }}</span> <strong>{{ p.title }}</strong></a> |
| 39 |
{% if p.state == "draft" %}<span class="tag">draft</span>{% endif %} |
| 40 |
{% if p.conflicted %}<span class="tag bad">conflicts</span>{% endif %} |
| 41 |
</div> |
| 42 |
<div class="right small">updated <time title="{{ p.updated_ms|when_i }}">{{ p.updated_ms|ago_i }}</time></div> |
| 43 |
</li> |
| 44 |
{% endfor %} |
| 45 |
</ul> |
| f8cf54e9 Andy McCall ↶ |
46 |
</section> |
| 25ab8c73 Andy McCall ↶ |
47 |
{% endif %} |
| 48 |
|
| 49 |
{% if !assigned.is_empty() %} |
| f8cf54e9 Andy McCall ↶ |
50 |
<section class="card-box"> |
| 51 |
<div class="card-head"><h2>Issues assigned to you</h2><span class="count-chip">{{ assigned.len() }}</span></div> |
| 25ab8c73 Andy McCall ↶ |
52 |
<ul class="rows"> |
| 53 |
{% for i in assigned %} |
| 54 |
<li> |
| 55 |
<div><a class="name" href="/{{ i.owner }}/{{ i.name }}/issue/{{ i.number }}"><span class="mute">{{ i.owner }}/{{ i.name }} #{{ i.number }}</span> <strong>{{ i.title }}</strong></a></div> |
| 56 |
<div class="right small">updated <time title="{{ i.updated_ms|when_i }}">{{ i.updated_ms|ago_i }}</time></div> |
| 57 |
</li> |
| 58 |
{% endfor %} |
| 59 |
</ul> |
| f8cf54e9 Andy McCall ↶ |
60 |
</section> |
| 25ab8c73 Andy McCall ↶ |
61 |
{% endif %} |
| 62 |
|
| f8cf54e9 Andy McCall ↶ |
63 |
<section class="card-box"> |
| 64 |
<div class="card-head"><h2>Recent activity</h2></div> |
| 25ab8c73 Andy McCall ↶ |
65 |
{% if feed.is_empty() %} |
| 66 |
<p class="empty small">No activity yet. Push to a repository and it shows here.</p> |
| 67 |
{% else %} |
| 68 |
<ul class="feed"> |
| 69 |
{% for a in feed %} |
| 70 |
<li> |
| 10174045 Andy McCall ↶ |
71 |
<span class="who">{% if a.actor.is_empty() %}the hub{% else %}<img class="avatar xs" src="/avatar/{{ a.actor }}" alt=""> <a href="/{{ a.actor }}">{{ a.actor }}</a>{% endif %}</span> |
| 25ab8c73 Andy McCall ↶ |
72 |
{% if a.kind == "push" %}pushed <span class="lbl lbl-bm">{{ a.event }}</span> to |
| 73 |
{% else if a.kind == "release" %}published <a href="{{ a.url() }}">{{ a.title }}</a> in |
| 74 |
{% else %}{{ a.event }} {{ a.kind }} <a href="{{ a.url() }}">#{{ a.number }} {{ a.title }}</a> in |
| 75 |
{% endif %} |
| 76 |
<a href="/{{ a.owner }}/{{ a.name }}">{{ a.owner }}/{{ a.name }}</a> |
| 77 |
<time class="mute small" title="{{ a.at_ms|when_i }}">{{ a.at_ms|ago_i }}</time> |
| 78 |
</li> |
| 79 |
{% endfor %} |
| 80 |
</ul> |
| 81 |
{% endif %} |
| f8cf54e9 Andy McCall ↶ |
82 |
</section> |
| 25ab8c73 Andy McCall ↶ |
83 |
</div> |
| f8cf54e9 Andy McCall ↶ |
84 |
<aside class="side cards"> |
| 85 |
<section class="side-card"><h3>Your repositories <span class="count-chip">{{ mine.len() }}</span><a class="more" href="/new">+ New</a></h3><div class="body"> |
| 25ab8c73 Andy McCall ↶ |
86 |
{% if mine.is_empty() %} |
| 87 |
<p class="small mute">None yet. <a href="/new">Create one</a>, or <a href="/explore">explore</a>.</p> |
| 88 |
{% else %} |
| f8cf54e9 Andy McCall ↶ |
89 |
<ul class="plain repo-list"> |
| 25ab8c73 Andy McCall ↶ |
90 |
{% for r in mine %} |
| f8cf54e9 Andy McCall ↶ |
91 |
<li><a href="/{{ r.owner }}/{{ r.name }}" title="{{ r.owner }}/{{ r.name }}"><span class="mute">{{ r.owner }} /</span> {{ r.name }}</a>{% if r.visibility != "public" %}<span class="tag">{{ r.visibility }}</span>{% endif %}</li> |
| 25ab8c73 Andy McCall ↶ |
92 |
{% endfor %} |
| 93 |
</ul> |
| 94 |
{% endif %} |
| f8cf54e9 Andy McCall ↶ |
95 |
</div></section> |
| 25ab8c73 Andy McCall ↶ |
96 |
</aside> |
| 97 |
</div> |
| 98 |
{% endblock %} |