diff --git a/layouts/default.vue b/layouts/default.vue index a07e90e..6ba9ae8 100644 --- a/layouts/default.vue +++ b/layouts/default.vue @@ -166,12 +166,11 @@ format="webp" /> 京公网安备11010802045670号 + >京ICP备{{ icpSuffix }}

@@ -187,12 +186,20 @@ const router = useRouter() const checkScroll = () => { isScrolled.value = window.scrollY > 20 } - +const icpSuffix = ref('') onMounted(() => { if (typeof window !== 'undefined') { checkScroll() window.addEventListener('scroll', checkScroll) } + const hostname = window.location.hostname + if (hostname.endsWith('.com')) { + icpSuffix.value = '2025119652号-2' + } else if (hostname.endsWith('.cn')) { + icpSuffix.value = '2025119652号-1' + } else { + icpSuffix.value = '2025119652号' + } }) onUnmounted(() => {