update to 2.2

This commit is contained in:
2025-08-27 18:44:12 +08:00
parent 7806149558
commit e0c71e325c
30 changed files with 26905 additions and 492 deletions

18
config/js/preheadicon.js Normal file
View File

@@ -0,0 +1,18 @@
$(document).ready(function() {
function updateAvatar() {
let $mail = $('#mail');
let $avatar = $('#preheadicon');
if ($mail.length && $avatar.length) {
let email = $mail.val().trim().toLowerCase();
if (email) {
let hash = md5(email);
$avatar.attr('src', `https://cravatar.cn/avatar/${hash}.png`);
}
}
}
updateAvatar(); // 确保页面加载后执行一次
$('#mail').on('blur', updateAvatar);
});