feat: change all Link component to SmartLink

Close #3512
This commit is contained in:
anime
2025-07-24 15:06:39 +08:00
parent fc4817e669
commit ba951cd2aa
338 changed files with 1381 additions and 1381 deletions

View File

@@ -1,7 +1,7 @@
/* eslint-disable @next/next/no-img-element */
import LazyImage from '@/components/LazyImage'
import { siteConfig } from '@/lib/config'
import Link from 'next/link'
import SmartLink from '@/components/SmartLink'
/**
* 博文列表
@@ -69,7 +69,7 @@ export const Blog = ({ posts }) => {
className='wow fadeInUp group mb-10 relative overflow-hidden blog'
data-wow-delay='.1s'>
<div className='relative rounded-xl border overflow-hidden shadow-md dark:border-gray-700 dark:bg-gray-800'>
<Link href={item?.href} className='block'>
<SmartLink href={item?.href} className='block'>
{item.pageCoverThumbnail && (
// 图片半透明
<LazyImage
@@ -92,7 +92,7 @@ export const Blog = ({ posts }) => {
className='absolute max-h-full object-cover'
/>
</div>
</Link>
</SmartLink>
</div>
{/* 内容部分 */}
<div className='relative z-10 p-4'>
@@ -100,11 +100,11 @@ export const Blog = ({ posts }) => {
{item.publishDay}
</span>
<h3>
<Link
<SmartLink
href={item?.href}
className='mb-4 inline-block text-xl font-semibold text-dark hover:text-primary dark:text-white dark:hover:text-primary sm:text-2xl lg:text-xl xl:text-2xl'>
{item.title}
</Link>
</SmartLink>
</h3>
</div>
</div>