import React, {Component, PropTypes} from 'react';
import {DragSource} from 'react-dnd';

const sampleSource = {
  beginDrag(props) {
    return props;
  }
};

const collectSource = (connect, monitor) => ({
  connectDragSource: connect.dragSource(),
  isDragging: monitor.isDragging()
});

class ElementContainer extends Component {
  constructor(props) {
    super(props);
  }

  render() {
    const {connectDragSource, sourceType} = this.props;
    if(sourceType == "") {
      return <span style={{fontSize: '18pt', cursor: 'not-allowed'}} className='text-muted fa fa-arrows'></span>;
    } else {
      return connectDragSource(
        <span style={{fontSize: '18pt', cursor: 'move'}} className='text-info fa fa-arrows'></span>,
        {dropEffect: 'copy'}
      );
    }
  }
}

export default DragSource(props => props.sourceType, sampleSource, collectSource)(ElementContainer);

ElementContainer.propTypes = {
  connectDragSource: PropTypes.func.isRequired,
  isDragging: PropTypes.bool.isRequired
};

@@ -534,16 +534,36 @@
 allowed'
+, color: 'lightgray'
 %7D%7D class
@@ -572,19 +572,8 @@
 me='
-text-muted 
 fa f

change disabled dragHandle-color