A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
fix: changing notes did not reset undo levels
thecodrrc7f04fc0fe00
diff --git a/apps/web/src/components/editor/index.js b/apps/web/src/components/editor/index.jsindex a24f7683d..3525ad179 100644--- a/apps/web/src/components/editor/index.js+++ b/apps/web/src/components/editor/index.js@@ -73,13 +73,12 @@ function Editor({ noteId, nonce }) {const editor = editorRef.current?.editor;if (!editor) return;function setContents() {- editor.undoManager.clear();- editor.undoManager.add();- editor.setDirty(false);-// NOTE: workaround to not fire onEditorChange event on content loadeditor.isLoading = true;editor.setContent(data, { format: "html" });++ editor.undoManager.reset();+ editor.setDirty(false);}setContents();editor.on("init", setContents);