mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-17 04:40:53 +08:00
Merge branch 'dev'
This commit is contained in:
@@ -1,10 +1,10 @@
|
|||||||
-
|
-
|
||||||
let isHighlightShrink
|
let isHighlightShrink
|
||||||
if (theme.highlight_shrink == 'none') isHighlightShrink = 'undefined'
|
if (theme.highlight_shrink == 'none') isHighlightShrink = 'undefined'
|
||||||
else if (page.highlight_shrink !== undefined) isHighlightShrink = page.highlight_shrink
|
else if (page.highlight_shrink !== null && page.toc !== undefined ) isHighlightShrink = page.highlight_shrink
|
||||||
else isHighlightShrink = theme.highlight_shrink
|
else isHighlightShrink = theme.highlight_shrink
|
||||||
|
|
||||||
const pageToc = page.toc !== undefined ? page.toc : theme.toc.enable
|
const pageToc = page.toc !== null && page.toc !== undefined ? page.toc : theme.toc.enable
|
||||||
const showToc = is_post() && pageToc && (toc(page.content) !== '' || page.encrypt == true )
|
const showToc = is_post() && pageToc && (toc(page.content) !== '' || page.encrypt == true )
|
||||||
-
|
-
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "hexo-theme-butterfly",
|
"name": "hexo-theme-butterfly",
|
||||||
"version": "3.0.0",
|
"version": "3.0.0-rc-1",
|
||||||
"private": true,
|
"private": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=8.10.0"
|
"node": ">=8.10.0"
|
||||||
|
|||||||
@@ -21,8 +21,7 @@ function btn (args) {
|
|||||||
icon = icon.trim()
|
icon = icon.trim()
|
||||||
option = option.trim()
|
option = option.trim()
|
||||||
|
|
||||||
return `<a class="btn-beautify button--animated ${option}" href="${urlFor(url)}" title="${text}">
|
return `<a class="btn-beautify button--animated ${option}" href="${urlFor(url)}" title="${text}">${icon.length > 0 ? `<i class="${icon} fa-fw"></i>` : ''} ${text} </a>`
|
||||||
${icon.length > 0 ? `<i class="${icon} fa-fw"></i>` : ''} ${text} </a>`
|
|
||||||
}
|
}
|
||||||
|
|
||||||
hexo.extend.tag.register('btn', btn, { ends: false })
|
hexo.extend.tag.register('btn', btn, { ends: false })
|
||||||
|
|||||||
@@ -12,7 +12,8 @@
|
|||||||
top: 0
|
top: 0
|
||||||
right: -250px
|
right: -250px
|
||||||
z-index: 103
|
z-index: 103
|
||||||
overflow: hidden scroll
|
overflow-x: hidden
|
||||||
|
overflow-y: auto
|
||||||
width: 250px
|
width: 250px
|
||||||
height: 100%
|
height: 100%
|
||||||
background: #f6f8fa
|
background: #f6f8fa
|
||||||
|
|||||||
Reference in New Issue
Block a user