lectures.alex.balgavy.eu

Lecture notes from university.
git clone git://git.alex.balgavy.eu/lectures.alex.balgavy.eu.git
Log | Files | Refs | Submodules

page.html (973B)


      1 {% extends "base.html" %}
      2 
      3 {% block title %}{{ page.title }}{% endblock title %}
      4 
      5 {% block sidebar %}
      6 {% set parent_section = get_section(path=page.ancestors | last) %}
      7 <h1><a href="{{ parent_section.permalink }}">{{ parent_section.title }}</a></h1>
      8 
      9 {% if page.toc %}
     10 <h2>Table of Contents</h2>
     11 <ul>
     12   {% for h1 in page.toc %}
     13   <li>
     14     <a href="{{h1.permalink | safe}}">{{ h1.title }}</a>
     15     {% if h1.children %}
     16     <ul>
     17       {% for h2 in h1.children %}
     18       <li>
     19         <a href="{{h2.permalink | safe}}">{{ h2.title }}</a>
     20         {% if h2.children %}
     21         <ul>
     22           {% for h3 in h2.children %}
     23           <li><a href="{{h3.permalink}}">{{h3.title }}</a></li>
     24           {% endfor %}
     25         </ul>
     26         {% endif %}
     27       </li>
     28       {% endfor %}
     29     </ul>
     30     {% endif %}
     31   </li>
     32   {% endfor %}
     33 </ul>
     34 {% endif %}
     35 {% endblock sidebar %}
     36 
     37 {% block content %}
     38 {{ page.content | replace(from="<img ", to="<img loading=lazy ") | safe }}
     39 {% endblock content %}