-
Notifications
You must be signed in to change notification settings - Fork 0
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
16 changed files
with
216 additions
and
62 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,12 @@ | ||
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app). | ||
# Welcome to my First Next.js Project | ||
|
||
## Getting Started | ||
I hope you find this project to look at. Been coding in Reactjs for sometime now, and just wondered how Next.js would be like?!! | ||
|
||
First, run the development server: | ||
# Here's what I found | ||
|
||
```bash | ||
npm run dev | ||
# or | ||
yarn dev | ||
# or | ||
pnpm dev | ||
# or | ||
bun dev | ||
``` | ||
- Next.js is exceptional [nothing kike I've seen before] | ||
|
||
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. | ||
|
||
You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file. | ||
|
||
This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font. | ||
|
||
## Learn More | ||
|
||
To learn more about Next.js, take a look at the following resources: | ||
|
||
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API. | ||
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial. | ||
|
||
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome! | ||
|
||
## Deploy on Vercel | ||
|
||
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js. | ||
|
||
Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details. | ||
- The new `app` router be something else | ||
- I wish I started using it earlier (isn't so late though) | ||
- Has in built optimization for images using `<Image />` from `next/image` | ||
- Same for links using `<Link />` from `next/link` |
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
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
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
This file was deleted.
Oops, something went wrong.
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,28 @@ | ||
import { cardData } from "@/src/utils/cardData"; | ||
import React from "react"; | ||
import styles from "./card.module.css"; | ||
import { CardData } from "@/src/utils/cardData"; | ||
import Image from "next/image"; | ||
|
||
export const Cards = () => { | ||
const imageDimensions = 75; | ||
|
||
return ( | ||
<div className={styles.container}> | ||
{cardData.map((card: CardData) => ( | ||
<div key={card.id} className={styles.card_content}> | ||
<div> | ||
<Image | ||
src={card.image} | ||
alt={card.alt} | ||
width={imageDimensions} | ||
height={imageDimensions} | ||
/> | ||
</div> | ||
<h1 className={styles.card_title}>{card.title}</h1> | ||
<p className={styles.card_description}>{card.desc}</p> | ||
</div> | ||
))} | ||
</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,35 @@ | ||
.container { | ||
margin-top: 6em; | ||
display: grid; | ||
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); | ||
gap: 1.5em; | ||
} | ||
|
||
.card_content { | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
flex-direction: column; | ||
gap: 1.5em; | ||
transition: scale 300ms ease; | ||
border-radius: .5rem; | ||
padding: 1.5em; | ||
} | ||
|
||
.card_content:hover { | ||
scale: 1.1; | ||
outline: 1px solid var(--green); | ||
} | ||
|
||
|
||
.card_title { | ||
font-weight: 600; | ||
font-size: 1.5rem; | ||
} | ||
|
||
.card_description { | ||
text-align: center; | ||
color: var(--dull-white); | ||
font-size: 1.2rem; | ||
width: 85%; | ||
} |
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,23 @@ | ||
import styles from "./user.module.css"; | ||
import Image from "next/image"; | ||
|
||
interface UserProps { | ||
image: string; | ||
name: string; | ||
} | ||
|
||
export const User = ({ image, name }: UserProps) => { | ||
return ( | ||
<div className={styles.container}> | ||
<div className={styles.image_container}> | ||
<Image src={image} alt={name} fill /> | ||
</div> | ||
<div className={styles.text_container}> | ||
<h3>{name}</h3> | ||
<p> | ||
Rated: <b>4.5 stars</b> | ||
</p> | ||
</div> | ||
</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,23 @@ | ||
.container { | ||
display: flex; | ||
align-items: center; | ||
gap: 1em; | ||
} | ||
|
||
.image_container { | ||
position: relative; | ||
width: 50px; | ||
aspect-ratio: 1; | ||
border-radius: 50%; | ||
outline: 3px solid var(--light-gray); | ||
box-shadow: 3px 4px 15px rgb(0 0 0 / 0.5); | ||
overflow: clip; | ||
} | ||
|
||
.image_container img { | ||
object-fit: cover; | ||
} | ||
|
||
.text_container h3 { | ||
font-weight: 300; | ||
} |
This file was deleted.
Oops, something went wrong.
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,31 @@ | ||
export interface CardData { | ||
id: number; | ||
image: string; | ||
title: string; | ||
desc: string; | ||
alt: string; | ||
} | ||
|
||
export const cardData: CardData[] = [ | ||
{ | ||
id: 1, | ||
image: "/cards-icon.png", | ||
title: "Customizable card", | ||
desc: "Custom your own card for your exact incomes and expenses needs.", | ||
alt: "Custom card", | ||
}, | ||
{ | ||
id: 2, | ||
image: "/coin-icon.png", | ||
title: "No payment fee", | ||
desc: "Transfer your payment all over the world with no payment fee.", | ||
alt: "Payment", | ||
}, | ||
{ | ||
id: 3, | ||
image: "/purse-icon.png", | ||
title: "All in one place", | ||
desc: "The right place to keep your credit and debit cards, boarding passes & more. ", | ||
alt: "One place", | ||
}, | ||
]; |