Issue #3 List of pages (long and short)

This commit is contained in:
Alexis Hassler
2019-05-16 18:46:58 +02:00
parent 6689a5faa5
commit a9c6585252
9 changed files with 54 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ menu: ['global']
<ul class="columns">
{%- for page in wiki_pages -%}
<li>
<a href="/{{ page.slug }}.html">{{ page.title }}</a>
<a href="{{ page.url }}.html">{{ page.title }}</a>&nbsp; [{{ page.bytes }} bytes]
{%- if page.author -%}&nbsp;(by <a href="/{{ site.data.i18n[site.lang].prefix.user }}{{ page.author }}.html">{{ page.author }}</a>) {%- endif -%}
</li>
{%- endfor -%}

View File

@@ -0,0 +1,14 @@
---
layout: default
title: Long pages
menu: ['global']
---
{%- include /functions/wiki-pages.html -%}
{%- assign long_pages = wiki_pages | sort: 'bytes' | reverse -%}
<ol>
{%- for page in long_pages limit:50 -%}
<li>
<a href="{{ page.url }}.html">{{ page.title }}</a>&nbsp; [{{ page.bytes }} bytes]
</li>
{%- endfor -%}
</ol>

View File

@@ -8,7 +8,7 @@ menu: ['global']
<ul>
{%- for page in recent_changes limit:20 -%}
<li>
<a href="/{{ page.slug }}.html">{{ page.title }}</a>
<a href="{{ page.url }}.html">{{ page.title }}</a>
&nbsp;- {{ page.modified }}
</li>
{%- endfor -%}

View File

@@ -0,0 +1,14 @@
---
layout: default
title: Short pages
menu: ['global']
---
{%- include /functions/wiki-pages.html -%}
{%- assign long_pages = wiki_pages | sort: 'bytes' -%}
<ol>
{%- for page in long_pages limit:50 -%}
<li>
<a href="{{ page.url }}.html">{{ page.title }}</a>&nbsp; [{{ page.bytes }} bytes]
</li>
{%- endfor -%}
</ol>