😆 Hey! Welcome to my profile
🍉 Take a look at my stats.
🌱 If you want to know more about me, please visit my blog
|
|
---|
博客园皮肤
License: ISC License
😆 Hey! Welcome to my profile
🍉 Take a look at my stats.
🌱 If you want to know more about me, please visit my blog
|
|
---|
同上
应用到博客设置后,刷新页面没有任何东西了
<!-- cnblogs.com Baidu tongji analytics -->
<script>
var _hmt = _hmt || [];
(function () {
var hm = document.createElement("script");
hm.src = "https://hm.baidu.com/hm.js?451e79a0eb2fa13dd013607b146b8e77";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();
</script>
<script type="text/javascript">
window.cnblogsConfig = {
// 拓展图标
// fontIconExtend: "https://cdn.cnblogs.com/jsDelivr/gh/BNDong/[email protected]/dist/style/fonticon.b054622b.css",
// link - 链接分享小尾巴
articleContent: {
link: true,
},
// 顶部进度条
progressBar: {
id: 'top-progress-bar', // 请勿修改该值
color: '#0076ff',
height: '3px',
duration: 0.2,
},
info: {
name: 'BNTang',
startDate: '2020-07-23',
// https://images.cnblogs.com/cnblogs_com/BNTang/1812554/o_210709055756BlogImage.png
avatar: 'https://img2022.cnblogs.com/blog/2105804/202207/2105804-20220728221952252-2069787489.png',
blogIcon: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/o_220623013841_uisdc-chat-chicken.gif'
},
sidebar: {
navList: [
['友链', 'https://www.cnblogs.com/BNTang/p/14737430.html', 'icon-lianjie'],
['书单', 'https://www.cnblogs.com/BNTang/p/13660390.html', 'icon-book'],
['Blog', 'https://bntang.github.io', 'icon-blog'],
['Gitee', 'https://gitee.com/BNTang', 'icon-gitee-fill'],
['GitLab', 'https://gitlab.com/Jone_Tang', 'icon-gitlab'],
['GitHub', 'https://github.com/BNTang', 'icon-github'],
['Cnblogs', 'https://www.cnblogs.com', 'icon-cnblogs']
],
titleMsg: '',
submenu: {
// 积分排行
pointsRank: true,
// 最新随笔
latestPosts: false,
// 我的标签
myTags: true,
// 随笔分类
postsClassify: true,
// 文章分类
articleClassify: true,
// 阅读排行
readRank: false,
// 推荐排行
recommendRank: false,
// 帖子档案
postsArchive: false,
// 文章档案
articleArchive: false,
// 自定义列表
customList: true,
// 最新评论
latestComment: false
}
},
// switchDayNight - 日/夜间模式
switchDayNight: {
enable: true,
// 是否默认一开始就是夜间模式
nightMode: false,
auto: {
enable: true,
dayHour: 5,
nightHour: 19
}
},
banner: {
home: {
background: [
"https://files.dbnuo.com/wallpaper/wallhaven-ne7lr8.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-k9p8l6.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-xl67ov.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-dgekog.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-47ldq9.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-lm2762.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-13mk9v.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-39qjjd.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-83w372.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-96w8e8.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-dgojvj.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-oxvkxp.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-83yl1y.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-6k88jq.webp"
],
title: [],
titleSource: 'one',
},
article: {
background: [
"https://files.dbnuo.com/wallpaper/wallhaven-13dv2g.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-lqddel.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-kwkg5q.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-ym56zg.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-yml8wd.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-ym62z7.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-6k3oox.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-dgeqoj.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-1j65pv.webp",
"https://files.dbnuo.com/wallpaper/wallhaven-kwxz16.webp"
],
}
},
links: {},
articleSuffix: {
imgUrl: '',
},
footer: {
text: {
left: '授之以欲',
right: '受之以瑜',
},
style: 2
},
cnzz: '1279528291',
rtMenu: {
qrCode: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/t_200723102903WeChat.jpg',
reward: {
alipay: 'https://images.cnblogs.com/cnblogs_com/TangXiaoHuiHui/1653035/t_200710143042alipay.png',
wechatpay: 'https://images.cnblogs.com/cnblogs_com/TangXiaoHuiHui/1653035/t_200710143033wechatpay.png'
},
downScrollDom: '#blog_post_info_block',
},
code: {
type: 'hljs',
options: {
hljs: {
// theme: 'agate',
theme: 'an-old-hope',
// theme: 'github',
// theme: 'github-gist',
// theme: 'atom-one-dark-reasonable',
languages: ['Bash', 'curl', 'CSS', 'Dockerfile', 'Go', 'HTML', 'XML', 'HTTP', 'Sass', 'Scss', 'Less', 'Lua', 'PHP', 'Python', 'Shell', 'SQL', 'Java', 'JSON']
},
maxHeight: '50vh',
line: true,
macStyle: true,
},
},
/*code: {
type: 'hljs',
options: {
line: true,
macStyle: true,
maxHeight: '70vh',
hljs: {
theme: 'a11y-dark',
languages: []
},
},
},*/
articleDirectory: {
position: 'right',
minBodyWeight: 900
},
animate: {
avatar: {
enable: true,
},
// 主页name动效
infoName: {
enable: true,
},
bannerImages: {
enable: true,
options: {
itemNum: 6,
current: -1,
sort: 1,
time: 30000
}
},
homeBanner: {
enable: true,
options: {
radius: 15,
density: 0.2,
color: 'rgba(255,255,255, .2)',
clearOffset: 0.3
}
},
// articleTitle - 文章页标题动效
articleTitle: {
enable: true
},
articleBanner: {
enable: true
},
// 背景动效
background: {
enable: false,
options: {
colorSaturation: "60%",
colorBrightness: "50%",
colorAlpha: 0.5,
colorCycleSpeed: 5,
verticalPosition: "random",
horizontalSpeed: 200,
ribbonCount: 3,
strokeSize: 0,
parallaxAmount: -0.2,
animateSections: true
}
},
// 背景动效,颜色比较浅不影响阅读,鼠标移动有简单动偏移动画。
backgroundMouse: {
enable: true
},
mouse: {
enable: false,
options: {
size: 1,
sizeF: 15
}
}
},
consoleList: [
['BNTang Gitee', 'gitee.com/BNTang'],
['BNTang GitHub', 'github.com/BNTang'],
['BNTang GitLab', 'gitlab.com/Jone_Tang'],
['BNTang Email', '[email protected]'],
],
// 纪念日
memorialDays: ['12-13', '07-27'],
}
window.cnblogsConfig.links.footer = [
["兔二工具", 'https://www.tool22.com'],
["Space", 'https://bntang.jetbrains.space'],
["Spring", 'https://spring.io'],
["简单网", 'https://www.ddayh.com'],
["wallhaven", 'https://wallhaven.cc'],
["速蛙云", 'https://m.ok4.icu/m/login'],
["notion", 'https://www.notion.so/zh-cn'],
["jetbrains", 'https://www.jetbrains.com'],
["试试吧", 'https://try8.cn'],
["SimpleMemory", 'https://bndong.github.io/Cnblogs-Theme-SimpleMemory/v2/#/'],
["stackoverflow", 'https://stackoverflow.com/'],
["mdn", 'https://developer.mozilla.org/zh-CN/'],
["npm", 'https://www.npmjs.com/']
]
// 友链配置
window.cnblogsConfig.links.page = [
{
title: '友情链接',
icon: 'icon-lianjie',
style: 'color: #a78bfa;',
links: [
{
name: 'BNDong',
introduction: 'IT技术类博客',
avatar: 'https://blog.dbnuo.com/images/avatar.gif',
url: 'https://blog.dbnuo.com'
},
{
name: 'qq628b229e2808e',
introduction: '51CTO, IT技术类博客',
avatar: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/t_200723130824author.png',
url: 'https://blog.51cto.com/u_15652665'
},
{
name: 'LOGI',
introduction: '会点代码的强迫症',
avatar: 'https://code.bdstatic.com/npm/[email protected]/logi.im/usr/images/global/logo.webp',
url: 'https://logi.im'
},
{
name: 'MrBird',
introduction: 'IT技术类博客',
avatar: 'https://mrbird.cc/images/blogImage.jpg',
url: 'https://mrbird.cc'
},
{
name: 'JonathanLee',
introduction: 'IT技术类博客',
avatar: 'https://images.cnblogs.com/cnblogs_com/TangXiaoHuiHui/1653035/o_200629043451default.jpg',
url: 'https://www.cnblogs.com/TangXiaoHuiHui'
},
{
name: '哈喽沃德先生',
introduction: '专注「JAVA,SPRING全家桶,微服务,高频面试题,软件开发技巧」',
avatar: 'https://mrhelloworld.com/resources/mrhelloworld/logo/avatar.jpg',
url: 'https://mrhelloworld.com'
},
{
name: '麋鹿鲁哟',
introduction: '大道至简,知易行难。',
avatar: 'https://pic.cnblogs.com/avatar/1273193/20190806180831.png',
url: 'https://www.cnblogs.com/miluluyo'
},
{
name: 'MikeC\'s Blog',
introduction: 'Study && Lost',
avatar: 'https://s1.ax1x.com/2020/07/05/UST4gS.jpg',
url: 'https://oiermikec.fun'
},
{
name: '南清风',
introduction: '不论何时,能依赖的只有自己变得的强大!',
avatar: 'https://pic.cnblogs.com/avatar/1491353/20191026164939.png',
url: 'https://www.cnblogs.com/su-root'
},
{
name: '杨不易',
introduction: '你的压力源于无法自律,只是假装努力,现状跟不上你内心的欲望,所以你焦急又恐慌---杨不易',
avatar: 'https://www.yangbuyi.top/upload/2021/05/logo-8ae334efbd044f83814f25a6183c7acd.png',
url: 'https://yangbuyi.top'
},
{
name: '未明上',
introduction: '鱼跃此时海,❤️花开彼岸天。',
avatar: 'https://images.cnblogs.com/cnblogs_com/blogs/629733/galleries/1978586/o_211120142931_Weimingshang.jpg',
url: 'https://www.cnblogs.com/WeiMingShang'
},
{
name: '知了',
introduction: '朝闻道,夕可眠矣。',
avatar: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/t_211130103350_default.gif',
url: 'https://zhile.io'
},
/*{
name: '维安雨轩 の Blog',
introduction: '寒蝉黎明之时,便是重生之日',
avatar: 'https://cdn.jsdelivr.net/gh/Ukenn2112/[email protected]/index/666.jpg',
url: 'https://blog.ukenn.top'
},*/
{
name: 'Nite07',
introduction: 'Share And Release',
avatar: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/t_211130103350_default.gif',
url: 'https://www.nite07.com'
},
{
name: 'N0ts Blog',
introduction: '一个爱好钻研技术的咸鱼',
avatar: 'https://cdn.nutssss.cn/wp-content/uploads/2020/02/1581510626-head.png',
url: 'https://blog.n0ts.cn'
},
{
name: '资源汇社区的资源库',
introduction: '这个人很酷,就留了个资源站',
avatar: 'https://dd-static.jd.com/ddimg/jfs/t1/218969/34/4067/23293/618be263E04f882ba/b50231b0cd00edf2.jpg',
url: 'http://ziyuanhuishequ.ys168.com'
},
/*{
name: 'ZHC',
introduction: '知道的越多,不知道的就越多。',
avatar: 'https://zhc-picture.cdn.bcebos.com/tx.jpeg',
url: 'https://www.zhhc.cc'
},*/
{
name: 'LzsCxb',
introduction: '这个人很酷,就留了个博客地址',
avatar: 'https://img2020.cnblogs.com/blog/2354934/202110/2354934-20211019224941117-168626507.png',
url: 'https://www.cnblogs.com/LzsCxb'
},
{
name: '懒得勤快的博客',
introduction: '本站是一个集精品软件、资源共享、前端技术和后端开发等互联网技术分享的博客,专注于资源分享、前端开发和后端技术。热衷于互联网行业,喜欢各种折腾。',
avatar: 'https://pic.ldqkcdn.top/20190606/5dc7fc1266bfd8109d1ef5e0e7630f2c_2_3_art.png',
url: 'https://masuit.com'
},
{
name: 'DuLi',
introduction: 'Do one thing at a time, and do well',
avatar: 'https://dulily.gitee.io/image/ava.png',
url: 'https://dulily.gitee.io/'
},
/*{
name: '陈亮',
introduction: '如果你不给自己设限,你的人生就没有极限。',
avatar: 'https://cdn.jsdelivr.net/gh/helinghands/cdn/img/avatar.jpg',
url: 'http://blog.itchenliang.club/'
},*/
{
name: 'Lance',
introduction: 'Front-end developer and iOS developer',
avatar: 'https://evestorm.github.io/uploads/avatar_lance.jpeg',
url: 'https://evestorm.github.io/'
},
{
name: '小飞博客',
introduction: '生活明朗,万物可爱,人间值得,未来可期。',
avatar: 'https://static.xffjs.com/xffjs/static/front/images/logo.png',
url: 'https://www.xffjs.com'
},
/*{
name: 'LyShark',
introduction: '专注信息安全技术',
avatar: 'https://images.cnblogs.com/cnblogs_com/LyShark/2122613/o_220310113333_security.png',
url: 'https://www.cnblogs.com/lyshark'
},*/
{
name: '山海小站',
introduction: '山海小站的宗旨是“推荐为王,资源为辅!”精选推荐分享各类影视/软件/美剧/动漫动画阿里云盘-天翼网盘资源',
avatar: 'https://sh1.shanhaiz.com/img/shbbs/2022/04/20220401104002761.png',
url: 'https://bbs.shanhaiz.com/'
},
{
name: 'hkgov',
introduction: '这个人很酷,就留了个博客地址',
avatar: 'http://file.qqtouxiang.com/nansheng/2020-03-11/c3d0257cc6697914bd5d6725c00c085c.jpeg',
url: 'https://www.cnblogs.com/hkgov/'
},
{
name: '攻城狮耗子',
introduction: '这个人很酷,就留了个博客地址',
avatar: 'https://pic.cnblogs.com/avatar/2726623/20220114174242.png',
url: 'https://www.cnblogs.com/haozi666'
},
{
name: 'xkcoding',
introduction: 'xkcoding 的代码成长日记',
avatar: 'https://static.xkcoding.com/blog/2020-04-02-xkcoding_favicon.png',
url: 'https://xkcoding.com'
},
{
name: '薛丫丫',
introduction: '这个人很酷,就留了个博客地址',
avatar: 'https://images.cnblogs.com/cnblogs_com/BNTang/1812554/t_211130103350_default.gif',
url: 'https://www.cnblogs.com/zhangsf8080/'
},
{
name: '。思索',
introduction: '这个人很酷,就留了个博客地址',
avatar: 'https://pic.cnblogs.com/face/1334215/20180504110551.png',
url: 'https://www.cnblogs.com/wangyang0210'
},
]
},
{
title: '网站',
icon: 'icon-website',
style: 'color: #a78bfa;',
links: [
// -------------------------网站-------------------------
{
name: 'Youtube',
introduction: '视频网站',
avatar: 'https://i.loli.net/2020/05/14/9ZkGg8v3azHJfM1.png',
url: 'https://www.youtube.com/'
},
{
name: 'Weibo',
introduction: '**最大社交分享平台',
avatar: 'https://i.loli.net/2020/05/14/TLJBum386vcnI1P.png',
url: 'https://www.weibo.com/'
},
{
name: 'Twitter',
introduction: '社交分享平台',
avatar: 'https://i.loli.net/2020/05/14/5VyHPQqR6LWF39a.png',
url: 'https://twitter.com/'
}
// -------------------------网站-------------------------
]
},
];
// 书单
window.cnblogsConfig.bookList = [
{
title: '在读',
books: [
{
cover: 'https://images.cnblogs.com/cnblogs_com/BNTang/1846939/t_200913155700%E7%A0%81%E5%87%BA%E9%AB%98%E6%95%88.jpg',
name: '码出高效:Java开发手册',
formerName: '',
author: '杨冠宝 / 高海慧',
translator: '',
press: '电子工业出版社',
year: '2018-10',
score: 5,
readDate: '23.51.05',
readPercentage: '90%'
},
]
},
{
title: '库存',
books: [
{
// 封面
cover: 'https://images.cnblogs.com/cnblogs_com/BNTang/1846939/t_210426110537ArtOfWar.jpg',
// 书名
name: '孙子兵法',
// 原书名
formerName: '',
// 作者
author: '孙武',
// 译者
translator: '郭化若',
// 出版社
press: '上海古籍出版社',
// 出版年
year: '2006-07-01',
// 等级1〜5
score: 5,
readDate: '00.00.00',
readPercentage: '0%'
},
]
},
{
title: '心愿',
books: [
{
cover: 'https://files.dbnuo.com/bkCover/s1291183.jpg',
name: '君主论',
formerName: 'Il Principe',
author: '[意] 尼科洛·马基雅维里',
translator: '潘汉典',
press: '商务印书馆',
year: '1985-7',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s3658701.jpg',
name: '潜规则:**历史中的真实游戏',
formerName: '',
author: '吴思',
translator: '',
press: '云南人民出版社',
year: '2001-1',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s2918885.jpg',
name: '血酬定律:**历史中的生存游戏',
formerName: '',
author: '吴思',
translator: '',
press: '**工人出版社',
year: '2003-08',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s27256973.jpg',
name: '爱的博弈:建立信任、避免背叛与不忠',
formerName: 'What makes love last? how to build trust and avoid betrayal',
author: '约翰·戈特曼 (John Gottman) / 娜恩·西尔弗 (Nan Silver)',
translator: '穆君 / 伏维',
press: '浙江人民出版社',
year: '2014-1',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s3838207.jpg',
name: '洞穴奇案',
formerName: 'The Case of the Speluncean Explorers',
author: '[美] 萨伯',
translator: '陈福勇 / 张世泰',
press: '生活·读书·新知三联书店',
year: '2009-6',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s2719608.jpg',
name: '合作的进化',
formerName: 'The evolution of cooperation',
author: '[美] 罗伯特·阿克塞尔罗德',
translator: '吴坚忠',
press: '上海人民出版社',
year: '2017-8',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s27433242.jpg',
name: '激荡三十年:**企业1978-2008',
formerName: '',
author: '吴晓波',
translator: '',
press: '中信出版社',
year: '2014-7',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s29539449.jpg',
name: '极简法则',
formerName: 'Simplify',
author: '[美] 理查德·科克 / 格雷格·洛克伍德',
translator: '李璐',
press: '后浪丨江西人民出版社',
year: '2018-2',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s29063065.jpg',
name: 'Java核心技术·卷 I(原书第10版)',
formerName: 'Core Java Volume I - Fundamentals (10th Edition)',
author: '[美] 凯.S.霍斯特曼(Cay S. Horstmann)',
translator: '周立新 等',
press: '机械工业出版社',
year: '2016-9',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s29628940.jpg',
name: 'Java核心技术·卷 II(原书第10版)',
formerName: 'Core Java, Volume II Advanced Features',
author: '[美] 凯.S.霍斯特曼(Cay S. Horstmann)',
translator: '陈昊鹏',
press: '机械工业出版社',
year: '2017-9',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s27956707.jpg',
name: '清明上河图密码',
formerName: '',
author: '冶文彪',
translator: '',
press: '北京联合出版公司',
year: '2015-1',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s4220739.jpg',
name: '设计模式之禅',
formerName: '',
author: '秦小波',
translator: '',
press: '机械工业出版社',
year: '2010-3',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s29466768.jpg',
name: '美国众神',
formerName: 'American Gods',
author: '[英] 尼尔·盖曼',
translator: '戚林',
press: '北京联合出版公司',
year: '2017-4',
score: 0
},
{
cover: 'https://files.dbnuo.com/bkCover/s24468373.jpg',
name: '看见',
formerName: '',
author: '柴静',
translator: '',
press: '广西师范大学出版社',
year: '2013-1',
score: 0
},
]
},
{
title: '搁置',
books: []
},
{
title: '已读',
books: []
},
];
window.cnblogsConfig.hooks = {
beforeCode: (_) => {
// console.log('code 渲染开始前');
},
afterCode: (_) => {
// console.log('code 渲染结束后');
},
beforeLoading: (_) => {
// console.log('loading 开始前');
},
afterLoading: (_) => {
// console.log('loading 结束后');
addEndImage();
birthday(new Date());
},
dayNightControl: (_, type) => {
// console.log(type);
// console.log('日/夜间模式');
},
}
// 添加文章底部End图片
const addEndImage = () => {
const oPostBody = document.querySelector("#cnblogs_post_body");
if (oPostBody === null) {
return;
}
const oUrl = window.location.href;
const filterUrlArray = ['14737430.html', 'category', '13660390.html'];
const index = filterUrlArray.findIndex((currentValue) => {
if (oUrl.indexOf(currentValue) !== -1) {
return true;
}
});
if (index !== -1) {
return;
}
// https://img2020.cnblogs.com/blog/2105804/202111/2105804-20211123214022176-1481511294.gif
// https://img2022.cnblogs.com/blog/2105804/202207/2105804-20220723133506934-1397639141.gif
const imageUrl = 'https://img2022.cnblogs.com/blog/2105804/202207/2105804-20220727003232595-1971106522.gif';
// 创建End Element
let oDiv = document.createElement("div");
oDiv.style.width = "100" + "%";
oDiv.style.height = "173" + "px";
oDiv.style.marginLeft = "55" + "px";
oDiv.style.background = `url('${imageUrl}') no-repeat 0 center`;
oPostBody.appendChild(oDiv);
}
/**
* 生日特效提示,如果当天的农历是你的出生那天的日子
* 生日蛋糕特效会在页面呈现
* @param bornDate 出生日期(农历)yyyy-mm-dd
*/
const birthday = (bornDate) => {
const birthdayList = getChineseDate(bornDate);
const dateVar = birthdayList.m + birthdayList.d;
const elementVar = [
// 本人
{dateVar: '五月二十五', name: 'BNTang'},
// 猪头
{dateVar: '十二月十一', name: '猪头🐷'},
];
let newArray = elementVar.filter(function (currentValue, currentIndex, currentArray) {
if (currentValue.dateVar === dateVar) {
return true;
}
});
let name = newArray.map((obj) => {
return obj.name
}).join("、");
if (newArray.length !== 0) {
setBirthdayStyle(name);
let msg = [`\n %c %c %c 生日快乐 ${name} %c %c 没有浪漫的诗句,没有贵重的礼物,没有例外的惊喜,只有轻轻的生日祝福 %c \n\n`, "background: #fadfa3; padding:5px 0;", "background: #fadfa3; padding:5px 0;", "color: #fadfa3; background: #030307; padding:5px 0;", "background: #fadfa3; padding:5px 0;", "background: #FCEDC9; color:#030307; padding:5px 0;", "background: #fadfa3; padding:5px 0;"];
window.console.log.apply(console, msg);
return;
}
let msg = ["\n %c %c %c 今日好友生日报告:无 %c %c 🐤时间在哪,成就在哪 %c \n\n", "background: #fadfa3; padding:5px 0;", "background: #fadfa3; padding:5px 0;", "color: #fadfa3; background: #030307; padding:5px 0;", "background: #fadfa3; padding:5px 0;", "background: #FCEDC9; color:#030307; padding:5px 0;", "background: #fadfa3; padding:5px 0;"];
window.console.log.apply(console, msg);
}
const numberToString = (number) => {
if (number.match(/\D/) || number.length >= 14) return;
let zhArray = ['零', '一', '二', '三', '四', '五', '六', '七', '八', '九', '十']; // 数字对应中文
let baseArray = ['', '十', '百', '千', '万', '十', '百', '千', '亿', '十', '百', '千', '万']; //进位填充字符,第一位是 个位,可省略
let string = String(number).split('').reverse().map((item, index) => { // 把数字切割成数组并倒序排列,然后进行遍历转成中文
// 如果当前位为0,直接输出数字, 否则输出 数字 + 进位填充字符
item = Number(item) === 0 ? zhArray[Number(item)] : zhArray[Number(item)] + baseArray[index];
return item;
}).reverse().join(''); // 倒叙回来数组,拼接成字符串
string = string.replace(/^一十/, '十'); // 如果以 一十 开头,可省略一
string = string.replace(/零+/, '零'); // 如果有多位相邻的零,只写一个即可
let index = -1;
if (string.length >= 2) {
index = string.lastIndexOf('零');
}
return index === -1 ? string : string.substring(0, index);
}
const getChineseDate = (time) => {
let date = time ? new Date(time) : new Date();
dateString = date.toLocaleString('zh-CN-u-ca-chinese');
dateString = dateString.replace(/(\d+)\s*?年/, (x, y) => {
let result = '';
result = "甲乙丙丁戊己庚辛壬癸".charAt((y - 4) % 10); // 天干
result += "子丑寅卯辰巳午未申酉戌亥".charAt((y - 4) % 12); // 地支
return result;
});
dateString = dateString.split(' ')[0]; // 取年月日
let g = dateString.substr(0, 2) + '年';
let m = dateString.substring(2, dateString.match('月').index) + '月';
let d = dateString.match(/\d+/)[0];
d = d < 11 ? '初' + numberToString(d) : numberToString(d);
let animals = ["猴", "鸡", "狗", "猪", "鼠", "牛", "虎", "兔", "龙", "蛇", "马", "羊"];
let index = date.toLocaleString('zh-CN-u-ca-chinese').substr(0, 4) % 12;
let a = animals[index];
return {
g, // 干支
m, // 月
d, // 日
a // 生肖
};
}
const setBirthdayStyle = (name) => {
let bodyWidth = document.body.clientWidth;
let bodyHeight = document.body.clientHeight;
let BNTangBirthdayLocation = document.querySelector('#BNTang-birthdayLocation');
let BNTangBirthdayCake = document.querySelector('#BNTang-birthdayCake');
let birthdayName = document.querySelector('#birthdayName');
BNTangBirthdayLocation.style.width = bodyWidth + 'px';
BNTangBirthdayLocation.style.height = bodyHeight + 'px';
BNTangBirthdayCake.style.width = 100 + '%';
BNTangBirthdayCake.style.height = 100 + '%';
birthdayName.innerHTML = `happy birthday ${name}!`;
BNTangBirthdayCake.style.display = 'block';
setTimeout(() => {
BNTangBirthdayLocation.style.display = 'none';
BNTangBirthdayCake.style.display = 'none';
}, 8000);
}
</script>
<script src="https://cdn.jsdelivr.net/gh/wangyang0210/[email protected]/dist/simpleMemory.js" defer></script>
如果没有在页脚HTML代码
添加任何东西,会报错,需修改元素追加位置;
今天早起看了部电影,所以引发了这个issue,目前主题已经有了书单的功能,大家可以讨论下是否需要增加下影单的功能;
是否有必要加入pjax,进行局部刷新;
目前发现只要在下方配置了animate,就会发生前面的配置项被覆盖的问题:背景图(主页及文章)、头像、titleMsg等都被覆盖不生效了。
例如在switchDayNight项目下方再增加animate配置项(无论其中项目是否为true)
animate: {
infoName: {
enable: false,
},
}
RT:请问鼠标点击特效如何实现的?
新的问题,Control+F5 强制刷新后页面一直加载,你的博客也有这个问题,普通的F5刷新是可以的。
文章内容区域才显示分享链接icon
问题如上
是否希望主题增加配置展示歌词以及歌词的播放位置?
如果有需要增加的一些共用的ICONFONT,请在此ISSUES提出;
如题
图片无
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.