New element .post-content

This commit is contained in:
Mimi 2020-09-27 01:50:22 +08:00
parent 9919fb5c49
commit 7c87d55d26
2 changed files with 16 additions and 14 deletions

View File

@ -1,7 +1,11 @@
{##################}
{### POST BLOCK ###}
{##################}
<article itemscope itemtype="http://schema.org/Article" class="post-block" lang="{{ post.lang or config.language }}">
{##################}
{### POST BLOCK ###}
{##################}
<div class="post-block">
{# Gallery support #}
{{ post_gallery(post.photos) }}
<article itemscope itemtype="http://schema.org/Article" class="post-content" lang="{{ post.lang or config.language }}">
<link itemprop="mainEntityOfPage" href="{{ post.permalink }}">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
@ -14,9 +18,6 @@
<meta itemprop="name" content="{{ title }}">
</span>
{# Gallery support #}
{{ post_gallery(post.photos) }}
{%- if post.header !== false %}
<header class="post-header">
<{%- if is_index %}h2{% else %}h1{%- endif %} class="post-title{%- if post.direction and post.direction.toLowerCase() === 'rtl' %} rtl{%- endif %}" itemprop="name headline">
@ -149,6 +150,7 @@
{%- endif %}
</footer>
</article>
{######################}
{### END POST BLOCK ###}
{######################}
</div>
{######################}
{### END POST BLOCK ###}
{######################}

View File

@ -1,12 +1,12 @@
{%- set serverURLs = theme.valine.serverURLs or 'https://' + theme.valine.appId.slice(0, 8) | lower + '.api.lncldglobal.com' %}
<script>
NexT.utils.loadComments('#valine-comments', () => {
NexT.utils.getScript('{{ theme.vendors.valine }}', () => {
new Valine(Object.assign({
new Valine(Object.assign({{ theme.valine | safedump }}, {
el: '#valine-comments',
path: {{ url_for(page.path) | replace(r/index\.html$/, '') | safedump }},
serverURLs: 'https://{{ theme.valine.appId.slice(0, 8) | lower }}.api.lncldglobal.com'
}, {{ theme.valine | safedump }}
));
serverURLs: {{ serverURLs | safedump }}
}));
}, window.Valine);
});
</script>