catchup-library-web 1.14.6 → 1.14.8
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/index.js
CHANGED
|
@@ -2506,6 +2506,7 @@ var findBestFitActivity = (activity, individualModelList, outcomeModelList) => {
|
|
|
2506
2506
|
} else if (type === "TRUE_FALSE") {
|
|
2507
2507
|
currentDifficulty = difficultyMap["trueFalseDifficulty"];
|
|
2508
2508
|
}
|
|
2509
|
+
currentDifficulty = currentDifficulty.toLowerCase();
|
|
2509
2510
|
const currentDifficultyScore = foundModel[currentDifficulty];
|
|
2510
2511
|
const splittedTypeList = type.split("_");
|
|
2511
2512
|
let activityTemplateString = "";
|
|
@@ -3270,14 +3271,14 @@ var ShowBodyMediaByContentType = ({
|
|
|
3270
3271
|
return "";
|
|
3271
3272
|
}
|
|
3272
3273
|
};
|
|
3273
|
-
const renderSpecialExpressions = (inputPart) => {
|
|
3274
|
+
const renderSpecialExpressions = (inputPart, inputPartIndex) => {
|
|
3274
3275
|
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
3275
3276
|
"span",
|
|
3276
3277
|
{
|
|
3277
3278
|
className: `${inputPart.isBold ? "font-bold" : ""} ${inputPart.isUnderline ? "underline" : ""}`,
|
|
3278
3279
|
children: inputPart.isEquation ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "text-2xl", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_katex.InlineMath, { math: inputPart.value }) }) : inputPart.value
|
|
3279
3280
|
},
|
|
3280
|
-
|
|
3281
|
+
inputPartIndex
|
|
3281
3282
|
);
|
|
3282
3283
|
};
|
|
3283
3284
|
const balanceSpecialChars = (text) => {
|
|
@@ -3296,7 +3297,7 @@ var ShowBodyMediaByContentType = ({
|
|
|
3296
3297
|
const renderTextContent = (text, itemKey) => {
|
|
3297
3298
|
const balancedText = balanceSpecialChars(text);
|
|
3298
3299
|
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "text-xl", children: constructInputWithSpecialExpressionList(balancedText).map(
|
|
3299
|
-
(inputPart) => renderSpecialExpressions(inputPart)
|
|
3300
|
+
(inputPart, inputPartIndex) => renderSpecialExpressions(inputPart, inputPartIndex)
|
|
3300
3301
|
) }, itemKey);
|
|
3301
3302
|
};
|
|
3302
3303
|
const handleOpenFullScreen = (imageSource) => {
|
|
@@ -3329,7 +3330,7 @@ var ShowBodyMediaByContentType = ({
|
|
|
3329
3330
|
const itemKey = `text-inside-${index}-${currentIndex}`;
|
|
3330
3331
|
valuePartList.push(
|
|
3331
3332
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "text-xl font-bold", children: constructInputWithSpecialExpressionList(textInsideTag).map(
|
|
3332
|
-
(inputPart) => renderSpecialExpressions(inputPart)
|
|
3333
|
+
(inputPart, inputPartIndex) => renderSpecialExpressions(inputPart, inputPartIndex)
|
|
3333
3334
|
) }, itemKey)
|
|
3334
3335
|
);
|
|
3335
3336
|
copyValue = copyValue.substring(
|
package/dist/index.mjs
CHANGED
|
@@ -2297,6 +2297,7 @@ var findBestFitActivity = (activity, individualModelList, outcomeModelList) => {
|
|
|
2297
2297
|
} else if (type === "TRUE_FALSE") {
|
|
2298
2298
|
currentDifficulty = difficultyMap["trueFalseDifficulty"];
|
|
2299
2299
|
}
|
|
2300
|
+
currentDifficulty = currentDifficulty.toLowerCase();
|
|
2300
2301
|
const currentDifficultyScore = foundModel[currentDifficulty];
|
|
2301
2302
|
const splittedTypeList = type.split("_");
|
|
2302
2303
|
let activityTemplateString = "";
|
|
@@ -3061,14 +3062,14 @@ var ShowBodyMediaByContentType = ({
|
|
|
3061
3062
|
return "";
|
|
3062
3063
|
}
|
|
3063
3064
|
};
|
|
3064
|
-
const renderSpecialExpressions = (inputPart) => {
|
|
3065
|
+
const renderSpecialExpressions = (inputPart, inputPartIndex) => {
|
|
3065
3066
|
return /* @__PURE__ */ jsx16(
|
|
3066
3067
|
"span",
|
|
3067
3068
|
{
|
|
3068
3069
|
className: `${inputPart.isBold ? "font-bold" : ""} ${inputPart.isUnderline ? "underline" : ""}`,
|
|
3069
3070
|
children: inputPart.isEquation ? /* @__PURE__ */ jsx16("span", { className: "text-2xl", children: /* @__PURE__ */ jsx16(InlineMath, { math: inputPart.value }) }) : inputPart.value
|
|
3070
3071
|
},
|
|
3071
|
-
|
|
3072
|
+
inputPartIndex
|
|
3072
3073
|
);
|
|
3073
3074
|
};
|
|
3074
3075
|
const balanceSpecialChars = (text) => {
|
|
@@ -3087,7 +3088,7 @@ var ShowBodyMediaByContentType = ({
|
|
|
3087
3088
|
const renderTextContent = (text, itemKey) => {
|
|
3088
3089
|
const balancedText = balanceSpecialChars(text);
|
|
3089
3090
|
return /* @__PURE__ */ jsx16("span", { className: "text-xl", children: constructInputWithSpecialExpressionList(balancedText).map(
|
|
3090
|
-
(inputPart) => renderSpecialExpressions(inputPart)
|
|
3091
|
+
(inputPart, inputPartIndex) => renderSpecialExpressions(inputPart, inputPartIndex)
|
|
3091
3092
|
) }, itemKey);
|
|
3092
3093
|
};
|
|
3093
3094
|
const handleOpenFullScreen = (imageSource) => {
|
|
@@ -3120,7 +3121,7 @@ var ShowBodyMediaByContentType = ({
|
|
|
3120
3121
|
const itemKey = `text-inside-${index}-${currentIndex}`;
|
|
3121
3122
|
valuePartList.push(
|
|
3122
3123
|
/* @__PURE__ */ jsx16("span", { className: "text-xl font-bold", children: constructInputWithSpecialExpressionList(textInsideTag).map(
|
|
3123
|
-
(inputPart) => renderSpecialExpressions(inputPart)
|
|
3124
|
+
(inputPart, inputPartIndex) => renderSpecialExpressions(inputPart, inputPartIndex)
|
|
3124
3125
|
) }, itemKey)
|
|
3125
3126
|
);
|
|
3126
3127
|
copyValue = copyValue.substring(
|
package/package.json
CHANGED
|
@@ -33,10 +33,13 @@ const ShowBodyMediaByContentType = ({
|
|
|
33
33
|
};
|
|
34
34
|
|
|
35
35
|
// Helper function to render special expressions with proper keys
|
|
36
|
-
const renderSpecialExpressions = (
|
|
36
|
+
const renderSpecialExpressions = (
|
|
37
|
+
inputPart: IInputPart,
|
|
38
|
+
inputPartIndex: number
|
|
39
|
+
) => {
|
|
37
40
|
return (
|
|
38
41
|
<span
|
|
39
|
-
key={
|
|
42
|
+
key={inputPartIndex}
|
|
40
43
|
className={`${inputPart.isBold ? "font-bold" : ""} ${
|
|
41
44
|
inputPart.isUnderline ? "underline" : ""
|
|
42
45
|
}`}
|
|
@@ -81,7 +84,8 @@ const ShowBodyMediaByContentType = ({
|
|
|
81
84
|
return (
|
|
82
85
|
<span key={itemKey} className="text-xl">
|
|
83
86
|
{constructInputWithSpecialExpressionList(balancedText).map(
|
|
84
|
-
(inputPart: IInputPart) =>
|
|
87
|
+
(inputPart: IInputPart, inputPartIndex: number) =>
|
|
88
|
+
renderSpecialExpressions(inputPart, inputPartIndex)
|
|
85
89
|
)}
|
|
86
90
|
</span>
|
|
87
91
|
);
|
|
@@ -128,7 +132,8 @@ const ShowBodyMediaByContentType = ({
|
|
|
128
132
|
valuePartList.push(
|
|
129
133
|
<span key={itemKey} className="text-xl font-bold">
|
|
130
134
|
{constructInputWithSpecialExpressionList(textInsideTag).map(
|
|
131
|
-
(inputPart: IInputPart) =>
|
|
135
|
+
(inputPart: IInputPart, inputPartIndex: number) =>
|
|
136
|
+
renderSpecialExpressions(inputPart, inputPartIndex)
|
|
132
137
|
)}
|
|
133
138
|
</span>
|
|
134
139
|
);
|
|
@@ -1498,6 +1498,7 @@ export const findBestFitActivity = (
|
|
|
1498
1498
|
} else if (type === "TRUE_FALSE") {
|
|
1499
1499
|
currentDifficulty = difficultyMap["trueFalseDifficulty"];
|
|
1500
1500
|
}
|
|
1501
|
+
currentDifficulty = currentDifficulty.toLowerCase();
|
|
1501
1502
|
|
|
1502
1503
|
const currentDifficultyScore = foundModel[currentDifficulty];
|
|
1503
1504
|
const splittedTypeList = type.split("_");
|