社交链接添加gitee

This commit is contained in:
Ewait 2023-01-30 10:53:35 +08:00
parent 4b5aaa8705
commit bd2b1a903d
3 changed files with 17 additions and 0 deletions

1
.env
View File

@ -11,6 +11,7 @@ VITE_DESC_TEXT_OTHER = "哎呀,这都被你发现了( 再点击一次可关
# 社交链接 # 社交链接
VITE_SOCIAL_GITHUB = "imsyy" VITE_SOCIAL_GITHUB = "imsyy"
VITE_SOCIAL_GITEE = "oschina"
VITE_SOCIAL_QQ = "1539250352" VITE_SOCIAL_QQ = "1539250352"
VITE_SOCIAL_EMAIL = "one@imsyy.top" VITE_SOCIAL_EMAIL = "one@imsyy.top"
VITE_SOCIAL_TELEGRAM = "bottom_user" VITE_SOCIAL_TELEGRAM = "bottom_user"

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -13,6 +13,17 @@
<Github /> <Github />
</Icon> </Icon>
</a> </a>
<a
id="gitee"
:href="socialLinks.gitee"
target="_blank"
@mouseenter="changeTip"
@mouseleave="leaveTip"
>
<span class="xicon" style="font-size: 24px;">
<img src="/images/icon/gitee.png" height="24"/>
</span>
</a>
<a <a
id="qq" id="qq"
:href="socialLinks.qq" :href="socialLinks.qq"
@ -72,6 +83,7 @@ let socialHover = ref(false);
let socialTip = ref("通过这里联系我吧"); let socialTip = ref("通过这里联系我吧");
let socialTipData = { let socialTipData = {
github: "去 Github 看看", github: "去 Github 看看",
gitee: "去 Gitee 看看",
qq: "有什么事吗", qq: "有什么事吗",
email: "来封 Email", email: "来封 Email",
telegram: "你懂的 ~", telegram: "你懂的 ~",
@ -81,6 +93,7 @@ let socialTipData = {
// //
const socialLinks = reactive({ const socialLinks = reactive({
github: "https://github.com/" + import.meta.env.VITE_SOCIAL_GITHUB, github: "https://github.com/" + import.meta.env.VITE_SOCIAL_GITHUB,
gitee: "https://gitee.com/" + import.meta.env.VITE_SOCIAL_GITEE,
qq: qq:
"https://wpa.qq.com/msgrd?v=3&uin=" + "https://wpa.qq.com/msgrd?v=3&uin=" +
import.meta.env.VITE_SOCIAL_QQ + import.meta.env.VITE_SOCIAL_QQ +
@ -97,6 +110,9 @@ const changeTip = (e) => {
case "github": case "github":
socialTip.value = socialTipData.github; socialTip.value = socialTipData.github;
return true; return true;
case "gitee":
socialTip.value = socialTipData.gitee;
return true;
case "qq": case "qq":
socialTip.value = socialTipData.qq; socialTip.value = socialTipData.qq;
return true; return true;