mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-10 21:17:07 +08:00
feat: twikoo 增加 option 配置
feat: aside widget 增加排序(只對page頁和sticky內的有效) feat: aside 增加自定義 widget improvement: readmode 優化 improvement: html結構優化
This commit is contained in:
@@ -4,7 +4,7 @@ script.
|
||||
function loadWaline () {
|
||||
function initWaline () {
|
||||
let initData = {
|
||||
el: '#waline',
|
||||
el: '#waline-wrap',
|
||||
serverURL: '!{theme.waline.serverURL}',
|
||||
avatar: '#{theme.waline.avatar}',
|
||||
path: location.pathname,
|
||||
@@ -12,7 +12,7 @@ script.
|
||||
|
||||
if (!{Boolean(option)}) {
|
||||
const otherData = !{option}
|
||||
initData = Object.assign({}, initData, otherData)
|
||||
initData = Object.assign(initData, otherData)
|
||||
}
|
||||
|
||||
const waline = new Waline(initData)
|
||||
@@ -23,7 +23,7 @@ script.
|
||||
}
|
||||
|
||||
if ('!{theme.comments.use[0]}' === 'Waline' || !!{theme.comments.lazyload}) {
|
||||
if (!{theme.comments.lazyload}) btf.loadComment(document.querySelector('#waline'),loadWaline)
|
||||
if (!{theme.comments.lazyload}) btf.loadComment(document.getElementById('waline-wrap'),loadWaline)
|
||||
else setTimeout(loadWaline, 0)
|
||||
} else {
|
||||
function loadOtherComment () {
|
||||
|
||||
Reference in New Issue
Block a user