{% extends "pydata_sphinx_theme/layout.html" %}
{# ref: https://github.com/pydata/pydata-sphinx-theme/blob/master/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/layout.html #}

{% block docs_main %}
{# A tiny helper pixel to detect if we've scrolled #}
<div class="sbt-scroll-pixel-helper"></div>
{{ super() }}
{% endblock %}


{% block docs_body %}
{# Table of contents that is only displayed when printing the page #}
<div id="jb-print-docs-body" class="onlyprint">
    <h1>{{ pagetitle }}</h1>
    <!-- Table of contents -->
    <div id="print-main-content">
        <div id="jb-print-toc">
            {% set page_toc = generate_toc_html() %}
            {%- if page_toc | length >= 1 %}
            <div>
                <h2> {{ translate(theme_toc_title) }} </h2>
            </div>
            <nav aria-label="Page">
                {{ page_toc }}
            </nav>
            {%- endif %}
        </div>
    </div>
</div>
{{ super() }}
{% endblock %}
