1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 01:36:22 +00:00

Added option to disable scroll sync.

This commit is contained in:
David Nagle
2018-10-26 11:17:06 -07:00
parent f92da16544
commit d62d1d670b
3 changed files with 14 additions and 0 deletions

View File

@@ -30,6 +30,8 @@ class MarkdownSplitEditor extends React.Component {
}
handleScroll (e) {
if (!this.props.config.preview.scrollSync) return
const previewDoc = _.get(this, 'refs.preview.refs.root.contentWindow.document')
const codeDoc = _.get(this, 'refs.code.editor.doc')
let srcTop, srcHeight, targetTop, targetHeight