From 4b029c1d69217e634f79364954eb5d19362498eb Mon Sep 17 00:00:00 2001 From: Joywin Bennis <107112207+joywin2003@users.noreply.github.com> Date: Sun, 24 Nov 2024 13:30:31 +0530 Subject: [PATCH] refactor: add back navigation button and adjust layout for privacy, refund, and terms pages --- src/app/(legal)/privacy/page.tsx | 30 +++++++++++++++++++++++---- src/app/(legal)/refund/page.tsx | 35 ++++++++++++++++++++++++++++---- src/app/(legal)/terms/page.tsx | 33 ++++++++++++++++++++++++------ 3 files changed, 84 insertions(+), 14 deletions(-) diff --git a/src/app/(legal)/privacy/page.tsx b/src/app/(legal)/privacy/page.tsx index cf683ef..d4afd27 100644 --- a/src/app/(legal)/privacy/page.tsx +++ b/src/app/(legal)/privacy/page.tsx @@ -4,11 +4,36 @@ import Container from "@/components/shared/container"; import { Text } from "@/components/shared/text"; import { legalInfo } from "@/data/legal-info"; import { cn } from "@/lib/utils"; +import { useRouter } from "next/navigation"; export default function PrivacyPolicy() { + const router = useRouter(); return ( - +
+
+ +
+ - {/* Policy Sections */}
{legalInfo.Privacy.map((privacy, index) => (
- {/* Section Title */} - {/* Section Description */}

{privacy.description}

diff --git a/src/app/(legal)/refund/page.tsx b/src/app/(legal)/refund/page.tsx index e3babe9..424c509 100644 --- a/src/app/(legal)/refund/page.tsx +++ b/src/app/(legal)/refund/page.tsx @@ -4,14 +4,41 @@ import Container from "@/components/shared/container"; import { Text } from "@/components/shared/text"; import { legalInfo } from "@/data/legal-info"; import { cn } from "@/lib/utils"; +import Link from "next/link"; // To create a back link +import { useRouter } from "next/navigation"; export default function Refund() { + const router = useRouter(); return ( - +
- - Refund Policy - +
+ +
+ + {/* Title Section */} +
+ + Refund Policy + +
{/* Policy Sections */}
diff --git a/src/app/(legal)/terms/page.tsx b/src/app/(legal)/terms/page.tsx index a4c1e7b..d1dd148 100644 --- a/src/app/(legal)/terms/page.tsx +++ b/src/app/(legal)/terms/page.tsx @@ -2,28 +2,51 @@ import Container from "@/components/shared/container"; import { Text } from "@/components/shared/text"; +import { Button } from "@/components/ui/button"; import { legalInfo } from "@/data/legal-info"; import { cn } from "@/lib/utils"; +import Link from "next/link"; +import { useRouter } from "next/navigation"; export default function TermsAndConditions() { + const router = useRouter(); return ( - +
+
+ +
Terms and Conditions - - {/* Policy Sections */}
{legalInfo.Terms.map((terms, index) => (
- {/* Section Title */} {terms.title} - - {/* Section Description */}

{terms.description}