Fix errors when resizing panels horizontally. (#265)
Closes #264 getWrappedInstance() is no longer necessary. If {forwardRef : true} has been passed to connect, adding a ref to the connected wrapper component will actually return the instance of the wrapped component.
This commit is contained in:
committed by
Jinseo Park
parent
aca5633927
commit
633e5dd30a
@@ -206,7 +206,7 @@ class App extends BaseComponent {
|
||||
|
||||
handleChangeWorkspaceWeights(workspaceWeights) {
|
||||
this.setState({ workspaceWeights });
|
||||
this.codeEditorRef.current.getWrappedInstance().handleResize();
|
||||
this.codeEditorRef.current.handleResize();
|
||||
}
|
||||
|
||||
toggleNavigatorOpened(navigatorOpened = !this.state.workspaceVisibles[0]) {
|
||||
|
||||
@@ -16,7 +16,7 @@ class CodeEditor extends React.Component {
|
||||
}
|
||||
|
||||
handleResize() {
|
||||
this.aceEditorRef.current.getWrappedInstance().resize();
|
||||
this.aceEditorRef.current.resize();
|
||||
}
|
||||
|
||||
render() {
|
||||
|
||||
Reference in New Issue
Block a user