Fixed some HTML tags.

This commit is contained in:
Cotes Chung 2019-12-23 00:55:51 +08:00
parent 40e44158ae
commit 77a47c4b62
6 changed files with 6 additions and 6 deletions

View file

@ -21,7 +21,7 @@
{% endfor %} {% endfor %}
{% if lastmod_list.size > 0 %} {% if lastmod_list.size > 0 %}
<div id="access-lastmod" class="post mb-4""> <div id="access-lastmod" class="post mb-4">
<h3 data-toc-skip> <h3 data-toc-skip>
{{- site.data.label.panel.lastmod -}} {{- site.data.label.panel.lastmod -}}
</h3> </h3>

View file

@ -56,7 +56,7 @@
</span> </span>
<h3 class="pt-0 mt-2 mb-3" data-toc-skip>{{ post.title }}</h3> <h3 class="pt-0 mt-2 mb-3" data-toc-skip>{{ post.title }}</h3>
<div class="text-muted small"> <div class="text-muted small">
<p>{{ post.content | markdownify | strip_html | truncate: 200 }}</p> <p>{{ post.content | markdownify | strip_html | truncate: 200 | replace: '&', '&amp;' }}</p>
</div> </div>
</div> </div>
</a> </a>

View file

@ -12,7 +12,7 @@
{% if avatar | slice: 0 == '/' %} {% if avatar | slice: 0 == '/' %}
{% assign avatar = avatar | prepend: site.baseurl %} {% assign avatar = avatar | prepend: site.baseurl %}
{% endif %} {% endif %}
<img src="{{ avatar }}"></img> <img src="{{ avatar }}">
</a> </a>
</div> </div>

View file

@ -15,7 +15,7 @@ layout: page
</h1> </h1>
<div class="post-content"> <div class="post-content">
<p> <p>
{{ post.content | strip_html | truncate: 200 }} {{ post.content | strip_html | truncate: 200 | replace: '&', '&amp;' }}
</p> </p>
</div> </div>

View file

@ -48,7 +48,7 @@ layout: default
{% capture post_content %} {% capture post_content %}
<div class="post-content"> <div class="post-content">
{% if page.image %} {% if page.image %}
<img src="{{ page.image }}" class="img-rounded"> <img src="{{ page.image }}">
{% endif %} {% endif %}
{{ content }} {{ content }}
</div> </div>
@ -56,7 +56,7 @@ layout: default
<!-- Add lozad class into image tags. see: <https://github.com/ApoorvSaxena/lozad.js#usage> --> <!-- Add lozad class into image tags. see: <https://github.com/ApoorvSaxena/lozad.js#usage> -->
{% if post_content contains '<img src=' %} {% if post_content contains '<img src=' %}
{{ post_content | replace: '<img src=', '<img class="lozad" data-src=' }} {{ post_content | replace: '<img src=', '<img class="lozad" src="/assets/img/commons/loading.png" data-src=' }}
{% else %} {% else %}
{{ post_content }} {{ post_content }}
{% endif %} {% endif %}

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 B