(props)
| 9 | @DragDropContext(HTML5Backend) |
| 10 | export default class Container extends Component { |
| 11 | constructor(props) { |
| 12 | super(props); |
| 13 | this.state = { |
| 14 | dustbins: [ |
| 15 | { accepts: [ItemTypes.GLASS], lastDroppedItem: null }, |
| 16 | { accepts: [ItemTypes.FOOD], lastDroppedItem: null }, |
| 17 | { accepts: [ItemTypes.PAPER, ItemTypes.GLASS, NativeTypes.URL], lastDroppedItem: null }, |
| 18 | { accepts: [ItemTypes.PAPER, NativeTypes.FILE], lastDroppedItem: null }, |
| 19 | ], |
| 20 | boxes: [ |
| 21 | { name: 'Bottle', type: ItemTypes.GLASS }, |
| 22 | { name: 'Banana', type: ItemTypes.FOOD }, |
| 23 | { name: 'Magazine', type: ItemTypes.PAPER }, |
| 24 | ], |
| 25 | droppedBoxNames: [], |
| 26 | }; |
| 27 | } |
| 28 | |
| 29 | isDropped(boxName) { |
| 30 | return this.state.droppedBoxNames.indexOf(boxName) > -1; |
nothing calls this directly
no outgoing calls
no test coverage detected