diff options
author | Jeffrey Tse <jeffreytse.mail@gmail.com> | 2019-09-11 12:19:34 +0800 |
---|---|---|
committer | Jeffrey Tse <jeffreytse.mail@gmail.com> | 2019-09-11 12:21:17 +0800 |
commit | 61eae5c5f9881cab29712f6e696085baa977e1f9 (patch) | |
tree | bb301b58b94fee5dcefbdfae8f0c8fc13ee5bd21 /_includes/sidebar/common-list.html | |
parent | cd3a8163dd997d0a7c4d320816651efa8f7dce60 (diff) |
release: v1.0.0
Diffstat (limited to '_includes/sidebar/common-list.html')
-rw-r--r-- | _includes/sidebar/common-list.html | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/_includes/sidebar/common-list.html b/_includes/sidebar/common-list.html new file mode 100644 index 0000000..7e7bf96 --- /dev/null +++ b/_includes/sidebar/common-list.html @@ -0,0 +1,25 @@ +{%- if include.keys -%} + {%- assign keys = include.keys -%} +{%- endif -%} + +{%- if include.field -%} + {%- assign field = include.field -%} +{%- endif -%} + +<div class="common-list"> + <ul> + <li> + <a href="/index.html"> + All<span>{{ site.posts.size }}</span> + </a> + </li> + + {% for key in keys %} + <li> + <a href="{{ url }}#h-{{ key }}"> + {{ key }} <span>{{ site.posts | where: field, key | size }}</span> + </a> + </li> + {% endfor %} + </ul> +</div> |