diff --git a/src/components/layers/LayerEditor.jsx b/src/components/layers/LayerEditor.jsx index 4c82a8f..79b4c16 100644 --- a/src/components/layers/LayerEditor.jsx +++ b/src/components/layers/LayerEditor.jsx @@ -154,6 +154,7 @@ export default class LayerEditor extends React.Component { onChange={newId => this.props.onLayerIdChange(this.props.layer.id, newId)} /> this.props.onLayerChanged(changeType(this.props.layer, newType))} diff --git a/src/components/layers/LayerTypeBlock.jsx b/src/components/layers/LayerTypeBlock.jsx index 4a4b2b3..1c68598 100644 --- a/src/components/layers/LayerTypeBlock.jsx +++ b/src/components/layers/LayerTypeBlock.jsx @@ -12,6 +12,11 @@ class LayerTypeBlock extends React.Component { wdKey: PropTypes.string, onChange: PropTypes.func.isRequired, error: PropTypes.object, + disabled: PropTypes.bool, + } + + static defaultProps = { + disabled: false, } render() { @@ -19,10 +24,29 @@ class LayerTypeBlock extends React.Component { data-wd-key={this.props.wdKey} error={this.props.error} > - + {this.props.disabled && + + } + {!this.props.disabled && + + } } }