summaryrefslogtreecommitdiffstats
path: root/gitsrht/templates/repo.html
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-09-21 15:32:22 -0400
committerDrew DeVault <sir@cmpwn.com>2018-09-21 15:32:22 -0400
commitf992ceccbf47a3e19ac45d17d624002a422fd2af (patch)
treec1df5ed4cb73f4a10bdd17ec8e8577a1e253719f /gitsrht/templates/repo.html
parent06b626de4cf86356b07b655e0cc7d3e631aa71aa (diff)
Mock up tree page
Diffstat (limited to 'gitsrht/templates/repo.html')
-rw-r--r--gitsrht/templates/repo.html13
1 files changed, 11 insertions, 2 deletions
diff --git a/gitsrht/templates/repo.html b/gitsrht/templates/repo.html
index 7f5fab0..1f3c855 100644
--- a/gitsrht/templates/repo.html
+++ b/gitsrht/templates/repo.html
@@ -9,12 +9,21 @@
>{{owner.canonical_name}}</a>/{{repo.name}}
</h2>
{% block tabs %}
+ {% macro link(path, title) %}
+ <a
+ class="nav-link {% if view == title %}active{% endif %}"
+ href="{{ path }}">{{ title }}</a>
+ {% endmacro %}
<ul class="nav nav-tabs">
<li class="nav-item">
- <a class="nav-link active" href="#">summary</a>
+ {{ link(url_for("repo.summary",
+ owner=repo.owner.canonical_name,
+ repo=repo.name), "summary") }}
</li>
<li class="nav-item">
- <a class="nav-link" href="#">tree</a>
+ {{ link(url_for("repo.tree",
+ owner=repo.owner.canonical_name,
+ repo=repo.name), "tree") }}
</li>
<li class="nav-item">
<a class="nav-link" href="#">log</a>