-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Event feed initialisation #44
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
…coholic into event-feed-frontend
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Outstanding work! I left some suggestions or notes for the future, but it looks great!
@@ -0,0 +1,8 @@ | |||
export default function EventFeedPage() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename the component here
<h2>{e.name}</h2> | ||
<main> | ||
<div className='flex flex-col items-center justify-center bg-green-300'> | ||
<Link href='http://bealcoholic.com'> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't hardcode any URLs, you can just use '/' here, that will redirect to the main page
<div className='w-[61rem]'> | ||
{events.map((event) => ( | ||
<div key={event.id} className='my-4'> | ||
{/* <Link href={`/events/${event.id}`}> */} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this commented out?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ohh I see, the other buttons don't work. I'll show you how it can be fixed
spoiler: https://developer.mozilla.org/en-US/docs/Web/API/Event/stopPropagation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you SO MUCH! I spent hours trying to find the answer without any success.
<Card className='w-48 h-48'> | ||
<CardContent className='flex flex-col aspect-square items-center justify-center p-6 w-auto'> | ||
<span className='text-xl font-semibold no-'>{drinkAction.drink.name}</span> | ||
<span className='text-xs mt-5'>Alcohol Content: {drinkAction.drink.alcoholContent}%</span> | ||
</CardContent> | ||
</Card> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd make this smaller
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is sick!
const [copied, setCopied] = useState(false); | ||
|
||
const handleCopyClick = (id: string) => { | ||
const linkToCopy = `https://bealcoholic.com/events/${id}`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we'll store the actual url in an environment variable, but it's fine for now
<Copy className='h-4 w-4' /> | ||
{copied && <span>Copied!</span>} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some spacing would be nice here
return ( | ||
<Carousel className='w-[51rem]'> | ||
<CarouselContent className='-ml-1'> | ||
{event.drinkActions.map((drinkAction) => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we shouldn't show every drink action here (though it might work with the carousel), would be better to show some stats, like most consumed drinks
<EventDiscription event={event} /> | ||
</div> | ||
<p className='text-gray-600 text-xs mt-2'> | ||
{event.startDate.toLocaleString('hu')} - {event.endDate.toLocaleString('hu')} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be further refined, really no need to display the seconds. Would be even better if the common parts of the two dates (year, month and possibly day) would only be shown once
No description provided.