File tree Expand file tree Collapse file tree 2 files changed +14
-7
lines changed Expand file tree Collapse file tree 2 files changed +14
-7
lines changed Original file line number Diff line number Diff line change 1
1
import React from 'react' ;
2
+ import PropTypes from 'prop-types' ;
2
3
import styled from 'styled-components' ;
3
- import { prop , remSize } from '../../theme ' ;
4
+ import Button from '../../common/Button ' ;
4
5
5
- const textColor = prop ( 'primaryTextColor' ) ;
6
-
7
- const IconButton = styled . button `
6
+ const ButtonWrapper = styled ( Button ) `
8
7
width: 3rem;
9
8
> svg {
10
9
width: 100%;
11
10
height: auto;
12
- fill: ${ textColor } ;
13
- stroke: ${ textColor } ;
14
11
}
15
12
` ;
16
13
14
+ const IconButton = ( { children } ) => ( < ButtonWrapper
15
+ aria-label = "Add to collection"
16
+ iconBefore = { children }
17
+ kind = { Button . kinds . inline }
18
+ /> ) ;
19
+
20
+ IconButton . propTypes = {
21
+ children : PropTypes . element . isRequired
22
+ } ;
23
+
17
24
export default IconButton ;
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ const IDEViewMobile = (props) => {
61
61
< h3 > { selectedFile . name } </ h3 >
62
62
</ div >
63
63
64
- < div style = { { marginLeft : '2rem' } } >
64
+ < div style = { { marginLeft : '2rem' , display : 'flex' } } >
65
65
< IconButton onClick = { ( ) => setOverlay ( 'preferences' ) } >
66
66
< PreferencesIcon focusable = "false" aria-hidden = "true" />
67
67
</ IconButton >
You can’t perform that action at this time.
0 commit comments