Update src/app/journal/page.tsx
This commit is contained in:
@@ -7,6 +7,15 @@ import FooterBaseCard from '@/components/sections/footer/FooterBaseCard';
|
||||
import NavbarStyleApple from '@/components/navbar/NavbarStyleApple/NavbarStyleApple';
|
||||
import SocialProofOne from '@/components/sections/socialProof/SocialProofOne';
|
||||
|
||||
// Import component props interfaces for discriminated union
|
||||
import { BlogCardThreeProps } from '@/components/sections/blog/BlogCardThree';
|
||||
import { SocialProofOneProps } from '@/components/sections/socialProof/SocialProofOne';
|
||||
|
||||
// Define a discriminated union type for pageSections to correctly link components with their props
|
||||
type PageSection =
|
||||
| { id: string; Component: typeof BlogCardThree; props: BlogCardThreeProps; }
|
||||
| { id: string; Component: typeof SocialProofOne; props: SocialProofOneProps; };
|
||||
|
||||
export default function LandingPage() {
|
||||
const navItems = [
|
||||
{
|
||||
@@ -35,7 +44,7 @@ export default function LandingPage() {
|
||||
}
|
||||
];
|
||||
|
||||
const pageSections = [
|
||||
const pageSections: PageSection[] = [
|
||||
{
|
||||
id: "journal-articles", Component: BlogCardThree,
|
||||
props: {
|
||||
|
||||
Reference in New Issue
Block a user