Skip to content
This repository has been archived by the owner on Dec 6, 2024. It is now read-only.

Commit

Permalink
Merge pull request #86 from nexlabsweb3/fix_navbar
Browse files Browse the repository at this point in the history
chore: fix layout
  • Loading branch information
EjembiEmmanuel authored Nov 30, 2024
2 parents d644d3f + 30d1d9f commit a30cdd5
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 32 deletions.
9 changes: 2 additions & 7 deletions frontend/src/app/Home/page.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
import Footer from '@/components/Footer';
import NavBar from '@/components/Navbar';
import React from 'react';
import ManufacturerPage from '../manufacturer/account/page';
import HeroSection from '@/components/HeroSection';
import ContentSection from '@/components/ContentSection';

const page = () => {
return (
<div>
<HeroSection />
<ContentSection />
{/* <HeroSection />
<ContentSection /> */}
</div>
);
};
Expand Down
13 changes: 0 additions & 13 deletions frontend/src/app/Home/scan/page.tsx

This file was deleted.

15 changes: 8 additions & 7 deletions frontend/src/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
'use client';

import ContentSection from '@/components/ContentSection';
import Footer from '@/components/Footer';
import HeroSection from '@/components/HeroSection';
import NavBar from '@/components/Navbar';
import { useRouter } from 'next/navigation';
import { useEffect } from 'react';
import Layout from './Home/layout';

export default function Home() {
const router = useRouter();
useEffect(() => {
router.push('/Home');
});
return <main className=""></main>;

return (
<Layout>
<HeroSection />
<ContentSection />
</Layout>
);
}
13 changes: 8 additions & 5 deletions frontend/src/app/scan/[product]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import ScanProduct from '@/components/Scan';
import ConnectModal from '@/components/ConnectModal';
import { useParams } from 'next/navigation';
import ProductPreview from '@/components/ProductPreview';
import Layout from '@/app/Home/layout';

export default function ScanPage() {
const { address } = useAccount();
Expand All @@ -25,11 +26,13 @@ export default function ScanPage() {
}, [product]);

return (
<main className=" w-full md:h-fit bg-product-overview-mobile md:bg-product-overview bg-no-repeat bg-cover bg-center pb-[80px]">
<ProductPreview productId="product" />
{open && <ScanProduct />}
<Layout>
<main className=" w-full md:h-fit bg-product-overview-mobile md:bg-product-overview bg-no-repeat bg-cover bg-center pb-[80px]">
<ProductPreview productId="product" />
{open && <ScanProduct />}

<ConnectModal isOpen={openConnectedModal} onClose={toggleUserModal} />
</main>
<ConnectModal isOpen={openConnectedModal} onClose={toggleUserModal} />
</main>
</Layout>
);
}

0 comments on commit a30cdd5

Please sign in to comment.