This is an automated email from the ASF dual-hosted git repository.

guoqi pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-website.git


The following commit(s) were added to refs/heads/master by this push:
     new 2cfa9417b15 fix: homepage link 404 (#1870)
2cfa9417b15 is described below

commit 2cfa9417b155745d4b52ae3165a5577f8d6e05b5
Author: Qi Guo <[email protected]>
AuthorDate: Fri Mar 7 10:24:30 2025 +0800

    fix: homepage link 404 (#1870)
---
 website/src/components/ArrowAnim.tsx            | 4 +++-
 website/src/components/sections/Endcta.tsx      | 3 ++-
 website/src/components/sections/HeroSection.tsx | 3 ++-
 3 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/website/src/components/ArrowAnim.tsx 
b/website/src/components/ArrowAnim.tsx
index 2daa1f53b64..123e99a19f7 100644
--- a/website/src/components/ArrowAnim.tsx
+++ b/website/src/components/ArrowAnim.tsx
@@ -1,12 +1,14 @@
 import type { FC } from 'react';
 import React from 'react';
 import Link from '@docusaurus/Link';
+import useBaseUrl from '@docusaurus/useBaseUrl';
 
 import Translate from '@docusaurus/Translate';
 
 const ArrowAnim: FC = () => (
   <Link
-    href="/blog"
+    target="_parent"
+    to={useBaseUrl('/blog/')}
     className="btn-docs"
   >
     <div className="goto">
diff --git a/website/src/components/sections/Endcta.tsx 
b/website/src/components/sections/Endcta.tsx
index 894fe60e954..eefe855f59d 100644
--- a/website/src/components/sections/Endcta.tsx
+++ b/website/src/components/sections/Endcta.tsx
@@ -4,6 +4,7 @@ import Link from '@docusaurus/Link';
 import Translate from '@docusaurus/Translate';
 import { LazyLoadImage } from 'react-lazy-load-image-component';
 import useWindowType from '@theme/hooks/useWindowSize';
+import useBaseUrl from '@docusaurus/useBaseUrl';
 import ArrowAnim from '../ArrowAnim';
 import style from '../../css/landing-sections/endcta.module.scss';
 
@@ -27,7 +28,7 @@ const EndCTA: FC = () => {
         )}
       </p>
       <div className={style.links}>
-        <Link href="/docs/apisix/getting-started" className="btn btn-download">
+        <Link target="_parent" to={useBaseUrl('docs/apisix/getting-started')} 
className="btn btn-download">
           <Translate id="hero.component.download.btn">Getting 
Started</Translate>
         </Link>
         <ArrowAnim />
diff --git a/website/src/components/sections/HeroSection.tsx 
b/website/src/components/sections/HeroSection.tsx
index f82192eed6b..f30f108b146 100644
--- a/website/src/components/sections/HeroSection.tsx
+++ b/website/src/components/sections/HeroSection.tsx
@@ -5,6 +5,7 @@ import Translate from '@docusaurus/Translate';
 
 import BrowserOnly from '@docusaurus/BrowserOnly';
 import useWindowType from '@theme/hooks/useWindowSize';
+import useBaseUrl from '@docusaurus/useBaseUrl';
 import ArrowAnim from '../ArrowAnim';
 import '../../css/landing-sections/hero.scss';
 
@@ -46,7 +47,7 @@ const HeroSection: FC = () => (
         </Translate>
       </h3>
       <div className="hero-ctas">
-        <Link href="/docs/apisix/getting-started" className="btn btn-download">
+        <Link target="_parent" to={useBaseUrl('docs/apisix/getting-started')} 
className="btn btn-download">
           <Translate id="hero.component.download.btn">Getting 
Started</Translate>
         </Link>
         <ArrowAnim />

Reply via email to