mirror of https://github.com/shadowfacts/type.git
Fix not being able to go to next chunk
This commit is contained in:
parent
5ddf1145f4
commit
0f9811d2c7
|
@ -159,7 +159,7 @@ function handleDelete(event) {
|
||||||
|
|
||||||
function handleEnter(event) {
|
function handleEnter(event) {
|
||||||
let pos = editor.getCursor();
|
let pos = editor.getCursor();
|
||||||
if (pos.line < editor.doc.size) {
|
if (pos.line < editor.doc.size - 1) {
|
||||||
let currentLine = editor.doc.getLine(pos.line);
|
let currentLine = editor.doc.getLine(pos.line);
|
||||||
let trimmed = currentLine.trim();
|
let trimmed = currentLine.trim();
|
||||||
if (editor.getCursor().ch >= currentLine.indexOf(trimmed) + trimmed.length) {
|
if (editor.getCursor().ch >= currentLine.indexOf(trimmed) + trimmed.length) {
|
||||||
|
|
Loading…
Reference in New Issue