diff --git a/src/components/AuthorCard.tsx b/src/components/AuthorCard.tsx index d869612..72337d2 100644 --- a/src/components/AuthorCard.tsx +++ b/src/components/AuthorCard.tsx @@ -24,7 +24,7 @@ export default function AuthorCard({ lang, author }: AuthorCardProps) {
{/* Avatar */}
-
+
{authorInfo.avatar ? ( diff --git a/src/components/Footer.tsx b/src/components/Footer.tsx index 52cb714..767191b 100644 --- a/src/components/Footer.tsx +++ b/src/components/Footer.tsx @@ -19,7 +19,7 @@ export default function Footer({ lang: propLang }: FooterProps) { const t = useTranslations(lang); return ( -
+
{lang === 'zh' ? '构建 AI 产品?寻找技术合伙人?联系我!' : 'Building AI Products? Need a Technical Co-founder? Contact me!'} diff --git a/src/components/GlassHeader.tsx b/src/components/GlassHeader.tsx index f3bc398..549b2d9 100644 --- a/src/components/GlassHeader.tsx +++ b/src/components/GlassHeader.tsx @@ -36,13 +36,13 @@ export default function GlassHeader({ lang: propLang }: GlassHeaderProps) { const toggleMenu = () => setIsMenuOpen(!isMenuOpen); return ( - @@ -75,11 +75,11 @@ export default function GlassHeader({ lang: propLang }: GlassHeaderProps) { { children: React.ReactNode; delay?: number; + direction?: 'up' | 'down' | 'left' | 'right' | 'none'; + duration?: number; } export default function MotionWrapper({ children, delay = 0, + direction = 'up', + duration = 0.6, ...props }: MotionWrapperProps) { + const directions = { + up: { y: 30, x: 0 }, + down: { y: -30, x: 0 }, + left: { x: 30, y: 0 }, + right: { x: -30, y: 0 }, + none: { x: 0, y: 0 } + }; + + const initial = { + opacity: 0, + ...directions[direction] + }; + + const whileInView = { + opacity: 1, + x: 0, + y: 0, + transition: { + duration, + delay, + ease: [0.43, 0.13, 0.23, 0.96] + } + }; + return ( {children} diff --git a/src/components/ShareButtons.tsx b/src/components/ShareButtons.tsx index 41cae11..7996c03 100644 --- a/src/components/ShareButtons.tsx +++ b/src/components/ShareButtons.tsx @@ -56,7 +56,7 @@ export default function ShareButtons({ lang, title, url }: ShareButtonsProps) { return (

- + {shareText} @@ -87,7 +87,7 @@ export default function ShareButtons({ lang, title, url }: ShareButtonsProps) { className=" flex items-center justify-center w-12 h-12 rounded-full bg-muted text-muted-foreground transition-all duration-200 - hover:bg-purple-500/10 hover:text-purple-500 + hover:bg-primary/10 hover:text-primary relative " title={copyText} @@ -106,7 +106,7 @@ export default function ShareButtons({ lang, title, url }: ShareButtonsProps) { {/* Copy Success Message */} {copied && ( -
+
diff --git a/src/components/SkillsMarquee.tsx b/src/components/SkillsMarquee.tsx index 9137527..ca0830c 100644 --- a/src/components/SkillsMarquee.tsx +++ b/src/components/SkillsMarquee.tsx @@ -53,7 +53,7 @@ function SkillItem({ skill }: { skill: SkillItem }) { const iconUrl = `https://skillicons.dev/icons?i=${skill.icon}`; return ( -
+
{skill.name} = ({ delayBeforeDelete = 2000, delayBeforeTyping = 700, loop = true, - cursorClassName = 'text-purple-500', + cursorClassName = 'text-primary', className = '', showCursor = true, }) => { diff --git a/src/components/blog/BlogList.astro b/src/components/blog/BlogList.astro index 6c31fbb..ed02946 100644 --- a/src/components/blog/BlogList.astro +++ b/src/components/blog/BlogList.astro @@ -76,7 +76,7 @@ const readMoreText = lang === 'zh' ? '阅读更多' : 'Read More'; {posts.length > 0 ? ( posts.map((post, index) => (
-
+
{/* Featured Image */}
@@ -91,7 +91,7 @@ const readMoreText = lang === 'zh' ? '阅读更多' : 'Read More'; {/* Content */}
-

+

{post.title} @@ -135,7 +135,7 @@ const readMoreText = lang === 'zh' ? '阅读更多' : 'Read More'; {readMoreText} @@ -150,7 +150,7 @@ const readMoreText = lang === 'zh' ? '阅读更多' : 'Read More'; )) ) : (
- +

@@ -161,7 +161,7 @@ const readMoreText = lang === 'zh' ? '阅读更多' : 'Read More';

diff --git a/src/components/blog/CategoryCard.astro b/src/components/blog/CategoryCard.astro index 7e92252..a7de5c4 100644 --- a/src/components/blog/CategoryCard.astro +++ b/src/components/blog/CategoryCard.astro @@ -43,7 +43,7 @@ const title = titles[lang] || titles[defaultLang];

- + {title}

@@ -52,7 +52,7 @@ const title = titles[lang] || titles[defaultLang]; const categoryId = categoryMap.get(cat) || cat.toLowerCase(); return ( + class={`block transition-colors duration-200 ${categoryId === currentCategory.toLowerCase() ? 'text-primary font-medium' : 'text-muted-foreground hover:text-primary'}`}> {cat} ); diff --git a/src/components/blog/PostMeta.astro b/src/components/blog/PostMeta.astro index fac5901..c54ca31 100644 --- a/src/components/blog/PostMeta.astro +++ b/src/components/blog/PostMeta.astro @@ -99,13 +99,13 @@ const getReadingTimeText = (minutes: number) => { : cat.toLowerCase(); return ( - + {cat} ); }) ) : ( - + {category} )} diff --git a/src/components/blog/TagCard.astro b/src/components/blog/TagCard.astro index e7e8cad..010a5de 100644 --- a/src/components/blog/TagCard.astro +++ b/src/components/blog/TagCard.astro @@ -43,7 +43,7 @@ const title = titles[lang] || titles[defaultLang];

- + {title}

@@ -54,7 +54,7 @@ const title = titles[lang] || titles[defaultLang]; const isCurrentTag = tagId === currentTag.toLowerCase(); return ( + class={`inline-block px-3 py-1 text-sm rounded-full transition-all duration-200 ${isCurrentTag ? 'bg-primary/20 text-primary font-medium' : 'bg-muted text-muted-foreground hover:bg-primary/20 hover:text-primary'}`}> {tagItem} ); diff --git a/src/components/layout/BlogNavigation.astro b/src/components/layout/BlogNavigation.astro index e67985d..fce0316 100644 --- a/src/components/layout/BlogNavigation.astro +++ b/src/components/layout/BlogNavigation.astro @@ -76,7 +76,7 @@ const nextText = lang === 'zh' ? '下一篇' : 'Next Post'; @@ -91,7 +91,7 @@ const nextText = lang === 'zh' ? '下一篇' : 'Next Post'; diff --git a/src/components/layout/TableOfContents.astro b/src/components/layout/TableOfContents.astro index 4d409a6..e1c0010 100644 --- a/src/components/layout/TableOfContents.astro +++ b/src/components/layout/TableOfContents.astro @@ -14,7 +14,7 @@ const title = lang === 'zh' ? '目录' : 'Table of Contents';