site_opytex/theme/templates/base.html

179 lines
5.5 KiB
HTML
Raw Permalink Normal View History

2019-07-18 10:43:36 +00:00
{% if 'jinja2.ext.i18n' not in JINJA_ENVIRONMENT.extensions and 'jinja2.ext.i18n' not in JINJA_EXTENSIONS %}
{% macro _(msg) %}
{{ msg % kwargs }}
{% endmacro %}
{% endif %}
<!DOCTYPE html>
<html lang="{{ DEFAULT_LANG }}">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
{% if page in hidden_pages %}
<meta name="robots" content="noindex, nofollow" />
{% else %}
<meta name="robots" content="{{ ROBOTS }}" />
{% endif %}
{% if USE_GOOGLE_FONTS != False %}
<link href="https://fonts.googleapis.com/css?family=Source+Code+Pro|Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
{% endif %}
{% if USE_LESS %}
<link rel="stylesheet/less" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/stylesheet/style.less">
<script src="//cdnjs.cloudflare.com/ajax/libs/less.js/2.5.1/less.min.js" type="text/javascript"></script>
{% else %}
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/stylesheet/style.min.css">
{% endif %}
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/pygments/{{ PYGMENTS_STYLE|default('github') }}.min.css">
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/font-awesome/css/font-awesome.min.css">
{% if CUSTOM_CSS %}
<link href="{{ SITEURL }}/{{ CUSTOM_CSS }}" rel="stylesheet">
{% endif %}
{% if FEED_ALL_ATOM %}
<link href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Atom">
{% endif %}
{% if FEED_ALL_RSS %}
<link href="{{ FEED_DOMAIN }}/{{ FEED_ALL_RSS }}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} RSS">
{% endif %}
{% if FAVICON %}
<link rel="shortcut icon" href="{{ FAVICON }}" type="image/x-icon">
<link rel="icon" href="{{ FAVICON }}" type="image/x-icon">
{% endif %}
{% if BROWSER_COLOR %}
<!-- Chrome, Firefox OS and Opera -->
<meta name="theme-color" content="{{ BROWSER_COLOR }}">
<!-- Windows Phone -->
<meta name="msapplication-navbutton-color" content="{{ BROWSER_COLOR }}">
<!-- iOS Safari -->
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<!-- Microsoft EDGE -->
<meta name="msapplication-TileColor" content="{{ BROWSER_COLOR }}">
{% endif %}
{% block meta %}
<meta name="author" content="{{ AUTHOR }}" />
<meta name="description" content="{{ SITEDESCRIPTION }}" />
{% include "partial/og.html" %}
{% endblock %}
<title>{{ SITENAME }}{% block title %}{% endblock %}</title>
</head>
<body>
<aside>
<div>
2020-06-05 08:41:20 +00:00
<!--
2019-07-18 10:43:36 +00:00
<a href="{{ SITEURL }}/">
{% if SITELOGO %}
<img src="{{ SITELOGO }}" alt="{{ SITETITLE }}" title="{{ SITETITLE }}">
{% else %}
<img src="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/img/profile.png" alt="{{ SITETITLE }}" title="{{ SITETITLE }}">
{% endif %}
</a>
2020-06-05 08:41:20 +00:00
-->
<h1><a href="/">{{ SITETITLE }}</a></h1>
2019-07-18 10:43:36 +00:00
{% if SITESUBTITLE %}<p><a href="{{ SITEURL }}/">{{ SITESUBTITLE }}</a></p>{% endif %}
2019-07-18 10:43:36 +00:00
2020-06-05 08:41:20 +00:00
<!--
2019-07-18 10:43:36 +00:00
<h2>Années</h2>
<nav>
<ul class="list">
{% for name, link in LINKS %}
<li><a href="{{ link }}">{{ name }}</a></li>
{% endfor %}
</ul>
</nav>
2020-06-05 08:41:20 +00:00
-->
2019-07-18 10:43:36 +00:00
<h2>Niveaux</h2>
<nav>
<ul class="list">
{% for category, articles in categories|sort %}
2020-06-30 12:28:14 +00:00
<li><a href="{{ SITEURL }}/{{ category.url }}">{{ category }} ({{ articles|count }})</a></li>
2019-07-18 10:43:36 +00:00
{% endfor %}
</ul>
2020-06-30 12:28:14 +00:00
2019-07-18 10:43:36 +00:00
</nav>
<h2><a href="{{ SITEURL }}/tags.html">
Thèmes
</a></h2>
<nav>
2020-06-30 12:28:14 +00:00
<ul class="tagcloud">
{% for tag in tag_cloud %}
<li class="tag-{{ tag.1 }}">
<a href="{{ SITEURL }}/{{ tag.0.url }}">
{{ tag.0 }}
{% if TAG_CLOUD_BADGE %}
<span class="badge">{{ tag.2 }}</span>
{% endif %}
</a>
</li>
{% endfor %}
</ul>
2019-07-18 10:43:36 +00:00
</nav>
</div>
</aside>
<main>
{% if MAIN_MENU %}
<nav>
{% for title, link in MENUITEMS %}
<a href="{{ link }}">{{ title }}</a>
{% endfor %}
{% if FEED_ALL_ATOM %}
<a href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}">{{ _('Atom') }}</a>
{% endif %}
{% if FEED_ALL_RSS %}
<a href="{{ FEED_DOMAIN }}/{{ FEED_ALL_RSS }}">{{ _('RSS') }}</a>
{% endif %}
</nav>
{% endif %}
{% block content %}
{% endblock %}
<footer>
{% if CC_LICENSE %}
{% include "partial/cc_license.html" %}
{% else %}
{% include "partial/copyright.html" %}
{% endif %}
</footer>
</main>
{% if GUAGES %}
{% include "partial/guages.html" %}
{% endif %}
{% if ADD_THIS_ID %}
<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid={{ ADD_THIS_ID }}" async="async"></script>
{% endif %}
{% if PIWIK_URL and PIWIK_SITE_ID %}
{% include "partial/piwik.html" %}
{% endif %}
{% include "partial/jsonld.html" %}
{% block additional_js %}{% endblock %}
{% if GITHUB_CORNER_URL %}
{% include 'partial/github.html' %}
{% endif %}
2022-06-15 07:26:27 +00:00
<script type="text/javascript" async defer data-website-id="2cb9cd4c-66da-4e4f-9e84-a2d53c7b07bc" src="https://stat.opytex.org/umami.js"></script>
2019-07-18 10:43:36 +00:00
</body>
</html>