diff --git a/app.json b/app.json
index 5704d4dc8..d04fdebaf 100644
--- a/app.json
+++ b/app.json
@@ -26,7 +26,8 @@
"buildNumber": "11.2.0",
"infoPlist": {
"NSLocationWhenInUseUsageDescription": "This app uses your location to geo-tag surveys accurately."
- }
+ },
+ "appStoreUrl": "https://apps.apple.com/us/app/puente-collect/id1362371696"
},
"web": {
"favicon": "./assets/images/favicon.png"
@@ -38,7 +39,8 @@
"ACCESS_FINE_LOCATION",
"INTERNET"
],
- "softwareKeyboardLayoutMode": "pan"
+ "softwareKeyboardLayoutMode": "pan",
+ "playStoreUrl": "https://play.google.com/store/apps/details?id=io.ionic.starter1270348"
},
"packagerOpts": {
"config": "metro.config.js",
@@ -57,4 +59,4 @@
]
}
}
-}
+}
\ No newline at end of file
diff --git a/domains/Settings/SettingsHome/AccountSettings/FindRecords/index.js b/domains/Settings/SettingsHome/AccountSettings/FindRecords/index.js
index 9f2f0a06d..608cd13c1 100644
--- a/domains/Settings/SettingsHome/AccountSettings/FindRecords/index.js
+++ b/domains/Settings/SettingsHome/AccountSettings/FindRecords/index.js
@@ -115,7 +115,7 @@ const FindRecords = () => {
setEdit(result.key);
}}
>
- Edit
+ {I18n.t('findRecordSettings.edit')}
)}
@@ -161,7 +161,7 @@ const FindRecords = () => {
color={theme.colors.primary}
/>
) : (
-
+
)}
);
diff --git a/domains/Settings/SettingsHome/AccountSettings/NamePhoneEmail/index.js b/domains/Settings/SettingsHome/AccountSettings/NamePhoneEmail/index.js
index d8958165c..0141d8f4c 100644
--- a/domains/Settings/SettingsHome/AccountSettings/NamePhoneEmail/index.js
+++ b/domains/Settings/SettingsHome/AccountSettings/NamePhoneEmail/index.js
@@ -145,7 +145,7 @@ const NamePhoneEmail = () => {
setEdit(result.key);
}}
>
- Edit
+ {I18n.t('findRecordSettings.edit')}
)}
@@ -190,7 +190,7 @@ const NamePhoneEmail = () => {
color={theme.colors.primary}
/>
) : (
-
+
)}
);
diff --git a/domains/Settings/SupportHome/SupportSettings/AboutUs/index.js b/domains/Settings/SupportHome/SupportSettings/AboutUs/index.js
deleted file mode 100644
index 065500d8c..000000000
--- a/domains/Settings/SupportHome/SupportSettings/AboutUs/index.js
+++ /dev/null
@@ -1,19 +0,0 @@
-import React, { useState } from 'react';
-import {
- View
-} from 'react-native';
-import {
- Button, Headline, IconButton, Text
-} from 'react-native-paper';
-
-import styles from '../../../index.styles';
-
-const AboutUs = ({
- settingsView, setSettingsView, supportView, setSupportView
-}) => (
-
- About us
-
- );
-
-export default AboutUs;
\ No newline at end of file
diff --git a/domains/Settings/SupportHome/SupportSettings/Feedback/index.js b/domains/Settings/SupportHome/SupportSettings/Feedback/index.js
index 4ea67ec09..222784f2f 100644
--- a/domains/Settings/SupportHome/SupportSettings/Feedback/index.js
+++ b/domains/Settings/SupportHome/SupportSettings/Feedback/index.js
@@ -9,6 +9,7 @@ import {
import email from 'react-native-email'
import styles from '../../../index.styles';
+import I18n from '../../../../../modules/i18n';
const Feedback = () => {
const handleEmail = () => {
@@ -26,16 +27,16 @@ const Feedback = () => {
return (
- Feedback
+ {I18n.t('feedback.feedback')}
- Please enter your feedback in the input below and press the "Send Feedback" button. This will redirect you to your email where you can send your feedback.
+ {I18n.t('feedback.enterFeedback')}
setEmailBody(text)}
- placeholder={"Type your feedback here..."}>
+ placeholder={I18n.t('feedback.typeFeedback')}>
-
+
)
diff --git a/domains/Settings/SupportHome/SupportSettings/RateOurApp/index.js b/domains/Settings/SupportHome/SupportSettings/RateOurApp/index.js
deleted file mode 100644
index 8eb611198..000000000
--- a/domains/Settings/SupportHome/SupportSettings/RateOurApp/index.js
+++ /dev/null
@@ -1,20 +0,0 @@
-import React, { useState } from 'react';
-import {
- View
-} from 'react-native';
-import {
- Button, Headline, IconButton, Text
-} from 'react-native-paper';
-
-import styles from '../../../index.styles';
-
-const RateOurApp = ({
- settingsView, setSettingsView, supportView, setSupportView
-}) => (
-
- Rate our app
-
-
- );
-
-export default RateOurApp;
\ No newline at end of file
diff --git a/domains/Settings/SupportHome/SupportSettings/WhatsNew/index.js b/domains/Settings/SupportHome/SupportSettings/WhatsNew/index.js
deleted file mode 100644
index 729e4209e..000000000
--- a/domains/Settings/SupportHome/SupportSettings/WhatsNew/index.js
+++ /dev/null
@@ -1,19 +0,0 @@
-import React, { useState } from 'react';
-import {
- View
-} from 'react-native';
-import {
- Button, Headline, IconButton, Text
-} from 'react-native-paper';
-
-import styles from '../../../index.styles';
-
-const WhatsNew = ({
- settingsView, setSettingsView, supportView, setSupportView
-}) => (
-
- Whats new
-
- );
-
-export default WhatsNew;
\ No newline at end of file
diff --git a/domains/Settings/SupportHome/SupportSettings/index.js b/domains/Settings/SupportHome/SupportSettings/index.js
index c56c0f9ea..de0e913dc 100644
--- a/domains/Settings/SupportHome/SupportSettings/index.js
+++ b/domains/Settings/SupportHome/SupportSettings/index.js
@@ -6,12 +6,10 @@ import {
Button, Headline, IconButton, Text
} from 'react-native-paper';
-import AboutUs from './AboutUs';
import Feedback from './Feedback';
-import RateOurApp from './RateOurApp';
-import WhatsNew from './WhatsNew';
import styles from '../../index.styles';
+import I18n from '../../../../modules/i18n';
const SupportSettings = ({
settingsView, setSettingsView, supportView, setSupportView
@@ -33,7 +31,7 @@ const SupportSettings = ({
+ >{I18n.t('supportHome.back')}
);
diff --git a/domains/Settings/SupportHome/index.js b/domains/Settings/SupportHome/index.js
index bd2abbe8f..02dab7e93 100644
--- a/domains/Settings/SupportHome/index.js
+++ b/domains/Settings/SupportHome/index.js
@@ -1,6 +1,6 @@
import React, { useState } from 'react';
import {
- View
+ View, TouchableOpacity
} from 'react-native';
import {
Button, Headline, IconButton, Text
@@ -11,32 +11,32 @@ import I18n from '../../../modules/i18n';
import { theme } from '../../../modules/theme';
import styles from '../index.styles'
+import * as StoreReview from 'expo-store-review';
const SupportHome = ({
setView, prevView, logOut, settingsView, setSettingsView
}) => {
const [supportView, setSupportView] = useState('');
+ const rateApp = async () => {
+ if (await StoreReview.isAvailableAsync()) {
+ StoreReview.requestReview();
+ }
+ }
const inputs = [
- {
- key: 'whatsNew',
- label: 'What\'s New?',
- button: true
- },
- {
- key: 'aboutUs',
- label: 'About us',
- button: true
- },
{
key: 'feedback',
- label: 'Contact us / Feedback?',
- button: true
+ label: I18n.t('supportHome.feedback'),
+ button: true,
+ touchable: false,
+ action: null
},
{
key: 'rateApp',
- label: 'Rate our app',
- button: false
+ label: I18n.t('supportHome.rateApp'),
+ button: false,
+ touchable: true,
+ action: rateApp
}
];
return (
@@ -54,24 +54,41 @@ const SupportHome = ({
- Help Center
+ {I18n.t('supportHome.helpCenter')}
{inputs.length > 0 && inputs.map((input) => (
-
-
- {input.label}
- {input.button && (
- {
- setSupportView(input.key);
- }}
- />
+
+ {input.touchable ? (
+ input.action()}>
+ {input.label}
+ {input.button && (
+ {
+ setSupportView(input.key);
+ }}
+ />
+ )}
+
+ ) : (
+
+ {input.label}
+ {input.button && (
+ {
+ setSupportView(input.key);
+ }}
+ />
+ )}
+
)}
-
))}
@@ -88,8 +105,8 @@ const SupportHome = ({
{supportView !== '' && (
diff --git a/modules/i18n/english/en.json b/modules/i18n/english/en.json
index bdc9d53c5..3963fca28 100644
--- a/modules/i18n/english/en.json
+++ b/modules/i18n/english/en.json
@@ -427,14 +427,15 @@
"findRecords": "Find Records",
"language": "Language",
"back": "Back",
- "logout":"Log out"
+ "logout": "Log out"
},
"findRecordSettings": {
"currentReccordsStored": "Current records stored",
"recordStorageLimit": "Record storage limit",
"errorMessage": "There was an error processing your request. Please ensure you are connected to the internet and try again.",
"successMessage": "You have updated your storage limit. You may experience app related issues if your phone cannot handle the new limit. If this occurs, your experience may be better if you reduce the limit.",
- "findRecords": "Find Records"
+ "findRecords": "Find Records",
+ "edit": "Edit"
},
"languageSettings": {
"chooseLanguage": "Choose Language"
@@ -457,5 +458,17 @@
"changePassword": "Change Password",
"currentPassword": "Current Password",
"newPassword": "New Password"
+ },
+ "supportHome": {
+ "feedback": "Contact us / Feedback",
+ "rateApp": "Rate our app",
+ "helpCenter": "Help Center",
+ "back": "Back"
+ },
+ "feedback": {
+ "feedback": "Feedback",
+ "enterFeedback": "Please enter your feedback in the input below and press the \"Send Feedback\" button. This will redirect you to your email where you can send your feedback.",
+ "sendMail": "Send Mail",
+ "typeFeedback": "Type your feedback here..."
}
}
\ No newline at end of file
diff --git a/modules/i18n/spanish/es.json b/modules/i18n/spanish/es.json
index 171096362..523957098 100644
--- a/modules/i18n/spanish/es.json
+++ b/modules/i18n/spanish/es.json
@@ -434,7 +434,8 @@
"recordStorageLimit": "Límite de almacenamiento de registros",
"errorMessage": "Hubo un error al procesar su solicitud. Asegúrese de estar conectado a Internet y vuelva a intentarlo.",
"successMessage": "Has actualizado tu límite de almacenamiento. Puede experimentar problemas relacionados con la aplicación si su teléfono no puede manejar el nuevo límite. Si esto ocurre, su experiencia puede mejorar si reduce el límite.",
- "findRecords": "Buscar registros"
+ "findRecords": "Buscar registros",
+ "edit": "Editar"
},
"languageSettings": {
"chooseLanguage": "Elige lengua"
@@ -457,5 +458,17 @@
"changePassword": "Cambiar la contraseña",
"currentPassword": "Contraseña actual",
"newPassword": "Nueva contraseña"
+ },
+ "supportHome": {
+ "feedback": "Contáctenos / Comentarios",
+ "rateApp": "Califica nuestra aplicación",
+ "helpCenter": "Centro de ayuda",
+ "back": "atrás"
+ },
+ "feedback": {
+ "feedback": "Realimentación",
+ "enterFeedback": "Ingrese sus comentarios en la entrada a continuación y presione el botón \"Enviar comentarios\". Esto lo redireccionará a su correo electrónico donde puede enviar sus comentarios.",
+ "sendMail": "Enviar correo",
+ "typeFeedback": "Escriba sus comentarios aquí ..."
}
}
\ No newline at end of file
diff --git a/package-lock.json b/package-lock.json
index 6f43b754b..890014971 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -7677,6 +7677,11 @@
"lodash": "^4.17.15"
}
},
+ "expo-store-review": {
+ "version": "2.1.3",
+ "resolved": "https://registry.npmjs.org/expo-store-review/-/expo-store-review-2.1.3.tgz",
+ "integrity": "sha512-4RJJs59l1auPLFMO0d1HsIcVs38/wb8fSpFmkRqfOuJYXbeFfXi7tBCoY5Fha1Num149Vuo+DyNHTdePAGgK+A=="
+ },
"expo-web-browser": {
"version": "8.3.1",
"resolved": "https://registry.npmjs.org/expo-web-browser/-/expo-web-browser-8.3.1.tgz",
diff --git a/package.json b/package.json
index be394eb1b..f8048793c 100644
--- a/package.json
+++ b/package.json
@@ -67,7 +67,7 @@
"react-dom": "16.11.0",
"react-native": "https://github.com/expo/react-native/archive/sdk-38.0.2.tar.gz",
"react-native-autocomplete-input": "4.2.0",
- "react-native-email": "^1.1.0",
+ "react-native-email": "1.1.0",
"react-native-emoji": "1.8.0",
"react-native-gesture-handler": "1.6.0",
"react-native-localize": "1.3.3",
@@ -80,7 +80,8 @@
"react-redux": "7.2.0",
"redux": "4.0.5",
"redux-actions": "2.6.5",
- "yup": "0.29.3"
+ "yup": "0.29.3",
+ "expo-store-review": "2.1.2"
},
"devDependencies": {
"@babel/core": "7.10.2",