Commit 4df78d17 authored by Matthieu Gautier's avatar Matthieu Gautier
Browse files

Utilisation de l'attribut 'index-style' pour spécifier le style css.

parent d7ad1e51
......@@ -23,13 +23,12 @@
<!--%
mpages = [p for p in pages if "menu-position" in p]
mpages.sort(key=lambda p: int(p["menu-position"]))
entry = '''<div class="%(header_style)s index-entry">
<div class="content">
<a href="%(url)s">%(title)s</a>'
</div></div>'''
entry = '''<div class="%(index-style)s index-entry">
<div class="content">
<a href="%(url)s">%(title)s</a>'
</div></div>'''
for p in mpages:
style = p.get('title-style', "pure-u-1 pure-u-md-1-4 pure-u-lg-1-4")
print(entry%dict(list(p.items()) +[('header_style', style)]))
print(entry%p)
%-->
</div>
</div>
......
menu-position: 3
title: Parlons XMPP - épisode 6 - les commandes à distance
index-style: xmpp pure-u-1 pure-u-md-1-3
authors: Goffi
date: 2015-07-27T12:31:53+02:00
license: CC by-sa
......
menu-position: 3
title: Présentation d'idée : PGPID
index-style: pgpid pure-u-1 pure-u-md-1-3
authors: GaMa
date: 2013-07-23T00:59:56+02:00
license: CC by-sa
......
menu-position: 4
title: Red Hat Enterprise Linux 6.7
title-style: pure-u-1 pure-u-md-1-2
index-style: redhat pure-u-1 pure-u-md-1-3
authors: Nils Ratusznik
Yvan Munoz, BAud, palm123, Nÿco, patrick_g, eggman, Stéphane Aulery et Benoît Sibaud
date: 2015-05-06T10:17:16+02:00
......
menu-position: 1
title: Sortie de Fedora 22
title-style: pure-u-1 pure-u-md-1-2
index-style: fedora_22 pure-u-1 pure-u-md-2-3
authors: M5oul
Stéphane Aulery, eggman, BAud, palm123, Renault, Sébastien Wilmet, Nils Ratusznik, CheckMatt, Benoît Sibaud, Julien.D, Jiehong et Atem18
date: 2015-04-21T20:17:12+02:00
......
menu-position: 2
title: Sortie du noyau Linux 4.1
index-style: linux_41 pure-u-1 pure-u-md-1-3
authors: Martin Peres
eggman, Davy Defaud, Siosm, BAud, palm123, M5oul, alpha_one_x86, Stéphane Aulery, Mali, tiwaz, Romain Perier, xaccrocheur, Olivier Esver, Xavier Claude, Benoît Sibaud, jcr83, pums974, ʭ ☯ , Nÿco, mimaison, Ytterbium, Segfault, Kioob, Vincent Meurisse, titinux, EdB et Jiehong
date: 2015-04-25T00:19:43+02:00
......
......@@ -23,3 +23,19 @@
background: #3c6eb4; /* fedora blue */
color: white;
}
.fedora_22 .content {
background: #db3279;
}
.linux_41 .content {
background: #e59728;
}
.xmpp .content {
background: #a07cbc;
}
.redhat .content {
background: #79db32;
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment