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 error on android's search query (#10106)
Suyadia1879dae1751
diff --git a/apps/mobile/app/screens/home/index.tsx b/apps/mobile/app/screens/home/index.tsxindex 46c4fa111..bdb556c49 100755--- a/apps/mobile/app/screens/home/index.tsx+++ b/apps/mobile/app/screens/home/index.tsx@@ -30,6 +30,7 @@ import SettingsService from "../../services/settings";import useNavigationStore from "../../stores/use-navigation-store";import { useNotes } from "../../stores/use-notes-store";import { openEditor } from "../notes/common";+import { db } from "../../common/database";export const Home = ({ navigation, route }: NavigationProps<"Notes">) => {const [notes, loading] = useNotes();@@ -59,7 +60,8 @@ export const Home = ({ navigation, route }: NavigationProps<"Notes">) => {placeholder: strings.searchInRoute(route.name),type: "note",title: route.name,- route: route.name+ route: route.name,+ items: db.notes.all});}}id={route.name}diff --git a/apps/mobile/app/stores/use-navigation-store.ts b/apps/mobile/app/stores/use-navigation-store.tsindex e3b1ff5c6..2d98a26ff 100644--- a/apps/mobile/app/stores/use-navigation-store.ts+++ b/apps/mobile/app/stores/use-navigation-store.ts@@ -74,13 +74,21 @@ export interface RouteParams extends ParamListBase {Tags: GenericRouteParam;Favorites: GenericRouteParam;Trash: GenericRouteParam;- Search: {- placeholder: string;- type: ItemType;- title: string;- route: RouteName;- items?: FilteredSelector<Item>;- };+ Search:+ | {+ placeholder: string;+ type: "note";+ title: string;+ route: RouteName;+ items: FilteredSelector<Note>;+ }+ | {+ placeholder: string;+ type: Exclude<ItemType, "note">;+ title: string;+ route: RouteName;+ items?: FilteredSelector<Item>;+ };TaggedNotes: NotesScreenParams;ColoredNotes: NotesScreenParams;TopicNotes: NotesScreenParams;diff --git a/packages/core/src/api/lookup.ts b/packages/core/src/api/lookup.tsindex d1ae43f00..2096d10b8 100644--- a/packages/core/src/api/lookup.ts+++ b/packages/core/src/api/lookup.ts@@ -114,7 +114,6 @@ export default class Lookup {): Promise<VirtualizedGrouping<HighlightedResult>> {const db = this.db.sql() as unknown as Kysely<RawDatabaseSchema>;const excludedIds = this.db.trash.cache.notes;-const {content,title,