mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-06 09:21:54 +00:00
fix (#2732)
This commit is contained in:
@@ -443,7 +443,11 @@ class DraftReview extends React.Component {
|
||||
}
|
||||
const win = window;
|
||||
let key = this.state.changedNodes[this.changeIndex];
|
||||
const element = win.document.querySelector(`[data-key="${key}"]`);
|
||||
let element = win.document.querySelector(`[data-key="${key}"]`);
|
||||
// fix code-block or tables
|
||||
while (element.className.indexOf('diff-') === -1 && element.tagName !== "BODY") {
|
||||
element = element.parentNode;
|
||||
}
|
||||
const scroller = this.findScrollContainer(element, win);
|
||||
const isWindow = scroller == win.document.body || scroller == win.document.documentElement;
|
||||
if (isWindow) {
|
||||
|
Reference in New Issue
Block a user