diff --git a/src/components/DeviceSelection.js b/src/components/DeviceSelection.js index 23eff4d..f4efb2d 100644 --- a/src/components/DeviceSelection.js +++ b/src/components/DeviceSelection.js @@ -29,7 +29,7 @@ class DeviceSeclection extends Component { constructor(props) { super(props); this.state = { - open: true, + open: props.selectedBoard ? false : true, selectedBoard: "", saveSettings: false, @@ -58,39 +58,34 @@ class DeviceSeclection extends Component { }; render() { - const board = this.props.selectedBoard; - if (board) { - return null; - } - else { - return ( - -
- - - this.onclick(e, "mcu")}> - - -

senseBox MCU

-
- {/* + return ( + +
+ + + this.onclick(e, "mcu")}> + + +

senseBox MCU

+
+ {/* this.onclick(e, "esp")}>

Sensebox ESP

*/} - - this.onclick(e, "mini")}> - - -

senseBox MCU:mini

-
+ + this.onclick(e, "mini")}> + + +

senseBox MCU:mini

-
- {/* +
+ {/* */} - - {Blockly.Msg.deviceselection_footnote} Arduino UNO {Blockly.Msg.deviceselection_footnote_02} senseBox MCU - -
- ); - } + + {Blockly.Msg.deviceselection_footnote} Arduino UNO {Blockly.Msg.deviceselection_footnote_02} senseBox MCU + + + ); } }