Melodia/web/views/templates/base

86 lines
1.9 KiB
Django/Jinja

{% comment %}
List of block elements in this page:
page_title
navbar_title
navbar_content
sidebar
sidebar_content
body
body_content
scripts
global_scripts
page_scripts
{% endcomment %}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>{% block page_title %}{% endblock %}</title>
<link href="{{ STATIC_URL }}css/bootstrap.min.css" rel="stylesheet">
<style>
body {
padding-top: 60px; /* Make sure that there is a gap on the navbar. */
}
</style>
</head>
<body>
{# Navbar code #}
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="#">{% block navbar_title %}{% endblock %}</a>
{% block navbar_content %}{% endblock %}
</div>
</div>
</div>
<div class="container-fluid">
<div class="row-fluid">
{# Sidebar code #}
{# Note that the sidebar is its own block, so we can remove it if need be. #}
{% block sidebar %}
<div class="span3">
<div class="well sidebar-nav">
{% block sidebar_content %}{% endblock %}
</div>
</div>
{% endblock %}
{% block body %}
<div class="span9">
{% block body_content %}{% endblock %}
</div>
{% endblock %}
</div>
</div>
</body>
{# General scripts #}
{% block scripts %}
<script type="text/javascript" src="{{ STATIC_URL }}js/jquery.min.js"></script>
<script type="text/javascript" src="{{ STATIC_URL }}js/jquery-ui.min.js"></script>
<script type="text/javascript" src="{{ STATIC_URL }}js/bootstrap.min.js"></script>
{% block global_scripts %}
<script type="text/javascript">
{# Scripts used globally go here. #}
</script>
{% endblock %}
<script type="text/javascript">
{% block page_scripts %}
{# This block is used by each page if they want to add additional scripts. #}
{% endblock %}
</script>
{% endblock %}{# endblock scripts #}
</html>
<!-- vim: ft=htmldjango