Switch over to tabs

This commit is contained in:
lukasmartinelli
2016-09-10 15:15:17 +02:00
parent e27b88c6bc
commit 0e65ac8937
10 changed files with 80 additions and 75 deletions
+3 -3
View File
@@ -3,9 +3,9 @@ import { Input } from 'rebass'
export default class BackgroundLayer extends React.Component {
static propTypes = {
layer: React.PropTypes.object.isRequired,
onPaintChanged: React.PropTypes.func.isRequired
}
layer: React.PropTypes.object.isRequired,
onPaintChanged: React.PropTypes.func.isRequired
}
onPaintChanged(property, e) {
let value = e.target.value
+11 -11
View File
@@ -20,14 +20,14 @@ class UnsupportedLayer extends React.Component {
/** Layer editor supporting multiple types of layers. */
export class LayerEditor extends React.Component {
static propTypes = {
layer: React.PropTypes.object.isRequired,
onLayerChanged: React.PropTypes.func.isRequired,
onLayerDestroyed: React.PropTypes.func.isRequired,
}
layer: React.PropTypes.object.isRequired,
onLayerChanged: React.PropTypes.func.isRequired,
onLayerDestroyed: React.PropTypes.func.isRequired,
}
static childContextTypes = {
static childContextTypes = {
reactIconBase: React.PropTypes.object
}
}
constructor(props) {
super(props);
@@ -36,12 +36,12 @@ export class LayerEditor extends React.Component {
}
}
getChildContext () {
return {
getChildContext () {
return {
reactIconBase: {
size: theme.fontSizes[4],
size: theme.fontSizes[4],
color: theme.colors.lowgray,
}
}
}
}
@@ -115,7 +115,7 @@ export class LayerEditor extends React.Component {
</NavItem>
<Space auto x={1} />
<NavItem onClick={this.toggleVisibility.bind(this)}>
{visibleIcon}
{visibleIcon}
</NavItem>
<NavItem onClick={(e) => this.props.onLayerDestroyed(this.props.layer)}>
<MdDelete />
+2 -2
View File
@@ -8,8 +8,8 @@ import scrollbars from '../scrollbars.scss'
export class LayerList extends React.Component {
static propTypes = {
layers: React.PropTypes.instanceOf(Immutable.List),
onLayersChanged: React.PropTypes.func.isRequired
}
onLayersChanged: React.PropTypes.func.isRequired
}
constructor(props) {
super(props)