mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-16 19:30:54 +08:00
breaking changes: 更改 rightside-bottom 為 rightside_bottom
feat: 置頂圖標改為在標題左側 feat: 可配置打賞按鈕的文字 feat: 側邊欄增加 系列文章顯示 feat: 增加 series 系列文章 標籤外掛 feat: 移除 addthis 分享 improvement: 代碼優化 improvement: tabs 標籤外掛的回到頂部箭頭位置調整 improvement: 更新 plugin.yml
This commit is contained in:
@@ -19,13 +19,11 @@ mixin postUI(posts)
|
||||
else
|
||||
div.post-bg(style=`background: ${post_cover}`)
|
||||
.recent-post-info(class=no_cover)
|
||||
a.article-title(href=url_for(link) title=title)= title
|
||||
.article-meta-wrap
|
||||
a.article-title(href=url_for(link) title=title)
|
||||
if (is_home() && (article.top || article.sticky > 0))
|
||||
span.article-meta
|
||||
i.fas.fa-thumbtack.sticky
|
||||
span.sticky= _p('sticky')
|
||||
span.article-meta-separator |
|
||||
i.fas.fa-thumbtack.sticky
|
||||
= title
|
||||
.article-meta-wrap
|
||||
if (theme.post_meta.page.date_type)
|
||||
span.post-meta-date
|
||||
if (theme.post_meta.page.date_type === 'both')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
.post-reward
|
||||
.reward-button
|
||||
i.fas.fa-qrcode
|
||||
= ' ' + _p('donate')
|
||||
= theme.reward.text || _p('donate')
|
||||
.reward-main
|
||||
ul.reward-all
|
||||
each item in theme.reward.QR_code
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
.addthis_inline_share_toolbox
|
||||
script(src=`//s7.addthis.com/js/300/addthis_widget.js#pubid=${theme.addThis.pubid}` async)
|
||||
4
layout/includes/third-party/share/index.pug
vendored
4
layout/includes/third-party/share/index.pug
vendored
@@ -1,7 +1,5 @@
|
||||
.post_share
|
||||
if theme.addThis.enable
|
||||
!=partial('includes/third-party/share/add-this', {}, {cache: true})
|
||||
else if theme.sharejs.enable
|
||||
if theme.sharejs.enable
|
||||
include ./share-js.pug
|
||||
else if theme.addtoany.enable
|
||||
!=partial('includes/third-party/share/addtoany', {}, {cache: true})
|
||||
|
||||
21
layout/includes/widget/card_post_series.pug
Normal file
21
layout/includes/widget/card_post_series.pug
Normal file
@@ -0,0 +1,21 @@
|
||||
if theme.aside.card_post_series.enable
|
||||
- const array = fragment_cache('seriesArr', groupPosts)
|
||||
.card-widget.card-post-series
|
||||
.item-headline
|
||||
i.fa-solid.fa-layer-group
|
||||
span= _p('aside.card_post_series')
|
||||
.aside-list
|
||||
each item in array[page.series]
|
||||
- const { path, title = _p('no_title'), cover, cover_type, date:dateA } = item
|
||||
- let link = url_for(path)
|
||||
- let no_cover = cover === false || !theme.cover.aside_enable ? 'no-cover' : ''
|
||||
.aside-list-item(class=no_cover)
|
||||
if cover && theme.cover.aside_enable
|
||||
a.thumbnail(href=link title=title)
|
||||
if cover_type === 'img'
|
||||
img(src=url_for(cover) onerror=`this.onerror=null;this.src='${url_for(theme.error_img.post_page)}'` alt=title)
|
||||
else
|
||||
div(style=`background: ${cover}`)
|
||||
.content
|
||||
a.title(href=link title=title)= title
|
||||
time(datetime=date_xml(dateA) title=_p('post.created') + ' ' + full_date(dateA)) #[=date(dateA, config.date_format)]
|
||||
@@ -13,6 +13,8 @@
|
||||
.sticky_layout
|
||||
if showToc
|
||||
include ./card_post_toc.pug
|
||||
if page.series
|
||||
include ./card_post_series.pug
|
||||
!=partial('includes/widget/card_recent_post', {}, {cache: true})
|
||||
!=partial('includes/widget/card_ad', {}, {cache: true})
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user