Compare commits

...

2 Commits

Author SHA1 Message Date
Ammar Ahmed
5a203b05fe mobile: release v3.0.25 2024-12-26 12:24:02 +05:00
Ammar Ahmed
303d1adc96 mobile: fix ts errors 2024-12-26 11:57:19 +05:00
23 changed files with 101 additions and 222 deletions

View File

@@ -47,7 +47,8 @@ export default {
deleteCacheFileByPath, deleteCacheFileByPath,
getCacheSize, getCacheSize,
requestPermission, requestPermission,
checkAndCreateDir checkAndCreateDir,
getUploadedFileSize
}; };
export const FileStorage: IFileStorage = { export const FileStorage: IFileStorage = {

View File

@@ -38,7 +38,7 @@ import { useAppState } from "../../hooks/use-app-state";
export interface BaseDialogProps extends PropsWithChildren { export interface BaseDialogProps extends PropsWithChildren {
animation?: "fade" | "none" | "slide" | undefined; animation?: "fade" | "none" | "slide" | undefined;
visible: boolean; visible?: boolean;
onRequestClose?: () => void; onRequestClose?: () => void;
onShow?: () => void; onShow?: () => void;
premium?: boolean; premium?: boolean;

View File

@@ -179,6 +179,7 @@ const ColorPicker = ({
title: title.current, title: title.current,
colorCode: selectedColor colorCode: selectedColor
}); });
if (!id) return;
useRelationStore.getState().update(); useRelationStore.getState().update();
useMenuStore.getState().setColorNotes(); useMenuStore.getState().setColorNotes();
setVisible(false); setVisible(false);

View File

@@ -297,7 +297,6 @@ function getDate(item: Item, groupType?: GroupingKey): number {
groupType groupType
? db.settings.getGroupOptions(groupType) ? db.settings.getGroupOptions(groupType)
: { : {
groupBy: "default",
sortBy: "dateEdited", sortBy: "dateEdited",
sortDirection: "desc" sortDirection: "desc"
}, },

View File

@@ -129,7 +129,10 @@ export const PricingPlans = ({
if (code.startsWith("com.streetwriters.notesnook")) { if (code.startsWith("com.streetwriters.notesnook")) {
skuId = code; skuId = code;
} else { } else {
skuId = await db.offers?.getCode(code.split(":")[0], Platform.OS); skuId = await db.offers?.getCode(
code.split(":")[0],
Platform.OS as "ios" | "android"
);
} }
const products = await PremiumService.getProducts(); const products = await PremiumService.getProducts();

View File

@@ -150,7 +150,7 @@ const PublishNoteSheet = ({
</View> </View>
) : ( ) : (
<> <>
{isPublished && ( {isPublished && publishUrl ? (
<View <View
style={{ style={{
flexDirection: "row", flexDirection: "row",
@@ -204,7 +204,7 @@ const PublishNoteSheet = ({
name="content-copy" name="content-copy"
/> />
</View> </View>
)} ) : null}
<TouchableOpacity <TouchableOpacity
onPress={() => { onPress={() => {

View File

@@ -556,9 +556,9 @@ export default function ReminderSheet({
{Object.keys(ReminderNotificationModes).map((mode) => ( {Object.keys(ReminderNotificationModes).map((mode) => (
<Button <Button
key={mode} key={mode}
title={strings.reminderNotificationModes[ title={strings.reminderNotificationModes(
mode as keyof typeof ReminderNotificationModes mode as keyof typeof ReminderNotificationModes
]()} )}
style={{ style={{
marginRight: 12, marginRight: 12,
borderRadius: 100 borderRadius: 100

View File

@@ -1,158 +0,0 @@
/*
This file is part of the Notesnook project (https://notesnook.com/)
Copyright (C) 2023 Streetwriters (Private) Limited
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
import React from "react";
import { ActivityIndicator, DimensionValue, ViewStyle } from "react-native";
import Animated, {
FadeIn,
FadeOut,
Layout,
LightSpeedInLeft
} from "react-native-reanimated";
import Icon from "react-native-vector-icons/MaterialCommunityIcons";
import { SIZE } from "../../../utils/size";
import NativeTooltip from "../../../utils/tooltip";
import { ButtonProps } from "../button";
import { Pressable, useButton } from "../pressable";
import Heading from "../typography/heading";
import Paragraph from "../typography/paragraph";
const AnimatedIcon = Animated.createAnimatedComponent(Icon);
export const AnimatedButton = ({
height = 45,
width = null,
onPress,
loading = false,
title = null,
icon,
fontSize = SIZE.sm,
type = "transparent",
iconSize = SIZE.md,
style = {},
accentColor = "accent",
accentText = "light",
onLongPress,
tooltipText,
textStyle,
iconPosition = "left",
buttonType,
bold,
iconColor,
fwdRef,
...restProps
}: ButtonProps) => {
const { text } = useButton({
type,
accent: accentColor,
text: accentText
});
const textColor = buttonType?.text ? buttonType.text : text;
const Component = bold ? Heading : Paragraph;
return (
<Animated.View
entering={FadeIn}
exiting={FadeOut}
layout={Layout.springify()}
>
<Pressable
{...restProps}
fwdRef={fwdRef}
onPress={onPress}
onLongPress={(event) => {
if (onLongPress) {
onLongPress(event);
return;
}
if (tooltipText) {
NativeTooltip.show(event, tooltipText, NativeTooltip.POSITIONS.TOP);
}
}}
disabled={loading}
type={type}
accentColor={accentColor}
accentText={accentText}
customColor={buttonType?.color}
customSelectedColor={buttonType?.selected}
customOpacity={buttonType?.opacity}
customAlpha={buttonType?.alpha}
style={{
height: height,
width: (width as DimensionValue) || undefined,
paddingHorizontal: 12,
borderRadius: 5,
alignSelf: "center",
justifyContent: "center",
alignItems: "center",
flexDirection: "row",
...(style as ViewStyle)
}}
>
{loading ? (
<ActivityIndicator color={textColor} size={fontSize + 4} />
) : null}
{icon && !loading && iconPosition === "left" ? (
<AnimatedIcon
exiting={FadeOut.duration(100)}
entering={LightSpeedInLeft}
layout={Layout.springify()}
name={icon}
style={{
marginRight: 0
}}
color={iconColor || buttonType?.text || textColor}
size={iconSize}
/>
) : null}
{!title ? null : (
<Component
layout={Layout.springify()}
animated={true}
color={textColor as string}
size={fontSize}
numberOfLines={1}
style={[
{
marginLeft:
icon || (loading && iconPosition === "left") ? 5 : 0,
marginRight:
icon || (loading && iconPosition === "right") ? 5 : 0
},
textStyle
]}
>
{title}
</Component>
)}
{icon && !loading && iconPosition === "right" ? (
<Icon
name={icon}
style={{
marginLeft: 0
}}
color={iconColor || buttonType?.text || textColor}
size={iconSize}
/>
) : null}
</Pressable>
</Animated.View>
);
};

View File

@@ -18,15 +18,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
import React from "react"; import React from "react";
import { View } from "react-native"; import { DimensionValue, View } from "react-native";
import { SvgXml } from "./lazy"; import { SvgXml } from "./lazy";
export const SvgView = ({ export const SvgView = ({
width = 250, width = 250,
height = 250, height = 250,
src src
}: { }: {
width?: number | string; width?: DimensionValue;
height?: number | number; height?: DimensionValue;
src?: string; src?: string;
}) => { }) => {
if (!src) return null; if (!src) return null;

View File

@@ -32,18 +32,11 @@ export function useAppState() {
const subscription = AppState.addEventListener("change", onChange); const subscription = AppState.addEventListener("change", onChange);
return () => { return () => {
// @ts-expect-error - React Native >= 0.65 subscription.remove();
if (typeof subscription?.remove === "function") {
// @ts-expect-error - need update @types/react-native@0.65.x
subscription.remove();
} else {
// React Native < 0.65
AppState.removeEventListener("change", onChange);
}
}; };
}, []); }, []);
return appState; return appState;
} }
export { AppStateStatus }; export type { AppStateStatus };

View File

@@ -18,7 +18,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
import { useEffect, useState } from "react"; import { useEffect, useState } from "react";
import { Keyboard, KeyboardEventListener, ScreenRect } from "react-native"; import { Keyboard, KeyboardEventListener, KeyboardMetrics } from "react-native";
const emptyCoordinates = Object.freeze({ const emptyCoordinates = Object.freeze({
screenX: 0, screenX: 0,
@@ -34,8 +34,8 @@ const initialValue = {
export default function useKeyboard() { export default function useKeyboard() {
const [shown, setShown] = useState(false); const [shown, setShown] = useState(false);
const [coordinates, setCoordinates] = useState<{ const [coordinates, setCoordinates] = useState<{
start: undefined | ScreenRect; start: undefined | KeyboardMetrics;
end: ScreenRect; end: KeyboardMetrics;
}>(initialValue); }>(initialValue);
const [keyboardHeight, setKeyboardHeight] = useState<number>(0); const [keyboardHeight, setKeyboardHeight] = useState<number>(0);

View File

@@ -59,15 +59,38 @@ export const Search = ({ route, navigation }: NavigationProps<"Search">) => {
} }
try { try {
setLoading(true); setLoading(true);
const type = let results: VirtualizedGrouping<Item> | undefined;
route.params.type === "trash"
? "trash" switch (route.params.type) {
: ((route.params?.type + "s") as keyof typeof db.lookup); case "note":
console.log(`Searching in ${type} for ${query}`); results = await db.lookup
const results = await db.lookup[type]( .notes(query, route.params.items as FilteredSelector<Note>)
query, .sorted();
route.params.items as FilteredSelector<Note> break;
).sorted(); case "notebook":
results = await db.lookup.notebooks(query).sorted();
break;
case "tag":
results = await db.lookup.tags(query).sorted();
break;
case "reminder":
results = await db.lookup.reminders(query).sorted();
break;
case "trash":
results = await db.lookup.trash(query).sorted();
break;
case "attachment":
results = await db.lookup.attachments(query).sorted();
break;
default:
results = undefined;
}
if (!results) {
setSearchStatus(strings.noResultsFound(query));
setLoading(false);
return;
}
console.log( console.log(
`Found ${results.placeholders?.length} results for ${query}` `Found ${results.placeholders?.length} results for ${query}`

View File

@@ -116,7 +116,7 @@ android {
minSdkVersion rootProject.ext.minSdkVersion minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled true multiDexEnabled true
versionCode 3034 versionCode 3035
versionName getNpmVersion() versionName getNpmVersion()
testBuildType System.getProperty('testBuildType', 'debug') testBuildType System.getProperty('testBuildType', 'debug')
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner' testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'

View File

@@ -1063,7 +1063,7 @@
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEVELOPMENT_TEAM = 53CWBG3QUC; DEVELOPMENT_TEAM = 53CWBG3QUC;
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
@@ -1137,7 +1137,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"$(inherited)", "$(inherited)",
"-ObjC", "-ObjC",
@@ -1168,7 +1168,7 @@
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual; CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEVELOPMENT_TEAM = ""; DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
@@ -1242,7 +1242,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
ONLY_ACTIVE_ARCH = NO; ONLY_ACTIVE_ARCH = NO;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"$(inherited)", "$(inherited)",
@@ -1401,7 +1401,7 @@
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEBUG_INFORMATION_FORMAT = dwarf; DEBUG_INFORMATION_FORMAT = dwarf;
DEVELOPMENT_TEAM = 53CWBG3QUC; DEVELOPMENT_TEAM = 53CWBG3QUC;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
@@ -1413,7 +1413,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
"@executable_path/../../Frameworks", "@executable_path/../../Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES; MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.notewidget; PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.notewidget;
@@ -1444,7 +1444,7 @@
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual; CODE_SIGN_STYLE = Manual;
COPY_PHASE_STRIP = NO; COPY_PHASE_STRIP = NO;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = ""; DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC;
@@ -1457,7 +1457,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
"@executable_path/../../Frameworks", "@executable_path/../../Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
MTL_FAST_MATH = YES; MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.notewidget; PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.notewidget;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
@@ -1487,7 +1487,7 @@
CODE_SIGN_ENTITLEMENTS = "Make Note/Make Note.entitlements"; CODE_SIGN_ENTITLEMENTS = "Make Note/Make Note.entitlements";
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEBUG_INFORMATION_FORMAT = dwarf; DEBUG_INFORMATION_FORMAT = dwarf;
DEVELOPMENT_TEAM = 53CWBG3QUC; DEVELOPMENT_TEAM = 53CWBG3QUC;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
@@ -1561,7 +1561,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
"@executable_path/../../Frameworks", "@executable_path/../../Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES; MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.share; PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.share;
@@ -1592,7 +1592,7 @@
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual; CODE_SIGN_STYLE = Manual;
COPY_PHASE_STRIP = NO; COPY_PHASE_STRIP = NO;
CURRENT_PROJECT_VERSION = 2121; CURRENT_PROJECT_VERSION = 2122;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = ""; DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 53CWBG3QUC;
@@ -1667,7 +1667,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
"@executable_path/../../Frameworks", "@executable_path/../../Frameworks",
); );
MARKETING_VERSION = 3.0.24; MARKETING_VERSION = 3.0.25;
MTL_FAST_MATH = YES; MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.share; PRODUCT_BUNDLE_IDENTIFIER = org.streetwriters.notesnook.share;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";

View File

@@ -88,7 +88,6 @@
"@tsconfig/react-native": "^3.0.2", "@tsconfig/react-native": "^3.0.2",
"@types/html-to-text": "^8.0.1", "@types/html-to-text": "^8.0.1",
"@types/metro-config": "^0.76.3", "@types/metro-config": "^0.76.3",
"@types/react": "^18.2.6",
"@types/react-native": "^0.69.1", "@types/react-native": "^0.69.1",
"@types/react-native-vector-icons": "^6.4.10", "@types/react-native-vector-icons": "^6.4.10",
"@types/react-test-renderer": "^18.0.0", "@types/react-test-renderer": "^18.0.0",

View File

@@ -1,12 +1,12 @@
{ {
"name": "@notesnook/mobile", "name": "@notesnook/mobile",
"version": "3.0.23", "version": "3.0.24",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "@notesnook/mobile", "name": "@notesnook/mobile",
"version": "3.0.23", "version": "3.0.24",
"hasInstallScript": true, "hasInstallScript": true,
"license": "GPL-3.0-or-later", "license": "GPL-3.0-or-later",
"workspaces": [ "workspaces": [
@@ -27,11 +27,13 @@
"@trpc/client": "^10.45.2", "@trpc/client": "^10.45.2",
"@trpc/react-query": "^10.45.2", "@trpc/react-query": "^10.45.2",
"@trpc/server": "^10.45.2", "@trpc/server": "^10.45.2",
"@types/validator": "^13.12.2",
"diffblazer": "^1.0.1", "diffblazer": "^1.0.1",
"react": "18.2.0", "react": "18.2.0",
"react-native": "0.74.5" "react-native": "0.74.5"
}, },
"devDependencies": { "devDependencies": {
"@types/react": "^18.2.39",
"fonteditor-core": "^2.1.11", "fonteditor-core": "^2.1.11",
"listr": "^0.14.3", "listr": "^0.14.3",
"otplib": "12.0.1", "otplib": "12.0.1",
@@ -29007,7 +29009,6 @@
"@types/html-to-text": "^8.0.1", "@types/html-to-text": "^8.0.1",
"@types/jest": "^29.5.14", "@types/jest": "^29.5.14",
"@types/metro-config": "^0.76.3", "@types/metro-config": "^0.76.3",
"@types/react": "^18.2.6",
"@types/react-native": "^0.69.1", "@types/react-native": "^0.69.1",
"@types/react-native-vector-icons": "^6.4.10", "@types/react-native-vector-icons": "^6.4.10",
"@types/react-test-renderer": "^18.0.0", "@types/react-test-renderer": "^18.0.0",
@@ -34355,12 +34356,13 @@
"license": "MIT" "license": "MIT"
}, },
"node_modules/@types/react": { "node_modules/@types/react": {
"version": "18.2.13", "version": "18.3.18",
"resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.18.tgz",
"integrity": "sha512-t4yC+vtgnkYjNSKlFx1jkAhH8LgTo2N/7Qvi83kdEaUtMDiwpbLAktKDaAMlRcJ5eSxZkH74eEGt1ky31d7kfQ==",
"devOptional": true, "devOptional": true,
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@types/prop-types": "*", "@types/prop-types": "*",
"@types/scheduler": "*",
"csstype": "^3.0.2" "csstype": "^3.0.2"
} }
}, },
@@ -34397,11 +34399,6 @@
"@types/react": "*" "@types/react": "*"
} }
}, },
"node_modules/@types/scheduler": {
"version": "0.16.3",
"devOptional": true,
"license": "MIT"
},
"node_modules/@types/semver": { "node_modules/@types/semver": {
"version": "7.5.0", "version": "7.5.0",
"dev": true, "dev": true,
@@ -34411,6 +34408,12 @@
"version": "2.0.1", "version": "2.0.1",
"license": "MIT" "license": "MIT"
}, },
"node_modules/@types/validator": {
"version": "13.12.2",
"resolved": "https://registry.npmjs.org/@types/validator/-/validator-13.12.2.tgz",
"integrity": "sha512-6SlHBzUW8Jhf3liqrGGXyTJSIFe4nqlJ5A5KaMZ2l/vbM3Wh3KSybots/wfWVzNLK4D1NZluDlSQIbIEPx6oyA==",
"license": "MIT"
},
"node_modules/@types/yargs": { "node_modules/@types/yargs": {
"version": "17.0.24", "version": "17.0.24",
"license": "MIT", "license": "MIT",

View File

@@ -1,6 +1,6 @@
{ {
"name": "@notesnook/mobile", "name": "@notesnook/mobile",
"version": "3.0.24", "version": "3.0.25",
"private": true, "private": true,
"license": "GPL-3.0-or-later", "license": "GPL-3.0-or-later",
"workspaces": [ "workspaces": [
@@ -24,6 +24,7 @@
"release-android-bundle": "cd native/android && ./gradlew bundleRelease --no-daemon" "release-android-bundle": "cd native/android && ./gradlew bundleRelease --no-daemon"
}, },
"devDependencies": { "devDependencies": {
"@types/react": "^18.2.39",
"fonteditor-core": "^2.1.11", "fonteditor-core": "^2.1.11",
"listr": "^0.14.3", "listr": "^0.14.3",
"otplib": "12.0.1", "otplib": "12.0.1",
@@ -37,19 +38,20 @@
"dependencies": { "dependencies": {
"@notesnook/common": "file:../../packages/common", "@notesnook/common": "file:../../packages/common",
"@notesnook/core": "file:../../packages/core", "@notesnook/core": "file:../../packages/core",
"@notesnook/crypto": "file:../../packages/crypto",
"@notesnook/editor": "file:../../packages/editor", "@notesnook/editor": "file:../../packages/editor",
"@notesnook/editor-mobile": "file:../../packages/editor-mobile", "@notesnook/editor-mobile": "file:../../packages/editor-mobile",
"@notesnook/intl": "file:../../packages/intl", "@notesnook/intl": "file:../../packages/intl",
"@notesnook/logger": "file:../../packages/logger", "@notesnook/logger": "file:../../packages/logger",
"@notesnook/theme": "file:../../packages/theme", "@notesnook/theme": "file:../../packages/theme",
"@notesnook/themes-server": "file:../../servers/themes", "@notesnook/themes-server": "file:../../servers/themes",
"@notesnook/crypto": "file:../../packages/crypto", "@tanstack/react-query": "^4.36.1",
"diffblazer": "^1.0.1",
"react": "18.2.0",
"react-native": "0.74.5",
"@trpc/client": "^10.45.2", "@trpc/client": "^10.45.2",
"@trpc/react-query": "^10.45.2", "@trpc/react-query": "^10.45.2",
"@trpc/server": "^10.45.2", "@trpc/server": "^10.45.2",
"@tanstack/react-query": "^4.36.1" "@types/validator": "^13.12.2",
"diffblazer": "^1.0.1",
"react": "18.2.0",
"react-native": "0.74.5"
} }
} }

View File

@@ -496,6 +496,7 @@ export const Search = ({
const tagId = await db.tags.add({ const tagId = await db.tags.add({
title: searchKeyword title: searchKeyword
}); });
if (!tagId) return;
SearchSetters.selectTags(tagId); SearchSetters.selectTags(tagId);
onSearch(); onSearch();
checkQueryExists(searchKeyword); checkQueryExists(searchKeyword);

View File

@@ -20,5 +20,5 @@
"maxNodeModuleJsDepth": 5, "maxNodeModuleJsDepth": 5,
"downlevelIteration": true "downlevelIteration": true
}, },
"exclude": ["native"] "exclude": ["native", "e2e"]
} }

View File

@@ -189,7 +189,7 @@ class Database {
tokenManager = new TokenManager(this.kv); tokenManager = new TokenManager(this.kv);
mfa = new MFAManager(this.tokenManager); mfa = new MFAManager(this.tokenManager);
subscriptions = new Subscriptions(this.tokenManager); subscriptions = new Subscriptions(this.tokenManager);
offers = new Offers(); offers = Offers;
debug = new Debug(); debug = new Debug();
pricing = Pricing; pricing = Pricing;

View File

@@ -6,6 +6,12 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"X-Generator: @lingui/cli\n" "X-Generator: @lingui/cli\n"
"Language: en\n" "Language: en\n"
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: \n"
"Last-Translator: \n"
"Language-Team: \n"
"Plural-Forms: \n"
#: src/strings.ts:817 #: src/strings.ts:817
msgid "— not just the" msgid "— not just the"

View File

@@ -6,6 +6,12 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"X-Generator: @lingui/cli\n" "X-Generator: @lingui/cli\n"
"Language: pseudo-LOCALE\n" "Language: pseudo-LOCALE\n"
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: \n"
"Last-Translator: \n"
"Language-Team: \n"
"Plural-Forms: \n"
#: src/strings.ts:817 #: src/strings.ts:817
msgid "— not just the" msgid "— not just the"