mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-16 17:50:54 +08:00
✨ 適配 valine 1.4.5, 增加emojiCDN和emojiMaps配置
This commit is contained in:
@@ -259,6 +259,8 @@ valine:
|
|||||||
enable: false # if you want use valine,please set this value is true
|
enable: false # if you want use valine,please set this value is true
|
||||||
appId: # leancloud application app id
|
appId: # leancloud application app id
|
||||||
appKey: # leancloud application app key
|
appKey: # leancloud application app key
|
||||||
|
notify: false # valine mail notify (true/false) Deprecated in v1.4.0+
|
||||||
|
verify: false # valine verify code (true/false) Deprecated in v1.4.0+
|
||||||
pageSize: 10 # comment list page size
|
pageSize: 10 # comment list page size
|
||||||
avatar: monsterid # gravatar style https://valine.js.org/#/avatar
|
avatar: monsterid # gravatar style https://valine.js.org/#/avatar
|
||||||
lang: en # i18n: zh-CN/zh-TW/en/ja
|
lang: en # i18n: zh-CN/zh-TW/en/ja
|
||||||
@@ -266,6 +268,7 @@ valine:
|
|||||||
guest_info: nick,mail,link #valine comment header info
|
guest_info: nick,mail,link #valine comment header info
|
||||||
recordIP: false # Record reviewer IP
|
recordIP: false # Record reviewer IP
|
||||||
serverURLs: # This configuration is suitable for domestic custom domain name users, overseas version will be automatically detected (no need to manually fill in)
|
serverURLs: # This configuration is suitable for domestic custom domain name users, overseas version will be automatically detected (no need to manually fill in)
|
||||||
|
emojiCDN: # emoji CDN
|
||||||
bg: /img/comment_bg.png # valine background
|
bg: /img/comment_bg.png # valine background
|
||||||
count: true # top_img顯示評論數
|
count: true # top_img顯示評論數
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
- let emojiMaps = '""'
|
||||||
|
if site.data.valine
|
||||||
|
- emojiMaps = JSON.stringify(site.data.valine)
|
||||||
|
|
||||||
#vcomment.vcomment
|
#vcomment.vcomment
|
||||||
script(src=url_for(theme.CDN.valine))
|
script(src=url_for(theme.CDN.valine))
|
||||||
script.
|
script.
|
||||||
@@ -11,11 +15,15 @@ script.
|
|||||||
el:'#vcomment',
|
el:'#vcomment',
|
||||||
appId: '#{theme.valine.appId}',
|
appId: '#{theme.valine.appId}',
|
||||||
appKey: '#{theme.valine.appKey}',
|
appKey: '#{theme.valine.appKey}',
|
||||||
|
notify: #{theme.valine.notify},
|
||||||
|
verify: #{theme.valine.verify},
|
||||||
placeholder: '#{theme.valine.placeholder}',
|
placeholder: '#{theme.valine.placeholder}',
|
||||||
avatar: '#{theme.valine.avatar}',
|
avatar: '#{theme.valine.avatar}',
|
||||||
meta: guest_info,
|
meta: guest_info,
|
||||||
pageSize: '#{theme.valine.pageSize}',
|
pageSize: '#{theme.valine.pageSize}',
|
||||||
lang: '#{theme.valine.lang}',
|
lang: '#{theme.valine.lang}',
|
||||||
recordIP: #{theme.valine.recordIP},
|
recordIP: #{theme.valine.recordIP},
|
||||||
serverURLs: '#{theme.valine.serverURLs}'
|
serverURLs: '#{theme.valine.serverURLs}',
|
||||||
|
emojiCDN: '#{theme.valine.emojiCDN}',
|
||||||
|
emojiMaps: !{emojiMaps}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user