Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update valine comment system version (#345)
* Update valine comment system version

* Update valine visitor annotation

* Update valine instruction
  • Loading branch information
Nine authored and sli1989 committed Jul 14, 2018
1 parent ec18888 commit 7d17575
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion _config.yml
Expand Up @@ -494,7 +494,7 @@ changyan:
# You can get your appid and appkey from https://leancloud.cn
# more info please open https://valine.js.org
valine:
enable: false
enable: false # When enable is set to be true, leancloud_visitors is recommended to be closed for the re-initialization problem within different leancloud adk version.
appid: # your leancloud application appid
appkey: # your leancloud application appkey
notify: false # mail notifier , https://github.com/xCss/Valine/wiki
Expand All @@ -503,6 +503,7 @@ valine:
avatar: mm # gravatar style
guest_info: nick,mail,link # custom comment header
pageSize: 10 # pagination size
visitor: false # leancloud-counter-security is not supported for now. When visitor is set to be true, appid and appkey are recommended to be the same as leancloud_visitors' for counter compatibility. Article reading statistic https://valine.js.org/visitor.html


# Support for youyan comments system.
Expand Down
2 changes: 1 addition & 1 deletion layout/_macro/post.swig
Expand Up @@ -212,7 +212,7 @@
{% endif %}

{# LeanCould PageView #}
{% if theme.leancloud_visitors.enable %}
{% if theme.leancloud_visitors.enable or (theme.valine.enable and theme.valine.appid and theme.valine.appkey and theme.valine.visitor) %}
<span id="{{ url_for(post.path) }}" class="leancloud_visitors" data-flag-title="{{ post.title }}">
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
Expand Down
2 changes: 1 addition & 1 deletion layout/_third-party/analytics/lean-analytics.swig
@@ -1,4 +1,4 @@
{% if theme.leancloud_visitors.enable %}
{% if theme.leancloud_visitors.enable and !theme.valine.visitor %}

{# custom analytics part create by xiamo; edited by LEAFERx #}
<script src="https://cdn1.lncld.net/static/js/av-core-mini-0.6.4.js"></script>
Expand Down
3 changes: 2 additions & 1 deletion layout/_third-party/comments/valine.swig
Expand Up @@ -20,8 +20,9 @@
appKey: '{{ theme.valine.appkey }}',
placeholder: '{{ theme.valine.placeholder }}',
avatar:'{{ theme.valine.avatar }}',
guest_info:guest,
meta:guest,
pageSize:'{{ theme.valine.pageSize }}' || 10,
visitor: {{ theme.valine.visitor }}
});
</script>
{% endif %}

4 comments on commit 7d17575

@reuixiy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My blog has been used. 😄
Thank you for your awesome contributions! 👍

@cugxuan
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My blog has been used too.
It works if you modify the files according to the changes.
So excited! I could use its new features before nextV6.4.0!
Thank you so much!

@sli1989
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cugxuan has been merged, just pull the new master.

@cugxuan
Copy link

@cugxuan cugxuan commented on 7d17575 Jul 19, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sli1989 Actually,I'm waiting for the the new release.
I have a bit of obsessive-compulsive disorder to use the stable version.
Thanks!

Please sign in to comment.