Skip to content

Commit 4d83973

Browse files
authored
MOD: add post-body class & refactor vision.
1 parent d26b00d commit 4d83973

File tree

1 file changed

+28
-20
lines changed

1 file changed

+28
-20
lines changed

layout/page.swig

+28-20
Original file line numberDiff line numberDiff line change
@@ -19,28 +19,36 @@
1919

2020
<div id="posts" class="posts-expand">
2121
{% include '_partials/page-header.swig' %}
22-
{# tagcloud page support #}
23-
{% if page.type === "tags" %}
24-
<div class="tag-cloud">
25-
<div class="tag-cloud-title">
26-
{{ _p('counter.tag_cloud', site.tags.length) }}
22+
{#################}
23+
{### PAGE BODY ###}
24+
{#################}
25+
<div class="post-body{% if theme.han %} han-init-context{% endif %}{% if page.direction && page.direction.toLowerCase() === 'rtl' %} rtl{% endif %}">
26+
{# tagcloud page support #}
27+
{% if page.type === "tags" %}
28+
<div class="tag-cloud">
29+
<div class="tag-cloud-title">
30+
{{ _p('counter.tag_cloud', site.tags.length) }}
31+
</div>
32+
<div class="tag-cloud-tags">
33+
{{ tagcloud({min_font: 12, max_font: 30, amount: 200, color: true, start_color: '#ccc', end_color: '#111'}) }}
34+
</div>
2735
</div>
28-
<div class="tag-cloud-tags">
29-
{{ tagcloud({min_font: 12, max_font: 30, amount: 200, color: true, start_color: '#ccc', end_color: '#111'}) }}
36+
{% elif page.type === 'categories' %}
37+
<div class="category-all-page">
38+
<div class="category-all-title">
39+
{{ _p('counter.categories', site.categories.length) }}
40+
</div>
41+
<div class="category-all">
42+
{{ list_categories() }}
43+
</div>
3044
</div>
31-
</div>
32-
{% elif page.type === 'categories' %}
33-
<div class="category-all-page">
34-
<div class="category-all-title">
35-
{{ _p('counter.categories', site.categories.length) }}
36-
</div>
37-
<div class="category-all">
38-
{{ list_categories() }}
39-
</div>
40-
</div>
41-
{% else %}
42-
{{ page.content }}
43-
{% endif %}
45+
{% else %}
46+
{{ page.content }}
47+
{% endif %}
48+
</div>
49+
{#####################}
50+
{### END PAGE BODY ###}
51+
{#####################}
4452
</div>
4553

4654
{% endblock %}

0 commit comments

Comments
 (0)