From eed561b298c530d3c3cc81695fdf4d1a0c204836 Mon Sep 17 00:00:00 2001 From: bae-sh Date: Sun, 14 Jan 2024 23:42:14 +0900 Subject: [PATCH] =?UTF-8?q?chore:=20home=20layout.tsx=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/app/(home)/layout.tsx | 6 +- client/src/app/(home)/page.tsx | 4 +- .../components/ErrorFallback/index.stories.ts | 68 ------------------- 3 files changed, 7 insertions(+), 71 deletions(-) delete mode 100644 client/src/components/ErrorFallback/index.stories.ts diff --git a/client/src/app/(home)/layout.tsx b/client/src/app/(home)/layout.tsx index ca088b9d..e0f5fd11 100644 --- a/client/src/app/(home)/layout.tsx +++ b/client/src/app/(home)/layout.tsx @@ -6,5 +6,9 @@ export default function LayoutComponent({ }: { children: React.ReactNode; }) { - return {children}; + return ( + +
{children}
+
+ ); } diff --git a/client/src/app/(home)/page.tsx b/client/src/app/(home)/page.tsx index 134ed685..c8076215 100644 --- a/client/src/app/(home)/page.tsx +++ b/client/src/app/(home)/page.tsx @@ -13,7 +13,7 @@ export default async function Home() { const data = await getAllPosts({}); return ( -
+ <>
}> @@ -21,6 +21,6 @@ export default async function Home() {
-
+ ); } diff --git a/client/src/components/ErrorFallback/index.stories.ts b/client/src/components/ErrorFallback/index.stories.ts deleted file mode 100644 index 0d26438b..00000000 --- a/client/src/components/ErrorFallback/index.stories.ts +++ /dev/null @@ -1,68 +0,0 @@ -import type { Meta, StoryObj } from '@storybook/react'; - -import ErrorFallback from './index'; - -const meta: Meta = { - title: 'Components/common/ErrorFallback', - component: ErrorFallback, - tags: ['autodocs'], - parameters: { - componentSubtitle: '에러가 발생했을 때 보여주는 컴포넌트입니다.', - }, - argTypes: { - error: { - description: '에러 객체로, 에러메세지를 가지고 있습니다.', - table: { - type: { - summary: 'Error', - }, - }, - }, - hasHomeButton: { - description: '홈으로 가는 버튼이 있는지 여부입니다.', - table: { - type: { - summary: 'boolean', - }, - defaultValue: { - summary: false, - }, - }, - }, - resetErrorBoundary: { - description: '에러를 리셋하는 함수입니다.', - table: { - type: { - summary: 'function', - }, - }, - }, - }, -}; - -export default meta; -type Story = StoryObj; - -export const Primary: Story = { - args: { error: { message: 'Error Message' } }, - parameters: { - docs: { - description: { - story: - '가장 기본적인 에러 컴포넌트입니다. 일반적인 에러 발생 시 사용합니다.', - }, - }, - }, -}; - -export const NotFound: Story = { - args: { error: { message: 'POST_NOT_EXIST' } }, - parameters: { - docs: { - description: { - story: - '존재하지 않는 게시글을 요청했을 때 보여주는 에러 컴포넌트입니다.', - }, - }, - }, -};