Skip to content

Commit

Permalink
Merge pull request #501 from pieces-app/community-events-filter-fi
Browse files Browse the repository at this point in the history
fix(EventCarousel): normalize event filter comparison
  • Loading branch information
mason-at-pieces authored Jul 21, 2024
2 parents 2d5ef0f + 27c545d commit 9fbfe0f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/EventCarousel/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React, {useEffect, useState} from 'react';
import CTAButton from "@site/src/components/CTAButton";
import { log } from 'console';

type Event = {
type: 'All' | 'Podcast' | 'Twitter Space' | 'Livestream' | 'Meetup'
Expand Down Expand Up @@ -106,7 +107,7 @@ const EventCarousel = () => {
{categories.map((category, index) => (
<span
key={index}
className={`category ${eventTypeFilter === category.toLowerCase() ? 'active' : ''}`}
className={`category ${eventTypeFilter.toLowerCase() === category.toLowerCase() ? 'active' : ''}`}
onClick={() => setEventTypeFilter(category.toLowerCase() as Event['type'])}
>
{category}
Expand Down

1 comment on commit 9fbfe0f

@vercel
Copy link

@vercel vercel bot commented on 9fbfe0f Jul 21, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.