From 9a403359b81f665e0ead8057dbc44721f09f9391 Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Wed, 14 Feb 2024 00:37:54 -0800 Subject: [PATCH 1/8] Working copy of feature that adjusts title when ID is changed in HomeScreen after pressing 'Navigate to ConditionsSection'; must have device connected on same network and use ipconfig or ifconfig to put IP address in requests.ts const API_BASE_URL otherwise network error is received --- dfm-sideline-sidekick-app/App.tsx | 62 +- .../ConditionsSection.tsx | 48 +- dfm-sideline-sidekick-app/HomeScreen.tsx | 30 + dfm-sideline-sidekick-app/emergencies.ts | 86 +++ .../generalPrinciples.ts | 0 dfm-sideline-sidekick-app/package-lock.json | 693 +++++++++++++++++- dfm-sideline-sidekick-app/package.json | 5 + dfm-sideline-sidekick-app/requests.ts | 179 +++++ 8 files changed, 1081 insertions(+), 22 deletions(-) create mode 100644 dfm-sideline-sidekick-app/HomeScreen.tsx create mode 100644 dfm-sideline-sidekick-app/emergencies.ts create mode 100644 dfm-sideline-sidekick-app/generalPrinciples.ts create mode 100644 dfm-sideline-sidekick-app/requests.ts diff --git a/dfm-sideline-sidekick-app/App.tsx b/dfm-sideline-sidekick-app/App.tsx index 3eefbad..3646f76 100644 --- a/dfm-sideline-sidekick-app/App.tsx +++ b/dfm-sideline-sidekick-app/App.tsx @@ -1,21 +1,51 @@ -import { StatusBar } from "expo-status-bar"; -import { StyleSheet, Text, View } from "react-native"; +import { NavigationContainer } from "@react-navigation/native"; +import { createNativeStackNavigator } from "@react-navigation/native-stack"; +// import { StatusBar } from "expo-status-bar"; +// import { StyleSheet, Text, View } from "react-native"; +// import { StyleSheet } from "react-native"; +// import { NativeRouter, Routes, Route } from "react-router-native"; -export default function App() { +import ConditionsSection from "./ConditionsSection"; +import HomeScreen from "./HomeScreen"; + +// In your App.tsx or where your navigation setup resides + +const Stack = createNativeStackNavigator(); + +function App() { return ( - // eslint-disable-next-line @typescript-eslint/no-use-before-define - - Open up App.js to start working on your app! - - + + + + + + ); } -const styles = StyleSheet.create({ - container: { - flex: 1, - backgroundColor: "#fff", - alignItems: "center", - justifyContent: "center", - }, -}); +export default App; + +// export default function App() { +// return ( +// // eslint-disable-next-line @typescript-eslint/no-use-before-define +// +// {/* Open up App.js to start working on your app! */} +// {/* */} +// +// +// } /> +// } /> +// +// +// +// +// ); +// } +// const styles = StyleSheet.create({ +// container: { +// flex: 1, +// backgroundColor: "#fff", +// alignItems: "center", +// justifyContent: "center", +// }, +// }); diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index 790b46d..5481616 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -1,14 +1,43 @@ +// import { useRoute } from "@react-navigation/native"; +import { ParamListBase, RouteProp } from "@react-navigation/native"; +import { StackNavigationProp } from "@react-navigation/stack"; import * as Font from "expo-font"; import { useEffect, useState } from "react"; +// eslint-disable-next-line import/namespace import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; import styles from "./ConditionSectionStyles"; +import { getEmergency } from "./emergencies"; -export default function ConditionsSection() { +import type { Emergency } from "./emergencies"; + +export type RootStackParamList = { + // Define the parameters for your screens here + Conditions: { emergencyObjectId: string }; // Example parameter +} & ParamListBase; + +// Define the type for the route parameters +type ConditionsScreenRouteProp = RouteProp; + +// Define the type for the navigation object +type ConditionsScreenNavigationProp = StackNavigationProp; + +type Props = { + route: ConditionsScreenRouteProp; + navigation: ConditionsScreenNavigationProp; +}; + +// eslint-disable-next-line @typescript-eslint/no-unused-vars +export default function ConditionsSection({ route, navigation }: Props) { const [isOverviewPressed, setIsOverviewPressed] = useState(true); const [isTreatmentPressed, setIsTreatmentPressed] = useState(false); const [isFontsLoaded, setIsFontsLoaded] = useState(false); + // const route = useRoute(); + const { params } = route; // Destructure params from the route object + //const { emergencyObjectId } = route.params(); + const [emergency, setEmergency] = useState(); + useEffect(() => { async function loadFont() { try { @@ -27,6 +56,20 @@ export default function ConditionsSection() { void loadFont(); }, []); + useEffect(() => { + if (params?.emergencyObjectId) { + // Check if params and emergencyObjectId exist + // eslint-disable-next-line @typescript-eslint/no-floating-promises + getEmergency(params.emergencyObjectId).then((result) => { + if (result.success) { + setEmergency(result.data); + } else { + console.error("Error fetching emergency data:", result.error); + } + }); + } + }, [params]); // Include params in the dependency array + type BulletListProps = { items: string[]; }; @@ -67,7 +110,8 @@ export default function ConditionsSection() { Medical Emergency - Cervical Spine Injury + {/* Cervical Spine Injury */} + {emergency && {emergency.title}} diff --git a/dfm-sideline-sidekick-app/HomeScreen.tsx b/dfm-sideline-sidekick-app/HomeScreen.tsx new file mode 100644 index 0000000..18cf4c2 --- /dev/null +++ b/dfm-sideline-sidekick-app/HomeScreen.tsx @@ -0,0 +1,30 @@ +import { useNavigation } from "@react-navigation/native"; +// import { useRoute } from "@react-navigation/native"; +// import * as Font from "expo-font"; +// import { useEffect, useState } from "react"; +// import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; +// eslint-disable-next-line import/namespace +import { Pressable, Text } from "react-native"; +// import styles from "./ConditionSectionStyles"; +// import { getEmergency } from "./emergencies"; + +// import type { Emergency } from "./emergencies"; + +export default function HomeScreen() { + const navigation = useNavigation(); + + const handlePress = () => { + // Test Case: Cervical Spine Injury + const emergencyObjectId = "65b36d110c9c60394b37f7a1"; // Replace with the actual ID + //Separate Test Case here: To Be Deleted Emergency + //const emergencyObjectId = "65b369a8e8fe96a404d4fd6b"; // Replace with the actual ID + + navigation.navigate("Conditions", { emergencyObjectId }); + }; + + return ( + + Navigate to ConditionsSection + + ); +} diff --git a/dfm-sideline-sidekick-app/emergencies.ts b/dfm-sideline-sidekick-app/emergencies.ts new file mode 100644 index 0000000..8904bbc --- /dev/null +++ b/dfm-sideline-sidekick-app/emergencies.ts @@ -0,0 +1,86 @@ +import { get, handleAPIError, post, put } from "./requests"; + +import type { APIResult } from "./requests"; + +export type Emergency = { + _id: string; + title: string; + overview?: object; + treatment?: object; + content?: object; +}; + +/** + * The expected inputs when we want to create a new Task object. In the MVP, we only + * need to provide the title and optionally the description, but in the course of + * this tutorial you'll likely want to add more fields here. + */ +export type CreateEmergencyRequest = { + title: string; + overview?: object; + treatment?: object; + content?: object; +}; + +/** + * The expected inputs when we want to update an existing Task object. Similar to + * `CreateTaskRequest`. + */ +export type UpdateEmergencyRequest = { + _id: string; + title: string; + overview?: object; + treatment?: object; + content?: object; +}; + +/** + * The implementations of these API client functions are provided as part of the + * MVP. You can use them as a guide for writing the other client functions. + */ +export async function createEmergency( + emergency: CreateEmergencyRequest, +): Promise> { + try { + const response = await post("/api/emergencies", emergency); + const json = (await response.json()) as Emergency; + return { success: true, data: json }; + } catch (error) { + return handleAPIError(error); + } +} + +export async function getEmergency(id: string): Promise> { + try { + const response = await get(`/api/emergencies/${id}`); + const json = (await response.json()) as Emergency; + return { success: true, data: json }; + } catch (error) { + return handleAPIError(error); + } +} + +export async function getAllEmergencies(): Promise> { + try { + const response = await get(`/api/emergencies/`); + const json = (await response.json()) as Emergency[]; + // const parsedJson = json.map((element) => (element)); + return { success: true, data: json }; + // your code here + } catch (error) { + return handleAPIError(error); + } +} + +export async function updateEmergency( + emergency: UpdateEmergencyRequest, +): Promise> { + try { + // your code here + const response = await put(`/api/emergencies/${emergency._id}`, emergency); + const json = (await response.json()) as Emergency; + return { success: true, data: json }; + } catch (error) { + return handleAPIError(error); + } +} diff --git a/dfm-sideline-sidekick-app/generalPrinciples.ts b/dfm-sideline-sidekick-app/generalPrinciples.ts new file mode 100644 index 0000000..e69de29 diff --git a/dfm-sideline-sidekick-app/package-lock.json b/dfm-sideline-sidekick-app/package-lock.json index 5d5b4f2..4b3fc59 100644 --- a/dfm-sideline-sidekick-app/package-lock.json +++ b/dfm-sideline-sidekick-app/package-lock.json @@ -8,11 +8,16 @@ "name": "dfm-sideline-sidekick-app", "version": "1.0.0", "dependencies": { + "@react-navigation/native": "^6.1.10", + "@react-navigation/native-stack": "^6.9.18", + "@react-navigation/stack": "^6.3.21", "@types/react": "~18.2.14", "expo": "~49.0.15", "expo-status-bar": "~1.6.0", "react": "18.2.0", "react-native": "0.72.6", + "react-router-dom": "^6.22.0", + "react-router-native": "^6.22.0", "typescript": "^5.1.3" }, "devDependencies": { @@ -1999,6 +2004,18 @@ "node": ">=6.9.0" } }, + "node_modules/@egjs/hammerjs": { + "version": "2.0.17", + "resolved": "https://registry.npmjs.org/@egjs/hammerjs/-/hammerjs-2.0.17.tgz", + "integrity": "sha512-XQsZgjm2EcVUiZQf11UBJQfmZeEmOW8DpI1gsFeln6w0ae0ii4dMQEQ0kjl6DspdWX1aGY1/loyXnP0JS06e/A==", + "peer": true, + "dependencies": { + "@types/hammerjs": "^2.0.36" + }, + "engines": { + "node": ">=0.8.0" + } + }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -6102,6 +6119,125 @@ "react-native": "*" } }, + "node_modules/@react-navigation/core": { + "version": "6.4.10", + "resolved": "https://registry.npmjs.org/@react-navigation/core/-/core-6.4.10.tgz", + "integrity": "sha512-oYhqxETRHNHKsipm/BtGL0LI43Hs2VSFoWMbBdHK9OqgQPjTVUitslgLcPpo4zApCcmBWoOLX2qPxhsBda644A==", + "dependencies": { + "@react-navigation/routers": "^6.1.9", + "escape-string-regexp": "^4.0.0", + "nanoid": "^3.1.23", + "query-string": "^7.1.3", + "react-is": "^16.13.0", + "use-latest-callback": "^0.1.7" + }, + "peerDependencies": { + "react": "*" + } + }, + "node_modules/@react-navigation/core/node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@react-navigation/core/node_modules/react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" + }, + "node_modules/@react-navigation/elements": { + "version": "1.3.22", + "resolved": "https://registry.npmjs.org/@react-navigation/elements/-/elements-1.3.22.tgz", + "integrity": "sha512-HYKucs0TwQT8zMvgoZbJsY/3sZfzeP8Dk9IDv4agst3zlA7ReTx4+SROCG6VGC7JKqBCyQykHIwkSwxhapoc+Q==", + "peerDependencies": { + "@react-navigation/native": "^6.0.0", + "react": "*", + "react-native": "*", + "react-native-safe-area-context": ">= 3.0.0" + } + }, + "node_modules/@react-navigation/native": { + "version": "6.1.10", + "resolved": "https://registry.npmjs.org/@react-navigation/native/-/native-6.1.10.tgz", + "integrity": "sha512-jDG89TbZItY7W7rIcS1RqT63vWOPD4XuQLNKqZO0DY7mKnKh/CGBd0eg3nDMXUl143Qp//IxJKe2TfBQRDEU4A==", + "dependencies": { + "@react-navigation/core": "^6.4.10", + "escape-string-regexp": "^4.0.0", + "fast-deep-equal": "^3.1.3", + "nanoid": "^3.1.23" + }, + "peerDependencies": { + "react": "*", + "react-native": "*" + } + }, + "node_modules/@react-navigation/native-stack": { + "version": "6.9.18", + "resolved": "https://registry.npmjs.org/@react-navigation/native-stack/-/native-stack-6.9.18.tgz", + "integrity": "sha512-PSe0qjROy8zD78ehW048NSuzWRktioSCJmB8LzWSR65ndgVaC2rO+xvgyjhHjqm01YdyVM1XTct2EorSjDV2Ow==", + "dependencies": { + "@react-navigation/elements": "^1.3.22", + "warn-once": "^0.1.0" + }, + "peerDependencies": { + "@react-navigation/native": "^6.0.0", + "react": "*", + "react-native": "*", + "react-native-safe-area-context": ">= 3.0.0", + "react-native-screens": ">= 3.0.0" + } + }, + "node_modules/@react-navigation/native/node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@react-navigation/routers": { + "version": "6.1.9", + "resolved": "https://registry.npmjs.org/@react-navigation/routers/-/routers-6.1.9.tgz", + "integrity": "sha512-lTM8gSFHSfkJvQkxacGM6VJtBt61ip2XO54aNfswD+KMw6eeZ4oehl7m0me3CR9hnDE4+60iAZR8sAhvCiI3NA==", + "dependencies": { + "nanoid": "^3.1.23" + } + }, + "node_modules/@react-navigation/stack": { + "version": "6.3.21", + "resolved": "https://registry.npmjs.org/@react-navigation/stack/-/stack-6.3.21.tgz", + "integrity": "sha512-oh059bD9w6Q7YbcK3POXRHK+bfoafPU9gvunD0MHJGmPVe9bazn5OMNzRYextvB6BfwQy+v3dy76Opf0vIGcNg==", + "dependencies": { + "@react-navigation/elements": "^1.3.22", + "color": "^4.2.3", + "warn-once": "^0.1.0" + }, + "peerDependencies": { + "@react-navigation/native": "^6.0.0", + "react": "*", + "react-native": "*", + "react-native-gesture-handler": ">= 1.0.0", + "react-native-safe-area-context": ">= 3.0.0", + "react-native-screens": ">= 3.0.0" + } + }, + "node_modules/@remix-run/router": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.15.0.tgz", + "integrity": "sha512-HOil5aFtme37dVQTB6M34G95kPM3MMuqSmIRVCC52eKV+Y/tGSqw9P3rWhlAx6A+mz+MoX+XxsGsNJbaI5qCgQ==", + "engines": { + "node": ">=14.0.0" + } + }, "node_modules/@segment/loosely-validate-event": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/@segment/loosely-validate-event/-/loosely-validate-event-2.0.0.tgz", @@ -6150,6 +6286,12 @@ "@sinonjs/commons": "^3.0.0" } }, + "node_modules/@types/hammerjs": { + "version": "2.0.45", + "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.45.tgz", + "integrity": "sha512-qkcUlZmX6c4J8q45taBKTL3p+LbITgyx7qhlPYOdOHZB7B31K0mXbP5YA7i7SgDeEGuI9MnumiKPEMrxg8j3KQ==", + "peer": true + }, "node_modules/@types/istanbul-lib-coverage": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", @@ -6554,6 +6696,11 @@ "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", "dev": true }, + "node_modules/@ungap/url-search-params": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/@ungap/url-search-params/-/url-search-params-0.2.2.tgz", + "integrity": "sha512-qQsguKXZVKdCixOHX9jqnX/K/1HekPDpGKyEcXHT+zR6EjGA7S4boSuelL4uuPv6YfhN0n8c4UxW+v/Z3gM2iw==" + }, "node_modules/@urql/core": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/@urql/core/-/core-2.3.6.tgz", @@ -7657,6 +7804,18 @@ "node": ">=6" } }, + "node_modules/color": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/color/-/color-4.2.3.tgz", + "integrity": "sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==", + "dependencies": { + "color-convert": "^2.0.1", + "color-string": "^1.9.0" + }, + "engines": { + "node": ">=12.5.0" + } + }, "node_modules/color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -7670,6 +7829,31 @@ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" }, + "node_modules/color-string": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.9.1.tgz", + "integrity": "sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==", + "dependencies": { + "color-name": "^1.0.0", + "simple-swizzle": "^0.2.2" + } + }, + "node_modules/color/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, "node_modules/colorette": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", @@ -7934,6 +8118,14 @@ "node": ">=0.10.0" } }, + "node_modules/decode-uri-component": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", + "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", + "engines": { + "node": ">=0.10" + } + }, "node_modules/deep-extend": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", @@ -9225,8 +9417,7 @@ "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==" }, "node_modules/fast-glob": { "version": "3.3.2", @@ -9347,6 +9538,14 @@ "node": ">=8" } }, + "node_modules/filter-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/filter-obj/-/filter-obj-1.1.0.tgz", + "integrity": "sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/finalhandler": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", @@ -9973,6 +10172,21 @@ "node": ">=8" } }, + "node_modules/hoist-non-react-statics": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz", + "integrity": "sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==", + "peer": true, + "dependencies": { + "react-is": "^16.7.0" + } + }, + "node_modules/hoist-non-react-statics/node_modules/react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "peer": true + }, "node_modules/hosted-git-info": { "version": "3.0.8", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-3.0.8.tgz", @@ -14092,6 +14306,23 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/query-string": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/query-string/-/query-string-7.1.3.tgz", + "integrity": "sha512-hh2WYhq4fi8+b+/2Kg9CEge4fDPvHS534aOOvOZeQ3+Vf2mCFsaFBYj0i+iXcAq6I9Vzp5fjMFBlONvayDC1qg==", + "dependencies": { + "decode-uri-component": "^0.2.2", + "filter-obj": "^1.1.0", + "split-on-first": "^1.0.0", + "strict-uri-encode": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/querystringify": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", @@ -14200,6 +14431,40 @@ } } }, + "node_modules/react-dom": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.2.0.tgz", + "integrity": "sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0", + "scheduler": "^0.23.0" + }, + "peerDependencies": { + "react": "^18.2.0" + } + }, + "node_modules/react-dom/node_modules/scheduler": { + "version": "0.23.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.0.tgz", + "integrity": "sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + } + }, + "node_modules/react-freeze": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/react-freeze/-/react-freeze-1.0.3.tgz", + "integrity": "sha512-ZnXwLQnGzrDpHBHiC56TXFXvmolPeMjTn1UOm610M4EXGzbEDR7oOIyS2ZiItgbs6eZc4oU/a0hpk8PrcKvv5g==", + "peer": true, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "react": ">=17.0.0" + } + }, "node_modules/react-is": { "version": "17.0.2", "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", @@ -14257,6 +14522,47 @@ "react": "18.2.0" } }, + "node_modules/react-native-gesture-handler": { + "version": "2.15.0", + "resolved": "https://registry.npmjs.org/react-native-gesture-handler/-/react-native-gesture-handler-2.15.0.tgz", + "integrity": "sha512-cmMGW8k86o/xgVTBZZOPohvR5re4Vh65PUxH4HbBBJAYTog4aN4wTVTUlnoky01HuSN8/X4h3tI/K3XLPoDnsg==", + "peer": true, + "dependencies": { + "@egjs/hammerjs": "^2.0.17", + "hoist-non-react-statics": "^3.3.0", + "invariant": "^2.2.4", + "lodash": "^4.17.21", + "prop-types": "^15.7.2" + }, + "peerDependencies": { + "react": "*", + "react-native": "*" + } + }, + "node_modules/react-native-safe-area-context": { + "version": "4.9.0", + "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.9.0.tgz", + "integrity": "sha512-/OJD9Pb8IURyvn+1tWTszWPJqsbZ4hyHBU9P0xhOmk7h5owSuqL0zkfagU0pg7Vh0G2NKQkaPpUKUMMCUMDh/w==", + "peer": true, + "peerDependencies": { + "react": "*", + "react-native": "*" + } + }, + "node_modules/react-native-screens": { + "version": "3.29.0", + "resolved": "https://registry.npmjs.org/react-native-screens/-/react-native-screens-3.29.0.tgz", + "integrity": "sha512-yB1GoAMamFAcYf4ku94uBPn0/ani9QG7NdI98beJ5cet2YFESYYzuEIuU+kt+CNRcO8qqKeugxlfgAa3HyTqlg==", + "peer": true, + "dependencies": { + "react-freeze": "^1.0.0", + "warn-once": "^0.1.0" + }, + "peerDependencies": { + "react": "*", + "react-native": "*" + } + }, "node_modules/react-native/node_modules/promise": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/promise/-/promise-8.3.0.tgz", @@ -14286,6 +14592,52 @@ "node": ">=0.10.0" } }, + "node_modules/react-router": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.22.0.tgz", + "integrity": "sha512-q2yemJeg6gw/YixRlRnVx6IRJWZD6fonnfZhN1JIOhV2iJCPeRNSH3V1ISwHf+JWcESzLC3BOLD1T07tmO5dmg==", + "dependencies": { + "@remix-run/router": "1.15.0" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "react": ">=16.8" + } + }, + "node_modules/react-router-dom": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.22.0.tgz", + "integrity": "sha512-z2w+M4tH5wlcLmH3BMMOMdrtrJ9T3oJJNsAlBJbwk+8Syxd5WFJ7J5dxMEW0/GEXD1BBis4uXRrNIz3mORr0ag==", + "dependencies": { + "@remix-run/router": "1.15.0", + "react-router": "6.22.0" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "react": ">=16.8", + "react-dom": ">=16.8" + } + }, + "node_modules/react-router-native": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router-native/-/react-router-native-6.22.0.tgz", + "integrity": "sha512-liTx9D6VbiTKAYMmO5sZ3pvWEycxdhO4vec8zbhBwFZx9Ul4ZMsBkevtBo+gjZ9j57VYGOJ+BO0+Vqfu3Mh7vA==", + "dependencies": { + "@ungap/url-search-params": "^0.2.2", + "react-router": "6.22.0" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "react": ">=16.8", + "react-native": ">=0.44" + } + }, "node_modules/react-shallow-renderer": { "version": "16.15.0", "resolved": "https://registry.npmjs.org/react-shallow-renderer/-/react-shallow-renderer-16.15.0.tgz", @@ -14869,6 +15221,19 @@ "node": ">= 5.10.0" } }, + "node_modules/simple-swizzle": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", + "integrity": "sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==", + "dependencies": { + "is-arrayish": "^0.3.1" + } + }, + "node_modules/simple-swizzle/node_modules/is-arrayish": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", + "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" + }, "node_modules/sisteransi": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", @@ -14947,6 +15312,14 @@ "node": "*" } }, + "node_modules/split-on-first": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/split-on-first/-/split-on-first-1.1.0.tgz", + "integrity": "sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==", + "engines": { + "node": ">=6" + } + }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -15022,6 +15395,14 @@ "node": ">= 0.10.0" } }, + "node_modules/strict-uri-encode": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz", + "integrity": "sha512-QwiXZgpRcKkhTj2Scnn++4PKtWsH0kpzZ62L2R6c/LUVYv7hVnZqcg2+sMuT6R7Jusu1vviK/MFsu6kNJfWlEQ==", + "engines": { + "node": ">=4" + } + }, "node_modules/string_decoder": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -15989,6 +16370,14 @@ "requires-port": "^1.0.0" } }, + "node_modules/use-latest-callback": { + "version": "0.1.9", + "resolved": "https://registry.npmjs.org/use-latest-callback/-/use-latest-callback-0.1.9.tgz", + "integrity": "sha512-CL/29uS74AwreI/f2oz2hLTW7ZqVeV5+gxFeGudzQrgkCytrHw33G4KbnQOrRlAEzzAFXi7dDLMC9zhWcVpzmw==", + "peerDependencies": { + "react": ">=16.8" + } + }, "node_modules/use-sync-external-store": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", @@ -16053,6 +16442,11 @@ "makeerror": "1.0.12" } }, + "node_modules/warn-once": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/warn-once/-/warn-once-0.1.1.tgz", + "integrity": "sha512-VkQZJbO8zVImzYFteBXvBOZEl1qL175WH8VmZcxF2fZAoudNhNDvHi+doCaAEdU2l2vtcIwa2zn0QK5+I1HQ3Q==" + }, "node_modules/wcwidth": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", @@ -17738,6 +18132,15 @@ "to-fast-properties": "^2.0.0" } }, + "@egjs/hammerjs": { + "version": "2.0.17", + "resolved": "https://registry.npmjs.org/@egjs/hammerjs/-/hammerjs-2.0.17.tgz", + "integrity": "sha512-XQsZgjm2EcVUiZQf11UBJQfmZeEmOW8DpI1gsFeln6w0ae0ii4dMQEQ0kjl6DspdWX1aGY1/loyXnP0JS06e/A==", + "peer": true, + "requires": { + "@types/hammerjs": "^2.0.36" + } + }, "@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -20751,6 +21154,87 @@ "nullthrows": "^1.1.1" } }, + "@react-navigation/core": { + "version": "6.4.10", + "resolved": "https://registry.npmjs.org/@react-navigation/core/-/core-6.4.10.tgz", + "integrity": "sha512-oYhqxETRHNHKsipm/BtGL0LI43Hs2VSFoWMbBdHK9OqgQPjTVUitslgLcPpo4zApCcmBWoOLX2qPxhsBda644A==", + "requires": { + "@react-navigation/routers": "^6.1.9", + "escape-string-regexp": "^4.0.0", + "nanoid": "^3.1.23", + "query-string": "^7.1.3", + "react-is": "^16.13.0", + "use-latest-callback": "^0.1.7" + }, + "dependencies": { + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" + }, + "react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" + } + } + }, + "@react-navigation/elements": { + "version": "1.3.22", + "resolved": "https://registry.npmjs.org/@react-navigation/elements/-/elements-1.3.22.tgz", + "integrity": "sha512-HYKucs0TwQT8zMvgoZbJsY/3sZfzeP8Dk9IDv4agst3zlA7ReTx4+SROCG6VGC7JKqBCyQykHIwkSwxhapoc+Q==", + "requires": {} + }, + "@react-navigation/native": { + "version": "6.1.10", + "resolved": "https://registry.npmjs.org/@react-navigation/native/-/native-6.1.10.tgz", + "integrity": "sha512-jDG89TbZItY7W7rIcS1RqT63vWOPD4XuQLNKqZO0DY7mKnKh/CGBd0eg3nDMXUl143Qp//IxJKe2TfBQRDEU4A==", + "requires": { + "@react-navigation/core": "^6.4.10", + "escape-string-regexp": "^4.0.0", + "fast-deep-equal": "^3.1.3", + "nanoid": "^3.1.23" + }, + "dependencies": { + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" + } + } + }, + "@react-navigation/native-stack": { + "version": "6.9.18", + "resolved": "https://registry.npmjs.org/@react-navigation/native-stack/-/native-stack-6.9.18.tgz", + "integrity": "sha512-PSe0qjROy8zD78ehW048NSuzWRktioSCJmB8LzWSR65ndgVaC2rO+xvgyjhHjqm01YdyVM1XTct2EorSjDV2Ow==", + "requires": { + "@react-navigation/elements": "^1.3.22", + "warn-once": "^0.1.0" + } + }, + "@react-navigation/routers": { + "version": "6.1.9", + "resolved": "https://registry.npmjs.org/@react-navigation/routers/-/routers-6.1.9.tgz", + "integrity": "sha512-lTM8gSFHSfkJvQkxacGM6VJtBt61ip2XO54aNfswD+KMw6eeZ4oehl7m0me3CR9hnDE4+60iAZR8sAhvCiI3NA==", + "requires": { + "nanoid": "^3.1.23" + } + }, + "@react-navigation/stack": { + "version": "6.3.21", + "resolved": "https://registry.npmjs.org/@react-navigation/stack/-/stack-6.3.21.tgz", + "integrity": "sha512-oh059bD9w6Q7YbcK3POXRHK+bfoafPU9gvunD0MHJGmPVe9bazn5OMNzRYextvB6BfwQy+v3dy76Opf0vIGcNg==", + "requires": { + "@react-navigation/elements": "^1.3.22", + "color": "^4.2.3", + "warn-once": "^0.1.0" + } + }, + "@remix-run/router": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.15.0.tgz", + "integrity": "sha512-HOil5aFtme37dVQTB6M34G95kPM3MMuqSmIRVCC52eKV+Y/tGSqw9P3rWhlAx6A+mz+MoX+XxsGsNJbaI5qCgQ==" + }, "@segment/loosely-validate-event": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/@segment/loosely-validate-event/-/loosely-validate-event-2.0.0.tgz", @@ -20799,6 +21283,12 @@ "@sinonjs/commons": "^3.0.0" } }, + "@types/hammerjs": { + "version": "2.0.45", + "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.45.tgz", + "integrity": "sha512-qkcUlZmX6c4J8q45taBKTL3p+LbITgyx7qhlPYOdOHZB7B31K0mXbP5YA7i7SgDeEGuI9MnumiKPEMrxg8j3KQ==", + "peer": true + }, "@types/istanbul-lib-coverage": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", @@ -21087,6 +21577,11 @@ "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", "dev": true }, + "@ungap/url-search-params": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/@ungap/url-search-params/-/url-search-params-0.2.2.tgz", + "integrity": "sha512-qQsguKXZVKdCixOHX9jqnX/K/1HekPDpGKyEcXHT+zR6EjGA7S4boSuelL4uuPv6YfhN0n8c4UxW+v/Z3gM2iw==" + }, "@urql/core": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/@urql/core/-/core-2.3.6.tgz", @@ -21910,6 +22405,30 @@ "shallow-clone": "^3.0.0" } }, + "color": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/color/-/color-4.2.3.tgz", + "integrity": "sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==", + "requires": { + "color-convert": "^2.0.1", + "color-string": "^1.9.0" + }, + "dependencies": { + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + } + } + }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -21923,6 +22442,15 @@ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" }, + "color-string": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.9.1.tgz", + "integrity": "sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==", + "requires": { + "color-name": "^1.0.0", + "simple-swizzle": "^0.2.2" + } + }, "colorette": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", @@ -22139,6 +22667,11 @@ "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==" }, + "decode-uri-component": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", + "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==" + }, "deep-extend": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", @@ -23125,8 +23658,7 @@ "fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==" }, "fast-glob": { "version": "3.3.2", @@ -23225,6 +23757,11 @@ "to-regex-range": "^5.0.1" } }, + "filter-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/filter-obj/-/filter-obj-1.1.0.tgz", + "integrity": "sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ==" + }, "finalhandler": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", @@ -23670,6 +24207,23 @@ "source-map": "^0.7.3" } }, + "hoist-non-react-statics": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz", + "integrity": "sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==", + "peer": true, + "requires": { + "react-is": "^16.7.0" + }, + "dependencies": { + "react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "peer": true + } + } + }, "hosted-git-info": { "version": "3.0.8", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-3.0.8.tgz", @@ -26640,6 +27194,17 @@ "side-channel": "^1.0.4" } }, + "query-string": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/query-string/-/query-string-7.1.3.tgz", + "integrity": "sha512-hh2WYhq4fi8+b+/2Kg9CEge4fDPvHS534aOOvOZeQ3+Vf2mCFsaFBYj0i+iXcAq6I9Vzp5fjMFBlONvayDC1qg==", + "requires": { + "decode-uri-component": "^0.2.2", + "filter-obj": "^1.1.0", + "split-on-first": "^1.0.0", + "strict-uri-encode": "^2.0.0" + } + }, "querystringify": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", @@ -26710,6 +27275,34 @@ } } }, + "react-dom": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.2.0.tgz", + "integrity": "sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0", + "scheduler": "^0.23.0" + }, + "dependencies": { + "scheduler": { + "version": "0.23.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.0.tgz", + "integrity": "sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0" + } + } + } + }, + "react-freeze": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/react-freeze/-/react-freeze-1.0.3.tgz", + "integrity": "sha512-ZnXwLQnGzrDpHBHiC56TXFXvmolPeMjTn1UOm610M4EXGzbEDR7oOIyS2ZiItgbs6eZc4oU/a0hpk8PrcKvv5g==", + "peer": true, + "requires": {} + }, "react-is": { "version": "17.0.2", "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", @@ -26781,11 +27374,67 @@ } } }, + "react-native-gesture-handler": { + "version": "2.15.0", + "resolved": "https://registry.npmjs.org/react-native-gesture-handler/-/react-native-gesture-handler-2.15.0.tgz", + "integrity": "sha512-cmMGW8k86o/xgVTBZZOPohvR5re4Vh65PUxH4HbBBJAYTog4aN4wTVTUlnoky01HuSN8/X4h3tI/K3XLPoDnsg==", + "peer": true, + "requires": { + "@egjs/hammerjs": "^2.0.17", + "hoist-non-react-statics": "^3.3.0", + "invariant": "^2.2.4", + "lodash": "^4.17.21", + "prop-types": "^15.7.2" + } + }, + "react-native-safe-area-context": { + "version": "4.9.0", + "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.9.0.tgz", + "integrity": "sha512-/OJD9Pb8IURyvn+1tWTszWPJqsbZ4hyHBU9P0xhOmk7h5owSuqL0zkfagU0pg7Vh0G2NKQkaPpUKUMMCUMDh/w==", + "peer": true, + "requires": {} + }, + "react-native-screens": { + "version": "3.29.0", + "resolved": "https://registry.npmjs.org/react-native-screens/-/react-native-screens-3.29.0.tgz", + "integrity": "sha512-yB1GoAMamFAcYf4ku94uBPn0/ani9QG7NdI98beJ5cet2YFESYYzuEIuU+kt+CNRcO8qqKeugxlfgAa3HyTqlg==", + "peer": true, + "requires": { + "react-freeze": "^1.0.0", + "warn-once": "^0.1.0" + } + }, "react-refresh": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.4.3.tgz", "integrity": "sha512-Hwln1VNuGl/6bVwnd0Xdn1e84gT/8T9aYNL+HAKDArLCS7LWjwr7StE30IEYbIkx0Vi3vs+coQxe+SQDbGbbpA==" }, + "react-router": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.22.0.tgz", + "integrity": "sha512-q2yemJeg6gw/YixRlRnVx6IRJWZD6fonnfZhN1JIOhV2iJCPeRNSH3V1ISwHf+JWcESzLC3BOLD1T07tmO5dmg==", + "requires": { + "@remix-run/router": "1.15.0" + } + }, + "react-router-dom": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.22.0.tgz", + "integrity": "sha512-z2w+M4tH5wlcLmH3BMMOMdrtrJ9T3oJJNsAlBJbwk+8Syxd5WFJ7J5dxMEW0/GEXD1BBis4uXRrNIz3mORr0ag==", + "requires": { + "@remix-run/router": "1.15.0", + "react-router": "6.22.0" + } + }, + "react-router-native": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/react-router-native/-/react-router-native-6.22.0.tgz", + "integrity": "sha512-liTx9D6VbiTKAYMmO5sZ3pvWEycxdhO4vec8zbhBwFZx9Ul4ZMsBkevtBo+gjZ9j57VYGOJ+BO0+Vqfu3Mh7vA==", + "requires": { + "@ungap/url-search-params": "^0.2.2", + "react-router": "6.22.0" + } + }, "react-shallow-renderer": { "version": "16.15.0", "resolved": "https://registry.npmjs.org/react-shallow-renderer/-/react-shallow-renderer-16.15.0.tgz", @@ -27247,6 +27896,21 @@ } } }, + "simple-swizzle": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", + "integrity": "sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==", + "requires": { + "is-arrayish": "^0.3.1" + }, + "dependencies": { + "is-arrayish": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", + "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" + } + } + }, "sisteransi": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", @@ -27306,6 +27970,11 @@ "through": "2" } }, + "split-on-first": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/split-on-first/-/split-on-first-1.1.0.tgz", + "integrity": "sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==" + }, "sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -27364,6 +28033,11 @@ "resolved": "https://registry.npmjs.org/stream-buffers/-/stream-buffers-2.2.0.tgz", "integrity": "sha512-uyQK/mx5QjHun80FLJTfaWE7JtwfRMKBLkMne6udYOmvH0CawotVa7TfgYHzAnpphn4+TweIx1QKMnRIbipmUg==" }, + "strict-uri-encode": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz", + "integrity": "sha512-QwiXZgpRcKkhTj2Scnn++4PKtWsH0kpzZ62L2R6c/LUVYv7hVnZqcg2+sMuT6R7Jusu1vviK/MFsu6kNJfWlEQ==" + }, "string_decoder": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -28060,6 +28734,12 @@ "requires-port": "^1.0.0" } }, + "use-latest-callback": { + "version": "0.1.9", + "resolved": "https://registry.npmjs.org/use-latest-callback/-/use-latest-callback-0.1.9.tgz", + "integrity": "sha512-CL/29uS74AwreI/f2oz2hLTW7ZqVeV5+gxFeGudzQrgkCytrHw33G4KbnQOrRlAEzzAFXi7dDLMC9zhWcVpzmw==", + "requires": {} + }, "use-sync-external-store": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", @@ -28112,6 +28792,11 @@ "makeerror": "1.0.12" } }, + "warn-once": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/warn-once/-/warn-once-0.1.1.tgz", + "integrity": "sha512-VkQZJbO8zVImzYFteBXvBOZEl1qL175WH8VmZcxF2fZAoudNhNDvHi+doCaAEdU2l2vtcIwa2zn0QK5+I1HQ3Q==" + }, "wcwidth": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", diff --git a/dfm-sideline-sidekick-app/package.json b/dfm-sideline-sidekick-app/package.json index 9dca5da..ab9b8cf 100644 --- a/dfm-sideline-sidekick-app/package.json +++ b/dfm-sideline-sidekick-app/package.json @@ -15,11 +15,16 @@ "prepare": "cd .. && husky install .husky" }, "dependencies": { + "@react-navigation/native": "^6.1.10", + "@react-navigation/native-stack": "^6.9.18", + "@react-navigation/stack": "^6.3.21", "@types/react": "~18.2.14", "expo": "~49.0.15", "expo-status-bar": "~1.6.0", "react": "18.2.0", "react-native": "0.72.6", + "react-router-dom": "^6.22.0", + "react-router-native": "^6.22.0", "typescript": "^5.1.3" }, "devDependencies": { diff --git a/dfm-sideline-sidekick-app/requests.ts b/dfm-sideline-sidekick-app/requests.ts new file mode 100644 index 0000000..76e6d3b --- /dev/null +++ b/dfm-sideline-sidekick-app/requests.ts @@ -0,0 +1,179 @@ +/* eslint-disable @typescript-eslint/no-floating-promises */ +/** + * Based on the TSE Fulcrum API client implementation by justinyaodu: + * https://github.com/TritonSE/TSE-Fulcrum/blob/main/frontend/src/api.ts + */ + +/** + * A custom type defining which HTTP methods we will handle in this file + */ +type Method = "GET" | "POST" | "PUT"; + +/** + * The first part of the backend API URL, which we will automatically prepend to + * every request. This means in the rest of our code, we can write "/api/foo" + * instead of "http://localhost:3001/api/foo". + */ +// const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || "http://localhost:3001"; +// INSERT IP ADDRESS HERE +const API_BASE_URL = "http://100.112.104.53:3001"; + +/** + * A wrapper around the built-in `fetch()` function that abstracts away some of + * the low-level details so we can focus on the important parts of each request. + * See https://developer.mozilla.org/en-US/docs/Web/API/fetch for information + * about the Fetch API. + * + * @param method The HTTP method to use + * @param url The URL to request + * @param body The body of the request, or undefined if there is none + * @param headers The headers of the request + * @returns The Response object returned by `fetch() + */ +async function fetchRequest( + method: Method, + url: string, + body: unknown, + headers: Record, +): Promise { + const hasBody = body !== undefined; + + const newHeaders = { ...headers }; + if (hasBody) { + newHeaders["Content-Type"] = "application/json"; + } + + const response = await fetch(url, { + method, + headers: newHeaders, + body: hasBody ? JSON.stringify(body) : undefined, + }); + + return response; +} + +/** + * Throws an error if the given response's status code indicates an error + * occurred, else does nothing. + * + * @param response A response returned by `fetch()` or `fetchRequest()` + * @throws An error if the response was not successful (200-299) or a redirect + * (300-399) + */ +async function assertOk(response: Response): Promise { + if (response.ok) { + return; + } + + let message = `${response.status} ${response.statusText}`; + + try { + const text = await response.text(); + if (text) { + message += ": " + text; + } + } catch (e) { + // skip errors + } + + throw new Error(message); +} + +/** + * Sends a GET request to the provided API URL. + * + * @param url The URL to request + * @param headers The headers of the request (optional) + * @returns The Response object returned by `fetch()` + */ +export async function get(url: string, headers: Record = {}): Promise { + // GET requests do not have a body + const response = await fetchRequest("GET", API_BASE_URL + url, undefined, headers); + assertOk(response); + return response; +} + +/** + * Sends a POST request to the provided API URL. + * + * @param url The URL to request + * @param body The body of the request, or undefined if there is none + * @param headers The headers of the request (optional) + * @returns The Response object returned by `fetch()` + */ +export async function post( + url: string, + body: unknown, + headers: Record = {}, +): Promise { + const response = await fetchRequest("POST", API_BASE_URL + url, body, headers); + assertOk(response); + return response; +} + +/** + * Sends a PUT request to the provided API URL. + * + * @param url The URL to request + * @param body The body of the request, or undefined if there is none + * @param headers The headers of the request (optional) + * @returns The Response object returned by `fetch()` + */ +export async function put( + url: string, + body: unknown, + headers: Record = {}, +): Promise { + const response = await fetchRequest("PUT", API_BASE_URL + url, body, headers); + assertOk(response); + return response; +} + +export type APIData = { success: true; data: T }; +export type APIError = { success: false; error: string }; +/** + * Utility type for the result of an API request. API client functions should + * always return an object of this type (without throwing an exception if + * something goes wrong). This allows users of the functions to perform easier + * error checking without excessive try-catch statements, making use of + * TypeScript's type narrowing feature. Specifically, by checking whether the + * `success` field is true or false, you'll know whether you can access the + * `data` field with the actual API response or the `error` field with an error + * message. + * + * For example, assume we have some API function with the type definition + * `doSomeRequest: (parameters: SomeParameters) => Promise>`. + * Then we could use it in a frontend component as follows: + * ``` + * doSomeRequest(parameters).then((result: APIResult) => { + * if (result.success) { + * console.log(result.data); // do something with the data, which is of type SomeData + * } else { + * console.error(result.error); // do something to inform the user of the error + * } + * }) + * ``` + * + * See `createTask` in `src/api/tasks` and its use in `src/components/TaskForm` + * for a more concrete example, and see + * https://www.typescriptlang.org/docs/handbook/2/narrowing.html for more info + * about type narrowing. + */ +export type APIResult = APIData | APIError; + +/** + * Helper function for API client functions to handle errors consistently. + * Recommended usage is in a `catch` block--see `createTask` in `src/api/tasks` + * for an example. + * + * @param error An error thrown by a lower-level API function + * @returns An `APIError` object with a message from the given error + */ +export function handleAPIError(error: unknown): APIError { + if (error instanceof Error) { + return { success: false, error: error.message }; + } else if (typeof error === "string") { + return { success: false, error }; + } + return { success: false, error: `Unknown error: ${String(error)}` }; +} From a62facb68509a2182c3eea5aa249262430bac8f8 Mon Sep 17 00:00:00 2001 From: Eshaan Sharma Date: Wed, 14 Feb 2024 21:49:58 -0800 Subject: [PATCH 2/8] Implemented the rest of the dynamic emergency page layout --- .../ConditionsSection.tsx | 47 +++++++++---------- dfm-sideline-sidekick-app/emergencies.ts | 16 ++++++- dfm-sideline-sidekick-app/requests.ts | 5 +- 3 files changed, 38 insertions(+), 30 deletions(-) diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index 5481616..f8cb12b 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -33,11 +33,23 @@ export default function ConditionsSection({ route, navigation }: Props) { const [isTreatmentPressed, setIsTreatmentPressed] = useState(false); const [isFontsLoaded, setIsFontsLoaded] = useState(false); + // const route = useRoute(); const { params } = route; // Destructure params from the route object //const { emergencyObjectId } = route.params(); const [emergency, setEmergency] = useState(); + const mechanismArray: string[] = emergency?.overview?.["Mechanism of Injury"] ?? []; + const diagnosisArray: string[] = emergency?.overview?.Diagnosis ?? []; + const physicalArray: string[] = emergency?.overview?.["Physical Exam"] ?? []; + + const accuteArray: string[] = emergency?.treatment?.["Acute Management"] ?? []; + const dispoArray: string[] = emergency?.treatment?.Dispo ?? []; + const contentArray: string[] = emergency?.treatment?.Considerations.Content ?? []; + + + + useEffect(() => { async function loadFont() { try { @@ -138,31 +150,24 @@ export default function ConditionsSection({ route, navigation }: Props) { Importance - The cervical spine is not stabilized or protected by ribs or other surrounding - structures, so fractures are more common and can be unstable. This creates risk for - potential damage to the spinal cord resulting in quadriplegia and death and could be - made worse by moving patients without proper immobilization + {emergency?.overview?.Importance} Mechanism of Injury - + Diagnosis - + Physical Exam - + + @@ -170,32 +175,22 @@ export default function ConditionsSection({ route, navigation }: Props) { Acute Management Dispo - + Considerations - If any suspicion for injury, send to ED. However, less likely if the following - criteria are met: + {emergency?.treatment.Considerations.Header} diff --git a/dfm-sideline-sidekick-app/emergencies.ts b/dfm-sideline-sidekick-app/emergencies.ts index 8904bbc..9e8e2b6 100644 --- a/dfm-sideline-sidekick-app/emergencies.ts +++ b/dfm-sideline-sidekick-app/emergencies.ts @@ -5,8 +5,20 @@ import type { APIResult } from "./requests"; export type Emergency = { _id: string; title: string; - overview?: object; - treatment?: object; + overview:{ + Importance: string; + 'Mechanism of Injury': string[]; + Diagnosis: string[]; + 'Physical Exam': string[]; + }; + treatment:{ + 'Acute Management': string[]; + Dispo: string[]; + Considerations:{ + Header: string; + Content: string[]; + }; + }; content?: object; }; diff --git a/dfm-sideline-sidekick-app/requests.ts b/dfm-sideline-sidekick-app/requests.ts index 76e6d3b..cf920e2 100644 --- a/dfm-sideline-sidekick-app/requests.ts +++ b/dfm-sideline-sidekick-app/requests.ts @@ -14,9 +14,10 @@ type Method = "GET" | "POST" | "PUT"; * every request. This means in the rest of our code, we can write "/api/foo" * instead of "http://localhost:3001/api/foo". */ -// const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || "http://localhost:3001"; +//const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || "http://localhost:3001"; // INSERT IP ADDRESS HERE -const API_BASE_URL = "http://100.112.104.53:3001"; +const API_BASE_URL = "http://100.83.62.24:3001"; + /** * A wrapper around the built-in `fetch()` function that abstracts away some of From d4ef9366b283461614ffabb0d798a13ffcca686b Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Thu, 15 Feb 2024 20:22:57 -0800 Subject: [PATCH 3/8] Implemented recursive dynamic header rendering as discussed in 2-15 meeting demo --- .idea/.gitignore | 3 + .idea/DFM-Sideline-Sidekick-App.iml | 9 + .idea/modules.xml | 8 + .idea/vcs.xml | 6 + .../ConditionsSection.tsx | 228 ++- dfm-sideline-sidekick-app/HomeScreen.tsx | 15 +- .../components/BulletPoint.tsx | 55 + .../components/BulletPointStyles.tsx | 42 + .../components/StringRenderer.tsx | 43 + dfm-sideline-sidekick-app/emergencies.ts | 36 +- dfm-sideline-sidekick-app/package-lock.json | 1298 ++++++++++++++++- dfm-sideline-sidekick-app/package.json | 6 + .../pages/EmergencyCare.tsx | 32 + .../pages/generalPrinciples.tsx | 54 + .../pages/generalPrinciplesStyles.tsx | 34 + dfm-sideline-sidekick-app/requests.ts | 6 +- 16 files changed, 1783 insertions(+), 92 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/DFM-Sideline-Sidekick-App.iml create mode 100644 .idea/modules.xml create mode 100644 .idea/vcs.xml create mode 100644 dfm-sideline-sidekick-app/components/BulletPoint.tsx create mode 100644 dfm-sideline-sidekick-app/components/BulletPointStyles.tsx create mode 100644 dfm-sideline-sidekick-app/components/StringRenderer.tsx create mode 100644 dfm-sideline-sidekick-app/pages/EmergencyCare.tsx create mode 100644 dfm-sideline-sidekick-app/pages/generalPrinciples.tsx create mode 100644 dfm-sideline-sidekick-app/pages/generalPrinciplesStyles.tsx diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/DFM-Sideline-Sidekick-App.iml b/.idea/DFM-Sideline-Sidekick-App.iml new file mode 100644 index 0000000..d6ebd48 --- /dev/null +++ b/.idea/DFM-Sideline-Sidekick-App.iml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..5dc45f0 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index f8cb12b..0bcf2ef 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -7,6 +7,7 @@ import { useEffect, useState } from "react"; import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; import styles from "./ConditionSectionStyles"; +import StringRenderer from "./components/StringRenderer"; import { getEmergency } from "./emergencies"; import type { Emergency } from "./emergencies"; @@ -27,28 +28,43 @@ type Props = { navigation: ConditionsScreenNavigationProp; }; +type StringValue = string | string[] | { [key: string]: StringValue }; + // eslint-disable-next-line @typescript-eslint/no-unused-vars export default function ConditionsSection({ route, navigation }: Props) { const [isOverviewPressed, setIsOverviewPressed] = useState(true); const [isTreatmentPressed, setIsTreatmentPressed] = useState(false); const [isFontsLoaded, setIsFontsLoaded] = useState(false); - + const [overviewHeaders, setOverviewHeaders] = useState([]); + const [overviewValues, setOverviewValues] = useState([]); + const [treatmentHeaders, setTreatmentHeaders] = useState([]); + const [treatmentValues, setTreatmentValues] = useState([]); + const [contentHeaders, setContentHeaders] = useState([]); + const [contentValues, setContentValues] = useState([]); // const route = useRoute(); const { params } = route; // Destructure params from the route object //const { emergencyObjectId } = route.params(); const [emergency, setEmergency] = useState(); - const mechanismArray: string[] = emergency?.overview?.["Mechanism of Injury"] ?? []; - const diagnosisArray: string[] = emergency?.overview?.Diagnosis ?? []; - const physicalArray: string[] = emergency?.overview?.["Physical Exam"] ?? []; + // Assuming emergency is of type Emergency + // if (emergency?.overview && typeof emergency.overview === "object") { + // setOverviewHeaders(Object.keys(emergency.overview)); + // setOverviewValues(Object.values(emergency.overview)); + // } - const accuteArray: string[] = emergency?.treatment?.["Acute Management"] ?? []; - const dispoArray: string[] = emergency?.treatment?.Dispo ?? []; - const contentArray: string[] = emergency?.treatment?.Considerations.Content ?? []; + // if (emergency?.overview && typeof emergency.overview === "string") { + // //const overviewHeaders = Object.keys(emergency.overview); + // console.log(emergency.overview); + // } + // const mechanismArray: string[] = emergency?.overview?.["Mechanism of Injury"] ?? []; + // const diagnosisArray: string[] = emergency?.overview?.Diagnosis ?? []; + // const physicalArray: string[] = emergency?.overview?.["Physical Exam"] ?? []; - + // const accuteArray: string[] = emergency?.treatment?.["Acute Management"] ?? []; + // const dispoArray: string[] = emergency?.treatment?.Dispo ?? []; + // const contentArray: string[] = emergency?.treatment?.Considerations?.Content ?? []; useEffect(() => { async function loadFont() { @@ -82,20 +98,37 @@ export default function ConditionsSection({ route, navigation }: Props) { } }, [params]); // Include params in the dependency array - type BulletListProps = { - items: string[]; - }; + useEffect(() => { + if (emergency?.overview && typeof emergency.overview === "object") { + setOverviewHeaders(Object.keys(emergency.overview)); + setOverviewValues(Object.values(emergency.overview) as StringValue[]); + } - const BulletList = ({ items }: BulletListProps) => ( - - {items.map((item: string, index: number) => ( - - {"\u2022"} - {item} - - ))} - - ); + if (emergency?.treatment && typeof emergency.treatment === "object") { + setTreatmentHeaders(Object.keys(emergency.treatment)); + setTreatmentValues(Object.values(emergency.treatment) as StringValue[]); + } + + if (emergency?.content && typeof emergency.content === "object") { + setContentHeaders(Object.keys(emergency.content)); + setContentValues(Object.values(emergency.content) as StringValue[]); + } + }, [emergency]); + + // type BulletListProps = { + // items: string[]; + // }; + + // const BulletList = ({ items }: BulletListProps) => ( + // + // {items.map((item: string, index: number) => ( + // + // {"\u2022"} + // {item} + // + // ))} + // + // ); function onOverviewPress() { if (!isOverviewPressed) { @@ -147,52 +180,119 @@ export default function ConditionsSection({ route, navigation }: Props) { - - Importance - - {emergency?.overview?.Importance} - - - - - Mechanism of Injury - - - - - Diagnosis - - - - - Physical Exam - - - + {emergency?.overview && typeof emergency.overview === "string" && ( + + {emergency?.overview} + + )} + + {emergency?.overview && typeof emergency.overview === "object" && ( + + {overviewHeaders.map((header, index) => ( + + {header} + + + ))} + + )} + + {/* {emergency?.overview && ( + + Importance + {emergency?.overview.} + + )} + {emergency?.overview?.Importance && ( + + Importance + {emergency?.overview?.Importance} + + )} + + {mechanismArray.length !== 0 && ( + + Mechanism of Injury + + + )} + + {diagnosisArray.length !== 0 && ( + + Diagnosis + + + )} + + {physicalArray.length !== 0 && ( + + Physical Exam + + + + )} */} - - Acute Management - - - - - Dispo - - - - - Considerations - - {emergency?.treatment.Considerations.Header} - - - + {emergency?.treatment && typeof emergency.treatment === "string" && ( + + {emergency?.treatment} + + )} + + {emergency?.treatment && typeof emergency.treatment === "object" && ( + + {treatmentHeaders.map((header, index) => ( + + {header} + + + ))} + + )} + + {emergency?.content && typeof emergency.content === "string" && ( + + {emergency?.content} + + )} + + {emergency?.content && typeof emergency.content === "object" && ( + + {contentHeaders.map((header, index) => ( + + {header} + + + ))} + + )} + + {/* {accuteArray.length !== 0 && ( + + Acute Management + + + )} + + {dispoArray.length !== 0 && ( + + Dispo + + + )} + + {contentArray.length !== 0 && ( + + Considerations + {emergency?.treatment?.Considerations?.Header && ( + + {emergency?.treatment?.Considerations?.Header} + + )} + + + )} */} diff --git a/dfm-sideline-sidekick-app/HomeScreen.tsx b/dfm-sideline-sidekick-app/HomeScreen.tsx index 18cf4c2..b194a8d 100644 --- a/dfm-sideline-sidekick-app/HomeScreen.tsx +++ b/dfm-sideline-sidekick-app/HomeScreen.tsx @@ -14,11 +14,16 @@ export default function HomeScreen() { const navigation = useNavigation(); const handlePress = () => { - // Test Case: Cervical Spine Injury - const emergencyObjectId = "65b36d110c9c60394b37f7a1"; // Replace with the actual ID - //Separate Test Case here: To Be Deleted Emergency - //const emergencyObjectId = "65b369a8e8fe96a404d4fd6b"; // Replace with the actual ID - + //NOTE TO REVIEWERS: Try the test cases below with different document ids and see if they work on your devices and emulators + //It seems to work on Android and iPad + //Test Case: Cervical Spine Injury - demonstrate recursive rendering + const emergencyObjectId = "65b36d110c9c60394b37f7a1"; + //Separate Test Case here: To Be Deleted Emergency - demonstrates textual rendering + //const emergencyObjectId = "65b369a8e8fe96a404d4fd6b"; + //Test Case: New Emergency Placeholder Four - demonstrates blank rendering (only title in db) + //const emergencyObjectId = "65c2ef26b87b638ac61beb09"; + //Test Case: Cervical Strain - demonstrates simple placeholder headers + //const emergencyObjectId = "65b36f12640d62464e0dd129"; navigation.navigate("Conditions", { emergencyObjectId }); }; diff --git a/dfm-sideline-sidekick-app/components/BulletPoint.tsx b/dfm-sideline-sidekick-app/components/BulletPoint.tsx new file mode 100644 index 0000000..d2d78a9 --- /dev/null +++ b/dfm-sideline-sidekick-app/components/BulletPoint.tsx @@ -0,0 +1,55 @@ +import React from "react"; +import { Text, View } from "react-native"; + +import styles from "./BulletPointStyles"; + +type Subpoint = { + text: string; + subpoints?: Subpoint[]; +}; + +type BulletPointProps = { + letter: string; + text: string; + subpoints?: Subpoint[]; +}; + +const BulletPoint: React.FC = ({ letter, text, subpoints: initSubpoints }) => { + // render subpoints recursively + const renderSubpoints = (subpoints: Subpoint[], level = 0) => { + const markers = [ + ["1", "2", "3"], // Level 0 markers + ["a", "b", "c"], // Level 1 markers + ["i", "ii", "iii"], // Level 2 markers + ]; + + // ensure the level has defined markers, if not, default to numeric + const currentMarkers = markers[level] || markers[0]; + + return subpoints.map((subpoint, index) => ( + + + {`${currentMarkers[index % currentMarkers.length]}. `} + {subpoint.text} + + {subpoint.subpoints && ( + {renderSubpoints(subpoint.subpoints, level + 1)} + )} + + )); + }; + + return ( + + + + {letter} + + {text} + + {initSubpoints && renderSubpoints(initSubpoints)} + + ); +}; + +export default BulletPoint; diff --git a/dfm-sideline-sidekick-app/components/BulletPointStyles.tsx b/dfm-sideline-sidekick-app/components/BulletPointStyles.tsx new file mode 100644 index 0000000..58e6dfb --- /dev/null +++ b/dfm-sideline-sidekick-app/components/BulletPointStyles.tsx @@ -0,0 +1,42 @@ +import { StyleSheet } from "react-native"; + +const styles = StyleSheet.create({ + container: { + flexDirection: "row", + alignItems: "center", + paddingTop: 15, + }, + circle: { + width: 24, // this should be a "props"-value in future + height: 24, // this should be a "props"-value in future + borderRadius: 24 / 2, + backgroundColor: "#00629B", + alignItems: "center", + justifyContent: "center", + }, + + circleCaption: { + fontSize: 14, + color: "white", + fontWeight: "600", + }, + mainText: { + color: "black", + fontSize: 16, + fontFamily: "Roboto-Bold", + fontWeight: "700", + paddingLeft: 5, + }, + subpoints: { + paddingTop: 5, + paddingLeft: 38, + paddingRight: 25, + fontFamily: "Roboto-Regular", + }, + point: { + fontSize: 15, + fontFamily: "Roboto-Regular", + }, +}); + +export default styles; diff --git a/dfm-sideline-sidekick-app/components/StringRenderer.tsx b/dfm-sideline-sidekick-app/components/StringRenderer.tsx new file mode 100644 index 0000000..42859c9 --- /dev/null +++ b/dfm-sideline-sidekick-app/components/StringRenderer.tsx @@ -0,0 +1,43 @@ +import React from "react"; +import { Text, View } from "react-native"; + +import styles from "../ConditionSectionStyles"; + +type StringValue = string | string[] | { [key: string]: StringValue } | undefined; + +type Props = { + data: StringValue; +}; + +const BulletList: React.FC<{ items: string[] }> = ({ items }) => ( + + {items.map((item: string, index: number) => ( + + {"\u2022"} + {item} + + ))} + +); + +const StringRenderer: React.FC = ({ data }) => { + if (typeof data === "string") { + return {data}; + } else if (Array.isArray(data) && data.every((item) => typeof item === "string")) { + return ; + } else if (typeof data === "object") { + return ( + + {Object.keys(data).map((key, index) => ( + + {key} + + + ))} + + ); + } + return null; +}; + +export default StringRenderer; diff --git a/dfm-sideline-sidekick-app/emergencies.ts b/dfm-sideline-sidekick-app/emergencies.ts index 9e8e2b6..39943fd 100644 --- a/dfm-sideline-sidekick-app/emergencies.ts +++ b/dfm-sideline-sidekick-app/emergencies.ts @@ -2,23 +2,31 @@ import { get, handleAPIError, post, put } from "./requests"; import type { APIResult } from "./requests"; +// export type Emergency = { +// _id: string; +// title: string; +// overview?: { +// Importance?: string; +// "Mechanism of Injury"?: string[]; +// Diagnosis?: string[]; +// "Physical Exam"?: string[]; +// }; +// treatment?: { +// "Acute Management"?: string[]; +// Dispo?: string[]; +// Considerations?: { +// Header?: string; +// Content?: string[]; +// }; +// }; +// content?: object; +// }; + export type Emergency = { _id: string; title: string; - overview:{ - Importance: string; - 'Mechanism of Injury': string[]; - Diagnosis: string[]; - 'Physical Exam': string[]; - }; - treatment:{ - 'Acute Management': string[]; - Dispo: string[]; - Considerations:{ - Header: string; - Content: string[]; - }; - }; + overview?: object; + treatment?: object; content?: object; }; diff --git a/dfm-sideline-sidekick-app/package-lock.json b/dfm-sideline-sidekick-app/package-lock.json index 4b3fc59..9d4a3cc 100644 --- a/dfm-sideline-sidekick-app/package-lock.json +++ b/dfm-sideline-sidekick-app/package-lock.json @@ -8,14 +8,20 @@ "name": "dfm-sideline-sidekick-app", "version": "1.0.0", "dependencies": { + "@ant-design/icons": "^5.2.6", + "@expo-google-fonts/roboto": "^0.2.3", "@react-navigation/native": "^6.1.10", "@react-navigation/native-stack": "^6.9.18", "@react-navigation/stack": "^6.3.21", "@types/react": "~18.2.14", "expo": "~49.0.15", + "expo-app-loading": "^2.1.1", + "expo-font": "~11.4.0", "expo-status-bar": "~1.6.0", + "next": "^14.1.0", "react": "18.2.0", "react-native": "0.72.6", + "react-native-vector-icons": "^10.0.3", "react-router-dom": "^6.22.0", "react-router-native": "^6.22.0", "typescript": "^5.1.3" @@ -55,6 +61,38 @@ "node": ">=6.0.0" } }, + "node_modules/@ant-design/colors": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@ant-design/colors/-/colors-7.0.2.tgz", + "integrity": "sha512-7KJkhTiPiLHSu+LmMJnehfJ6242OCxSlR3xHVBecYxnMW8MS/878NXct1GqYARyL59fyeFdKRxXTfvR9SnDgJg==", + "dependencies": { + "@ctrl/tinycolor": "^3.6.1" + } + }, + "node_modules/@ant-design/icons": { + "version": "5.2.6", + "resolved": "https://registry.npmjs.org/@ant-design/icons/-/icons-5.2.6.tgz", + "integrity": "sha512-4wn0WShF43TrggskBJPRqCD0fcHbzTYjnaoskdiJrVHg86yxoZ8ZUqsXvyn4WUqehRiFKnaclOhqk9w4Ui2KVw==", + "dependencies": { + "@ant-design/colors": "^7.0.0", + "@ant-design/icons-svg": "^4.3.0", + "@babel/runtime": "^7.11.2", + "classnames": "^2.2.6", + "rc-util": "^5.31.1" + }, + "engines": { + "node": ">=8" + }, + "peerDependencies": { + "react": ">=16.0.0", + "react-dom": ">=16.0.0" + } + }, + "node_modules/@ant-design/icons-svg": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/@ant-design/icons-svg/-/icons-svg-4.3.1.tgz", + "integrity": "sha512-4QBZg8ccyC6LPIRii7A0bZUk3+lEDCLnhB+FVsflGdcWPPmV+j3fire4AwwoqHV/BibgvBmR9ZIo4s867smv+g==" + }, "node_modules/@babel/code-frame": { "version": "7.23.5", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.23.5.tgz", @@ -2004,6 +2042,14 @@ "node": ">=6.9.0" } }, + "node_modules/@ctrl/tinycolor": { + "version": "3.6.1", + "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-3.6.1.tgz", + "integrity": "sha512-SITSV6aIXsuVNV3f3O0f2n/cgyEDWoSqtZMYiAmcsYHydcKrOz3gUxB/iXd/Qf08+IZX4KpgNbvUdMBmWz+kcA==", + "engines": { + "node": ">=10" + } + }, "node_modules/@egjs/hammerjs": { "version": "2.0.17", "resolved": "https://registry.npmjs.org/@egjs/hammerjs/-/hammerjs-2.0.17.tgz", @@ -2154,6 +2200,11 @@ "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, + "node_modules/@expo-google-fonts/roboto": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@expo-google-fonts/roboto/-/roboto-0.2.3.tgz", + "integrity": "sha512-PF6S//ZYWeXfpYTwvY2oEe0d5RnqwR5KMsGjuTgg6y9p/CPK/IkWL+wsbkzjfd+Jck1Q1pRlWOoe5uz42sQFRg==" + }, "node_modules/@expo/bunyan": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/@expo/bunyan/-/bunyan-4.0.0.tgz", @@ -2529,6 +2580,77 @@ "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" }, + "node_modules/@expo/configure-splash-screen": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@expo/configure-splash-screen/-/configure-splash-screen-0.6.0.tgz", + "integrity": "sha512-4DyPoNXJqx9bN4nEwF3HQreo//ECu7gDe1Xor3dnnzFm9P/VDxAKdbEhA0n+R6fgkNfT2onVHWijqvdpTS3Xew==", + "dependencies": { + "color-string": "^1.5.3", + "commander": "^5.1.0", + "fs-extra": "^9.0.0", + "glob": "^7.1.6", + "lodash": "^4.17.15", + "pngjs": "^5.0.0", + "xcode": "^3.0.0", + "xml-js": "^1.6.11" + }, + "bin": { + "configure-splash-screen": "build/index-cli.js", + "expo-splash-screen": "build/index-cli.js" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@expo/configure-splash-screen/node_modules/commander": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", + "integrity": "sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg==", + "engines": { + "node": ">= 6" + } + }, + "node_modules/@expo/configure-splash-screen/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@expo/configure-splash-screen/node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/@expo/configure-splash-screen/node_modules/pngjs": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/pngjs/-/pngjs-5.0.0.tgz", + "integrity": "sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw==", + "engines": { + "node": ">=10.13.0" + } + }, + "node_modules/@expo/configure-splash-screen/node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "engines": { + "node": ">= 10.0.0" + } + }, "node_modules/@expo/dev-server": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/@expo/dev-server/-/dev-server-0.5.5.tgz", @@ -3978,6 +4100,146 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "node_modules/@next/env": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/env/-/env-14.1.0.tgz", + "integrity": "sha512-Py8zIo+02ht82brwwhTg36iogzFqGLPXlRGKQw5s+qP/kMNc4MAyDeEwBKDijk6zTIbegEgu8Qy7C1LboslQAw==" + }, + "node_modules/@next/swc-darwin-arm64": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.1.0.tgz", + "integrity": "sha512-nUDn7TOGcIeyQni6lZHfzNoo9S0euXnu0jhsbMOmMJUBfgsnESdjN97kM7cBqQxZa8L/bM9om/S5/1dzCrW6wQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-darwin-x64": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.1.0.tgz", + "integrity": "sha512-1jgudN5haWxiAl3O1ljUS2GfupPmcftu2RYJqZiMJmmbBT5M1XDffjUtRUzP4W3cBHsrvkfOFdQ71hAreNQP6g==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-gnu": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.1.0.tgz", + "integrity": "sha512-RHo7Tcj+jllXUbK7xk2NyIDod3YcCPDZxj1WLIYxd709BQ7WuRYl3OWUNG+WUfqeQBds6kvZYlc42NJJTNi4tQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-musl": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.1.0.tgz", + "integrity": "sha512-v6kP8sHYxjO8RwHmWMJSq7VZP2nYCkRVQ0qolh2l6xroe9QjbgV8siTbduED4u0hlk0+tjS6/Tuy4n5XCp+l6g==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-gnu": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.1.0.tgz", + "integrity": "sha512-zJ2pnoFYB1F4vmEVlb/eSe+VH679zT1VdXlZKX+pE66grOgjmKJHKacf82g/sWE4MQ4Rk2FMBCRnX+l6/TVYzQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-musl": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.1.0.tgz", + "integrity": "sha512-rbaIYFt2X9YZBSbH/CwGAjbBG2/MrACCVu2X0+kSykHzHnYH5FjHxwXLkcoJ10cX0aWCEynpu+rP76x0914atg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-arm64-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.1.0.tgz", + "integrity": "sha512-o1N5TsYc8f/HpGt39OUQpQ9AKIGApd3QLueu7hXk//2xq5Z9OxmV6sQfNp8C7qYmiOlHYODOGqNNa0e9jvchGQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-ia32-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.1.0.tgz", + "integrity": "sha512-XXIuB1DBRCFwNO6EEzCTMHT5pauwaSj4SWs7CYnME57eaReAKBXCnkUE80p/pAZcewm7hs+vGvNqDPacEXHVkw==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-x64-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.1.0.tgz", + "integrity": "sha512-9WEbVRRAqJ3YFVqEZIxUqkiO8l1nool1LmNxygr5HWF8AcSYsEpneUDhmjUVJEzO2A04+oPtZdombzzPPkTtgg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -6286,6 +6548,14 @@ "@sinonjs/commons": "^3.0.0" } }, + "node_modules/@swc/helpers": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.2.tgz", + "integrity": "sha512-E4KcWTpoLHqwPHLxidpOqQbcrZVgi0rsmmZXUle1jXmJfuIf/UWpczUJ7MZZ5tlxytgJXyp0w4PGkkeLiuIdZw==", + "dependencies": { + "tslib": "^2.4.0" + } + }, "node_modules/@types/hammerjs": { "version": "2.0.45", "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.45.tgz", @@ -7536,6 +7806,17 @@ "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", "integrity": "sha512-uYBjakWipfaO/bXI7E8rq6kpwHRZK5cNYrUv2OzZSI/FvmdMyXJ2tG9dKcjEC5YHmHpUAwsargWIZNWdxb/bnQ==" }, + "node_modules/busboy": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/busboy/-/busboy-1.6.0.tgz", + "integrity": "sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==", + "dependencies": { + "streamsearch": "^1.1.0" + }, + "engines": { + "node": ">=10.16.0" + } + }, "node_modules/bytes": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", @@ -7668,9 +7949,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001572", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001572.tgz", - "integrity": "sha512-1Pbh5FLmn5y4+QhNyJE9j3/7dK44dGB83/ZMjv/qJk86TvDbjk0LosiZo0i0WB0Vx607qMX9jYrn1VLHCkN4rw==", + "version": "1.0.30001579", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001579.tgz", + "integrity": "sha512-u5AUVkixruKHJjw/pj9wISlcMpgFWzSrczLZbrqBSxukQixmg0SJ5sZTpvaFvxU0HoQKd4yoyAogyrAz9pzJnA==", "funding": [ { "type": "opencollective", @@ -7729,6 +8010,11 @@ "node": ">=8" } }, + "node_modules/classnames": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==" + }, "node_modules/clean-stack": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", @@ -7759,6 +8045,11 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/client-only": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz", + "integrity": "sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==" + }, "node_modules/cliui": { "version": "8.0.1", "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", @@ -9223,6 +9514,14 @@ "expo": "bin/cli" } }, + "node_modules/expo-app-loading": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/expo-app-loading/-/expo-app-loading-2.1.1.tgz", + "integrity": "sha512-b3VNkPuFaI9J847HSpjI4uiuyE4+IWyAIPT9uzbkS7QFknL99DMoihtgzeWzKaJKSAmbYc3ph2Vl9skJAkVYUg==", + "dependencies": { + "expo-splash-screen": "~0.17.0" + } + }, "node_modules/expo-application": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/expo-application/-/expo-application-5.3.1.tgz", @@ -9409,6 +9708,280 @@ "invariant": "^2.2.4" } }, + "node_modules/expo-splash-screen": { + "version": "0.17.5", + "resolved": "https://registry.npmjs.org/expo-splash-screen/-/expo-splash-screen-0.17.5.tgz", + "integrity": "sha512-ejSO78hwHXz8T9u8kh8t4r6CR4h70iBvA65gX8GK+dYxZl6/IANPbIb2VnUpND9vqfW+JnkDw+ZFst+gDnkpcQ==", + "dependencies": { + "@expo/configure-splash-screen": "^0.6.0", + "@expo/prebuild-config": "5.0.7" + }, + "peerDependencies": { + "expo": "*" + } + }, + "node_modules/expo-splash-screen/node_modules/@babel/code-frame": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", + "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", + "dependencies": { + "@babel/highlight": "^7.10.4" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/config": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/@expo/config/-/config-7.0.3.tgz", + "integrity": "sha512-joVtB5o+NF40Tmsdp65UzryRtbnCuMbXkVO4wJnNJO4aaK0EYLdHCYSewORVqNcDfGN0LphQr8VTG2npbd9CJA==", + "dependencies": { + "@babel/code-frame": "~7.10.4", + "@expo/config-plugins": "~5.0.3", + "@expo/config-types": "^47.0.0", + "@expo/json-file": "8.2.36", + "getenv": "^1.0.0", + "glob": "7.1.6", + "require-from-string": "^2.0.2", + "resolve-from": "^5.0.0", + "semver": "7.3.2", + "slugify": "^1.3.4", + "sucrase": "^3.20.0" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/config-plugins": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/@expo/config-plugins/-/config-plugins-5.0.4.tgz", + "integrity": "sha512-vzUcVpqOMs3h+hyRdhGwk+eGIOhXa5xYdd92yO17RMNHav3v/+ekMbs7XA2c3lepMO8Yd4/5hqmRw9ZTL6jGzg==", + "dependencies": { + "@expo/config-types": "^47.0.0", + "@expo/json-file": "8.2.36", + "@expo/plist": "0.0.18", + "@expo/sdk-runtime-versions": "^1.0.0", + "@react-native/normalize-color": "^2.0.0", + "chalk": "^4.1.2", + "debug": "^4.3.1", + "find-up": "~5.0.0", + "getenv": "^1.0.0", + "glob": "7.1.6", + "resolve-from": "^5.0.0", + "semver": "^7.3.5", + "slash": "^3.0.0", + "xcode": "^3.0.1", + "xml2js": "0.4.23" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/config-plugins/node_modules/semver": { + "version": "7.6.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.0.tgz", + "integrity": "sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/config-types": { + "version": "47.0.0", + "resolved": "https://registry.npmjs.org/@expo/config-types/-/config-types-47.0.0.tgz", + "integrity": "sha512-r0pWfuhkv7KIcXMUiNACJmJKKwlTBGMw9VZHNdppS8/0Nve8HZMTkNRFQzTHW1uH3pBj8jEXpyw/2vSWDHex9g==" + }, + "node_modules/expo-splash-screen/node_modules/@expo/json-file": { + "version": "8.2.36", + "resolved": "https://registry.npmjs.org/@expo/json-file/-/json-file-8.2.36.tgz", + "integrity": "sha512-tOZfTiIFA5KmMpdW9KF7bc6CFiGjb0xnbieJhTGlHrLL+ps2G0OkqmuZ3pFEXBOMnJYUVpnSy++52LFxvpa5ZQ==", + "dependencies": { + "@babel/code-frame": "~7.10.4", + "json5": "^1.0.1", + "write-file-atomic": "^2.3.0" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/plist": { + "version": "0.0.18", + "resolved": "https://registry.npmjs.org/@expo/plist/-/plist-0.0.18.tgz", + "integrity": "sha512-+48gRqUiz65R21CZ/IXa7RNBXgAI/uPSdvJqoN9x1hfL44DNbUoWHgHiEXTx7XelcATpDwNTz6sHLfy0iNqf+w==", + "dependencies": { + "@xmldom/xmldom": "~0.7.0", + "base64-js": "^1.2.3", + "xmlbuilder": "^14.0.0" + } + }, + "node_modules/expo-splash-screen/node_modules/@expo/prebuild-config": { + "version": "5.0.7", + "resolved": "https://registry.npmjs.org/@expo/prebuild-config/-/prebuild-config-5.0.7.tgz", + "integrity": "sha512-D+TBpJUHe4+oTGFPb4o0rrw/h1xxc6wF+abJnbDHUkhnaeiHkE2O3ByS7FdiZ2FT36t0OKqeSKG/xFwWT3m1Ew==", + "dependencies": { + "@expo/config": "~7.0.2", + "@expo/config-plugins": "~5.0.3", + "@expo/config-types": "^47.0.0", + "@expo/image-utils": "0.3.22", + "@expo/json-file": "8.2.36", + "debug": "^4.3.1", + "fs-extra": "^9.0.0", + "resolve-from": "^5.0.0", + "semver": "7.3.2", + "xml2js": "0.4.23" + }, + "peerDependencies": { + "expo-modules-autolinking": ">=0.8.1" + } + }, + "node_modules/expo-splash-screen/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/expo-splash-screen/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/expo-splash-screen/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/expo-splash-screen/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "node_modules/expo-splash-screen/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/expo-splash-screen/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "engines": { + "node": ">=8" + } + }, + "node_modules/expo-splash-screen/node_modules/json5": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", + "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", + "dependencies": { + "minimist": "^1.2.0" + }, + "bin": { + "json5": "lib/cli.js" + } + }, + "node_modules/expo-splash-screen/node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/expo-splash-screen/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/expo-splash-screen/node_modules/semver": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", + "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/expo-splash-screen/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/expo-splash-screen/node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/expo-splash-screen/node_modules/xml2js": { + "version": "0.4.23", + "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.4.23.tgz", + "integrity": "sha512-ySPiMjM0+pLDftHgXY4By0uswI3SPKLDw/i3UXbnO8M/p28zqexCUoPmQFrYD+/1BzhGJSs2i1ERWKJAtiLrug==", + "dependencies": { + "sax": ">=0.6.0", + "xmlbuilder": "~11.0.0" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/expo-splash-screen/node_modules/xml2js/node_modules/xmlbuilder": { + "version": "11.0.1", + "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-11.0.1.tgz", + "integrity": "sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/expo-splash-screen/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, "node_modules/expo-status-bar": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/expo-status-bar/-/expo-status-bar-1.6.0.tgz", @@ -13301,6 +13874,78 @@ "resolved": "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.0.1.tgz", "integrity": "sha512-SrQrok4CATudVzBS7coSz26QRSmlK9TzzoFbeKfcPBUFPjcQM9Rqvr/DlJkOrwI/0KcgvMub1n1g5Jt9EgRn4A==" }, + "node_modules/next": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/next/-/next-14.1.0.tgz", + "integrity": "sha512-wlzrsbfeSU48YQBjZhDzOwhWhGsy+uQycR8bHAOt1LY1bn3zZEcDyHQOEoN3aWzQ8LHCAJ1nqrWCc9XF2+O45Q==", + "dependencies": { + "@next/env": "14.1.0", + "@swc/helpers": "0.5.2", + "busboy": "1.6.0", + "caniuse-lite": "^1.0.30001579", + "graceful-fs": "^4.2.11", + "postcss": "8.4.31", + "styled-jsx": "5.1.1" + }, + "bin": { + "next": "dist/bin/next" + }, + "engines": { + "node": ">=18.17.0" + }, + "optionalDependencies": { + "@next/swc-darwin-arm64": "14.1.0", + "@next/swc-darwin-x64": "14.1.0", + "@next/swc-linux-arm64-gnu": "14.1.0", + "@next/swc-linux-arm64-musl": "14.1.0", + "@next/swc-linux-x64-gnu": "14.1.0", + "@next/swc-linux-x64-musl": "14.1.0", + "@next/swc-win32-arm64-msvc": "14.1.0", + "@next/swc-win32-ia32-msvc": "14.1.0", + "@next/swc-win32-x64-msvc": "14.1.0" + }, + "peerDependencies": { + "@opentelemetry/api": "^1.1.0", + "react": "^18.2.0", + "react-dom": "^18.2.0", + "sass": "^1.3.0" + }, + "peerDependenciesMeta": { + "@opentelemetry/api": { + "optional": true + }, + "sass": { + "optional": true + } + } + }, + "node_modules/next/node_modules/postcss": { + "version": "8.4.31", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.31.tgz", + "integrity": "sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.6", + "picocolors": "^1.0.0", + "source-map-js": "^1.0.2" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, "node_modules/nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", @@ -14391,6 +15036,24 @@ "rc": "cli.js" } }, + "node_modules/rc-util": { + "version": "5.38.1", + "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.38.1.tgz", + "integrity": "sha512-e4ZMs7q9XqwTuhIK7zBIVFltUtMSjphuPPQXHoHlzRzNdOwUxDejo0Zls5HYaJfRKNURcsS/ceKVULlhjBrxng==", + "dependencies": { + "@babel/runtime": "^7.18.3", + "react-is": "^18.2.0" + }, + "peerDependencies": { + "react": ">=16.9.0", + "react-dom": ">=16.9.0" + } + }, + "node_modules/rc-util/node_modules/react-is": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", + "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==" + }, "node_modules/react": { "version": "18.2.0", "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", @@ -14563,6 +15226,67 @@ "react-native": "*" } }, + "node_modules/react-native-vector-icons": { + "version": "10.0.3", + "resolved": "https://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-10.0.3.tgz", + "integrity": "sha512-ZgVlV5AdQgnPHHvBEihGf2xwyziT1acpXV1U+WfCgCv3lcEeCRsmwAsBU+kUSNsU+8TcWVsX04kdI6qUaS8D7w==", + "dependencies": { + "prop-types": "^15.7.2", + "yargs": "^16.1.1" + }, + "bin": { + "fa-upgrade.sh": "bin/fa-upgrade.sh", + "fa5-upgrade": "bin/fa5-upgrade.sh", + "fa6-upgrade": "bin/fa6-upgrade.sh", + "generate-icon": "bin/generate-icon.js" + } + }, + "node_modules/react-native-vector-icons/node_modules/cliui": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", + "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^7.0.0" + } + }, + "node_modules/react-native-vector-icons/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/react-native-vector-icons/node_modules/yargs": { + "version": "16.2.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", + "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", + "dependencies": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.0", + "y18n": "^5.0.5", + "yargs-parser": "^20.2.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/react-native-vector-icons/node_modules/yargs-parser": { + "version": "20.2.9", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", + "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", + "engines": { + "node": ">=10" + } + }, "node_modules/react-native/node_modules/promise": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/promise/-/promise-8.3.0.tgz", @@ -15395,6 +16119,14 @@ "node": ">= 0.10.0" } }, + "node_modules/streamsearch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/streamsearch/-/streamsearch-1.1.0.tgz", + "integrity": "sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==", + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/strict-uri-encode": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz", @@ -15615,6 +16347,28 @@ "resolved": "https://registry.npmjs.org/structured-headers/-/structured-headers-0.4.1.tgz", "integrity": "sha512-0MP/Cxx5SzeeZ10p/bZI0S6MpgD+yxAhi1BOQ34jgnMXsCq3j1t6tQnZu+KdlL7dvJTLT3g9xN8tl10TqgFMcg==" }, + "node_modules/styled-jsx": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/styled-jsx/-/styled-jsx-5.1.1.tgz", + "integrity": "sha512-pW7uC1l4mBZ8ugbiZrcIsiIvVx1UmTfw7UkC3Um2tmfUq9Bhk8IiyEIPl6F8agHgjzku6j0xQEZbfA5uSgSaCw==", + "dependencies": { + "client-only": "0.0.1" + }, + "engines": { + "node": ">= 12.0.0" + }, + "peerDependencies": { + "react": ">= 16.8.0 || 17.x.x || ^18.0.0-0" + }, + "peerDependenciesMeta": { + "@babel/core": { + "optional": true + }, + "babel-plugin-macros": { + "optional": true + } + } + }, "node_modules/sucrase": { "version": "3.35.0", "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.0.tgz", @@ -16747,6 +17501,17 @@ "uuid": "dist/bin/uuid" } }, + "node_modules/xml-js": { + "version": "1.6.11", + "resolved": "https://registry.npmjs.org/xml-js/-/xml-js-1.6.11.tgz", + "integrity": "sha512-7rVi2KMfwfWFl+GpPg6m80IVMWXLRjO+PxTq7V2CDhoGak0wzYzFgUY2m4XJ47OGdXd8eLE8EmwfAmdjw7lC1g==", + "dependencies": { + "sax": "^1.2.4" + }, + "bin": { + "xml-js": "bin/cli.js" + } + }, "node_modules/xml2js": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.6.0.tgz", @@ -16857,6 +17622,31 @@ "@jridgewell/trace-mapping": "^0.3.9" } }, + "@ant-design/colors": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@ant-design/colors/-/colors-7.0.2.tgz", + "integrity": "sha512-7KJkhTiPiLHSu+LmMJnehfJ6242OCxSlR3xHVBecYxnMW8MS/878NXct1GqYARyL59fyeFdKRxXTfvR9SnDgJg==", + "requires": { + "@ctrl/tinycolor": "^3.6.1" + } + }, + "@ant-design/icons": { + "version": "5.2.6", + "resolved": "https://registry.npmjs.org/@ant-design/icons/-/icons-5.2.6.tgz", + "integrity": "sha512-4wn0WShF43TrggskBJPRqCD0fcHbzTYjnaoskdiJrVHg86yxoZ8ZUqsXvyn4WUqehRiFKnaclOhqk9w4Ui2KVw==", + "requires": { + "@ant-design/colors": "^7.0.0", + "@ant-design/icons-svg": "^4.3.0", + "@babel/runtime": "^7.11.2", + "classnames": "^2.2.6", + "rc-util": "^5.31.1" + } + }, + "@ant-design/icons-svg": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/@ant-design/icons-svg/-/icons-svg-4.3.1.tgz", + "integrity": "sha512-4QBZg8ccyC6LPIRii7A0bZUk3+lEDCLnhB+FVsflGdcWPPmV+j3fire4AwwoqHV/BibgvBmR9ZIo4s867smv+g==" + }, "@babel/code-frame": { "version": "7.23.5", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.23.5.tgz", @@ -18132,6 +18922,11 @@ "to-fast-properties": "^2.0.0" } }, + "@ctrl/tinycolor": { + "version": "3.6.1", + "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-3.6.1.tgz", + "integrity": "sha512-SITSV6aIXsuVNV3f3O0f2n/cgyEDWoSqtZMYiAmcsYHydcKrOz3gUxB/iXd/Qf08+IZX4KpgNbvUdMBmWz+kcA==" + }, "@egjs/hammerjs": { "version": "2.0.17", "resolved": "https://registry.npmjs.org/@egjs/hammerjs/-/hammerjs-2.0.17.tgz", @@ -18233,6 +19028,11 @@ "integrity": "sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A==", "dev": true }, + "@expo-google-fonts/roboto": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@expo-google-fonts/roboto/-/roboto-0.2.3.tgz", + "integrity": "sha512-PF6S//ZYWeXfpYTwvY2oEe0d5RnqwR5KMsGjuTgg6y9p/CPK/IkWL+wsbkzjfd+Jck1Q1pRlWOoe5uz42sQFRg==" + }, "@expo/bunyan": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/@expo/bunyan/-/bunyan-4.0.0.tgz", @@ -18536,6 +19336,58 @@ "resolved": "https://registry.npmjs.org/@expo/config-types/-/config-types-49.0.0.tgz", "integrity": "sha512-8eyREVi+K2acnMBe/rTIu1dOfyR2+AMnTLHlut+YpMV9OZPdeKV0Bs9BxAewGqBA2slslbQ9N39IS2CuTKpXkA==" }, + "@expo/configure-splash-screen": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@expo/configure-splash-screen/-/configure-splash-screen-0.6.0.tgz", + "integrity": "sha512-4DyPoNXJqx9bN4nEwF3HQreo//ECu7gDe1Xor3dnnzFm9P/VDxAKdbEhA0n+R6fgkNfT2onVHWijqvdpTS3Xew==", + "requires": { + "color-string": "^1.5.3", + "commander": "^5.1.0", + "fs-extra": "^9.0.0", + "glob": "^7.1.6", + "lodash": "^4.17.15", + "pngjs": "^5.0.0", + "xcode": "^3.0.0", + "xml-js": "^1.6.11" + }, + "dependencies": { + "commander": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", + "integrity": "sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg==" + }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, + "jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "requires": { + "graceful-fs": "^4.1.6", + "universalify": "^2.0.0" + } + }, + "pngjs": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/pngjs/-/pngjs-5.0.0.tgz", + "integrity": "sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw==" + }, + "universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==" + } + } + }, "@expo/dev-server": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/@expo/dev-server/-/dev-server-0.5.5.tgz", @@ -19650,6 +20502,65 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "@next/env": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/env/-/env-14.1.0.tgz", + "integrity": "sha512-Py8zIo+02ht82brwwhTg36iogzFqGLPXlRGKQw5s+qP/kMNc4MAyDeEwBKDijk6zTIbegEgu8Qy7C1LboslQAw==" + }, + "@next/swc-darwin-arm64": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.1.0.tgz", + "integrity": "sha512-nUDn7TOGcIeyQni6lZHfzNoo9S0euXnu0jhsbMOmMJUBfgsnESdjN97kM7cBqQxZa8L/bM9om/S5/1dzCrW6wQ==", + "optional": true + }, + "@next/swc-darwin-x64": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.1.0.tgz", + "integrity": "sha512-1jgudN5haWxiAl3O1ljUS2GfupPmcftu2RYJqZiMJmmbBT5M1XDffjUtRUzP4W3cBHsrvkfOFdQ71hAreNQP6g==", + "optional": true + }, + "@next/swc-linux-arm64-gnu": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.1.0.tgz", + "integrity": "sha512-RHo7Tcj+jllXUbK7xk2NyIDod3YcCPDZxj1WLIYxd709BQ7WuRYl3OWUNG+WUfqeQBds6kvZYlc42NJJTNi4tQ==", + "optional": true + }, + "@next/swc-linux-arm64-musl": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.1.0.tgz", + "integrity": "sha512-v6kP8sHYxjO8RwHmWMJSq7VZP2nYCkRVQ0qolh2l6xroe9QjbgV8siTbduED4u0hlk0+tjS6/Tuy4n5XCp+l6g==", + "optional": true + }, + "@next/swc-linux-x64-gnu": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.1.0.tgz", + "integrity": "sha512-zJ2pnoFYB1F4vmEVlb/eSe+VH679zT1VdXlZKX+pE66grOgjmKJHKacf82g/sWE4MQ4Rk2FMBCRnX+l6/TVYzQ==", + "optional": true + }, + "@next/swc-linux-x64-musl": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.1.0.tgz", + "integrity": "sha512-rbaIYFt2X9YZBSbH/CwGAjbBG2/MrACCVu2X0+kSykHzHnYH5FjHxwXLkcoJ10cX0aWCEynpu+rP76x0914atg==", + "optional": true + }, + "@next/swc-win32-arm64-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.1.0.tgz", + "integrity": "sha512-o1N5TsYc8f/HpGt39OUQpQ9AKIGApd3QLueu7hXk//2xq5Z9OxmV6sQfNp8C7qYmiOlHYODOGqNNa0e9jvchGQ==", + "optional": true + }, + "@next/swc-win32-ia32-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.1.0.tgz", + "integrity": "sha512-XXIuB1DBRCFwNO6EEzCTMHT5pauwaSj4SWs7CYnME57eaReAKBXCnkUE80p/pAZcewm7hs+vGvNqDPacEXHVkw==", + "optional": true + }, + "@next/swc-win32-x64-msvc": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.1.0.tgz", + "integrity": "sha512-9WEbVRRAqJ3YFVqEZIxUqkiO8l1nool1LmNxygr5HWF8AcSYsEpneUDhmjUVJEzO2A04+oPtZdombzzPPkTtgg==", + "optional": true + }, "@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -21283,6 +22194,14 @@ "@sinonjs/commons": "^3.0.0" } }, + "@swc/helpers": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.2.tgz", + "integrity": "sha512-E4KcWTpoLHqwPHLxidpOqQbcrZVgi0rsmmZXUle1jXmJfuIf/UWpczUJ7MZZ5tlxytgJXyp0w4PGkkeLiuIdZw==", + "requires": { + "tslib": "^2.4.0" + } + }, "@types/hammerjs": { "version": "2.0.45", "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.45.tgz", @@ -22228,6 +23147,14 @@ "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", "integrity": "sha512-uYBjakWipfaO/bXI7E8rq6kpwHRZK5cNYrUv2OzZSI/FvmdMyXJ2tG9dKcjEC5YHmHpUAwsargWIZNWdxb/bnQ==" }, + "busboy": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/busboy/-/busboy-1.6.0.tgz", + "integrity": "sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==", + "requires": { + "streamsearch": "^1.1.0" + } + }, "bytes": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", @@ -22323,9 +23250,9 @@ "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==" }, "caniuse-lite": { - "version": "1.0.30001572", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001572.tgz", - "integrity": "sha512-1Pbh5FLmn5y4+QhNyJE9j3/7dK44dGB83/ZMjv/qJk86TvDbjk0LosiZo0i0WB0Vx607qMX9jYrn1VLHCkN4rw==" + "version": "1.0.30001579", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001579.tgz", + "integrity": "sha512-u5AUVkixruKHJjw/pj9wISlcMpgFWzSrczLZbrqBSxukQixmg0SJ5sZTpvaFvxU0HoQKd4yoyAogyrAz9pzJnA==" }, "chalk": { "version": "2.4.2", @@ -22352,6 +23279,11 @@ "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==" }, + "classnames": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==" + }, "clean-stack": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", @@ -22370,6 +23302,11 @@ "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==" }, + "client-only": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz", + "integrity": "sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==" + }, "cliui": { "version": "8.0.1", "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", @@ -23507,6 +24444,14 @@ "uuid": "^3.4.0" } }, + "expo-app-loading": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/expo-app-loading/-/expo-app-loading-2.1.1.tgz", + "integrity": "sha512-b3VNkPuFaI9J847HSpjI4uiuyE4+IWyAIPT9uzbkS7QFknL99DMoihtgzeWzKaJKSAmbYc3ph2Vl9skJAkVYUg==", + "requires": { + "expo-splash-screen": "~0.17.0" + } + }, "expo-application": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/expo-application/-/expo-application-5.3.1.tgz", @@ -23650,6 +24595,227 @@ "invariant": "^2.2.4" } }, + "expo-splash-screen": { + "version": "0.17.5", + "resolved": "https://registry.npmjs.org/expo-splash-screen/-/expo-splash-screen-0.17.5.tgz", + "integrity": "sha512-ejSO78hwHXz8T9u8kh8t4r6CR4h70iBvA65gX8GK+dYxZl6/IANPbIb2VnUpND9vqfW+JnkDw+ZFst+gDnkpcQ==", + "requires": { + "@expo/configure-splash-screen": "^0.6.0", + "@expo/prebuild-config": "5.0.7" + }, + "dependencies": { + "@babel/code-frame": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", + "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", + "requires": { + "@babel/highlight": "^7.10.4" + } + }, + "@expo/config": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/@expo/config/-/config-7.0.3.tgz", + "integrity": "sha512-joVtB5o+NF40Tmsdp65UzryRtbnCuMbXkVO4wJnNJO4aaK0EYLdHCYSewORVqNcDfGN0LphQr8VTG2npbd9CJA==", + "requires": { + "@babel/code-frame": "~7.10.4", + "@expo/config-plugins": "~5.0.3", + "@expo/config-types": "^47.0.0", + "@expo/json-file": "8.2.36", + "getenv": "^1.0.0", + "glob": "7.1.6", + "require-from-string": "^2.0.2", + "resolve-from": "^5.0.0", + "semver": "7.3.2", + "slugify": "^1.3.4", + "sucrase": "^3.20.0" + } + }, + "@expo/config-plugins": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/@expo/config-plugins/-/config-plugins-5.0.4.tgz", + "integrity": "sha512-vzUcVpqOMs3h+hyRdhGwk+eGIOhXa5xYdd92yO17RMNHav3v/+ekMbs7XA2c3lepMO8Yd4/5hqmRw9ZTL6jGzg==", + "requires": { + "@expo/config-types": "^47.0.0", + "@expo/json-file": "8.2.36", + "@expo/plist": "0.0.18", + "@expo/sdk-runtime-versions": "^1.0.0", + "@react-native/normalize-color": "^2.0.0", + "chalk": "^4.1.2", + "debug": "^4.3.1", + "find-up": "~5.0.0", + "getenv": "^1.0.0", + "glob": "7.1.6", + "resolve-from": "^5.0.0", + "semver": "^7.3.5", + "slash": "^3.0.0", + "xcode": "^3.0.1", + "xml2js": "0.4.23" + }, + "dependencies": { + "semver": { + "version": "7.6.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.0.tgz", + "integrity": "sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==", + "requires": { + "lru-cache": "^6.0.0" + } + } + } + }, + "@expo/config-types": { + "version": "47.0.0", + "resolved": "https://registry.npmjs.org/@expo/config-types/-/config-types-47.0.0.tgz", + "integrity": "sha512-r0pWfuhkv7KIcXMUiNACJmJKKwlTBGMw9VZHNdppS8/0Nve8HZMTkNRFQzTHW1uH3pBj8jEXpyw/2vSWDHex9g==" + }, + "@expo/json-file": { + "version": "8.2.36", + "resolved": "https://registry.npmjs.org/@expo/json-file/-/json-file-8.2.36.tgz", + "integrity": "sha512-tOZfTiIFA5KmMpdW9KF7bc6CFiGjb0xnbieJhTGlHrLL+ps2G0OkqmuZ3pFEXBOMnJYUVpnSy++52LFxvpa5ZQ==", + "requires": { + "@babel/code-frame": "~7.10.4", + "json5": "^1.0.1", + "write-file-atomic": "^2.3.0" + } + }, + "@expo/plist": { + "version": "0.0.18", + "resolved": "https://registry.npmjs.org/@expo/plist/-/plist-0.0.18.tgz", + "integrity": "sha512-+48gRqUiz65R21CZ/IXa7RNBXgAI/uPSdvJqoN9x1hfL44DNbUoWHgHiEXTx7XelcATpDwNTz6sHLfy0iNqf+w==", + "requires": { + "@xmldom/xmldom": "~0.7.0", + "base64-js": "^1.2.3", + "xmlbuilder": "^14.0.0" + } + }, + "@expo/prebuild-config": { + "version": "5.0.7", + "resolved": "https://registry.npmjs.org/@expo/prebuild-config/-/prebuild-config-5.0.7.tgz", + "integrity": "sha512-D+TBpJUHe4+oTGFPb4o0rrw/h1xxc6wF+abJnbDHUkhnaeiHkE2O3ByS7FdiZ2FT36t0OKqeSKG/xFwWT3m1Ew==", + "requires": { + "@expo/config": "~7.0.2", + "@expo/config-plugins": "~5.0.3", + "@expo/config-types": "^47.0.0", + "@expo/image-utils": "0.3.22", + "@expo/json-file": "8.2.36", + "debug": "^4.3.1", + "fs-extra": "^9.0.0", + "resolve-from": "^5.0.0", + "semver": "7.3.2", + "xml2js": "0.4.23" + } + }, + "ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "requires": { + "color-convert": "^2.0.1" + } + }, + "chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + }, + "json5": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", + "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", + "requires": { + "minimist": "^1.2.0" + } + }, + "jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "requires": { + "graceful-fs": "^4.1.6", + "universalify": "^2.0.0" + } + }, + "lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "requires": { + "yallist": "^4.0.0" + } + }, + "semver": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", + "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==" + }, + "supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "requires": { + "has-flag": "^4.0.0" + } + }, + "universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==" + }, + "xml2js": { + "version": "0.4.23", + "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.4.23.tgz", + "integrity": "sha512-ySPiMjM0+pLDftHgXY4By0uswI3SPKLDw/i3UXbnO8M/p28zqexCUoPmQFrYD+/1BzhGJSs2i1ERWKJAtiLrug==", + "requires": { + "sax": ">=0.6.0", + "xmlbuilder": "~11.0.0" + }, + "dependencies": { + "xmlbuilder": { + "version": "11.0.1", + "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-11.0.1.tgz", + "integrity": "sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==" + } + } + }, + "yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + } + } + }, "expo-status-bar": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/expo-status-bar/-/expo-status-bar-1.6.0.tgz", @@ -26482,6 +27648,41 @@ "resolved": "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.0.1.tgz", "integrity": "sha512-SrQrok4CATudVzBS7coSz26QRSmlK9TzzoFbeKfcPBUFPjcQM9Rqvr/DlJkOrwI/0KcgvMub1n1g5Jt9EgRn4A==" }, + "next": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/next/-/next-14.1.0.tgz", + "integrity": "sha512-wlzrsbfeSU48YQBjZhDzOwhWhGsy+uQycR8bHAOt1LY1bn3zZEcDyHQOEoN3aWzQ8LHCAJ1nqrWCc9XF2+O45Q==", + "requires": { + "@next/env": "14.1.0", + "@next/swc-darwin-arm64": "14.1.0", + "@next/swc-darwin-x64": "14.1.0", + "@next/swc-linux-arm64-gnu": "14.1.0", + "@next/swc-linux-arm64-musl": "14.1.0", + "@next/swc-linux-x64-gnu": "14.1.0", + "@next/swc-linux-x64-musl": "14.1.0", + "@next/swc-win32-arm64-msvc": "14.1.0", + "@next/swc-win32-ia32-msvc": "14.1.0", + "@next/swc-win32-x64-msvc": "14.1.0", + "@swc/helpers": "0.5.2", + "busboy": "1.6.0", + "caniuse-lite": "^1.0.30001579", + "graceful-fs": "^4.2.11", + "postcss": "8.4.31", + "styled-jsx": "5.1.1" + }, + "dependencies": { + "postcss": { + "version": "8.4.31", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.31.tgz", + "integrity": "sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==", + "requires": { + "nanoid": "^3.3.6", + "picocolors": "^1.0.0", + "source-map-js": "^1.0.2" + } + } + } + }, "nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", @@ -27250,6 +28451,22 @@ "strip-json-comments": "~2.0.1" } }, + "rc-util": { + "version": "5.38.1", + "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.38.1.tgz", + "integrity": "sha512-e4ZMs7q9XqwTuhIK7zBIVFltUtMSjphuPPQXHoHlzRzNdOwUxDejo0Zls5HYaJfRKNURcsS/ceKVULlhjBrxng==", + "requires": { + "@babel/runtime": "^7.18.3", + "react-is": "^18.2.0" + }, + "dependencies": { + "react-is": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", + "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==" + } + } + }, "react": { "version": "18.2.0", "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", @@ -27404,6 +28621,54 @@ "warn-once": "^0.1.0" } }, + "react-native-vector-icons": { + "version": "10.0.3", + "resolved": "https://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-10.0.3.tgz", + "integrity": "sha512-ZgVlV5AdQgnPHHvBEihGf2xwyziT1acpXV1U+WfCgCv3lcEeCRsmwAsBU+kUSNsU+8TcWVsX04kdI6qUaS8D7w==", + "requires": { + "prop-types": "^15.7.2", + "yargs": "^16.1.1" + }, + "dependencies": { + "cliui": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", + "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", + "requires": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^7.0.0" + } + }, + "strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "requires": { + "ansi-regex": "^5.0.1" + } + }, + "yargs": { + "version": "16.2.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", + "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", + "requires": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.0", + "y18n": "^5.0.5", + "yargs-parser": "^20.2.2" + } + }, + "yargs-parser": { + "version": "20.2.9", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", + "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==" + } + } + }, "react-refresh": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.4.3.tgz", @@ -28033,6 +29298,11 @@ "resolved": "https://registry.npmjs.org/stream-buffers/-/stream-buffers-2.2.0.tgz", "integrity": "sha512-uyQK/mx5QjHun80FLJTfaWE7JtwfRMKBLkMne6udYOmvH0CawotVa7TfgYHzAnpphn4+TweIx1QKMnRIbipmUg==" }, + "streamsearch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/streamsearch/-/streamsearch-1.1.0.tgz", + "integrity": "sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==" + }, "strict-uri-encode": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz", @@ -28200,6 +29470,14 @@ "resolved": "https://registry.npmjs.org/structured-headers/-/structured-headers-0.4.1.tgz", "integrity": "sha512-0MP/Cxx5SzeeZ10p/bZI0S6MpgD+yxAhi1BOQ34jgnMXsCq3j1t6tQnZu+KdlL7dvJTLT3g9xN8tl10TqgFMcg==" }, + "styled-jsx": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/styled-jsx/-/styled-jsx-5.1.1.tgz", + "integrity": "sha512-pW7uC1l4mBZ8ugbiZrcIsiIvVx1UmTfw7UkC3Um2tmfUq9Bhk8IiyEIPl6F8agHgjzku6j0xQEZbfA5uSgSaCw==", + "requires": { + "client-only": "0.0.1" + } + }, "sucrase": { "version": "3.35.0", "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.0.tgz", @@ -29027,6 +30305,14 @@ } } }, + "xml-js": { + "version": "1.6.11", + "resolved": "https://registry.npmjs.org/xml-js/-/xml-js-1.6.11.tgz", + "integrity": "sha512-7rVi2KMfwfWFl+GpPg6m80IVMWXLRjO+PxTq7V2CDhoGak0wzYzFgUY2m4XJ47OGdXd8eLE8EmwfAmdjw7lC1g==", + "requires": { + "sax": "^1.2.4" + } + }, "xml2js": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.6.0.tgz", diff --git a/dfm-sideline-sidekick-app/package.json b/dfm-sideline-sidekick-app/package.json index ab9b8cf..98c55a7 100644 --- a/dfm-sideline-sidekick-app/package.json +++ b/dfm-sideline-sidekick-app/package.json @@ -15,14 +15,20 @@ "prepare": "cd .. && husky install .husky" }, "dependencies": { + "@ant-design/icons": "^5.2.6", + "@expo-google-fonts/roboto": "^0.2.3", "@react-navigation/native": "^6.1.10", "@react-navigation/native-stack": "^6.9.18", "@react-navigation/stack": "^6.3.21", "@types/react": "~18.2.14", "expo": "~49.0.15", + "expo-app-loading": "^2.1.1", + "expo-font": "~11.4.0", "expo-status-bar": "~1.6.0", + "next": "^14.1.0", "react": "18.2.0", "react-native": "0.72.6", + "react-native-vector-icons": "^10.0.3", "react-router-dom": "^6.22.0", "react-router-native": "^6.22.0", "typescript": "^5.1.3" diff --git a/dfm-sideline-sidekick-app/pages/EmergencyCare.tsx b/dfm-sideline-sidekick-app/pages/EmergencyCare.tsx new file mode 100644 index 0000000..c009f9f --- /dev/null +++ b/dfm-sideline-sidekick-app/pages/EmergencyCare.tsx @@ -0,0 +1,32 @@ +import { Roboto_400Regular, Roboto_700Bold } from "@expo-google-fonts/roboto"; +import { useFonts } from "expo-font"; +import { Text, TouchableOpacity, View } from "react-native"; +import AntIcon from "react-native-vector-icons/AntDesign"; + +import BulletPoint from "../components/BulletPoint"; + +import styles from "./generalPrinciplesStyles"; + +const EmergencyCare = () => { + const [fontsLoaded] = useFonts({ + "Roboto-Regular": Roboto_400Regular, + "Roboto-Bold": Roboto_700Bold, + }); + if (!fontsLoaded) { + return Loading...; + } + return ( + + + + + Emergency Care + Emergency Care + + + + + ); +}; + +export default EmergencyCare; diff --git a/dfm-sideline-sidekick-app/pages/generalPrinciples.tsx b/dfm-sideline-sidekick-app/pages/generalPrinciples.tsx new file mode 100644 index 0000000..d0a4625 --- /dev/null +++ b/dfm-sideline-sidekick-app/pages/generalPrinciples.tsx @@ -0,0 +1,54 @@ +import { Roboto_400Regular, Roboto_700Bold } from "@expo-google-fonts/roboto"; +import { useFonts } from "expo-font"; +import { Text, TouchableOpacity, View } from "react-native"; +import AntIcon from "react-native-vector-icons/AntDesign"; + +import BulletPoint from "../components/BulletPoint"; + +import styles from "./generalPrinciplesStyles"; + +const GeneralPrinciples = () => { + const [fontsLoaded] = useFonts({ + "Roboto-Regular": Roboto_400Regular, + "Roboto-Bold": Roboto_700Bold, + }); + if (!fontsLoaded) { + return Loading...; + } + return ( + + + + + General Principles + General Principles + + + + ); +}; + +export default GeneralPrinciples; diff --git a/dfm-sideline-sidekick-app/pages/generalPrinciplesStyles.tsx b/dfm-sideline-sidekick-app/pages/generalPrinciplesStyles.tsx new file mode 100644 index 0000000..68bb0c8 --- /dev/null +++ b/dfm-sideline-sidekick-app/pages/generalPrinciplesStyles.tsx @@ -0,0 +1,34 @@ +import { StyleSheet } from "react-native"; + +const styles = StyleSheet.create({ + container: { + flex: 1, + backgroundColor: "#fff", + paddingTop: 50, + textAlign: "left", + alignSelf: "stretch", + paddingLeft: 25, + }, + title: { + color: "#182B49", + fontSize: 28, + fontFamily: "Roboto-Bold", + fontWeight: "700", + marginBottom: 20, + textAlign: "left", + paddingTop: 10, + }, + subTitle: { + color: "#182B49", + fontSize: 21, + fontFamily: "Roboto-Bold", + fontWeight: "700", + marginBottom: 5, + textAlign: "left", + }, + button: { + fontSize: 25, + }, +}); + +export default styles; diff --git a/dfm-sideline-sidekick-app/requests.ts b/dfm-sideline-sidekick-app/requests.ts index cf920e2..fb31db8 100644 --- a/dfm-sideline-sidekick-app/requests.ts +++ b/dfm-sideline-sidekick-app/requests.ts @@ -15,9 +15,9 @@ type Method = "GET" | "POST" | "PUT"; * instead of "http://localhost:3001/api/foo". */ //const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || "http://localhost:3001"; -// INSERT IP ADDRESS HERE -const API_BASE_URL = "http://100.83.62.24:3001"; - +// NOTE TO REVIEWERS: INSERT IP ADDRESS HERE +// YOU MUST BE ON THE SAME NETWORK AS TEST DEVICE AND HAVE BACKEND RUNNING (WITH .env SETUP and "Database Connected" message) +const API_BASE_URL = "http://100.112.104.53:3001"; /** * A wrapper around the built-in `fetch()` function that abstracts away some of From f9d24a21c939a0097ba708c87daf46f8606b0755 Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Fri, 16 Feb 2024 19:55:19 -0800 Subject: [PATCH 4/8] Fixed frontend linter issues --- dfm-sideline-sidekick-app/ConditionsSection.tsx | 1 - dfm-sideline-sidekick-app/HomeScreen.tsx | 1 - 2 files changed, 2 deletions(-) diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index 0bcf2ef..efacdcf 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -3,7 +3,6 @@ import { ParamListBase, RouteProp } from "@react-navigation/native"; import { StackNavigationProp } from "@react-navigation/stack"; import * as Font from "expo-font"; import { useEffect, useState } from "react"; -// eslint-disable-next-line import/namespace import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; import styles from "./ConditionSectionStyles"; diff --git a/dfm-sideline-sidekick-app/HomeScreen.tsx b/dfm-sideline-sidekick-app/HomeScreen.tsx index b194a8d..3ab48be 100644 --- a/dfm-sideline-sidekick-app/HomeScreen.tsx +++ b/dfm-sideline-sidekick-app/HomeScreen.tsx @@ -3,7 +3,6 @@ import { useNavigation } from "@react-navigation/native"; // import * as Font from "expo-font"; // import { useEffect, useState } from "react"; // import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; -// eslint-disable-next-line import/namespace import { Pressable, Text } from "react-native"; // import styles from "./ConditionSectionStyles"; // import { getEmergency } from "./emergencies"; From 31ae9eb5797a82f3dbcb0c11dc85c7c4306700cb Mon Sep 17 00:00:00 2001 From: Eshaan Sharma Date: Tue, 20 Feb 2024 21:12:24 -0800 Subject: [PATCH 5/8] Removed extra file and comments --- .../ConditionsSection.tsx | 96 ------------------- .../generalPrinciples.ts | 0 2 files changed, 96 deletions(-) delete mode 100644 dfm-sideline-sidekick-app/generalPrinciples.ts diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index efacdcf..8569ea4 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -41,30 +41,9 @@ export default function ConditionsSection({ route, navigation }: Props) { const [contentHeaders, setContentHeaders] = useState([]); const [contentValues, setContentValues] = useState([]); - // const route = useRoute(); const { params } = route; // Destructure params from the route object - //const { emergencyObjectId } = route.params(); const [emergency, setEmergency] = useState(); - // Assuming emergency is of type Emergency - // if (emergency?.overview && typeof emergency.overview === "object") { - // setOverviewHeaders(Object.keys(emergency.overview)); - // setOverviewValues(Object.values(emergency.overview)); - // } - - // if (emergency?.overview && typeof emergency.overview === "string") { - // //const overviewHeaders = Object.keys(emergency.overview); - // console.log(emergency.overview); - // } - - // const mechanismArray: string[] = emergency?.overview?.["Mechanism of Injury"] ?? []; - // const diagnosisArray: string[] = emergency?.overview?.Diagnosis ?? []; - // const physicalArray: string[] = emergency?.overview?.["Physical Exam"] ?? []; - - // const accuteArray: string[] = emergency?.treatment?.["Acute Management"] ?? []; - // const dispoArray: string[] = emergency?.treatment?.Dispo ?? []; - // const contentArray: string[] = emergency?.treatment?.Considerations?.Content ?? []; - useEffect(() => { async function loadFont() { try { @@ -114,21 +93,6 @@ export default function ConditionsSection({ route, navigation }: Props) { } }, [emergency]); - // type BulletListProps = { - // items: string[]; - // }; - - // const BulletList = ({ items }: BulletListProps) => ( - // - // {items.map((item: string, index: number) => ( - // - // {"\u2022"} - // {item} - // - // ))} - // - // ); - function onOverviewPress() { if (!isOverviewPressed) { setIsOverviewPressed(!isOverviewPressed); @@ -154,7 +118,6 @@ export default function ConditionsSection({ route, navigation }: Props) { Medical Emergency - {/* Cervical Spine Injury */} {emergency && {emergency.title}} @@ -196,40 +159,6 @@ export default function ConditionsSection({ route, navigation }: Props) { )} - {/* {emergency?.overview && ( - - Importance - {emergency?.overview.} - - )} - {emergency?.overview?.Importance && ( - - Importance - {emergency?.overview?.Importance} - - )} - - {mechanismArray.length !== 0 && ( - - Mechanism of Injury - - - )} - - {diagnosisArray.length !== 0 && ( - - Diagnosis - - - )} - - {physicalArray.length !== 0 && ( - - Physical Exam - - - - )} */} @@ -267,31 +196,6 @@ export default function ConditionsSection({ route, navigation }: Props) { )} - {/* {accuteArray.length !== 0 && ( - - Acute Management - - - )} - - {dispoArray.length !== 0 && ( - - Dispo - - - )} - - {contentArray.length !== 0 && ( - - Considerations - {emergency?.treatment?.Considerations?.Header && ( - - {emergency?.treatment?.Considerations?.Header} - - )} - - - )} */} diff --git a/dfm-sideline-sidekick-app/generalPrinciples.ts b/dfm-sideline-sidekick-app/generalPrinciples.ts deleted file mode 100644 index e69de29..0000000 From 72d7bc79ad9e8ffdc71fd95f8f005fb1077a33d2 Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Wed, 21 Feb 2024 14:35:56 -0800 Subject: [PATCH 6/8] Changed from passing in emergency id to passing in emergency directly. Fixed test cases in dummy HomeScreen.tsx to reflect this. Removed awkward vertical spacings in ConditionsSection styling. --- .../ConditionSectionStyles.tsx | 4 +- .../ConditionsSection.tsx | 27 +++++----- dfm-sideline-sidekick-app/HomeScreen.tsx | 52 ++++++++++++------- 3 files changed, 48 insertions(+), 35 deletions(-) diff --git a/dfm-sideline-sidekick-app/ConditionSectionStyles.tsx b/dfm-sideline-sidekick-app/ConditionSectionStyles.tsx index 0b67ad4..e0af253 100644 --- a/dfm-sideline-sidekick-app/ConditionSectionStyles.tsx +++ b/dfm-sideline-sidekick-app/ConditionSectionStyles.tsx @@ -27,7 +27,7 @@ export default StyleSheet.create({ alignItems: "flex-start", justifyContent: "space-evenly", width: "100%", - marginTop: 45, + marginTop: 16, }, menuText: { fontFamily: "Roboto-Regular", @@ -73,7 +73,7 @@ export default StyleSheet.create({ }, information: { marginLeft: 16, - marginTop: 20, + marginTop: 0, marginRight: 16, }, overview: {}, diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index 8569ea4..fed150b 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -13,7 +13,7 @@ import type { Emergency } from "./emergencies"; export type RootStackParamList = { // Define the parameters for your screens here - Conditions: { emergencyObjectId: string }; // Example parameter + Conditions: { emergency: Emergency }; // Example parameter } & ParamListBase; // Define the type for the route parameters @@ -63,17 +63,18 @@ export default function ConditionsSection({ route, navigation }: Props) { }, []); useEffect(() => { - if (params?.emergencyObjectId) { - // Check if params and emergencyObjectId exist - // eslint-disable-next-line @typescript-eslint/no-floating-promises - getEmergency(params.emergencyObjectId).then((result) => { - if (result.success) { - setEmergency(result.data); - } else { - console.error("Error fetching emergency data:", result.error); - } - }); - } + // if (params?.emergencyObjectId) { + // // Check if params and emergencyObjectId exist + // // eslint-disable-next-line @typescript-eslint/no-floating-promises + // getEmergency(params.emergencyObjectId).then((result) => { + // if (result.success) { + // setEmergency(result.data); + // } else { + // console.error("Error fetching emergency data:", result.error); + // } + // }); + // } + setEmergency(params.emergency); }, [params]); // Include params in the dependency array useEffect(() => { @@ -158,7 +159,6 @@ export default function ConditionsSection({ route, navigation }: Props) { ))} )} - @@ -195,7 +195,6 @@ export default function ConditionsSection({ route, navigation }: Props) { ))} )} - diff --git a/dfm-sideline-sidekick-app/HomeScreen.tsx b/dfm-sideline-sidekick-app/HomeScreen.tsx index 3ab48be..7c7534c 100644 --- a/dfm-sideline-sidekick-app/HomeScreen.tsx +++ b/dfm-sideline-sidekick-app/HomeScreen.tsx @@ -1,33 +1,47 @@ import { useNavigation } from "@react-navigation/native"; -// import { useRoute } from "@react-navigation/native"; -// import * as Font from "expo-font"; -// import { useEffect, useState } from "react"; -// import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-native"; +import React, { useEffect, useState } from "react"; import { Pressable, Text } from "react-native"; -// import styles from "./ConditionSectionStyles"; -// import { getEmergency } from "./emergencies"; -// import type { Emergency } from "./emergencies"; +import { getEmergency } from "./emergencies"; export default function HomeScreen() { const navigation = useNavigation(); + const [emergency, setEmergency] = useState(null); + + useEffect(() => { + async function fetchEmergency() { + try { + //It seems to work on Android and iPad + //Test Case: Cervical Spine Injury - demonstrate recursive rendering + const emergencyObjectId = "65b36d110c9c60394b37f7a1"; + //Separate Test Case here: To Be Deleted Emergency - demonstrates textual rendering + //const emergencyObjectId = "65b369a8e8fe96a404d4fd6b"; + //Test Case: New Emergency Placeholder Four - demonstrates blank rendering (only title in db) + //const emergencyObjectId = "65c2ef26b87b638ac61beb09"; + //Test Case: Cervical Strain - demonstrates simple placeholder headers + //const emergencyObjectId = "65b36f12640d62464e0dd129"; + const result = await getEmergency(emergencyObjectId); + if (result.success) { + setEmergency(result.data); + } else { + console.error("Error fetching emergency data:", result.error); + } + } catch (error) { + console.error("Error fetching emergency data:", error); + } + } + + fetchEmergency(); + }, []); const handlePress = () => { - //NOTE TO REVIEWERS: Try the test cases below with different document ids and see if they work on your devices and emulators - //It seems to work on Android and iPad - //Test Case: Cervical Spine Injury - demonstrate recursive rendering - const emergencyObjectId = "65b36d110c9c60394b37f7a1"; - //Separate Test Case here: To Be Deleted Emergency - demonstrates textual rendering - //const emergencyObjectId = "65b369a8e8fe96a404d4fd6b"; - //Test Case: New Emergency Placeholder Four - demonstrates blank rendering (only title in db) - //const emergencyObjectId = "65c2ef26b87b638ac61beb09"; - //Test Case: Cervical Strain - demonstrates simple placeholder headers - //const emergencyObjectId = "65b36f12640d62464e0dd129"; - navigation.navigate("Conditions", { emergencyObjectId }); + if (emergency !== null) { + navigation.navigate("Conditions", { emergency }); + } }; return ( - + Navigate to ConditionsSection ); From 95f995c15034e0900fa3434dfa29babfc8c500d5 Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Wed, 21 Feb 2024 14:59:25 -0800 Subject: [PATCH 7/8] Fixed frontend linter issues --- dfm-sideline-sidekick-app/ConditionsSection.tsx | 2 +- dfm-sideline-sidekick-app/HomeScreen.tsx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dfm-sideline-sidekick-app/ConditionsSection.tsx b/dfm-sideline-sidekick-app/ConditionsSection.tsx index fed150b..b534460 100644 --- a/dfm-sideline-sidekick-app/ConditionsSection.tsx +++ b/dfm-sideline-sidekick-app/ConditionsSection.tsx @@ -7,7 +7,7 @@ import { Image, Pressable, SafeAreaView, ScrollView, Text, View } from "react-na import styles from "./ConditionSectionStyles"; import StringRenderer from "./components/StringRenderer"; -import { getEmergency } from "./emergencies"; +// import { getEmergency } from "./emergencies"; import type { Emergency } from "./emergencies"; diff --git a/dfm-sideline-sidekick-app/HomeScreen.tsx b/dfm-sideline-sidekick-app/HomeScreen.tsx index 7c7534c..a2dc2c6 100644 --- a/dfm-sideline-sidekick-app/HomeScreen.tsx +++ b/dfm-sideline-sidekick-app/HomeScreen.tsx @@ -1,5 +1,5 @@ import { useNavigation } from "@react-navigation/native"; -import React, { useEffect, useState } from "react"; +import { useEffect, useState } from "react"; import { Pressable, Text } from "react-native"; import { getEmergency } from "./emergencies"; @@ -31,7 +31,7 @@ export default function HomeScreen() { } } - fetchEmergency(); + void fetchEmergency(); }, []); const handlePress = () => { @@ -41,7 +41,7 @@ export default function HomeScreen() { }; return ( - + Navigate to ConditionsSection ); From 7eedb71257cf3d853d8567ba486ab18626041bb6 Mon Sep 17 00:00:00 2001 From: Rohan Sachdeva Date: Mon, 26 Feb 2024 10:38:16 -0800 Subject: [PATCH 8/8] Replace App.tsx with main branch copy --- dfm-sideline-sidekick-app/App.tsx | 102 ++++++++++++++++++------------ 1 file changed, 63 insertions(+), 39 deletions(-) diff --git a/dfm-sideline-sidekick-app/App.tsx b/dfm-sideline-sidekick-app/App.tsx index 3646f76..3d6f0d0 100644 --- a/dfm-sideline-sidekick-app/App.tsx +++ b/dfm-sideline-sidekick-app/App.tsx @@ -1,51 +1,75 @@ -import { NavigationContainer } from "@react-navigation/native"; +import { NavigationContainer, useNavigation } from "@react-navigation/native"; import { createNativeStackNavigator } from "@react-navigation/native-stack"; -// import { StatusBar } from "expo-status-bar"; -// import { StyleSheet, Text, View } from "react-native"; -// import { StyleSheet } from "react-native"; -// import { NativeRouter, Routes, Route } from "react-router-native"; +import { StackNavigationProp } from "@react-navigation/stack"; +import { StatusBar } from "expo-status-bar"; +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import React from "react"; +import { StyleSheet } from "react-native"; -import ConditionsSection from "./ConditionsSection"; -import HomeScreen from "./HomeScreen"; +import { BottomNavBar, NavItem } from "./components/bar"; +import BookmarkPage from "./pages/BookmarkPage"; +import SearchPage from "./pages/SearchPage"; +import TabPage from "./pages/TabPage"; -// In your App.tsx or where your navigation setup resides +type RootStackParamList = { + Bookmark: undefined; + Search: undefined; + Tab: undefined; +}; -const Stack = createNativeStackNavigator(); +type StackNavigation = StackNavigationProp; +const Stack = createNativeStackNavigator(); -function App() { +const BottomNavBarComponent = () => { + const navigation = useNavigation(); + + const navigationItems: NavItem[] = [ + { + id: 1, + icon: "bookmark", + onClick: () => { + navigation.navigate("Bookmark"); + }, + }, + { + id: 2, + icon: "search", + onClick: () => { + navigation.navigate("Search"); + }, + }, + { + id: 3, + icon: "principles", + onClick: () => { + navigation.navigate("Tab"); + }, + }, + ]; + + return ; +}; + +export default function App() { return ( - - - + + + + + + ); } -export default App; - -// export default function App() { -// return ( -// // eslint-disable-next-line @typescript-eslint/no-use-before-define -// -// {/* Open up App.js to start working on your app! */} -// {/* */} -// -// -// } /> -// } /> -// -// -// -// -// ); -// } -// const styles = StyleSheet.create({ -// container: { -// flex: 1, -// backgroundColor: "#fff", -// alignItems: "center", -// justifyContent: "center", -// }, -// }); +// eslint-disable-next-line @typescript-eslint/no-unused-vars +const styles = StyleSheet.create({ + container: { + flex: 1, + backgroundColor: "#fff", + alignItems: "center", + justifyContent: "center", + }, +});