performanceresultscreens 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -2,12 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
4
4
|
const QuizResult_styles_1 = require("./QuizResult.styles"); // Keep styles file same unless you want to rename it too
|
|
5
|
-
const PreformanceResultScreen = ({ percentage, timeTaken, comparisonText, imgSrc, onLevelUp, onReview, onBackToHomework, }) => {
|
|
5
|
+
const PreformanceResultScreen = ({ percentage, description, timeTaken, comparisonText, imgSrc, onLevelUp, onReview, onBackToHomework, }) => {
|
|
6
6
|
const getContent = () => {
|
|
7
7
|
if (percentage < 60) {
|
|
8
8
|
return {
|
|
9
9
|
title: "Nice effort! ",
|
|
10
|
-
description: "Let's turn this into progress. Review the questions to see where you can improve. Understanding them now will help you ace similar ones later!",
|
|
11
10
|
messageBoxStyle: QuizResult_styles_1.styles.messageBoxImprove,
|
|
12
11
|
primaryButton: "Review questions",
|
|
13
12
|
secondaryButton: "Level Up",
|
|
@@ -17,7 +16,6 @@ const PreformanceResultScreen = ({ percentage, timeTaken, comparisonText, imgSrc
|
|
|
17
16
|
else if (percentage >= 60 && percentage < 80) {
|
|
18
17
|
return {
|
|
19
18
|
title: "Well done!",
|
|
20
|
-
description: "You're really getting the hang of this. You're so close to acing it! Go through the tricky questions once more and you'll have this topic locked in.",
|
|
21
19
|
messageBoxStyle: QuizResult_styles_1.styles.messageBoxGood,
|
|
22
20
|
primaryButton: "Review questions",
|
|
23
21
|
secondaryButton: "Level Up",
|
|
@@ -27,7 +25,6 @@ const PreformanceResultScreen = ({ percentage, timeTaken, comparisonText, imgSrc
|
|
|
27
25
|
else if (percentage >= 80 && percentage < 100) {
|
|
28
26
|
return {
|
|
29
27
|
title: "Fantastic job ! ",
|
|
30
|
-
description: "You have done quite well! A quick look into your practice history will help you remain on the top",
|
|
31
28
|
messageBoxStyle: QuizResult_styles_1.styles.messageBoxGood,
|
|
32
29
|
primaryButton: "Review questions",
|
|
33
30
|
secondaryButton: "Level Up",
|
|
@@ -37,7 +34,6 @@ const PreformanceResultScreen = ({ percentage, timeTaken, comparisonText, imgSrc
|
|
|
37
34
|
else {
|
|
38
35
|
return {
|
|
39
36
|
title: "Outstanding!",
|
|
40
|
-
description: "You've demonstrated excellent understanding! Review the remaining questions to seal your expertise.",
|
|
41
37
|
messageBoxStyle: QuizResult_styles_1.styles.messageBoxBrilliant,
|
|
42
38
|
primaryButton: "Review questions",
|
|
43
39
|
secondaryButton: "Back to homework",
|
|
@@ -49,7 +45,7 @@ const PreformanceResultScreen = ({ percentage, timeTaken, comparisonText, imgSrc
|
|
|
49
45
|
return ((0, jsx_runtime_1.jsx)("div", { style: QuizResult_styles_1.styles.container, children: (0, jsx_runtime_1.jsxs)("div", { style: QuizResult_styles_1.styles.card, children: [(0, jsx_runtime_1.jsx)("div", { style: QuizResult_styles_1.styles.header, children: (0, jsx_runtime_1.jsxs)("div", { style: { ...QuizResult_styles_1.styles.messageBox, ...content.messageBoxStyle }, children: [(0, jsx_runtime_1.jsx)("img", { src: imgSrc, alt: "Resulticon", style: QuizResult_styles_1.styles.icon }), (0, jsx_runtime_1.jsx)("div", { style: {
|
|
50
46
|
...QuizResult_styles_1.styles.title,
|
|
51
47
|
paddingTop: content.showLevelUp ? "43px" : "14px",
|
|
52
|
-
}, children: content.title }), (0, jsx_runtime_1.jsx)("div", { style: QuizResult_styles_1.styles.description, children:
|
|
48
|
+
}, children: content.title }), (0, jsx_runtime_1.jsx)("div", { style: QuizResult_styles_1.styles.description, children: description })] }) }), (0, jsx_runtime_1.jsx)("div", { style: QuizResult_styles_1.styles.separator }), (0, jsx_runtime_1.jsxs)("div", { style: {
|
|
53
49
|
...QuizResult_styles_1.styles.timeSection,
|
|
54
50
|
backgroundColor: content.showLevelUp ? "#FAF9FE" : "#FFF5E6",
|
|
55
51
|
}, children: [(0, jsx_runtime_1.jsxs)("div", { style: comparisonText && comparisonText.trim().length > 0
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreformanceResultScreen.js","sourceRoot":"","sources":["../../../../src/components/Molecules/PerformanceScreen/PreformanceResultScreen.tsx"],"names":[],"mappings":";;;AACA,2DAA6C,CAAC,yDAAyD;
|
|
1
|
+
{"version":3,"file":"PreformanceResultScreen.js","sourceRoot":"","sources":["../../../../src/components/Molecules/PerformanceScreen/PreformanceResultScreen.tsx"],"names":[],"mappings":";;;AACA,2DAA6C,CAAC,yDAAyD;AAavG,MAAM,uBAAuB,GAA2C,CAAC,EACvE,UAAU,EACV,WAAW,EACX,SAAS,EACT,cAAc,EACd,MAAM,EACN,SAAS,EACT,QAAQ,EACR,gBAAgB,GACjB,EAAE,EAAE;IACH,MAAM,UAAU,GAAG,GAAG,EAAE;QACtB,IAAI,UAAU,GAAG,EAAE,EAAE;YACnB,OAAO;gBACL,KAAK,EAAE,eAAe;gBACtB,eAAe,EAAE,0BAAM,CAAC,iBAAiB;gBACzC,aAAa,EAAE,kBAAkB;gBACjC,eAAe,EAAE,UAAU;gBAC3B,WAAW,EAAE,IAAI;aAClB,CAAC;SACH;aAAM,IAAI,UAAU,IAAI,EAAE,IAAI,UAAU,GAAG,EAAE,EAAE;YAC9C,OAAO;gBACL,KAAK,EAAE,YAAY;gBACnB,eAAe,EAAE,0BAAM,CAAC,cAAc;gBACtC,aAAa,EAAE,kBAAkB;gBACjC,eAAe,EAAE,UAAU;gBAC3B,WAAW,EAAE,IAAI;aAClB,CAAC;SACH;aAAM,IAAI,UAAU,IAAI,EAAE,IAAI,UAAU,GAAG,GAAG,EAAE;YAC/C,OAAO;gBACL,KAAK,EAAE,kBAAkB;gBACzB,eAAe,EAAE,0BAAM,CAAC,cAAc;gBACtC,aAAa,EAAE,kBAAkB;gBACjC,eAAe,EAAE,UAAU;gBAC3B,WAAW,EAAE,KAAK;aACnB,CAAC;S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