halo-theme-joe2.0主题修改记录
增
添加每日60s新闻
添加摸鱼人日记
https://api.vvhan.com/api/moyu
文章打赏
添加文章打赏,支持支付宝/微信。
接入广告
开启强制ssl
添加来源IP显示
位置:template/common/footer.ftl
大概在配置访问量前
<i class="fa fa-flag" aria-hidden="true">
<script src="https://pv.sohu.com/cityjson?ie=utf-8"></script>
<script type="text/javascript">
document.write('IP地址:' + returnCitySN["cip"] +' ' + returnCitySN["cname"]);
</script>
</i>
来源作者:胖胖
来源网站:https://www.sxs.icu/
增加一个右键菜单功能
css
位置:自定义–>自定义css
.toastify {
padding: 12px 20px;
color: #ffffff;
display: inline-block;
box-shadow: 0 3px 6px -1px rgba(0, 0, 0, 0.12), 0 10px 36px -4px rgba(77, 96, 232, 0.3);
background: -webkit-linear-gradient(315deg, #73a5ff, #5477f5);
background: linear-gradient(135deg, #73a5ff, #5477f5);
position: fixed;
opacity: 0;
transition: all 0.4s cubic-bezier(0.215, 0.61, 0.355, 1);
border-radius: 2px;
cursor: pointer;
text-decoration: none;
max-width: calc(50% - 20px);
z-index: 2147483647;
}
.toastify.on {
opacity: 1;
}
.toast-close {
background: transparent;
border: 0;
color: white;
cursor: pointer;
font-family: inherit;
font-size: 1em;
opacity: 0.4;
padding: 0 5px;
}
.toastify-right {
right: 15px;
}
.toastify-left {
left: 15px;
}
.toastify-top {
top: -150px;
}
.toastify-bottom {
bottom: -150px;
}
.toastify-rounded {
border-radius: 25px;
}
.toastify-avatar {
width: 1.5em;
height: 1.5em;
margin: -7px 5px;
border-radius: 2px;
}
.toastify-center {
margin-left: auto;
margin-right: auto;
left: 0;
right: 0;
max-width: fit-content;
max-width: -moz-fit-content;
}
@media only screen and (max-width: 360px) {
.toastify-right, .toastify-left {
margin-left: auto;
margin-right: auto;
left: 0;
right: 0;
max-width: fit-content;
}
}
a {text-decoration: none;}
div.usercm{overflow: hidden;background-repeat:no-repeat;background-position:center center;background-size:cover;background-color:#fff;font-size:13px!important;width:130px;-moz-box-shadow:1px 1px 3px rgba
(0,0,0,.3);box-shadow:0px 0px 15px #333;position:absolute;display:none;z-index:99;opacity:0.9; border-radius: 8px;}
div.usercm ul{list-style-type:none;list-style-position:outside;margin:0px;padding:0px;display:block}
div.usercm ul li{margin:0px;padding:0px;line-height:35px;}
div.usercm ul li a{color:#666;padding:0 15px;display:block}
div.usercm ul li a:hover{color:#fff;background:#fb6c28}
div.usercm ul li a i{margin-right:10px}
a.disabled{color:#c8c8c8!important;cursor:not-allowed}
a.disabled:hover{background-color:rgba(255,11,11,0)!important}
div.usercm{background:#fff !important;}
js
位置:自定义–>自定义js(body)
(function(root, factory) {
if (typeof module === "object" && module.exports) {
module.exports = factory();
} else {
root.Toastify = factory();
}
})(this, function(global) {
// Object initialization
var Toastify = function(options) {
// Returning a new init object
return new Toastify.lib.init(options);
},
// Library version
version = "1.12.0";
// Set the default global options
Toastify.defaults = {
oldestFirst: true,
text: "Toastify is awesome!",
node: undefined,
duration: 3000,
selector: undefined,
callback: function () {
},
destination: undefined,
newWindow: false,
close: false,
gravity: "toastify-top",
positionLeft: false,
position: '',
backgroundColor: '',
avatar: "",
className: "",
stopOnFocus: true,
onClick: function () {
},
offset: {x: 0, y: 0},
escapeMarkup: true,
ariaLive: 'polite',
style: {background: ''}
};
// Defining the prototype of the object
Toastify.lib = Toastify.prototype = {
toastify: version,
constructor: Toastify,
// Initializing the object with required parameters
init: function(options) {
// Verifying and validating the input object
if (!options) {
options = {};
}
// Creating the options object
this.options = {};
this.toastElement = null;
// Validating the options
this.options.text = options.text || Toastify.defaults.text; // Display message
this.options.node = options.node || Toastify.defaults.node; // Display content as node
this.options.duration = options.duration === 0 ? 0 : options.duration || Toastify.defaults.duration; // Display duration
this.options.selector = options.selector || Toastify.defaults.selector; // Parent selector
this.options.callback = options.callback || Toastify.defaults.callback; // Callback after display
this.options.destination = options.destination || Toastify.defaults.destination; // On-click destination
this.options.newWindow = options.newWindow || Toastify.defaults.newWindow; // Open destination in new window
this.options.close = options.close || Toastify.defaults.close; // Show toast close icon
this.options.gravity = options.gravity === "bottom" ? "toastify-bottom" : Toastify.defaults.gravity; // toast position - top or bottom
this.options.positionLeft = options.positionLeft || Toastify.defaults.positionLeft; // toast position - left or right
this.options.position = options.position || Toastify.defaults.position; // toast position - left or right
this.options.backgroundColor = options.backgroundColor || Toastify.defaults.backgroundColor; // toast background color
this.options.avatar = options.avatar || Toastify.defaults.avatar; // img element src - url or a path
this.options.className = options.className || Toastify.defaults.className; // additional class names for the toast
this.options.stopOnFocus = options.stopOnFocus === undefined ? Toastify.defaults.stopOnFocus : options.stopOnFocus; // stop timeout on focus
this.options.onClick = options.onClick || Toastify.defaults.onClick; // Callback after click
this.options.offset = options.offset || Toastify.defaults.offset; // toast offset
this.options.escapeMarkup = options.escapeMarkup !== undefined ? options.escapeMarkup : Toastify.defaults.escapeMarkup;
this.options.ariaLive = options.ariaLive || Toastify.defaults.ariaLive;
this.options.style = options.style || Toastify.defaults.style;
if(options.backgroundColor) {
this.options.style.background = options.backgroundColor;
}
// Returning the current object for chaining functions
return this;
},
// Building the DOM element
buildToast: function() {
// Validating if the options are defined
if (!this.options) {
throw "Toastify is not initialized";
}
// Creating the DOM object
var divElement = document.createElement("div");
divElement.className = "toastify on " + this.options.className;
// Positioning toast to left or right or center
if (!!this.options.position) {
divElement.className += " toastify-" + this.options.position;
} else {
// To be depreciated in further versions
if (this.options.positionLeft === true) {
divElement.className += " toastify-left";
console.warn('Property `positionLeft` will be depreciated in further versions. Please use `position` instead.')
} else {
// Default position
divElement.className += " toastify-right";
}
}
// Assigning gravity of element
divElement.className += " " + this.options.gravity;
if (this.options.backgroundColor) {
// This is being deprecated in favor of using the style HTML DOM property
console.warn('DEPRECATION NOTICE: "backgroundColor" is being deprecated. Please use the "style.background" property.');
}
// Loop through our style object and apply styles to divElement
for (var property in this.options.style) {
divElement.style[property] = this.options.style[property];
}
// Announce the toast to screen readers
if (this.options.ariaLive) {
divElement.setAttribute('aria-live', this.options.ariaLive)
}
// Adding the toast message/node
if (this.options.node && this.options.node.nodeType === Node.ELEMENT_NODE) {
// If we have a valid node, we insert it
divElement.appendChild(this.options.node)
} else {
if (this.options.escapeMarkup) {
divElement.innerText = this.options.text;
} else {
divElement.innerHTML = this.options.text;
}
if (this.options.avatar !== "") {
var avatarElement = document.createElement("img");
avatarElement.src = this.options.avatar;
avatarElement.className = "toastify-avatar";
if (this.options.position == "left" || this.options.positionLeft === true) {
// Adding close icon on the left of content
divElement.appendChild(avatarElement);
} else {
// Adding close icon on the right of content
divElement.insertAdjacentElement("afterbegin", avatarElement);
}
}
}
// Adding a close icon to the toast
if (this.options.close === true) {
// Create a span for close element
var closeElement = document.createElement("button");
closeElement.type = "button";
closeElement.setAttribute("aria-label", "Close");
closeElement.className = "toast-close";
closeElement.innerHTML = "✖";
// Triggering the removal of toast from DOM on close click
closeElement.addEventListener(
"click",
function(event) {
event.stopPropagation();
this.removeElement(this.toastElement);
window.clearTimeout(this.toastElement.timeOutValue);
}.bind(this)
);
//Calculating screen width
var width = window.innerWidth > 0 ? window.innerWidth : screen.width;
// Adding the close icon to the toast element
// Display on the right if screen width is less than or equal to 360px
if ((this.options.position == "left" || this.options.positionLeft === true) && width > 360) {
// Adding close icon on the left of content
divElement.insertAdjacentElement("afterbegin", closeElement);
} else {
// Adding close icon on the right of content
divElement.appendChild(closeElement);
}
}
// Clear timeout while toast is focused
if (this.options.stopOnFocus && this.options.duration > 0) {
var self = this;
// stop countdown
divElement.addEventListener(
"mouseover",
function(event) {
window.clearTimeout(divElement.timeOutValue);
}
)
// add back the timeout
divElement.addEventListener(
"mouseleave",
function() {
divElement.timeOutValue = window.setTimeout(
function() {
// Remove the toast from DOM
self.removeElement(divElement);
},
self.options.duration
)
}
)
}
// Adding an on-click destination path
if (typeof this.options.destination !== "undefined") {
divElement.addEventListener(
"click",
function(event) {
event.stopPropagation();
if (this.options.newWindow === true) {
window.open(this.options.destination, "_blank");
} else {
window.location = this.options.destination;
}
}.bind(this)
);
}
if (typeof this.options.onClick === "function" && typeof this.options.destination === "undefined") {
divElement.addEventListener(
"click",
function(event) {
event.stopPropagation();
this.options.onClick();
}.bind(this)
);
}
// Adding offset
if(typeof this.options.offset === "object") {
var x = getAxisOffsetAValue("x", this.options);
var y = getAxisOffsetAValue("y", this.options);
var xOffset = this.options.position == "left" ? x : "-" + x;
var yOffset = this.options.gravity == "toastify-top" ? y : "-" + y;
divElement.style.transform = "translate(" + xOffset + "," + yOffset + ")";
}
// Returning the generated element
return divElement;
},
// Displaying the toast
showToast: function() {
// Creating the DOM object for the toast
this.toastElement = this.buildToast();
// Getting the root element to with the toast needs to be added
var rootElement;
if (typeof this.options.selector === "string") {
rootElement = document.getElementById(this.options.selector);
} else if (this.options.selector instanceof HTMLElement || (typeof ShadowRoot !== 'undefined' && this.options.selector instanceof ShadowRoot)) {
rootElement = this.options.selector;
} else {
rootElement = document.body;
}
// Validating if root element is present in DOM
if (!rootElement) {
throw "Root element is not defined";
}
// Adding the DOM element
var elementToInsert = Toastify.defaults.oldestFirst ? rootElement.firstChild : rootElement.lastChild;
rootElement.insertBefore(this.toastElement, elementToInsert);
// Repositioning the toasts in case multiple toasts are present
Toastify.reposition();
if (this.options.duration > 0) {
this.toastElement.timeOutValue = window.setTimeout(
function() {
// Remove the toast from DOM
this.removeElement(this.toastElement);
}.bind(this),
this.options.duration
); // Binding `this` for function invocation
}
// Supporting function chaining
return this;
},
hideToast: function() {
if (this.toastElement.timeOutValue) {
clearTimeout(this.toastElement.timeOutValue);
}
this.removeElement(this.toastElement);
},
// Removing the element from the DOM
removeElement: function(toastElement) {
// Hiding the element
// toastElement.classList.remove("on");
toastElement.className = toastElement.className.replace(" on", "");
// Removing the element from DOM after transition end
window.setTimeout(
function() {
// remove options node if any
if (this.options.node && this.options.node.parentNode) {
this.options.node.parentNode.removeChild(this.options.node);
}
// Remove the element from the DOM, only when the parent node was not removed before.
if (toastElement.parentNode) {
toastElement.parentNode.removeChild(toastElement);
}
// Calling the callback function
this.options.callback.call(toastElement);
// Repositioning the toasts again
Toastify.reposition();
}.bind(this),
400
); // Binding `this` for function invocation
},
};
// Positioning the toasts on the DOM
Toastify.reposition = function() {
// Top margins with gravity
var topLeftOffsetSize = {
top: 15,
bottom: 15,
};
var topRightOffsetSize = {
top: 15,
bottom: 15,
};
var offsetSize = {
top: 15,
bottom: 15,
};
// Get all toast messages on the DOM
var allToasts = document.getElementsByClassName("toastify");
var classUsed;
// Modifying the position of each toast element
for (var i = 0; i < allToasts.length; i++) {
// Getting the applied gravity
if (containsClass(allToasts[i], "toastify-top") === true) {
classUsed = "toastify-top";
} else {
classUsed = "toastify-bottom";
}
var height = allToasts[i].offsetHeight;
classUsed = classUsed.substr(9, classUsed.length-1)
// Spacing between toasts
var offset = 15;
var width = window.innerWidth > 0 ? window.innerWidth : screen.width;
// Show toast in center if screen with less than or equal to 360px
if (width <= 360) {
// Setting the position
allToasts[i].style[classUsed] = offsetSize[classUsed] + "px";
offsetSize[classUsed] += height + offset;
} else {
if (containsClass(allToasts[i], "toastify-left") === true) {
// Setting the position
allToasts[i].style[classUsed] = topLeftOffsetSize[classUsed] + "px";
topLeftOffsetSize[classUsed] += height + offset;
} else {
// Setting the position
allToasts[i].style[classUsed] = topRightOffsetSize[classUsed] + "px";
topRightOffsetSize[classUsed] += height + offset;
}
}
}
// Supporting function chaining
return this;
};
// Helper function to get offset.
function getAxisOffsetAValue(axis, options) {
if(options.offset[axis]) {
if(isNaN(options.offset[axis])) {
return options.offset[axis];
}
else {
return options.offset[axis] + 'px';
}
}
return '0px';
}
function containsClass(elem, yourClass) {
if (!elem || typeof yourClass !== "string") {
return false;
} else if (
elem.className &&
elem.className
.trim()
.split(/\s+/gi)
.indexOf(yourClass) > -1
) {
return true;
} else {
return false;
}
}
// Setting up the prototype for the init object
Toastify.lib.init.prototype = Toastify.lib;
// Returning the Toastify function to be assigned to the window object/module
return Toastify;
});
function createRightMenu(){
var _template=`
<ul>
<li><a href="https://blog.tryrun.top/"><i class="fa fa-home fa-fw"></i><span>首页</span></a></li>
<li><a href="javascript:void(0);" onclick="getSelect();"><i class="fa fa-copy fa-fw"></i><span>复制</span></a></li>
<li ><a href="javascript:void(0);" onclick="baiduSearch();"><i class="fa fa-search fa-fw"></i><span>百度</span></a></li>
<li ><a href="javascript:void(0);" onclick="blogSearch();"><i class="fa fa-search fa-fw"></i><span>站内</span></a></li>
<li><a href="javascript:history.go(1);"><i class="fa fa-arrow-right fa-fw"></i><span>前进</span></a></li>
<li><a href="javascript:history.go(-1);"><i class="fa fa-arrow-left fa-fw"></i><span>后退</span></a></li>
<li style="border-bottom:1px solid gray"><a href="javascript:window.location.reload();"><i class="fa fa-refresh fa-fw"></i><span>重载网页</span></a></li>
<li><a href="https://blog.tryrun.top/links"><i class="fa fa-meh-o fa-fw"></i><span>和我当邻居</span></a></li>
<li><a href="https://blog.tryrun.top/leaving"><i class="fa fa-pencil-square-o fa-fw"></i><span>给我留言吧</span></a></li>
</ul>
`
let _blogBody= document.getElementsByTagName('body')[0];
let _usercmDom = document.createElement('div');
_usercmDom.className='usercm';
_usercmDom.style.left='199px';
_usercmDom.style.top='5px';
_usercmDom.style.display='none';
_usercmDom.innerHTML = _template;
_blogBody.appendChild(_usercmDom);
}
createRightMenu();
(function(a) {
a.extend({
mouseMoveShow: function(b) {
var d = 0,
c = 0,
h = 0,
k = 0,
e = 0,
f = 0;
a(window).mousemove(function(g) {
d = a(window).width();
c = a(window).height();
h = g.clientX;
k = g.clientY;
e = g.pageX;
f = g.pageY;
h + a(b).width() >= d && (e = e - a(b).width() - 5);
k + a(b).height() >= c && (f = f - a(b).height() - 5);
a("html").on({
contextmenu: function(c) {
3 == c.which && a(b).css({
left: e,
top: f
}).show()
},
click: function() {
a(b).hide()
}
})
})
},
disabledContextMenu: function() {
window.oncontextmenu = function() {
return !1
}
}
})
})(jQuery);
function showToast(text){
Toastify({
text: text,
className: "info",
offset:{y:'50px'},
position: "center",
style: {
background: "linear-gradient(to right, #6394FD, #4E73F6)",
}
}).showToast();
}
function getSelect() {
"" == (window.getSelection ? window.getSelection() : document.selection.createRange().text) ? showToast("啊噢...你没还没选择文字呢!") : document.execCommand("Copy")
};
function baiduSearch() {
var a = window.getSelection ? window.getSelection() : document.selection.createRange().text;
"" == a ? showToast("啊噢...你没还没选择文字呢!") : window.open("https://www.baidu.com/s?wd=" + a)
};
function blogSearch() {
var _port = location.port?':'+location.port:''
var _href = location.protocol+'//'+location.hostname+_port+'/search?keyword='
var a = window.getSelection ? window.getSelection() : document.selection.createRange().text;
"" == a ? showToast("啊噢...你没还没选择文字呢!") : window.open(_href + a)
};
$(function() {
for (var a = navigator.userAgent, b = "Android;iPhone;SymbianOS;Windows Phone;iPad;iPod".split(";"), d = !0, c = 0; c < b.length; c++) if (0 < a.indexOf(b[c])) {
d = !1;
break
}
d && ($.mouseMoveShow(".usercm"), $.disabledContextMenu())
});
来源作者:小莫唐尼
来源网站:https://b.925i.cn/
侧边栏添加舔狗日记
1css(引入)
.joe_aside__item.flatterer {background: var(--background);}.joe_aside__item.flatterer .content {border-style: solid;border-color: var(--classC);padding: 15px;line-height: 1.8;background: var(--classD);color: var(--routine);margin-bottom: 15px;}.joe_aside__item.flatterer .content mark {background-color: transparent;background-image: linear-gradient(#ffe21d, #ffe21d);background-position: 0 85%;background-size: 100% 25%;background-repeat: no-repeat;color: var(--routine);}.joe_aside__item.flatterer .content.type1 {border-bottom-left-radius: 15px 255px;border-bottom-right-radius: 225px 15px;border-top-left-radius: 255px 15px;border-top-right-radius: 15px 225px;}.joe_aside__item.flatterer .content.type2 {border-bottom-left-radius: 185px 25px;border-bottom-right-radius: 20px 205px;border-top-left-radius: 125px 25px;border-top-right-radius: 10px 205px;}.joe_aside__item.flatterer .content.type3 {border-bottom-left-radius: 225px 15px;border-bottom-right-radius: 15px 255px;border-top-left-radius: 15px 225px;border-top-right-radius: 255px 15px;}.joe_aside__item.flatterer .content.type4 {border-bottom-left-radius: 25px 115px;border-bottom-right-radius: 155px 25px;border-top-left-radius: 15px 225px;border-top-right-radius: 25px 150px;}.joe_aside__item.flatterer .content.type5 {border-bottom-left-radius: 20px 115px;border-bottom-right-radius: 115px 20px;border-top-left-radius: 250px 15px;border-top-right-radius: 25px 80px;}.joe_aside__item.flatterer .content.type6 {border-bottom-left-radius: 15px 225px;border-bottom-right-radius: 20px 205px;border-top-left-radius: 28px 125px;border-top-right-radius: 100px 30px;}.joe_aside__item.flatterer .change {display: flex;align-items: center;justify-content: center;width: 40px;height: 40px;border-radius: 50%;margin: 0 auto;cursor: pointer;border: 2px solid var(--classC);}.joe_aside__item.flatterer .change .icon {fill: var(--routine);}
2js(引入)
(function(){"use strict";const FlattererDefaultList=["你昨天晚上又没回我信息,我却看见你的游戏在线,在我再一次孜孜不倦的骚扰你的情况下,你终于跟我说了一句最长的话“**你他妈是不是有病**”,我又陷入了沉思,这一定有什么含义,我想了很久,你竟然提到了我的妈妈,原来你已经想得那么长远了,想和我结婚见我的父母,我太感动了,真的。那你现在在干嘛,我好想你,我妈妈说她也很喜欢你。","今天我观战了一天你和别人打游戏,**你们玩的很开心**;我给你发了200多条消息,你说没流量就不回;晚上发说说没有人爱你,我连滚带爬评论了句有“我在”,你把我拉黑了,我给你打电话也无人接听。对不起,我不该打扰你,我求求你再给我一次当好友的机会吧!","我爸说再敢网恋就打断我的腿,幸好不是胳膊,这样我还能继续**和你打字聊天**,就算连胳膊也打断了,我的心里也会有你位置。","你说你情侣头像是一个人用的,空间上锁是因为你不喜欢玩空间,情侣空间是和闺蜜开的,找你连麦时你说你在忙工作,每次聊天你都说在忙,你真是一个**上进的好女孩**,你真好,我好喜欢你!","你跟他已经醒了吧?我今天捡垃圾挣了一百多,明天给你打过去。你快点休息吧,我明天叫你起床,给你点外卖买烟,给你点你最喜欢的奶茶。晚上我会继续去摆地摊的,你不用担心我,你床只有那么大睡不下三个。**你要好好照顾好自己,不要让他抢你被子**。我永远爱你!","她三天没回我的消息了,在我孜孜不倦地骚扰下她终于舍得回我“**nmsl**”,我想这一定是有什么含义吧,噢!我恍然大悟原来是**尼美舒利颗粒**,她知道我有关节炎让我吃尼美舒利颗粒,她还是关心我的,但是又不想显现的那么热情。天啊!她好高冷,我好像更喜欢她了!","你想我了吧?可以回我消息了吗?我买了万通筋骨贴,你**运动一个晚上腰很疼**吧?今晚早点回家,我炖了排骨汤,我永远在家等你。","昨晚你和朋友打了一晚上游戏,你破天荒的给我看了战绩,虽然我看不懂但是我相信你一定是最厉害的、最棒的。我给你发了好多消息夸你,告诉你我多崇拜你,你回了我一句“**啥B**”,我翻来覆去思考这是什么意思,Sha[傻],噢你是说我傻,那B就是Baby的意思了吧,原来你是在叫我**傻宝**,这么宠溺的语气,我竟一时不敢相信,其实你也是喜欢我的对吧。","今天我还是照常给你发消息,汇报日常工作,你终于回了我四个字:“**嗯嗯,好的。**”。你开始愿意敷衍我了,我太感动了,受宠若惊。我愿意天天给你发消息,就算你天天骂我,我也不觉得烦。","你昨天晚上又没回我的消息,在我孜孜不倦的骚扰下,你终于舍得回我了,你说“**滚**”,这其中一定有什么含义,我想了很久,滚是三点水,这代表你对我的思念也如**滚滚流水**一样汹涌,我感动哭了,不知道你现在在干嘛,我很想你。","听说你想要一套化妆品,我算了算,明天我去工地上**搬一天砖**,就可以拿到200块钱,再加上我上个月攒下来的零花钱,刚好给你买一套迪奥。","今天表白被拒绝了,她对我说能不能脱下裤子**撒泡尿照照自己**。当我脱下裤子,她咽了口水,说我们可以试一下。","刚从派出所出来,原因前几天14号情人节,我想送你礼物,我去偷东西的时候被抓了。我本来想反抗,警察说了一句老实点别动,我立刻就放弃了反抗,因为我记得你说过,你喜欢**老实人**。","疫情不能出门,现在是早上八点,你肯定饿了吧。我早起做好了早餐来到你小区,保安大哥不让进。我给你打了三个电话你终于接了“**有病啊,我还睡觉呢,你小区门口等着吧**”。啊,我高兴坏了!你终于愿意吃我做的早餐了,还让我等你,啊!啊!啊!好幸福噢!","我存了两个月钱,给你买了一双**北卡蓝**,你对我说一句“谢谢”,我好开心。这是你第一次对我说两个字,以前你都只对我说滚。今天晚上逛**闲鱼**,看到了你把我送你的北卡蓝发布上去了。我想你一定是在考验我,再次送给你,给你一个惊喜,我爱你。","昨天**你领完红包就把我删了**,我陷入久久地沉思。我想这其中一定有什么含义,原来你是在欲擒故纵,嫌我不够爱你。无理取闹的你变得更加可爱了,我会坚守我对你的爱的。你放心好啦!今天发工资了,发了1850,给你微信转了520,支付宝1314,还剩下16。给你发了很多消息你没回。剩下16块我在小卖部买了你爱吃的老坛酸菜牛肉面,给你寄过去了。希望你保护好食欲,我去上班了爱你~~","在保安亭内看完了最新一集的梨泰院,曾经多么倔强的朴世路因为伊瑞给张大熙跪下了,亭外的树也许感受到了**我的悲伤**,枯了。我连树都保护不了,怎么保护你,或许保安才是真的需要被保护的吧。我难受,我想你。over","难以言喻的下午。说不想你是假的,说爱你是真的。昨天他们骂**我是你的舔狗**,我不相信,因为我知道你肯定也是爱我的,你一定是在考验我对你的感情,只要我坚持下去你一定会被我的真诚所打动,加油!不过我要批评你一下,昨晚你说**去酒店跟人斗地主**,我寻思两个人也玩不了呀。算了,不想了,毕竟打牌是赌博行为,不太好。","明天就周六了我知道你不上班,但是我怕你睡懒觉不吃早饭饿坏自己。我早晨4点去菜市场买了新鲜活鸡**给你炖鸡汤**,阿姨给我用箱子装了起来,我骑上我280买的电动车哼着小调回家,心想你一定会被我感动的,箱子半路开了,鸡跑了,拐到了一个胡同里,凌晨4点的胡同还有穿超短裙和大叔聊天的美女,不禁感叹这个世界变了,她问我找什么,…………。对不起,我爱你","12点队长过来准时交班,出去的车辆按喇叭我也没听到,只因我在监控中看到了穿睡衣出来倒垃圾的你,**望你望的入神**不由的傻笑了起来,队长过来骂我扣了我一天工资。我委屈,想抱你。你送的泡面真好吃。","今天的我排位输了好多把,我将这些事情分享给你,但是你一个字都没有讲,我在想你是不是在忙?我头痛欲裂,终于在我给你发了几十条消息之后,你回了我一个“**脑子是不是有病?**”,原来你还是关心我的,看到这句话,我的脑子一下就不疼了,今天也是爱你的一天。","我存了半年的工资,给你买了一只LV,你对我说了一句“**你真好**”,我好开心,这是你第一次这么认可我,以前你都只对我说滚。今天晚上逛闲鱼,看到你把我送你的LV发布上去了。我想,你一定是在考验我,于是我用借呗里的钱把它买了下来,再次送给你,给你一个惊喜,我爱你。","其实我每月工资6000,但我只给你转2000,你以为我给你了全部。才不是,我一共舔了3个啦,**我要舔的雨露均沾**,才不会把你当成唯一。","昨天你把我拉黑了,我看着红色感叹号陷入了久久的沉思,我想这其中一定有什么含义?红色红色?我明白了!红色代表热情,你对我很热情,你想和我结婚,我愿意。","今天你问我借了两千块钱,说要做个手术,你果然还是爱我的,**不是我的孩子,你不要**。 ","中午你无故扇了我一巴掌,我握着你的手说“手怎么这么凉,都怪我没有照顾好你,一定要更加对你好”。","我给你打了几通电话,你终于接了。听到了**你发出啊啊啊啊的声音**,你说你肚子痛,我想你一定是很难受吧。电话还有个男的对你说“来换个姿势”,一定是**在做理疗**了。期待你早日康复,我好担心。","昨天晚上好冷,本来以为街上没人,结果刚刚**偷电动车**的时候被抓了,本来想反抗,但警察说了一句老实点别动,我立刻就放弃了抵抗,因为我记得你说过,你喜欢**老实人**。","找你连麦时你说你在忙工作,每次聊天你都说在忙,你真是一个**上进的好女孩**,你真好,发现我越来越喜欢这样优秀的你。","你从来没说过爱我,聊天记录搜索了一下“爱”,唯一的一条是:**你好像乡村爱情里的刘能啊**。","今天好开心啊,和你一起在峡谷嬉戏,打完一波团战之后看到你在打大龙,残血的我跳过去直接被龙爪拍死,但这一刻我觉得好浪漫,**死在你的脚旁边,这是我离你最近的一次**。","哥们,求你和她说句话吧,这样她就不会那么难过了。","今天你把我的微信拉黑了,这下我终于解放了!以前我总担心太多消息会打扰你,现在我终于不用顾忌,不管我怎么给你发消息,都不会让你不开心了。等我**攒够5201314条**我就拿给你看,你一定会震惊得说不出话然后哭着说会爱我一辈子。哈哈。","昨天你把我删了,我陷入了久久的沉思 。我想这其中一定有什么含义,你应该是欲擒故纵吧,嫌我不够爱你。突然觉得**无理取闹的你变得更加可爱**了,我会坚守我对你的爱的 你放心好啦!这么一想,突然对我俩的未来更有期望了呢。","今天上班不是太忙,百无聊赖,又翻出了你的相片,看了又看。今天是我认识你的第302天,也是我爱你的第302天,可是这些你并不知道,也许**你知道了,也不会在意**吧。 此刻的我好想你! ","今天你跟我说我很丑,让我不要骚扰你了。我听了很高兴,小说里的主角都像你这样,最开始表现的很厌恶,但最后**总会被我的真心打动**。你现在有多讨厌我,以后就会有多爱我。嘻嘻。","我坐在窗边给你发了99条消息,你终于肯回我了,你说“**发你妈啊**”,我一下子就哭了。原来努力真的有用,你已经开始考虑想见我的妈妈了,你也是挺喜欢我的。","刚才我找你说话,你回了一个滚,我陷入了沉思,你还是如此的关心我,知道我腿受伤了,让我这样走,好感动!看来你还是爱我的!","今天下雨了,我去你公司接你下班。看见我你不耐烦的说“**烦不烦啊,不要再找我了**”,一头冲进雨里就跑开了。我心里真高兴啊,你宁愿自己淋雨,都不愿让我也淋湿一点,你果然还是爱我的。","晚上和你聊天,10点钟不到,你就说“**困了,去睡觉了**”。现在凌晨1点钟,看到你给他的朋友圈点赞评论,约他明天去吃火锅,一定是你微信被盗了吧。","今天我主动给你发了游戏邀请,邀请你和我单挑安琪拉,虽然我安琪拉很菜,可是为了和你打游戏,我还是毅然决然给你发了邀请。你说你不接受,你在打其他游戏。联想到我自己很菜,我突然明白,原来你还是在乎我的,只是不想一遍遍连招一套的在泉水送我走。我再一次感动哭了,因此,我好像更喜欢你了,你可真是一个宝藏男孩!","你的头像是一个女孩子左手边牵着一条秋田犬,犬=狗,而**我是一条舔狗**。是不是代表你的小手在牵着我呢?","今天发工资了,我一个月工资3000,你猜我会给你多少,是不是觉得我会给你2500,自己留500吃饭?你想多了,我3000都给你,因为厂里包吃包住。","昨天就为你充了710点卷,虽然知道你不会玩不知去向,但你说好看,你刚才说小号想要还想要一个,爱你的我还是满心欢喜的把剩下的100元伙食费又给你充了710,然后看到你小号并没有买,而是你送给了你的一个弟弟,你对弟弟真好,好有爱心,我感觉对你陷得很深了。","今天我给你发消息,你回复我“**nmsl**”,我想了半天才知道你是在夸我,原来是**你美死了**,你嘴真甜,我爱你。","你说你想买口红,今天我去了叔叔的口罩厂做了一天的打包。拿到了两百块钱,加上我这几天**省下的钱刚好能给你买一根小金条**。即没有给我自己剩下一分钱,但你不用担心,因为厂里包吃包住。对了打包的时候,满脑子都是你,想着你哪天突然就接受我的橄榄枝了呢。而且今天我很棒呢,主管表扬我很能干,其实也有你的功劳啦,是你给了我无穷的力量。今天我比昨天多想你一点,比明天少想你一点。","在我一如既往的每天跟她问早安的时候,她今天终于回我了。我激动地问她我是不是今天第一个跟她说话的人,她说不是,是**她男朋友把她叫起来退房**的。","听说你朋友说今天出门了,我打扮成精神小伙来找你,没想到你竟然对我说“**给我爬,别过来**”我当场就哭了,原来真心真的会感动人,你一定是知道,穿豆豆鞋走路脚会很累,让我爬是因为这样不会累着脚,其实你是喜欢我的吧","今天把你的备注改成了「**对方正在输入...**」,这样我就知道你不是不想回我,刚又给你发了消息,看到你在思考怎么回我,我就知道你和我一样,心里有我。","今天在楼上窗户上看见你和他在公园里接吻,我看见哭了出来,并打电话给你,想问问你为什么?但你说怎么了,声音是那么好听。于是我说“**以后你和他接吻的时候,能不能用我送给你的口红啊?**”","我退了无关紧要的群,唯独这个群我没有退,因为这里有一个对我来说很特别的女孩子,我们不是好友,**我每天只能通过群名片看看她**,虽然一张照片也看不到,我也知足了,我不敢说她的名字,但我知道她是群里面最美的女孩子,她说我们这样会距离产生美~ 我想想发现她说的挺对的,我心里很开心。","今天早上我告诉你我想你了,你没理我。今天中午我给你打电话,你不接,打第二个你就关机。晚上我在你公司楼下等你,你对我说的第一句话就是滚“**滚,别烦我,别浪费时间了**”,我真的好感动,你居然为我考虑了,怕我浪费时间。呜呜呜,这是我爱你的第74天。","我坐在窗边给你发了99条消息,你终于肯回我了你说“**发你妈啊**”,我一下子就哭了,原来努力真的有用,你已经开始考虑想见我的妈妈了,你其实也是挺喜欢我的。","你一个小时没回我的消息,在我孜孜不倦地骚扰下你终于舍得回我了“**在做爱**”,这其中一定有什么含义,我想了很久,“在做爱”这简简单单的三个字肯定是三句话,分别是**我在忙、做你女朋友、我爱你**,想到这里我不禁流下了眼泪,我这么长时间的喜欢没有白费,不知道你现在忙干嘛,但我很想你。","最近我暗恋的女生每天都和不同的男生约会,我想总有一天会轮到我,我问她什么时候能见见我?她说**下辈子吧**。她真好,下辈子还要和我在一起。","你好像从来没有对我说过晚安,我在我们的聊天记录里搜索了关键字:“晚安”,你说过一次:**我早晚安排人弄死你**。",];const Utils={getRandom:function(min,max){min=Math.ceil(min);max=Math.floor(max);return Math.floor(Math.random()*(max-min+1))+min},};const EvanFlatterer=function(options){if(!(this instanceof EvanFlatterer)){return new EvanFlatterer(options)}this.options=Object.assign({},{list:FlattererDefaultList,auto:true,api:null,format:null,interval:1500,},options);this.init()};EvanFlatterer.prototype={dom:{container:null,},fnGetDom(){this.dom.container=$(".joe_aside__item.flatterer")},timer:null,fnHandle(){const _list=this.options.list;const _random=(e,t)=>((e=Math.ceil(e)),(t=Math.floor(t)),Math.floor(Math.random()*(t-e+1))+e);this.dom.container.find(".content").html(_list[_random(0,_list.length-1)].replace(/\*\*(.*?)\*\*/g,"<mark>$1</mark>"));this.dom.container.find(".content").attr("class","content type"+_random(1,6))},fnAuto(){const _this=this;clearTimeout(_this.timer);setTimeout(function(){_this.fnAuto()},_this.options.interval||2000)},fnClick(){const _this=this;_this.dom.container.find(".change").off("click").click(function(){_this.fnHandle()})},fnGetData(fn){const _this=this;$.get(this.options.api,{},function(res){if(typeof _this.options.format=="function"){_this.options.list=_this.options.format(res)}else{_this.options.list=res}fn()})},init(){const _this=this;window.onload=function(){_this.fnGetDom();if(!document.querySelector(".joe_aside__item.flatterer"))return;const _load=function(){if(_this.options.auto){_this.fnAuto()}_this.fnClick();_this.fnHandle()};if(_this.options.api){_this.fnGetData(_load)}else{_load()}}},};window.EvanFlatterer=EvanFlatterer})(); new EvanFlatterer( )
3ftl(自定义)
<#-- 舔狗日记 -->
<section class="joe_aside__item flatterer">
<div class="joe_aside__item-title">
<svg class="icon" style="fill:var(--theme)" viewbox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg"
width="18" height="18">
<path
d="M774.144 734.72c-35.328 60.416-99.84 93.696-176.64 74.752-1.024 29.696-12.288 54.784-36.352 72.704-15.36 11.264-33.28 16.896-51.712 15.872-47.616-1.536-75.264-30.72-85.504-88.064-74.752 15.36-132.608-8.704-173.056-72.192-17.92 3.584-35.84 9.216-53.76 10.752-63.488 5.12-107.52-28.16-122.88-90.112-12.288-49.152-7.68-98.816 5.12-146.944 34.304-130.048 102.4-238.08 213.504-315.392 146.944-102.912 333.312-93.184 471.552 24.576C865.792 307.2 928.768 416.768 952.832 547.84c6.144 34.816 6.656 70.144-1.024 104.96-20.48 94.72-100.864 110.592-166.4 86.016-3.584-.512-7.168-2.048-11.264-4.096zm-235.008-46.592c11.776 41.984 46.592 71.68 90.112 76.288 42.496 4.096 82.432-17.92 102.912-55.296 3.072-6.144 3.072-10.752.512-17.92-6.144-16.384-14.336-33.792-14.848-51.2-2.048-86.016-2.048-172.032-2.56-258.048 0-15.872 8.704-24.576 23.04-24.064 13.824.512 20.992 8.704 20.992 24.576l1.536 240.64c0 6.144 0 12.288.512 18.432 1.536 15.872 7.168 30.208 19.456 40.96 40.448 36.864 104.96 19.456 120.32-32.768 8.704-30.208 8.704-60.928 3.584-91.136-20.48-117.248-75.776-216.064-164.352-295.424-119.296-106.496-277.504-121.344-408.064-36.352-117.76 76.8-184.832 188.416-211.968 324.608-6.656 33.792-7.168 68.608 4.096 101.888 8.192 23.552 22.528 40.96 48.128 46.08 54.784 10.752 92.16-19.456 92.16-75.264V614.4c0-76.8 0-153.088.512-229.888 0-17.92 8.192-27.136 23.04-26.624 14.336 0 21.504 9.216 22.016 26.624 0 12.8-.512 25.6-.512 37.888 0 69.12-.512 138.24-.512 207.36 0 22.528-5.12 43.52-16.384 63.488-2.048 4.096-2.56 11.264-.512 15.36 29.696 59.904 111.104 75.264 160.768 30.72 16.384-14.848 28.16-32.256 32.256-50.688-14.336-13.312-26.624-25.088-39.424-36.864-15.36-14.336-17.92-31.744-12.288-50.688 5.632-19.968 19.456-33.792 39.424-35.84 25.6-2.56 51.712-2.048 77.312 0 19.456 1.536 32.256 15.36 38.4 33.792 5.632 16.896 5.632 33.792-7.168 47.616-11.776 14.336-26.624 26.624-42.496 41.472zm-50.176 85.504c-18.944 13.312-24.064 30.208-16.384 51.712 6.144 17.92 23.552 29.184 41.472 27.648 18.944-1.536 33.28-14.336 37.376-33.28 5.632-26.112 2.56-35.328-15.872-45.056-1.024 9.216-.512 18.944-2.56 27.648-2.56 10.24-11.264 14.848-21.504 14.848-15.36.512-19.968-8.192-22.528-43.52z">
</path>
<path
d="M391.168 496.64c-20.992 0-37.376-16.896-36.864-37.376.512-20.48 17.92-36.864 38.4-36.352 19.968.512 35.84 16.896 35.84 37.376.512 20.48-15.872 36.352-37.376 36.352zm282.624-31.744c0 20.48-15.872 36.864-36.352 36.864-20.992 0-37.888-16.384-37.376-37.376.512-20.48 16.384-36.864 36.864-36.864 20.992-.512 36.864 15.872 36.864 37.376z">
</path>
</svg>
<span class="text">舔狗日记</span>
<span class="title-right_icon"></span>
</div>
<div class="joe_aside__item-contain">
<div class="content"></div>
<div class="change">
<svg class="icon" viewbox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" width="20" height="20">
<path
d="M1000.61 625.5c-24.6-33.4-55.3-155.5-69.3-231.5-3.8-20.6-18.7-36.9-38.8-42.6-4-1.1-8.1-1.8-12.2-1.9-35.3-59-74.5-66.7-100.5-71.8-18.5-3.6-18.8-4.5-21.5-11.1-13.1-32.1-32.3-54-57.1-65.1-20.8-9.4-41.4-9.2-53.7-9.2-.9 0-2-.2-3.2-.5-.8-.2-1.6-.3-2.4-.4-39.3-56.7-70.7-68.1-108.5-68.1h-.2c-38.1 0-63 21-81.2 36.4l-1.6 1.4c-21.3 18-24.9 18.8-33.7 15.2-45.3-18.6-84.6-8.1-116.8 31-13.6 16.6-20.7 29-25.4 37.1l-.1.2c-5.1-.7-10.3-1.6-15.4-2.5-27.5-4.9-51.8 6.7-72.4 34.5-16.7 22.5-27.7 51.7-34.2 73.1-1.7-.2-3.3-.3-5-.3-27.1 0-50.4 20.3-54 47.2-5.5 39.8-15.3 87.4-26.2 127.3-13.4 48.9-27.5 83.2-40.8 99.3-27.6 33.4-28.7 66.5-24.7 88.4 6.7 37.3 34.9 73.7 75.5 97.3 55.3 32.2 158.1 92 447 92 268 0 356.3-52.2 414.8-86.8l2.2-1.3c2.3-1.4 4.5-2.7 6.8-4 18.6-10.8 63-41.6 73.8-93.3 4.4-21.8 4.5-55-21.2-90zM919.01 759c-3 1.8-6.1 3.6-9.3 5.5-27.1 16-60.7 35.9-118.5 51.5-67.9 18.3-155.2 27.2-266.9 27.2-273.4 0-367.5-54.8-418.1-84.2-20.2-11.8-43.4-33.1-47.8-57.7-2.6-14.5 1.6-28.5 12.5-41.6 22.3-27 42.5-78.2 60-152.3 10.3-43.7 16.6-82.8 18.8-97.2 28.9 25.2 104.2 42.6 148.1 51 73.8 14.1 161.6 22.5 234.9 22.5 68.4 0 140.7-7.1 203.7-20.1 62.7-12.9 110.4-30.4 134.6-49.3 1.9-.2 3.7-.6 5.5-1.2 7.7 39.5 39.9 194.9 77.8 246.5 10.6 14.4 14.3 29.2 11.2 44.2-4.3 20.1-21.7 40.8-46.5 55.2zm-271.3-509.5c23.2-.1 41.5-.2 57.3 38.6 14.8 36.3 44.2 42 63.7 45.9 18.9 3.7 38.5 7.6 59.3 40.1-15.5 9-49.3 21.8-101.4 32.7v-1c-1.7-55.7-39.4-82-61.3-88.7-7.3-2.3-15.1-1.5-21.9 2.1-6.8 3.6-11.8 9.6-14.1 17-4.7 15.2 3.9 31.3 19 35.9.8.3 19.9 6.8 20.7 35.5.1 3 .7 6 1.8 9-45.5 6.3-91.7 9.6-137.6 9.6h-.8c-68 0-150.1-7.7-219.4-20.6-60.1-11.2-93.1-22.8-108.5-29.4 11.5-43.5 32-79.4 44.4-77.4 38.1 6.7 55.8 8.2 75.1-25.2 4-6.9 9.5-16.4 20.3-29.6 17.9-21.8 31.6-21.8 50.4-14.1 42.5 17.4 70.8-6.5 91.5-24l3.7-3.1c14-11.8 26.1-22.1 43.3-22.1 18.3 0 32.8 0 65.4 49.3 0 .1.1.2.1.3.2.5.4 1 .7 1.5 13 17.6 32.6 17.7 48.3 17.7z">
</path>
<path
d="M197.61 503.7c-15.7-2.2-30.3 8.9-32.4 24.6-3.6 25.7-10.5 55.9-18.6 80.8-9.8 30.3-20.5 50.7-30.8 59.1-6 4.8-9.9 11.6-10.8 19.2-.9 7.6 1.2 15.2 6 21.2s11.6 9.9 19.2 10.8c1.2.1 2.3.2 3.5.2 6.4 0 12.6-2.1 17.7-6.2.2-.2.4-.3.6-.5 21.2-17.1 39.2-50.4 53.4-98.8 11-37.4 16-71.6 16.9-78.1 2-15.6-9-30.2-24.7-32.3zm234.9-238.6c-6.6-4-14.3-5.2-21.8-3.4l-.4.1c-55.8 13.8-74.3 65.3-76.5 93.6-.6 7.7 1.9 15.1 6.9 20.9 5 5.8 12 9.4 19.6 9.9h.1c.7.1 1.4.1 2.1.1 14.9 0 27.5-11.5 28.7-26.6 0-.3 3.2-34.7 32.9-42.1 7.5-1.8 13.8-6.4 17.8-13s5.2-14.3 3.4-21.8c-1.6-7.4-6.2-13.7-12.8-17.7zm144.2 34.3c-1.8.4-18 3.3-28.7-18.6-6.9-14.3-24.2-20.2-38.5-13.3-6.9 3.4-12.1 9.2-14.6 16.5-2.5 7.3-2 15.1 1.3 22 22.5 46.2 61.9 51.2 77.8 51.2 5.8 0 11.4-.6 16.2-1.8 7.5-1.8 13.8-6.4 17.8-13s5.2-14.3 3.4-21.8c-1.8-7.5-6.4-13.8-13-17.8s-14.3-5.2-21.7-3.4z">
</path>
</svg>
</div>
</div>
</section>
4修改aside.ftl
<!-- 舔狗日记模板 -->
<#include "../xxx/aside_flatterer.ftl">
注意:模板路径根据自己上传的位置而定
来源作者:小莫唐尼
来源网站:https://b.925i.cn/
增加51统计邀请
邀请链接:https://invite.51.la/1O0lnS13M?target=V6
邀请文字:【51LA网站统计V6】新人注册立得5元现金收益~现在加入“优站计划”,还有额外收益赚取,点击链接了解详情 https://invite.51.la/1O0lnS13M?target=V6
删
取消日志编写跳转链接
- 暴露后台地址
- 假设更换后台地址则该功能无效
- 位置 journals.ftl 14行后删除
<#if settings.enable_journal_add!false>
<a class="joe_journal_add" href="${blog_url+'/admin/index.html#/sheets/journals'}" target="_blank" rel="nofollow"><i class="joe-font joe-icon-edit"></i></a>
</#if>
提高seo(据说)
位置:template/module/link.ftl 第3行后
原:
<link rel="canonical" href="${blog_url!}">
现
<link href="${blog_url!}">
据说能提高seo的收录,咋也不敢不行,试试又何妨
改
评论头像源
http://api.btstu.cn/sjtx/api.php?lx=c1&format=images
加入又拍云联盟
位置为template/common/footer.ftl 46行后加入
</a>提供云服务
<a href="https://www.upyun.com/?utm_source=lianmeng&utm_medium=referral"noopener noreferrer nofollow">
<img class="upyun" src="youpaiyun.svg(又拍云logo)" onerror="Joe.errorImg(this)" alt="CDN服务商"/>
</a>提供CDN加速服务
修改文章页面上一篇下一篇可以显示文章标题功能
post.ftl 第111行
<ul class="joe_post__pagination">
<#if prevPost??>
<li class="joe_post__pagination-item prev"><a href="${prevPost.fullPath!}" title="${prevPost.title!}">上一篇</a></li>
</#if>
<#if nextPost??>
<li class="joe_post__pagination-item next"><a href="${nextPost.fullPath!}" title="${nextPost.title!}">下一篇</a></li>
</#if>
</ul>
改成
<ul class="joe_post__pagination">
<#if prevPost??>
<li class="joe_post__pagination-item prev"><a href="${prevPost.fullPath!}" title="${prevPost.title!}">上一篇: <span>${prevPost.title!}</span></a></li>
</#if>
<#if nextPost??>
<li class="joe_post__pagination-item next"><a href="${nextPost.fullPath!}" title="${nextPost.title!}">下一篇: <span>${nextPost.title!}</span></a></li>
</#if>
</ul>
文章来源: 沙漠渔溏
文章链接: https://www.sammery.com
修改文章标题能带上个人网站的标题
template-common-header.ftl
第4行
<title>${(type == 'index')?then(blog_title!, title! + '-' + blog_title!)}</title>
改成
<title>${(type == 'index')?then(blog_title!, title + '-' + blog_title!)}</title>
文章来源: 沙漠渔溏
文章链接: https://www.sammery.com
对接萌icp
位置 template/common/footer.ftl
<a href="https://icp.gov.moe/?keyword=20221607" target="_blank">萌ICP备20221607号</a>
更改logo
来源:[u钙网](https://www.uugai.com/)
更改随机图api
改为 :樱花API http://www.dmoe.cc/random.php
网站统计
将百度统计更改为51.la统计
启动参数更改
java -server -Xms256m -Xmx256m -jar
将 Xmx256m 改成 Xmx512m
Xms256m 改成 Xms512m
当然,配置够好可以调整到512m以上(配置高的请无视)
评论更改
因为之前被xxs过,所以设置评论审核后才显示
菜单icon
系统所有主题通用:FontAwesome
头像
https://q1.qlogo.cn/g?b=qq&nk=qq号&s=640
这个方法是官方接口,不知道能用多久,且用且珍惜!!!
相关功能的关闭
由于现在访问速度不佳,一切能关闭的我会关,一切以访问速度为主,花里胡哨的东西会等访问速度提上来在开启
链接跳转
- 文章链接直接在当前页面打开
- 位置:主题设置-主题相关-链接跳转–当前页
- 此位置针对joe2.0 1.0.10版本有效,其他版本自测
主题背景
主题背景启用随机图:https://api.ixiaowai.cn/gqapi/gqapi.php
调整全局内容宽度
位置:主题自定义css
#Joe .joe_container{
max-width: 1360px;
}
文章来源: 公爵书房 | 技术分享
文章链接: https://blog.gjcloak.top
头像呼吸光环和鼠标悬停旋转放大
位置:主题自定义css
.avatar {
border-radius: 50%;
animation: light 4s ease-in-out infinite;
transition: 0.5s;
}
.avatar:hover {
transform: scale(1.15) rotate(720deg);
}
@keyframes light {
0%{box-shadow: 0 0 4px #f00;}
25%{box-shadow: 0 0 16px #0f0;}
50%{box-shadow: 0 0 4px #00f;}
75%{box-shadow: 0 0 16px #0f0;}
100%{box-shadow: 0 0 4px #f00;}
}
文章来源: 公爵书房 | 技术分享
文章链接: https://blog.gjcloak.top
修改当前主题,页脚增加页面加载耗时显示
位置:template/common/footer.ftl
大概在58行后添加
<#if settings.enable_birthday!false>
<div class="site_life">
<i class="joe-font joe-icon-jiasu"></i>已运行 <strong class="joe_run__day">00</strong> 天 <strong class="joe_run__hour">00</strong> 时 <strong class="joe_run__minute">00</strong> 分 <strong class="joe_run__second">00</strong> 秒
</div>
</#if>
<!-- 在该位置添加如下代码 -->
<#if settings.enable_process!false>
<div class="site_life">
<i class="joe-font joe-icon-shijian"></i>页面耗时 <strong class="joe_run_process">10ms</strong>
</div>
</#if>
settings.yaml
大概在536行后添加
enable_process:
name: enable_birthday
label: "展示页面加载时间"
type: switch
data-type: bool
default: false
description: "在页面底部添加页面加载时间,默认关闭以节省性能"
options:
- value: true
label: 是
- value: false
label: 否
source\js\min\joe.common.min.js
现已上传各大网盘,需要的可以自取
直接下载替换即可
showLoadTime: function() {
var consume_time= performance.now();
if (ThemeConfig.show_loaded_time) {
consume_time && console.log("%c页面加载耗时:" + Math.round(consume_time) + " ms", "padding: 6px 8px;color:#fff;background:linear-gradient(270deg, #4edb21, #f15206);border-radius: 3px;")
}
if(ThemeConfig.enable_process){
var p = $(".joe_run_process")
p.html(Math.round(consume_time) + " ms")
}
}
文章来源: 沙漠渔溏
文章链接: https://www.sammery.com
修改当前主题,右侧边栏最新文章显示问题
位置:template/macro/latest.ftl
原代码:
<div class="joe_aside__item-contain">
<@postTag method="latest" top="${settings.newest_page_size!5}">
<#if posts?size gt 0>
<ul class="list">
<#list posts?sort_by("editTime")?reverse as post>
<li class="item">
<a class="link" href="${post.fullPath!}" title="${post.title!}">${post.title!}</a>
<i class="joe-font joe-icon-link"></i>
</li>
</#list>
</ul>
<#else>
<#include "empty.ftl">
<@empty type="newest" showImg="false"/>
</#if>
</@postTag>
</div>
修改后代码:
<div class="joe_aside__item-contain">
<@postTag method="latest" top="${settings.newest_page_size!5}">
<#if posts?size gt 0>
<ul class="list">
<#list posts?sort_by("createTime")?reverse as post>
<li class="item">
<a class="link" href="${post.fullPath!}" title="${post.title!}">${post.title!}</a>
<i class="joe-font joe-icon-link"></i>
</li>
</#list>
</ul>
<#else>
<#include "empty.ftl">
<@empty type="newest" showImg="false"/>
</#if>
</@postTag>
</div>
文章来源: 沙漠渔溏
文章链接: https://www.sammery.com
修改友情链接卡片
1 css
位置:自定义–>自定义css
.evan-friends .sub-text {word-break: break-all;display: -webkit-box;-webkit-line-clamp: 1;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}.evan-friends .evan-f-left {width: 100px;min-width: 100px;display: flex;align-items: center;justify-content: center;transition: all 0.5s ease-in-out;}.evan-friends .evan-f-left .f-avatar {width: 60px;height: 60px;box-sizing: border-box;padding: 3px;border-radius: 50%;overflow: hidden;transition: all 0.5s ease-in-out;}.evan-f-left .f-avatar .avatar {width: 100%;height: 100%;border-radius: 50%;margin: 0;object-fit: cover;}.evan-friends .evan-f-right {flex-grow: 1;display: flex;flex-direction: column;align-items: center;justify-content: center;box-sizing: border-box;}.evan-friends .joe_detail__friends-item .contain {border-radius: 12px;}.evan-friends .joe_detail__friends-item .contain .title::after {display: none;}.evan-friends .title {max-width: 70%;min-width: 70%;display: flex;align-items: center;justify-content: center;font-weight: 700;font-size: 1.3em;color: var(--fcolor);}.evan-friends .title .icon {width: 1em;min-width: 1em;height: 1em;min-height: 1em;fill: currentColor;overflow: hidden;font-size: 20px;margin-left: 3px;}.evan-friends .content {margin-top: 10px !important;font-size: 0.93em;color: var(--fcolor);}.evan-friends .joe_detail__friends-item .contain .content .desc {-webkit-line-clamp: 1;}.evan-friends .contain {display: flex;align-items: center;position: relative;transition: background-color 0.1s ease-in-out, border 0.2s ease-in-out;border: 1px solid transparent;}.evan-friends .contain:hover {transform: none;background-color: var(--fcolor) !important;box-shadow: 0px 0px 20px -5px rgb(158 158 158 / 20%);border-color: var(--fcolor);}.evan-friends .contain::before {content: "";position: absolute;left: 0;top: 0;bottom: 0;right: 0;z-index: -1;background-color: var(--fcolor) !important;transform: scale(0);transition: all 0.5s ease-in-out;transform-origin: right bottom;border-bottom-left-radius: 12px;}.evan-friends .contain:hover::before {}.evan-friends .contain:hover .title, .evan-friends .contain:hover .content {color: #ffffff !important;}.evan-friends .contain:hover .title .icon {display: none;}.evan-friends .contain:hover .evan-f-left {margin-left: -200px;}.evan-friends .contain:hover .evan-f-right {padding-left: 100px;}.evan-friends .contain:hover .f-avatar {transform: rotateZ(-360deg);}@media (max-width: 768px) {.evan-friends .contain {border-color: #ebeef5;}.evan-friends .contain:hover {border-color: var(--fcolor);box-shadow: 0px 0px 20px -5px rgb(158 158 158 / 20%);}}
2.修改模板
1)template-> macro-> links_item.ftl 第四行
<!-- 原代码 -->
<ul class="joe_detail__friends">
<!-- 修改后的代码 -->
<ul class="joe_detail__friends evan-friends">
2)原代码 第七行
<li class="joe_detail__friends-item">
<a class="contain" href="${link.url!}" target="_blank" style="background:${colors[nextRandom % colors?size]}" rel="noopener noreferrer">
<span class="title">${link.name!}</span>
<div class="content">
<div class="desc" title="${link.description!}">${(link.description?? && link.description?trim!='')?then(link.description,'这位博主啥也没说')}</div>
<#assign logo=(link.logo?? && link.logo!='')?then(link.logo,logo_default)>
<img width="40" height="40" class="avatar lazyload" data-src="${logo!}" src="${BASE_RES_URL+'/source/svg/spinner-preloader.svg'}" onerror="Joe.errorImg(this)" alt="${link.name!}">
</div>
</a>
</li>
改后
<li class="joe_detail__friends-item">
<a class="contain" href="${link.url!}" target="_blank" style="--fcolor:${colors[nextRandom % colors?size]}" rel="noopener noreferrer">
<div class="evan-f-left">
<div class="f-avatar">
<#assign logo=(link.logo?? && link.logo!='')?then(link.logo,logo_default)>
<img width="40" height="40" class="avatar lazyload" data-src="${logo!}" src="${BASE_RES_URL+'/source/svg/spinner-preloader.svg'}" onerror="Joe.errorImg(this)" alt="${link.name!}">
</div>
</div>
<div class="evan-f-right">
<span class="title" style="--fcolor:${colors[nextRandom % colors?size]}">
<span class="sub-text"> ${link.name!}</span>
<svg t="1658027717181" class="icon" viewBox="0 0 1024 1024" version="1.1"
xmlns="http://www.w3.org/2000/svg" p-id="25920" width="200" height="200">
<path d="M0 0h1024v1024H0V0z" fill="#202425" opacity=".01" p-id="25921"></path>
<path
d="M989.866667 512c0 263.918933-213.947733 477.866667-477.866667 477.866667S34.133333 775.918933 34.133333 512 248.081067 34.133333 512 34.133333s477.866667 213.947733 477.866667 477.866667z"
fill="#FF7744" p-id="25922"></path>
<path
d="M787.114667 339.285333a51.2 51.2 0 0 1 0 72.362667l-307.2 307.2a51.2 51.2 0 0 1-72.362667 0l-170.666667-170.666667a51.2 51.2 0 0 1 72.362667-72.362666L443.733333 610.235733l271.018667-271.018666a51.2 51.2 0 0 1 72.362667 0z"
fill="#FFFFFF" p-id="25923"></path>
</svg>
</span>
<div class="content">
<div class="desc" title="${link.description!}">${(link.description?? && link.description?trim!='')?then(link.description,'这位博主啥也没说')}</div>
</div>
</div>
</a>
</li>
来源作者:小莫唐尼
来源网站:https://b.925i.cn/
旗下站点
个人主页:https://www.tryrun.top
个人博客:https://blog.tryrun.top -->halo博客
音乐:https://music.tryrun.top
壁纸:https://wallpaper.tryrun.top
加密通话:https://si.tryrun.top -->php部署,已停止
alist: https://pan.tryrun.top -->共享网盘(建设中)
图床:https://tc.tryrun.top -->图床(建设中)
评论区