mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-10 21:17:07 +08:00
label: 3.5.0
This commit is contained in:
@@ -1,9 +1,9 @@
|
|||||||
# hexo-theme-butterfly
|
# hexo-theme-butterfly
|
||||||
|
|
||||||

|

|
||||||
|

|
||||||

|

|
||||||

|

|
||||||

|
|
||||||

|

|
||||||
|
|
||||||
Demo: 👍 [Butterfly](https://butterfly.js.org/) || 🤞 [JerryC](https://jerryc.me/)
|
Demo: 👍 [Butterfly](https://butterfly.js.org/) || 🤞 [JerryC](https://jerryc.me/)
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
# hexo-theme-butterfly
|
# hexo-theme-butterfly
|
||||||
|
|
||||||

|

|
||||||
|

|
||||||

|

|
||||||

|

|
||||||

|
|
||||||

|

|
||||||
|
|
||||||
|
|
||||||
預覽: 👍 [Butterfly](https://butterfly.js.org/) || 🤞 [JerryC](https://jerryc.me/)
|
預覽: 👍 [Butterfly](https://butterfly.js.org/) || 🤞 [JerryC](https://jerryc.me/)
|
||||||
|
|
||||||
文檔: 📖 [Butterfly Docs](https://butterfly.js.org/posts/21cfbf15/)
|
文檔: 📖 [Butterfly Docs](https://butterfly.js.org/posts/21cfbf15/)
|
||||||
|
|||||||
@@ -309,6 +309,7 @@ valine:
|
|||||||
waline:
|
waline:
|
||||||
serverURL: # Waline server address url
|
serverURL: # Waline server address url
|
||||||
avatar: monsterid # gravatar style https://zh-tw.gravatar.com/site/implement/images/#default-image
|
avatar: monsterid # gravatar style https://zh-tw.gravatar.com/site/implement/images/#default-image
|
||||||
|
emojiCDN: # emoji CDN
|
||||||
bg: /image/comment_bg.png # waline background
|
bg: /image/comment_bg.png # waline background
|
||||||
option:
|
option:
|
||||||
|
|
||||||
|
|||||||
@@ -83,7 +83,7 @@
|
|||||||
when 'Gitalk'
|
when 'Gitalk'
|
||||||
+countBlock
|
+countBlock
|
||||||
a(href=url_for(page.path) + '#post-comment')
|
a(href=url_for(page.path) + '#post-comment')
|
||||||
span.gitalk-#card-toc
|
span.gitalk-comment-count
|
||||||
when 'Twikoo'
|
when 'Twikoo'
|
||||||
+countBlock
|
+countBlock
|
||||||
a(href=url_for(page.path) + '#post-comment')
|
a(href=url_for(page.path) + '#post-comment')
|
||||||
|
|||||||
@@ -1,4 +1,7 @@
|
|||||||
- let option = theme.waline.option ? JSON.stringify(theme.waline.option) : false
|
- let option = theme.waline.option ? JSON.stringify(theme.waline.option) : false
|
||||||
|
- let emojiMaps = '""'
|
||||||
|
if site.data.waline
|
||||||
|
- emojiMaps = JSON.stringify(site.data.waline)
|
||||||
|
|
||||||
script.
|
script.
|
||||||
function loadWaline () {
|
function loadWaline () {
|
||||||
@@ -8,6 +11,8 @@ script.
|
|||||||
serverURL: '!{theme.waline.serverURL}',
|
serverURL: '!{theme.waline.serverURL}',
|
||||||
avatar: '#{theme.waline.avatar}',
|
avatar: '#{theme.waline.avatar}',
|
||||||
path: location.pathname,
|
path: location.pathname,
|
||||||
|
emojiCDN: '#{theme.waline.emojiCDN}',
|
||||||
|
emojiMaps: !{emojiMaps},
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!{Boolean(option)}) {
|
if (!{Boolean(option)}) {
|
||||||
|
|||||||
@@ -80,7 +80,7 @@ script.
|
|||||||
'content': changeContent(e.comment),
|
'content': changeContent(e.comment),
|
||||||
'mail': e.mail,
|
'mail': e.mail,
|
||||||
'nick': e.nick,
|
'nick': e.nick,
|
||||||
'url': e.url,
|
'url': e.url + '#' + e.objectId,
|
||||||
'date': e.createdAt,
|
'date': e.createdAt,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ script.
|
|||||||
'content': changeContent(e.comment),
|
'content': changeContent(e.comment),
|
||||||
'mail': e.mail,
|
'mail': e.mail,
|
||||||
'nick': e.nick,
|
'nick': e.nick,
|
||||||
'url': e.url,
|
'url': e.url + '#' + e.objectId,
|
||||||
'date': e.createdAt,
|
'date': e.createdAt,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "hexo-theme-butterfly",
|
"name": "hexo-theme-butterfly",
|
||||||
"version": "3.5.0-b3",
|
"version": "3.5.0",
|
||||||
"description": "A Simple and Card UI Design theme for Hexo",
|
"description": "A Simple and Card UI Design theme for Hexo",
|
||||||
"main": "package.json",
|
"main": "package.json",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -247,7 +247,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||||||
* fancybox和 mediumZoom
|
* fancybox和 mediumZoom
|
||||||
*/
|
*/
|
||||||
const addFancybox = function (ele) {
|
const addFancybox = function (ele) {
|
||||||
if (ele.length) {
|
|
||||||
const runFancybox = (ele) => {
|
const runFancybox = (ele) => {
|
||||||
ele.each(function (i, o) {
|
ele.each(function (i, o) {
|
||||||
const $this = $(o)
|
const $this = $(o)
|
||||||
@@ -275,7 +274,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||||||
runFancybox($(ele))
|
runFancybox($(ele))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
const addMediumZoom = () => {
|
const addMediumZoom = () => {
|
||||||
const zoom = mediumZoom(document.querySelectorAll('#article-container :not(a)>img'))
|
const zoom = mediumZoom(document.querySelectorAll('#article-container :not(a)>img'))
|
||||||
|
|||||||
Reference in New Issue
Block a user