Skip to content

Commit

Permalink
Create tags listing page
Browse files Browse the repository at this point in the history
  • Loading branch information
alecharp committed Oct 17, 2014
1 parent 6281b03 commit 9658cee
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 2 deletions.
3 changes: 2 additions & 1 deletion _includes/sidebar.html
Expand Up @@ -9,8 +9,9 @@ <h1><a href="/">Adrien Lecharpentier</a></h1>

<nav class="nav" id="menu">
<ul>
<li><a class="pure-button" href="{{site.baseurl}}/tags"><i class="fa fa-tags"></i> Tags</a></li>
<li><a class="pure-button" href="{{site.baseurl}}/archives"><i class="fa fa-archive"></i> Archives</a></li>
<li><a class="pure-button" href="{{site.baseurl}}/apropos"><i class="fa fa-question"></i> À propos</a></li>
<li><a class="pure-button" href="{{site.baseurl}}/apropos"><i class="fa fa-info"></i> À propos</a></li>
<li><a class="pure-button" target="_blank" href="https://drive.google.com/file/d/0BzRjeTUP87fJZ1U5d2J3eWZ4OWs/edit">CV fr</a></li>
<li><a class="pure-button" target="_blank" href="https://drive.google.com/file/d/0BzRjeTUP87fJXzlTVGxyNGpQQjg/edit">CV en</a></li>
</ul>
Expand Down
2 changes: 1 addition & 1 deletion _layouts/default.html
Expand Up @@ -7,7 +7,7 @@
<link href="/atom.xml" rel="alternate" title="Adrien Lecharpentier's blog ATOM" type="application/atom+xml" />
<meta name="viewport" content="initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,width=device-width,user-scalable=no">

<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet">
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">
<link rel="stylesheet" href="{{site.baseurl}}/resources/css/main.css" type="text/css" />
<style type="text/css">
{% if page.banner %}
Expand Down
1 change: 1 addition & 0 deletions _sass/alecharp.scss
Expand Up @@ -129,6 +129,7 @@ article {
border-radius: .25em;
color: #fff;
font-size: 0.7em;
a, a:hover { color: inherit }
}
}
p { text-align: justify; }
Expand Down
33 changes: 33 additions & 0 deletions tags.html
@@ -0,0 +1,33 @@
---
layout: default
---

<article>
<div class="tag-list">
{% for tag in site.tags %}
<span class="tag">
<a href="#{{ tag[0] }}-ref">{{tag[0]}}</a>
</span>
{% endfor %}
</div>
</article>

<div>
{% for tag in site.tags %}
<h2 id="{{tag[0]}}-ref">{{tag[0]}} ({{tag[1]|size}})</h2>
<ul>
{% assign pages_list = tag[1] %}

{% for node in pages_list %}
{% if node.title != null %}
{% if group == null or group == node.group %}
<li><a href="{{ site.baseurl }}{{node.url}}">{{node.title}}</a></li>
{% endif %}
{% endif %}
{% endfor %}
{% assign pages_list = nil %}
{% assign group = nil %}

</ul>
{% endfor %}
</div>

0 comments on commit 9658cee

Please sign in to comment.