From 9d46733e2f9b776dfe1bab5e65be0937dd4ca5b8 Mon Sep 17 00:00:00 2001 From: "Ivan.Nginx" Date: Tue, 23 Jan 2018 04:36:10 +0300 Subject: [PATCH] =?UTF-8?q?Rename=20=C2=ABWords=20count=20in=20article?= =?UTF-8?q?=C2=BB=20on=20=C2=ABSymbols=20count=20in=20article=C2=BB.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. Refactored `wordscount` on `symbols_count`. 2. Fixed excess `post-description` spaces. --- languages/_en.yml | 8 ++++---- layout/_macro/post.swig | 16 ++++++++-------- layout/_partials/footer.swig | 8 ++++---- .../css/_common/components/post/post-meta.styl | 2 +- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/languages/_en.yml b/languages/_en.yml index 4c179ada07..4f63ba0319 100644 --- a/languages/_en.yml +++ b/languages/_en.yml @@ -32,10 +32,10 @@ post: untitled: Untitled toc_empty: This post does not have a Table of Contents visitors: Visitors - wordcount: Words count in article - min2read: Reading time - totalcount: Site words total count - totaltime: Site reading time + symbols_count: Symbols count in article + symbols_time: Reading time + total_symbols: Symbols count total + total_time: Reading time total copyright: author: Post author link: Post link diff --git a/layout/_macro/post.swig b/layout/_macro/post.swig index ba51a3dedf..7fa623390f 100644 --- a/layout/_macro/post.swig +++ b/layout/_macro/post.swig @@ -222,7 +222,7 @@ {% endif %} {% if config.symbols_count_time.symbols or config.symbols_count_time.time %} -
+
{% if not theme.symbols_count_time.separated_meta %} {% endif %} @@ -232,9 +232,9 @@ {% if theme.symbols_count_time.item_text_post %} - + {% endif %} - {# + {# #}{{ symbolsCount(post.content) }}{# #} {% endif %} @@ -248,9 +248,9 @@ {% if theme.symbols_count_time.item_text_post %} - + {% endif %} - {# + {# #}{{ symbolsTime(post.content, theme.symbols_count_time.awl, theme.symbols_count_time.wpm) }}{# #} {% endif %} @@ -258,9 +258,9 @@ {% endif %} {% if post.description and (not theme.excerpt_description or not is_index) %} -
- {{ post.description }} -
+
{# + #}{{ post.description }}{# + #}
{% endif %}
diff --git a/layout/_partials/footer.swig b/layout/_partials/footer.swig index 5ae1441924..229ff182cc 100644 --- a/layout/_partials/footer.swig +++ b/layout/_partials/footer.swig @@ -13,9 +13,9 @@ {% if theme.symbols_count_time.item_text_total %} - + {% endif %} - {# + {# #}{{ symbolsCountTotal(site) }}{# #} {% endif %} @@ -26,9 +26,9 @@ {% if theme.symbols_count_time.item_text_total %} - + {% endif %} - {# + {# #}{{ symbolsTimeTotal(site, theme.symbols_count_time.awl, theme.symbols_count_time.wpm) }}{# #} {% endif %} diff --git a/source/css/_common/components/post/post-meta.styl b/source/css/_common/components/post/post-meta.styl index 97b650c3bd..dca02e57ef 100644 --- a/source/css/_common/components/post/post-meta.styl +++ b/source/css/_common/components/post/post-meta.styl @@ -18,7 +18,7 @@ } } -.post-wordcount { +.post-symbolscount { if !hexo-config('symbols_count_time.separated_meta') { display: inline-block; } }