reorg coil gen posts + new theme
This commit is contained in:
parent
650f7ceb04
commit
ad3bcc971e
79 changed files with 14597 additions and 25 deletions
62
themes/material-theme/templates/post_header.tmpl
Normal file
62
themes/material-theme/templates/post_header.tmpl
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
{# -*- 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="p-name entry-title" itemprop="headline name"><a href="{{ post.permalink() }}" class="u-url">{{ post.title()|e }}</a></h1><hr/>
|
||||
{% 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.keys() %}
|
||||
{% 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() %}
|
||||
<header>
|
||||
{{ html_title() }}
|
||||
<div class="metadata">
|
||||
<span class="byline author vcard">
|
||||
<a href="{{ post.permalink() }}" >
|
||||
{% if author_avatar %}
|
||||
<img class="img-circle" src="{{ author_avatar }}" alt="icon"/>
|
||||
{% else %}
|
||||
<i class="mdi-action-face-unlock"></i>
|
||||
{% endif %}
|
||||
{{ post.author() }}
|
||||
</a>
|
||||
</span>
|
||||
<span class="dateline">
|
||||
<a href="{{ post.permalink() }}" rel="bookmark"><i class="mdi-device-access-time"></i>
|
||||
<time class="published dt-published" datetime="{{ post.date.isoformat() }}" itemprop="datePublished" title="{{ post.formatted_date(date_format) }}">{{ post.formatted_date(date_format) }}</time>
|
||||
</a>
|
||||
</span>
|
||||
{% if post.meta('link') %}
|
||||
<span><a href='{{ post.meta('link') }}'><i class="mdi-action-launch"></i>{{ messages("Original site") }}</a></span>
|
||||
{% endif %}
|
||||
{% if not post.meta('nocomments') and site_has_comments %}
|
||||
<span class="commentline">{{ comments.comment_link(post.permalink(), post._base_path) }}</span>
|
||||
{% endif %}
|
||||
{% if post.description() %}
|
||||
<meta name="description" itemprop="description" content="{{ post.description() }}">
|
||||
{% endif %}
|
||||
</div>
|
||||
{{ html_translations(post) }}
|
||||
<hr />
|
||||
</header>
|
||||
{% endmacro %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue