fix theme...
This commit is contained in:
26
themes/anzhiyu/layout/includes/anzhiyu/ai-info.pug
Normal file
26
themes/anzhiyu/layout/includes/anzhiyu/ai-info.pug
Normal file
@@ -0,0 +1,26 @@
|
||||
- let pageFillDescription = get_page_fill_description()
|
||||
- let gptName = theme.post_head_ai_description.gptName
|
||||
- let mode = theme.post_head_ai_description.mode
|
||||
- let switchBtn = theme.post_head_ai_description.switchBtn
|
||||
if (pageFillDescription && page.ai)
|
||||
.post-ai-description
|
||||
.ai-title
|
||||
i.anzhiyufont.anzhiyu-icon-bilibili
|
||||
.ai-title-text AI-摘要
|
||||
if (switchBtn)
|
||||
#ai-Toggle 切换
|
||||
i.anzhiyufont.anzhiyu-icon-arrow-rotate-right
|
||||
i.anzhiyufont.anzhiyu-icon-circle-dot(title="朗读摘要")
|
||||
#ai-tag
|
||||
if mode == "tianli"
|
||||
= "Tianli GPT"
|
||||
else
|
||||
= gptName + " GPT"
|
||||
.ai-explanation AI初始化中...
|
||||
.ai-btn-box
|
||||
.ai-btn-item 介绍自己 🙈
|
||||
.ai-btn-item 生成本文简介 👋
|
||||
.ai-btn-item 推荐相关文章 📖
|
||||
.ai-btn-item 前往主页 🏠
|
||||
.ai-btn-item#go-tianli-blog 前往爱发电购买
|
||||
script(data-pjax src=url_for(theme.asset.ai_abstract_js))
|
||||
29
themes/anzhiyu/layout/includes/anzhiyu/clock.pug
Normal file
29
themes/anzhiyu/layout/includes/anzhiyu/clock.pug
Normal file
@@ -0,0 +1,29 @@
|
||||
#he-plugin-simple
|
||||
script.
|
||||
var WIDGET = {
|
||||
"CONFIG": {
|
||||
"modules": "0124",
|
||||
"background": "2",
|
||||
"tmpColor": "FFFFFF",
|
||||
"tmpSize": "16",
|
||||
"cityColor": "FFFFFF",
|
||||
"citySize": "16",
|
||||
"aqiColor": "E8D87B",
|
||||
"aqiSize": "16",
|
||||
"weatherIconSize": "24",
|
||||
"alertIconSize": "18",
|
||||
"padding": "10px 10px 10px 10px",
|
||||
"shadow": "0",
|
||||
"language": "auto",
|
||||
"borderRadius": "20",
|
||||
"fixed": "true",
|
||||
"vertical": "top",
|
||||
"horizontal": "left",
|
||||
"left": "20",
|
||||
"top": "7.1",
|
||||
"key": "df245676fb434a0691ead1c63341cd94"
|
||||
}
|
||||
}
|
||||
|
||||
link(rel="stylesheet", href="https://widget.qweather.net/simple/static/css/he-simple.css?v=1.4.0")
|
||||
script(src="https://widget.qweather.net/simple/static/js/he-simple.js?v=1.4.0")
|
||||
47
themes/anzhiyu/layout/includes/anzhiyu/console.pug
Normal file
47
themes/anzhiyu/layout/includes/anzhiyu/console.pug
Normal file
@@ -0,0 +1,47 @@
|
||||
#console
|
||||
.console-card-group-reward
|
||||
ul.reward-all.console-card
|
||||
each item in theme.reward.QR_code
|
||||
li.reward-item
|
||||
a(href=url_for(item.link || item.img), target='_blank')
|
||||
img.post-qr-code-img(alt=item.text, src=url_for(item.img))
|
||||
.post-qr-code-desc=item.text
|
||||
.console-card-group
|
||||
.console-card-group-left
|
||||
!=partial('includes/widget/card_newest_comment', {}, {cache: true})
|
||||
.console-card-group-right
|
||||
.console-card.tags
|
||||
.card-content
|
||||
if theme.nav_music.enable && theme.nav_music.console_widescreen_music
|
||||
.author-content-item-tips 音乐
|
||||
span.author-content-item-title 灵魂的碰撞💥
|
||||
else
|
||||
.author-content-item-tips 兴趣点
|
||||
span.author-content-item-title 寻找你感兴趣的领域
|
||||
!=partial('includes/widget/card_console_tags', {}, {cache: true})
|
||||
.console-card.history
|
||||
.item-headline
|
||||
i.anzhiyufont.anzhiyu-icon-box-archiv
|
||||
span 文章
|
||||
!=partial('includes/widget/card_console_archives', {}, {cache: true})
|
||||
.button-group
|
||||
if theme.darkmode.enable
|
||||
.console-btn-item
|
||||
a.darkmode_switchbutton(title='显示模式切换', href='javascript:void(0);')
|
||||
i.anzhiyufont.anzhiyu-icon-moon
|
||||
.console-btn-item#consoleHideAside(onclick='anzhiyu.hideAsideBtn()', title='边栏显示控制')
|
||||
a.asideSwitch
|
||||
i.anzhiyufont.anzhiyu-icon-arrows-left-right
|
||||
if theme.comment_barrage_config.enable
|
||||
.console-btn-item.on#consoleCommentBarrage(onclick='anzhiyu.switchCommentBarrage()', title='热评开关')
|
||||
a.commentBarrage
|
||||
i.anzhiyufont.anzhiyu-icon-message
|
||||
if theme.nav_music.enable
|
||||
.console-btn-item#consoleMusic(onclick='anzhiyu.musicToggle()', title='音乐开关')
|
||||
a.music-switch
|
||||
i.anzhiyufont.anzhiyu-icon-music
|
||||
if theme.shortcutKey.enable
|
||||
.console-btn-item#consoleKeyboard(onclick='anzhiyu.keyboardToggle()', title='快捷键开关')
|
||||
a.keyboard-switch
|
||||
i.anzhiyufont.anzhiyu-icon-keyboard
|
||||
.console-mask(onclick='anzhiyu.hideConsole()', href='javascript:void(0);')
|
||||
78
themes/anzhiyu/layout/includes/anzhiyu/log-js.pug
Normal file
78
themes/anzhiyu/layout/includes/anzhiyu/log-js.pug
Normal file
@@ -0,0 +1,78 @@
|
||||
- let author = config.author
|
||||
- let launch_time = theme.footer.runtime.launch_time
|
||||
- let since = theme.footer.owner.since
|
||||
- let version = get_version("tags")
|
||||
script.
|
||||
// 消除控制台打印
|
||||
var HoldLog = console.log;
|
||||
console.log = function () {};
|
||||
let now1 = new Date();
|
||||
queueMicrotask(() => {
|
||||
const Log = function () {
|
||||
HoldLog.apply(console, arguments);
|
||||
}; //在恢复前输出日志
|
||||
const grt = new Date("#{launch_time}"); //此处修改你的建站时间或者网站上线时间
|
||||
now1.setTime(now1.getTime() + 250);
|
||||
const days = (now1 - grt) / 1000 / 60 / 60 / 24;
|
||||
const dnum = Math.floor(days);
|
||||
const ascll = [
|
||||
`欢迎使用安知鱼!`,
|
||||
`生活明朗, 万物可爱`,
|
||||
`
|
||||
|
||||
█████╗ ███╗ ██╗███████╗██╗ ██╗██╗██╗ ██╗██╗ ██╗
|
||||
██╔══██╗████╗ ██║╚══███╔╝██║ ██║██║╚██╗ ██╔╝██║ ██║
|
||||
███████║██╔██╗ ██║ ███╔╝ ███████║██║ ╚████╔╝ ██║ ██║
|
||||
██╔══██║██║╚██╗██║ ███╔╝ ██╔══██║██║ ╚██╔╝ ██║ ██║
|
||||
██║ ██║██║ ╚████║███████╗██║ ██║██║ ██║ ╚██████╔╝
|
||||
╚═╝ ╚═╝╚═╝ ╚═══╝╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝
|
||||
|
||||
`,
|
||||
"已上线",
|
||||
dnum,
|
||||
"天",
|
||||
"©#{since} By 安知鱼 V#{version}",
|
||||
];
|
||||
const ascll2 = [`NCC2-036`, `调用前置摄像头拍照成功,识别为【小笨蛋】.`, `Photo captured: `, `🤪`];
|
||||
|
||||
setTimeout(
|
||||
Log.bind(
|
||||
console,
|
||||
`\n%c${ascll[0]} %c ${ascll[1]} %c ${ascll[2]} %c${ascll[3]}%c ${ascll[4]}%c ${ascll[5]}\n\n%c ${ascll[6]}\n`,
|
||||
"color:#425AEF",
|
||||
"",
|
||||
"color:#425AEF",
|
||||
"color:#425AEF",
|
||||
"",
|
||||
"color:#425AEF",
|
||||
""
|
||||
)
|
||||
);
|
||||
setTimeout(
|
||||
Log.bind(
|
||||
console,
|
||||
`%c ${ascll2[0]} %c ${ascll2[1]} %c \n${ascll2[2]} %c\n${ascll2[3]}\n`,
|
||||
"color:white; background-color:#4fd953",
|
||||
"",
|
||||
"",
|
||||
'background:url("https://npm.elemecdn.com/anzhiyu-blog@1.1.6/img/post/common/tinggge.gif") no-repeat;font-size:450%'
|
||||
)
|
||||
);
|
||||
|
||||
setTimeout(Log.bind(console, "%c WELCOME %c 你好,小笨蛋.", "color:white; background-color:#4f90d9", ""));
|
||||
|
||||
setTimeout(
|
||||
console.warn.bind(
|
||||
console,
|
||||
"%c ⚡ Powered by 安知鱼 %c 你正在访问 #{author} 的博客.",
|
||||
"color:white; background-color:#f0ad4e",
|
||||
""
|
||||
)
|
||||
);
|
||||
|
||||
setTimeout(Log.bind(console, "%c W23-12 %c 你已打开控制台.", "color:white; background-color:#4f90d9", ""));
|
||||
|
||||
setTimeout(
|
||||
console.warn.bind(console, "%c S013-782 %c 你现在正处于监控中.", "color:white; background-color:#d9534f", "")
|
||||
);
|
||||
});
|
||||
82
themes/anzhiyu/layout/includes/anzhiyu/rightmenu.pug
Normal file
82
themes/anzhiyu/layout/includes/anzhiyu/rightmenu.pug
Normal file
@@ -0,0 +1,82 @@
|
||||
- const { translate } = theme
|
||||
#rightMenu
|
||||
.rightMenu-group.rightMenu-small
|
||||
.rightMenu-item#menu-backward
|
||||
i.anzhiyufont.anzhiyu-icon-arrow-left
|
||||
.rightMenu-item#menu-forward
|
||||
i.anzhiyufont.anzhiyu-icon-arrow-right
|
||||
.rightMenu-item#menu-refresh
|
||||
i.anzhiyufont.anzhiyu-icon-arrow-rotate-right(style="font-size: 1rem;")
|
||||
.rightMenu-item#menu-top
|
||||
i.anzhiyufont.anzhiyu-icon-arrow-up
|
||||
.rightMenu-group.rightMenu-line.rightMenuPlugin
|
||||
.rightMenu-item#menu-copytext
|
||||
i.anzhiyufont.anzhiyu-icon-copy
|
||||
span 复制选中文本
|
||||
.rightMenu-item#menu-pastetext
|
||||
i.anzhiyufont.anzhiyu-icon-paste
|
||||
span 粘贴文本
|
||||
a.rightMenu-item#menu-commenttext
|
||||
i.anzhiyufont.anzhiyu-icon-comment-medical
|
||||
span 引用到评论
|
||||
.rightMenu-item#menu-newwindow
|
||||
i.anzhiyufont.anzhiyu-icon-window-restore
|
||||
span 新窗口打开
|
||||
.rightMenu-item#menu-copylink
|
||||
i.anzhiyufont.anzhiyu-icon-link
|
||||
span 复制链接地址
|
||||
.rightMenu-item#menu-copyimg
|
||||
i.anzhiyufont.anzhiyu-icon-images
|
||||
span 复制此图片
|
||||
.rightMenu-item#menu-downloadimg
|
||||
i.anzhiyufont.anzhiyu-icon-download
|
||||
span 下载此图片
|
||||
.rightMenu-item#menu-newwindowimg
|
||||
i.anzhiyufont.anzhiyu-icon-window-restore
|
||||
span 新窗口打开图片
|
||||
.rightMenu-item#menu-search
|
||||
i.anzhiyufont.anzhiyu-icon-magnifying-glass
|
||||
span 站内搜索
|
||||
.rightMenu-item#menu-searchBaidu
|
||||
i.anzhiyufont.anzhiyu-icon-magnifying-glass
|
||||
span 百度搜索
|
||||
.rightMenu-item#menu-music-toggle
|
||||
i.anzhiyufont.anzhiyu-icon-play
|
||||
span 播放音乐
|
||||
.rightMenu-item#menu-music-back
|
||||
i.anzhiyufont.anzhiyu-icon-backward
|
||||
span 切换到上一首
|
||||
.rightMenu-item#menu-music-forward
|
||||
i.anzhiyufont.anzhiyu-icon-forward
|
||||
span 切换到下一首
|
||||
- const nav_music_all_playlist = theme.nav_music.all_playlist
|
||||
.rightMenu-item#menu-music-playlist(onclick=`window.open("${nav_music_all_playlist}", "_blank");`, style='display: none;')
|
||||
i.anzhiyufont.anzhiyu-icon-radio
|
||||
span 查看所有歌曲
|
||||
.rightMenu-item#menu-music-copyMusicName
|
||||
i.anzhiyufont.anzhiyu-icon-copy
|
||||
span 复制歌名
|
||||
.rightMenu-group.rightMenu-line.rightMenuOther
|
||||
a.rightMenu-item.menu-link#menu-randomPost
|
||||
i.anzhiyufont.anzhiyu-icon-shuffle
|
||||
span 随便逛逛
|
||||
a.rightMenu-item.menu-link(href='/categories/')
|
||||
i.anzhiyufont.anzhiyu-icon-cube
|
||||
span 博客分类
|
||||
a.rightMenu-item.menu-link(href='/tags/')
|
||||
i.anzhiyufont.anzhiyu-icon-tags
|
||||
span 文章标签
|
||||
.rightMenu-group.rightMenu-line.rightMenuOther
|
||||
a.rightMenu-item#menu-copy(href='javascript:void(0);')
|
||||
i.anzhiyufont.anzhiyu-icon-copy
|
||||
span 复制地址
|
||||
a.rightMenu-item#menu-commentBarrage(href='javascript:void(0);')
|
||||
i.anzhiyufont.anzhiyu-icon-message
|
||||
span.menu-commentBarrage-text 关闭热评
|
||||
a.rightMenu-item#menu-darkmode(href='javascript:void(0);')
|
||||
i.anzhiyufont.anzhiyu-icon-circle-half-stroke
|
||||
span.menu-darkmode-text 深色模式
|
||||
a.rightMenu-item#menu-translate(href='javascript:void(0);')
|
||||
i.anzhiyufont.anzhiyu-icon-language
|
||||
span=translate.rightMenuMsgDefault
|
||||
#rightmenu-mask
|
||||
20
themes/anzhiyu/layout/includes/anzhiyu/tags-group-all.pug
Normal file
20
themes/anzhiyu/layout/includes/anzhiyu/tags-group-all.pug
Normal file
@@ -0,0 +1,20 @@
|
||||
if site.data.creativity
|
||||
#skills-tags-group-all
|
||||
.tags-group-wrapper
|
||||
each i in site.data.creativity
|
||||
- const evenNum = i.creativity_list.filter((x, index) => index % 2 === 0);
|
||||
- const oddNum = i.creativity_list.filter((x, index) => index % 2 === 1);
|
||||
each item, index in i.creativity_list
|
||||
if ((index+1 <= evenNum.length) && (index+1 <= oddNum.length))
|
||||
.tags-group-icon-pair
|
||||
.tags-group-icon(style=`background: ${evenNum[index].color}`)
|
||||
img.no-lightbox(title=evenNum[index].name, src=evenNum[index].icon, size="60px" alt=evenNum[index].name)
|
||||
.tags-group-icon(style=`background: ${oddNum[index].color}`)
|
||||
img.no-lightbox(title=oddNum[index].name, src=oddNum[index].icon, size="60px" alt=oddNum[index].name)
|
||||
each item, index in i.creativity_list
|
||||
if ((index+1 <= evenNum.length) && (index+1 <= oddNum.length))
|
||||
.tags-group-icon-pair
|
||||
.tags-group-icon(style=`background: ${evenNum[index].color}`)
|
||||
img.no-lightbox(title=evenNum[index].name, src=evenNum[index].icon, size="60px" alt=evenNum[index].name)
|
||||
.tags-group-icon(style=`background: ${oddNum[index].color}`)
|
||||
img.no-lightbox(title=oddNum[index].name, src=oddNum[index].icon, size="60px" alt=oddNum[index].name)
|
||||
Reference in New Issue
Block a user