l-min-components 1.7.1583 → 1.7.1584
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.
package/package.json
CHANGED
|
@@ -8,21 +8,21 @@ import Tabs from "../components/tabs.jsx";
|
|
|
8
8
|
import useReportUtils from "../../hooks/useRreportUtils.jsx";
|
|
9
9
|
// import Response from "../components/response.jsx";
|
|
10
10
|
// import AnalysisButton from "../components/analysisButton.jsx";
|
|
11
|
-
import QuestionDropdown from "../components/questionDropdown.jsx";
|
|
12
|
-
import QuizQuestion from "../components/quizQuestion.jsx";
|
|
11
|
+
// import QuestionDropdown from "../components/questionDropdown.jsx";
|
|
12
|
+
// import QuizQuestion from "../components/quizQuestion.jsx";
|
|
13
13
|
|
|
14
14
|
// import useTranslation from "../../../../hooks/useTranslation.jsx";
|
|
15
15
|
// import wordStore from "../../../../mc/wordStore.json";
|
|
16
16
|
const QuizWritten = ({
|
|
17
|
-
data,
|
|
17
|
+
// data,
|
|
18
18
|
// aiData,
|
|
19
19
|
// setToggle,
|
|
20
20
|
answerData,
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
isPersonal,
|
|
22
|
+
defaultSelected = 1,
|
|
23
23
|
}) => {
|
|
24
24
|
// const { findText } = useTranslation(wordStore);
|
|
25
|
-
|
|
25
|
+
const [selected, setSelected] = useState(defaultSelected);
|
|
26
26
|
// const [analysis, setAnalysis] = useState(null);
|
|
27
27
|
const { quizResponses } = useReportUtils();
|
|
28
28
|
const quizList = quizResponses({
|
|
@@ -34,8 +34,8 @@ const QuizWritten = ({
|
|
|
34
34
|
value: item?.key,
|
|
35
35
|
label: `Reponses ${item?.key}`,
|
|
36
36
|
}));
|
|
37
|
-
|
|
38
|
-
|
|
37
|
+
const selectedResponse =
|
|
38
|
+
quizList?.find((item) => item?.key === selected) || {};
|
|
39
39
|
|
|
40
40
|
// const selectedModel = quizWrittenSelectedModel(selectedResponse, aiData);
|
|
41
41
|
|
|
@@ -68,7 +68,7 @@ const QuizWritten = ({
|
|
|
68
68
|
// </>
|
|
69
69
|
// </QuestionDropdown>
|
|
70
70
|
|
|
71
|
-
//
|
|
71
|
+
// <Response response={selectedResponse?.text} isPersonal={isPersonal} />
|
|
72
72
|
|
|
73
73
|
// <QuestionSectionWithAnalysis>
|
|
74
74
|
// <QuestionSectionAction>
|
|
@@ -93,22 +93,7 @@ const QuizWritten = ({
|
|
|
93
93
|
selected={selected}
|
|
94
94
|
onChange={setSelected}
|
|
95
95
|
/>
|
|
96
|
-
|
|
97
|
-
<QuestionDropdown>
|
|
98
|
-
<>
|
|
99
|
-
<li>
|
|
100
|
-
<h3>{"Instruction"}</h3>
|
|
101
|
-
<p>{data?.question_data?.instruction}</p>
|
|
102
|
-
</li>
|
|
103
|
-
<li>
|
|
104
|
-
<QuizQuestion data={data} />
|
|
105
|
-
</li>
|
|
106
|
-
<li>
|
|
107
|
-
<h3>{"Question"}</h3>
|
|
108
|
-
<p>{data?.question_data?.question_data?.question}</p>
|
|
109
|
-
</li>
|
|
110
|
-
</>
|
|
111
|
-
</QuestionDropdown>
|
|
96
|
+
<Response response={selectedResponse?.text} isPersonal={isPersonal} />
|
|
112
97
|
</QuestionSection>
|
|
113
98
|
</>
|
|
114
99
|
);
|