{% extends "!layout.html" %}

{% block rootrellink %}
        {% if pagename != 'index' %}
        <li class="active"><a href="{{ pathto('index') }}">{{ shorttitle|e }}</a></li>
        {% endif %}
{% endblock %}

{% block sidebarsearch %}
{%- if sourcename %}
<ul class="this-page-menu">
{%- if 'reference/generated' in sourcename %}
  <li><a href="/numpy/docs/{{ sourcename.replace('reference/generated/', '').replace('.txt', '') |e }}">{{_('Edit page')}}</a></li>
{%- else %}
  <li><a href="/numpy/docs/numpy-docs/{{ sourcename.replace('.txt', '.rst') |e }}">{{_('Edit page')}}</a></li>
{%- endif %}
</ul>
{%- endif %}
{{ super() }}
{% endblock %}
