Skip to content

Commit

Permalink
Fixed prettier issues with ClubDirectoryGrid.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
ishaanthenerd committed Oct 23, 2024
1 parent ca9838c commit 7217fea
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 13 deletions.
7 changes: 2 additions & 5 deletions src/components/CommunityEvents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,13 @@ const CommunityEvents = ({ events }: Props) => {
}
return (
<div
className="group flex flex-row overflow-x-auto place-content-start items-center pt-4 sm:items-start"
className="group flex flex-row place-content-start items-center overflow-x-auto pt-4 sm:items-start"
data-view={'list'}
>
{events.map((event) => (

// let's see if this works
<div className="flex flex-shrink-0 items-center pr-4">
<div className="flex flex-shrink-0 items-center pr-4" key={event.id}>
<EventCard key={event.id} event={event} />
</div>

))}
</div>
);
Expand Down
9 changes: 3 additions & 6 deletions src/components/OrgDirectoryCarousel.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
'use client';

import { useRef, type FC } from 'react';
import React, { useState } from 'react';
import { type FC } from 'react';
import React from 'react';
import { type Session } from 'next-auth';
import { type SelectClub } from '@src/server/db/models';
import { LeftArrowIcon, RightArrowIcon } from '@src/icons/Icons';
import ClubCard from './club/ClubCard';

type Props = {
Expand All @@ -18,9 +17,7 @@ const OrgDirectoryCarousel: FC<Props> = ({ clubs, session }) => {
<div className="carousel-container relative flex w-full flex-col">
<div className="carousel-wrapper relative flex w-full">
<div className="carousel-content-wrapper h-full w-full overflow-hidden">
<div
className="carousel-content flex w-full flex-shrink-0 flex-grow overflow-x-auto"
>
<div className="carousel-content flex w-full flex-shrink-0 flex-grow overflow-x-auto">
{clubs.map((club) => (
<div className="py-8 pr-8" key={club.id}>
<ClubCard
Expand Down
5 changes: 3 additions & 2 deletions src/components/club/directory/ClubDirectoryGrid.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import { type FC } from 'react';
import ClubCard from '../ClubCard';
import { api } from '@src/trpc/server';
import { getServerAuthSession } from '@src/server/auth';
import InfiniteScrollGrid from './InfiniteScrollGrid';
import ScrollTop from './ScrollTop';
import { SelectClub } from '@src/server/db/models';
import { FC } from 'react';

interface Props {
tag?: string;
Expand All @@ -15,7 +16,7 @@ const ClubDirectoryGrid: FC<Props> = async ({ tag }) => {

return (
<div className="grid w-full auto-rows-fr grid-cols-[repeat(auto-fill,320px)] justify-center gap-16 pb-4">
{clubs.map((club) => (
{clubs.map((club: SelectClub) => (
<ClubCard key={club.id} club={club} session={session} priority />
))}
{clubs.length === 9 && <InfiniteScrollGrid tag={tag} session={session} />}
Expand Down

0 comments on commit 7217fea

Please sign in to comment.