analytica-frontend-lib 1.2.69 → 1.2.71
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/dist/ActivityCardQuestionBanks/index.js +8 -2
- package/dist/ActivityCardQuestionBanks/index.js.map +1 -1
- package/dist/ActivityCardQuestionBanks/index.mjs +8 -2
- package/dist/ActivityCardQuestionBanks/index.mjs.map +1 -1
- package/dist/ActivityCardQuestionPreview/index.js +8 -2
- package/dist/ActivityCardQuestionPreview/index.js.map +1 -1
- package/dist/ActivityCardQuestionPreview/index.mjs +8 -2
- package/dist/ActivityCardQuestionPreview/index.mjs.map +1 -1
- package/dist/ActivityDetails/index.d.ts +1 -1
- package/dist/ActivityDetails/index.d.ts.map +1 -1
- package/dist/ActivityDetails/index.js +55 -8
- package/dist/ActivityDetails/index.js.map +1 -1
- package/dist/ActivityDetails/index.mjs +55 -8
- package/dist/ActivityDetails/index.mjs.map +1 -1
- package/dist/ActivityPreview/index.js +8 -2
- package/dist/ActivityPreview/index.js.map +1 -1
- package/dist/ActivityPreview/index.mjs +8 -2
- package/dist/ActivityPreview/index.mjs.map +1 -1
- package/dist/CorrectActivityModal/index.js +54 -3
- package/dist/CorrectActivityModal/index.js.map +1 -1
- package/dist/CorrectActivityModal/index.mjs +54 -3
- package/dist/CorrectActivityModal/index.mjs.map +1 -1
- package/dist/index.js +55 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +55 -8
- package/dist/index.mjs.map +1 -1
- package/dist/utils/questionRenderer/alternative/index.d.ts.map +1 -1
- package/dist/utils/questionRenderer/multipleChoice/index.d.ts.map +1 -1
- package/dist/utils/studentActivityCorrection/utils.d.ts +14 -0
- package/dist/utils/studentActivityCorrection/utils.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -3472,12 +3472,15 @@ var renderQuestionAlternative = ({
|
|
|
3472
3472
|
question,
|
|
3473
3473
|
result
|
|
3474
3474
|
}) => {
|
|
3475
|
+
const hasAutoValidation = result?.options?.some(
|
|
3476
|
+
(op) => op.isCorrect !== void 0 && op.isCorrect !== null
|
|
3477
|
+
);
|
|
3475
3478
|
const alternatives = question.options?.map((option) => {
|
|
3476
3479
|
const isCorrectOption = result?.options?.find((op) => op.id === option.id)?.isCorrect || false;
|
|
3477
3480
|
const isSelected = result?.selectedOptions?.some(
|
|
3478
3481
|
(selectedOption) => selectedOption.optionId === option.id
|
|
3479
3482
|
) || false;
|
|
3480
|
-
const shouldShowCorrectAnswers = result?.answerStatus !== "PENDENTE_AVALIACAO" /* PENDENTE_AVALIACAO
|
|
3483
|
+
const shouldShowCorrectAnswers = result?.answerStatus !== "PENDENTE_AVALIACAO" /* PENDENTE_AVALIACAO */ || hasAutoValidation;
|
|
3481
3484
|
let status;
|
|
3482
3485
|
if (shouldShowCorrectAnswers) {
|
|
3483
3486
|
if (isCorrectOption) {
|
|
@@ -3651,12 +3654,15 @@ var renderQuestionMultipleChoice = ({
|
|
|
3651
3654
|
question,
|
|
3652
3655
|
result
|
|
3653
3656
|
}) => {
|
|
3657
|
+
const hasAutoValidation = result?.options?.some(
|
|
3658
|
+
(op) => op.isCorrect !== void 0 && op.isCorrect !== null
|
|
3659
|
+
);
|
|
3654
3660
|
const choices = question.options?.map((option) => {
|
|
3655
3661
|
const isCorrectOption = result?.options?.find((op) => op.id === option.id)?.isCorrect || false;
|
|
3656
3662
|
const isSelected = result?.selectedOptions?.some(
|
|
3657
3663
|
(op) => op.optionId === option.id
|
|
3658
3664
|
);
|
|
3659
|
-
const shouldShowCorrectAnswers = result?.answerStatus !== "PENDENTE_AVALIACAO" /* PENDENTE_AVALIACAO */ && result?.answerStatus !== "NAO_RESPONDIDO" /* NAO_RESPONDIDO
|
|
3665
|
+
const shouldShowCorrectAnswers = result?.answerStatus !== "PENDENTE_AVALIACAO" /* PENDENTE_AVALIACAO */ && result?.answerStatus !== "NAO_RESPONDIDO" /* NAO_RESPONDIDO */ || hasAutoValidation;
|
|
3660
3666
|
let status;
|
|
3661
3667
|
if (shouldShowCorrectAnswers) {
|
|
3662
3668
|
if (isCorrectOption) {
|