From df3d10f4616eab47103d27899619f4424d301349 Mon Sep 17 00:00:00 2001 From: Shaina Date: Mon, 7 Apr 2025 10:57:35 -0400 Subject: [PATCH 01/25] added outline for progress bar --- src/Pages/BasicQuestions.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index 98b0837..e6bfdf0 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -27,7 +27,12 @@ export function BasicQuestions(): React.JSX.Element{ const [answer1, setAnswer1] = useState(Q1ANSWER[0]); const [answer2, setAnswer2] = useState(Q2ANSWER[0]); const [answer3, setAnswer3] = useState(Q3ANSWER[0]); - + const [progress,setProgress]=useState(0) + let sum =0; + function UpdateProgress(){ + sum+=1; + setProgress(sum); + } return( @@ -78,12 +83,13 @@ export function BasicQuestions(): React.JSX.Element{ value={ananswer3} label={ananswer3} onChange={(e) => { - setAnswer3(e.target.value); + UpdateProgress(); }} checked={answer3 === ananswer3} /> ))} + ) From 1a7cb3de57e190618fddb138bac65a45eb847618 Mon Sep 17 00:00:00 2001 From: Axel Rodriguez-Leon Date: Mon, 7 Apr 2025 11:05:57 -0400 Subject: [PATCH 02/25] Fixed issue with Detailed Questions page not displaying --- src/App.tsx | 2 +- src/Pages/BasicQuestions.tsx | 4 ++-- src/Pages/DetailedQuestions.tsx | 2 +- src/Pages/Pages.css | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index 3f0a78f..84a029e 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -54,10 +54,10 @@ function App() { - - + Date: Tue, 15 Apr 2025 18:18:09 -0400 Subject: [PATCH 15/25] removed uneccessary css file --- src/Pages/BasicQuestions.css | 3 --- src/Pages/DetailedQuestions.tsx | 2 +- src/Pages/Pages.css | 4 +++- 3 files changed, 4 insertions(+), 5 deletions(-) delete mode 100644 src/Pages/BasicQuestions.css diff --git a/src/Pages/BasicQuestions.css b/src/Pages/BasicQuestions.css deleted file mode 100644 index 97bd9c3..0000000 --- a/src/Pages/BasicQuestions.css +++ /dev/null @@ -1,3 +0,0 @@ -.Ready{ - color: white; -} \ No newline at end of file diff --git a/src/Pages/DetailedQuestions.tsx b/src/Pages/DetailedQuestions.tsx index 71706fc..54e6336 100644 --- a/src/Pages/DetailedQuestions.tsx +++ b/src/Pages/DetailedQuestions.tsx @@ -94,7 +94,7 @@ export function DetailedQuestions(): React.JSX.Element{ - + {response.q5.length} Characters diff --git a/src/Pages/Pages.css b/src/Pages/Pages.css index 0ad69c0..750079f 100644 --- a/src/Pages/Pages.css +++ b/src/Pages/Pages.css @@ -5,7 +5,9 @@ padding: 15px; top: 67%; } - +.Ready{ + color: white; +} .Detailed-Question{ text-align: center; } From dc44d4910f57429e6b7222c16fc00fde78caa97b Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 18:21:55 -0400 Subject: [PATCH 16/25] fixed function error --- src/Pages/BasicQuestions.tsx | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index 9e6eedd..b82489e 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -145,6 +145,3 @@ export function BasicQuestions(): React.JSX.Element{ ) } -function UpdateProgress() { - throw new Error('Function not implemented.'); -} From bd66b1976b5de266f36ee775a543508c8692b4c6 Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 18:23:59 -0400 Subject: [PATCH 17/25] fixed color of basic question title --- src/Pages/BasicQuestions.tsx | 2 +- src/Pages/Pages.css | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index b82489e..611f0ee 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -45,7 +45,7 @@ export function BasicQuestions(): React.JSX.Element{
-
Basic Quiz
+
Basic Quiz

1. I would like to develop new medicine

{QTYPEAANSWER.map((ananswer) => ( diff --git a/src/Pages/Pages.css b/src/Pages/Pages.css index 750079f..a0f90b5 100644 --- a/src/Pages/Pages.css +++ b/src/Pages/Pages.css @@ -5,6 +5,9 @@ padding: 15px; top: 67%; } +.Basic-Title{ + color:white +} .Ready{ color: white; } From def48cd9282d1cea154cf3a42cef98d29b8940a2 Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 18:43:50 -0400 Subject: [PATCH 18/25] potentially fixing action/cache error? --- package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index d2189d1..d21c919 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,8 @@ "react-dom": "^18.2.0", "react-scripts": "5.0.1", "typescript": "^4.9.5", - "web-vitals": "^2.1.4" + "web-vitals": "^2.1.4", + "@actions/cache": "^4.0.0" }, "scripts": { "start": "react-scripts start", From 15b11f6bfca1008615db76bb377ffd1313dc227f Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 18:45:23 -0400 Subject: [PATCH 19/25] reverting fix --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/package.json b/package.json index d21c919..d2189d1 100644 --- a/package.json +++ b/package.json @@ -18,8 +18,7 @@ "react-dom": "^18.2.0", "react-scripts": "5.0.1", "typescript": "^4.9.5", - "web-vitals": "^2.1.4", - "@actions/cache": "^4.0.0" + "web-vitals": "^2.1.4" }, "scripts": { "start": "react-scripts start", From bd91d4f17d48539949174ed634eaaa4d4c91a0fa Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 18:59:57 -0400 Subject: [PATCH 20/25] potientally fixing deployment error? --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 78b5428..6536a58 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,7 +19,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: "npm" From ce35ff810c845d8715d0ec3956fef4327a9a210a Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 19:04:59 -0400 Subject: [PATCH 21/25] fixing linting errors --- src/Pages/BasicQuestions.tsx | 29 +++++------------------------ 1 file changed, 5 insertions(+), 24 deletions(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index 611f0ee..0918a1e 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -10,26 +10,7 @@ const QTYPEAANSWER = [ "Strongly agree" ] -const Q5ANSWER = [ - "Choice A", - "Choice B", - "Choice C", - "Choice D" -] - -const Q6ANSWER = [ - "Choice A", - "Choice B", - "Choice C", - "Choice D" -] -const Q7ANSWER = [ - "Choice A", - "Choice B", - "Choice C", - "Choice D" -] export function BasicQuestions(): React.JSX.Element{ const [answer1, setAnswer1] = useState(QTYPEAANSWER[0]); const [answer2, setAnswer2] = useState(QTYPEAANSWER[0]); @@ -60,7 +41,7 @@ export function BasicQuestions(): React.JSX.Element{ setAnswer1(e.target.value); UpdateProgress(); }} - //checked={answer1 === ananswer} + //checked={answer1 !== ananswer} /> ))} @@ -78,7 +59,7 @@ export function BasicQuestions(): React.JSX.Element{ setAnswer2(e.target.value); UpdateProgress(); }} - //checked={answer2 === ananswer2} + //checked={answer2 !== ananswer2} /> ))} @@ -97,7 +78,7 @@ export function BasicQuestions(): React.JSX.Element{ ); UpdateProgress(); }} - //checked={answer3 === ananswer3} + //checked={answer3 !== ananswer3} /> ))} @@ -115,7 +96,7 @@ export function BasicQuestions(): React.JSX.Element{ setAnswer4(e.target.value); UpdateProgress(); }} - //checked={answer4 === ananswer4} + //checked={answer4 !== ananswer4} /> ))} @@ -133,7 +114,7 @@ export function BasicQuestions(): React.JSX.Element{ setAnswer5(e.target.value); UpdateProgress(); }} - //checked={answer5 === ananswer5} + //checked={answer5 !== ananswer5} /> ))} From 2d82d8c39cd06948d18b6b7737f042f659079e7f Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 19:09:42 -0400 Subject: [PATCH 22/25] fixing linting errors --- src/Pages/BasicQuestions.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index 0918a1e..f19a098 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -35,7 +35,7 @@ export function BasicQuestions(): React.JSX.Element{ type={"radio"} name={"response1"} key={ananswer} - value={ananswer} + value={answer1} label={ananswer} onChange={(e) => { setAnswer1(e.target.value); @@ -53,7 +53,7 @@ export function BasicQuestions(): React.JSX.Element{ type={"radio"} name={"response2"} key={ananswer2} - value={ananswer2} + value={answer2} label={ananswer2} onChange={(e) => { setAnswer2(e.target.value); @@ -71,7 +71,7 @@ export function BasicQuestions(): React.JSX.Element{ type={"radio"} name={"response3"} key={ananswer3} - value={ananswer3} + value={answer3} label={ananswer3} onChange={(e) => { setAnswer3(e.target.value @@ -90,7 +90,7 @@ export function BasicQuestions(): React.JSX.Element{ type={"radio"} name={"response4"} key={ananswer4} - value={ananswer4} + value={answer4} label={ananswer4} onChange={(e) => { setAnswer4(e.target.value); @@ -108,7 +108,7 @@ export function BasicQuestions(): React.JSX.Element{ type={"radio"} name={"response5"} key={ananswer5} - value={ananswer5} + value={answer5} label={ananswer5} onChange={(e) => { setAnswer5(e.target.value); From c51c67b33b11aad8d1f989ecbe8661b74a37202d Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 19:12:53 -0400 Subject: [PATCH 23/25] fixing warnings --- src/Pages/Pages.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Pages/Pages.css b/src/Pages/Pages.css index a0f90b5..ebce20f 100644 --- a/src/Pages/Pages.css +++ b/src/Pages/Pages.css @@ -23,7 +23,7 @@ display: flex; flex-direction: column; align-items: center; - justify-content: start; + justify-content: flex-start; min-height: 10vh; top: 40%; } From 9f9db19176c0ad35168c7ce96eea1b92dcecb106 Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 19:39:49 -0400 Subject: [PATCH 24/25] fixing deployment issues --- src/Pages/BasicQuestions.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index f19a098..657030f 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -78,7 +78,7 @@ export function BasicQuestions(): React.JSX.Element{ ); UpdateProgress(); }} - //checked={answer3 !== ananswer3} + ///checked={answer3 !== ananswer3} /> ))} From caa27214ecec0e74aca3d662266b11e369fa9cff Mon Sep 17 00:00:00 2001 From: Shaina Date: Tue, 15 Apr 2025 20:02:41 -0400 Subject: [PATCH 25/25] fixing deployment issues --- src/Pages/BasicQuestions.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Pages/BasicQuestions.tsx b/src/Pages/BasicQuestions.tsx index 657030f..f19a098 100644 --- a/src/Pages/BasicQuestions.tsx +++ b/src/Pages/BasicQuestions.tsx @@ -78,7 +78,7 @@ export function BasicQuestions(): React.JSX.Element{ ); UpdateProgress(); }} - ///checked={answer3 !== ananswer3} + //checked={answer3 !== ananswer3} /> ))}