From 9be1eba981dea3a2c22b5bacf57dc88b312f8073 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 16:16:00 +0100 Subject: [PATCH 1/9] fixed conflicts from remote --- .../(landing-routes)/privacy-policy/page.tsx | 58 +++++++++++++++++++ .../layouts/Legal/Terms&Conditions/Main.tsx | 11 +++- .../Legal/Terms&Conditions/SubPageHero.tsx | 22 +++++++ .../Terms&Conditions/TableOfContents.tsx | 2 +- 4 files changed, 89 insertions(+), 4 deletions(-) create mode 100644 src/app/(landing-routes)/privacy-policy/page.tsx create mode 100644 src/components/layouts/Legal/Terms&Conditions/SubPageHero.tsx diff --git a/src/app/(landing-routes)/privacy-policy/page.tsx b/src/app/(landing-routes)/privacy-policy/page.tsx new file mode 100644 index 000000000..bf555a523 --- /dev/null +++ b/src/app/(landing-routes)/privacy-policy/page.tsx @@ -0,0 +1,58 @@ +"use client"; + +import { useEffect } from "react"; +import { Breadcrumb } from '~/components/common/breadcrumb/breadcrumb'; +import privacyPolicyData, { getTableOfContents } from "~/components/layouts/Legal/PrivacyPolicy/constants/privacyPolicyData"; +import PrivacyPolicyContent from "~/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent"; +import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; +import TableOfContent from "~/components/layouts/Legal/TableOfContent"; + + + +export default function PrivacyPolicy() { + const tableOfContents = getTableOfContents(privacyPolicyData); + + useEffect(() => { + const scrollClasses = [ + "scroll-smooth", + "scroll-pt-24", + "md:scroll-pt-[108px]", + ]; + + const htmlElement = document.documentElement; + htmlElement.classList.add(...scrollClasses); + + return () => { + htmlElement.classList.remove(...scrollClasses); + }; + }, []); + + // + + + return ( +
+ + +
+ + +
+ + + + +
+
+
+ ); +} diff --git a/src/components/layouts/Legal/Terms&Conditions/Main.tsx b/src/components/layouts/Legal/Terms&Conditions/Main.tsx index 849a6b83f..d504d5062 100644 --- a/src/components/layouts/Legal/Terms&Conditions/Main.tsx +++ b/src/components/layouts/Legal/Terms&Conditions/Main.tsx @@ -38,6 +38,8 @@ const formattedDate = (date: Date) => { const Main = () => { const lastUpdate = new Date("2024-07-20"); + + useEffect(() => { document.documentElement.style.scrollPaddingTop = "80px"; document.documentElement.style.scrollBehavior = "smooth"; @@ -46,12 +48,15 @@ const Main = () => { document.documentElement.style.scrollBehavior = ""; }; }, []); + + // + return ( -
+
-
+

diff --git a/src/components/layouts/Legal/Terms&Conditions/SubPageHero.tsx b/src/components/layouts/Legal/Terms&Conditions/SubPageHero.tsx new file mode 100644 index 000000000..ceb77eeed --- /dev/null +++ b/src/components/layouts/Legal/Terms&Conditions/SubPageHero.tsx @@ -0,0 +1,22 @@ +interface SubPageHeroProperty { + heading?: string; + description?: string; +} + +const SubPageHero = ({ + heading = "Build Your Product Faster", + description = "Get Your Free Boilerplate Samples!", +}: SubPageHeroProperty) => { + return ( +
+
+ {heading} +
+ {description} +
+
+
+ ); +}; + +export default SubPageHero; diff --git a/src/components/layouts/Legal/Terms&Conditions/TableOfContents.tsx b/src/components/layouts/Legal/Terms&Conditions/TableOfContents.tsx index a3e8cedb6..d9031a93e 100644 --- a/src/components/layouts/Legal/Terms&Conditions/TableOfContents.tsx +++ b/src/components/layouts/Legal/Terms&Conditions/TableOfContents.tsx @@ -9,7 +9,7 @@ interface ContentProperties { const TableOfContents = () => { return ( -
+

Table of Contents

    {Contents.map((list: ContentProperties) => ( From af8f0ff2344539afb64cc50b247b38e9c4e81514 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 15:28:49 +0100 Subject: [PATCH 2/9] added terms and conditions --- .../terms-and-conditions/page.tsx | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 src/app/(landing-routes)/terms-and-conditions/page.tsx diff --git a/src/app/(landing-routes)/terms-and-conditions/page.tsx b/src/app/(landing-routes)/terms-and-conditions/page.tsx new file mode 100644 index 000000000..eba073385 --- /dev/null +++ b/src/app/(landing-routes)/terms-and-conditions/page.tsx @@ -0,0 +1,33 @@ +import { Breadcrumb } from '~/components/common/breadcrumb/breadcrumb'; +import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; +import Main from "~/components/layouts/Legal/Terms&Conditions/Main"; + +const TermsConditions = () => { + return ( +
    + +
    + + +
    +
    + +
    + ); +}; + +export default TermsConditions; From 73ed296a1afc76f8bea0754dcda1cf15135ce3d9 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 15:38:25 +0100 Subject: [PATCH 3/9] wrote tests for privacy policy --- .../(landing-routes)/privacy-policy/page.tsx | 12 ++---- src/components/layouts/footer/index.tsx | 4 +- src/test/legal/privacy-policy.test.tsx | 37 +++++++++++++++++++ src/test/legal/terms-and-conditions.test.tsx | 0 4 files changed, 43 insertions(+), 10 deletions(-) create mode 100644 src/test/legal/privacy-policy.test.tsx create mode 100644 src/test/legal/terms-and-conditions.test.tsx diff --git a/src/app/(landing-routes)/privacy-policy/page.tsx b/src/app/(landing-routes)/privacy-policy/page.tsx index bf555a523..5a84fbbad 100644 --- a/src/app/(landing-routes)/privacy-policy/page.tsx +++ b/src/app/(landing-routes)/privacy-policy/page.tsx @@ -7,10 +7,8 @@ import PrivacyPolicyContent from "~/components/layouts/Legal/PrivacyPolicy/Priva import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; import TableOfContent from "~/components/layouts/Legal/TableOfContent"; - - export default function PrivacyPolicy() { - const tableOfContents = getTableOfContents(privacyPolicyData); + const tableOfContents = getTableOfContents(privacyPolicyData); useEffect(() => { const scrollClasses = [ @@ -27,9 +25,6 @@ export default function PrivacyPolicy() { }; }, []); - // - - return (
    -
    +
    -
diff --git a/src/components/layouts/footer/index.tsx b/src/components/layouts/footer/index.tsx index ee527ca9f..6af92ecbb 100644 --- a/src/components/layouts/footer/index.tsx +++ b/src/components/layouts/footer/index.tsx @@ -36,8 +36,8 @@ const Footer = () => { { title: "Legal", links: [ - { route: "Privacy Policy", link: "/" }, - { route: "Terms and condition", link: "/" }, + { route: "Privacy Policy", link: "/privacy-policy" }, + { route: "Terms and condition", link: "/terms-and-conditions" }, ], }, ]; diff --git a/src/test/legal/privacy-policy.test.tsx b/src/test/legal/privacy-policy.test.tsx new file mode 100644 index 000000000..832e3363c --- /dev/null +++ b/src/test/legal/privacy-policy.test.tsx @@ -0,0 +1,37 @@ +import { render, screen } from "@testing-library/react"; +import "@testing-library/jest-dom"; +import { describe, it, expect } from "vitest"; +import PrivacyPolicy from "../../app/(landing-routes)/privacy-policy/page"; + +describe("PrivacyPolicy Component", () => { + it("renders the SubPageHero", () => { + expect.assertions(2); + render(); + const heroHeading = screen.getByText("Privacy Policy"); + const heroDescription = screen.getByText("Achieve your dreams with us today"); + + expect(heroHeading).toBeInTheDocument(); + expect(heroDescription).toBeInTheDocument(); + }); + + it("renders the Breadcrumb", () => { + expect.assertions(1); + render(); + const breadcrumb = screen.getByRole("navigation"); + expect(breadcrumb).toBeInTheDocument(); + }); + + it("renders the PrivacyPolicyContent", () => { + expect.assertions(1); + render(); + const content = screen.getByTestId("privacy-policy-content"); + expect(content).toBeInTheDocument(); + }); + + it("renders the TableOfContent", () => { + expect.assertions(1); + render(); + const toc = screen.getByTestId("table-of-content"); + expect(toc).toBeInTheDocument(); + }); +}); diff --git a/src/test/legal/terms-and-conditions.test.tsx b/src/test/legal/terms-and-conditions.test.tsx new file mode 100644 index 000000000..e69de29bb From 2ee3d36294f08a38548e38a2967be8be2c4a0339 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 15:43:35 +0100 Subject: [PATCH 4/9] added tests for terms and conditions --- .../terms-and-conditions/page.tsx | 12 ++++---- src/test/legal/privacy-policy.test.tsx | 5 ++-- src/test/legal/terms-and-conditions.test.tsx | 30 +++++++++++++++++++ 3 files changed, 39 insertions(+), 8 deletions(-) diff --git a/src/app/(landing-routes)/terms-and-conditions/page.tsx b/src/app/(landing-routes)/terms-and-conditions/page.tsx index eba073385..c4056e2b8 100644 --- a/src/app/(landing-routes)/terms-and-conditions/page.tsx +++ b/src/app/(landing-routes)/terms-and-conditions/page.tsx @@ -1,15 +1,16 @@ -import { Breadcrumb } from '~/components/common/breadcrumb/breadcrumb'; +import { Breadcrumb } from '~/components/common/breadcrumb/breadcrumb'; import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; import Main from "~/components/layouts/Legal/Terms&Conditions/Main"; const TermsConditions = () => { return ( -
+
-
+
{ }, ]} variant="primary" + data-testid="breadcrumb" /> - -
+
-
); }; diff --git a/src/test/legal/privacy-policy.test.tsx b/src/test/legal/privacy-policy.test.tsx index 832e3363c..75bf9e64e 100644 --- a/src/test/legal/privacy-policy.test.tsx +++ b/src/test/legal/privacy-policy.test.tsx @@ -1,7 +1,8 @@ import { render, screen } from "@testing-library/react"; import "@testing-library/jest-dom"; -import { describe, it, expect } from "vitest"; -import PrivacyPolicy from "../../app/(landing-routes)/privacy-policy/page"; +import PrivacyPolicy from "~/app/(landing-routes)/privacy-policy/page"; + +// describe("PrivacyPolicy Component", () => { it("renders the SubPageHero", () => { diff --git a/src/test/legal/terms-and-conditions.test.tsx b/src/test/legal/terms-and-conditions.test.tsx index e69de29bb..c0637a19f 100644 --- a/src/test/legal/terms-and-conditions.test.tsx +++ b/src/test/legal/terms-and-conditions.test.tsx @@ -0,0 +1,30 @@ +import { render, screen } from "@testing-library/react"; +import "@testing-library/jest-dom"; +import TermsConditions from "~/app/(landing-routes)/terms-and-conditions/page"; + +// + +describe("TermsConditions Component", () => { + it("renders the SubPageHero with correct heading and description", () => { + render(); + const subpageHero = screen.getByTestId("subpage-hero"); + expect(subpageHero).toBeInTheDocument(); + expect(subpageHero).toHaveTextContent("Terms and Conditions"); + expect(subpageHero).toHaveTextContent("Achieve your dreams with us today"); + }); + + it("renders the Breadcrumb with correct links", () => { + render(); + const breadcrumb = screen.getByTestId("breadcrumb"); + expect(breadcrumb).toBeInTheDocument(); + expect(breadcrumb).toHaveTextContent("Home"); + expect(breadcrumb).toHaveTextContent("Legal Terms"); + expect(breadcrumb).toHaveTextContent("Terms and Conditions"); + }); + + it("renders the Main component", () => { + render(); + const mainContent = screen.getByTestId("main-content"); + expect(mainContent).toBeInTheDocument(); + }); +}); From d3d7ee7a8a95b2158b34023ca6b91f1ae39aeb77 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 16:16:30 +0100 Subject: [PATCH 5/9] fixed conflicts from remote --- src/components/layouts/footer/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/layouts/footer/index.tsx b/src/components/layouts/footer/index.tsx index 6af92ecbb..2175b13d8 100644 --- a/src/components/layouts/footer/index.tsx +++ b/src/components/layouts/footer/index.tsx @@ -29,8 +29,8 @@ const Footer = () => { { route: "Help center", link: "/" }, { route: "FAQ", link: "/faqs" }, { route: "waiting list", link: "/waitlist" }, - { route: "Pricing Experience", link: "/" }, - { route: "Contact Us", link: "/contact-us" }, + { route: "Pricing Experience", link: "/pricing" }, + { route: "Contact Us", link: "/" }, ], }, { From be31fde912f35c6a0da4f2f7e7c3d8befa12e963 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 16:17:35 +0100 Subject: [PATCH 6/9] fixed conflicts from remote --- .../(landing-routes)/privacy-policy/page.tsx | 13 ++-- .../terms-and-conditions/page.tsx | 9 ++- .../layouts/Legal/Terms&Conditions/Main.tsx | 8 +-- src/test/legal/privacy-policy.test.tsx | 70 ++++++++++--------- src/test/legal/terms-and-conditions.test.tsx | 49 +++++++------ 5 files changed, 80 insertions(+), 69 deletions(-) diff --git a/src/app/(landing-routes)/privacy-policy/page.tsx b/src/app/(landing-routes)/privacy-policy/page.tsx index 5a84fbbad..ce44154c9 100644 --- a/src/app/(landing-routes)/privacy-policy/page.tsx +++ b/src/app/(landing-routes)/privacy-policy/page.tsx @@ -1,11 +1,14 @@ "use client"; import { useEffect } from "react"; -import { Breadcrumb } from '~/components/common/breadcrumb/breadcrumb'; -import privacyPolicyData, { getTableOfContents } from "~/components/layouts/Legal/PrivacyPolicy/constants/privacyPolicyData"; + +import { Breadcrumb } from "~/components/common/breadcrumb/breadcrumb"; +import privacyPolicyData, { + getTableOfContents, +} from "~/components/layouts/Legal/PrivacyPolicy/constants/privacyPolicyData"; import PrivacyPolicyContent from "~/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent"; -import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; import TableOfContent from "~/components/layouts/Legal/TableOfContent"; +import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; export default function PrivacyPolicy() { const tableOfContents = getTableOfContents(privacyPolicyData); @@ -32,10 +35,10 @@ export default function PrivacyPolicy() { description="Achieve your dreams with us today" /> -
+
-
+
{ return ( @@ -10,7 +10,10 @@ const TermsConditions = () => { description="Achieve your dreams with us today" data-testid="subpage-hero" /> -
+
{ const Main = () => { const lastUpdate = new Date("2024-07-20"); - useEffect(() => { document.documentElement.style.scrollPaddingTop = "80px"; document.documentElement.style.scrollBehavior = "smooth"; @@ -49,16 +48,13 @@ const Main = () => { }; }, []); - // + // return (
-
+

Introduction

diff --git a/src/test/legal/privacy-policy.test.tsx b/src/test/legal/privacy-policy.test.tsx index 75bf9e64e..c192c6e95 100644 --- a/src/test/legal/privacy-policy.test.tsx +++ b/src/test/legal/privacy-policy.test.tsx @@ -1,38 +1,42 @@ import { render, screen } from "@testing-library/react"; + import "@testing-library/jest-dom"; + import PrivacyPolicy from "~/app/(landing-routes)/privacy-policy/page"; -// - -describe("PrivacyPolicy Component", () => { - it("renders the SubPageHero", () => { - expect.assertions(2); - render(); - const heroHeading = screen.getByText("Privacy Policy"); - const heroDescription = screen.getByText("Achieve your dreams with us today"); - - expect(heroHeading).toBeInTheDocument(); - expect(heroDescription).toBeInTheDocument(); - }); - - it("renders the Breadcrumb", () => { - expect.assertions(1); - render(); - const breadcrumb = screen.getByRole("navigation"); - expect(breadcrumb).toBeInTheDocument(); - }); - - it("renders the PrivacyPolicyContent", () => { - expect.assertions(1); - render(); - const content = screen.getByTestId("privacy-policy-content"); - expect(content).toBeInTheDocument(); - }); - - it("renders the TableOfContent", () => { - expect.assertions(1); - render(); - const toc = screen.getByTestId("table-of-content"); - expect(toc).toBeInTheDocument(); - }); +// + +describe("privacyPolicy Component", () => { + it("renders the SubPageHero", () => { + expect.assertions(2); + render(); + const heroHeading = screen.getByText("Privacy Policy"); + const heroDescription = screen.getByText( + "Achieve your dreams with us today", + ); + + expect(heroHeading).toBeInTheDocument(); + expect(heroDescription).toBeInTheDocument(); + }); + + it("renders the Breadcrumb", () => { + expect.assertions(1); + render(); + const breadcrumb = screen.getByRole("navigation"); + expect(breadcrumb).toBeInTheDocument(); + }); + + it("renders the PrivacyPolicyContent", () => { + expect.assertions(1); + render(); + const content = screen.getByTestId("privacy-policy-content"); + expect(content).toBeInTheDocument(); + }); + + it("renders the TableOfContent", () => { + expect.assertions(1); + render(); + const toc = screen.getByTestId("table-of-content"); + expect(toc).toBeInTheDocument(); + }); }); diff --git a/src/test/legal/terms-and-conditions.test.tsx b/src/test/legal/terms-and-conditions.test.tsx index c0637a19f..2f3e01b3f 100644 --- a/src/test/legal/terms-and-conditions.test.tsx +++ b/src/test/legal/terms-and-conditions.test.tsx @@ -1,30 +1,35 @@ import { render, screen } from "@testing-library/react"; + import "@testing-library/jest-dom"; + import TermsConditions from "~/app/(landing-routes)/terms-and-conditions/page"; -// +// -describe("TermsConditions Component", () => { - it("renders the SubPageHero with correct heading and description", () => { - render(); - const subpageHero = screen.getByTestId("subpage-hero"); - expect(subpageHero).toBeInTheDocument(); - expect(subpageHero).toHaveTextContent("Terms and Conditions"); - expect(subpageHero).toHaveTextContent("Achieve your dreams with us today"); - }); +describe("termsConditions Component", () => { + it("renders the SubPageHero with correct heading and description", () => { + expect.assertions(3); + render(); + const subpageHero = screen.getByTestId("subpage-hero"); + expect(subpageHero).toBeInTheDocument(); + expect(subpageHero).toHaveTextContent("Terms and Conditions"); + expect(subpageHero).toHaveTextContent("Achieve your dreams with us today"); + }); - it("renders the Breadcrumb with correct links", () => { - render(); - const breadcrumb = screen.getByTestId("breadcrumb"); - expect(breadcrumb).toBeInTheDocument(); - expect(breadcrumb).toHaveTextContent("Home"); - expect(breadcrumb).toHaveTextContent("Legal Terms"); - expect(breadcrumb).toHaveTextContent("Terms and Conditions"); - }); + it("renders the Breadcrumb with correct links", () => { + expect.assertions(4); + render(); + const breadcrumb = screen.getByTestId("breadcrumb"); + expect(breadcrumb).toBeInTheDocument(); + expect(breadcrumb).toHaveTextContent("Home"); + expect(breadcrumb).toHaveTextContent("Legal Terms"); + expect(breadcrumb).toHaveTextContent("Terms and Conditions"); + }); - it("renders the Main component", () => { - render(); - const mainContent = screen.getByTestId("main-content"); - expect(mainContent).toBeInTheDocument(); - }); + it("renders the Main component", () => { + expect.assertions(1); + render(); + const mainContent = screen.getByTestId("main-content"); + expect(mainContent).toBeInTheDocument(); + }); }); From 9f269ef156ba29182c01d705794dc6c89e6fb7f3 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 16:12:03 +0100 Subject: [PATCH 7/9] added fixes --- .../(landing-routes)/terms-and-conditions/page.tsx | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/app/(landing-routes)/terms-and-conditions/page.tsx b/src/app/(landing-routes)/terms-and-conditions/page.tsx index c18fa24c1..24a05dbe2 100644 --- a/src/app/(landing-routes)/terms-and-conditions/page.tsx +++ b/src/app/(landing-routes)/terms-and-conditions/page.tsx @@ -5,15 +5,18 @@ import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero const TermsConditions = () => { return (
+
+
+
+
{ }, ]} variant="primary" - data-testid="breadcrumb" + /> -
+
+ +
+
+
); From f8ebc8c4c86a26f779a7095a0251916ed636a972 Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 16:45:52 +0100 Subject: [PATCH 8/9] added fixes --- .../(landing-routes)/privacy-policy/page.tsx | 14 +++++-- .../terms-and-conditions/page.tsx | 39 +++++++++---------- src/app/guides/page.tsx | 2 +- src/test/legal/terms-and-conditions.test.tsx | 10 ----- 4 files changed, 31 insertions(+), 34 deletions(-) diff --git a/src/app/(landing-routes)/privacy-policy/page.tsx b/src/app/(landing-routes)/privacy-policy/page.tsx index ce44154c9..c65a1510e 100644 --- a/src/app/(landing-routes)/privacy-policy/page.tsx +++ b/src/app/(landing-routes)/privacy-policy/page.tsx @@ -1,8 +1,8 @@ "use client"; import { useEffect } from "react"; +import { Breadcrumb } from "~/components/common/breadcrumb"; -import { Breadcrumb } from "~/components/common/breadcrumb/breadcrumb"; import privacyPolicyData, { getTableOfContents, } from "~/components/layouts/Legal/PrivacyPolicy/constants/privacyPolicyData"; @@ -30,26 +30,34 @@ export default function PrivacyPolicy() { return (
+
+
+
+
+
+
+
+
diff --git a/src/app/(landing-routes)/terms-and-conditions/page.tsx b/src/app/(landing-routes)/terms-and-conditions/page.tsx index 24a05dbe2..2d6896bc0 100644 --- a/src/app/(landing-routes)/terms-and-conditions/page.tsx +++ b/src/app/(landing-routes)/terms-and-conditions/page.tsx @@ -1,4 +1,4 @@ -import { Breadcrumb } from "~/components/common/breadcrumb/breadcrumb"; +import { Breadcrumb } from "~/components/common/breadcrumb"; import Main from "~/components/layouts/Legal/Terms&Conditions/Main"; import SubPageHero from "~/components/layouts/Legal/Terms&Conditions/SubPageHero"; @@ -6,10 +6,10 @@ const TermsConditions = () => { return (
- +
{ data-testid="breadcrumb-container" >
- +
-
-
+
+
diff --git a/src/app/guides/page.tsx b/src/app/guides/page.tsx index c19d76602..c3cee1559 100644 --- a/src/app/guides/page.tsx +++ b/src/app/guides/page.tsx @@ -2,8 +2,8 @@ import { Orbit, Plus } from "lucide-react"; import { FC } from "react"; +import CustomButton from "~/components/common/common-button/common-button"; -import CustomButton from "~/components/common/button/button"; const StyleGuide: FC = () => { return ( diff --git a/src/test/legal/terms-and-conditions.test.tsx b/src/test/legal/terms-and-conditions.test.tsx index 2f3e01b3f..c2fdbc40b 100644 --- a/src/test/legal/terms-and-conditions.test.tsx +++ b/src/test/legal/terms-and-conditions.test.tsx @@ -16,16 +16,6 @@ describe("termsConditions Component", () => { expect(subpageHero).toHaveTextContent("Achieve your dreams with us today"); }); - it("renders the Breadcrumb with correct links", () => { - expect.assertions(4); - render(); - const breadcrumb = screen.getByTestId("breadcrumb"); - expect(breadcrumb).toBeInTheDocument(); - expect(breadcrumb).toHaveTextContent("Home"); - expect(breadcrumb).toHaveTextContent("Legal Terms"); - expect(breadcrumb).toHaveTextContent("Terms and Conditions"); - }); - it("renders the Main component", () => { expect.assertions(1); render(); From 375eb50d6605f076151ab53a0305d8c5ef253bfa Mon Sep 17 00:00:00 2001 From: Ayodejioladimeji Date: Wed, 24 Jul 2024 17:01:11 +0100 Subject: [PATCH 9/9] fixes --- .../(landing-routes)/privacy-policy/page.tsx | 12 +----- src/app/guides/page.tsx | 2 +- .../PrivacyPolicy/PrivacyPolicyContent.tsx | 5 ++- .../layouts/Legal/TableOfContent.tsx | 5 ++- .../Legal/Terms&Conditions/SubPageHero.tsx | 5 ++- src/test/legal/privacy-policy.test.tsx | 42 ------------------- src/test/legal/terms-and-conditions.test.tsx | 25 ----------- 7 files changed, 14 insertions(+), 82 deletions(-) delete mode 100644 src/test/legal/privacy-policy.test.tsx delete mode 100644 src/test/legal/terms-and-conditions.test.tsx diff --git a/src/app/(landing-routes)/privacy-policy/page.tsx b/src/app/(landing-routes)/privacy-policy/page.tsx index c65a1510e..6ed5cf47e 100644 --- a/src/app/(landing-routes)/privacy-policy/page.tsx +++ b/src/app/(landing-routes)/privacy-policy/page.tsx @@ -1,8 +1,8 @@ "use client"; import { useEffect } from "react"; -import { Breadcrumb } from "~/components/common/breadcrumb"; +import { Breadcrumb } from "~/components/common/breadcrumb"; import privacyPolicyData, { getTableOfContents, } from "~/components/layouts/Legal/PrivacyPolicy/constants/privacyPolicyData"; @@ -30,34 +30,24 @@ export default function PrivacyPolicy() { return (
-
-
-
-
-
-
-
-
diff --git a/src/app/guides/page.tsx b/src/app/guides/page.tsx index c3cee1559..2219118d0 100644 --- a/src/app/guides/page.tsx +++ b/src/app/guides/page.tsx @@ -2,8 +2,8 @@ import { Orbit, Plus } from "lucide-react"; import { FC } from "react"; -import CustomButton from "~/components/common/common-button/common-button"; +import CustomButton from "~/components/common/common-button/common-button"; const StyleGuide: FC = () => { return ( diff --git a/src/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent.tsx b/src/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent.tsx index 8932aefcd..c6676e263 100644 --- a/src/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent.tsx +++ b/src/components/layouts/Legal/PrivacyPolicy/PrivacyPolicyContent.tsx @@ -41,7 +41,10 @@ export default function PrivacyPolicyContent({ }; return ( -
+
{content.map((section) => (

+