From 5c60594a4f828bbecdee1dd11277f63e7aaf4cc8 Mon Sep 17 00:00:00 2001 From: Thatsaphorn Atchariyaphap Date: Wed, 16 Apr 2025 17:37:41 +0000 Subject: [PATCH] Merge branch 'homepage-refactoring' into 'dev' Homepage Refactoring - Pt .3 See merge request rheinsw/website!28 --- app/(root)/layout.tsx | 4 +- app/contact/layout.tsx | 6 +- app/globals.css | 21 -- app/legal/layout.tsx | 7 +- app/services/layout.tsx | 6 +- app/services/page.tsx | 4 +- components/Helper/SectionDivider.tsx | 12 +- components/Helper/Theme.ts | 18 -- components/Helper/ThemeColors.ts | 34 +-- components/Home/Contact/ContactCTA.tsx | 57 ----- components/Home/Home.tsx | 53 +++-- components/Home/Offer/FullStack.tsx | 75 ------- components/Home/Offer/ManagedServices.tsx | 57 ----- components/Home/Offer/Offer.tsx | 28 --- components/Home/{About => Sections}/About.tsx | 48 ++-- components/Home/Sections/ContactCTA.tsx | 57 +++++ components/Home/{Hero => Sections}/Hero.tsx | 0 .../Home/{ => Sections}/HomeServices.tsx | 48 ++-- components/Home/{ => Sections}/TechStack.tsx | 67 +++--- components/Navbar/DesktopNav.tsx | 69 +++--- components/Navbar/MobileNav.tsx | 38 ++-- components/Section.tsx | 34 +++ components/Services/Section/OverviewTabs.tsx | 88 ++++++++ components/Services/Section/ServiceHero.tsx | 30 +++ .../Services/Section/overview/BugFixing.tsx | 70 ++++++ .../Services/Section/overview/Consulting.tsx | 60 +++++ .../Services/Section/overview/Development.tsx | 210 ++++++++++++++++++ .../Section/overview/ManagedServices.tsx | 62 ++++++ components/Services/Services.tsx | 34 +++ components/provider/ThemeProvider.tsx | 42 ++-- constant/Constant.ts | 7 +- package-lock.json | 10 + package.json | 1 + tailwind.config.ts | 1 + tsconfig.json | 1 + utils/useThemeColors.ts | 10 + 36 files changed, 896 insertions(+), 473 deletions(-) delete mode 100644 components/Helper/Theme.ts delete mode 100644 components/Home/Contact/ContactCTA.tsx delete mode 100644 components/Home/Offer/FullStack.tsx delete mode 100644 components/Home/Offer/ManagedServices.tsx delete mode 100644 components/Home/Offer/Offer.tsx rename components/Home/{About => Sections}/About.tsx (63%) create mode 100644 components/Home/Sections/ContactCTA.tsx rename components/Home/{Hero => Sections}/Hero.tsx (100%) rename components/Home/{ => Sections}/HomeServices.tsx (76%) rename components/Home/{ => Sections}/TechStack.tsx (66%) create mode 100644 components/Section.tsx create mode 100644 components/Services/Section/OverviewTabs.tsx create mode 100644 components/Services/Section/ServiceHero.tsx create mode 100644 components/Services/Section/overview/BugFixing.tsx create mode 100644 components/Services/Section/overview/Consulting.tsx create mode 100644 components/Services/Section/overview/Development.tsx create mode 100644 components/Services/Section/overview/ManagedServices.tsx create mode 100644 components/Services/Services.tsx create mode 100644 utils/useThemeColors.ts diff --git a/app/(root)/layout.tsx b/app/(root)/layout.tsx index 4a3ccb9..518d45e 100644 --- a/app/(root)/layout.tsx +++ b/app/(root)/layout.tsx @@ -6,6 +6,7 @@ import Footer from "@/components/Footer/Footer"; import {ThemeProvider} from "@/components/provider/ThemeProvider"; import React from "react"; import {cookies} from "next/headers"; +import {themeColors} from "@/components/Helper/ThemeColors"; export const metadata: Metadata = { title: "Rhein Software", @@ -19,11 +20,12 @@ export default async function RootLayout({ }>) { const cookieStore = await cookies(); const theme = cookieStore.get("theme")?.value === "dark" ? "dark" : "light"; + const bgColor = themeColors[theme].primaryBg; return ( - +