Feat: 新增评论组件,细化通知组件样式,引入环境变量,替换图标组件

This commit is contained in:
2026-07-30 00:59:09 +08:00
parent d585fc909f
commit b66de3129d
18 changed files with 630 additions and 14 deletions
+27
View File
@@ -0,0 +1,27 @@
// 获取记录的评论用户信息
export const getAuthorInfo = () => {
if (typeof window === "undefined") {
return {
name: "",
email: "",
site: "",
};
}
return {
name: localStorage.getItem("paul-author") || "",
email: localStorage.getItem("paul-email") || "",
site: localStorage.getItem("paul-site") || "",
};
};
// 保存
export const setAuthorInfo = (values: Record<string, string>) => {
if (typeof window === "undefined") {
return;
}
localStorage.setItem("paul-author", values.name);
localStorage.setItem("paul-email", values.email);
localStorage.setItem("paul-site", values.site);
};