{#
    cloud/layout.html
    ~~~~~~~~~~~~~~~~~

    Sphinx layout template for the cloud theme.

    :copyright: Copyright 2009-2011 Assurance Technologies LLC
    :license: BSD

    roottarget - optional target for root link (default to toc)
    logotarget - optional target for logo link (defaults to root target)
#}

{% extends "basic/layout.html" %}

{# add script file to instrument collapsable sections #}
{% set script_files = script_files + ['_static/toggle_sections.js'] %}

{# add font stylesheets #}
{% set css_files = css_files + [theme_fontcssurl] %}

{# make root link redirectable #}
{%- set theme_roottarget = (theme_roottarget == "<toc>" and master_doc or theme_roottarget) %}
{% block rootrellink %}
    <li><a href="{{ pathto(theme_roottarget) }}">{{project}} Documentation</a> &raquo; </li>
{% endblock %}

{# make logo link redirectable #}
{%- set theme_logotarget = (theme_logotarget == "<root>" and theme_roottarget or (theme_logotarget == "<toc>" and master_doc or theme_logotarget)) %}
{%- block sidebarlogo %}
    {%- if logo %}
        <p class="logo"><a href="{{ pathto(theme_logotarget) }}">
          <img class="logo" src="{{ pathto('_static/' + logo, 1) }}" alt="Logo"/>
        </a></p>
    {%- endif %}
{%- endblock %}

{# wrap relbars in distinct classes to make themeing easier #}
{%- block relbar1 %}
    <div class="relbar-top">
        {{ super() }}
    </div>
{% endblock %}

{%- block relbar2 %}
    <div class="relbar-bottom">
        {{ super() }}
    </div>
{% endblock %}
