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
web: remove "some notes of this topic..." error
Abdullah Atta2adce27f154f
diff --git a/apps/web/src/views/notes.js b/apps/web/src/views/notes.jsindex fccded99e..fc0d2b89d 100644--- a/apps/web/src/views/notes.js+++ b/apps/web/src/views/notes.js@@ -17,7 +17,7 @@ You should have received a copy of the GNU General Public Licensealong with this program. If not, see <http://www.gnu.org/licenses/>.*/-import { useEffect, useState } from "react";+import { useEffect } from "react";import ListContainer from "../components/list-container";import { useStore as useNotesStore } from "../stores/note-store";import NotesPlaceholder from "../components/placeholders/notesplacholder";@@ -25,11 +25,8 @@ import { hashNavigate, navigate } from "../navigation";import FavoritesPlaceholder from "../components/placeholders/favorites-placeholder";import { groupArray } from "@notesnook/core/utils/grouping";import { db } from "../common/db";-import { Flex, Text } from "@theme-ui/components";-import { SyncError } from "../components/icons";function Notes() {- const [isSynced, setIsSynced] = useState(true);const context = useNotesStore((store) => store.context);const refreshContext = useNotesStore((store) => store.refreshContext);const type = context?.type === "favorite" ? "favorites" : "notes";@@ -40,14 +37,6 @@ function Notes() {}}, [context]);- useEffect(() => {- if (context?.type === "topic") {- const { id, topic } = context.value;- if (!db.notebooks.notebook(id)?.topics.topic(topic)?.synced())- setIsSynced(false);- }- }, [context]);-if (!context) return null;return (<ListContainer@@ -56,16 +45,6 @@ function Notes() {refresh={refreshContext}context={{ ...context, notes: undefined }}items={groupArray(context.notes, db.settings.getGroupOptions(type))}- header={- isSynced ? null : (- <Flex bg="errorBg" p={2} py={1} sx={{ alignItems: "center" }}>- <SyncError color="error" size={16} />- <Text variant={"body"} ml={1} sx={{ color: "error" }}>- Some notes of this topic are not synced.- </Text>- </Flex>- )- }placeholder={context.type === "favorite" ? FavoritesPlaceholder : NotesPlaceholder}