diff --git a/.detoxrc.js b/.detoxrc.js
index 5ea56ba83d..7e41bb76a7 100644
--- a/.detoxrc.js
+++ b/.detoxrc.js
@@ -6,7 +6,8 @@ module.exports = {
config: "e2e/jest.config.js",
},
jest: {
- setupTimeout: 120000,
+ setupTimeout: 900000,
+ teardownTimeout: 900000,
},
},
apps: {
@@ -27,16 +28,16 @@ module.exports = {
simulator: {
type: "ios.simulator",
device: {
- type: "iPhone 14 Plus",
+ type: "iPhone 15 Pro",
},
},
},
configurations: {
- "ios.sim.debug": {
+ "ios.debug": {
device: "simulator",
app: "ios.debug",
},
- "ios.sim.release": {
+ "ios.release": {
device: "simulator",
app: "ios.release",
},
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md
index 18fd49b408..44c86436ac 100644
--- a/.github/ISSUE_TEMPLATE/feature_request.md
+++ b/.github/ISSUE_TEMPLATE/feature_request.md
@@ -6,9 +6,6 @@ labels: ''
assignees: ''
---
-**Is this an AR camera feature?**
-If so, please head to [react-native-inat-camera](https://github.com/inaturalist/react-native-inat-camera) library and fill out a feature request there.
-
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
diff --git a/README.md b/README.md
index 178db247fa..8998e36e86 100644
--- a/README.md
+++ b/README.md
@@ -26,7 +26,7 @@
2. Build locally to a device or simulator by running `npm run ios` or `npm run android`
## Manual Linking
-Most third-party libraries use autolinking as of [React Native 0.60.0](https://facebook.github.io/react-native/blog/2019/07/03/version-60#native-modules-are-now-autolinked). Any exceptions are listed in the `react-native.config.js` file. Currently, [react-native-inat-camera](https://github.com/inaturalist/react-native-inat-camera) on Android is manually linked.
+Most third-party libraries use autolinking as of [React Native 0.60.0](https://facebook.github.io/react-native/blog/2019/07/03/version-60#native-modules-are-now-autolinked). Any exceptions are listed in the `react-native.config.js` file.
## Tests
We currently have three kinds of tests:
diff --git a/android/app/build.gradle b/android/app/build.gradle
index 36b099c067..521100fff9 100644
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -131,8 +131,6 @@ android {
}
dependencies {
- implementation project(':react-native-inat-camera')
-
// The version of react-native is set by the React Native Gradle Plugin
implementation("com.facebook.react:react-android")
implementation("com.facebook.react:flipper-integration")
diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml
index 799af6a354..901d579d30 100644
--- a/android/app/src/main/AndroidManifest.xml
+++ b/android/app/src/main/AndroidManifest.xml
@@ -10,11 +10,10 @@
-
+
-
=
PackageList(this).packages.apply {
// Packages that cannot be autolinked yet can be added manually here, for example:
- add(INatCameraViewPackage())
}
override fun getJSMainModuleName(): String = "index"
diff --git a/android/settings.gradle b/android/settings.gradle
index 1943f9df4e..49ef1b59ef 100644
--- a/android/settings.gradle
+++ b/android/settings.gradle
@@ -1,8 +1,6 @@
rootProject.name = 'Seek'
include ':@react-native-camera-roll_camera-roll'
project(':@react-native-camera-roll_camera-roll').projectDir = new File(rootProject.projectDir, '../node_modules/@react-native-camera-roll/camera-roll/android')
-include ':react-native-inat-camera'
-project(':react-native-inat-camera').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-inat-camera/android')
include ':react-native-check-app-install'
project(':react-native-check-app-install').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-check-app-install/android')
include ':RNSendIntentModule', ':app'
diff --git a/assets/icons.ts b/assets/icons.ts
index 6b9e3dd3f6..2f98531ba5 100644
--- a/assets/icons.ts
+++ b/assets/icons.ts
@@ -65,7 +65,8 @@ const icons: Icons = {
iNat_valueprop_bullet_2: require( "./icons/icon-cv-green.webp" ),
iNat_valueprop_bullet_3: require( "./icons/icon-obs-green.webp" ),
iNat_valueprop_bullet_4: require( "./icons/icon-person-green.webp" ),
- noProfilePhoto: require( "./icons/img-inatlogin-nophoto.webp" )
+ noProfilePhoto: require( "./icons/img-inatlogin-nophoto.webp" ),
+ gallery: require( "./icons/icon-gallery.webp" )
};
export default icons;
diff --git a/assets/icons/icon-gallery.webp b/assets/icons/icon-gallery.webp
new file mode 100644
index 0000000000..e031856069
Binary files /dev/null and b/assets/icons/icon-gallery.webp differ
diff --git a/assets/icons/icon-gallery@2x.webp b/assets/icons/icon-gallery@2x.webp
new file mode 100644
index 0000000000..d0d55fc9ec
Binary files /dev/null and b/assets/icons/icon-gallery@2x.webp differ
diff --git a/assets/icons/icon-gallery@3x.webp b/assets/icons/icon-gallery@3x.webp
new file mode 100644
index 0000000000..dd99b6cdb2
Binary files /dev/null and b/assets/icons/icon-gallery@3x.webp differ
diff --git a/components/About/AboutScreen.js b/components/About/AboutScreen.js
index 3a3c6f7973..7ba1379b48 100644
--- a/components/About/AboutScreen.js
+++ b/components/About/AboutScreen.js
@@ -37,7 +37,7 @@ const AboutScreen = (): Node => {
{i18n.t( "about.seek_designed_by" )}
- {i18n.t( "about.inat_team_credits_4" )}
+ {i18n.t( "about.inat_team_credits_5" )}
{i18n.t( "about.support_from" )}
diff --git a/components/Camera/ARCamera/ARCamera.e2e-mock.js b/components/Camera/ARCamera/ARCamera.e2e-mock.js
deleted file mode 100644
index 627d459a03..0000000000
--- a/components/Camera/ARCamera/ARCamera.e2e-mock.js
+++ /dev/null
@@ -1,214 +0,0 @@
-// @flow
-
-import React, {
- useReducer,
- useEffect,
- useRef,
- useCallback,
- useContext
-} from "react";
-import {
- Image,
- TouchableOpacity,
- View,
- Platform
-} from "react-native";
-import { CameraRoll } from "@react-native-camera-roll/camera-roll";
-import { useNavigation } from "@react-navigation/native";
-import type { Node } from "react";
-import RNFS from "react-native-fs";
-
-import i18n from "../../../i18n";
-import icons from "../../../assets/icons";
-import {
- showCameraSaveFailureAlert
-} from "../../../utility/cameraHelpers";
-import { checkCameraPermissions } from "../../../utility/androidHelpers.android";
-import { createTimestamp } from "../../../utility/dateHelpers";
-import { fetchImageLocationOrErrorCode } from "../../../utility/resultsHelpers";
-import { useObservation } from "../../Providers/ObservationProvider";
-import { UserContext } from "../../UserContext";
-
-const useVisionCamera = Platform.OS === "android";
-
-const ARCamera = ( ): Node => {
- const navigation = useNavigation( );
- const camera = useRef( null );
- const { setObservation, observation } = useObservation();
-
- // determines whether or not to fetch untruncated coords or precise coords for posting to iNat
- const { login } = useContext( UserContext );
-
- // eslint-disable-next-line no-shadow
- const [state, dispatch] = useReducer( ( state, action ) => {
- switch ( action.type ) {
- case "RESET_RANKS":
- return { ...state, ranks: {} };
- case "SET_RANKS":
- return { ...state, ranks: action.ranks };
- case "PHOTO_TAKEN":
- return { ...state, pictureTaken: true };
- case "RESET_STATE":
- return {
- ...state,
- pictureTaken: false,
- error: null,
- ranks: {}
- };
- case "FILTER_TAXON":
- return {
- ...state,
- pictureTaken: false,
- error: null,
- ranks: {}
- };
- case "ERROR":
- return { ...state, error: action.error };
- default:
- throw new Error( );
- }
- }, {
- ranks: {},
- error: null,
- pictureTaken: false
- } );
-
- const {
- error,
- pictureTaken
- } = state;
-
- const updateError = useCallback( ( err, errEvent?: string ) => {
- console.log( "updateError" );
- // don't update error on first camera load
- if ( err === null && error === null ) {
- return;
- }
- dispatch( { type: "ERROR", error: err, errorEvent: errEvent } );
- }, [error] );
-
- const navigateToResults = useCallback( async ( uri, predictions ) => {
- const userImage = {
- time: createTimestamp( ), // add current time to AR camera photos
- uri,
- predictions
- };
-
- // AR camera photos don't come with a location
- // especially when user has location permissions off
- // this is also needed for ancestor screen, species nearby
- const { image, errorCode } = await fetchImageLocationOrErrorCode( userImage, login );
- image.errorCode = errorCode;
- image.arCamera = true;
- setObservation( { image } );
- }, [setObservation, login] );
-
- useEffect( ( ) => {
- if ( observation && observation.taxon && observation.image.arCamera && pictureTaken ) {
- navigation.navigate( "Drawer", {
- screen: "Match"
- } );
- }
- }, [observation, navigation, pictureTaken] );
-
- const handleCameraRollSaveError = useCallback( async ( uri, predictions, e ) => {
- // react-native-cameraroll does not yet have granular detail about read vs. write permissions
- // but there's a pull request for it as of March 2021
-
- await showCameraSaveFailureAlert( e, uri );
- navigateToResults( uri, predictions );
- }, [navigateToResults] );
-
- const savePhoto = useCallback( async ( photo: { uri: string, predictions: Array