File tree Expand file tree Collapse file tree 3 files changed +23
-16
lines changed
components/commons/bottomSheet
pages/main/components/floating Expand file tree Collapse file tree 3 files changed +23
-16
lines changed Original file line number Diff line number Diff line change 1
- import { ReactNode } from "react" ;
1
+ import React , { ReactNode } from "react" ;
2
2
import * as S from "./BottomSheet.styled" ;
3
3
4
4
export interface BottomSheetPropType {
5
+ onClick ?: React . MouseEventHandler < HTMLButtonElement > ;
5
6
isOpen : boolean ;
6
7
children ?: ReactNode ;
7
8
title ?: string ;
8
9
}
9
10
10
11
const BottomSheet = ( { isOpen, title, children } : BottomSheetPropType ) => {
11
12
return (
12
- < S . BottomSheetWrapper $isOpen = { isOpen } >
13
+ < S . BottomSheetWrapper $isOpen = { isOpen } onClick = { ( e ) => e . stopPropagation ( ) } >
13
14
< S . BottomSheetLayout >
14
15
< S . Title > { title } </ S . Title >
15
16
{ children }
Original file line number Diff line number Diff line change @@ -13,10 +13,14 @@ const float = keyframes`
13
13
}
14
14
` ;
15
15
16
+ export const Layer = styled . section `
17
+ position: relative;
18
+ ` ;
19
+
16
20
export const FloatingWrapper = styled . section `
17
21
position: fixed;
18
22
right: 0.3rem;
19
- bottom: 12rem ;
23
+ bottom: 15rem ;
20
24
z-index: 25;
21
25
display: flex;
22
26
flex-direction: column;
Original file line number Diff line number Diff line change @@ -5,19 +5,21 @@ const Floating = () => {
5
5
const navigate = useNavigate ( ) ;
6
6
7
7
return (
8
- < S . FloatingWrapper >
9
- < S . FloatingContainer >
10
- < S . UnionIcon > </ S . UnionIcon >
11
- < S . UnionText > 공연을 등록해보세요!</ S . UnionText >
12
- < S . FloatingBtnWrapper
13
- onClick = { ( ) => {
14
- navigate ( "/gig-register" ) ;
15
- } }
16
- >
17
- < S . FloatingBtn />
18
- </ S . FloatingBtnWrapper >
19
- </ S . FloatingContainer >
20
- </ S . FloatingWrapper >
8
+ < S . Layer >
9
+ < S . FloatingWrapper >
10
+ < S . FloatingContainer >
11
+ < S . UnionIcon > </ S . UnionIcon >
12
+ < S . UnionText > 공연을 등록해보세요!</ S . UnionText >
13
+ < S . FloatingBtnWrapper
14
+ onClick = { ( ) => {
15
+ navigate ( "/register" ) ;
16
+ } }
17
+ >
18
+ < S . FloatingBtn />
19
+ </ S . FloatingBtnWrapper >
20
+ </ S . FloatingContainer >
21
+ </ S . FloatingWrapper >
22
+ </ S . Layer >
21
23
) ;
22
24
} ;
23
25
You can’t perform that action at this time.
0 commit comments