From 85bfbeb11a927a7eef6c0d56f4ce8a0906a32073 Mon Sep 17 00:00:00 2001 From: hae-on Date: Sat, 13 Apr 2024 12:29:24 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20top=20bar=20logo=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Common/TopBar/TopBar.stories.tsx | 11 +++++++++++ src/components/Common/TopBar/TopBar.tsx | 11 +++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/components/Common/TopBar/TopBar.stories.tsx b/src/components/Common/TopBar/TopBar.stories.tsx index f65c98a5..93b27658 100644 --- a/src/components/Common/TopBar/TopBar.stories.tsx +++ b/src/components/Common/TopBar/TopBar.stories.tsx @@ -22,6 +22,17 @@ export const Default: Story = { }, }; +export const Logo: Story = { + render: (args) => { + return ( + + + + + ); + }, +}; + export const CenterTitleAndSearch: Story = { render: (args) => { return ( diff --git a/src/components/Common/TopBar/TopBar.tsx b/src/components/Common/TopBar/TopBar.tsx index 77e647cd..5197fa3b 100644 --- a/src/components/Common/TopBar/TopBar.tsx +++ b/src/components/Common/TopBar/TopBar.tsx @@ -4,9 +4,11 @@ import { LeftNavigationWrapper, container, headerTitle, leftTitle } from './topB import SvgIcon from '../Svg/SvgIcon'; import Text from '../Text/Text'; +import LogoImage from '@/assets/logo.svg'; import { PATH } from '@/constants/path'; import { vars } from '@/styles/theme.css'; + interface TopBarProps { children?: React.ReactNode; title?: string; @@ -18,6 +20,14 @@ const TopBar = ({ children }: TopBarProps) => { return
{children}
; }; +const Logo = () => { + return ( + + + + ); +}; + const BackLink = ({ state }: TopBarProps) => { return ( @@ -70,6 +80,7 @@ const Spacer = () => { return
; }; +TopBar.Logo = Logo; TopBar.BackLink = BackLink; TopBar.LeftNavigationGroup = LeftNavigationGroup; TopBar.Title = Title;