{% if page.author_profile or layout.author_profile or page.sidebar or page.layout=="textbook" %}
{% if page.author_profile or layout.author_profile %}{% include author-profile.html %}{% endif %}
{% if page.sidebar or page.layout=='textbook' %}
{% if page.layout=='textbook' and site.textbook_logo %}{% endif %}
{% for s in page.sidebar %}
{% if s.image %}
{% endif %}
{% if s.title %}
{{ s.title }}
{% endif %}
{% if s.text %}{{ s.text | markdownify }}{% endif %}
{% endfor %}
{% if page.layout=='textbook' %}
{% include nav_list textbook=true %}
{% elsif page.sidebar.nav %}
{% include nav_list nav=page.sidebar.nav %}
{% endif %}
{% endif %}