99 lines
3.7 KiB
HTML
99 lines
3.7 KiB
HTML
{% comment %}
|
|
Base website template. It displays various elements depending on context
|
|
variables.
|
|
|
|
Usefull context:
|
|
- cover: image cover
|
|
- site: current website
|
|
- model: view model or displayed `object`'s
|
|
- sidebar_object_list: item to display in sidebar
|
|
- sidebar_url_name: url name sidebar item complete list
|
|
- sidebar_url_parent: parent page for sidebar items complete list
|
|
{% endcomment %}
|
|
{% load static i18n thumbnail aircox %}
|
|
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<meta name="application-name" content="aircox" />
|
|
<meta name="description" content="{{ site.description }}" />
|
|
<meta name="keywords" content="{{ site.tags }}" />
|
|
<meta name="generator" content="Aircox" />
|
|
<link rel="icon" href="{% thumbnail site.favicon 32x32 crop %}" />
|
|
|
|
{% block assets %}
|
|
<link rel="stylesheet" type="text/css" href="{% static "aircox/css/chunk-common.css" %}"/>
|
|
<link rel="stylesheet" type="text/css" href="{% static "aircox/css/chunk-vendors.css" %}"/>
|
|
<script src="{% static "aircox/js/chunk-common.js" %}"></script>
|
|
<script src="{% static "aircox/js/chunk-vendors.js" %}"></script>
|
|
<script src="{% static "aircox/js/core.js" %}"></script>
|
|
{% endblock %}
|
|
|
|
<title>
|
|
{% block head_title %}
|
|
{% if page and page.title %}{{ page.title }} — {{ station.name }}
|
|
{% else %}{{ station.name }}
|
|
{% endif %}
|
|
{% endblock %}
|
|
</title>
|
|
|
|
{% block head_extra %}{% endblock %}
|
|
</head>
|
|
<body>
|
|
<script id="init-script">
|
|
window.addEventListener('load', function() {
|
|
{% block init-scripts %}
|
|
aircox.init(null, {hotReload:window})
|
|
{% endblock %}
|
|
})
|
|
</script>
|
|
<div id="app">
|
|
<div class="container">
|
|
{% block nav %}
|
|
<nav class="nav primary" role="navigation" aria-label="main navigation">
|
|
{% block nav-primary %}
|
|
<a class="navbar-brand" href="{% url "home" %}">
|
|
<img src="{{ station.logo.url }}">
|
|
</a>
|
|
<div class="navbar-menu">
|
|
{% block nav-primary-menu %}
|
|
{% nav_items "top" css_class="nav-item" active_class="active" as items %}
|
|
{% for item, render in items %}
|
|
{{ render }}
|
|
{% endfor %}
|
|
{% endblock %}
|
|
</div>
|
|
{% endblock %}
|
|
</nav>
|
|
{% endblock %}
|
|
{% block secondary-nav %}{% endblock %}
|
|
</div>
|
|
|
|
{% block main-container %}
|
|
<main class="page">
|
|
{% block main %}
|
|
<header class="container header {% if cover %}has-cover{% endif %}">
|
|
{% block header %}
|
|
{% include header_template_name|default:"./widgets/header.html" %}
|
|
{% endblock %}
|
|
</header>
|
|
|
|
{% block content-container %}
|
|
<div class="container content">
|
|
{% block content %}
|
|
{% if page and page.content %}
|
|
<section class="page-content mb-2">{{ page.content|safe }}</section>
|
|
{% endif %}
|
|
{% endblock %}
|
|
</div>
|
|
{% endblock %}
|
|
{% endblock %}
|
|
</main>
|
|
{% endblock %}
|
|
</div>
|
|
{% block player-container %}
|
|
<div id="player">{% include "aircox/widgets/player.html" %}</div>
|
|
{% endblock %}
|
|
</body>
|
|
</html>
|