From 03b3de82d0facb925fdf4e6fe76613a3540d70d3 Mon Sep 17 00:00:00 2001 From: Amaan Mirza Date: Thu, 11 Sep 2025 18:44:18 +0530 Subject: [PATCH 1/3] Not found page layout design --- src/theme/NotFound/Content/index.js | 89 +++++++++++++++++++++++++---- 1 file changed, 78 insertions(+), 11 deletions(-) diff --git a/src/theme/NotFound/Content/index.js b/src/theme/NotFound/Content/index.js index a20b1a706..54df25c40 100644 --- a/src/theme/NotFound/Content/index.js +++ b/src/theme/NotFound/Content/index.js @@ -1,20 +1,87 @@ -import React, {useEffect} from "react"; +import React from "react"; import {PageMetadata} from "@docusaurus/theme-common"; +import Link from "@docusaurus/Link"; +import useBaseUrl from "@docusaurus/useBaseUrl"; export default function Index() { - useEffect(() => { - window.location.href = "/docs/"; - }, 2000); - []; - return ( <> - -
-
-
-

Redirecting to home page...

+ +
+
+ {/* 404 Error Icon */} +
+ + + +
+ + {/* Error Message */} +
+

+ 404 - Page Not Found +

+

+ Oops! The page you're looking for doesn't exist. It might have been moved, deleted, or you entered the wrong URL. +

+ + {/* Action Buttons */} +
+ + + + + Go to Homepage + + + + + + Browse Documentation + +
+ +
From c6fa6a743cf7e2ee0ba8300b7db27a644f096187 Mon Sep 17 00:00:00 2001 From: Amaan Mirza Date: Sat, 13 Sep 2025 15:42:11 +0530 Subject: [PATCH 2/3] signed commit Signed-off-by: Amaan Mirza --- src/theme/NotFound/Content/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/theme/NotFound/Content/index.js b/src/theme/NotFound/Content/index.js index 54df25c40..4150c8bf0 100644 --- a/src/theme/NotFound/Content/index.js +++ b/src/theme/NotFound/Content/index.js @@ -9,7 +9,7 @@ export default function Index() {
- {/* 404 Error Icon */} + {/* 404 Error */}
Date: Fri, 26 Sep 2025 18:45:07 +0530 Subject: [PATCH 3/3] added redirect after 2 seconds delay Signed-off-by: amaan287 --- src/theme/NotFound/Content/index.js | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/src/theme/NotFound/Content/index.js b/src/theme/NotFound/Content/index.js index 4150c8bf0..3c139583c 100644 --- a/src/theme/NotFound/Content/index.js +++ b/src/theme/NotFound/Content/index.js @@ -1,9 +1,19 @@ -import React from "react"; -import {PageMetadata} from "@docusaurus/theme-common"; +import React, { useEffect } from "react"; +import { PageMetadata } from "@docusaurus/theme-common"; import Link from "@docusaurus/Link"; import useBaseUrl from "@docusaurus/useBaseUrl"; + export default function Index() { + useEffect(() => { + const timer = setTimeout(() => { + window.location.href = "/docs/"; + }, 2000); + + + return () => clearTimeout(timer); + }, []); + return ( <> @@ -81,7 +91,7 @@ export default function Index() {
- +