mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-10 21:17:07 +08:00
feat: aside widget 增加排序(只對page頁和sticky內的有效) feat: aside 增加自定義 widget improvement: readmode 優化 improvement: html結構優化
28 lines
596 B
Plaintext
28 lines
596 B
Plaintext
- let option = theme.artitalk.option ? JSON.stringify(theme.artitalk.option) : false
|
|
|
|
if top_img === false
|
|
h1.page-title= page.title
|
|
|
|
#artitalk_main
|
|
script.
|
|
(()=>{
|
|
let setting = {
|
|
appId: '!{theme.artitalk.appId}',
|
|
appKey: '!{theme.artitalk.appKey}',
|
|
}
|
|
|
|
if (!{Boolean(option)}) {
|
|
const otherSetting = !{option}
|
|
setting = Object.assign(setting, otherSetting)
|
|
}
|
|
|
|
const init = () => {
|
|
new Artitalk(setting)
|
|
}
|
|
|
|
if (typeof Artitalk === 'function') {
|
|
init()
|
|
} else {
|
|
getScript('!{theme.CDN.artitalk}').then(init)
|
|
}
|
|
})() |