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
mobile: fix individual note history version deletion
kashaf-ansari-devc8cf4ce52aba
diff --git a/apps/mobile/app/components/note-history/preview.tsx b/apps/mobile/app/components/note-history/preview.tsxindex 9124312bc..e4cb3abb1 100644--- a/apps/mobile/app/components/note-history/preview.tsx+++ b/apps/mobile/app/components/note-history/preview.tsx@@ -112,19 +112,23 @@ export default function NotePreview({paragraph: strings.deleteNoteConfirmation(),positiveText: strings.delete(),negativeText: strings.cancel(),- context: "local",+ context: "preview",positivePress: async () => {- if (note) {+ if (session) {+ await db.noteHistory.remove(session.id);+ eSendEvent(eCloseSheet, "note_history");+ Navigation.queueRoutesForUpdate();+ } else if (note.type === "trash") {await db.trash.delete(note.id);useTrashStore.getState().refresh();useSelectionStore.getState().setSelectionMode();- ToastManager.show({- heading: strings.noteDeleted(),- type: "success",- context: "local"- });- eSendEvent(eCloseSheet);}+ ToastManager.show({+ heading: strings.noteDeleted(),+ type: "success"+ });++ eSendEvent(eCloseSheet);},positiveType: "error"});@@ -137,7 +141,7 @@ export default function NotePreview({width: "100%"}}>- <Dialog context="local" />+ <Dialog context="preview" /><DialogHeaderpadding={12}title={content?.title || note.title || session?.session}