From c4bf6d484d71ea3f19dfdf0bbafba4596bd404f0 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 25 Sep 2023 15:45:19 -0400 Subject: [PATCH 01/12] Create README.md --- design-files/README.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 design-files/README.md diff --git a/design-files/README.md b/design-files/README.md new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/design-files/README.md @@ -0,0 +1 @@ + From 638da540232a049352f10619297524738d2bcb3c Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 25 Sep 2023 15:46:01 -0400 Subject: [PATCH 02/12] Wireframe of user profile page --- design-files/User-Profile.png | Bin 0 -> 23445 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 design-files/User-Profile.png diff --git a/design-files/User-Profile.png b/design-files/User-Profile.png new file mode 100644 index 0000000000000000000000000000000000000000..b1a60d129abfaacff58bd4f17216d905c4ce08e3 GIT binary patch literal 23445 zcmeFZ2UJt*w=cR-w_VwY(u*6miV7mVlc+QWLzHnZB&rYtL z2!iZ6tD$lUL4MOfkj+usx5ANw78(KYwd1D7H8%v=#ftu8LK2>Fz(FRrOX{bQycQl3 z{McfBO8XRo6h!V?zy2G77#=&Ta!SvO>Bo?1*wcxmuheZ1x8F&h4QrB2?Q?IQwG-2D zN)vm}uDMcok>}BS_FiTA(D~-C@9X8b`Xby9wy0Ldhq+z9V=eVQM7n;y*X_inoQSY% zM}NOA_e#)1!ur78>d9r6d+m883fDe|rD_*)IUFwh=p7(xT&3E%$9TxN`|{l4nnwCm zw$F6#)Qir0`FPB6%5t@jAQLndxiOi%1^s?>^!9%A`%?@S?LBfs^B^=GLEapCvgi_ZfNedBLahZAAWPL2y=nLjZ138bRCzU@%iYO#R`W z(i6+~GWU4?^eOkFEyj_VLITH1UO3OalG%qK z(Z9cUowz&Q$WiWLk-Pgv(vQKqdGUl80_)Wb^%t8EY{hn%L1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DJY^qQc=J*i0GD= zkZdw^OMS({JiAcu#~#XOInw9N>LH;@N~_Vt8h2t7Da&JK#GTMzXRByzyyG#>!sZ?^ zm#} zKm`{Y*5JC_yR!J<&4T7d*N@hXyM&B=X5z$iiz}RHdh^v|(o8N*-&(lY(+si+6TBL} z1R#6@>u;cM5aRb`1l*!f{@V^s&a^qo@BXYzd3y_{{@4-pckAX$>&|9({eHiz zG*HzbE+R?(`%%{ZU%NJJf6@N(_UybDU%%hzH~uEmTkHGS^zo|i-`B-Q#Z>N_mURBg z429mk-j6>YEqs6L&(B2r{c|StK9Ju2`0Jw`&Xujdm2~p01NPMAxC+c)88^RN;r#pz zFJM?M(>%MDe=aaoW1fAG-#;(*@5d+X&2O|Crt{O!uOxLP}4 zyZA7uVCQ-8aq;J%>-p6GmmjUNwq~-w&9D|M-N_T(Qck6CVciE*^mk%shYkFUO|4 z1hp;iSv>6;Go;0Tz+g-HSpiSUAW8Sfzk$PYM?l9B@dUf9zx^+})7JB4c#VFZ^$r(c z<7Gwy$VS1A)XV1Y;$J4ymaT+1>i!}10A5c?_GS6&Dwp> zLb7I7noXR}vAADu?sPe8qx08*SyK4M6`-;eN47lJ`~P;(oj72%`75b7J<9O+byo{f zANBbWPW5X()!(~Unp*YGCAjM2-AG_Sc7o=RRy1{_HUYbnJ~rQgJRlf7m1w|QX1{dr Yq_M@$kF^2rIACD#boFyt=akR{0QegZO#lD@ literal 0 HcmV?d00001 From c8770de86aa76eb8ed0ad2de437c8addbd6b4815 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 14:54:08 -0400 Subject: [PATCH 03/12] Update Register.tsx --- client/src/components/pages/Register.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/src/components/pages/Register.tsx b/client/src/components/pages/Register.tsx index a3e1c1a..4a975ea 100644 --- a/client/src/components/pages/Register.tsx +++ b/client/src/components/pages/Register.tsx @@ -11,7 +11,8 @@ import { Heading, Box, VStack, -} from "@chakra-ui/react"; +} +from "@chakra-ui/react"; import { useState } from "react"; import { RegisterBody } from "../../types"; import { registerBodySchema } from "../../schemas"; From 4bac53aa816fef6bebdc83c519ebaed717ab6816 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 14:54:14 -0400 Subject: [PATCH 04/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 2fcee40..330da81 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -1,3 +1,23 @@ +import { + FormControl, + FormLabel, + Input, + Radio, + RadioGroup, + Stack, + Select, + Button, + ButtonGroup, + Heading, + Box, + VStack, +} +from "@chakra-ui/react"; +import { useState } from "react"; +import { UserCredientials } from "../../types"; +import { userCredentialsSchema } from "../../schemas"; + + const Login = () => { return
Login
; }; From 7defa771379965e8d13c5db58e7dc461be9a3bb2 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:04:43 -0400 Subject: [PATCH 05/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 330da81..a017c00 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -19,7 +19,9 @@ import { userCredentialsSchema } from "../../schemas"; const Login = () => { - return
Login
; + const [loginBody, setLoginBody] = useState({ + username: "", + password: "" + }); }; - export default Login; From 4bbfce33622935e833058db992be359f3f84f6d0 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:21:50 -0400 Subject: [PATCH 06/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index a017c00..59625ce 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -17,11 +17,34 @@ import { useState } from "react"; import { UserCredientials } from "../../types"; import { userCredentialsSchema } from "../../schemas"; +type Action = { type: 'loginSuccess', payload: string } +| { type: 'loginFailed', payload: string }; const Login = () => { const [loginBody, setLoginBody] = useState({ username: "", password: "" }); + + const handleLogin = () => { + const parsedLoginBody = userCredentialsSchema.safeParse(UserCredientials); + if (!parsedLoginBody.success) { + alert("Login import failed!"); + return; + } + + if (loginBody.username !== '' && loginBody.password !== '') { + dispatch({ + type: 'loginSuccess', + payload: 'Login Successfully' + }); + } + else { + dispatch({ + type: 'loginFailed', + payload: 'Incorrect username or password' + }); + } + } }; export default Login; From 7617239a18c6e2ae756f10837cd6d3fb6b164ac8 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:28:07 -0400 Subject: [PATCH 07/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 59625ce..668b0a6 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -32,19 +32,15 @@ const Login = () => { alert("Login import failed!"); return; } - - if (loginBody.username !== '' && loginBody.password !== '') { - dispatch({ - type: 'loginSuccess', - payload: 'Login Successfully' - }); - } - else { - dispatch({ - type: 'loginFailed', - payload: 'Incorrect username or password' - }); + if (loginBody.username == '' || loginBody.password !== '') { + alert("Login failed!"); + return; } + alert(JSON.stringify(parsedLoginBody.data)); } + + return ( + + ); }; export default Login; From 1b158f9d940ee712a77d79fc4c00c053d7437a60 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:38:58 -0400 Subject: [PATCH 08/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 31 ++++++++++++++++++++++++--- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 668b0a6..4f997c2 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -32,15 +32,40 @@ const Login = () => { alert("Login import failed!"); return; } - if (loginBody.username == '' || loginBody.password !== '') { - alert("Login failed!"); + if (loginBody.username == '' || loginBody.password == '') { + alert("Please enter a username and password!"); return; } alert(JSON.stringify(parsedLoginBody.data)); } return ( - + + + Login + + Username + setLoginBody({ ...loginBody, username: event.target.value })} + /> + + + Password + setLoginBody({ ...loginBody, password: event.target.value })} + /> + + + + + + ); }; export default Login; From e531fcc7c2c94d377cd7498b053bba9246c4c561 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:39:26 -0400 Subject: [PATCH 09/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 3 --- 1 file changed, 3 deletions(-) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 4f997c2..6051592 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -17,9 +17,6 @@ import { useState } from "react"; import { UserCredientials } from "../../types"; import { userCredentialsSchema } from "../../schemas"; -type Action = { type: 'loginSuccess', payload: string } -| { type: 'loginFailed', payload: string }; - const Login = () => { const [loginBody, setLoginBody] = useState({ username: "", From 444956e0b5b58a6a86e0614a8de290214dab3578 Mon Sep 17 00:00:00 2001 From: Jocelyn <28810573+Noodulz@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:47:07 -0400 Subject: [PATCH 10/12] Update Login.tsx --- client/src/components/pages/Login.tsx | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/client/src/components/pages/Login.tsx b/client/src/components/pages/Login.tsx index 6051592..6732299 100644 --- a/client/src/components/pages/Login.tsx +++ b/client/src/components/pages/Login.tsx @@ -2,15 +2,10 @@ import { FormControl, FormLabel, Input, - Radio, - RadioGroup, - Stack, - Select, Button, - ButtonGroup, Heading, Box, - VStack, + VStack } from "@chakra-ui/react"; import { useState } from "react"; From 3d32f7cfc121b64bd014921bb8d217b629b9e959 Mon Sep 17 00:00:00 2001 From: noodulz <28810573+Noodulz@users.noreply.github.com> Date: Mon, 23 Oct 2023 15:45:34 -0400 Subject: [PATCH 11/12] Added select boxes and implemented search query to backend --- client/src/components/Search.tsx | 60 +++++++++++++++++++++++++++----- client/src/types.ts | 7 ++++ 2 files changed, 58 insertions(+), 9 deletions(-) diff --git a/client/src/components/Search.tsx b/client/src/components/Search.tsx index efba51b..57baa6d 100644 --- a/client/src/components/Search.tsx +++ b/client/src/components/Search.tsx @@ -1,4 +1,4 @@ -import { Box, HStack, FormControl, FormLabel, Input, Button } from "@chakra-ui/react"; +import { Box, HStack, FormControl, FormLabel, Button, Select } from "@chakra-ui/react"; import { useState } from "react"; import UserCard from "./UserCard"; @@ -7,32 +7,74 @@ export default function Search() { const [cleanliness, setCleanliness] = useState(""); const [loudness, setLoudness] = useState(""); const [coed, setCoed] = useState(""); - + const [searchLoading, setSearchLoading] = useState(false); + const handleSearch = async () => { + const query = `?budget=${budget}&cleanliness=${cleanliness}&loudness=${loudness}&coEd=${coed}`; + try { + const response = await fetch(`${import.meta.env.VITE_BACKEND_URL}/search${query}`); + const data = await response.json(); + console.log(data); + } catch (error) { + console.error("Error fetching search results:", error); + } + }; return ( Budget - setBudget(event.target.value)} /> + Cleanliness - setCleanliness(event.target.value)} - /> + > + + + + Loudness - setLoudness(event.target.value)} /> + Co-Ed - setCoed(event.target.value)} /> + - diff --git a/client/src/types.ts b/client/src/types.ts index e2208a6..0cf4d3d 100644 --- a/client/src/types.ts +++ b/client/src/types.ts @@ -21,4 +21,11 @@ export interface UserCredentials { password: string; } +export interface SearchBody { + budget: number; + cleanliness: string; + loudness: string; + coed: string; +} + export type RegisterBody = UserCredentials & UserProfile; From 69f4169700cba467347d3d073ddc949ccdd102c5 Mon Sep 17 00:00:00 2001 From: noodulz <28810573+Noodulz@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:45:51 -0400 Subject: [PATCH 12/12] Applied search schema and mapped out search results --- client/src/components/Search.tsx | 11 +++++++++-- client/src/components/UserCard.tsx | 15 +++++++++------ client/src/schemas.ts | 24 ++++++++++++++---------- 3 files changed, 32 insertions(+), 18 deletions(-) diff --git a/client/src/components/Search.tsx b/client/src/components/Search.tsx index 57baa6d..e120db5 100644 --- a/client/src/components/Search.tsx +++ b/client/src/components/Search.tsx @@ -1,23 +1,30 @@ import { Box, HStack, FormControl, FormLabel, Button, Select } from "@chakra-ui/react"; import { useState } from "react"; import UserCard from "./UserCard"; +import { UserProfile } from "../types"; +import { searchResultSchema } from "../schemas"; export default function Search() { + const [results, setResults] = useState([]); const [budget, setBudget] = useState(""); const [cleanliness, setCleanliness] = useState(""); const [loudness, setLoudness] = useState(""); const [coed, setCoed] = useState(""); const [searchLoading, setSearchLoading] = useState(false); + const handleSearch = async () => { const query = `?budget=${budget}&cleanliness=${cleanliness}&loudness=${loudness}&coEd=${coed}`; try { const response = await fetch(`${import.meta.env.VITE_BACKEND_URL}/search${query}`); const data = await response.json(); + const dataResults = searchResultSchema.parse(data); + setResults(dataResults); console.log(data); } catch (error) { console.error("Error fetching search results:", error); } }; + return ( @@ -69,7 +76,7 @@ export default function Search() { colorScheme="orange" width="100%" borderRadius="6px" - onClick={() => { + onClick={async () => { setSearchLoading(true); handleSearch().then(() => setSearchLoading(false)); }} @@ -79,7 +86,7 @@ export default function Search() { - + {results.map(result => )} ); } diff --git a/client/src/components/UserCard.tsx b/client/src/components/UserCard.tsx index 946281e..9339e1c 100644 --- a/client/src/components/UserCard.tsx +++ b/client/src/components/UserCard.tsx @@ -1,6 +1,7 @@ import { Card, Image, Stack, CardBody, Heading, Text, Box, Button } from "@chakra-ui/react"; +import { UserProfile } from "../types"; -export default function UserCard() { +export default function UserCard(props: {profile: UserProfile}) { return ( Caffe Latte @@ -22,9 +23,11 @@ export default function UserCard() { First Name Last Name - Gender: - About: - Preferences: + Gender: {props.profile.gender} + Budget: {props.profile.budget} + Loudness: {props.profile.loudness} + Cleanliness: {props.profile.cleanliness} + Co-Ed: {props.profile.cleanliness} diff --git a/client/src/schemas.ts b/client/src/schemas.ts index f7834da..3bbe1e2 100644 --- a/client/src/schemas.ts +++ b/client/src/schemas.ts @@ -4,18 +4,22 @@ export const apiErrorSchema = z.object({ errorMessage: z.string(), }); -export const userProfileSchema = z - .object({ - profilePic: z.string().optional(), - displayName: z.string().min(1), - budget: z.literal(1).or(z.literal(2)).or(z.literal(3)).or(z.literal(4)), - gender: z.string().min(1), - cleanliness: z.literal(1).or(z.literal(2)).or(z.literal(3)), - loudness: z.literal(1).or(z.literal(2)).or(z.literal(3)), - coed: z.boolean(), - }) +const userProfileBodySchema = z +.object({ + profilePic: z.string().optional(), + budget: z.literal(1).or(z.literal(2)).or(z.literal(3)).or(z.literal(4)), + cleanliness: z.literal(1).or(z.literal(2)).or(z.literal(3)), + coed: z.boolean(), + displayName: z.string().min(1), + gender: z.string().min(1), + loudness: z.literal(1).or(z.literal(2)).or(z.literal(3)), +}); + +export const userProfileSchema = userProfileBodySchema .or(apiErrorSchema); +export const searchResultSchema = z.array(userProfileBodySchema); + export const tokenMessageSchema = z.object({ token: z.string(), });