Skip to content

Commit 45ba0c6

Browse files
committed
refactor: fix lint warning on public/js/syncscroll.js
Signed-off-by: BoHong Li <[email protected]>
1 parent e564c40 commit 45ba0c6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

public/js/lib/syncscroll.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ function buildMapInner (callback) {
188188
}
189189

190190
nonEmptyList.push(0)
191-
// make the first line go top
191+
// make the first line go top
192192
_scrollMap[0] = viewTop
193193

194194
const parts = markdownArea.find('.part').toArray()
@@ -336,7 +336,7 @@ export function syncScrollToView (event, preventAnimate) {
336336
const scrollInfo = editor.getScrollInfo()
337337
const textHeight = editor.defaultTextHeight()
338338
lineNo = Math.floor(scrollInfo.top / textHeight)
339-
// if reach the last line, will start lerp to the bottom
339+
// if reach the last line, will start lerp to the bottom
340340
const diffToBottom = (scrollInfo.top + scrollInfo.clientHeight) - (scrollInfo.height - textHeight)
341341
if (scrollInfo.height > scrollInfo.clientHeight && diffToBottom > 0) {
342342
topDiffPercent = diffToBottom / textHeight

0 commit comments

Comments
 (0)