Skip to content

Commit

Permalink
more simplification
Browse files Browse the repository at this point in the history
  • Loading branch information
bilalabbad committed Mar 5, 2025
1 parent 4061e84 commit 5253078
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions frontend/app/src/entities/events/ui/event-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ export const EventDetails = ({
);
};

export const EventCard = ({ __typename, ...props }: EventType) => {
export const EventCard = (props: EventType) => {
return (
<div className="flex gap-2">
<TimelineBorder />
Expand All @@ -150,14 +150,12 @@ export const EventCard = ({ __typename, ...props }: EventType) => {

{"attributes" in props && <EventAttributes attributes={props.attributes} />}

{BRANCH_EVENTS.includes(__typename) && <BranchEvent {...props} />}
{BRANCH_EVENTS.includes(props.__typename) && <BranchEvent {...props} />}

{STANDARD_EVENTS.includes(__typename) && <StandardEvent {...props} />}
{STANDARD_EVENTS.includes(props.__typename) && <StandardEvent {...props} />}

<div className="flex justify-between">
<div className="text-xs font-medium text-gray-500 dark:text-neutral-400">
<DateDisplay date={props.occurred_at} />
</div>
<div className="flex justify-between text-gray-500">
<DateDisplay date={props.occurred_at} />

<EventDetailsPopover {...props} />
</div>
Expand Down

0 comments on commit 5253078

Please sign in to comment.