Skip to content
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions components/Tickets/ticketCards.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,15 @@ function TicketCards({ className, city }) {
const buttonText = city.isFree ? 'Get Your Ticket' : 'Buy Now';

return (
<div className={`w-[300px] lg:w-full ${cardOpacity} hoverEffect h-[400px] cursor-pointer flex flex-col text-white justify-between rounded-lg card bg-white ${className}`}>
<div className='p-4'>
<div className='text-xl font-bold text-gradient'>{city.name}, {city.country}</div>
<div className='mt-2 text-lg'>{city.date}</div>
<div className={`w-[300px] lg:w-full ${cardOpacity} hoverEffect h-[400px] cursor-pointer flex flex-col text-white justify-between rounded-lg card bg-white lg:m-0 m-4 ${className}`}>
<div className="p-4 h-[100%] bg-cover relative">
<div className="absolute inset-0 bg-cover" style={{ backgroundImage: `url(${city.img})`, opacity: 0.2, zIndex: -1 }}></div>
<div className='text-xl font-bold text-gradient'>{city.name}, {city.country}
</div>
<div className='mt-2 text-lg mb-2'>{city.date}</div>
<p className='border-t pt-2'>{city.description}</p>
</div>

<div className='flex justify-center border-t h-20 border-dashed p-4 text-center'>
{/* Show a button based on the event status */}
{isEndedOrUpcoming ? (
Expand Down
2 changes: 1 addition & 1 deletion config/city-lists.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,6 @@
],
"ticket": false,
"isFree": true,
"ended": true
"ended": false
}
]
9 changes: 5 additions & 4 deletions pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,12 @@ export default function Home() {
Experience the Future of Asynchronous Communication: Get Tickets for the AsyncAPI Conference on Tour!
</Paragraph>
</div>
<div className='w-[1000px] lg:w-full mt-10 flex justify-between lg:flex-col'>
{cities.map((city) => {
if(city.ended === false){
<div className='w-[1000px] lg:w-full mt-10 flex justify-between lg:flex-col flex-wrap'>
{cities.filter((x)=>x.ended == false).map((city) => {
return <TicketCards key={city.name} city={city} className='lg:mt-10' />
})}
{cities.filter((x)=>x.ended == true).map((city) => {
return <TicketCards key={city.name} city={city} className='lg:mt-10' />
}
})}
</div>
</div>
Expand Down