-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
53 changed files
with
458 additions
and
107 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,38 @@ | ||
import { Metadata } from 'next'; | ||
import config from '@payload-config'; | ||
import React from 'react'; | ||
import { getPayload } from 'payload'; | ||
import { RichText } from '@/src/components/typography'; | ||
import configPromise from '@payload-config'; | ||
import { AboutBlock } from '@/src/components/blocks'; | ||
|
||
export const metadata: Metadata = { | ||
description: 'About Aman Singh Bhogal', | ||
title: 'About | Aman Singh Bhogal', | ||
}; | ||
|
||
export default async function Page() { | ||
// const { about: aboutData } = await getAboutData(); | ||
|
||
const payload = await getPayload({ | ||
config, | ||
config: configPromise, | ||
}); | ||
|
||
const data = await payload.find({ | ||
collection: 'pages', | ||
where: { | ||
title: { | ||
equals: 'About', | ||
}, | ||
}, | ||
}); | ||
|
||
const data = await payload | ||
.find({ | ||
collection: 'pages', | ||
}) | ||
.then((results) => results.docs[2]); | ||
const { docs } = data; | ||
|
||
// eslint-disable-next-line no-console | ||
console.log(data); | ||
return ( | ||
<React.Fragment> | ||
<p>About</p> | ||
{/* <AboutCover /> | ||
<AboutSection aboutData={aboutData} /> | ||
<CTA /> */} | ||
</React.Fragment> | ||
<div> | ||
<h1>{docs[0].title}</h1> | ||
{/* @ts-expect-error resolve type mismatch */} | ||
<RichText content={docs[0]?.layout?.[0].Content || []} /> | ||
{/* @ts-expect-error resolve type mismatch */} | ||
<AboutBlock history={docs[0]?.layout?.[1].about} /> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
export declare const arrowDown: string; | ||
export declare const image: string; | ||
export declare const imageContainer: string; | ||
export declare const stacksList: string; | ||
export declare const title: string; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
import { Page } from '@/payload-types'; | ||
import dayjs from 'dayjs'; | ||
import styles from './styles.module.scss'; | ||
|
||
type AboutBlock = Extract<NonNullable<Page['layout']>[number], { blockType: 'about-block' }>; | ||
|
||
interface Props { | ||
history: AboutBlock['about']; | ||
} | ||
|
||
export const AboutBlock = ({ history }: Props) => ( | ||
<ul className={styles.containerOuter}> | ||
{history?.map((event) => ( | ||
<li | ||
className={styles.container} | ||
key={event.id} | ||
> | ||
<div className={styles.containerInner}> | ||
<p className={styles.date}>{dayjs(event.date).format('MMM YYYY')}</p> | ||
<p className={styles.position}> | ||
{event.position} | ||
</p> | ||
<p className={styles.company}>{event.company}</p> | ||
</div> | ||
<div className={styles.containerInner}> | ||
<ul className={styles.stacks}> | ||
{event?.stacks?.map((stack) => ( | ||
<li | ||
className={styles.stack} | ||
key={stack.id} | ||
> | ||
{stack.stack} | ||
</li> | ||
))} | ||
</ul> | ||
<ul className={styles.responsibilities}> | ||
{event?.responsibilities?.map((responsibility) => ( | ||
<li | ||
className={styles.responsibility} | ||
key={responsibility.id} | ||
> | ||
{responsibility.responsibility} | ||
</li> | ||
))} | ||
</ul> | ||
</div> | ||
|
||
</li> | ||
))} | ||
</ul> | ||
); |
Oops, something went wrong.