-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #319 from sharemindteam/feat/add_empty_view_317
[Feat] empty section 공통 컴포넌트 구현 및 결제내역, 리뷰 내역에 적용
- Loading branch information
Showing
3 changed files
with
252 additions
and
136 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import styled from 'styled-components'; | ||
import { Body2, Heading } from 'styles/font'; | ||
import { ReactComponent as Empty } from 'assets/icons/graphic-noting.svg'; | ||
import { Space } from './Space'; | ||
|
||
// | ||
// | ||
// | ||
|
||
interface EmptySectionProps { | ||
title?: string; | ||
subtitle?: string; | ||
} | ||
|
||
// | ||
// | ||
// | ||
|
||
const EmptySection = ({ title, subtitle }: EmptySectionProps) => { | ||
return ( | ||
<EmptyWrapper> | ||
<EmptyIcon /> | ||
{title ? <Heading>{title}</Heading> : null} | ||
<Space height="1.5rem" /> | ||
{subtitle ? ( | ||
<Body2 style={{ whiteSpace: 'pre-wrap', textAlign: 'center' }}> | ||
{subtitle} | ||
</Body2> | ||
) : null} | ||
</EmptyWrapper> | ||
); | ||
}; | ||
|
||
// | ||
// | ||
// | ||
|
||
const EmptyWrapper = styled.div` | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
`; | ||
|
||
const EmptyIcon = styled(Empty)` | ||
margin-top: 20vh; | ||
padding: 4.5rem; | ||
`; | ||
|
||
export default EmptySection; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.