more updates to match new code, new entry for testing
This commit is contained in:
parent
46751d66ca
commit
008d2d760c
140 changed files with 17228 additions and 12 deletions
13
themes/hyde/templates/archiveindex.tmpl
Normal file
13
themes/hyde/templates/archiveindex.tmpl
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% extends 'index.tmpl' %}
|
||||
|
||||
{% block extra_head %}
|
||||
{{ super() }}
|
||||
{% if translations|length > 1 and generate_atom %}
|
||||
{% for language in translations|sort %}
|
||||
<link rel="alternate" type="application/atom+xml" title="Atom for the {{ archive_name }} section ({{ language }})" href="{{ _link("archive_atom", archive_name, language) }}">
|
||||
{% endfor %}
|
||||
{% elif generate_atom %}
|
||||
<link rel="alternate" type="application/atom+xml" title="Atom for the {{ archive_name }} archive" href="{{ _link("archive_atom", archive_name) }}">
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
39
themes/hyde/templates/base.tmpl
Normal file
39
themes/hyde/templates/base.tmpl
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% import 'base_helper.tmpl' as base with context %}
|
||||
{% import 'base_header.tmpl' as header with context %}
|
||||
{% import 'base_footer.tmpl' as footer with context %}
|
||||
{{ set_locale(lang) }}
|
||||
{{ base.html_headstart() }}
|
||||
{% block extra_head %}
|
||||
{# Leave this block alone. #}
|
||||
{% endblock %}
|
||||
{{ template_hooks['extra_head']() }}
|
||||
</head>
|
||||
<body class="{{ hyde_subtheme }}">
|
||||
<a href="#content" class="sr-only sr-only-focusable">{{ messages("Skip to main content") }}</a>
|
||||
|
||||
<div class="hsidebar">
|
||||
<div class="container sidebar-sticky">
|
||||
<div class="sidebar-about">
|
||||
<h1>
|
||||
<a href="{{ abs_link(_link("root", None, lang)) }}">
|
||||
{{ header.html_site_title() }}
|
||||
</a>
|
||||
</h1>
|
||||
{{ header.html_site_description() }}
|
||||
</div>
|
||||
{{ header.html_navigation_links() }}
|
||||
{{ footer.html_footer() }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="content container" id="content">
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
|
||||
{% block extra_js %}{% endblock %}
|
||||
{{ body_end }}
|
||||
{{ template_hooks['body_end']() }}
|
||||
{{ base.late_load_js() }}
|
||||
</body>
|
||||
</html>
|
||||
14
themes/hyde/templates/base_footer.tmpl
Normal file
14
themes/hyde/templates/base_footer.tmpl
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% import 'base_helper.tmpl' as base with context %}
|
||||
|
||||
{% macro html_footer() %}
|
||||
{% if content_footer %}
|
||||
<footer id="footer">
|
||||
<span class="copyright">
|
||||
{{ content_footer }}
|
||||
</span>
|
||||
</p>
|
||||
{{ template_hooks['page_footer']() }}
|
||||
</footer>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
53
themes/hyde/templates/base_header.tmpl
Normal file
53
themes/hyde/templates/base_header.tmpl
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% import 'base_helper.tmpl' as base with context %}
|
||||
|
||||
{% macro html_header() %}
|
||||
<header id="header">
|
||||
{{ html_site_title() }}
|
||||
{{ html_site_description() }}
|
||||
{{ html_translation_header() }}
|
||||
{{ html_navigation_links() }}
|
||||
{% if search_form %}
|
||||
<div class="searchform" role="search">
|
||||
{{ search_form }}
|
||||
</div>
|
||||
{% endif %}
|
||||
</header>
|
||||
{{ template_hooks['page_header']() }}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_site_description() %}
|
||||
<p class="lead">{{ blog_description|e }}</p>
|
||||
{% endmacro %}
|
||||
|
||||
|
||||
{% macro html_site_title() %}
|
||||
<h1 id="brand"><a href="{{ abs_link(_link("root", None, lang)) }}" title="{{ blog_title|e }}" rel="home">
|
||||
{% if logo_url %}
|
||||
<img src="{{ logo_url }}" alt="{{ blog_title|e }}" id="logo">
|
||||
{% endif %}
|
||||
|
||||
{% if show_blog_title %}
|
||||
<span id="blog-title">{{ blog_title|e }}</span>
|
||||
{% endif %}
|
||||
</a></h1>
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_navigation_links() %}
|
||||
<nav id="menu" role="navigation" class="sidebar-nav">
|
||||
{% for url, text in navigation_links[lang] %}
|
||||
<a class="sidebar-nav-item" href="{{url}}">{{text}}</a>
|
||||
{% endfor %}
|
||||
{{ template_hooks['menu']() }}
|
||||
{{ template_hooks['menu_alt']() }}
|
||||
</nav>
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_translation_header() %}
|
||||
{% if translations|length > 1 %}
|
||||
<div id="toptranslations">
|
||||
<h2>{{ messages("Languages:") }}</h2>
|
||||
{{ base.html_translations() }}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
125
themes/hyde/templates/base_helper.tmpl
Normal file
125
themes/hyde/templates/base_helper.tmpl
Normal file
|
|
@ -0,0 +1,125 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
|
||||
{% macro html_headstart() %}
|
||||
<!DOCTYPE html>
|
||||
<html \
|
||||
prefix='
|
||||
{% if use_open_graph or (twitter_card and twitter_card['use_twitter_cards']) %}
|
||||
og: http://ogp.me/ns# article: http://ogp.me/ns/article#
|
||||
{% endif %}
|
||||
{% if comment_system == 'facebook' %}
|
||||
fb: http://ogp.me/ns/fb#
|
||||
{% endif %}
|
||||
' \
|
||||
{% if use_open_graph or (twitter_card and twitter_card['use_twitter_cards']) %}
|
||||
vocab="http://ogp.me/ns" \
|
||||
{% endif %}
|
||||
{% if is_rtl %}
|
||||
dir="rtl"
|
||||
{% endif %}
|
||||
|
||||
lang="{{ lang }}">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
{% if use_base_tag %}
|
||||
<base href="{{ abs_link(permalink) }}">
|
||||
{% endif %}
|
||||
{% if description %}
|
||||
<meta name="description" content="{{ description|e }}">
|
||||
{% endif %}
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
{% if title == blog_title %}
|
||||
<title>{{ blog_title|e }}</title>
|
||||
{% else %}
|
||||
<title>{{ blog_title|e }} · {{ title|e }} </title>
|
||||
{% endif %}
|
||||
|
||||
{{ html_stylesheets() }}
|
||||
<meta content="{{ theme_color }}" name="theme-color">
|
||||
{{ html_feedlinks() }}
|
||||
<link rel="canonical" href="{{ abs_link(permalink) }}">
|
||||
|
||||
{% if favicons %}
|
||||
{% for name, file, size in favicons %}
|
||||
<link rel="{{ name }}" href="{{ file }}" sizes="{{ size }}"/>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if comment_system == 'facebook' %}
|
||||
<meta property="fb:app_id" content="{{ comment_system_id }}">
|
||||
{% endif %}
|
||||
|
||||
{% if prevlink %}
|
||||
<link rel="prev" href="{{ prevlink }}" type="text/html">
|
||||
{% endif %}
|
||||
{% if nextlink %}
|
||||
<link rel="next" href="{{ nextlink }}" type="text/html">
|
||||
{% endif %}
|
||||
|
||||
{{ mathjax_config }}
|
||||
{% if use_cdn %}
|
||||
<!--[if lt IE 9]><script src="https://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
|
||||
{% else %}
|
||||
<!--[if lt IE 9]><script src="{{ url_replacer(permalink, '/assets/js/html5.js', lang) }}"></script><![endif]-->
|
||||
{% endif %}
|
||||
|
||||
{{ extra_head_data }}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro late_load_js() %}
|
||||
{{ social_buttons_code }}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_stylesheets() %}
|
||||
{% if use_bundles %}
|
||||
<link href="/assets/css/all.css" rel="stylesheet" type="text/css">
|
||||
{% else %}
|
||||
<link href="/assets/css/rst.css" rel="stylesheet" type="text/css">
|
||||
<link href="/assets/css/poole.css" rel="stylesheet" type="text/css">
|
||||
<link href="/assets/css/hyde.css" rel="stylesheet" type="text/css">
|
||||
<link href="/assets/css/code.css" rel="stylesheet" type="text/css">
|
||||
{% if has_custom_css %}
|
||||
<link href="/assets/css/custom.css" rel="stylesheet" type="text/css">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% if needs_ipython_css %}
|
||||
<link href="/assets/css/ipython.min.css" rel="stylesheet" type="text/css">
|
||||
<link href="/assets/css/nikola_ipython.css" rel="stylesheet" type="text/css">
|
||||
{% endif %}
|
||||
|
||||
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=PT+Sans:400,400italic,700|Abril+Fatface">
|
||||
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_feedlinks() %}
|
||||
{% if rss_link %}
|
||||
{{ rss_link }}
|
||||
{% elif generate_rss %}
|
||||
{% if translations|length > 1 %}
|
||||
{% for language in translations|sort %}
|
||||
<link rel="alternate" type="application/rss+xml" title="RSS ({{ language }})" href="{{ _link('rss', None, language) }}">
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<link rel="alternate" type="application/rss+xml" title="RSS" href="{{ _link('rss', None) }}">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% if generate_atom %}
|
||||
{% if translations|length > 1 %}
|
||||
{% for language in translations|sort %}
|
||||
<link rel="alternate" type="application/atom+xml" title="Atom ({{ language }})" href="{{ _link('index_atom', None, language) }}">
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<link rel="alternate" type="application/atom+xml" title="Atom" href="{{ _link('index_atom', None) }}">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_translations() %}
|
||||
<ul class="translations">
|
||||
{% for langname in translations|sort %}
|
||||
{% if langname != lang %}
|
||||
<li><a href="{{ abs_link(_link("root", None, langname)) }}" rel="alternate" hreflang="{{ langname }}">{{ messages("LANGUAGE", langname) }}</a></li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endmacro %}
|
||||
43
themes/hyde/templates/index.tmpl
Normal file
43
themes/hyde/templates/index.tmpl
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% import 'index_helper.tmpl' as helper with context %}
|
||||
{% import 'math_helper.tmpl' as math with context %}
|
||||
{% import 'comments_helper.tmpl' as comments with context %}
|
||||
{% extends 'base.tmpl' %}
|
||||
|
||||
{% block extra_head %}
|
||||
{{ super() }}
|
||||
{% if posts and (permalink == '/' or permalink == '/' + index_file) %}
|
||||
<link rel="prefetch" href="{{ posts[0].permalink() }}" type="text/html">
|
||||
{% endif %}
|
||||
{{ math.math_styles_ifposts(posts) }}
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
{% block content_header %}{% endblock %}
|
||||
{% if 'main_index' in pagekind %}
|
||||
{{ front_index_header }}
|
||||
{% endif %}
|
||||
<div class="post">
|
||||
{% for post in posts %}
|
||||
<article class="post h-entry post-{{ post.meta('type') }}">
|
||||
<header>
|
||||
<h1 class="post-title p-name"><a href="{{ post.permalink() }}" class="u-url">{{ post.title()|e }}</a></h1>
|
||||
<div class="metadata">
|
||||
<span class="post-date dateline"><time class="published dt-published" datetime="{{ post.formatted_date('webiso') }}" title="{{ post.formatted_date(date_format)|e }}">{{ post.formatted_date(date_format)|e }}</time></span>
|
||||
</div>
|
||||
</header>
|
||||
{% if index_teasers %}
|
||||
<div class="p-summary entry-summary">
|
||||
{{ post.text(teaser_only=True) }}
|
||||
{% else %}
|
||||
<div class="e-content entry-content">
|
||||
{{ post.text(teaser_only=False) }}
|
||||
{% endif %}
|
||||
</div>
|
||||
</article>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{{ helper.html_pager() }}
|
||||
{{ comments.comment_link_script() }}
|
||||
{{ math.math_scripts_ifposts(posts) }}
|
||||
{% endblock %}
|
||||
22
themes/hyde/templates/list_post.tmpl
Normal file
22
themes/hyde/templates/list_post.tmpl
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% extends 'base.tmpl' %}
|
||||
|
||||
{% block content %}
|
||||
<article class="listpage">
|
||||
<header>
|
||||
<h1>{{ title|e }}</h1>
|
||||
</header>
|
||||
{% if posts %}
|
||||
<ul class="postlist">
|
||||
{% for post in posts %}
|
||||
<li>
|
||||
<a href="{{ post.permalink() }}" class="listtitle">{{ post.title()|e }}</a> -
|
||||
<time class="listdate" datetime="{{ post.formatted_date('webiso') }}" title="{{ post.formatted_date(date_format)|e }}">{{ post.formatted_date(date_format)|e }}</time>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% else %}
|
||||
<p>{{ messages("No posts found.") }}</p>
|
||||
{% endif %}
|
||||
</article>
|
||||
{% endblock %}
|
||||
44
themes/hyde/templates/post_header.tmpl
Normal file
44
themes/hyde/templates/post_header.tmpl
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% import 'post_helper.tmpl' as helper with context %}
|
||||
{% import 'comments_helper.tmpl' as comments with context %}
|
||||
|
||||
{% macro html_title() %}
|
||||
{% if title and not post.meta('hidetitle') %}
|
||||
<h1 class="post-title p-name"><a href="{{ post.permalink() }}" class="u-url">{{ post.title()|e }}</a></h1>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_translations(post) %}
|
||||
{% if post.translated_to|length > 1 %}
|
||||
<div class="metadata posttranslations translations">
|
||||
<h3 class="posttranslations-intro">{{ messages("Also available in:") }}</h3>
|
||||
{% for langname in translations|sort %}
|
||||
{% if langname != lang and post.is_translation_available(langname) %}
|
||||
<p><a href="{{ post.permalink(langname) }}" rel="alternate" hreflang="{{ langname }}">{{ messages("LANGUAGE", langname) }}</a></p>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_sourcelink() %}
|
||||
{% if show_sourcelink %}
|
||||
<p class="sourceline"><a href="{{ post.source_link() }}" id="sourcelink">{{ messages("Source") }}</a></p>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_post_header() %}
|
||||
{{ html_title() }}
|
||||
<span class="post-date">
|
||||
<time class="published dt-published" datetime="{{ post.formatted_date('webiso') }}" itemprop="datePublished" title="{{ post.formatted_date(date_format)|e }}">{{ post.formatted_date(date_format)|e }}</time>
|
||||
</span>
|
||||
{% if post.meta('link') %}
|
||||
<p class="linkline"><a href="{{ post.meta('link') }}">{{ messages("Original site") }}</a></p>
|
||||
{% endif %}
|
||||
{% if post.description() %}
|
||||
<meta name="description" itemprop="description" content="{{ post.description()|e }}">
|
||||
{% endif %}
|
||||
|
||||
{{ html_translations(post) }}
|
||||
</header>
|
||||
{% endmacro %}
|
||||
96
themes/hyde/templates/post_helper.tmpl
Normal file
96
themes/hyde/templates/post_helper.tmpl
Normal file
|
|
@ -0,0 +1,96 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
|
||||
{% macro meta_translations(post) %}
|
||||
{% if translations|length > 1 %}
|
||||
{% for langname in translations|sort %}
|
||||
{% if langname != lang and ((not post.skip_untranslated) or post.is_translation_available(langname)) %}
|
||||
<link rel="alternate" hreflang="{{ langname }}" href="{{ post.permalink(langname) }}">
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_tags(post) %}
|
||||
{% if post.tags %}
|
||||
<p itemprop="keywords" class="tags">
|
||||
{% for tag in post.tags %}
|
||||
{% if tag not in hidden_tags %}
|
||||
<span class="tag"><a class="p-category" href="{{ _link('tag', tag) }}" rel="tag">{{ tag|e }}</a></span>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</p>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro html_pager(post) %}
|
||||
{% if post.prev_post or post.next_post %}
|
||||
<div class="pager hidden-print pagination">
|
||||
|
||||
<span class="previous pagination-item older">
|
||||
{% if post.prev_post %}
|
||||
<a href="{{ post.prev_post.permalink() }}" rel="prev" title="{{ post.prev_post.title()|e }}">
|
||||
{% endif %}
|
||||
{{ messages("Previous post") }}
|
||||
{% if post.prev_post %}
|
||||
</a>
|
||||
{% endif %}
|
||||
</span>
|
||||
|
||||
|
||||
<span class="next pagination-item newer">
|
||||
{% if post.next_post %}
|
||||
<a href="{{ post.next_post.permalink() }}" rel="next" title="{{ post.next_post.title()|e }}">
|
||||
{% endif %}{{ messages("Next post") }}
|
||||
{% if post.next_post %}
|
||||
</a>
|
||||
{% endif %}
|
||||
</span>
|
||||
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro open_graph_metadata(post) %}
|
||||
{% if use_open_graph %}
|
||||
<meta property="og:site_name" content="{{ blog_title|e }}">
|
||||
<meta property="og:title" content="{{ post.title()[:70]|e }}">
|
||||
<meta property="og:url" content="{{ abs_link(permalink) }}">
|
||||
{% if post.description() %}
|
||||
<meta property="og:description" content="{{ post.description()[:200]|e }}">
|
||||
{% else %}
|
||||
<meta property="og:description" content="{{ post.text(strip_html=True)[:200]|e }}">
|
||||
{% endif %}
|
||||
{% if post.previewimage %}
|
||||
<meta property="og:image" content="{{ url_replacer(permalink, post.previewimage, lang, 'absolute') }}">
|
||||
{% endif %}
|
||||
<meta property="og:type" content="article">
|
||||
{# Will only work with Pintrest and breaks everywhere else who expect a [Facebook] URI. #}
|
||||
{# %if post.author(): #}
|
||||
{# <meta property="article:author" content="{{ post.author()|e }}"> #}
|
||||
{# %endif #}
|
||||
{% if post.date.isoformat() %}
|
||||
<meta property="article:published_time" content="{{ post.formatted_date('webiso') }}">
|
||||
{% endif %}
|
||||
{% if post.tags %}
|
||||
{% for tag in post.tags %}
|
||||
<meta property="article:tag" content="{{ tag|e }}">
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro twitter_card_information(post) %}
|
||||
{% if twitter_card and twitter_card['use_twitter_cards'] %}
|
||||
<meta name="twitter:card" content="{{ twitter_card.get('card', 'summary')|e }}">
|
||||
{% if 'site:id' in twitter_card %}
|
||||
<meta name="twitter:site:id" content="{{ twitter_card['site:id'] }}">
|
||||
{% elif 'site' in twitter_card %}
|
||||
<meta name="twitter:site" content="{{ twitter_card['site'] }}">
|
||||
{% endif %}
|
||||
{% if 'creator:id' in twitter_card %}
|
||||
<meta name="twitter:creator:id" content="{{ twitter_card['creator:id'] }}">
|
||||
{% elif 'creator' in twitter_card %}
|
||||
<meta name="twitter:creator" content="{{ twitter_card['creator'] }}">
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
23
themes/hyde/templates/sectionindex.tmpl
Normal file
23
themes/hyde/templates/sectionindex.tmpl
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% extends 'index.tmpl' %}
|
||||
|
||||
{% block extra_head %}
|
||||
{{ super() }}
|
||||
{% if generate_atom %}
|
||||
<link rel="alternate" type="application/atom+xml" title="Atom for the {{ posts[0].section_name()|e }} section" href="{{ _link('section_index_atom', posts[0].section_slug()) }}">
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<div class="sectionindex">
|
||||
<header>
|
||||
<h2><a href="{{ _link('section_index', posts[0].section_slug()) }}">{{ title|e }}</a></h2>
|
||||
{% if generate_atom %}
|
||||
<p class="feedlink"><a href="{{ _link('section_index_atom', posts[0].section_slug()) }}" type="application/atom+xml">{{ messages('Updates') }}</a></p>
|
||||
{% endif %}
|
||||
</header>
|
||||
{{ super() }}
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
||||
40
themes/hyde/templates/tag.tmpl
Normal file
40
themes/hyde/templates/tag.tmpl
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% extends 'list_post.tmpl' %}
|
||||
|
||||
{% block extra_head %}
|
||||
{{ super() }}
|
||||
{% if translations|length > 1 and generate_rss %}
|
||||
{% for language in translations|sort %}
|
||||
<link rel="alternate" type="application/rss+xml" title="RSS for {{ kind }} {{ tag|e }} ({{ language }})" href="{{ _link(kind + "_rss", tag, language) }}">
|
||||
{% endfor %}
|
||||
{% elif generate_rss %}
|
||||
<link rel="alternate" type="application/rss+xml" title="RSS for {{ kind }} {{ tag|e }}" href="{{ _link(kind + "_rss", tag) }}">
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
|
||||
{% block content %}
|
||||
<article class="post tagpage">
|
||||
<header>
|
||||
<h1 class="post-title p-name">{{ title|e }}</h1>
|
||||
{% if description %}
|
||||
<p>{{ description }}</p>
|
||||
{% endif %}
|
||||
{% if subcategories %}
|
||||
{{ messages('Subcategories:') }}
|
||||
<ul>
|
||||
{% for name, link in subcategories %}
|
||||
<li><a href="{{ link }}">{{ name|e }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</header>
|
||||
{% if posts %}
|
||||
<ul class="postlist">
|
||||
{% for post in posts %}
|
||||
<li><a href="{{ post.permalink() }}" class="listtitle">{{ post.title()|e }}</a><span class="post-date dateline"><time class="listdate" datetime="{{ post.formatted_date('webiso') }}" title="{{ post.formatted_date(date_format)|e }}">{{ post.formatted_date(date_format)|e }}</time></span></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</article>
|
||||
{% endblock %}
|
||||
42
themes/hyde/templates/tags.tmpl
Normal file
42
themes/hyde/templates/tags.tmpl
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
{# -*- coding: utf-8 -*- #}
|
||||
{% extends 'base.tmpl' %}
|
||||
|
||||
{% block content %}
|
||||
<article class="post tagindex">
|
||||
<header>
|
||||
<h1>{{ title|e }}</h1>
|
||||
</header>
|
||||
{% if cat_items %}
|
||||
{% if items %}
|
||||
<h2>{{ messages("Categories") }}</h2>
|
||||
{% endif %}
|
||||
{% for text, full_name, path, link, indent_levels, indent_change_before, indent_change_after in cat_hierarchy %}
|
||||
{% for i in range(indent_change_before) %}
|
||||
<ul class="postlist">
|
||||
{% endfor %}
|
||||
<li><a class="reference" href="{{ link }}">{{ text }}</a>
|
||||
{% if indent_change_after <= 0 %}
|
||||
</li>
|
||||
{% endif %}
|
||||
{% for i in range(-indent_change_after) %}
|
||||
</ul>
|
||||
{% if i + 1 < indent_levels|length %}
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% if items %}
|
||||
<h2>{{ messages("Tags") }}</h2>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% if items %}
|
||||
<ul class="postlist">
|
||||
{% for text, link in items %}
|
||||
{% if text not in hidden_tags %}
|
||||
<li><a class="reference listtitle" href="{{ link }}">{{ text|e }}</a></li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</article>
|
||||
{% endblock %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue