-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add register component, hero tweaks and prettier fix
- Loading branch information
1 parent
3ea22ec
commit 412bf22
Showing
7 changed files
with
62 additions
and
34 deletions.
There are no files selected for viewing
50 changes: 27 additions & 23 deletions
50
app/(transition)/(root)/events/[id]/_components/Hero/Hero.tsx
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,27 +1,31 @@ | ||
// import { FC } from 'react'; | ||
import { MapPinIcon } from '@heroicons/react/24/solid' | ||
import { FC } from 'react'; | ||
import { MapPinIcon } from '@heroicons/react/24/solid'; | ||
import { HeroTypes } from './types'; | ||
|
||
// export const Hero = ({ name, image, organizer, datime, location }) => ( | ||
export const Hero = () => ( | ||
<section className={`flex h-80 w-full place-items-end bg-[url('https://www.slingacademy.com/wp-content/uploads/2022/10/hero-image-example.webp')] md:h-96`}> | ||
<div className="mx-auto flex w-full max-w-screen-xl px-4 py-8 md:grid-cols-12 lg:gap-8 xl:gap-0"> | ||
<div className="mr-auto flex w-full flex-col place-self-center"> | ||
<h1 className="mb-4 max-w-2xl text-2xl font-extrabold leading-none tracking-tight dark:text-white md:text-4xl"> | ||
Javascript Meetup — Enero | ||
</h1> | ||
<div className="flex w-full justify-between"> | ||
<div className="flex grow flex-col"> | ||
<p className='font-thin'>por <span className='underline'>Javascript Chile</span></p> | ||
<p className='font-thin'>Jueves, 27 Enero, 2024 | 6:30 PM</p> | ||
</div> | ||
<div className="hidden md:flex md:max-w-xs md:items-center md:gap-2"> | ||
<MapPinIcon className="h-8 w-8" /> | ||
<p> | ||
Hub Providencia, Calle Falsa, 1234, Santiago | ||
</p> | ||
export const Hero: FC<HeroTypes> = ({ name, organizer, datetime, location }) => { | ||
return ( | ||
<section className={`flex h-80 w-full place-items-end bg-[url(https://images.unsplash.com/photo-1604014237800-1c9102c219da?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1770&q=80)] bg-cover bg-center bg-no-repeat md:h-96`}> | ||
<div className='flex h-full w-full flex-col justify-end bg-slate-100/75 dark:bg-slate-900/75'> | ||
<div className="mx-auto flex w-full max-w-screen-xl px-4 py-8 md:grid-cols-12 lg:gap-8 xl:gap-0"> | ||
<div className="mr-auto flex w-full flex-col place-self-center"> | ||
<h1 className="mb-4 max-w-2xl text-xl font-extrabold leading-none tracking-tight dark:text-white md:text-4xl"> | ||
{name} | ||
</h1> | ||
<div className="flex w-full justify-between"> | ||
<div className="flex grow flex-col"> | ||
<p className='font-thin'>por <span className='underline'>{organizer}</span></p> | ||
<p className='font-thin'>{datetime}</p> | ||
</div> | ||
<div className="hidden md:flex md:max-w-xs md:items-center md:gap-2"> | ||
<MapPinIcon className="h-8 w-8" /> | ||
<p> | ||
{location} | ||
</p> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</section> | ||
); | ||
</section> | ||
); | ||
}; |
1 change: 0 additions & 1 deletion
1
app/(transition)/(root)/events/[id]/_components/Hero/types.d.ts
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,6 +1,5 @@ | ||
export type HeroTypes = { | ||
name: string; | ||
image: string; | ||
location: string; | ||
organizer: string; | ||
datetime: string; | ||
|
22 changes: 22 additions & 0 deletions
22
app/(transition)/(root)/events/[id]/_components/Register/Register.tsx
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,22 @@ | ||
import { Button } from '@/components/ui/button'; | ||
import { InformationCircleIcon } from '@heroicons/react/24/outline'; | ||
|
||
export const Register = () => { | ||
return ( | ||
<section className="flex w-full flex-col gap-2 bg-slate-900 p-6 dark:bg-slate-50"> | ||
<h2 className="text-xl text-slate-50 dark:text-slate-900 md:text-4xl">Registro</h2> | ||
<ol> | ||
<li className="flex content-center gap-2 text-slate-50 dark:text-slate-900"> | ||
<InformationCircleIcon className="h-6 w-6 shrink-0" /> | ||
<span className="text-sm italic">El evento requiere aprobación de los organizadores</span> | ||
</li> | ||
<li className="flex content-center gap-2 text-slate-50 dark:text-slate-900"> | ||
<InformationCircleIcon className="h-6 w-6 shrink-0" /> | ||
<span className="text-sm italic">Apúrate! Quedan pocas entradas</span> | ||
</li> | ||
</ol> | ||
<p className="text-slate-50 dark:text-slate-900">Para registrarte, por favor haz click en el botón.</p> | ||
<Button variant={'secondary'} size={'lg'}>Registrarse</Button> | ||
</section> | ||
); | ||
}; |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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
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