1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-08-02 07:47:32 +00:00

fix-scroll-to-changes-bug (#2773)

This commit is contained in:
Michael An 2019-01-07 11:28:26 +08:00 committed by Daniel Pan
parent 41f9d58dc6
commit 12c841e700

View File

@ -64,10 +64,6 @@ class DraftReview extends React.Component {
componentDidMount() {
this.initialContent();
document.addEventListener('selectionchange', this.setBtnPosition);
let that = this;
setTimeout(() => {
that.getChangedNodes();
}, 1000);
}
initialContent = () => {
@ -116,6 +112,10 @@ class DraftReview extends React.Component {
draftOriginContent: draftOriginContent.data,
isLoading: false
});
let that = this;
setTimeout(() => {
that.getChangedNodes();
}, 100);
}));
}));
break;