提交 0baa62f5 编写于 作者: EvanOne(文一)'s avatar EvanOne(文一)

feat: Add the info of theme in console

上级 97fb0810
$(document).ready(function () {
Stun.utils.showThemeInConsole();
CONFIG.shortcuts.switch_post && Stun.utils.registerHotkeyToSwitchPost();
// Not reload this, because it's changeless.
......
......@@ -82,6 +82,16 @@ Stun.utils = Stun.$u = {
isDesktop: function () {
return !this.isTablet() && !this.isMobile();
},
showThemeInConsole: function () {
var stunInfo = '主题不错?⭐star 支持一下 ->';
var stunURL = 'https://github.com/liuyib/hexo-theme-stun';
var stunNameStr = '\n\n ___ ___ ___ ___ \n /\\ \\ /\\ \\ /\\__\\ /\\__\\ \n /::\\ \\ \\:\\ \\ /:/ / /::| | \n /:/\\ \\ \\ \\:\\ \\ /:/ / /:|:| | \n _\\:\\ \\ \\ \\ /::\\ \\ /:/ / ___ /:/|:| |__ \n /\\ \\:\\ \\ \\__\\ /:/\\:\\__\\ /:/__/ /\\__\\ /:/ |:| /\\__\\ \n \\:\\ \\:\\ \\/__/ /:/ \\/__/ \\:\\ \\ /:/ / \\/__|:|/:/ / \n \\:\\ \\:\\__\\ /:/ / \\:\\ /:/ / |:/:/ / \n \\:\\/:/ / \\/__/ \\:\\/:/ / |::/ / \n \\::/ / \\::/ / /:/ / \n \\/__/ \\/__/ \\/__/ \n \n';
var stunInfoStyle = 'background-color: #49b1f5; color: #fff; padding: 8px; font-size: 14px;';
var stunURLStyle = 'background-color: #ffbca2; padding: 8px; font-size: 14px;';
var stunNameStyle = 'background-color: #eaf8ff;';
console.log('%c%s%c%s%c%s', stunInfoStyle, stunInfo, stunURLStyle, stunURL, stunNameStyle, stunNameStr);
},
/**
* Change the event code to keyCode.
* @param {String} code Event code
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册