diff --git a/.cz.toml b/.cz.toml index 4b4c90d..973c69f 100644 --- a/.cz.toml +++ b/.cz.toml @@ -2,6 +2,6 @@ name = "cz_conventional_commits" tag_format = "$version" version_scheme = "semver" -version = "0.1.1" +version = "0.2.0" update_changelog_on_bump = true major_version_zero = true diff --git a/CHANGELOG.md b/CHANGELOG.md index 71592e7..78effae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,27 @@ +## 0.2.0 (2023-10-19) + +### BREAKING CHANGE + +- Completely redos frontend + +### Feat + +- **migrations**: added insert, drop, and reset +- **db.go**: function to add data to the db +- **Onboarding-Flow**: Added boiler plate for Onboarding Context +- redo how the frontend is set up + +### Fix + +- **taskfile.yaml**: added task kill function +- **Yarn-lock**: Fix node package issues that causes build to fail + +## 0.1.1 (2023-10-07) + +### Fix + +- **db.go**: added error checking for migration + ## 0.1.0 (2023-10-07) ### Feat diff --git a/client-new/App.tsx b/client-new/App.tsx index d57564d..a662925 100644 --- a/client-new/App.tsx +++ b/client-new/App.tsx @@ -3,6 +3,8 @@ import { StyleSheet, Text, View } from "react-native"; import Router from "./src/navigation/Router"; import { NativeBaseProvider, extendTheme } from "native-base"; import { SafeAreaProvider } from "react-native-safe-area-context"; +import { Auth0Provider } from "react-native-auth0"; +import { AuthProvider } from "./src/contexts/AuthContext"; export default function App() { const theme = extendTheme({ @@ -10,11 +12,13 @@ export default function App() { colors: {}, }); return ( - - - - - + + + + + + + ); } diff --git a/client-new/app.json b/client-new/app.json index 06acf38..84bfc6c 100644 --- a/client-new/app.json +++ b/client-new/app.json @@ -16,13 +16,14 @@ ], "ios": { "supportsTablet": true, - "bundleIdentifier": "com.dupuguntla.a.legacy" + "bundleIdentifier": "com.legacy" }, "android": { "adaptiveIcon": { "foregroundImage": "./assets/adaptive-icon.png", "backgroundColor": "#ffffff" - } + }, + "package": "com.legacy" }, "web": { "favicon": "./assets/favicon.png" diff --git a/client-new/firebase.ts b/client-new/firebase.ts new file mode 100644 index 0000000..c6a9f9b --- /dev/null +++ b/client-new/firebase.ts @@ -0,0 +1,17 @@ +import * as firebase from "firebase/app"; +import * as firebaseAuth from "firebase/auth"; + +const firebaseConfig = { + apiKey: "AIzaSyDjdkEvyE9m0URAbvyFSIpJVNI-xEATs84", + authDomain: "legacy-4ba7f.firebaseapp.com", + projectId: "legacy-4ba7f", + storageBucket: "legacy-4ba7f.appspot.com", + messagingSenderId: "403289696368", + appId: "1:403289696368:web:eae1fe6606facbbfdf6cb5", + measurementId: "G-ES6PJGKJTJ" + }; + +// Initialize Firebase +const app = firebase.initializeApp(firebaseConfig); + +export const auth = firebaseAuth.getAuth(app);; diff --git a/client-new/package.json b/client-new/package.json index 05abe49..eecee96 100644 --- a/client-new/package.json +++ b/client-new/package.json @@ -10,6 +10,7 @@ "ts:check": "tsc" }, "dependencies": { + "@react-native-community/slider": "^4.4.3", "@react-navigation/native": "^6.1.8", "@react-navigation/native-stack": "^6.9.14", "@types/react": "^18.2.28", @@ -17,15 +18,19 @@ "@types/react-native": "^0.72.3", "expo": "~49.0.13", "expo-dev-client": "^2.4.11", + "expo-secure-store": "^12.5.0", "expo-status-bar": "~1.6.0", + "firebase": "^10.5.0", "native-base": "^3.4.28", "react": "18.2.0", "react-dom": "^18.2.0", "react-native": "0.72.5", + "react-native-auth0": "^3.0.2", "react-native-responsive-screen": "^1.4.2", "react-native-safe-area-context": "^4.7.2", "react-native-screens": "^3.25.0", - "react-native-svg": "^13.14.0" + "react-native-svg": "^13.14.0", + "react-native-vector-icons": "^10.0.0" }, "devDependencies": { "@babel/core": "^7.20.0", diff --git a/client-new/src/components/reusable/Circle.tsx b/client-new/src/components/reusable/Circle.tsx new file mode 100644 index 0000000..92c5764 --- /dev/null +++ b/client-new/src/components/reusable/Circle.tsx @@ -0,0 +1,29 @@ +import { View, Text } from "native-base"; +import { border } from "native-base/lib/typescript/theme/styled-system"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +type CircleProps = { + color: string; + border?: boolean +}; + +export default function Circle(props: CircleProps) { + + const borderWidth = props.border ? 1 : 0 + + return ( + <> + + + ); +} diff --git a/client-new/src/components/reusable/CircleProgressBar.tsx b/client-new/src/components/reusable/CircleProgressBar.tsx new file mode 100644 index 0000000..c453e73 --- /dev/null +++ b/client-new/src/components/reusable/CircleProgressBar.tsx @@ -0,0 +1,38 @@ +import { View } from "native-base"; +import Circle from "./Circle"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +type CircleProgressBarProps = { + totalCircles: number; + completedCircles: number; +}; + +export default function CircleProgressBar(props: CircleProgressBarProps) { + const circles = []; + + for (let i = 0; i < props.totalCircles; i++) { + if (i === 0 && props.completedCircles === 0) { + circles.push(); + } else if (i < props.completedCircles) { + circles.push(); + } else if (i === props.completedCircles) { + circles.push(); + } else { + circles.push(); + } + } + + return ( + + {circles} + + ); +} diff --git a/client-new/src/components/reusable/CompaniesFooter.tsx b/client-new/src/components/reusable/CompaniesFooter.tsx new file mode 100644 index 0000000..613a984 --- /dev/null +++ b/client-new/src/components/reusable/CompaniesFooter.tsx @@ -0,0 +1,28 @@ +import { Text, View } from "native-base"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +export default function CompaniesFooter() { + return ( + <> + + Company 1 + Company 2 + Company 3 + + + + See why these companies are partnered with Legacy + + + + ); +} diff --git a/client-new/src/components/reusable/HalfScreenWideButton.tsx b/client-new/src/components/reusable/HalfScreenWideButton.tsx new file mode 100644 index 0000000..9f905dc --- /dev/null +++ b/client-new/src/components/reusable/HalfScreenWideButton.tsx @@ -0,0 +1,32 @@ +import { Text, Button } from "native-base"; +import React from "react"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +type ScreenWideButtonProps = { + text: string; + textColor: string; + backgroundColor: string; + borderColor: string; + onClick?: (input) => any; +}; + +export default function HalfScreenWideButton(props: ScreenWideButtonProps) { + return ( + <> + + + ); +} diff --git a/client-new/src/components/reusable/LegacyWordmark.tsx b/client-new/src/components/reusable/LegacyWordmark.tsx new file mode 100644 index 0000000..9d2fa58 --- /dev/null +++ b/client-new/src/components/reusable/LegacyWordmark.tsx @@ -0,0 +1,10 @@ +import { Text, View } from "native-base"; +export default function LegacyWordmark() { + return ( + + + Legacy Wordmark + + + ); +} diff --git a/client-new/src/components/reusable/LetsGo.tsx b/client-new/src/components/reusable/LetsGo.tsx new file mode 100644 index 0000000..028839d --- /dev/null +++ b/client-new/src/components/reusable/LetsGo.tsx @@ -0,0 +1,10 @@ +import { Text, View } from "native-base"; +export default function LetsGo() { + return ( + <> + + Let's go! + + + ); +} diff --git a/client-new/src/components/reusable/QuestionaireBox.tsx b/client-new/src/components/reusable/QuestionaireBox.tsx new file mode 100644 index 0000000..710a862 --- /dev/null +++ b/client-new/src/components/reusable/QuestionaireBox.tsx @@ -0,0 +1,77 @@ +import React from "react"; +import { View, Text, Slider } from "native-base"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import ResponseSlider from "./ResponseSlider"; + +type QuestionaireBoxProps = { + text1: string; + text2: string; + initialSliderValue: number; + field: string; + handleChange: (name, value) => void +}; + +export default function QuestionaireBox(props: QuestionaireBoxProps) { + return ( + + + + {props.text1} + + + {props.text2} + + + + + + + 1 + 5 + + + props.handleChange(props.field, value)} + > + + + + + + {/* */} + + ); +} diff --git a/client-new/src/components/reusable/ResponseSlider.tsx b/client-new/src/components/reusable/ResponseSlider.tsx new file mode 100644 index 0000000..8be22cc --- /dev/null +++ b/client-new/src/components/reusable/ResponseSlider.tsx @@ -0,0 +1,62 @@ +import { Divider, View, Text, Button } from "native-base"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +export default function ResponseSlider() { + const bigCircle = ( + + ); + const smallCircle = ( + + ); + + const divider = ; + + return ( + <> + + 1 + 5 + + + + {bigCircle} + {divider} + {smallCircle} + {divider} + {smallCircle} + {divider} + {smallCircle} + {divider} + {bigCircle} + + + ); +} diff --git a/client-new/src/components/reusable/ScreenWideButton.tsx b/client-new/src/components/reusable/ScreenWideButton.tsx new file mode 100644 index 0000000..65aef93 --- /dev/null +++ b/client-new/src/components/reusable/ScreenWideButton.tsx @@ -0,0 +1,32 @@ +import { Text, Button } from "native-base"; +import React from "react"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +type ScreenWideButtonProps = { + text: string; + textColor: string; + backgroundColor: string; + borderColor: string; + onClick?: (input) => any; +}; + +export default function ScreenWideButton(props: ScreenWideButtonProps) { + return ( + <> + + + ); +} diff --git a/client-new/src/components/reusable/ScreenWideInput.tsx b/client-new/src/components/reusable/ScreenWideInput.tsx new file mode 100644 index 0000000..9b34f15 --- /dev/null +++ b/client-new/src/components/reusable/ScreenWideInput.tsx @@ -0,0 +1,65 @@ +import React, { useState } from "react"; +import { Input, FormControl, Button, Text, View } from "native-base"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import Icon from "react-native-vector-icons/FontAwesome"; + +type ScreenWideInputProps = { + title?: string; + password?: boolean; + placeholderText?: string; + onChangeText: (value) => void; + iconName?: string; + value: string; +}; + +export default function ScreenWideInput(props: ScreenWideInputProps) { + const [showPassword, setShowPassword] = useState(false); + + const toggleShowPassword = () => setShowPassword(!showPassword); + + const inputLeftIcon = props.iconName ? ( + + + + ) : null; + + const inputRightElement = props.password ? ( + + ) : undefined; + + return ( + <> + + {props.title} + props.onChangeText(value)} + placeholder={props.placeholderText} + InputLeftElement={inputLeftIcon} + InputRightElement={inputRightElement} + rounded="full" + /> + + + ); +} diff --git a/client-new/src/components/reusable/SquareButton.tsx b/client-new/src/components/reusable/SquareButton.tsx new file mode 100644 index 0000000..2aaabf1 --- /dev/null +++ b/client-new/src/components/reusable/SquareButton.tsx @@ -0,0 +1,22 @@ +import { Button, Text } from "native-base"; + +type SquareButtonProps = { + title: string; + onClick?: (input) => any; +}; + +export default function SquareButton(props: SquareButtonProps) { + return ( + + ); +} diff --git a/client-new/src/contexts/AuthContext.tsx b/client-new/src/contexts/AuthContext.tsx new file mode 100644 index 0000000..81e6516 --- /dev/null +++ b/client-new/src/contexts/AuthContext.tsx @@ -0,0 +1,136 @@ +import React, { useContext, useEffect, useState } from "react"; +import { + User as FirebaseUser, + UserCredential, + createUserWithEmailAndPassword, + signInWithEmailAndPassword, + signOut, +} from "firebase/auth"; +import { auth } from "../../firebase"; +import { getItemAsync, setItemAsync, deleteItemAsync } from "expo-secure-store"; + +type AuthContextData = { + user: FirebaseUser | null; + createAccount: (email: string, password: string) => Promise; + login: (email: string, password: string) => Promise; + logout: () => Promise; +}; + +type AuthProviderProps = { + children?: React.ReactNode; +}; +const AuthContext = React.createContext({} as AuthContextData); + +export const AuthProvider: React.FC = ({ children }) => { + const [user, setUser] = useState(null); + + useEffect(() => { + const unsubscribe = auth.onAuthStateChanged((firebaseUser) => { + setUser(firebaseUser); + setItemAsync("User", JSON.stringify(firebaseUser)) + console.log(firebaseUser) + }); + loadStorageData(); + + return unsubscribe; + }, []); + + async function loadStorageData(): Promise { + try { + const authDataSerialized = await getItemAsync("User"); + if (authDataSerialized) { + const user: FirebaseUser = JSON.parse(authDataSerialized); + setUser(user); + } + } catch (error) { + } finally { + } + } + + const createAccount = async (username: string, password: string) => { + try { + const user = await createUserWithEmailAndPassword(auth, username, password); + + console.log(user); + + // very ugly code + const response = await fetch("http://localhost:8080/api/users", { + method: "POST", + headers: { + "Content-Type": "application/json", + }, + body: JSON.stringify({ + username: username, + password: 'password', + email: user.user.email, + persona_id: 1, + firebase_id: user.user.uid, + }), + }); + + if (!response.ok) { + throw new Error('Network response was not ok'); + } + + const data = await response.json(); + console.log('test', data); + + // this should probably be in the login function + const profileResponse = await fetch(`http://localhost:8080/api/profiles/${data.id}`, { + method: "POST", + headers: { + "Content-Type": "application/json", + }, + body: JSON.stringify({ + name: user.user.email.split('@')[0] + }), + }); + + const profileData = await profileResponse.json(); + console.log('test', profileData); + } catch (error) { + console.log('Error:', error.message); + } + }; + + + const login = async (username: string, password: string) => { + try { + const user = await signInWithEmailAndPassword(auth, username, password); + + const response = await fetch(`http://localhost:8080/api/users/firebase/${user.user.uid}`); + + response.json().then((data) => { + console.log(data); + }); + + const data = await response.json(); + console.log('test', data); + + } catch (error) { + console.log(error.message); + } + }; + + const logout = async () => { + setUser(undefined); + await signOut(auth); + await deleteItemAsync("User"); + }; + + return ( + + {children} + + ); +}; + +export const useAuth = (): AuthContextData => { + const context = useContext(AuthContext); + + if (!context) { + throw new Error("useAuth must be used within an AuthProvider"); + } + + return context; +}; diff --git a/client-new/src/contexts/OnboardingContext.tsx b/client-new/src/contexts/OnboardingContext.tsx new file mode 100644 index 0000000..b98d9b8 --- /dev/null +++ b/client-new/src/contexts/OnboardingContext.tsx @@ -0,0 +1,317 @@ +import { createContext, useContext, useState } from "react"; +import { IOnboardingFlowState } from "../interfaces/IOnboardingFlowState"; + +type OnboardingContextData = { + page: number; + setPage: React.Dispatch>; + onboardingState: IOnboardingFlowState; + setOnboardingState: React.Dispatch>; + onboardingFlow: Object; + handleChange: (name: string, value: any) => void; +}; + +type OnboardingProviderProps = { + children?: React.ReactNode; +}; + +const OnboardingContext = createContext( + {} as OnboardingContextData +); + +export const OnboardingProvider: React.FC = ({ + children, +}) => { + const [page, setPage] = useState(0); + const [onboardingState, setOnboardingState] = useState({ + worldviewQ1: 3, + worldviewQ2: 3, + worldviewQ3: 3, + worldviewQ4: 3, + worldviewQ5: 3, + worldviewQ6: 3, + emotionalPatternQ1: 3, + emotionalPatternQ2: 3, + emotionalPatternQ3: 3, + workstyleQ1: 3, + workstyleQ2: 3, + workstyleQ3: 3, + workstyleQ4: 3, + socialInclinationQ1: 3, + socialInclinationQ2: 3, + socialInclinationQ3: 3, + funnelActivitiesQ1: 3, + funnelActivitiesQ2: 3, + }); + + const onboardingFlow = [ + { + page: "Sign Up Transition Screen", + props: {}, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ1", + totalCircles: 6, + completedCircles: 0, + questionNumber: "One", + question: + 'When it comes to the future, are you the ultimate planner or more of a "let\'s see what happens" kind of person?', + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ2", + totalCircles: 6, + completedCircles: 1, + questionNumber: "Two", + question: + 'Would you describe yourself as more of a perfectionist or someone who is content with "good enough"?', + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ3", + totalCircles: 6, + completedCircles: 2, + questionNumber: "Three", + question: + "Are you a firm believer in self-improvement, no matter your age?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ4", + totalCircles: 6, + completedCircles: 3, + questionNumber: "Four", + question: + "How open are you to learning and stepping out of your comfort zone?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ5", + totalCircles: 6, + completedCircles: 4, + questionNumber: "Five", + question: + "Do you tend to focus on what you lack or on what you can provide for your loved ones?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "worldviewQ6", + totalCircles: 6, + completedCircles: 5, + questionNumber: "Six", + question: + "Do you take the initiative to plan ahead, or do you wait until circumstances force you to react?", + }, + }, + { + page: "Quiz Section Intro Screen", + props: { + totalCircles: 3, + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "emotionalPatternQ1", + totalCircles: 3, + completedCircles: 0, + questionNumber: "One", + question: "On a typical day, how anxious or calm do you tend to feel?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "emotionalPatternQ2", + totalCircles: 3, + completedCircles: 1, + questionNumber: "Two", + question: + "Is your glass usually half full, or do you tend to see it as half empty?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "emotionalPatternQ3", + totalCircles: 3, + completedCircles: 2, + questionNumber: "Three", + question: + "When making decisions, how often do you consider the emotional burden it might place on those close to you?", + }, + }, + { + page: "Quiz Section Intro Screen", + props: { + totalCircles: 4, + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "workstyleQ1", + totalCircles: 4, + completedCircles: 0, + questionNumber: "One", + question: + "Are you a laser-focused, 'I get things done' dynamo, or more of a 'why stick to one thing when I can multitask' explorer?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "workstyleQ2", + totalCircles: 4, + completedCircles: 1, + questionNumber: "Two", + question: + "Are you more internally motivated to accomplish tasks, or do you rely on external notifications and reminders?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "workstyleQ3", + totalCircles: 4, + completedCircles: 2, + questionNumber: "Three", + question: + "Do you prefer to tackle tasks iteratively over time, or do you prefer to do everything all at once?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "workstyleQ4", + totalCircles: 4, + completedCircles: 3, + questionNumber: "Four", + question: + "Do you prefer in-depth, detailed information when making important decisions, or do you gravitate towards concise, action-oriented advice?", + }, + }, + + { + page: "Quiz Section Intro Screen", + props: { + totalCircles: 3, + }, + }, + + { + page: "Questionaire Screen", + props: { + inputName: "socialInclinationQ1", + totalCircles: 3, + completedCircles: 0, + questionNumber: "One", + question: + "Is talking about death as easy as chatting about the weather, or do you tend to avoid the topic?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "socialInclinationQ2", + totalCircles: 3, + completedCircles: 1, + questionNumber: "Two", + question: + "Are you the go-to person to help friends and family with tricky decisions, or do you prefer someone else to do the heavy lifting?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "socialInclinationQ3", + totalCircles: 3, + completedCircles: 2, + questionNumber: "Three", + question: + "Are you more inclined to focus on your issues, or do you often help others with theirs?", + }, + }, + + { + page: "Quiz Section Intro Screen", + props: { + totalCircles: 2, + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "funnelActivitiesQ1", + totalCircles: 2, + completedCircles: 0, + questionNumber: "One", + question: + "Are you a walking encyclopedia on end-of-life planning, or do you feel like you're navigating uncharted waters?", + }, + }, + { + page: "Questionaire Screen", + props: { + inputName: "funnelActivitiesQ2", + totalCircles: 2, + completedCircles: 1, + questionNumber: "Two", + question: + 'Is your end-of-life planning a "when I get around to it" affair, or are you sprinting towards getting it done?', + }, + }, + { + page: "Persona Screen", + props: {}, + }, + { + page: "Landing Screen", + props: {}, + }, + ]; + + const handleChange = (name: string, value: any) => { + console.log(value); + setOnboardingState((prevData) => ({ + ...prevData, + [name]: value, + })); + }; + + return ( + + {children} + + ); +}; + +export const useOnboarding = (): OnboardingContextData => { + const context = useContext(OnboardingContext); + + if (!context) { + throw new Error("useOnboarding must be used within an AuthProvider"); + } + + return context; +}; diff --git a/client-new/src/interfaces/IOnboardingFlowState.tsx b/client-new/src/interfaces/IOnboardingFlowState.tsx new file mode 100644 index 0000000..ca25a4a --- /dev/null +++ b/client-new/src/interfaces/IOnboardingFlowState.tsx @@ -0,0 +1,20 @@ +export interface IOnboardingFlowState { + worldviewQ1: number; + worldviewQ2: number; + worldviewQ3: number; + worldviewQ4: number; + worldviewQ5: number; + worldviewQ6: number; + emotionalPatternQ1: number; + emotionalPatternQ2: number; + emotionalPatternQ3: number; + workstyleQ1: number; + workstyleQ2: number; + workstyleQ3: number; + workstyleQ4: number; + socialInclinationQ1: number; + socialInclinationQ2: number; + socialInclinationQ3: number; + funnelActivitiesQ1: number; + funnelActivitiesQ2: number; +} diff --git a/client-new/src/navigation/AuthStack.tsx b/client-new/src/navigation/AuthStack.tsx index 82dc2b8..f0288d9 100644 --- a/client-new/src/navigation/AuthStack.tsx +++ b/client-new/src/navigation/AuthStack.tsx @@ -1,16 +1,23 @@ import { createNativeStackNavigator } from "@react-navigation/native-stack"; +import LoginScreen from "../screens/auth/LoginScreen"; +import SignUpScreen from "../screens/auth/SignUpScreen"; import AccessScreen from "../screens/auth/AccessScreen"; +import OnboardingStack from "./OnboardingStack"; const Stack = createNativeStackNavigator(); export default function AuthStack() { - return ( - - - - ); -} \ No newline at end of file + return ( + + + + + + + ); +} diff --git a/client-new/src/navigation/OnboardingStack.tsx b/client-new/src/navigation/OnboardingStack.tsx new file mode 100644 index 0000000..7f1f6d9 --- /dev/null +++ b/client-new/src/navigation/OnboardingStack.tsx @@ -0,0 +1,39 @@ +import { createNativeStackNavigator } from "@react-navigation/native-stack"; +import { OnboardingProvider } from "../contexts/OnboardingContext"; +import QuestionaireScreen from "../screens/auth/QuestionaireScreen"; +import SignUpTransitionScreen from "../screens/auth/SignUpTransitionScreen"; +import PersonaScreen from "../screens/auth/PersonaScreen"; +import LandingScreen from "../screens/auth/LandingScreen"; +import QuizSectionIntroScreen from "../screens/auth/QuizSectionIntroScreen"; +import HomeScreen from "../screens/app/HomeScreen"; + +const Stack = createNativeStackNavigator(); + +export default function OnboardingStack() { + return ( + + + + + + + + + + ); +} diff --git a/client-new/src/navigation/Router.tsx b/client-new/src/navigation/Router.tsx index 729ed89..ebd6341 100644 --- a/client-new/src/navigation/Router.tsx +++ b/client-new/src/navigation/Router.tsx @@ -1,13 +1,13 @@ import { NavigationContainer } from '@react-navigation/native'; -import { useState } from 'react'; import AppStack from './AppStack'; import AuthStack from './AuthStack'; +import { useAuth } from '../contexts/AuthContext'; export default function Router() { - const [authData, setAuthData] = useState(false); + const {user} = useAuth(); return - {authData ? : } + {false ? : } } \ No newline at end of file diff --git a/client-new/src/screens/app/HomeScreen.tsx b/client-new/src/screens/app/HomeScreen.tsx index e1d048b..92c3dca 100644 --- a/client-new/src/screens/app/HomeScreen.tsx +++ b/client-new/src/screens/app/HomeScreen.tsx @@ -1,10 +1,177 @@ -import { Text } from "react-native"; +import { KeyboardAvoidingView, View, Text, } from "native-base"; +import { StyleSheet } from "react-native"; import { SafeAreaView } from "react-native-safe-area-context"; +import { useAuth } from "../../contexts/AuthContext"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import { SvgUri } from "react-native-svg"; +import { createBottomTabNavigator } from '@react-navigation/bottom-tabs'; +import { NavigationContainer } from '@react-navigation/native'; + export default function HomeScreen() { + const { user, logout } = useAuth(); + const testData = [ + { + title: 'Acknowledge Your Aversion to End-Of-Life-Planning', + description: 'Lorem ipsum dolor sit amet consectetur. Ornare vestibulum.', + progress: 33, + }, + { + title: 'Create Familiarity with the Process', + description: 'Lorem ipsum dolor sit amet consectetur. Ornare vestibulum.', + progress: 10, + }, + { + title: 'Define Your Values and Priorities', + description: 'Lorem ipsum dolor sit amet consectetur. Ornare vestibulum.', + progress: 0, + }, + ]; + return ( - - Home Screen, Welcome to Legacy! - + <> + + + + + + + + Hello Amanda! + + + + + + + Your Journey + + + See all + + + + + {testData.map((item, index) => ( + + + + ))} + + + + + + ); } + +const Card = (props) => { + return ( + + + + {props.title} + + + {props.description} + + + + + + + + {props.progress}% + + + + ); +}; diff --git a/client-new/src/screens/auth/AccessScreen.tsx b/client-new/src/screens/auth/AccessScreen.tsx index 7ecae0c..79df79d 100644 --- a/client-new/src/screens/auth/AccessScreen.tsx +++ b/client-new/src/screens/auth/AccessScreen.tsx @@ -1,10 +1,73 @@ -import { Text } from "react-native"; import { SafeAreaView } from "react-native-safe-area-context"; +import QuestionaireBox from "../../components/reusable/QuestionaireBox"; +import { KeyboardAvoidingView, View, Text } from "native-base"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import ScreenWideButton from "../../components/reusable/ScreenWideButton"; + +export default function AccessScreen({ route, navigation }) { + const toSignUp = () => { + navigation.navigate("Sign Up Screen"); + }; + + const toLogin = () => { + navigation.navigate("Login Screen"); + }; -export default function AccessScreen() { return ( - Access Screen, Welcome to Legacy! This is Akshay + + + + + + More Life. + + + Less Stress. + + + + Lorem ipsum dolor sit amet consectetur. Congue habitant fermentum + eget ornare sit. + + + + + + + + + + + + + ); } diff --git a/client-new/src/screens/auth/LandingScreen.tsx b/client-new/src/screens/auth/LandingScreen.tsx new file mode 100644 index 0000000..a05d715 --- /dev/null +++ b/client-new/src/screens/auth/LandingScreen.tsx @@ -0,0 +1,20 @@ +import { KeyboardAvoidingView, Text, View } from "native-base"; +import { SafeAreaView } from "react-native-safe-area-context"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; + +export default function LandingScreen({ route, navigation }) { + return ( + + + + + Landing Page + + + + + ); +} diff --git a/client-new/src/screens/auth/LoginScreen.tsx b/client-new/src/screens/auth/LoginScreen.tsx new file mode 100644 index 0000000..3784676 --- /dev/null +++ b/client-new/src/screens/auth/LoginScreen.tsx @@ -0,0 +1,142 @@ +import { KeyboardAvoidingView, View } from "native-base"; +import { StyleSheet } from "react-native"; +import { SafeAreaView } from "react-native-safe-area-context"; +import { useAuth } from "../../contexts/AuthContext"; +import { useState } from "react"; +import ScreenWideInput from "../../components/reusable/ScreenWideInput"; +import ScreenWideButton from "../../components/reusable/HalfScreenWideButton"; +import SquareButton from "../../components/reusable/SquareButton"; +import CompaniesFooter from "../../components/reusable/CompaniesFooter"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import LetsGo from "../../components/reusable/LetsGo"; + +export default function LoginScreen({ route, navigation }) { + const { user, createAccount, login, logout } = useAuth(); + + const [email, setEmail] = useState(""); + const [password, setPassword] = useState(""); + + const signUp = () => { + createAccount(email, password); + }; + + const signIn = () => { + login(email, password); + }; + + const switchToSignUp = () => { + navigation.navigate("Sign Up Screen"); + }; + + return ( + + + + + + + + + + + setEmail(value)} + value={email} + /> + + setPassword(value)} + value={password} + /> + + + + + + + + + + + + ); +} + +const styles = StyleSheet.create({ + container: { + flex: 1, + justifyContent: "center", + alignItems: "center", + }, + inputContainer: { + width: "80%", + }, + input: { + backgroundColor: "white", + paddingHorizontal: 15, + paddingVertical: 10, + borderRadius: 10, + marginTop: 5, + }, + buttonContainer: { + width: "60%", + justifyContent: "center", + alignItems: "center", + marginTop: 40, + }, + button: { + backgroundColor: "#0782F9", + width: "100%", + padding: 15, + borderRadius: 10, + alignItems: "center", + }, + buttonOutline: { + backgroundColor: "white", + marginTop: 5, + borderColor: "#0782F9", + borderWidth: 2, + }, + buttonText: { + color: "white", + fontWeight: "700", + fontSize: 16, + }, + buttonOutlineText: { + color: "#0782F9", + fontWeight: "700", + fontSize: 16, + }, +}); diff --git a/client-new/src/screens/auth/PersonaScreen.tsx b/client-new/src/screens/auth/PersonaScreen.tsx new file mode 100644 index 0000000..5a53e40 --- /dev/null +++ b/client-new/src/screens/auth/PersonaScreen.tsx @@ -0,0 +1,115 @@ +import { SafeAreaView } from "react-native-safe-area-context"; +import { Text, KeyboardAvoidingView, View } from "native-base"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import ScreenWideButton from "../../components/reusable/ScreenWideButton"; +import { useOnboarding } from "../../contexts/OnboardingContext"; + +export default function PersonaScreen({ route, navigation }) { + const { + page, + setPage, + onboardingState, + setOnboardingState, + onboardingFlow, + handleChange, + } = useOnboarding(); + + const next = async () => { + const nextPage = onboardingFlow[page + 1]; + setPage(page + 1); + navigation.push(nextPage.page, { props: nextPage.props }); + }; + + const calculateScore = () => { + let sum = 0; + for (const response in onboardingState) { + sum += onboardingState[response] + } + if (sum < 18) return "Procrastinating Rookie" + else if (sum < 36) return "Easygoing Explorer" + else if (sum < 54) return "Multitasking Dynamo" + else if (sum < 72) return "Tranquil Trailblazer" + else if (sum < 91) return "Adventurous Optimist" + } + + const getDescription = () => { + const persona = calculateScore(); + if (persona === "Procrastinating Rookie") return "Enjoys a challenge, scarcity mindset, the ultimate planner, a perfectionist, selfish, always on the edge, half-empty glass thinker, externally motivated, all-at-once worker, quick-start guide enthusiast, uncomfortable discussing death, less nurturing, inexperienced with EOLP, racing against time, tight finances, dipping toes in the water." + else if (persona === "Easygoing Explorer") return "Thrives on adventure, abundance advocate, let's-see-what-happens future, content with \"good enough,\" empathetic, beach-level tranquility, sunny disposition, internally motivated, explores tasks over time, full novel enthusiast, comfortable discussing death, nurturing, fairly familiar with EOLP, no rush, tight finances, ready to start." + else if (persona === "Multitasking Dynamo") return "Loves a challenge, abundance believer, the ultimate planner, prefers perfection, selfish, edgy, half-empty glass view, externally motivated, all-at-once worker, quick-start guide fan, uncomfortable discussing death, less nurturing, somewhat familiar with EOLP, procrastinator, comfortable finances, at the starting line." + else if (persona === "Tranquil Trailblazer") return "Adventuresome, abundance thinker, let's-see-what-happens future, content with \"good enough,\" empathetic, always at the beach, glass-half-full mentality, internally motivated, an explorer of tasks, quick-start guide lover, comfortable discussing death, nurturing, knowledgeable about EOLP, no rush, comfortable finances, ready to start." + else if (persona === "Adventurous Optimist") return "Always up for new experiences, believes in abundance, a laid-back planner, a chill perfectionist, empathetic, beach-level calmness, a sunny outlook, internally motivated, explores tasks over time, loves the full novel, comfortable discussing death, nurturing, well-versed in EOLP, has time to plan, financially stable, ready to start." + } + + return ( + + + + + + + + + + You've been assigned: + + + + {calculateScore()} + + + + + + + {getDescription()} + + + + + + + + + ); +} diff --git a/client-new/src/screens/auth/QuestionaireScreen.tsx b/client-new/src/screens/auth/QuestionaireScreen.tsx new file mode 100644 index 0000000..7313d0e --- /dev/null +++ b/client-new/src/screens/auth/QuestionaireScreen.tsx @@ -0,0 +1,88 @@ +import { SafeAreaView } from "react-native-safe-area-context"; +import QuestionaireBox from "../../components/reusable/QuestionaireBox"; +import { Button, Divider, KeyboardAvoidingView, View } from "native-base"; +import CircleProgressBar from "../../components/reusable/CircleProgressBar"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import Icon from "react-native-vector-icons/Ionicons"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import ScreenWideButton from "../../components/reusable/ScreenWideButton"; +import { useOnboarding } from "../../contexts/OnboardingContext"; + +export default function QuestionaireScreen({ route, navigation }) { + const {page, setPage, onboardingState, setOnboardingState, onboardingFlow, handleChange} = useOnboarding(); + const { props } = route.params; + + const back = async () => { + const prevPage = onboardingFlow[page - 1]; + setPage(page - 1); + navigation.pop(); + }; + + const next = async () => { + const nextPage = onboardingFlow[page + 1]; + setPage(page + 1); + navigation.push(nextPage.page, { props: nextPage.props }); + }; + + return ( + + + + + + + + + + + + + + + + + + + + + + + + ); +} diff --git a/client-new/src/screens/auth/QuizSectionIntroScreen.tsx b/client-new/src/screens/auth/QuizSectionIntroScreen.tsx new file mode 100644 index 0000000..94d206a --- /dev/null +++ b/client-new/src/screens/auth/QuizSectionIntroScreen.tsx @@ -0,0 +1,90 @@ +import { KeyboardAvoidingView, View, Text, Divider, Button } from "native-base"; +import { SafeAreaView } from "react-native-safe-area-context"; +import CircleProgressBar from "../../components/reusable/CircleProgressBar"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import Icon from "react-native-vector-icons/MaterialCommunityIcons"; +import { useOnboarding } from "../../contexts/OnboardingContext"; + +export default function QuizSectionIntroScreen({ route, navigation }) { + const { + page, + setPage, + onboardingState, + setOnboardingState, + onboardingFlow, + handleChange, + } = useOnboarding(); + + const next = async () => { + const nextPage = onboardingFlow[page + 1]; + setPage(page + 1); + navigation.push(nextPage.page, { props: nextPage.props }); + }; + const { props } = route.params; + return ( + + + + + + + + + + + Quiz Section Title + + + + + + + Section description here, section purpose and outline here + + + Lorem ipsum dolor sit amet consectetur. Rhoncus viverra adipiscing + cursus amet viverra adipiscing cursus amet + + + + + + + ); +} diff --git a/client-new/src/screens/auth/SignUpScreen.tsx b/client-new/src/screens/auth/SignUpScreen.tsx new file mode 100644 index 0000000..ad9b2fc --- /dev/null +++ b/client-new/src/screens/auth/SignUpScreen.tsx @@ -0,0 +1,185 @@ +import { KeyboardAvoidingView, View } from "native-base"; +import { StyleSheet } from "react-native"; +import { SafeAreaView } from "react-native-safe-area-context"; +import { useAuth } from "../../contexts/AuthContext"; +import { useState } from "react"; +import ScreenWideInput from "../../components/reusable/ScreenWideInput"; +import ScreenWideButton from "../../components/reusable/HalfScreenWideButton"; +import SquareButton from "../../components/reusable/SquareButton"; +import CompaniesFooter from "../../components/reusable/CompaniesFooter"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import LetsGo from "../../components/reusable/LetsGo"; + +export default function SignUpScreen({ route, navigation }) { + const { user, createAccount, login} = useAuth(); + + const [fullName, setFullName] = useState(""); + const [email, setEmail] = useState(""); + const [password, setPassword] = useState(""); + + const signUp = () => { + createAccount(email, password); + navigation.setOptions() + navigation.navigate("Onboarding Stack"); + }; + + const signIn = () => { + login(email, password); + }; + + const switchToLogin = () => { + navigation.navigate("Login Screen"); + }; + + return ( + + + + + + + + + + + setFullName(value)} + value={fullName} + /> + + setEmail(value)} + value={email} + /> + + + setPassword(value)} + value={password} + /> + + + + + + + + + + + + // + // + // + // + // setFullName(value)} + // value={fullName} + // /> + // setEmail(value)} + // value={email} + // /> + // setPassword(value)} + // value={password} + // /> + // + // + // + // + ); +} + +const styles = StyleSheet.create({ + container: { + flex: 1, + justifyContent: "center", + alignItems: "center", + }, + inputContainer: { + width: "80%", + }, + input: { + backgroundColor: "white", + paddingHorizontal: 15, + paddingVertical: 10, + borderRadius: 10, + marginTop: 5, + }, + buttonContainer: { + width: "60%", + justifyContent: "center", + alignItems: "center", + marginTop: 40, + }, + button: { + backgroundColor: "#0782F9", + width: "100%", + padding: 15, + borderRadius: 10, + alignItems: "center", + }, + buttonOutline: { + backgroundColor: "white", + marginTop: 5, + borderColor: "#0782F9", + borderWidth: 2, + }, + buttonText: { + color: "white", + fontWeight: "700", + fontSize: 16, + }, + buttonOutlineText: { + color: "#0782F9", + fontWeight: "700", + fontSize: 16, + }, +}); diff --git a/client-new/src/screens/auth/SignUpTransitionScreen.tsx b/client-new/src/screens/auth/SignUpTransitionScreen.tsx new file mode 100644 index 0000000..3a2ee58 --- /dev/null +++ b/client-new/src/screens/auth/SignUpTransitionScreen.tsx @@ -0,0 +1,89 @@ +import { KeyboardAvoidingView, View, Text, Divider, Button } from "native-base"; +import { SafeAreaView } from "react-native-safe-area-context"; +import CircleProgressBar from "../../components/reusable/CircleProgressBar"; +import LegacyWordmark from "../../components/reusable/LegacyWordmark"; +import { + widthPercentageToDP as w, + heightPercentageToDP as h, +} from "react-native-responsive-screen"; +import Icon from "react-native-vector-icons/MaterialCommunityIcons"; +import { useOnboarding } from "../../contexts/OnboardingContext"; + +export default function SignUpTransitionScreen({ route, navigation }) { + console.log(route); + const { + page, + setPage, + onboardingState, + setOnboardingState, + onboardingFlow, + handleChange, + } = useOnboarding(); + + const next = async () => { + const nextPage = onboardingFlow[page + 1]; + setPage(page + 1); + navigation.push(nextPage.page, { props: nextPage.props }); + }; + + return ( + + + + + + + + + + + Welcome Max! + + + + + + + Our mission is to mission, your mission here, your mission statement + here + + + {" "} + We have a few questions before we going.{" "} + + + + + + + ); +} diff --git a/client-new/tsconfig.json b/client-new/tsconfig.json index 5a05690..0e6371f 100644 --- a/client-new/tsconfig.json +++ b/client-new/tsconfig.json @@ -2,4 +2,3 @@ "compilerOptions": {}, "extends": "expo/tsconfig.base" } - diff --git a/client-new/yarn.lock b/client-new/yarn.lock index 6e895c1..4a13c17 100644 --- a/client-new/yarn.lock +++ b/client-new/yarn.lock @@ -1484,6 +1484,378 @@ find-up "^5.0.0" js-yaml "^4.1.0" +"@firebase/analytics-compat@0.2.6": + version "0.2.6" + resolved "https://registry.yarnpkg.com/@firebase/analytics-compat/-/analytics-compat-0.2.6.tgz#50063978c42f13eb800e037e96ac4b17236841f4" + integrity sha512-4MqpVLFkGK7NJf/5wPEEP7ePBJatwYpyjgJ+wQHQGHfzaCDgntOnl9rL2vbVGGKCnRqWtZDIWhctB86UWXaX2Q== + dependencies: + "@firebase/analytics" "0.10.0" + "@firebase/analytics-types" "0.8.0" + "@firebase/component" "0.6.4" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/analytics-types@0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@firebase/analytics-types/-/analytics-types-0.8.0.tgz#551e744a29adbc07f557306530a2ec86add6d410" + integrity sha512-iRP+QKI2+oz3UAh4nPEq14CsEjrjD6a5+fuypjScisAh9kXKFvdJOZJDwk7kikLvWVLGEs9+kIUS4LPQV7VZVw== + +"@firebase/analytics@0.10.0": + version "0.10.0" + resolved "https://registry.yarnpkg.com/@firebase/analytics/-/analytics-0.10.0.tgz#9c6986acd573c6c6189ffb52d0fd63c775db26d7" + integrity sha512-Locv8gAqx0e+GX/0SI3dzmBY5e9kjVDtD+3zCFLJ0tH2hJwuCAiL+5WkHuxKj92rqQj/rvkBUCfA1ewlX2hehg== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/installations" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/app-check-compat@0.3.7": + version "0.3.7" + resolved "https://registry.yarnpkg.com/@firebase/app-check-compat/-/app-check-compat-0.3.7.tgz#e150f61d653a0f2043a34dcb995616a717161839" + integrity sha512-cW682AxsyP1G+Z0/P7pO/WT2CzYlNxoNe5QejVarW2o5ZxeWSSPAiVEwpEpQR/bUlUmdeWThYTMvBWaopdBsqw== + dependencies: + "@firebase/app-check" "0.8.0" + "@firebase/app-check-types" "0.5.0" + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/app-check-interop-types@0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@firebase/app-check-interop-types/-/app-check-interop-types-0.3.0.tgz#b27ea1397cb80427f729e4bbf3a562f2052955c4" + integrity sha512-xAxHPZPIgFXnI+vb4sbBjZcde7ZluzPPaSK7Lx3/nmuVk4TjZvnL8ONnkd4ERQKL8WePQySU+pRcWkh8rDf5Sg== + +"@firebase/app-check-types@0.5.0": + version "0.5.0" + resolved "https://registry.yarnpkg.com/@firebase/app-check-types/-/app-check-types-0.5.0.tgz#1b02826213d7ce6a1cf773c329b46ea1c67064f4" + integrity sha512-uwSUj32Mlubybw7tedRzR24RP8M8JUVR3NPiMk3/Z4bCmgEKTlQBwMXrehDAZ2wF+TsBq0SN1c6ema71U/JPyQ== + +"@firebase/app-check@0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@firebase/app-check/-/app-check-0.8.0.tgz#b531ec40900af9c3cf1ec63de9094a0ddd733d6a" + integrity sha512-dRDnhkcaC2FspMiRK/Vbp+PfsOAEP6ZElGm9iGFJ9fDqHoPs0HOPn7dwpJ51lCFi1+2/7n5pRPGhqF/F03I97g== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/app-compat@0.2.20": + version "0.2.20" + resolved "https://registry.yarnpkg.com/@firebase/app-compat/-/app-compat-0.2.20.tgz#df996427ce781d51e439e6fee42e5d954645f7bb" + integrity sha512-FXgdjgwUruLMZMh0HDwLmbcu2ImckT10HPdXZyzIJoaor9OenoTQO2RLk2xvvOL/JJnszN6kmv56c+8qA4KFXQ== + dependencies: + "@firebase/app" "0.9.20" + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/app-types@0.9.0": + version "0.9.0" + resolved "https://registry.yarnpkg.com/@firebase/app-types/-/app-types-0.9.0.tgz#35b5c568341e9e263b29b3d2ba0e9cfc9ec7f01e" + integrity sha512-AeweANOIo0Mb8GiYm3xhTEBVCmPwTYAu9Hcd2qSkLuga/6+j9b1Jskl5bpiSQWy9eJ/j5pavxj6eYogmnuzm+Q== + +"@firebase/app@0.9.20": + version "0.9.20" + resolved "https://registry.yarnpkg.com/@firebase/app/-/app-0.9.20.tgz#d5a1d21d3661bf1465189d1b7bde30a3cff97f95" + integrity sha512-cMTDHr+1GfYyHBSLLvvTE8ywlDCKk/E8cUZmfv0ODmUBB1vXgrICShj7yH9UYf6m7l6pxad8T+qI/oAoAkCp2Q== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + idb "7.1.1" + tslib "^2.1.0" + +"@firebase/auth-compat@0.4.6": + version "0.4.6" + resolved "https://registry.yarnpkg.com/@firebase/auth-compat/-/auth-compat-0.4.6.tgz#413568be48d23a17aa14438b8aad86556bd1e132" + integrity sha512-pKp1d4fSf+yoy1EBjTx9ISxlunqhW0vTICk0ByZ3e+Lp6ZIXThfUy4F1hAJlEafD/arM0oepRiAh7LXS1xn/BA== + dependencies: + "@firebase/auth" "1.3.0" + "@firebase/auth-types" "0.12.0" + "@firebase/component" "0.6.4" + "@firebase/util" "1.9.3" + node-fetch "2.6.7" + tslib "^2.1.0" + +"@firebase/auth-interop-types@0.2.1": + version "0.2.1" + resolved "https://registry.yarnpkg.com/@firebase/auth-interop-types/-/auth-interop-types-0.2.1.tgz#78884f24fa539e34a06c03612c75f222fcc33742" + integrity sha512-VOaGzKp65MY6P5FI84TfYKBXEPi6LmOCSMMzys6o2BN2LOsqy7pCuZCup7NYnfbk5OkkQKzvIfHOzTm0UDpkyg== + +"@firebase/auth-types@0.12.0": + version "0.12.0" + resolved "https://registry.yarnpkg.com/@firebase/auth-types/-/auth-types-0.12.0.tgz#f28e1b68ac3b208ad02a15854c585be6da3e8e79" + integrity sha512-pPwaZt+SPOshK8xNoiQlK5XIrS97kFYc3Rc7xmy373QsOJ9MmqXxLaYssP5Kcds4wd2qK//amx/c+A8O2fVeZA== + +"@firebase/auth@1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@firebase/auth/-/auth-1.3.0.tgz#514d77309fdef5cc0ae81d5f57cb07bdaf6822d7" + integrity sha512-vjK4CHbY9aWdiVOrKi6mpa8z6uxeaf7LB/MZTHuZOiGHMcUoTGB6TeMbRShyqk1uaMrxhhZ5Ar/dR0965E1qyA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + node-fetch "2.6.7" + tslib "^2.1.0" + +"@firebase/component@0.6.4": + version "0.6.4" + resolved "https://registry.yarnpkg.com/@firebase/component/-/component-0.6.4.tgz#8981a6818bd730a7554aa5e0516ffc9b1ae3f33d" + integrity sha512-rLMyrXuO9jcAUCaQXCMjCMUsWrba5fzHlNK24xz5j2W6A/SRmK8mZJ/hn7V0fViLbxC0lPMtrK1eYzk6Fg03jA== + dependencies: + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/database-compat@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@firebase/database-compat/-/database-compat-1.0.1.tgz#ab0acbbfb0031080cc16504cef6d00c95cf27ff1" + integrity sha512-ky82yLIboLxtAIWyW/52a6HLMVTzD2kpZlEilVDok73pNPLjkJYowj8iaIWK5nTy7+6Gxt7d00zfjL6zckGdXQ== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/database" "1.0.1" + "@firebase/database-types" "1.0.0" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/database-types@1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@firebase/database-types/-/database-types-1.0.0.tgz#3f7f71c2c3fd1e29d15fce513f14dae2e7543f2a" + integrity sha512-SjnXStoE0Q56HcFgNQ+9SsmJc0c8TqGARdI/T44KXy+Ets3r6x/ivhQozT66bMnCEjJRywYoxNurRTMlZF8VNg== + dependencies: + "@firebase/app-types" "0.9.0" + "@firebase/util" "1.9.3" + +"@firebase/database@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@firebase/database/-/database-1.0.1.tgz#28830f1d0c05ec2f7014658a3165129cec891bcb" + integrity sha512-VAhF7gYwunW4Lw/+RQZvW8dlsf2r0YYqV9W0Gi2Mz8+0TGg1mBJWoUtsHfOr8kPJXhcLsC4eP/z3x6L/Fvjk/A== + dependencies: + "@firebase/auth-interop-types" "0.2.1" + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + faye-websocket "0.11.4" + tslib "^2.1.0" + +"@firebase/firestore-compat@0.3.19": + version "0.3.19" + resolved "https://registry.yarnpkg.com/@firebase/firestore-compat/-/firestore-compat-0.3.19.tgz#71e14de8866fa8f30a6d55b68cc572f258feb11a" + integrity sha512-hRcW9oTyluap8Qko/yqtgk4O/BJmR4FxkvF+P6LVvoqtspKLfQL70jJvzr1gYCCXn2OY8XUI7Q9BVdsTzEEONA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/firestore" "4.3.0" + "@firebase/firestore-types" "3.0.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/firestore-types@3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@firebase/firestore-types/-/firestore-types-3.0.0.tgz#f3440d5a1cc2a722d361b24cefb62ca8b3577af3" + integrity sha512-Meg4cIezHo9zLamw0ymFYBD4SMjLb+ZXIbuN7T7ddXN6MGoICmOTq3/ltdCGoDCS2u+H1XJs2u/cYp75jsX9Qw== + +"@firebase/firestore@4.3.0": + version "4.3.0" + resolved "https://registry.yarnpkg.com/@firebase/firestore/-/firestore-4.3.0.tgz#229de93fa15ed4898b423ea97a693b30e23f1751" + integrity sha512-FwSMCxGdUuA9Su74I9himAKJogzjU41IBjjnNf0+5smORMKtWlNeeXqMpljrhZubj5V+GmWyExf5UD3y1in6FA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + "@firebase/webchannel-wrapper" "0.10.3" + "@grpc/grpc-js" "~1.9.0" + "@grpc/proto-loader" "^0.7.8" + node-fetch "2.6.7" + tslib "^2.1.0" + +"@firebase/functions-compat@0.3.5": + version "0.3.5" + resolved "https://registry.yarnpkg.com/@firebase/functions-compat/-/functions-compat-0.3.5.tgz#7a532d3a9764c6d5fbc1ec5541a989a704326647" + integrity sha512-uD4jwgwVqdWf6uc3NRKF8cSZ0JwGqSlyhPgackyUPe+GAtnERpS4+Vr66g0b3Gge0ezG4iyHo/EXW/Hjx7QhHw== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/functions" "0.10.0" + "@firebase/functions-types" "0.6.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/functions-types@0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@firebase/functions-types/-/functions-types-0.6.0.tgz#ccd7000dc6fc668f5acb4e6a6a042a877a555ef2" + integrity sha512-hfEw5VJtgWXIRf92ImLkgENqpL6IWpYaXVYiRkFY1jJ9+6tIhWM7IzzwbevwIIud/jaxKVdRzD7QBWfPmkwCYw== + +"@firebase/functions@0.10.0": + version "0.10.0" + resolved "https://registry.yarnpkg.com/@firebase/functions/-/functions-0.10.0.tgz#c630ddf12cdf941c25bc8d554e30c3226cd560f6" + integrity sha512-2U+fMNxTYhtwSpkkR6WbBcuNMOVaI7MaH3cZ6UAeNfj7AgEwHwMIFLPpC13YNZhno219F0lfxzTAA0N62ndWzA== + dependencies: + "@firebase/app-check-interop-types" "0.3.0" + "@firebase/auth-interop-types" "0.2.1" + "@firebase/component" "0.6.4" + "@firebase/messaging-interop-types" "0.2.0" + "@firebase/util" "1.9.3" + node-fetch "2.6.7" + tslib "^2.1.0" + +"@firebase/installations-compat@0.2.4": + version "0.2.4" + resolved "https://registry.yarnpkg.com/@firebase/installations-compat/-/installations-compat-0.2.4.tgz#b5557c897b4cd3635a59887a8bf69c3731aaa952" + integrity sha512-LI9dYjp0aT9Njkn9U4JRrDqQ6KXeAmFbRC0E7jI7+hxl5YmRWysq5qgQl22hcWpTk+cm3es66d/apoDU/A9n6Q== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/installations" "0.6.4" + "@firebase/installations-types" "0.5.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/installations-types@0.5.0": + version "0.5.0" + resolved "https://registry.yarnpkg.com/@firebase/installations-types/-/installations-types-0.5.0.tgz#2adad64755cd33648519b573ec7ec30f21fb5354" + integrity sha512-9DP+RGfzoI2jH7gY4SlzqvZ+hr7gYzPODrbzVD82Y12kScZ6ZpRg/i3j6rleto8vTFC8n6Len4560FnV1w2IRg== + +"@firebase/installations@0.6.4": + version "0.6.4" + resolved "https://registry.yarnpkg.com/@firebase/installations/-/installations-0.6.4.tgz#20382e33e6062ac5eff4bede8e468ed4c367609e" + integrity sha512-u5y88rtsp7NYkCHC3ElbFBrPtieUybZluXyzl7+4BsIz4sqb4vSAuwHEUgCgCeaQhvsnxDEU6icly8U9zsJigA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/util" "1.9.3" + idb "7.0.1" + tslib "^2.1.0" + +"@firebase/logger@0.4.0": + version "0.4.0" + resolved "https://registry.yarnpkg.com/@firebase/logger/-/logger-0.4.0.tgz#15ecc03c452525f9d47318ad9491b81d1810f113" + integrity sha512-eRKSeykumZ5+cJPdxxJRgAC3G5NknY2GwEbKfymdnXtnT0Ucm4pspfR6GT4MUQEDuJwRVbVcSx85kgJulMoFFA== + dependencies: + tslib "^2.1.0" + +"@firebase/messaging-compat@0.2.4": + version "0.2.4" + resolved "https://registry.yarnpkg.com/@firebase/messaging-compat/-/messaging-compat-0.2.4.tgz#323ca48deef77065b4fcda3cfd662c4337dffcfd" + integrity sha512-lyFjeUhIsPRYDPNIkYX1LcZMpoVbBWXX4rPl7c/rqc7G+EUea7IEtSt4MxTvh6fDfPuzLn7+FZADfscC+tNMfg== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/messaging" "0.12.4" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/messaging-interop-types@0.2.0": + version "0.2.0" + resolved "https://registry.yarnpkg.com/@firebase/messaging-interop-types/-/messaging-interop-types-0.2.0.tgz#6056f8904a696bf0f7fdcf5f2ca8f008e8f6b064" + integrity sha512-ujA8dcRuVeBixGR9CtegfpU4YmZf3Lt7QYkcj693FFannwNuZgfAYaTmbJ40dtjB81SAu6tbFPL9YLNT15KmOQ== + +"@firebase/messaging@0.12.4": + version "0.12.4" + resolved "https://registry.yarnpkg.com/@firebase/messaging/-/messaging-0.12.4.tgz#ccb49df5ab97d5650c9cf5b8c77ddc34daafcfe0" + integrity sha512-6JLZct6zUaex4g7HI3QbzeUrg9xcnmDAPTWpkoMpd/GoSVWH98zDoWXMGrcvHeCAIsLpFMe4MPoZkJbrPhaASw== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/installations" "0.6.4" + "@firebase/messaging-interop-types" "0.2.0" + "@firebase/util" "1.9.3" + idb "7.0.1" + tslib "^2.1.0" + +"@firebase/performance-compat@0.2.4": + version "0.2.4" + resolved "https://registry.yarnpkg.com/@firebase/performance-compat/-/performance-compat-0.2.4.tgz#95cbf32057b5d9f0c75d804bc50e6ed3ba486274" + integrity sha512-nnHUb8uP9G8islzcld/k6Bg5RhX62VpbAb/Anj7IXs/hp32Eb2LqFPZK4sy3pKkBUO5wcrlRWQa6wKOxqlUqsg== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/performance" "0.6.4" + "@firebase/performance-types" "0.2.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/performance-types@0.2.0": + version "0.2.0" + resolved "https://registry.yarnpkg.com/@firebase/performance-types/-/performance-types-0.2.0.tgz#400685f7a3455970817136d9b48ce07a4b9562ff" + integrity sha512-kYrbr8e/CYr1KLrLYZZt2noNnf+pRwDq2KK9Au9jHrBMnb0/C9X9yWSXmZkFt4UIdsQknBq8uBB7fsybZdOBTA== + +"@firebase/performance@0.6.4": + version "0.6.4" + resolved "https://registry.yarnpkg.com/@firebase/performance/-/performance-0.6.4.tgz#0ad766bfcfab4f386f4fe0bef43bbcf505015069" + integrity sha512-HfTn/bd8mfy/61vEqaBelNiNnvAbUtME2S25A67Nb34zVuCSCRIX4SseXY6zBnOFj3oLisaEqhVcJmVPAej67g== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/installations" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/remote-config-compat@0.2.4": + version "0.2.4" + resolved "https://registry.yarnpkg.com/@firebase/remote-config-compat/-/remote-config-compat-0.2.4.tgz#1f494c81a6c9560b1f9ca1b4fbd4bbbe47cf4776" + integrity sha512-FKiki53jZirrDFkBHglB3C07j5wBpitAaj8kLME6g8Mx+aq7u9P7qfmuSRytiOItADhWUj7O1JIv7n9q87SuwA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/remote-config" "0.4.4" + "@firebase/remote-config-types" "0.3.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/remote-config-types@0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@firebase/remote-config-types/-/remote-config-types-0.3.0.tgz#689900dcdb3e5c059e8499b29db393e4e51314b4" + integrity sha512-RtEH4vdcbXZuZWRZbIRmQVBNsE7VDQpet2qFvq6vwKLBIQRQR5Kh58M4ok3A3US8Sr3rubYnaGqZSurCwI8uMA== + +"@firebase/remote-config@0.4.4": + version "0.4.4" + resolved "https://registry.yarnpkg.com/@firebase/remote-config/-/remote-config-0.4.4.tgz#6a496117054de58744bc9f382d2a6d1e14060c65" + integrity sha512-x1ioTHGX8ZwDSTOVp8PBLv2/wfwKzb4pxi0gFezS5GCJwbLlloUH4YYZHHS83IPxnua8b6l0IXUaWd0RgbWwzQ== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/installations" "0.6.4" + "@firebase/logger" "0.4.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/storage-compat@0.3.2": + version "0.3.2" + resolved "https://registry.yarnpkg.com/@firebase/storage-compat/-/storage-compat-0.3.2.tgz#51a97170fd652a516f729f82b97af369e5a2f8d7" + integrity sha512-wvsXlLa9DVOMQJckbDNhXKKxRNNewyUhhbXev3t8kSgoCotd1v3MmqhKKz93ePhDnhHnDs7bYHy+Qa8dRY6BXw== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/storage" "0.11.2" + "@firebase/storage-types" "0.8.0" + "@firebase/util" "1.9.3" + tslib "^2.1.0" + +"@firebase/storage-types@0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@firebase/storage-types/-/storage-types-0.8.0.tgz#f1e40a5361d59240b6e84fac7fbbbb622bfaf707" + integrity sha512-isRHcGrTs9kITJC0AVehHfpraWFui39MPaU7Eo8QfWlqW7YPymBmRgjDrlOgFdURh6Cdeg07zmkLP5tzTKRSpg== + +"@firebase/storage@0.11.2": + version "0.11.2" + resolved "https://registry.yarnpkg.com/@firebase/storage/-/storage-0.11.2.tgz#c5e0316543fe1c4026b8e3910f85ad73f5b77571" + integrity sha512-CtvoFaBI4hGXlXbaCHf8humajkbXhs39Nbh6MbNxtwJiCqxPy9iH3D3CCfXAvP0QvAAwmJUTK3+z9a++Kc4nkA== + dependencies: + "@firebase/component" "0.6.4" + "@firebase/util" "1.9.3" + node-fetch "2.6.7" + tslib "^2.1.0" + +"@firebase/util@1.9.3": + version "1.9.3" + resolved "https://registry.yarnpkg.com/@firebase/util/-/util-1.9.3.tgz#45458dd5cd02d90e55c656e84adf6f3decf4b7ed" + integrity sha512-DY02CRhOZwpzO36fHpuVysz6JZrscPiBXD0fXp6qSrL9oNOx5KWICKdR95C0lSITzxp0TZosVyHqzatE8JbcjA== + dependencies: + tslib "^2.1.0" + +"@firebase/webchannel-wrapper@0.10.3": + version "0.10.3" + resolved "https://registry.yarnpkg.com/@firebase/webchannel-wrapper/-/webchannel-wrapper-0.10.3.tgz#c894a21e8c911830e36bbbba55903ccfbc7a7e25" + integrity sha512-+ZplYUN3HOpgCfgInqgdDAbkGGVzES1cs32JJpeqoh87SkRobGXElJx+1GZSaDqzFL+bYiX18qEcBK76mYs8uA== + "@formatjs/ecma402-abstract@1.17.2": version "1.17.2" resolved "https://registry.yarnpkg.com/@formatjs/ecma402-abstract/-/ecma402-abstract-1.17.2.tgz#d197c6e26b9fd96ff7ba3b3a0cc2f25f1f2dcac3" @@ -1533,6 +1905,24 @@ resolved "https://registry.yarnpkg.com/@graphql-typed-document-node/core/-/core-3.2.0.tgz#5f3d96ec6b2354ad6d8a28bf216a1d97b5426861" integrity sha512-mB9oAsNCm9aM3/SOv4YtBMqZbYj10R7dkq8byBqxGY/ncFwhf2oQzMV+LCRlWoDSEBJ3COiR1yeDvMtsoOsuFQ== +"@grpc/grpc-js@~1.9.0": + version "1.9.5" + resolved "https://registry.yarnpkg.com/@grpc/grpc-js/-/grpc-js-1.9.5.tgz#22e283754b7b10d1ad26c3fb21849028dcaabc53" + integrity sha512-iouYNlPxRAwZ2XboDT+OfRKHuaKHiqjB5VFYZ0NFrHkbEF+AV3muIUY9olQsp8uxU4VvRCMiRk9ftzFDGb61aw== + dependencies: + "@grpc/proto-loader" "^0.7.8" + "@types/node" ">=12.12.47" + +"@grpc/proto-loader@^0.7.8": + version "0.7.10" + resolved "https://registry.yarnpkg.com/@grpc/proto-loader/-/proto-loader-0.7.10.tgz#6bf26742b1b54d0a473067743da5d3189d06d720" + integrity sha512-CAqDfoaQ8ykFd9zqBDn4k6iWT9loLAlc2ETmDFS9JCD70gDcnA4L3AFEo2iV7KyAtAAHFW9ftq1Fz+Vsgq80RQ== + dependencies: + lodash.camelcase "^4.3.0" + long "^5.0.0" + protobufjs "^7.2.4" + yargs "^17.7.2" + "@hapi/hoek@^9.0.0": version "9.3.0" resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-9.3.0.tgz#8368869dcb735be2e7f5cb7647de78e167a251fb" @@ -1721,6 +2111,59 @@ mkdirp "^1.0.4" rimraf "^3.0.2" +"@protobufjs/aspromise@^1.1.1", "@protobufjs/aspromise@^1.1.2": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@protobufjs/aspromise/-/aspromise-1.1.2.tgz#9b8b0cc663d669a7d8f6f5d0893a14d348f30fbf" + integrity sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ== + +"@protobufjs/base64@^1.1.2": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@protobufjs/base64/-/base64-1.1.2.tgz#4c85730e59b9a1f1f349047dbf24296034bb2735" + integrity sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg== + +"@protobufjs/codegen@^2.0.4": + version "2.0.4" + resolved "https://registry.yarnpkg.com/@protobufjs/codegen/-/codegen-2.0.4.tgz#7ef37f0d010fb028ad1ad59722e506d9262815cb" + integrity sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg== + +"@protobufjs/eventemitter@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz#355cbc98bafad5978f9ed095f397621f1d066b70" + integrity sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q== + +"@protobufjs/fetch@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@protobufjs/fetch/-/fetch-1.1.0.tgz#ba99fb598614af65700c1619ff06d454b0d84c45" + integrity sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ== + dependencies: + "@protobufjs/aspromise" "^1.1.1" + "@protobufjs/inquire" "^1.1.0" + +"@protobufjs/float@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@protobufjs/float/-/float-1.0.2.tgz#5e9e1abdcb73fc0a7cb8b291df78c8cbd97b87d1" + integrity sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ== + +"@protobufjs/inquire@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@protobufjs/inquire/-/inquire-1.1.0.tgz#ff200e3e7cf2429e2dcafc1140828e8cc638f089" + integrity sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q== + +"@protobufjs/path@^1.1.2": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@protobufjs/path/-/path-1.1.2.tgz#6cc2b20c5c9ad6ad0dccfd21ca7673d8d7fbf68d" + integrity sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA== + +"@protobufjs/pool@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@protobufjs/pool/-/pool-1.1.0.tgz#09fd15f2d6d3abfa9b65bc366506d6ad7846ff54" + integrity sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw== + +"@protobufjs/utf8@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@protobufjs/utf8/-/utf8-1.1.0.tgz#a777360b5b39a1a2e5106f8e858f2fd2d060c570" + integrity sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw== + "@react-aria/checkbox@^3.2.1": version "3.11.1" resolved "https://registry.yarnpkg.com/@react-aria/checkbox/-/checkbox-3.11.1.tgz#80cf9548a8d8aee08cf91c0fb3bd21eeada5afa9" @@ -2274,6 +2717,11 @@ prompts "^2.4.0" semver "^7.5.2" +"@react-native-community/slider@^4.4.3": + version "4.4.3" + resolved "https://registry.yarnpkg.com/@react-native-community/slider/-/slider-4.4.3.tgz#9b9dc639b88f5bfda72bd72a9dff55cbf9f777ed" + integrity sha512-WdjvGtqJfqcCiLwtbzie53Z/H6w6dIfRHhlW832D89ySAdE5DxLAsqRhDOG0eacuAxxEB+T9sGCkVMD0fa3aBg== + "@react-native/assets-registry@^0.72.0": version "0.72.0" resolved "https://registry.yarnpkg.com/@react-native/assets-registry/-/assets-registry-0.72.0.tgz#c82a76a1d86ec0c3907be76f7faf97a32bbed05d" @@ -2836,10 +3284,10 @@ dependencies: "@types/istanbul-lib-report" "*" -"@types/node@*": - version "20.8.4" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.8.4.tgz#0e9ebb2ff29d5c3302fc84477d066fa7c6b441aa" - integrity sha512-ZVPnqU58giiCjSxjVUESDtdPk4QR5WQhhINbc9UBrKLU68MX5BF6kbQzTrkwbolyr0X8ChBpXfavr5mZFKZQ5A== +"@types/node@*", "@types/node@>=12.12.47", "@types/node@>=13.7.0": + version "20.8.6" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.8.6.tgz#0dbd4ebcc82ad0128df05d0e6f57e05359ee47fa" + integrity sha512-eWO4K2Ji70QzKUqRy6oyJWUeB7+g2cRagT3T/nxYibYcT4y2BDL8lqolRXjTHmkZCdJfIPaY73KbJAZmcryxTQ== dependencies: undici-types "~5.25.1" @@ -3218,6 +3666,11 @@ balanced-match@^1.0.0: resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== +base-64@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/base-64/-/base-64-0.1.0.tgz#780a99c84e7d600260361511c4877613bf24f6bb" + integrity sha512-Y5gU45svrR5tI2Vt/X9GPd3L0HNIKzGu202EjxrXMpuc2V2CiKgemAbUUsqYmZJvPtCXoUKjNZwBJzsNScUbXA== + base64-js@^1.1.2, base64-js@^1.2.3, base64-js@^1.3.1, base64-js@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" @@ -3514,6 +3967,15 @@ cliui@^6.0.0: strip-ansi "^6.0.0" wrap-ansi "^6.2.0" +cliui@^7.0.2: + version "7.0.4" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-7.0.4.tgz#a0265ee655476fc807aea9df3df8df7783808b4f" + integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^7.0.0" + cliui@^8.0.1: version "8.0.1" resolved "https://registry.yarnpkg.com/cliui/-/cliui-8.0.1.tgz#0c04b075db02cbfe60dc8e6cf2f5486b1a3608aa" @@ -3727,6 +4189,11 @@ crypt@0.0.2, crypt@~0.0.1: resolved "https://registry.yarnpkg.com/crypt/-/crypt-0.0.2.tgz#88d7ff7ec0dfb86f713dc87bbb42d044d3e6c41b" integrity sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow== +crypto-js@^4.0.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/crypto-js/-/crypto-js-4.1.1.tgz#9e485bcf03521041bd85844786b83fb7619736cf" + integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== + crypto-random-string@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e" @@ -3953,9 +4420,9 @@ ee-first@1.1.1: integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== electron-to-chromium@^1.4.535: - version "1.4.551" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.551.tgz#14db6660a88f66ce095ea2657abe5653bc7f42ed" - integrity sha512-/Ng/W/kFv7wdEHYzxdK7Cv0BHEGSkSB3M0Ssl8Ndr1eMiYeas/+Mv4cNaDqamqWx6nd2uQZfPz6g25z25M/sdw== + version "1.4.554" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.554.tgz#04e09c2ee31dc0f1546174033809b54cc372740b" + integrity sha512-Q0umzPJjfBrrj8unkONTgbKQXzXRrH7sVV7D9ea2yBV3Oaogz991yhbpfvo2LMNkJItmruXTEzVpP9cp7vaIiQ== emoji-regex@^8.0.0: version "8.0.0" @@ -4204,6 +4671,11 @@ expo-modules-core@1.5.11: compare-versions "^3.4.0" invariant "^2.2.4" +expo-secure-store@^12.5.0: + version "12.5.0" + resolved "https://registry.yarnpkg.com/expo-secure-store/-/expo-secure-store-12.5.0.tgz#f52456e15315d64d1e9000384d4a837eea9dbb1f" + integrity sha512-Ow2ei+SB1w4zPLxmOg2PVPf2i45Eii0T9KUaER5iRLJAMcBWN4nyGCxzESOoN3OrvxVadP0hAn6RVE1G3gdD+Q== + expo-status-bar@~1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/expo-status-bar/-/expo-status-bar-1.6.0.tgz#e79ffdb9a84d2e0ec9a0dc7392d9ab364fefa9cf" @@ -4275,6 +4747,13 @@ fastq@^1.6.0: dependencies: reusify "^1.0.4" +faye-websocket@0.11.4: + version "0.11.4" + resolved "https://registry.yarnpkg.com/faye-websocket/-/faye-websocket-0.11.4.tgz#7f0d9275cfdd86a1c963dc8b65fcc451edcbb1da" + integrity sha512-CzbClwlXAuiRQAlUyfqPgvPoNKTckTPGfwZV4ZdAhVcP2lh9KUxJg2b5GkE7XbjKQ3YJnQ9z6D9ntLAlB+tP8g== + dependencies: + websocket-driver ">=0.5.1" + fb-watchman@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.2.tgz#e9524ee6b5c77e9e5001af0f85f3adbb8623255c" @@ -4384,6 +4863,38 @@ find-yarn-workspace-root@~2.0.0: dependencies: micromatch "^4.0.2" +firebase@^10.5.0: + version "10.5.0" + resolved "https://registry.yarnpkg.com/firebase/-/firebase-10.5.0.tgz#bc04ff746b0e6a7bd2bc21b63eeb46eb68d61c9d" + integrity sha512-ROwoOFQa7tZret/giHtVJH4YCRLCuKpN386mxzXd0likAVmv+38YGkJiqfkmZju7dIQ+QJOvBScXVf27Kvob0g== + dependencies: + "@firebase/analytics" "0.10.0" + "@firebase/analytics-compat" "0.2.6" + "@firebase/app" "0.9.20" + "@firebase/app-check" "0.8.0" + "@firebase/app-check-compat" "0.3.7" + "@firebase/app-compat" "0.2.20" + "@firebase/app-types" "0.9.0" + "@firebase/auth" "1.3.0" + "@firebase/auth-compat" "0.4.6" + "@firebase/database" "1.0.1" + "@firebase/database-compat" "1.0.1" + "@firebase/firestore" "4.3.0" + "@firebase/firestore-compat" "0.3.19" + "@firebase/functions" "0.10.0" + "@firebase/functions-compat" "0.3.5" + "@firebase/installations" "0.6.4" + "@firebase/installations-compat" "0.2.4" + "@firebase/messaging" "0.12.4" + "@firebase/messaging-compat" "0.2.4" + "@firebase/performance" "0.6.4" + "@firebase/performance-compat" "0.2.4" + "@firebase/remote-config" "0.4.4" + "@firebase/remote-config-compat" "0.2.4" + "@firebase/storage" "0.11.2" + "@firebase/storage-compat" "0.3.2" + "@firebase/util" "1.9.3" + flow-enums-runtime@^0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/flow-enums-runtime/-/flow-enums-runtime-0.0.5.tgz#95884bfcc82edaf27eef7e1dd09732331cfbafbc" @@ -4470,9 +4981,9 @@ fsevents@^2.3.2: integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + version "1.1.2" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" + integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== gensync@^1.0.0-beta.2: version "1.0.0-beta.2" @@ -4665,6 +5176,11 @@ http-errors@2.0.0: statuses "2.0.1" toidentifier "1.0.1" +http-parser-js@>=0.5.1: + version "0.5.8" + resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.5.8.tgz#af23090d9ac4e24573de6f6aecc9d84a48bf20e3" + integrity sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q== + https-proxy-agent@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" @@ -4690,6 +5206,16 @@ iconv-lite@0.4.24: dependencies: safer-buffer ">= 2.1.2 < 3" +idb@7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/idb/-/idb-7.0.1.tgz#d2875b3a2f205d854ee307f6d196f246fea590a7" + integrity sha512-UUxlE7vGWK5RfB/fDwEGgRf84DY/ieqNha6msMV99UsEMQhJ1RwbCd8AYBj3QMgnE3VZnfQvm4oKVCJTYlqIgg== + +idb@7.1.1: + version "7.1.1" + resolved "https://registry.yarnpkg.com/idb/-/idb-7.1.1.tgz#d910ded866d32c7ced9befc5bfdf36f572ced72b" + integrity sha512-gchesWBzyvGHRO9W8tzUWFDycow5gwjvFKfyV9FF32Y7F50yZMp7mP+T2mJIWFx49zicqyC4uefHM17o6xKIVQ== + ieee754@^1.1.13: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" @@ -5072,6 +5598,11 @@ js-yaml@^4.1.0: dependencies: argparse "^2.0.1" +jsbn@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-1.1.0.tgz#b01307cb29b618a1ed26ec79e911f803c4da0040" + integrity sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A== + jsc-android@^250231.0.0: version "250231.0.0" resolved "https://registry.yarnpkg.com/jsc-android/-/jsc-android-250231.0.0.tgz#91720f8df382a108872fa4b3f558f33ba5e95262" @@ -5157,6 +5688,11 @@ jsonfile@^6.0.1: optionalDependencies: graceful-fs "^4.1.6" +jwt-decode@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/jwt-decode/-/jwt-decode-3.1.2.tgz#3fb319f3675a2df0c2895c8f5e9fa4b67b04ed59" + integrity sha512-UfpWE/VZn0iP50d8cz9NrZLM9lSWhcJ+0Gt/nm4by88UL+J1SiKN8/5dkjMmbEzwL2CAe+67GsegCbIKtbp75A== + kind-of@^6.0.2: version "6.0.3" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" @@ -5262,6 +5798,11 @@ locate-path@^6.0.0: dependencies: p-locate "^5.0.0" +lodash.camelcase@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz#b28aa6288a2b9fc651035c7711f65ab6190331a6" + integrity sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA== + lodash.clonedeep@^4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" @@ -5361,6 +5902,11 @@ logkitty@^0.7.1: dayjs "^1.8.15" yargs "^15.1.0" +long@^5.0.0: + version "5.2.3" + resolved "https://registry.yarnpkg.com/long/-/long-5.2.3.tgz#a3ba97f3877cf1d778eccbcb048525ebb77499e1" + integrity sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q== + loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" @@ -5963,6 +6509,13 @@ node-dir@^0.1.17: dependencies: minimatch "^3.0.2" +node-fetch@2.6.7: + version "2.6.7" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" + integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ== + dependencies: + whatwg-url "^5.0.0" + node-fetch@^2.2.0, node-fetch@^2.6.0, node-fetch@^2.6.1, node-fetch@^2.6.12, node-fetch@^2.6.7: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" @@ -6324,6 +6877,11 @@ postcss@~8.4.21: picocolors "^1.0.0" source-map-js "^1.0.2" +prettier-quick@^0.0.5: + version "0.0.5" + resolved "https://registry.yarnpkg.com/prettier-quick/-/prettier-quick-0.0.5.tgz#10912263ede6e99872f4d3655b6a8a205265d4ce" + integrity sha512-5zOMSPAK7JQMNWjtxAy35XPgRN8TQY+khgpNhznQ30Zsv6V0hOIjre8X5cTrtdqa3NKZWWF1+TNS5+1LX/3a0w== + pretty-bytes@5.6.0: version "5.6.0" resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-5.6.0.tgz#356256f643804773c82f64723fe78c92c62beaeb" @@ -6385,7 +6943,7 @@ prompts@^2.3.2, prompts@^2.4.0: kleur "^3.0.3" sisteransi "^1.0.5" -prop-types@*: +prop-types@*, prop-types@^15.7.2, prop-types@^15.8.1: version "15.8.1" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5" integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg== @@ -6394,6 +6952,24 @@ prop-types@*: object-assign "^4.1.1" react-is "^16.13.1" +protobufjs@^7.2.4: + version "7.2.5" + resolved "https://registry.yarnpkg.com/protobufjs/-/protobufjs-7.2.5.tgz#45d5c57387a6d29a17aab6846dcc283f9b8e7f2d" + integrity sha512-gGXRSXvxQ7UiPgfw8gevrfRWcTlSbOFg+p/N+JVJEK5VhueL2miT6qTymqAmjr1Q5WbOCyJbyrk6JfWKwlFn6A== + dependencies: + "@protobufjs/aspromise" "^1.1.2" + "@protobufjs/base64" "^1.1.2" + "@protobufjs/codegen" "^2.0.4" + "@protobufjs/eventemitter" "^1.1.0" + "@protobufjs/fetch" "^1.1.0" + "@protobufjs/float" "^1.0.2" + "@protobufjs/inquire" "^1.1.0" + "@protobufjs/path" "^1.1.2" + "@protobufjs/pool" "^1.1.0" + "@protobufjs/utf8" "^1.1.0" + "@types/node" ">=13.7.0" + long "^5.0.0" + pump@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" @@ -6402,6 +6978,11 @@ pump@^3.0.0: end-of-stream "^1.1.0" once "^1.3.1" +punycode@^1.4.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" + integrity sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ== + qrcode-terminal@0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/qrcode-terminal/-/qrcode-terminal-0.11.0.tgz#ffc6c28a2fc0bfb47052b47e23f4f446a5fbdb9e" @@ -6414,6 +6995,13 @@ qs@6.11.0: dependencies: side-channel "^1.0.4" +qs@^6.11.2: + version "6.11.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" + integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== + dependencies: + side-channel "^1.0.4" + query-string@^7.1.3: version "7.1.3" resolved "https://registry.yarnpkg.com/query-string/-/query-string-7.1.3.tgz#a1cf90e994abb113a325804a972d98276fe02328" @@ -6502,6 +7090,19 @@ react-is@^17.0.1: resolved "https://registry.yarnpkg.com/react-is/-/react-is-17.0.2.tgz#e691d4a8e9c789365655539ab372762b0efb54f0" integrity sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w== +react-native-auth0@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/react-native-auth0/-/react-native-auth0-3.0.2.tgz#e7fb5995f67114e4f685648af8f2d1242f4ef558" + integrity sha512-lHrUH/bFivYUXjK/HprKFca8gllTjCkOe00jIPo7B1Wh5xEB2OEpFZizD+cJHN6SlSU8ZUIRgBNJVhf1GwsW2A== + dependencies: + base-64 "^0.1.0" + crypto-js "^4.0.0" + jsbn "^1.1.0" + jwt-decode "^3.1.2" + prettier-quick "^0.0.5" + prop-types "^15.8.1" + url "^0.11.0" + react-native-responsive-screen@^1.4.2: version "1.4.2" resolved "https://registry.yarnpkg.com/react-native-responsive-screen/-/react-native-responsive-screen-1.4.2.tgz#45280826d24f9accbfdf46a36cb8e6d780f76f28" @@ -6528,6 +7129,14 @@ react-native-svg@^13.14.0: css-select "^5.1.0" css-tree "^1.1.3" +react-native-vector-icons@^10.0.0: + version "10.0.0" + resolved "https://registry.yarnpkg.com/react-native-vector-icons/-/react-native-vector-icons-10.0.0.tgz#0f031f7717f76f0a397f725de9b5a47ec87862e9" + integrity sha512-efMOVbZIebY8RszZPzPBoXi9pvD/NFYmjIDYxRoc9LYSzV8rMJtT8FfcO2hPu85Rn2x9xktha0+qn0B7EqMAcQ== + dependencies: + prop-types "^15.7.2" + yargs "^16.1.1" + react-native@0.72.5: version "0.72.5" resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.72.5.tgz#2c343fa6f3ead362cf07376634a33a4078864357" @@ -6801,7 +7410,7 @@ safe-buffer@5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safe-buffer@~5.2.0: +safe-buffer@>=5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== @@ -7534,6 +8143,14 @@ url-parse@^1.5.9: querystringify "^2.1.1" requires-port "^1.0.0" +url@^0.11.0: + version "0.11.3" + resolved "https://registry.yarnpkg.com/url/-/url-0.11.3.tgz#6f495f4b935de40ce4a0a52faee8954244f3d3ad" + integrity sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw== + dependencies: + punycode "^1.4.1" + qs "^6.11.2" + use-latest-callback@^0.1.5: version "0.1.6" resolved "https://registry.yarnpkg.com/use-latest-callback/-/use-latest-callback-0.1.6.tgz#3fa6e7babbb5f9bfa24b5094b22939e1e92ebcf6" @@ -7615,6 +8232,20 @@ webidl-conversions@^3.0.0: resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== +websocket-driver@>=0.5.1: + version "0.7.4" + resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.4.tgz#89ad5295bbf64b480abcba31e4953aca706f5760" + integrity sha512-b17KeDIQVjvb0ssuSDF2cYXSg2iztliJ4B9WdsuB6J952qCPKmnVq4DyW5motImXHDC1cBT/1UezrJVsKw5zjg== + dependencies: + http-parser-js ">=0.5.1" + safe-buffer ">=5.1.0" + websocket-extensions ">=0.1.1" + +websocket-extensions@>=0.1.1: + version "0.1.4" + resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.4.tgz#7f8473bc839dfd87608adb95d7eb075211578a42" + integrity sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg== + whatwg-fetch@^3.0.0: version "3.6.19" resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.6.19.tgz#caefd92ae630b91c07345537e67f8354db470973" @@ -7775,6 +8406,11 @@ yargs-parser@^18.1.2: camelcase "^5.0.0" decamelize "^1.2.0" +yargs-parser@^20.2.2: + version "20.2.9" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" + integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== + yargs-parser@^21.1.1: version "21.1.1" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" @@ -7797,7 +8433,20 @@ yargs@^15.1.0: y18n "^4.0.0" yargs-parser "^18.1.2" -yargs@^17.6.2: +yargs@^16.1.1: + version "16.2.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66" + 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" + +yargs@^17.6.2, yargs@^17.7.2: version "17.7.2" resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269" integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w== diff --git a/server/data.sql b/server/data.sql new file mode 100644 index 0000000..76dfd60 --- /dev/null +++ b/server/data.sql @@ -0,0 +1,105 @@ +-- Creating test personas +INSERT INTO personas (persona_title, persona_description, created_at, updated_at) VALUES +('Procrastinating Rookie', 'Compassionate and reassuring', clock_timestamp(), clock_timestamp()), +('Adventurous Optimist', 'Informed and death positive', clock_timestamp(), clock_timestamp()), +('Adventurous Optimist with Wealth', 'Expert driven and death positive', clock_timestamp(), clock_timestamp()); + +-- Creating test users +INSERT INTO users (username, password, email, persona_id, created_at, updated_at) VALUES +('testuser1', 'password', 'user1@example.com', 1, clock_timestamp(), clock_timestamp()), +('testuser2', 'password', 'user2@example.com', 2, clock_timestamp(), clock_timestamp()), +('testuser3', 'password', 'user3@example.com', 3, clock_timestamp(), clock_timestamp()), +('testuser4', 'password', 'user4@example.com', 1, clock_timestamp(), clock_timestamp()), +('testuser5', 'password', 'user5@example.com', 2, clock_timestamp(), clock_timestamp()); + +-- Creating user profile +INSERT INTO user_profiles (name, user_id, date_of_birth, phone_number, created_at, updated_at) VALUES +('Test User 1', 1, '1990-01-01', '5555555555', clock_timestamp(), clock_timestamp()), +('Test User 2', 2, '1990-01-01', '5555555555', clock_timestamp(), clock_timestamp()), +('Test User 3', 3, '1990-01-01', '5555555555', clock_timestamp(), clock_timestamp()), +('Test User 4', 4, '1990-01-01', '5555555555', clock_timestamp(), clock_timestamp()), +('Test User 5', 5, '1990-01-01', '5555555555', clock_timestamp(), clock_timestamp()); + +-- Creating test tasks +INSERT INTO tasks (task_name, task_description, created_at, updated_at) VALUES +('Acknowledging Fear', 'Acknowledge your aversion to end of life planning', clock_timestamp(), clock_timestamp()), +('Understanding EOLP', 'Create familiarity with the process', clock_timestamp(), clock_timestamp()), +('Values and Priorities', 'Define your values and priorities', clock_timestamp(), clock_timestamp()), +('Initial Plan', 'Create an initial end-of-life plan', clock_timestamp(), clock_timestamp()), +('Existing Financials', 'Review your existing financial plan', clock_timestamp(), clock_timestamp()), +('Non-financial Aspects', 'Explore non-financial aspects', clock_timestamp(), clock_timestamp()), +('Will', 'Create a comprehensive will', clock_timestamp(), clock_timestamp()), +('Specific Wishes', 'Communicate any specific wishes', clock_timestamp(), clock_timestamp()), +('Plan Moving Forward', 'Regularly review and update', clock_timestamp(), clock_timestamp()), +('Assemble Team', 'Assemble your financial team', clock_timestamp(), clock_timestamp()), +('Living Trust', 'Establish a revocable living trust', clock_timestamp(), clock_timestamp()), +('Tax Planning', 'Leverage tax planning strategies', clock_timestamp(), clock_timestamp()), +('Family Governance', 'Develop a family governance plan.', clock_timestamp(), clock_timestamp()), +('Emotional and Spiritual', 'Address emotional and spiritual concerns.', clock_timestamp(), clock_timestamp()), +('Create Project', 'Create a legacy project', clock_timestamp(), clock_timestamp()); + +-- Creating test task progress +INSERT INTO task_progresses (user_id, task_id, completed) VALUES +(1, 1, True), +(1, 2, True), +(1, 3, False), +(1, 4, True); + + +-- Creating test subtasks +INSERT INTO sub_tasks (task_id, task_name, task_description, created_at, updated_at) VALUES +(1, 'Research Fear', 'Research books, articles, or podcasts on overcoming fear of death.', clock_timestamp(), clock_timestamp()), +(1, 'Connect With Support', 'Connect with a local support group for individuals facing similar fears.', clock_timestamp(), clock_timestamp()), +(1, 'Manage Anxiety', 'Explore mindfulness or meditation practices to help manage anxiety related to end-of-life topics.', clock_timestamp(), clock_timestamp()), +(2, 'Create Checklist', 'Create a checklist of basic personal information needed for end-of-life planning.', clock_timestamp(), clock_timestamp()), +(3, 'Your Values', 'Write down your personal values and beliefs.', clock_timestamp(), clock_timestamp()), +(3, 'Causes to Support', 'Identify specific causes or charities you would like to support', clock_timestamp(), clock_timestamp()), +(3, 'Legacy Statement', 'Legacy statement or ethical will to pass on your values to loved ones.', clock_timestamp(), clock_timestamp()), +(4, 'Draft Intentions', 'Draft a simple letter of intent outlining your wishes for end-of-life care.', clock_timestamp(), clock_timestamp()), +(4, 'Legal Plans', 'Complete healthcare proxies and power of attorney agents.', clock_timestamp(), clock_timestamp()), +(5, 'Financial Inventory', 'Conduct a thorough inventory of all financial accounts and assets.', clock_timestamp(), clock_timestamp()), +(5, 'Life Insurance', 'Review and update your life insurance policies, including coverage amounts and beneficiaries.', clock_timestamp(), clock_timestamp()), +(5, 'Financial Document Storage', 'Store digital copies of important financial documents in a secure location.', clock_timestamp(), clock_timestamp()), +(6, 'Personal Values', 'Create a comprehensive list of your personal values, preferences', clock_timestamp(), clock_timestamp()), +(6, 'Important Contacts', 'Create a comprehensive list of important contacts.', clock_timestamp(), clock_timestamp()), +(6, 'Organ Donation', 'Document your preferred organ donation choices', clock_timestamp(), clock_timestamp()), +(6, 'Burial/Cremation', 'Document your preferred burial or cremation preferences.', clock_timestamp(), clock_timestamp()), +(6, 'Eulogy', 'Create a eulogy for yourself', clock_timestamp(), clock_timestamp()), +(7, 'Asset Distribution', 'Leverage draft specific clauses regarding asset distribution, including any conditional bequests.', clock_timestamp(), clock_timestamp()), +(7, 'Minor Children', 'Designate a guardian for minor children and establish trusts for their care.', clock_timestamp(), clock_timestamp()), +(7, 'Digital Assets', 'Include provisions for digital assets, such as passwords and access instructions.', clock_timestamp(), clock_timestamp()), +(8, 'Family Members', 'Schedule individual meetings with family members to discuss your end-of-life plans.', clock_timestamp(), clock_timestamp()), +(8, 'Financial Institutions', 'Provide your executor with a detailed list of your financial institutions, account numbers, and contact information.', clock_timestamp(), clock_timestamp()), +(8, 'Important Document Location', 'Share the location of your important documents, such as your will and healthcare directives.', clock_timestamp(), clock_timestamp()), +(9, 'Annual Reminder', 'Set up an automated annual reminder for financial plan reviews.', clock_timestamp(), clock_timestamp()), +(9, 'Major Life Change Updates', 'Update your beneficiaries and estate plan whenever you experience significant life changes, such as marriage, divorce, or the birth of a child.', clock_timestamp(), clock_timestamp()), +(9, 'Periodic Preference Reviews', 'Conduct periodic reviews of your funeral or memorial preferences and make adjustments as needed.', clock_timestamp(), clock_timestamp()), +(10, 'Find Lawyer', 'Research and interview multiple trust and estate lawyers to find the most suitable one.', clock_timestamp(), clock_timestamp()), +(10, 'Financial Planner', 'Hire a financial planner to create a detailed financial roadmap and investment strategy.', clock_timestamp(), clock_timestamp()), +(10, 'Certified Public Accountant', 'Collaborate with a certified public accountant (CPA) to address tax planning and compliance.', clock_timestamp(), clock_timestamp()), +(11, 'Comprehensive Trust Document', 'Consult with your trust and estate lawyer to draft a comprehensive trust document.', clock_timestamp(), clock_timestamp()), +(11, 'Asset Inventory', 'Review and update your asset inventory to ensure all valuable assets are included in the trust.', clock_timestamp(), clock_timestamp()), +(11, 'Backup Successor Trustees', 'Appoint backup successor trustees and provide them with necessary information.', clock_timestamp(), clock_timestamp()), +(12, 'Tax Planning Calendar', 'Create a comprehensive tax planning calendar outlining important deadlines.', clock_timestamp(), clock_timestamp()), +(12, 'Reducing Estate Tax Liability', 'Implement gifting strategies to reduce potential estate tax liability.', clock_timestamp(), clock_timestamp()), +(12, 'Charitable Giving', 'Consult with a philanthropic advisor to structure charitable giving in a tax-efficient manner.', clock_timestamp(), clock_timestamp()), +(15, 'Family Meetings', 'Schedule regular family meetings, including an annual retreat to discuss long-term objectives.', clock_timestamp(), clock_timestamp()), +(13, 'Family Counseling', 'Work with a family therapist or counselor to facilitate constructive communication and conflict resolution strategies.', clock_timestamp(), clock_timestamp()), +(13, 'Family Mission', 'Create a family mission statement or constitution outlining the family''s values, mission, and governance principles.', clock_timestamp(), clock_timestamp()), +(14, 'Death Doula', 'Arrange meetings with a death doula and spiritual advisor to explore emotional and spiritual concerns.', clock_timestamp(), clock_timestamp()), +(15, 'Life Story', 'Record your life story and personal anecdotes to pass on your legacy.', clock_timestamp(), clock_timestamp()), +(15, 'Family Philanthropic Participation', 'Establish a process for family members to participate in philanthropic initiatives and maintain alignment with family values.', clock_timestamp(), clock_timestamp()); + +-- Insert relationships into the persona_tasks junction table + +-- Persona 1: Procrastinating Rookie +INSERT INTO persona_tasks (persona_id, task_id) VALUES +(1, 1), (1, 2), (1, 3), (1, 4), (1, 5), (1, 6), (1, 7), (1, 8); + +-- Persona 2: Adventurous Optimist +INSERT INTO persona_tasks (persona_id, task_id) VALUES +(2, 4), (2, 5), (2, 6), (2, 6), (2, 6), (2, 7), (2, 8), (2, 9), (2, 9), (2, 9), (2, 10), (2, 11), (2, 12), (2, 13), (2, 14), (2, 15); + +-- Persona 3: Adventurous Optimist with Wealth +INSERT INTO persona_tasks (persona_id, task_id) VALUES +(3, 10), (3, 11), (3, 12), (3, 13), (3, 11), (3, 14), (3, 15), (3, 16), (3, 17), (3, 18), (3, 19), (3, 20), (3, 21), (3, 22), (3, 23), (3, 24), (3, 25), (3, 26), (3, 27), (3, 28); diff --git a/server/src/controller/setup.go b/server/src/controller/setup.go index 496834f..739dc12 100644 --- a/server/src/controller/setup.go +++ b/server/src/controller/setup.go @@ -22,6 +22,7 @@ func SetupControllers(e *echo.Echo, db *gorm.DB) { e.GET("api/users", userController.GetAllUsers) e.GET("api/users/:uid", userController.GetUser) e.GET("api/users/username/:username", userController.GetUserFromUsername) + e.GET("api/users/firebase/:firebaseid", userController.GetUserFromFirebaseID) // Once user gets created call this functon X // e.POST("api/progress/:uid", taskprogressController.CreateAllTaskProgress) @@ -30,6 +31,7 @@ func SetupControllers(e *echo.Echo, db *gorm.DB) { e.GET("api/users/:uid/persona", userController.GetUserPersona) e.GET("api/users/:uid/tasks", userController.GetUserTasks) + e.GET("api/users/:uid/profile", userController.GetUserProfile) e.POST("api/users", userController.CreateUser) e.PUT("api/users/:uid", userController.UpdateUser) @@ -49,8 +51,9 @@ func SetupControllers(e *echo.Echo, db *gorm.DB) { // User Profile routes e.GET("api/profiles/:upid", userProfileController.GetUserProfile) - e.POST("api/profiles/:uid/", userProfileController.CreateUserProfile) + e.POST("api/profiles/:uid/", userProfileController.CreateUserProfile) // Creates a user profile for the given user e.PUT("api/profiles/:upid", userProfileController.UpdateUserProfile) + e.PUT("api/profiles/response/:uid", userProfileController.CreateOnboardingResponse) e.DELETE("api/profiles/:upid", userProfileController.DeleteUserProfile) // Task routes diff --git a/server/src/controller/user.go b/server/src/controller/user.go index db1b89c..46208fd 100644 --- a/server/src/controller/user.go +++ b/server/src/controller/user.go @@ -71,9 +71,28 @@ func (u *UserController) GetUserTasks(c echo.Context) error { if len(tasks) == 0 { return c.JSON(http.StatusNotFound, "Persona does not have any tasks") } + return c.JSON(http.StatusOK, tasks) } +func (u *UserController) GetUserProfile(c echo.Context) error { + var user model.User + var userProfile model.UserProfile + userID := c.Param("uid") + + err := u.DB.First(&user, userID).Error + if err != nil { + return c.JSON(http.StatusNotFound, "User not found") + } + + err = u.DB.Where("user_id = ?", user.ID).First(&userProfile).Error + if err != nil { + return c.JSON(http.StatusNotFound, "User does not have a profile") + } + + return c.JSON(http.StatusOK, userProfile) +} + func (u *UserController) GetUserFromUsername(c echo.Context) error { username := c.Param("username") // Extract username from the query parameter var user model.User @@ -85,6 +104,20 @@ func (u *UserController) GetUserFromUsername(c echo.Context) error { return c.JSON(http.StatusOK, user) } +func (u *UserController) GetUserFromFirebaseID(c echo.Context) error { + var user model.User + fib := c.Param("firebaseid") + + u.DB.Where("firebase_id = ?", fib).First(&user) + + if user.ID == 0 { + return c.JSON(http.StatusNotFound, "User not found or does not havea firebase id") + } + + return c.JSON(http.StatusOK, user) +} + +// TODO: Should create a user profile when a user is created func (u *UserController) CreateUser(c echo.Context) error { var user model.User @@ -105,7 +138,10 @@ func (u *UserController) CreateUser(c echo.Context) error { return c.JSON(http.StatusBadRequest, map[string]string{"error": err.Error()}) } - u.DB.Create(&user) + err := u.DB.Create(&user).Error + if err != nil { + return c.JSON(http.StatusBadRequest, map[string]string{"error": err.Error()}) + } return c.JSON(http.StatusCreated, user) } diff --git a/server/src/controller/user_profile.go b/server/src/controller/user_profile.go index 55dd45a..92c270f 100644 --- a/server/src/controller/user_profile.go +++ b/server/src/controller/user_profile.go @@ -1,6 +1,7 @@ package controller import ( + "encoding/json" "net/http" "server/src/model" @@ -85,6 +86,74 @@ func (up *UserProfileController) UpdateUserProfile(c echo.Context) error { return c.JSON(http.StatusOK, userprofile) } +type OnboardingResponse struct { + WorldviewQ1 string `json:"worldviewQ1"` + WorldviewQ2 string `json:"worldviewQ2"` + WorldviewQ3 string `json:"worldviewQ3"` + WorldviewQ4 string `json:"worldviewQ4"` + WorldviewQ5 string `json:"worldviewQ5"` + WorldviewQ6 string `json:"worldviewQ6"` + EmotionalPatternQ1 string `json:"emotionalPatternQ1"` + EmotionalPatternQ2 string `json:"emotionalPatternQ2"` + EmotionalPatternQ3 string `json:"emotionalPatternQ3"` + WorkstyleQ1 string `json:"workstyleQ1"` + WorkstyleQ2 string `json:"workstyleQ2"` + WorkstyleQ3 string `json:"workstyleQ3"` + WorkstyleQ4 string `json:"workstyleQ4"` + SocialInclinationQ1 string `json:"socialInclinationQ1"` + SocialInclinationQ2 string `json:"socialInclinationQ2"` + SocialInclinationQ3 string `json:"socialInclinationQ3"` + FunnelActivitiesQ1 string `json:"funnelActivitiesQ1"` + FunnelActivitiesQ2 string `json:"funnelActivitiesQ2"` +} + +func (up *UserProfileController) CreateOnboardingResponse(c echo.Context) error { + var user model.User + var onboardingResponse OnboardingResponse + var response []byte + userID := c.Param("uid") + + // Check if the user exists + err := up.DB.First(&user, userID).Error + if err != nil { + return c.JSON(http.StatusNotFound, "User not found") + } + + // Check if a user profile already exists for the user + var existingProfile model.UserProfile + err = up.DB.Where("user_id = ?", user.ID).First(&existingProfile).Error + if err != nil { + return c.JSON(http.StatusNotFound, "User profile not found") + } + + if err := c.Bind(&onboardingResponse); err != nil { + return c.JSON(http.StatusBadRequest, map[string]string{"error": err.Error()}) + } + + // Associate the profile with the user + response, err = json.Marshal(onboardingResponse) + if err != nil { + return c.JSON(http.StatusBadRequest, map[string]string{"error": err.Error()}) + } + + existingProfile.OnboardingResponse = string(response) + + // Validate the user profile data before creating + validator := validator.New() + + if err := validator.Struct(existingProfile); err != nil { + return c.JSON(http.StatusBadRequest, map[string]string{"error": err.Error()}) + } + + // Create the user profile + result := up.DB.Save(&existingProfile) + if result.Error != nil { + return handleError(c, http.StatusBadRequest, result.Error.Error()) + } + + return c.JSON(http.StatusCreated, existingProfile) +} + func (up *UserProfileController) DeleteUserProfile(c echo.Context) error { var userprofile model.UserProfile userprofileID := c.Param("upid") diff --git a/server/src/model/file.go b/server/src/model/file.go index 6358110..e419c3d 100644 --- a/server/src/model/file.go +++ b/server/src/model/file.go @@ -8,5 +8,5 @@ type File struct { FileDescription string `gorm:"type:text" json:"file_description"` FilePath string `gorm:"type:varchar(255)" json:"file_path"` UserID uint `json:"user_id"` - User User `gorm:"foreignkey:UserID"` + User User `gorm:"foreignkey:UserID" json:"-"` } diff --git a/server/src/model/persona.go b/server/src/model/persona.go index 95dea3e..ba7d5ba 100644 --- a/server/src/model/persona.go +++ b/server/src/model/persona.go @@ -6,5 +6,5 @@ type Persona struct { gorm.Model PersonaDescription string `gorm:"type:text" json:"persona_description"` PersonaTitle string `gorm:"type:varchar(255)" json:"persona_title"` - Tasks []Task `gorm:"many2many:persona_tasks;"` + Tasks []Task `gorm:"many2many:persona_tasks;" json:"-"` } diff --git a/server/src/model/subtask.go b/server/src/model/subtask.go index 990e73d..47d5ece 100644 --- a/server/src/model/subtask.go +++ b/server/src/model/subtask.go @@ -9,5 +9,5 @@ type SubTask struct { TaskName string `gorm:"type:varchar(255)" json:"task_name"` TaskDescription string `gorm:"type:text" json:"task_description"` TaskID uint `json:"task_id"` - Task Task `gorm:"foreignkey:TaskID"` + Task Task `gorm:"foreignkey:TaskID" json:"-"` } diff --git a/server/src/model/subtask_progress.go b/server/src/model/subtask_progress.go index aa0fdef..670eb26 100644 --- a/server/src/model/subtask_progress.go +++ b/server/src/model/subtask_progress.go @@ -7,6 +7,6 @@ type SubTaskProgress struct { Completed bool `json:"completed"` UserID int `json:"user_id"` SubTaskID int `json:"subtask_id"` - User User `gorm:"foreignkey:UserID"` - SubTask SubTask `gorm:"foreignkey:SubTaskID"` + User User `gorm:"foreignkey:UserID" json:"-"` + SubTask SubTask `gorm:"foreignkey:SubTaskID" json:"-"` } diff --git a/server/src/model/task_progress.go b/server/src/model/task_progress.go index b017911..b57e6fd 100644 --- a/server/src/model/task_progress.go +++ b/server/src/model/task_progress.go @@ -7,6 +7,6 @@ type TaskProgress struct { Completed bool `json:"completed"` UserID uint `json:"user_id"` TaskID uint `json:"task_id"` - User User `gorm:"foreignkey:UserID"` - Task Task `gorm:"foreignkey:TaskID"` + User User `gorm:"foreignkey:UserID" json:"-"` + Task Task `gorm:"foreignkey:TaskID" json:"-"` } diff --git a/server/src/model/user.go b/server/src/model/user.go index 01d9543..2ef8c34 100644 --- a/server/src/model/user.go +++ b/server/src/model/user.go @@ -6,9 +6,10 @@ import ( type User struct { gorm.Model - Username string `gorm:"type:varchar(255);unique" json:"username"` - Password string `gorm:"type:text" json:"password"` - Email string `gorm:"type:varchar(255);unique" json:"email"` - PersonaID uint `json:"persona_id"` - Persona Persona `gorm:"foreignkey:PersonaID" json:"persona"` + Username string `gorm:"type:varchar(255);unique" json:"username"` + FirebaseID string `gorm:"type:varchar(255);unique" json:"firebase_id"` + Password string `gorm:"type:text" json:"password"` + Email string `gorm:"type:varchar(255);unique" json:"email"` + PersonaID uint `json:"persona_id"` + Persona Persona `gorm:"foreignkey:PersonaID" json:"persona"` } diff --git a/server/src/model/user_profile.go b/server/src/model/user_profile.go index c483e10..f2b74e3 100644 --- a/server/src/model/user_profile.go +++ b/server/src/model/user_profile.go @@ -8,10 +8,10 @@ import ( type UserProfile struct { gorm.Model - Name string `gorm:"type:varchar(255)" json:"name"` - DateOfBirth time.Time `gorm:"type:date" json:"date_of_birth"` - PhoneNumber string `gorm:"type:varchar(20)" json:"phone_number"` - Response string `gorm:"type:jsonb;default:'{}'" json:"response"` - UserID uint `gorm:"foreignkey:User;unique" json:"user_id"` - User User + Name string `gorm:"type:varchar(255)" json:"name"` + DateOfBirth time.Time `gorm:"type:date" json:"date_of_birth"` + PhoneNumber string `gorm:"type:varchar(20)" json:"phone_number"` + OnboardingResponse string `gorm:"type:jsonb;default:'{}'" json:"response"` + UserID uint `gorm:"foreignkey:User;unique" json:"user_id"` + User User `json:"-"` } diff --git a/yarn.lock b/yarn.lock new file mode 100644 index 0000000..fb57ccd --- /dev/null +++ b/yarn.lock @@ -0,0 +1,4 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + +