Skip to content

Commit

Permalink
add location to panels
Browse files Browse the repository at this point in the history
  • Loading branch information
kentcdodds committed Sep 20, 2024
1 parent e4ac38f commit 9729f13
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/components/workshop-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,9 @@ function WorkshopCard({
title="Open for registration"
/>
{workshopEvents.length === 1
? workshopEvents[0]?.date
? [workshopEvents[0]?.date, workshopEvents[0]?.location]
.filter(Boolean)
.join(' | ')
: 'Multiple events scheduled'}
</>
) : (
Expand Down
5 changes: 5 additions & 0 deletions app/components/workshop-registration-panel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ function RegistrationPanel({
<h5 className="text-2xl font-medium text-black dark:text-white">
{workshopEvent.title}
</h5>
{workshopEvent.location ? (
<p className="text-secondary inline-block">
Location: {workshopEvent.location}
</p>
) : null}
<div className="flex flex-wrap gap-2">
<p className="text-secondary inline-block">{workshopEvent.date}</p>
<span>{hasDiscounts ? ' | ' : null}</span>
Expand Down

0 comments on commit 9729f13

Please sign in to comment.