-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feat/#296] 회의 생성 전 확인 바텀시트 구현 #313
Merged
Merged
Changes from 5 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
ba55619
feaT: bottomSheet 기본 틀
simeunseo d48cbcf
fix: radix-ui 의존성 제거
simeunseo 7756932
feat: BottomSheet 공통 컴포넌트로 분리
simeunseo 2bd8374
fix: BottomSheet 애니메이션 로직 변경
simeunseo ab61439
feat: 회의 생성 전 확인 바텀시트 구현
simeunseo fb06d02
chore: console.log 삭제
simeunseo 8b47fcb
merge develop
simeunseo File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,51 @@ | ||
import { HTMLAttributes, PropsWithChildren, ReactNode } from 'react'; | ||
|
||
import styled from 'styled-components'; | ||
|
||
interface BottomSheetProps extends PropsWithChildren<HTMLAttributes<HTMLDivElement>> { | ||
children?: ReactNode; | ||
isOpen: boolean; | ||
onClose?: () => void; | ||
} | ||
|
||
function BottomSheet({ children, isOpen }: BottomSheetProps) { | ||
return ( | ||
<> | ||
<BottomSheetModal $isModalOpen={isOpen}>{children}</BottomSheetModal> | ||
<ModalOverlay $isModalOpen={isOpen} /> | ||
</> | ||
); | ||
} | ||
|
||
export default BottomSheet; | ||
|
||
const BottomSheetModal = styled.div<{ $isModalOpen: boolean }>` | ||
display: flex; | ||
position: fixed; | ||
bottom: 0; | ||
transform: translateY(${({ $isModalOpen }) => ($isModalOpen ? 0 : '100%')}); | ||
flex-direction: column; | ||
gap: 0.8rem; | ||
transition: transform 600ms cubic-bezier(0.86, 0, 0.07, 1); | ||
z-index: 1; | ||
border-top-left-radius: 1.2rem; | ||
border-top-right-radius: 1.2rem; | ||
background-color: ${({ theme }) => theme.colors.grey8}; | ||
|
||
padding: 4.4rem 2rem 4rem; | ||
width: 37.5rem; | ||
|
||
& button { | ||
width: 100%; | ||
} | ||
`; | ||
|
||
const ModalOverlay = styled.div<{ $isModalOpen: boolean }>` | ||
display: ${({ $isModalOpen }) => ($isModalOpen ? 'block' : 'none')}; | ||
position: fixed; | ||
top: 0; | ||
|
||
background-color: ${({ theme }) => theme.colors.black60}; | ||
width: 100%; | ||
height: 100%; | ||
`; |
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
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
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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
p4) 저도 콘솔 지우는걸 자주 깜빡하는데 eslint 콘솔 설정을 error로 변경할까요??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
어머나 좋습니다 ㅎ...ㅎ 추가로 배포 환경에서는 console이 보이지 않게하는 방법이 있다고 들었는데 알아보겠습니다