Open dzpt opened 6 years ago
I don't know why, but after i put setState inside onChange callback, it couldn't close anymore.
Here is the code:
<SideMenu isOpen={this.state.peakOpened} openMenuOffset={layout.peakWidth} menu={this.state.peak} style={pstyle.peak} menuPosition='right' onChange={isOpen => this.changePeak(isOpen)} disableGestures={false}>
changePeak(isOpen) { this.setState({}) }
I faced the same issue, any update for this ?
I don't know why, but after i put setState inside onChange callback, it couldn't close anymore.
Here is the code:
<SideMenu isOpen={this.state.peakOpened} openMenuOffset={layout.peakWidth} menu={this.state.peak} style={pstyle.peak} menuPosition='right' onChange={isOpen => this.changePeak(isOpen)} disableGestures={false}>
changePeak(isOpen) { this.setState({}) }