Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

add sodium for encryption

ammarahm-ed83cd3197567b
diff --git a/apps/mobile/App.js b/apps/mobile/App.js
index dc56aa719..1446eb98f 100644
--- a/apps/mobile/App.js
+++ b/apps/mobile/App.js
@@ -1,14 +1,17 @@
-import React, {useEffect, useState} from 'react';
+import React, { useEffect, useState } from 'react';
import MMKV from 'react-native-mmkv-storage';
import Orientation from 'react-native-orientation';
-import {Loading} from './Loading';
-import {getColorScheme, scale, updateSize} from './src/common/common';
-import {useTracked} from './src/provider';
-import {ACTIONS} from './src/provider/actions';
-import {defaultState} from './src/provider/defaultState';
-import {eSubscribeEvent, eUnSubscribeEvent} from './src/services/eventManager';
-import {eDispatchAction} from './src/services/events';
-import {db, DDS} from './src/utils/utils';
+import { Loading } from './Loading';
+import { getColorScheme, scale, updateSize } from './src/common/common';
+import { useTracked } from './src/provider';
+import { ACTIONS } from './src/provider/actions';
+import { defaultState } from './src/provider/defaultState';
+import { eSubscribeEvent, eUnSubscribeEvent } from './src/services/eventManager';
+import { eDispatchAction } from './src/services/events';
+import { db, DDS } from './src/utils/utils';
+import { test } from './src/utils/storage';
+
+
const App = () => {
const [state, dispatch] = useTracked();
@@ -43,8 +46,9 @@ const App = () => {
useEffect(() => {
Initialize().then(() => {
db.init().then(async () => {
+
let user = await db.user.get();
- dispatch({type: ACTIONS.USER, user: user});
+ dispatch({ type: ACTIONS.USER, user: user });
setInit(true);
});
@@ -57,7 +61,7 @@ const App = () => {
let s;
try {
s = await MMKV.getStringAsync('settings');
- } catch (e) {}
+ } catch (e) { }
if (typeof s !== 'string') {
s = defaultState.settings;
s = JSON.stringify(s);
@@ -65,7 +69,7 @@ const App = () => {
await MMKV.setStringAsync('settings', s);
- dispatch({type: ACTIONS.SETTINGS, s});
+ dispatch({ type: ACTIONS.SETTINGS, s });
} else {
s = JSON.parse(s);
if (s.fontScale) {
@@ -75,9 +79,9 @@ const App = () => {
}
updateSize();
- dispatch({type: ACTIONS.SETTINGS, settings: {...s}});
+ dispatch({ type: ACTIONS.SETTINGS, settings: { ...s } });
}
- dispatch({type: ACTIONS.THEME, colors: newColors});
+ dispatch({ type: ACTIONS.THEME, colors: newColors });
}
if (!init) {
diff --git a/apps/mobile/ios/Notes-Bridging-Header.h b/apps/mobile/ios/Notes-Bridging-Header.h
new file mode 100644
index 000000000..1b2cb5d6d
--- /dev/null
+++ b/apps/mobile/ios/Notes-Bridging-Header.h
@@ -0,0 +1,4 @@
+//
+// Use this file to import your target's public headers that you would like to expose to Swift.
+//
+
diff --git a/apps/mobile/ios/Notes.xcodeproj/project.pbxproj b/apps/mobile/ios/Notes.xcodeproj/project.pbxproj
index 566fa53b4..ae8647563 100644
--- a/apps/mobile/ios/Notes.xcodeproj/project.pbxproj
+++ b/apps/mobile/ios/Notes.xcodeproj/project.pbxproj
@@ -18,11 +18,12 @@
2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
2DCD954D1E0B4F2C00145EB5 /* NotesTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* NotesTests.m */; };
- 4FFCB73C43232E07469EEB31 /* libPods-NotesTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 89ABD2DB3BB5CC5C08F50BC5 /* libPods-NotesTests.a */; };
58062BBC8B02A59BE1E73AED /* libPods-Notes.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FF962EEB8D0C9B17231DA150 /* libPods-Notes.a */; };
+ 6553712A244357FC00630CCC /* dummy.swift in Sources */ = {isa = PBXBuildFile; fileRef = 65537129244357FC00630CCC /* dummy.swift */; };
656D9DFF23D49A4600C49628 /* Web.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 656D9DFE23D49A4600C49628 /* Web.bundle */; };
659063ED243B132E004C1699 /* DMSans-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 659063EC243B132E004C1699 /* DMSans-Regular.ttf */; };
65A9D59A243B1394005DD7B5 /* DMSerifText-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 65A9D599243B1394005DD7B5 /* DMSerifText-Regular.ttf */; };
+ 74BD408DD384D602D170459E /* libPods-Notes-NotesTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = AF4CC7A4167D42A69DDE491D /* libPods-Notes-NotesTests.a */; };
773523A6669C9373D8945A06 /* libPods-Notes-tvOSTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 177E12D91F5B0732079F75AB /* libPods-Notes-tvOSTests.a */; };
CE84FC9EAE5373A65AB003DE /* libPods-Notes.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 654E158023E6AD1E008A3451 /* libPods-Notes.a */; };
/* End PBXBuildFile section */
@@ -62,6 +63,7 @@
00E356EE1AD99517003FC87E /* NotesTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = NotesTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
00E356F21AD99517003FC87E /* NotesTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = NotesTests.m; sourceTree = "<group>"; };
+ 06E1E8CEC35DCC5B07738C0D /* Pods-Notes-NotesTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes-NotesTests.release.xcconfig"; path = "Target Support Files/Pods-Notes-NotesTests/Pods-Notes-NotesTests.release.xcconfig"; sourceTree = "<group>"; };
13B07F961A680F5B00A75B9A /* Notes.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Notes.app; sourceTree = BUILT_PRODUCTS_DIR; };
13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = Notes/AppDelegate.h; sourceTree = "<group>"; };
13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = Notes/AppDelegate.m; sourceTree = "<group>"; };
@@ -81,14 +83,17 @@
654E157E23E6AD17008A3451 /* libReactNativeShareExtension.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = libReactNativeShareExtension.a; sourceTree = BUILT_PRODUCTS_DIR; };
654E158023E6AD1E008A3451 /* libPods-Notes.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libPods-Notes.a"; sourceTree = BUILT_PRODUCTS_DIR; };
654E158C23E6AEE6008A3451 /* libReact-Core.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libReact-Core.a"; sourceTree = BUILT_PRODUCTS_DIR; };
+ 65537128244357FC00630CCC /* Notes-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Notes-Bridging-Header.h"; sourceTree = "<group>"; };
+ 65537129244357FC00630CCC /* dummy.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = dummy.swift; sourceTree = "<group>"; };
656D9DFE23D49A4600C49628 /* Web.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = Web.bundle; path = ../html/Web.bundle; sourceTree = "<group>"; };
659063EC243B132E004C1699 /* DMSans-Regular.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; name = "DMSans-Regular.ttf"; path = "../html/Web.bundle/site/fonts/DMSans-Regular.ttf"; sourceTree = "<group>"; };
65A9D599243B1394005DD7B5 /* DMSerifText-Regular.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "DMSerifText-Regular.ttf"; sourceTree = "<group>"; };
6FB6DE7AD66669BE4A951A9E /* Pods-Notes-tvOSTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes-tvOSTests.debug.xcconfig"; path = "Target Support Files/Pods-Notes-tvOSTests/Pods-Notes-tvOSTests.debug.xcconfig"; sourceTree = "<group>"; };
87D2DFC238DED597B12E218E /* Pods-Notes-tvOSTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes-tvOSTests.release.xcconfig"; path = "Target Support Files/Pods-Notes-tvOSTests/Pods-Notes-tvOSTests.release.xcconfig"; sourceTree = "<group>"; };
- 89ABD2DB3BB5CC5C08F50BC5 /* libPods-NotesTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-NotesTests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
90C9DE97291FDC5E86C0D472 /* Pods-NotesTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NotesTests.release.xcconfig"; path = "Target Support Files/Pods-NotesTests/Pods-NotesTests.release.xcconfig"; sourceTree = "<group>"; };
+ 93C2808BD43E835DE3D61B90 /* Pods-Notes-NotesTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes-NotesTests.debug.xcconfig"; path = "Target Support Files/Pods-Notes-NotesTests/Pods-Notes-NotesTests.debug.xcconfig"; sourceTree = "<group>"; };
985D14A8C7261D8065A696A9 /* Pods-Notes.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes.release.xcconfig"; path = "Target Support Files/Pods-Notes/Pods-Notes.release.xcconfig"; sourceTree = "<group>"; };
+ AF4CC7A4167D42A69DDE491D /* libPods-Notes-NotesTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Notes-NotesTests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
CF69C4930BA6763C1B79A24E /* Pods-NotesTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NotesTests.debug.xcconfig"; path = "Target Support Files/Pods-NotesTests/Pods-NotesTests.debug.xcconfig"; sourceTree = "<group>"; };
E612868E6257D30458E07404 /* Pods-Notes-tvOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notes-tvOS.debug.xcconfig"; path = "Target Support Files/Pods-Notes-tvOS/Pods-Notes-tvOS.debug.xcconfig"; sourceTree = "<group>"; };
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
@@ -101,7 +106,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
- 4FFCB73C43232E07469EEB31 /* libPods-NotesTests.a in Frameworks */,
+ 74BD408DD384D602D170459E /* libPods-Notes-NotesTests.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -162,6 +167,8 @@
13B07FB61A68108700A75B9A /* Info.plist */,
13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
13B07FB71A68108700A75B9A /* main.m */,
+ 65537129244357FC00630CCC /* dummy.swift */,
+ 65537128244357FC00630CCC /* Notes-Bridging-Header.h */,
);
name = Notes;
sourceTree = "<group>";
@@ -180,7 +187,7 @@
FF962EEB8D0C9B17231DA150 /* libPods-Notes.a */,
36FE4CF96F141D64B0A0C1FF /* libPods-Notes-tvOS.a */,
177E12D91F5B0732079F75AB /* libPods-Notes-tvOSTests.a */,
- 89ABD2DB3BB5CC5C08F50BC5 /* libPods-NotesTests.a */,
+ AF4CC7A4167D42A69DDE491D /* libPods-Notes-NotesTests.a */,
);
name = Frameworks;
sourceTree = "<group>";
@@ -196,6 +203,8 @@
87D2DFC238DED597B12E218E /* Pods-Notes-tvOSTests.release.xcconfig */,
CF69C4930BA6763C1B79A24E /* Pods-NotesTests.debug.xcconfig */,
90C9DE97291FDC5E86C0D472 /* Pods-NotesTests.release.xcconfig */,
+ 93C2808BD43E835DE3D61B90 /* Pods-Notes-NotesTests.debug.xcconfig */,
+ 06E1E8CEC35DCC5B07738C0D /* Pods-Notes-NotesTests.release.xcconfig */,
);
path = Pods;
sourceTree = "<group>";
@@ -263,6 +272,7 @@
00E356EA1AD99517003FC87E /* Sources */,
00E356EB1AD99517003FC87E /* Frameworks */,
00E356EC1AD99517003FC87E /* Resources */,
+ 8B787EC96FFC3CE504B50441 /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -348,6 +358,9 @@
CreatedOnToolsVersion = 6.2;
TestTargetID = 13B07F861A680F5B00A75B9A;
};
+ 13B07F861A680F5B00A75B9A = {
+ LastSwiftMigration = 1110;
+ };
2D02E47A1E0B4A5D006451C7 = {
CreatedOnToolsVersion = 8.2.1;
ProvisioningStyle = Automatic;
@@ -448,7 +461,7 @@
outputFileListPaths = (
);
outputPaths = (
- "$(DERIVED_FILE_DIR)/Pods-NotesTests-checkManifestLockResult.txt",
+ "$(DERIVED_FILE_DIR)/Pods-Notes-NotesTests-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
@@ -517,6 +530,54 @@
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Notes/Pods-Notes-resources.sh\"\n";
showEnvVarsInLog = 0;
};
+ 8B787EC96FFC3CE504B50441 /* [CP] Copy Pods Resources */ = {
+ isa = PBXShellScriptBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ inputPaths = (
+ "${PODS_ROOT}/Target Support Files/Pods-Notes-NotesTests/Pods-Notes-NotesTests-resources.sh",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/AntDesign.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Entypo.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/EvilIcons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Feather.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Brands.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Regular.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Solid.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Fontisto.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Foundation.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Ionicons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/MaterialCommunityIcons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/MaterialIcons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Octicons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/SimpleLineIcons.ttf",
+ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Zocial.ttf",
+ );
+ name = "[CP] Copy Pods Resources";
+ outputPaths = (
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AntDesign.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Entypo.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/EvilIcons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Feather.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Brands.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Regular.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Solid.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Fontisto.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Foundation.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Ionicons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/MaterialCommunityIcons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/MaterialIcons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Octicons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/SimpleLineIcons.ttf",
+ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Zocial.ttf",
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ shellPath = /bin/sh;
+ shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Notes-NotesTests/Pods-Notes-NotesTests-resources.sh\"\n";
+ showEnvVarsInLog = 0;
+ };
BDF073639B3193387D3F311B /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
@@ -637,6 +698,7 @@
buildActionMask = 2147483647;
files = (
13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */,
+ 6553712A244357FC00630CCC /* dummy.swift in Sources */,
13B07FC11A68108700A75B9A /* main.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
@@ -688,8 +750,9 @@
/* Begin XCBuildConfiguration section */
00E356F61AD99517003FC87E /* Debug */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = CF69C4930BA6763C1B79A24E /* Pods-NotesTests.debug.xcconfig */;
+ baseConfigurationReference = 93C2808BD43E835DE3D61B90 /* Pods-Notes-NotesTests.debug.xcconfig */;
buildSettings = {
+ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
@@ -698,6 +761,10 @@
INFOPLIST_FILE = NotesTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"-ObjC",
"-lc++",
@@ -711,13 +778,18 @@
};
00E356F71AD99517003FC87E /* Release */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = 90C9DE97291FDC5E86C0D472 /* Pods-NotesTests.release.xcconfig */;
+ baseConfigurationReference = 06E1E8CEC35DCC5B07738C0D /* Pods-Notes-NotesTests.release.xcconfig */;
buildSettings = {
+ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
COPY_PHASE_STRIP = NO;
INFOPLIST_FILE = NotesTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"-ObjC",
"-lc++",
@@ -734,10 +806,15 @@
baseConfigurationReference = 58ACEDFE1446560AB8875A8B /* Pods-Notes.debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+ CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 1;
DEAD_CODE_STRIPPING = NO;
INFOPLIST_FILE = Notes/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
@@ -745,6 +822,9 @@
);
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = Notes;
+ SWIFT_OBJC_BRIDGING_HEADER = "Notes-Bridging-Header.h";
+ SWIFT_OPTIMIZATION_LEVEL = "-Onone";
+ SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
@@ -755,9 +835,14 @@
baseConfigurationReference = 985D14A8C7261D8065A696A9 /* Pods-Notes.release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+ CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 1;
INFOPLIST_FILE = Notes/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
@@ -765,6 +850,8 @@
);
PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = Notes;
+ SWIFT_OBJC_BRIDGING_HEADER = "Notes-Bridging-Header.h";
+ SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
@@ -785,6 +872,10 @@
GCC_NO_COMMON_BLOCKS = YES;
INFOPLIST_FILE = "Notes-tvOS/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
@@ -813,6 +904,10 @@
GCC_NO_COMMON_BLOCKS = YES;
INFOPLIST_FILE = "Notes-tvOS/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
@@ -840,6 +935,10 @@
GCC_NO_COMMON_BLOCKS = YES;
INFOPLIST_FILE = "Notes-tvOSTests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
@@ -867,6 +966,10 @@
GCC_NO_COMMON_BLOCKS = YES;
INFOPLIST_FILE = "Notes-tvOSTests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
+ OTHER_CFLAGS = (
+ "$(inherited)",
+ "-DFB_SONARKIT_ENABLED=1",
+ );
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
diff --git a/apps/mobile/ios/Notes/AppDelegate.m b/apps/mobile/ios/Notes/AppDelegate.m
index c8966b6d2..351848096 100644
--- a/apps/mobile/ios/Notes/AppDelegate.m
+++ b/apps/mobile/ios/Notes/AppDelegate.m
@@ -19,6 +19,7 @@
#import <FlipperKitNetworkPlugin/FlipperKitNetworkPlugin.h>
#import <SKIOSNetworkPlugin/SKIOSNetworkAdapter.h>
#import <FlipperKitReactPlugin/FlipperKitReactPlugin.h>
+
static void InitializeFlipper(UIApplication *application) {
FlipperClient *client = [FlipperClient sharedClient];
SKDescriptorMapper *layoutDescriptorMapper = [[SKDescriptorMapper alloc] initWithDefaults];
@@ -29,14 +30,6 @@ static void InitializeFlipper(UIApplication *application) {
[client start];
}
#endif
-@implementation AppDelegate
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
-#if DEBUG
- InitializeFlipper(application);
-#endif
-
-
@implementation AppDelegate
@@ -46,7 +39,7 @@ static void InitializeFlipper(UIApplication *application) {
#if DEBUG
InitializeFlipper(application);
-#endif
+ #endif
RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions];
RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge
diff --git a/apps/mobile/ios/Podfile b/apps/mobile/ios/Podfile
index 14146b76b..776bc67fe 100644
--- a/apps/mobile/ios/Podfile
+++ b/apps/mobile/ios/Podfile
@@ -31,6 +31,7 @@ def add_flipper_pods!(versions = {})
pod 'FlipperKit/FlipperKitLayoutTextSearchable', versions['Flipper'], :configuration => 'Debug'
pod 'FlipperKit/FlipperKitNetworkPlugin', versions['Flipper'], :configuration => 'Debug'
end
+
# Post Install processing for Flipper
def flipper_post_install(installer)
installer.pods_project.targets.each do |target|
@@ -40,6 +41,20 @@ def flipper_post_install(installer)
end
end
end
+ file_name = Dir.glob("*.xcodeproj")[0]
+ app_project = Xcodeproj::Project.open(file_name)
+ app_project.native_targets.each do |target|
+ target.build_configurations.each do |config|
+ cflags = config.build_settings['OTHER_CFLAGS'] || '$(inherited) '
+ unless cflags.include? '-DFB_SONARKIT_ENABLED=1'
+ puts 'Adding -DFB_SONARKIT_ENABLED=1 in OTHER_CFLAGS...'
+ cflags << '-DFB_SONARKIT_ENABLED=1'
+ end
+ config.build_settings['OTHER_CFLAGS'] = cflags
+ end
+ app_project.save
+ end
+ installer.pods_project.save
end
diff --git a/apps/mobile/ios/Podfile.lock b/apps/mobile/ios/Podfile.lock
index ad8177cef..c5c990ba6 100644
--- a/apps/mobile/ios/Podfile.lock
+++ b/apps/mobile/ios/Podfile.lock
@@ -1,14 +1,62 @@
PODS:
- boost-for-react-native (1.63.0)
+ - CocoaAsyncSocket (7.6.4)
+ - CocoaLibEvent (1.0.0)
- DoubleConversion (1.1.6)
- - FBLazyVector (0.61.5)
- - FBReactNativeSpec (0.61.5):
+ - FBLazyVector (0.62.2)
+ - FBReactNativeSpec (0.62.2):
- Folly (= 2018.10.22.00)
- - RCTRequired (= 0.61.5)
- - RCTTypeSafety (= 0.61.5)
- - React-Core (= 0.61.5)
- - React-jsi (= 0.61.5)
- - ReactCommon/turbomodule/core (= 0.61.5)
+ - RCTRequired (= 0.62.2)
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - Flipper (0.33.1):
+ - Flipper-Folly (~> 2.1)
+ - Flipper-RSocket (~> 1.0)
+ - Flipper-DoubleConversion (1.1.7)
+ - Flipper-Folly (2.1.1):
+ - boost-for-react-native
+ - CocoaLibEvent (~> 1.0)
+ - Flipper-DoubleConversion
+ - Flipper-Glog
+ - OpenSSL-Universal (= 1.0.2.19)
+ - Flipper-Glog (0.3.6)
+ - Flipper-PeerTalk (0.0.4)
+ - Flipper-RSocket (1.0.0):
+ - Flipper-Folly (~> 2.0)
+ - FlipperKit (0.33.1):
+ - FlipperKit/Core (= 0.33.1)
+ - FlipperKit/Core (0.33.1):
+ - Flipper (~> 0.33.1)
+ - FlipperKit/CppBridge
+ - FlipperKit/FBCxxFollyDynamicConvert
+ - FlipperKit/FBDefines
+ - FlipperKit/FKPortForwarding
+ - FlipperKit/CppBridge (0.33.1):
+ - Flipper (~> 0.33.1)
+ - FlipperKit/FBCxxFollyDynamicConvert (0.33.1):
+ - Flipper-Folly (~> 2.1)
+ - FlipperKit/FBDefines (0.33.1)
+ - FlipperKit/FKPortForwarding (0.33.1):
+ - CocoaAsyncSocket (~> 7.6)
+ - Flipper-PeerTalk (~> 0.0.4)
+ - FlipperKit/FlipperKitHighlightOverlay (0.33.1)
+ - FlipperKit/FlipperKitLayoutPlugin (0.33.1):
+ - FlipperKit/Core
+ - FlipperKit/FlipperKitHighlightOverlay
+ - FlipperKit/FlipperKitLayoutTextSearchable
+ - YogaKit (~> 1.18)
+ - FlipperKit/FlipperKitLayoutTextSearchable (0.33.1)
+ - FlipperKit/FlipperKitNetworkPlugin (0.33.1):
+ - FlipperKit/Core
+ - FlipperKit/FlipperKitReactPlugin (0.33.1):
+ - FlipperKit/Core
+ - FlipperKit/FlipperKitUserDefaultsPlugin (0.33.1):
+ - FlipperKit/Core
+ - FlipperKit/SKIOSNetworkPlugin (0.33.1):
+ - FlipperKit/Core
+ - FlipperKit/FlipperKitNetworkPlugin
- Folly (2018.10.22.00):
- boost-for-react-native
- DoubleConversion
@@ -20,213 +68,244 @@ PODS:
- glog
- glog (0.3.5)
- MMKV (1.0.24)
- - RCTRequired (0.61.5)
- - RCTTypeSafety (0.61.5):
- - FBLazyVector (= 0.61.5)
+ - OpenSSL-Universal (1.0.2.19):
+ - OpenSSL-Universal/Static (= 1.0.2.19)
+ - OpenSSL-Universal/Static (1.0.2.19)
+ - RCTRequired (0.62.2)
+ - RCTTypeSafety (0.62.2):
+ - FBLazyVector (= 0.62.2)
- Folly (= 2018.10.22.00)
- - RCTRequired (= 0.61.5)
- - React-Core (= 0.61.5)
- - React (0.61.5):
- - React-Core (= 0.61.5)
- - React-Core/DevSupport (= 0.61.5)
- - React-Core/RCTWebSocket (= 0.61.5)
- - React-RCTActionSheet (= 0.61.5)
- - React-RCTAnimation (= 0.61.5)
- - React-RCTBlob (= 0.61.5)
- - React-RCTImage (= 0.61.5)
- - React-RCTLinking (= 0.61.5)
- - React-RCTNetwork (= 0.61.5)
- - React-RCTSettings (= 0.61.5)
- - React-RCTText (= 0.61.5)
- - React-RCTVibration (= 0.61.5)
- - React-Core (0.61.5):
+ - RCTRequired (= 0.62.2)
+ - React-Core (= 0.62.2)
+ - React (0.62.2):
+ - React-Core (= 0.62.2)
+ - React-Core/DevSupport (= 0.62.2)
+ - React-Core/RCTWebSocket (= 0.62.2)
+ - React-RCTActionSheet (= 0.62.2)
+ - React-RCTAnimation (= 0.62.2)
+ - React-RCTBlob (= 0.62.2)
+ - React-RCTImage (= 0.62.2)
+ - React-RCTLinking (= 0.62.2)
+ - React-RCTNetwork (= 0.62.2)
+ - React-RCTSettings (= 0.62.2)
+ - React-RCTText (= 0.62.2)
+ - React-RCTVibration (= 0.62.2)
+ - React-Core (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- - React-Core/Default (= 0.61.5)
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-Core/Default (= 0.62.2)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/CoreModulesHeaders (0.61.5):
+ - React-Core/CoreModulesHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/Default (0.61.5):
+ - React-Core/Default (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/DevSupport (0.61.5):
+ - React-Core/DevSupport (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- - React-Core/Default (= 0.61.5)
- - React-Core/RCTWebSocket (= 0.61.5)
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
- - React-jsinspector (= 0.61.5)
+ - React-Core/Default (= 0.62.2)
+ - React-Core/RCTWebSocket (= 0.62.2)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
+ - React-jsinspector (= 0.62.2)
- Yoga
- - React-Core/RCTActionSheetHeaders (0.61.5):
+ - React-Core/RCTActionSheetHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTAnimationHeaders (0.61.5):
+ - React-Core/RCTAnimationHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTBlobHeaders (0.61.5):
+ - React-Core/RCTBlobHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTImageHeaders (0.61.5):
+ - React-Core/RCTImageHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTLinkingHeaders (0.61.5):
+ - React-Core/RCTLinkingHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTNetworkHeaders (0.61.5):
+ - React-Core/RCTNetworkHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTSettingsHeaders (0.61.5):
+ - React-Core/RCTSettingsHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTTextHeaders (0.61.5):
+ - React-Core/RCTTextHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTVibrationHeaders (0.61.5):
+ - React-Core/RCTVibrationHeaders (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- React-Core/Default
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-Core/RCTWebSocket (0.61.5):
+ - React-Core/RCTWebSocket (0.62.2):
- Folly (= 2018.10.22.00)
- glog
- - React-Core/Default (= 0.61.5)
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsiexecutor (= 0.61.5)
+ - React-Core/Default (= 0.62.2)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsiexecutor (= 0.62.2)
- Yoga
- - React-CoreModules (0.61.5):
- - FBReactNativeSpec (= 0.61.5)
+ - React-CoreModules (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
- Folly (= 2018.10.22.00)
- - RCTTypeSafety (= 0.61.5)
- - React-Core/CoreModulesHeaders (= 0.61.5)
- - React-RCTImage (= 0.61.5)
- - ReactCommon/turbomodule/core (= 0.61.5)
- - React-cxxreact (0.61.5):
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core/CoreModulesHeaders (= 0.62.2)
+ - React-RCTImage (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-cxxreact (0.62.2):
- boost-for-react-native (= 1.63.0)
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-jsinspector (= 0.61.5)
- - React-jsi (0.61.5):
+ - React-jsinspector (= 0.62.2)
+ - React-jsi (0.62.2):
- boost-for-react-native (= 1.63.0)
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-jsi/Default (= 0.61.5)
- - React-jsi/Default (0.61.5):
+ - React-jsi/Default (= 0.62.2)
+ - React-jsi/Default (0.62.2):
- boost-for-react-native (= 1.63.0)
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-jsiexecutor (0.61.5):
+ - React-jsiexecutor (0.62.2):
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-jsinspector (0.61.5)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-jsinspector (0.62.2)
- react-native-aes (1.3.6):
- React
+ - react-native-get-random-values (1.3.1):
+ - React
- react-native-mmkv-storage (0.2.2):
- MMKV (= 1.0.24)
- React
- react-native-orientation (3.1.3):
- React
- - react-native-webview (7.5.1):
+ - react-native-sodium (0.3.6):
+ - React
+ - react-native-webview (9.1.4):
- React
- - React-RCTActionSheet (0.61.5):
- - React-Core/RCTActionSheetHeaders (= 0.61.5)
- - React-RCTAnimation (0.61.5):
- - React-Core/RCTAnimationHeaders (= 0.61.5)
- - React-RCTBlob (0.61.5):
- - React-Core/RCTBlobHeaders (= 0.61.5)
- - React-Core/RCTWebSocket (= 0.61.5)
- - React-jsi (= 0.61.5)
- - React-RCTNetwork (= 0.61.5)
- - React-RCTImage (0.61.5):
- - React-Core/RCTImageHeaders (= 0.61.5)
- - React-RCTNetwork (= 0.61.5)
- - React-RCTLinking (0.61.5):
- - React-Core/RCTLinkingHeaders (= 0.61.5)
- - React-RCTNetwork (0.61.5):
- - React-Core/RCTNetworkHeaders (= 0.61.5)
- - React-RCTSettings (0.61.5):
- - React-Core/RCTSettingsHeaders (= 0.61.5)
- - React-RCTText (0.61.5):
- - React-Core/RCTTextHeaders (= 0.61.5)
- - React-RCTVibration (0.61.5):
- - React-Core/RCTVibrationHeaders (= 0.61.5)
- - ReactCommon/jscallinvoker (0.61.5):
+ - React-RCTActionSheet (0.62.2):
+ - React-Core/RCTActionSheetHeaders (= 0.62.2)
+ - React-RCTAnimation (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core/RCTAnimationHeaders (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTBlob (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - React-Core/RCTBlobHeaders (= 0.62.2)
+ - React-Core/RCTWebSocket (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - React-RCTNetwork (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTImage (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core/RCTImageHeaders (= 0.62.2)
+ - React-RCTNetwork (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTLinking (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - React-Core/RCTLinkingHeaders (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTNetwork (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core/RCTNetworkHeaders (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTSettings (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - RCTTypeSafety (= 0.62.2)
+ - React-Core/RCTSettingsHeaders (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - React-RCTText (0.62.2):
+ - React-Core/RCTTextHeaders (= 0.62.2)
+ - React-RCTVibration (0.62.2):
+ - FBReactNativeSpec (= 0.62.2)
+ - Folly (= 2018.10.22.00)
+ - React-Core/RCTVibrationHeaders (= 0.62.2)
+ - ReactCommon/turbomodule/core (= 0.62.2)
+ - ReactCommon/callinvoker (0.62.2):
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-cxxreact (= 0.61.5)
- - ReactCommon/turbomodule/core (0.61.5):
+ - React-cxxreact (= 0.62.2)
+ - ReactCommon/turbomodule/core (0.62.2):
- DoubleConversion
- Folly (= 2018.10.22.00)
- glog
- - React-Core (= 0.61.5)
- - React-cxxreact (= 0.61.5)
- - React-jsi (= 0.61.5)
- - ReactCommon/jscallinvoker (= 0.61.5)
+ - React-Core (= 0.62.2)
+ - React-cxxreact (= 0.62.2)
+ - React-jsi (= 0.62.2)
+ - ReactCommon/callinvoker (= 0.62.2)
- rn-fetch-blob (0.11.2):
- React-Core
- RNGestureHandler (1.5.0):
@@ -240,11 +319,32 @@ PODS:
- RNVectorIcons (6.6.0):
- React
- Yoga (1.14.0)
+ - YogaKit (1.18.1):
+ - Yoga (~> 1.14)
DEPENDENCIES:
- DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`)
- FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`)
- FBReactNativeSpec (from `../node_modules/react-native/Libraries/FBReactNativeSpec`)
+ - Flipper (~> 0.33.1)
+ - Flipper-DoubleConversion (= 1.1.7)
+ - Flipper-Folly (~> 2.1)
+ - Flipper-Glog (= 0.3.6)
+ - Flipper-PeerTalk (~> 0.0.4)
+ - Flipper-RSocket (~> 1.0)
+ - FlipperKit (~> 0.33.1)
+ - FlipperKit/Core (~> 0.33.1)
+ - FlipperKit/CppBridge (~> 0.33.1)
+ - FlipperKit/FBCxxFollyDynamicConvert (~> 0.33.1)
+ - FlipperKit/FBDefines (~> 0.33.1)
+ - FlipperKit/FKPortForwarding (~> 0.33.1)
+ - FlipperKit/FlipperKitHighlightOverlay (~> 0.33.1)
+ - FlipperKit/FlipperKitLayoutPlugin (~> 0.33.1)
+ - FlipperKit/FlipperKitLayoutTextSearchable (~> 0.33.1)
+ - FlipperKit/FlipperKitNetworkPlugin (~> 0.33.1)
+ - FlipperKit/FlipperKitReactPlugin (~> 0.33.1)
+ - FlipperKit/FlipperKitUserDefaultsPlugin (~> 0.33.1)
+ - FlipperKit/SKIOSNetworkPlugin (~> 0.33.1)
- Folly (from `../node_modules/react-native/third-party-podspecs/Folly.podspec`)
- glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`)
- RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`)
@@ -259,8 +359,10 @@ DEPENDENCIES:
- React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`)
- React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector`)
- react-native-aes (from `../node_modules/react-native-aes-crypto`)
+ - react-native-get-random-values (from `../node_modules/react-native-get-random-values`)
- react-native-mmkv-storage (from `../node_modules/react-native-mmkv-storage`)
- react-native-orientation (from `../node_modules/react-native-orientation`)
+ - react-native-sodium (from `../node_modules/react-native-sodium`)
- react-native-webview (from `../node_modules/react-native-webview`)
- React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`)
- React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`)
@@ -271,7 +373,7 @@ DEPENDENCIES:
- React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`)
- React-RCTText (from `../node_modules/react-native/Libraries/Text`)
- React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`)
- - ReactCommon/jscallinvoker (from `../node_modules/react-native/ReactCommon`)
+ - ReactCommon/callinvoker (from `../node_modules/react-native/ReactCommon`)
- ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`)
- rn-fetch-blob (from `../node_modules/rn-fetch-blob`)
- RNGestureHandler (from `../node_modules/react-native-gesture-handler`)
@@ -284,7 +386,18 @@ DEPENDENCIES:
SPEC REPOS:
trunk:
- boost-for-react-native
+ - CocoaAsyncSocket
+ - CocoaLibEvent
+ - Flipper
+ - Flipper-DoubleConversion
+ - Flipper-Folly
+ - Flipper-Glog
+ - Flipper-PeerTalk
+ - Flipper-RSocket
+ - FlipperKit
- MMKV
+ - OpenSSL-Universal
+ - YogaKit
EXTERNAL SOURCES:
DoubleConversion:
@@ -317,10 +430,14 @@ EXTERNAL SOURCES:
:path: "../node_modules/react-native/ReactCommon/jsinspector"
react-native-aes:
:path: "../node_modules/react-native-aes-crypto"
+ react-native-get-random-values:
+ :path: "../node_modules/react-native-get-random-values"
react-native-mmkv-storage:
:path: "../node_modules/react-native-mmkv-storage"
react-native-orientation:
:path: "../node_modules/react-native-orientation"
+ react-native-sodium:
+ :path: "../node_modules/react-native-sodium"
react-native-webview:
:path: "../node_modules/react-native-webview"
React-RCTActionSheet:
@@ -360,43 +477,56 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
boost-for-react-native: 39c7adb57c4e60d6c5479dd8623128eb5b3f0f2c
+ CocoaAsyncSocket: 694058e7c0ed05a9e217d1b3c7ded962f4180845
+ CocoaLibEvent: 2fab71b8bd46dd33ddb959f7928ec5909f838e3f
DoubleConversion: 5805e889d232975c086db112ece9ed034df7a0b2
- FBLazyVector: aaeaf388755e4f29cd74acbc9e3b8da6d807c37f
- FBReactNativeSpec: 118d0d177724c2d67f08a59136eb29ef5943ec75
+ FBLazyVector: 4aab18c93cd9546e4bfed752b4084585eca8b245
+ FBReactNativeSpec: 5465d51ccfeecb7faa12f9ae0024f2044ce4044e
+ Flipper: 6c1f484f9a88d30ab3e272800d53688439e50f69
+ Flipper-DoubleConversion: 38631e41ef4f9b12861c67d17cb5518d06badc41
+ Flipper-Folly: 2de3d03e0acc7064d5e4ed9f730e2f217486f162
+ Flipper-Glog: 1dfd6abf1e922806c52ceb8701a3599a79a200a6
+ Flipper-PeerTalk: 116d8f857dc6ef55c7a5a75ea3ceaafe878aadc9
+ Flipper-RSocket: 1260a31c05c238eabfa9bb8a64e3983049048371
+ FlipperKit: 6dc9b8f4ef60d9e5ded7f0264db299c91f18832e
Folly: 30e7936e1c45c08d884aa59369ed951a8e68cf51
glog: 1f3da668190260b06b429bb211bfbee5cd790c28
MMKV: 758b2edee46b08bdd958db4169191afb9a6d4ebd
- RCTRequired: b153add4da6e7dbc44aebf93f3cf4fcae392ddf1
- RCTTypeSafety: 9aa1b91d7f9310fc6eadc3cf95126ffe818af320
- React: b6a59ef847b2b40bb6e0180a97d0ca716969ac78
- React-Core: 688b451f7d616cc1134ac95295b593d1b5158a04
- React-CoreModules: d04f8494c1a328b69ec11db9d1137d667f916dcb
- React-cxxreact: d0f7bcafa196ae410e5300736b424455e7fb7ba7
- React-jsi: cb2cd74d7ccf4cffb071a46833613edc79cdf8f7
- React-jsiexecutor: d5525f9ed5f782fdbacb64b9b01a43a9323d2386
- React-jsinspector: fa0ecc501688c3c4c34f28834a76302233e29dc0
+ OpenSSL-Universal: 8b48cc0d10c1b2923617dfe5c178aa9ed2689355
+ RCTRequired: cec6a34b3ac8a9915c37e7e4ad3aa74726ce4035
+ RCTTypeSafety: 93006131180074cffa227a1075802c89a49dd4ce
+ React: 29a8b1a02bd764fb7644ef04019270849b9a7ac3
+ React-Core: b12bffb3f567fdf99510acb716ef1abd426e0e05
+ React-CoreModules: 4a9b87bbe669d6c3173c0132c3328e3b000783d0
+ React-cxxreact: e65f9c2ba0ac5be946f53548c1aaaee5873a8103
+ React-jsi: b6dc94a6a12ff98e8877287a0b7620d365201161
+ React-jsiexecutor: 1540d1c01bb493ae3124ed83351b1b6a155db7da
+ React-jsinspector: 512e560d0e985d0e8c479a54a4e5c147a9c83493
react-native-aes: 22ea989d641f53ea7722fe6b146349ed66e6455d
+ react-native-get-random-values: 148a42f97f2ce180a52d219144e83c278d4fe24b
react-native-mmkv-storage: 4f85ac485ff25ad5b9f7b3c6cd4c8bb067b1028c
react-native-orientation: f1caf84d65f1a4fd4511a18f2b924e634ad7a628
- react-native-webview: 2aadbfef6b9eaa9e89b306ae3e31e6e870a6306d
- React-RCTActionSheet: 600b4d10e3aea0913b5a92256d2719c0cdd26d76
- React-RCTAnimation: 791a87558389c80908ed06cc5dfc5e7920dfa360
- React-RCTBlob: d89293cc0236d9cb0933d85e430b0bbe81ad1d72
- React-RCTImage: 6b8e8df449eb7c814c99a92d6b52de6fe39dea4e
- React-RCTLinking: 121bb231c7503cf9094f4d8461b96a130fabf4a5
- React-RCTNetwork: fb353640aafcee84ca8b78957297bd395f065c9a
- React-RCTSettings: 8db258ea2a5efee381fcf7a6d5044e2f8b68b640
- React-RCTText: 9ccc88273e9a3aacff5094d2175a605efa854dbe
- React-RCTVibration: a49a1f42bf8f5acf1c3e297097517c6b3af377ad
- ReactCommon: 198c7c8d3591f975e5431bec1b0b3b581aa1c5dd
+ react-native-sodium: c7587732667e1cdb7d0d77c2aa2e98420aad2036
+ react-native-webview: 8315502f9fd22b98c09c9832fd1181ef88c33667
+ React-RCTActionSheet: f41ea8a811aac770e0cc6e0ad6b270c644ea8b7c
+ React-RCTAnimation: 49ab98b1c1ff4445148b72a3d61554138565bad0
+ React-RCTBlob: a332773f0ebc413a0ce85942a55b064471587a71
+ React-RCTImage: e70be9b9c74fe4e42d0005f42cace7981c994ac3
+ React-RCTLinking: c1b9739a88d56ecbec23b7f63650e44672ab2ad2
+ React-RCTNetwork: 73138b6f45e5a2768ad93f3d57873c2a18d14b44
+ React-RCTSettings: 6e3738a87e21b39a8cb08d627e68c44acf1e325a
+ React-RCTText: fae545b10cfdb3d247c36c56f61a94cfd6dba41d
+ React-RCTVibration: 4356114dbcba4ce66991096e51a66e61eda51256
+ ReactCommon: ed4e11d27609d571e7eee8b65548efc191116eb3
rn-fetch-blob: f525a73a78df9ed5d35e67ea65e79d53c15255bc
RNGestureHandler: a4ddde1ffc6e590c8127b8b7eabfdade45475c74
RNReanimated: b2ab0b693dddd2339bd2f300e770f6302d2e960c
RNScreens: f28b48b8345f2f5f39ed6195518291515032a788
RNShare: 0e19ddb0bf338b62702ce1d9e001ee14effa68a8
RNVectorIcons: 0bb4def82230be1333ddaeee9fcba45f0b288ed4
- Yoga: f2a7cd4280bfe2cca5a7aed98ba0eb3d1310f18b
+ Yoga: 3ebccbdd559724312790e7742142d062476b698e
+ YogaKit: f782866e155069a2cca2517aafea43200b01fd5a
-PODFILE CHECKSUM: 7cd3068f3c42e6d85b0135aaebe910c2bb876b5d
+PODFILE CHECKSUM: 032fcf57f00b3b8244e0ba107ff11a66bcba0c38
COCOAPODS: 1.8.4
diff --git a/apps/mobile/ios/dummy.swift b/apps/mobile/ios/dummy.swift
new file mode 100644
index 000000000..e68c53d57
--- /dev/null
+++ b/apps/mobile/ios/dummy.swift
@@ -0,0 +1,9 @@
+//
+// dummy.swift
+// Notes
+//
+// Created by Ammar Ahmed on 1/24/1399 AP.
+// Copyright © 1399 Facebook. All rights reserved.
+//
+
+import Foundation
diff --git a/apps/mobile/src/utils/storage.js b/apps/mobile/src/utils/storage.js
index e18be8e24..1b0b19645 100644
--- a/apps/mobile/src/utils/storage.js
+++ b/apps/mobile/src/utils/storage.js
@@ -1,5 +1,7 @@
import { NativeModules } from 'react-native';
import MMKV from 'react-native-mmkv-storage';
+import Sodium from "react-native-sodium";
+import { func } from 'prop-types';
var Aes = NativeModules.Aes;
@@ -53,29 +55,22 @@ function clear() {
MMKV.clearStore();
}
+
+
+
+
function encrypt(password, data) {
- let key;
- return Aes.pbkdf2(password, 'salt', 5000, 256).then(aes => {
- key = aes;
- return Aes.randomKey(16).then(iv => {
- return Aes.encrypt(data, key, iv).then(cipher => {
- return {
- cipher,
- iv,
- };
- });
- });
- });
+
+ return Sodium.encrypt({ password: password }, data).then(result => result);
}
function decrypt(password, data) {
- let key;
- return Aes.pbkdf2(password, 'salt', 5000, 256).then(aes => {
- key = aes;
- return Aes.decrypt(data.cipher, key, data.iv).then(e => {
- return e;
- });
- });
+ return Sodium.decrypt({ password: password }, data).then(result => result);
+}
+
+function deriveKey(passoword) {
+ return Sodium.deriveKey('password').then(result => result);
}
-export default { read, write, readMulti, remove, clear, encrypt, decrypt };
+
+export default { read, write, readMulti, remove, clear, encrypt, decrypt, deriveKey };
diff --git a/apps/mobile/src/utils/utils.js b/apps/mobile/src/utils/utils.js
index ce89c9b0c..8beb42d6f 100755
--- a/apps/mobile/src/utils/utils.js
+++ b/apps/mobile/src/utils/utils.js
@@ -1,35 +1,31 @@
import Storage from 'notes-core/api/index';
-import {Dimensions} from 'react-native';
-import {eSendEvent} from '../services/eventManager';
+import { Dimensions } from 'react-native';
+import { eSendEvent } from '../services/eventManager';
import {
- eOpenSideMenu,
- eCloseSideMenu,
- eDisableGestures,
- eEnableGestures,
eShowToast,
eHideToast,
} from '../services/events';
-import {DeviceDetectionService} from './deviceDetection';
+import { DeviceDetectionService } from './deviceDetection';
import StorageInterface from './storage';
import MMKV from 'react-native-mmkv-storage';
-import {updateEvent} from '../components/DialogManager/recievers';
-import {ACTIONS} from '../provider/actions';
+import { updateEvent } from '../components/DialogManager/recievers';
+import { ACTIONS } from '../provider/actions';
export const DDS = new DeviceDetectionService();
export const db = new Storage(StorageInterface);
export async function setSetting(settings, name, value) {
- let s = {...settings};
+ let s = { ...settings };
s[name] = value;
await MMKV.setStringAsync('settings', JSON.stringify(s));
- updateEvent({type: ACTIONS.SETTINGS, settings: s});
+ updateEvent({ type: ACTIONS.SETTINGS, settings: s });
}
export const getElevation = elevation => {
return {
elevation,
shadowColor: 'black',
- shadowOffset: {width: 0.3 * elevation, height: 0.5 * elevation},
+ shadowOffset: { width: 0.3 * elevation, height: 0.5 * elevation },
shadowOpacity: 0.2,
shadowRadius: 0.7 * elevation,
};