Skip to content

Commit

Permalink
style: 스켈레톤 ul 제거
Browse files Browse the repository at this point in the history
  • Loading branch information
hyoribogo committed Nov 25, 2023
1 parent 460cf6e commit a63ed03
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/pages/MainPage/components/CreatedReviewList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ const CreatedReviewList = ({
{...review}
/>
))}
{isFetchingNextPage && <ListSkeleton />}
<div ref={ref}></div>
</ul>
{isFetchingNextPage && <ListSkeleton />}
</>
)
}
Expand Down
3 changes: 1 addition & 2 deletions src/pages/MainPage/components/InvitedReviewList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,9 @@ const InvitedReviewList = ({ handleClickReview }: InvitedReviewListProps) => {
{...review}
/>
))}

{isFetchingNextPage && <ListSkeleton />}
<div ref={ref}></div>
</ul>
{isFetchingNextPage && <ListSkeleton />}
</>
)
}
Expand Down
4 changes: 2 additions & 2 deletions src/pages/MainPage/components/ListSkeleton/index.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
const ListSkeleton = () => {
return (
<ul className="grid grid-cols-2 gap-8 sm:grid-cols-3 md:grid-cols-4 md:gap-10">
<>
<li className="skeleton h-36 rounded-md md:h-40"></li>
<li className="skeleton h-36 rounded-md md:h-40"></li>
<li className="skeleton h-36 rounded-md md:h-40"></li>
<li className="skeleton h-36 rounded-md md:h-40"></li>
</ul>
</>
)
}

Expand Down
2 changes: 1 addition & 1 deletion src/pages/MainPage/components/ReceivedReviewList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ const ReceivedReviewList = ({ handleClickReview }: ReceivedReviewListProps) => {
{...review}
/>
))}
{isFetchingNextPage && <ListSkeleton />}
<div ref={ref}></div>
</ul>
{isFetchingNextPage && <ListSkeleton />}
</>
)
}
Expand Down
8 changes: 7 additions & 1 deletion src/pages/MainPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,13 @@ const MainPage = () => {
</div>
</PageIntro>

<Suspense fallback={<ListSkeleton />}>
<Suspense
fallback={
<ul className="grid grid-cols-2 gap-8 sm:grid-cols-3 md:grid-cols-4 md:gap-10">
<ListSkeleton />
</ul>
}
>
{(() => {
switch (activeTab) {
case 'invited':
Expand Down

0 comments on commit a63ed03

Please sign in to comment.