Skip to content

Commit

Permalink
feat: 섹션 구분선 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
Leejin-Yang committed Mar 19, 2024
1 parent 4981897 commit 509863c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 deletions.
23 changes: 13 additions & 10 deletions src/pages/ProductPage/ProductPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Spacing } from '@fun-eat/design-system';
import { useQueryErrorResetBoundary } from '@tanstack/react-query';
import { Suspense } from 'react';

import { productSection } from './productPage.css';
import { categorySection, productSection } from './productPage.css';

import {
Loading,
Expand Down Expand Up @@ -35,15 +35,18 @@ export const ProductPage = () => {
return (
<>
<TabMenu tabMenus={TAB_MENUS} selectedTabMenu={selectedTabMenu} handleTabMenuSelect={handleTabMenuClick} />
<Spacing size={28} />
<Suspense fallback={null}>
{selectedTabMenu === TAB_MENUS[0].value ? (
<CategoryFoodList location="products" hasName isCircular />
) : (
<CategoryStoreList location="products" hasName isBordered />
)}
</Suspense>
<Spacing size={12} />

<section className={categorySection}>
<Suspense fallback={null}>
{selectedTabMenu === TAB_MENUS[0].value ? (
<CategoryFoodList location="products" hasName isCircular />
) : (
<CategoryStoreList location="products" hasName isBordered />
)}
</Suspense>
</section>

<div style={{ height: '12px', backgroundColor: '#f9f9f9' }} aria-hidden />

<ErrorBoundary fallback={ErrorComponent} handleReset={reset}>
<Suspense fallback={<Loading />}>
Expand Down
4 changes: 4 additions & 0 deletions src/pages/ProductPage/productPage.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ export const menuName = styleVariants({
default: [menuNameBase, { fontWeight: 600, color: '#999' }],
});

export const categorySection = style({
margin: '28px 0 24px',
});

export const productSection = style({
margin: '28px 0 32px',
});
Expand Down

0 comments on commit 509863c

Please sign in to comment.