Skip to content

Commit

Permalink
feat: section title 공통 컴포넌트 작성
Browse files Browse the repository at this point in the history
  • Loading branch information
YOOJS1205 committed Apr 20, 2024
1 parent b2ae49b commit 590d2b8
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/components/SectionTitleV2/SectionTitleV2.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { ReactNode } from 'react';
import { css, SerializedStyles, Theme } from '@emotion/react';

interface SectionTitleV2Props {
children: ReactNode;
style?: SerializedStyles | ((theme: Theme) => SerializedStyles);
}

export function SectionTitleV2({ children, style }: SectionTitleV2Props) {
return <div css={[sectionTitleCss, style]}>{children}</div>;
}

const sectionTitleCss = css`
display: flex;
width: 100%;
height: 40px;
padding: 12px 24px;
justify-content: center;
align-items: center;
gap: 4px;
`;
1 change: 1 addition & 0 deletions src/components/SectionTitleV2/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { SectionTitleV2 } from './SectionTitleV2';

0 comments on commit 590d2b8

Please sign in to comment.