eat-js-sdk 1.2.3 → 1.2.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.
- package/dist/eat-prompt-builder.mjs +88 -98
- package/package.json +1 -1
|
@@ -5529,7 +5529,7 @@
|
|
|
5529
5529
|
return selectedOptions2.length > 0 && correctAnswerIds2.every((option) => selectedOptions2.includes(option));
|
|
5530
5530
|
};
|
|
5531
5531
|
const isSkipped = () => {
|
|
5532
|
-
return !isPreviewModeInteractive &&
|
|
5532
|
+
return !isPreviewModeInteractive && selectedOptions.length === 0 || isPreviewModeInteractive && interactiveHasAnswered && !selectedOptions.length;
|
|
5533
5533
|
};
|
|
5534
5534
|
if (isFinished) {
|
|
5535
5535
|
const { hasAnswer, answerIds: ansIds, correctAnswerIds: correctAnsIds } = scoringMetadata;
|
|
@@ -5583,12 +5583,9 @@
|
|
|
5583
5583
|
$$invalidate(18, interactiveHasAnswered = true);
|
|
5584
5584
|
$$invalidate(7, resultFeedback = null);
|
|
5585
5585
|
if (correctAnswersLength === selectedOptions.length) {
|
|
5586
|
-
|
|
5587
|
-
()
|
|
5588
|
-
|
|
5589
|
-
},
|
|
5590
|
-
50
|
|
5591
|
-
);
|
|
5586
|
+
tick().then(() => {
|
|
5587
|
+
getFeedback();
|
|
5588
|
+
});
|
|
5592
5589
|
}
|
|
5593
5590
|
}
|
|
5594
5591
|
};
|
|
@@ -5849,14 +5846,14 @@
|
|
|
5849
5846
|
// src/lib/components/prompt/typein/PromptTypeIn.svelte
|
|
5850
5847
|
function get_each_context2(ctx, list, i) {
|
|
5851
5848
|
const child_ctx = ctx.slice();
|
|
5852
|
-
child_ctx[
|
|
5853
|
-
child_ctx[
|
|
5849
|
+
child_ctx[59] = list[i];
|
|
5850
|
+
child_ctx[61] = i;
|
|
5854
5851
|
return child_ctx;
|
|
5855
5852
|
}
|
|
5856
5853
|
function get_each_context_1(ctx, list, i) {
|
|
5857
5854
|
const child_ctx = ctx.slice();
|
|
5858
|
-
child_ctx[
|
|
5859
|
-
child_ctx[
|
|
5855
|
+
child_ctx[62] = list[i];
|
|
5856
|
+
child_ctx[64] = i;
|
|
5860
5857
|
return child_ctx;
|
|
5861
5858
|
}
|
|
5862
5859
|
function create_else_block_3(ctx) {
|
|
@@ -6793,7 +6790,7 @@
|
|
|
6793
6790
|
/*inlineAnswerResult*/
|
|
6794
6791
|
ctx2[15][
|
|
6795
6792
|
/*itemIndex*/
|
|
6796
|
-
ctx2[
|
|
6793
|
+
ctx2[61]
|
|
6797
6794
|
]
|
|
6798
6795
|
)
|
|
6799
6796
|
return 0;
|
|
@@ -6809,7 +6806,7 @@
|
|
|
6809
6806
|
attr(span0, "class", span0_class_value = /*inlineAnswerResult*/
|
|
6810
6807
|
(ctx[15][
|
|
6811
6808
|
/*itemIndex*/
|
|
6812
|
-
ctx[
|
|
6809
|
+
ctx[61]
|
|
6813
6810
|
] ? "text-green-900" : "text-red-900") + " p-0.5");
|
|
6814
6811
|
attr(span1, "class", "w-6 h-6 absolute right-4 top-3 bottom-0 my-auto flex item-center justify-center");
|
|
6815
6812
|
},
|
|
@@ -6841,7 +6838,7 @@
|
|
|
6841
6838
|
32768 && span0_class_value !== (span0_class_value = /*inlineAnswerResult*/
|
|
6842
6839
|
(ctx2[15][
|
|
6843
6840
|
/*itemIndex*/
|
|
6844
|
-
ctx2[
|
|
6841
|
+
ctx2[61]
|
|
6845
6842
|
] ? "text-green-900" : "text-red-900") + " p-0.5")) {
|
|
6846
6843
|
attr(span0, "class", span0_class_value);
|
|
6847
6844
|
}
|
|
@@ -6933,7 +6930,7 @@
|
|
|
6933
6930
|
let p;
|
|
6934
6931
|
let t0_value = useIsEven(
|
|
6935
6932
|
/*iterationIndex*/
|
|
6936
|
-
ctx[
|
|
6933
|
+
ctx[64]
|
|
6937
6934
|
) ? `Student's` : "Correct";
|
|
6938
6935
|
let t0;
|
|
6939
6936
|
let t1;
|
|
@@ -6957,7 +6954,7 @@
|
|
|
6957
6954
|
let t6;
|
|
6958
6955
|
let show_if = useIsEven(
|
|
6959
6956
|
/*iterationIndex*/
|
|
6960
|
-
ctx[
|
|
6957
|
+
ctx[64]
|
|
6961
6958
|
);
|
|
6962
6959
|
let div0_class_value;
|
|
6963
6960
|
let div1_class_value;
|
|
@@ -6978,7 +6975,7 @@
|
|
|
6978
6975
|
t3 = space();
|
|
6979
6976
|
span1 = element("span");
|
|
6980
6977
|
span1.textContent = `${/*itemIndex*/
|
|
6981
|
-
ctx[
|
|
6978
|
+
ctx[61] + 1}`;
|
|
6982
6979
|
t5 = space();
|
|
6983
6980
|
textarea = element("textarea");
|
|
6984
6981
|
t6 = space();
|
|
@@ -6986,130 +6983,130 @@
|
|
|
6986
6983
|
if_block.c();
|
|
6987
6984
|
attr(p, "class", p_class_value = "text-base text-charcoal font-semibold " + (useIsEven(
|
|
6988
6985
|
/*iterationIndex*/
|
|
6989
|
-
ctx[
|
|
6986
|
+
ctx[64]
|
|
6990
6987
|
) && /*itemIndex*/
|
|
6991
|
-
ctx[
|
|
6988
|
+
ctx[61] !== 0 ? "hidden" : !useIsEven(
|
|
6992
6989
|
/*iterationIndex*/
|
|
6993
|
-
ctx[
|
|
6990
|
+
ctx[64]
|
|
6994
6991
|
) && /*itemIndex*/
|
|
6995
|
-
ctx[
|
|
6992
|
+
ctx[61] !== 0 ? "mt-2 md:mt-0 md:hidden" : !useIsEven(
|
|
6996
6993
|
/*iterationIndex*/
|
|
6997
|
-
ctx[
|
|
6994
|
+
ctx[64]
|
|
6998
6995
|
) && /*itemIndex*/
|
|
6999
|
-
ctx[
|
|
6996
|
+
ctx[61] === 0 ? "mt-2 md:mt-0" : (
|
|
7000
6997
|
/*itemIndex*/
|
|
7001
|
-
ctx[
|
|
6998
|
+
ctx[61] === 0 ? "" : ""
|
|
7002
6999
|
)) + " " + (!useIsEven(
|
|
7003
7000
|
/*iterationIndex*/
|
|
7004
|
-
ctx[
|
|
7001
|
+
ctx[64]
|
|
7005
7002
|
) && /*inlineAnswerResult*/
|
|
7006
7003
|
ctx[15][
|
|
7007
7004
|
/*itemIndex*/
|
|
7008
|
-
ctx[
|
|
7005
|
+
ctx[61]
|
|
7009
7006
|
] ? "hidden md:block" : ""));
|
|
7010
7007
|
attr(span0, "class", "absolute inset-0 bottom-[7px] bg-black opacity-5 rounded-l-lg w-8.5 top-1");
|
|
7011
7008
|
attr(span1, "class", "absolute font-semibold text-base leading-[19px] text-charcoal px-3 inline-block top-1/2 -translate-y-1/2 -mt-0.5");
|
|
7012
7009
|
attr(label, "for", label_for_value = `${/*iterationIndex*/
|
|
7013
|
-
ctx[
|
|
7010
|
+
ctx[64]}-${/*sessionId*/
|
|
7014
7011
|
ctx[5]}-${/*itemIndex*/
|
|
7015
|
-
ctx[
|
|
7012
|
+
ctx[61]}`);
|
|
7016
7013
|
attr(label, "class", label_class_value = "absolute left-0 top-[13px] bottom-0 " + /*correctAnswerDataLength*/
|
|
7017
7014
|
(ctx[17] > 1 && !useIsEven(
|
|
7018
7015
|
/*iterationIndex*/
|
|
7019
|
-
ctx[
|
|
7016
|
+
ctx[64]
|
|
7020
7017
|
) ? "hidden md:inline-block" : (
|
|
7021
7018
|
/*correctAnswerDataLength*/
|
|
7022
7019
|
ctx[17] > 1 && useIsEven(
|
|
7023
7020
|
/*iterationIndex*/
|
|
7024
|
-
ctx[
|
|
7021
|
+
ctx[64]
|
|
7025
7022
|
) ? "" : "hidden"
|
|
7026
7023
|
)));
|
|
7027
7024
|
attr(label, "aria-hidden", "true");
|
|
7028
7025
|
attr(textarea, "aria-label", textarea_aria_label_value = `${useIsEven(
|
|
7029
7026
|
/*iterationIndex*/
|
|
7030
|
-
ctx[
|
|
7027
|
+
ctx[64]
|
|
7031
7028
|
) ? `Student's` : "Correct"} answer${useIsEven(
|
|
7032
7029
|
/*iterationIndex*/
|
|
7033
|
-
ctx[
|
|
7030
|
+
ctx[64]
|
|
7034
7031
|
) && /*inlineAnswerResult*/
|
|
7035
7032
|
ctx[15][
|
|
7036
7033
|
/*itemIndex*/
|
|
7037
|
-
ctx[
|
|
7034
|
+
ctx[61]
|
|
7038
7035
|
] ? " (Correct)" : useIsEven(
|
|
7039
7036
|
/*iterationIndex*/
|
|
7040
|
-
ctx[
|
|
7037
|
+
ctx[64]
|
|
7041
7038
|
) && !/*inlineAnswerResult*/
|
|
7042
7039
|
ctx[15][
|
|
7043
7040
|
/*itemIndex*/
|
|
7044
|
-
ctx[
|
|
7041
|
+
ctx[61]
|
|
7045
7042
|
] ? " (Incorrect)" : ""}, Item number ${/*itemIndex*/
|
|
7046
|
-
ctx[
|
|
7043
|
+
ctx[61] + 1}:`);
|
|
7047
7044
|
attr(textarea, "class", textarea_class_value = "typein-textbox py-[9px] pr-4 mt-4 " + /*correctAnswerDataLength*/
|
|
7048
7045
|
(ctx[17] > 1 && !useIsEven(
|
|
7049
7046
|
/*iterationIndex*/
|
|
7050
|
-
ctx[
|
|
7047
|
+
ctx[64]
|
|
7051
7048
|
) ? "md:pl-13.2" : (
|
|
7052
7049
|
/*correctAnswerDataLength*/
|
|
7053
7050
|
ctx[17] > 1 && useIsEven(
|
|
7054
7051
|
/*iterationIndex*/
|
|
7055
|
-
ctx[
|
|
7052
|
+
ctx[64]
|
|
7056
7053
|
) ? "pl-13.2" : ""
|
|
7057
7054
|
)) + " " + (useIsEven(
|
|
7058
7055
|
/*iterationIndex*/
|
|
7059
|
-
ctx[
|
|
7056
|
+
ctx[64]
|
|
7060
7057
|
) ? "!pr-11" : "") + " " + (useIsEven(
|
|
7061
7058
|
/*iterationIndex*/
|
|
7062
|
-
ctx[
|
|
7059
|
+
ctx[64]
|
|
7063
7060
|
) && /*inlineAnswerResult*/
|
|
7064
7061
|
ctx[15][
|
|
7065
7062
|
/*itemIndex*/
|
|
7066
|
-
ctx[
|
|
7063
|
+
ctx[61]
|
|
7067
7064
|
] ? "border-2 border-green-900" : useIsEven(
|
|
7068
7065
|
/*iterationIndex*/
|
|
7069
|
-
ctx[
|
|
7066
|
+
ctx[64]
|
|
7070
7067
|
) && !/*inlineAnswerResult*/
|
|
7071
7068
|
ctx[15][
|
|
7072
7069
|
/*itemIndex*/
|
|
7073
|
-
ctx[
|
|
7070
|
+
ctx[61]
|
|
7074
7071
|
] ? "border-2 border-red-900 bg-red-50" : ""));
|
|
7075
7072
|
attr(textarea, "id", textarea_id_value = `${/*iterationIndex*/
|
|
7076
|
-
ctx[
|
|
7073
|
+
ctx[64]}-${/*sessionId*/
|
|
7077
7074
|
ctx[5]}-${/*itemIndex*/
|
|
7078
|
-
ctx[
|
|
7075
|
+
ctx[61]}`);
|
|
7079
7076
|
textarea.value = textarea_value_value = useIsEven(
|
|
7080
7077
|
/*iterationIndex*/
|
|
7081
|
-
ctx[
|
|
7078
|
+
ctx[64]
|
|
7082
7079
|
) ? (
|
|
7083
7080
|
/*inlineTypeinAnswer*/
|
|
7084
7081
|
ctx[9][
|
|
7085
7082
|
/*itemIndex*/
|
|
7086
|
-
ctx[
|
|
7083
|
+
ctx[61]
|
|
7087
7084
|
] || "No answer provided"
|
|
7088
7085
|
) : (
|
|
7089
7086
|
/*item*/
|
|
7090
|
-
ctx[
|
|
7087
|
+
ctx[59][0]
|
|
7091
7088
|
);
|
|
7092
7089
|
attr(textarea, "rows", "1");
|
|
7093
7090
|
textarea.readOnly = true;
|
|
7094
7091
|
attr(textarea, "tabindex", textarea_tabindex_value = !useIsEven(
|
|
7095
7092
|
/*iterationIndex*/
|
|
7096
|
-
ctx[
|
|
7093
|
+
ctx[64]
|
|
7097
7094
|
) && /*inlineAnswerResult*/
|
|
7098
7095
|
ctx[15][
|
|
7099
7096
|
/*itemIndex*/
|
|
7100
|
-
ctx[
|
|
7097
|
+
ctx[61]
|
|
7101
7098
|
] ? "-1" : "");
|
|
7102
7099
|
attr(div0, "class", div0_class_value = "h-fit relative " + (!useIsEven(
|
|
7103
7100
|
/*iterationIndex*/
|
|
7104
|
-
ctx[
|
|
7101
|
+
ctx[64]
|
|
7105
7102
|
) && /*inlineAnswerResult*/
|
|
7106
7103
|
ctx[15][
|
|
7107
7104
|
/*itemIndex*/
|
|
7108
|
-
ctx[
|
|
7105
|
+
ctx[61]
|
|
7109
7106
|
] ? "hidden md:block" : ""));
|
|
7110
7107
|
attr(div1, "class", div1_class_value = "flex flex-col md:w-1/2 " + (useIsEven(
|
|
7111
7108
|
/*iterationIndex*/
|
|
7112
|
-
ctx[
|
|
7109
|
+
ctx[64]
|
|
7113
7110
|
) ? "md:pr-4" : "ml-8.5 md:ml-0 md:pl-4"));
|
|
7114
7111
|
},
|
|
7115
7112
|
m(target, anchor) {
|
|
@@ -7138,46 +7135,46 @@
|
|
|
7138
7135
|
if (!current || dirty[0] & /*inlineAnswerResult*/
|
|
7139
7136
|
32768 && p_class_value !== (p_class_value = "text-base text-charcoal font-semibold " + (useIsEven(
|
|
7140
7137
|
/*iterationIndex*/
|
|
7141
|
-
ctx2[
|
|
7138
|
+
ctx2[64]
|
|
7142
7139
|
) && /*itemIndex*/
|
|
7143
|
-
ctx2[
|
|
7140
|
+
ctx2[61] !== 0 ? "hidden" : !useIsEven(
|
|
7144
7141
|
/*iterationIndex*/
|
|
7145
|
-
ctx2[
|
|
7142
|
+
ctx2[64]
|
|
7146
7143
|
) && /*itemIndex*/
|
|
7147
|
-
ctx2[
|
|
7144
|
+
ctx2[61] !== 0 ? "mt-2 md:mt-0 md:hidden" : !useIsEven(
|
|
7148
7145
|
/*iterationIndex*/
|
|
7149
|
-
ctx2[
|
|
7146
|
+
ctx2[64]
|
|
7150
7147
|
) && /*itemIndex*/
|
|
7151
|
-
ctx2[
|
|
7148
|
+
ctx2[61] === 0 ? "mt-2 md:mt-0" : (
|
|
7152
7149
|
/*itemIndex*/
|
|
7153
|
-
ctx2[
|
|
7150
|
+
ctx2[61] === 0 ? "" : ""
|
|
7154
7151
|
)) + " " + (!useIsEven(
|
|
7155
7152
|
/*iterationIndex*/
|
|
7156
|
-
ctx2[
|
|
7153
|
+
ctx2[64]
|
|
7157
7154
|
) && /*inlineAnswerResult*/
|
|
7158
7155
|
ctx2[15][
|
|
7159
7156
|
/*itemIndex*/
|
|
7160
|
-
ctx2[
|
|
7157
|
+
ctx2[61]
|
|
7161
7158
|
] ? "hidden md:block" : ""))) {
|
|
7162
7159
|
attr(p, "class", p_class_value);
|
|
7163
7160
|
}
|
|
7164
7161
|
if (!current || dirty[0] & /*sessionId*/
|
|
7165
7162
|
32 && label_for_value !== (label_for_value = `${/*iterationIndex*/
|
|
7166
|
-
ctx2[
|
|
7163
|
+
ctx2[64]}-${/*sessionId*/
|
|
7167
7164
|
ctx2[5]}-${/*itemIndex*/
|
|
7168
|
-
ctx2[
|
|
7165
|
+
ctx2[61]}`)) {
|
|
7169
7166
|
attr(label, "for", label_for_value);
|
|
7170
7167
|
}
|
|
7171
7168
|
if (!current || dirty[0] & /*correctAnswerDataLength*/
|
|
7172
7169
|
131072 && label_class_value !== (label_class_value = "absolute left-0 top-[13px] bottom-0 " + /*correctAnswerDataLength*/
|
|
7173
7170
|
(ctx2[17] > 1 && !useIsEven(
|
|
7174
7171
|
/*iterationIndex*/
|
|
7175
|
-
ctx2[
|
|
7172
|
+
ctx2[64]
|
|
7176
7173
|
) ? "hidden md:inline-block" : (
|
|
7177
7174
|
/*correctAnswerDataLength*/
|
|
7178
7175
|
ctx2[17] > 1 && useIsEven(
|
|
7179
7176
|
/*iterationIndex*/
|
|
7180
|
-
ctx2[
|
|
7177
|
+
ctx2[64]
|
|
7181
7178
|
) ? "" : "hidden"
|
|
7182
7179
|
)))) {
|
|
7183
7180
|
attr(label, "class", label_class_value);
|
|
@@ -7185,87 +7182,87 @@
|
|
|
7185
7182
|
if (!current || dirty[0] & /*inlineAnswerResult*/
|
|
7186
7183
|
32768 && textarea_aria_label_value !== (textarea_aria_label_value = `${useIsEven(
|
|
7187
7184
|
/*iterationIndex*/
|
|
7188
|
-
ctx2[
|
|
7185
|
+
ctx2[64]
|
|
7189
7186
|
) ? `Student's` : "Correct"} answer${useIsEven(
|
|
7190
7187
|
/*iterationIndex*/
|
|
7191
|
-
ctx2[
|
|
7188
|
+
ctx2[64]
|
|
7192
7189
|
) && /*inlineAnswerResult*/
|
|
7193
7190
|
ctx2[15][
|
|
7194
7191
|
/*itemIndex*/
|
|
7195
|
-
ctx2[
|
|
7192
|
+
ctx2[61]
|
|
7196
7193
|
] ? " (Correct)" : useIsEven(
|
|
7197
7194
|
/*iterationIndex*/
|
|
7198
|
-
ctx2[
|
|
7195
|
+
ctx2[64]
|
|
7199
7196
|
) && !/*inlineAnswerResult*/
|
|
7200
7197
|
ctx2[15][
|
|
7201
7198
|
/*itemIndex*/
|
|
7202
|
-
ctx2[
|
|
7199
|
+
ctx2[61]
|
|
7203
7200
|
] ? " (Incorrect)" : ""}, Item number ${/*itemIndex*/
|
|
7204
|
-
ctx2[
|
|
7201
|
+
ctx2[61] + 1}:`)) {
|
|
7205
7202
|
attr(textarea, "aria-label", textarea_aria_label_value);
|
|
7206
7203
|
}
|
|
7207
7204
|
if (!current || dirty[0] & /*correctAnswerDataLength, inlineAnswerResult*/
|
|
7208
7205
|
163840 && textarea_class_value !== (textarea_class_value = "typein-textbox py-[9px] pr-4 mt-4 " + /*correctAnswerDataLength*/
|
|
7209
7206
|
(ctx2[17] > 1 && !useIsEven(
|
|
7210
7207
|
/*iterationIndex*/
|
|
7211
|
-
ctx2[
|
|
7208
|
+
ctx2[64]
|
|
7212
7209
|
) ? "md:pl-13.2" : (
|
|
7213
7210
|
/*correctAnswerDataLength*/
|
|
7214
7211
|
ctx2[17] > 1 && useIsEven(
|
|
7215
7212
|
/*iterationIndex*/
|
|
7216
|
-
ctx2[
|
|
7213
|
+
ctx2[64]
|
|
7217
7214
|
) ? "pl-13.2" : ""
|
|
7218
7215
|
)) + " " + (useIsEven(
|
|
7219
7216
|
/*iterationIndex*/
|
|
7220
|
-
ctx2[
|
|
7217
|
+
ctx2[64]
|
|
7221
7218
|
) ? "!pr-11" : "") + " " + (useIsEven(
|
|
7222
7219
|
/*iterationIndex*/
|
|
7223
|
-
ctx2[
|
|
7220
|
+
ctx2[64]
|
|
7224
7221
|
) && /*inlineAnswerResult*/
|
|
7225
7222
|
ctx2[15][
|
|
7226
7223
|
/*itemIndex*/
|
|
7227
|
-
ctx2[
|
|
7224
|
+
ctx2[61]
|
|
7228
7225
|
] ? "border-2 border-green-900" : useIsEven(
|
|
7229
7226
|
/*iterationIndex*/
|
|
7230
|
-
ctx2[
|
|
7227
|
+
ctx2[64]
|
|
7231
7228
|
) && !/*inlineAnswerResult*/
|
|
7232
7229
|
ctx2[15][
|
|
7233
7230
|
/*itemIndex*/
|
|
7234
|
-
ctx2[
|
|
7231
|
+
ctx2[61]
|
|
7235
7232
|
] ? "border-2 border-red-900 bg-red-50" : ""))) {
|
|
7236
7233
|
attr(textarea, "class", textarea_class_value);
|
|
7237
7234
|
}
|
|
7238
7235
|
if (!current || dirty[0] & /*sessionId*/
|
|
7239
7236
|
32 && textarea_id_value !== (textarea_id_value = `${/*iterationIndex*/
|
|
7240
|
-
ctx2[
|
|
7237
|
+
ctx2[64]}-${/*sessionId*/
|
|
7241
7238
|
ctx2[5]}-${/*itemIndex*/
|
|
7242
|
-
ctx2[
|
|
7239
|
+
ctx2[61]}`)) {
|
|
7243
7240
|
attr(textarea, "id", textarea_id_value);
|
|
7244
7241
|
}
|
|
7245
7242
|
if (!current || dirty[0] & /*inlineTypeinAnswer, correctAnswerData*/
|
|
7246
7243
|
66048 && textarea_value_value !== (textarea_value_value = useIsEven(
|
|
7247
7244
|
/*iterationIndex*/
|
|
7248
|
-
ctx2[
|
|
7245
|
+
ctx2[64]
|
|
7249
7246
|
) ? (
|
|
7250
7247
|
/*inlineTypeinAnswer*/
|
|
7251
7248
|
ctx2[9][
|
|
7252
7249
|
/*itemIndex*/
|
|
7253
|
-
ctx2[
|
|
7250
|
+
ctx2[61]
|
|
7254
7251
|
] || "No answer provided"
|
|
7255
7252
|
) : (
|
|
7256
7253
|
/*item*/
|
|
7257
|
-
ctx2[
|
|
7254
|
+
ctx2[59][0]
|
|
7258
7255
|
))) {
|
|
7259
7256
|
textarea.value = textarea_value_value;
|
|
7260
7257
|
}
|
|
7261
7258
|
if (!current || dirty[0] & /*inlineAnswerResult*/
|
|
7262
7259
|
32768 && textarea_tabindex_value !== (textarea_tabindex_value = !useIsEven(
|
|
7263
7260
|
/*iterationIndex*/
|
|
7264
|
-
ctx2[
|
|
7261
|
+
ctx2[64]
|
|
7265
7262
|
) && /*inlineAnswerResult*/
|
|
7266
7263
|
ctx2[15][
|
|
7267
7264
|
/*itemIndex*/
|
|
7268
|
-
ctx2[
|
|
7265
|
+
ctx2[61]
|
|
7269
7266
|
] ? "-1" : "")) {
|
|
7270
7267
|
attr(textarea, "tabindex", textarea_tabindex_value);
|
|
7271
7268
|
}
|
|
@@ -7274,11 +7271,11 @@
|
|
|
7274
7271
|
if (!current || dirty[0] & /*inlineAnswerResult*/
|
|
7275
7272
|
32768 && div0_class_value !== (div0_class_value = "h-fit relative " + (!useIsEven(
|
|
7276
7273
|
/*iterationIndex*/
|
|
7277
|
-
ctx2[
|
|
7274
|
+
ctx2[64]
|
|
7278
7275
|
) && /*inlineAnswerResult*/
|
|
7279
7276
|
ctx2[15][
|
|
7280
7277
|
/*itemIndex*/
|
|
7281
|
-
ctx2[
|
|
7278
|
+
ctx2[61]
|
|
7282
7279
|
] ? "hidden md:block" : ""))) {
|
|
7283
7280
|
attr(div0, "class", div0_class_value);
|
|
7284
7281
|
}
|
|
@@ -7522,7 +7519,7 @@
|
|
|
7522
7519
|
ctx2[14];
|
|
7523
7520
|
if (dirty[0] & /*correctAnswerData, inlineAnswerResult, correctAnswerDataLength, sessionId, inlineTypeinAnswer, isPreviewMode, isPreviewModeInteractive, isSkippedAnswer, isResultCorrect, resultFeedback, isFinished, resultLabel, isDataSaving, root, inlinePromptString, textAriaLabel, placeholder, typeinAnswer*/
|
|
7524
7521
|
507903 | dirty[2] & /*$$scope*/
|
|
7525
|
-
|
|
7522
|
+
8) {
|
|
7526
7523
|
promptbody_changes.$$scope = { dirty, ctx: ctx2 };
|
|
7527
7524
|
}
|
|
7528
7525
|
promptbody.$set(promptbody_changes);
|
|
@@ -7632,8 +7629,6 @@
|
|
|
7632
7629
|
$$invalidate(0, isFinished = true);
|
|
7633
7630
|
$$invalidate(16, correctAnswerData = previewCorrectAnswer);
|
|
7634
7631
|
$$invalidate(17, correctAnswerDataLength = previewCorrectAnswer.length);
|
|
7635
|
-
if (hasOnlyEmptyWrongAnswers(inlineTypeinAnswer, inlineAnswerResult) && !isResultCorrect)
|
|
7636
|
-
$$invalidate(10, isSkippedAnswer = true);
|
|
7637
7632
|
getFeedback();
|
|
7638
7633
|
buildInlinePrompt();
|
|
7639
7634
|
setTimeout(
|
|
@@ -7673,9 +7668,6 @@
|
|
|
7673
7668
|
return transformedAnswerList[index].includes(inlineAnswer.toLowerCase().trim());
|
|
7674
7669
|
});
|
|
7675
7670
|
};
|
|
7676
|
-
const hasOnlyEmptyWrongAnswers = (answers, answerResults) => {
|
|
7677
|
-
return answers.filter((value) => value === "").length === answerResults.filter((value) => value === false).length;
|
|
7678
|
-
};
|
|
7679
7671
|
if (isFinished) {
|
|
7680
7672
|
const { answer, hasAnswer } = scoringMetadata;
|
|
7681
7673
|
isSkippedAnswer = !hasAnswer;
|
|
@@ -7690,8 +7682,6 @@
|
|
|
7690
7682
|
correctAnswerData = correctAnswer;
|
|
7691
7683
|
correctAnswerDataLength = correctAnswer.length;
|
|
7692
7684
|
inlineAnswerResult = checkInlineAnswer(correctAnswer, metadataAnswer, allowNonMacrons, ignorePunctuation);
|
|
7693
|
-
if (hasOnlyEmptyWrongAnswers(metadataAnswer, inlineAnswerResult) && !isResultCorrect)
|
|
7694
|
-
isSkippedAnswer = true;
|
|
7695
7685
|
} else {
|
|
7696
7686
|
typeinAnswer = answer && hasAnswer ? answer : typeinAnswer;
|
|
7697
7687
|
}
|
|
@@ -14692,7 +14682,7 @@
|
|
|
14692
14682
|
}
|
|
14693
14683
|
});
|
|
14694
14684
|
$$invalidate(26, allAnswersCorrect = hasCorrect && !hasIncorrect && !hasWordBinItems);
|
|
14695
|
-
$$invalidate(27, isItemSkipped = totalRemainingWordBinItem === totalCategoryItems
|
|
14685
|
+
$$invalidate(27, isItemSkipped = totalRemainingWordBinItem === totalCategoryItems);
|
|
14696
14686
|
$$invalidate(28, resultFeedback = allAnswersCorrect ? correctFeedback : incorrectFeedback);
|
|
14697
14687
|
$$invalidate(25, isFeedbackShown = isPreviewModeInteractive ? allItemsPlacedTrigger : allAnswersCorrect ? false : true);
|
|
14698
14688
|
}
|
|
@@ -18391,7 +18381,7 @@
|
|
|
18391
18381
|
if (!scoringMetadata.hasAnswer)
|
|
18392
18382
|
return true;
|
|
18393
18383
|
const answerStatus = getSessionFeedbackData();
|
|
18394
|
-
return answerStatus.
|
|
18384
|
+
return answerStatus.every((status) => status === "skipped");
|
|
18395
18385
|
});
|
|
18396
18386
|
}
|
|
18397
18387
|
if ($$self.$$.dirty[0] & /*getSessionFeedbackData*/
|