Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2021-1-capstone-design1
/
GCL_Project1
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
이승윤
2021-05-03 18:24:09 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
45aef35b47510d4d4d76bda740fc915a14aa2240
45aef35b
1 parent
57b7db02
style: size 조정 props 추가
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
7 deletions
frontend/src/components/common/DropdownButton.js
frontend/src/components/common/DropdownButton.js
View file @
45aef35
...
...
@@ -10,22 +10,28 @@ const DropDownBlock = styled.div`
const
DropDownHeader
=
styled
.
button
`
margin-bottom: 0.8em;
padding: 0.4em;
box-shadow: 0 2px 3px rgba(0, 0, 0, 0.15)
;
font-weight: 500
;
font-size:
${
props
=>
props
.
size
}
;
border: 2px solid
${
props
=>
dropdownHeaderColorMap
[
props
.
color
].
borderColor
}
;
width:
${
props
=>
props
.
width
||
'100px'
}
;
line-height:
${
props
=>
props
.
height
||
'30px'
}
;
padding-right: 30px
;
font-size:
${
props
=>
props
.
fontsize
||
'20px'
}
;
color:
${
props
=>
dropdownHeaderColorMap
[
props
.
color
].
color
}
;
background-color:
${
props
=>
dropdownHeaderColorMap
[
props
.
color
].
background
}
;
&:hover {
background-color:
${
props
=>
dropdownHeaderColorMap
[
props
.
color
].
hoverBackground
}
;
}
border: 1px
${
props
=>
dropdownHeaderColorMap
[
props
.
color
].
background
}
;
`
;
const
DropDown
=
({
children
,
float
,
color
,
size
})
=>
{
const
DropDown
=
({
children
,
float
,
color
,
fontsize
,
width
,
height
})
=>
{
return
(
<
DropDownBlock
float
=
{
float
}
color
=
{
color
}
size
=
{
size
}
>
<
DropDownHeader
color
=
{
color
}
size
=
{
size
}
>
<
DropDownBlock
float
=
{
float
}
color
=
{
color
}
>
<
DropDownHeader
color
=
{
color
}
fontsize
=
{
fontsize
}
width
=
{
width
}
height
=
{
height
}
>
{
children
}
<
/DropDownHeader
>
<
/DropDownBlock
>
...
...
Please
register
or
login
to post a comment