Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

editor: fix input rules not working at the end of note (#4130)

Muhammad Aliae819504f064
diff --git a/packages/editor/src/utils/prosemirror.ts b/packages/editor/src/utils/prosemirror.ts
index a3edbab3d..a10e170a4 100644
--- a/packages/editor/src/utils/prosemirror.ts
+++ b/packages/editor/src/utils/prosemirror.ts
@@ -364,6 +364,7 @@ export function getDeletedNodes(
typeof step.to === "number" &&
"from" in step &&
typeof step.from === "number" &&
+ step.from < tr.doc.nodeSize - 1 &&
step.slice === Slice.empty
) {
const $from = tr.doc.resolve(step.from);