diff options
author | Justin Mayer <entroP@gmail.com> | 2017-09-04 11:06:52 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-04 11:06:52 -0700 |
commit | dcecbb6085f24420b14d97f06c53f49755db95c9 (patch) | |
tree | 3de8977ed3665245ada9c94f8e0b95f77cdc929d /pelican-bootstrap3/templates | |
parent | 7fc1dbfcf93232725006882210f434e6561cf7dd (diff) | |
parent | 09aae94c108f54b99614ac0747c24287dbce115d (diff) | |
download | pelican-themes-dcecbb6085f24420b14d97f06c53f49755db95c9.tar.gz |
Merge pull request #531 from josch/authors-sidebar
pelican-bootstrap3: Add authors to sidebar
Diffstat (limited to 'pelican-bootstrap3/templates')
-rw-r--r-- | pelican-bootstrap3/templates/includes/sidebar.html | 1 | ||||
-rw-r--r-- | pelican-bootstrap3/templates/includes/sidebar/authors.html | 22 |
2 files changed, 23 insertions, 0 deletions
diff --git a/pelican-bootstrap3/templates/includes/sidebar.html b/pelican-bootstrap3/templates/includes/sidebar.html index 7772ff8..d83a7b8 100644 --- a/pelican-bootstrap3/templates/includes/sidebar.html +++ b/pelican-bootstrap3/templates/includes/sidebar.html @@ -10,6 +10,7 @@ {% include 'includes/sidebar/github.html' %} {% include 'includes/sidebar/twitter_timeline.html' %} {% include 'includes/sidebar/links.html' %} + {% include 'includes/sidebar/authors.html' %} {% include 'includes/sidebar/images.html' %} {% include 'includes/sidebar/optional_bottom.html' ignore missing %} </ul> diff --git a/pelican-bootstrap3/templates/includes/sidebar/authors.html b/pelican-bootstrap3/templates/includes/sidebar/authors.html new file mode 100644 index 0000000..114c688 --- /dev/null +++ b/pelican-bootstrap3/templates/includes/sidebar/authors.html @@ -0,0 +1,22 @@ +{% if DISPLAY_AUTHORS_ON_SIDEBAR %} + {% from 'includes/sidebar/macros.jinja' import title %} + +<!-- Sidebar/Authors --> +<li class="list-group-item"> + <h4>{{ title(_('Authors'), DISABLE_SIDEBAR_TITLE_ICONS) }}</h4> + <ul class="list-group" id="authors"> + {% for author, articles in authors|sort %} + <li class="list-group-item"> + <a href="{{ SITEURL }}/{{ author.url }}"> + {%- if not DISABLE_SIDEBAR_TITLE_ICONS -%} + <i class="fa fa-user fa-lg"></i> + {%- endif -%} + {{- author -}} + </a> + ({{ articles|count }}) + </li> + {% endfor %} + </ul> +</li> +<!-- End Sidebar/Authors --> +{% endif %} |