-
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.
Merge pull request #96 from UoaWDCC/065_home-page-connector-gap
065 home page connector gap
- Loading branch information
Showing
8 changed files
with
91 additions
and
105 deletions.
There are no files selected for viewing
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
Empty file.
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,21 @@ | ||
export default function GridPage() { | ||
return ( | ||
<div className="border border-green-500 grid grid-cols-2 gap-4"> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-green-500 col-start-2 col-span-2 row-start-4 border border-pink-400"> | ||
Grid Page | ||
</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
<h1 className="text-red-500">Grid Page</h1> | ||
</div> | ||
); | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { ReactNode } from "react"; | ||
import RichText from "../blocks/RichText"; | ||
|
||
type BlobProps = { | ||
children: ReactNode; | ||
className?: string; | ||
}; | ||
|
||
export default function Blob({ children, className = "" }: BlobProps) { | ||
// If children is a string, render it as a RichText component | ||
const richChildren = <RichText props={{ text: children }} />; | ||
children = children instanceof String ? richChildren : children; | ||
|
||
return ( | ||
<div | ||
className={`block rounded-3xl text-blue-950 text-lg p-8 [&_:is(h1, h2, h3)]:text-xl [&_:is(h1, h2, h3)]:font-bold ${className}`} | ||
> | ||
{children} | ||
</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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import connector from "@/assets/home/connector.svg"; | ||
import Image from "next/image"; | ||
|
||
export default function ConnectorBlob({ | ||
className = "", | ||
}: { | ||
className?: string; | ||
}) { | ||
return ( | ||
<Image | ||
draggable={false} | ||
className={className} | ||
src={connector} | ||
alt="" | ||
width={60} | ||
height={32} | ||
/> | ||
); | ||
} |
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,36 +1,26 @@ | ||
import connector from "@/assets/home/connector.svg"; | ||
import React from "react"; | ||
import RichText from "../blocks/RichText"; | ||
import Blob from "./Blob"; | ||
import ConnectorBlob from "./ConnectorBlob"; | ||
import styles from "./HomePageBlob.module.css"; | ||
import Image from "next/image"; | ||
|
||
const HomePageBlob: React.FC<{ | ||
type Props = { | ||
blob1: string; | ||
blob2: string; | ||
blob3: string; | ||
}> = ({ blob1, blob2, blob3 }) => { | ||
}; | ||
|
||
export default function HomePageBlobs({ blob1, blob2, blob3 }: Props) { | ||
return ( | ||
<div className={styles.container}> | ||
<div className={`${styles.blob} ${styles.whiteBlob} ${styles.blob1}`}> | ||
<RichText props={{ text: blob1 }} /> | ||
<Image | ||
draggable={false} | ||
className={styles.connector} | ||
src={connector} | ||
alt="" | ||
width={60} | ||
height={32} | ||
/> | ||
</div> | ||
<div className={`${styles.blob} ${styles.whiteBlob} ${styles.blob2}`}> | ||
<div | ||
className={`${styles.container} grid grid-cols-14 my-24 p-5 drop-shadow-xl`} | ||
> | ||
<Blob className="bg-white col-start-8 col-span-4">{blob1}</Blob> | ||
<ConnectorBlob className="col-start-10 col-end-12 justify-self-center hidden md:block" /> | ||
<Blob className="bg-white col-start-10 col-span-4"> | ||
<RichText props={{ text: blob2 }} /> | ||
<button className={styles.button}>JOIN US NOW</button> | ||
</div> | ||
<div className={`${styles.blob} ${styles.orangeBlob} ${styles.blob3}`}> | ||
<RichText props={{ text: blob3 }} /> | ||
</div> | ||
</Blob> | ||
<Blob className="bg-[#ffaa00] text-black row-start-4 col-start-2 col-span-4">{blob3}</Blob> | ||
</div> | ||
); | ||
}; | ||
|
||
export default HomePageBlob; | ||
} |