@cuemath/leap 3.2.29 → 3.2.30-aa0
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/features/sheets/constants/sheet.js +12 -7
- package/dist/features/sheets/constants/sheet.js.map +1 -1
- package/dist/features/sheets/utils/is-v3-worksheet.js +17 -0
- package/dist/features/sheets/utils/is-v3-worksheet.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet-behavior-helper.js +141 -0
- package/dist/features/worksheet/worksheet/worksheet-behavior-helper.js.map +1 -0
- package/dist/features/worksheet/worksheet/worksheet-types.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet.js +318 -367
- package/dist/features/worksheet/worksheet/worksheet.js.map +1 -1
- package/dist/index.d.ts +24 -17
- package/dist/index.js +40 -38
- package/dist/index.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/regex.js +5 -0
- package/dist/node_modules/uuid/dist/esm-browser/regex.js.map +1 -0
- package/dist/node_modules/uuid/dist/esm-browser/rng.js +2 -3
- package/dist/node_modules/uuid/dist/esm-browser/rng.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js +10 -6
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/v4.js +9 -12
- package/dist/node_modules/uuid/dist/esm-browser/v4.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/validate.js +8 -0
- package/dist/node_modules/uuid/dist/esm-browser/validate.js.map +1 -0
- package/package.json +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/native.js +0 -7
- package/dist/node_modules/uuid/dist/esm-browser/native.js.map +0 -1
|
@@ -1,402 +1,353 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import Ct from "
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import Nt from "./worksheet-
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
|
|
25
|
-
import Jt from "./worksheet-summary/worksheet-summary.js";
|
|
26
|
-
const Yt = (Ie, Se) => {
|
|
1
|
+
import { jsxs as y, Fragment as lt, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { memo as dt, forwardRef as mt, useMemo as K, useState as I, useCallback as S, useEffect as T, useLayoutEffect as ut } from "react";
|
|
3
|
+
import ht from "../../../assets/line-icons/icons/check2.js";
|
|
4
|
+
import ft from "../../../assets/line-icons/icons/info2.js";
|
|
5
|
+
import pt from "../../../helpers/get-device-details.js";
|
|
6
|
+
import gt from "../../sheet-tools/desmos-calculator/desmos-calculator.js";
|
|
7
|
+
import de from "../../ui/layout/flex-view.js";
|
|
8
|
+
import bt from "../../ui/text/text.js";
|
|
9
|
+
import Ct from "../user-pointer-pin/user-pin.js";
|
|
10
|
+
import { WORKSHEET_NUDGE_BANNER_HEIGHT as me, TOP_NAVIGATION_HEIGHT as It, DESMOS_CALC_POSITION as St } from "./constants.js";
|
|
11
|
+
import kt from "./hooks/use-create-imperative-handle.js";
|
|
12
|
+
import $t from "./hooks/use-get-active-question-id.js";
|
|
13
|
+
import Tt from "./hooks/use-time-on-questions.js";
|
|
14
|
+
import vt from "./question-tips.js";
|
|
15
|
+
import wt from "./worksheet-action-bar/worksheet-action-bar.js";
|
|
16
|
+
import Et from "./worksheet-blocker/worksheet-blocker.js";
|
|
17
|
+
import { getWorksheetDimensions as Nt, getQuestionsFromItems as At, getInitialResponses as Bt, getLastUnlockedQuestionIndex as ue, getInitialQuestionId as yt, getQuestionMetadata as he, scrollToQuestion as x, getRenderableQuestions as Wt, getWorksheetNudgeBannerInfo as _t } from "./worksheet-helpers.js";
|
|
18
|
+
import Ot from "./worksheet-navigation/worksheet-navigation.js";
|
|
19
|
+
import Dt from "./worksheet-question/worksheet-question.js";
|
|
20
|
+
import Vt from "./worksheet-sidebar/navigator.js";
|
|
21
|
+
import Ht from "./worksheet-sidebar/sidebar.js";
|
|
22
|
+
import { NudgeBannerWrapper as Mt, NudgeBannerIcon as fe, WorksheetContainer as xt, NavigationContainer as Rt, NavigationWrapper as Pt, BlockerWrapper as Qt, DesmosCalcWrapper as Gt, ActionbarContainer as Ft, ActionbarWrapper as jt, StudentWorksheetSideBar as zt, QuestionsWrapper as Lt } from "./worksheet-styled.js";
|
|
23
|
+
import qt from "./worksheet-summary/worksheet-summary.js";
|
|
24
|
+
const Xt = (pe, ge) => {
|
|
27
25
|
const {
|
|
28
|
-
userType:
|
|
29
|
-
studentName:
|
|
30
|
-
questionsSignedRequest:
|
|
31
|
-
worksheetName:
|
|
32
|
-
initialResponseId:
|
|
33
|
-
initialItemIndex:
|
|
34
|
-
learnosityActivityRef
|
|
35
|
-
learnosityItems:
|
|
36
|
-
learnosityResponses:
|
|
37
|
-
layout:
|
|
38
|
-
background:
|
|
26
|
+
userType: r,
|
|
27
|
+
studentName: be = "Student",
|
|
28
|
+
questionsSignedRequest: Ce,
|
|
29
|
+
worksheetName: U,
|
|
30
|
+
initialResponseId: Ie,
|
|
31
|
+
initialItemIndex: Se,
|
|
32
|
+
// learnosityActivityRef,
|
|
33
|
+
learnosityItems: R,
|
|
34
|
+
learnosityResponses: ke,
|
|
35
|
+
layout: k,
|
|
36
|
+
background: $e,
|
|
39
37
|
behavior: a,
|
|
40
|
-
updatedResponses:
|
|
41
|
-
showNudgeBanner:
|
|
42
|
-
markedAsCompleted:
|
|
43
|
-
onResponseChange:
|
|
44
|
-
onBulkResponsesChange:
|
|
45
|
-
onResponsesChange:
|
|
46
|
-
onMediaStateChange:
|
|
47
|
-
onTeacherValidation:
|
|
38
|
+
updatedResponses: P,
|
|
39
|
+
showNudgeBanner: Te,
|
|
40
|
+
markedAsCompleted: J,
|
|
41
|
+
onResponseChange: f,
|
|
42
|
+
onBulkResponsesChange: ve,
|
|
43
|
+
onResponsesChange: Q,
|
|
44
|
+
onMediaStateChange: G,
|
|
45
|
+
onTeacherValidation: Y,
|
|
48
46
|
onOptionalItemAssignment: we,
|
|
49
|
-
onOptionalItemSkip:
|
|
50
|
-
onExitTicketStart:
|
|
51
|
-
onExitTicketSubmit:
|
|
52
|
-
onSubmit:
|
|
53
|
-
learnosity:
|
|
54
|
-
appendedQuestionIds:
|
|
55
|
-
worksheetCompleted:
|
|
56
|
-
userId:
|
|
57
|
-
onPublishStrokes:
|
|
58
|
-
onReceiveStrokes:
|
|
59
|
-
initialStrokesData:
|
|
60
|
-
isCanvasEnabled:
|
|
61
|
-
onHelp:
|
|
62
|
-
onPublishMouseMove:
|
|
63
|
-
onSubscribeMouseMove:
|
|
47
|
+
onOptionalItemSkip: Ee,
|
|
48
|
+
onExitTicketStart: W,
|
|
49
|
+
onExitTicketSubmit: _,
|
|
50
|
+
onSubmit: Ne,
|
|
51
|
+
learnosity: p,
|
|
52
|
+
appendedQuestionIds: Z,
|
|
53
|
+
worksheetCompleted: Ae,
|
|
54
|
+
userId: Be,
|
|
55
|
+
onPublishStrokes: ye,
|
|
56
|
+
onReceiveStrokes: We,
|
|
57
|
+
initialStrokesData: _e,
|
|
58
|
+
isCanvasEnabled: ee,
|
|
59
|
+
onHelp: Oe,
|
|
60
|
+
onPublishMouseMove: De,
|
|
61
|
+
onSubscribeMouseMove: Ve,
|
|
64
62
|
onActiveQuestionChange: F,
|
|
65
63
|
openQuestionFeedbackModal: He,
|
|
66
|
-
summaryDescription:
|
|
67
|
-
canSubmitWorksheet:
|
|
68
|
-
loggerRef:
|
|
69
|
-
canResolveDoubt:
|
|
70
|
-
onResolveDoubt:
|
|
71
|
-
onSkip:
|
|
72
|
-
onUnassign:
|
|
64
|
+
summaryDescription: Me,
|
|
65
|
+
canSubmitWorksheet: xe,
|
|
66
|
+
loggerRef: j,
|
|
67
|
+
canResolveDoubt: Re,
|
|
68
|
+
onResolveDoubt: Pe,
|
|
69
|
+
onSkip: Qe,
|
|
70
|
+
onUnassign: Ge,
|
|
73
71
|
onReview: Fe,
|
|
74
72
|
canToggleScribbling: je = !0,
|
|
75
|
-
studentId:
|
|
76
|
-
subjectiveProps:
|
|
77
|
-
canShowActionBar:
|
|
78
|
-
} =
|
|
79
|
-
containerStyle:
|
|
80
|
-
containerWidth:
|
|
81
|
-
minQuestionHeight:
|
|
82
|
-
minSummaryHeight:
|
|
83
|
-
questionsScrollable:
|
|
84
|
-
navigationBar:
|
|
85
|
-
topOffset:
|
|
86
|
-
renderSideBar:
|
|
87
|
-
showUserPointer:
|
|
88
|
-
} =
|
|
89
|
-
() =>
|
|
90
|
-
[
|
|
91
|
-
), [t] =
|
|
92
|
-
() =>
|
|
93
|
-
sectioned:
|
|
94
|
-
adaptive:
|
|
73
|
+
studentId: ze,
|
|
74
|
+
subjectiveProps: Le,
|
|
75
|
+
canShowActionBar: qe = !0
|
|
76
|
+
} = pe, { initialQuestion: Xe, navigationMode: m, teacherValidationEnabled: Ke, maximumAttempts: te } = a, {
|
|
77
|
+
containerStyle: O,
|
|
78
|
+
containerWidth: Ue,
|
|
79
|
+
minQuestionHeight: ie,
|
|
80
|
+
minSummaryHeight: Je,
|
|
81
|
+
questionsScrollable: D,
|
|
82
|
+
navigationBar: Ye,
|
|
83
|
+
topOffset: V,
|
|
84
|
+
renderSideBar: Ze,
|
|
85
|
+
showUserPointer: et = !0
|
|
86
|
+
} = k, ne = te === -2, { actionbarHeight: g, maxQuestionWidth: z, questionsContainerWidth: L } = K(
|
|
87
|
+
() => Nt(R, k),
|
|
88
|
+
[k, R]
|
|
89
|
+
), [t] = I(
|
|
90
|
+
() => At(R, {
|
|
91
|
+
sectioned: Ke && m !== "ADAPTIVE" && m !== "CURRENT",
|
|
92
|
+
adaptive: m === "ADAPTIVE"
|
|
95
93
|
})
|
|
96
|
-
), [c,
|
|
97
|
-
() =>
|
|
98
|
-
), [
|
|
99
|
-
() =>
|
|
94
|
+
), [c, v] = I(
|
|
95
|
+
() => ke ?? Bt(t)
|
|
96
|
+
), [oe, tt] = I(!1), u = K(
|
|
97
|
+
() => m !== "OPEN" ? ue({
|
|
100
98
|
questions: t,
|
|
101
99
|
responses: c,
|
|
102
100
|
behavior: a,
|
|
103
|
-
userType:
|
|
101
|
+
userType: r
|
|
104
102
|
}) : t.length - 1,
|
|
105
|
-
[a,
|
|
106
|
-
), l = t[
|
|
107
|
-
() =>
|
|
103
|
+
[a, m, t, c, r]
|
|
104
|
+
), l = t[u], n = c[(l == null ? void 0 : l.response_id) ?? ""], { bannerBackgroundColor: it, label: nt } = _t(r, !!J), [w] = I(
|
|
105
|
+
() => yt({
|
|
108
106
|
questions: t,
|
|
109
|
-
initialQuestion:
|
|
110
|
-
lastUnlockedQuestionIndex:
|
|
107
|
+
initialQuestion: Xe,
|
|
108
|
+
lastUnlockedQuestionIndex: ue({
|
|
111
109
|
questions: t,
|
|
112
110
|
responses: c,
|
|
113
111
|
behavior: a,
|
|
114
|
-
userType:
|
|
112
|
+
userType: r
|
|
115
113
|
}),
|
|
116
|
-
initialResponseId:
|
|
117
|
-
initialItemIndex:
|
|
114
|
+
initialResponseId: Ie,
|
|
115
|
+
initialItemIndex: Se
|
|
118
116
|
})
|
|
119
|
-
), { activeQuestionId:
|
|
120
|
-
() => t.findIndex((e) => e.response_id ===
|
|
121
|
-
[
|
|
122
|
-
), [
|
|
123
|
-
(e,
|
|
124
|
-
const
|
|
125
|
-
|
|
126
|
-
const
|
|
127
|
-
if (
|
|
128
|
-
const
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
[
|
|
117
|
+
), { activeQuestionId: E, setActiveQuestionId: H, intersectionObserver: q } = $t(w), d = K(
|
|
118
|
+
() => t.findIndex((e) => e.response_id === E),
|
|
119
|
+
[E, t]
|
|
120
|
+
), [h, X] = I(!1), [re, N] = I(), [se, ae] = I(!1), ce = Tt(a, c, E), ot = S(
|
|
121
|
+
(e, s, o) => {
|
|
122
|
+
const b = s === "SIMULATION" ? "simState" : void 0;
|
|
123
|
+
b && (f ? v(($) => {
|
|
124
|
+
const C = e.response_id, B = he(t, C);
|
|
125
|
+
if (!B) return $;
|
|
126
|
+
const le = {
|
|
127
|
+
...B,
|
|
128
|
+
...$[C],
|
|
129
|
+
[b]: o
|
|
132
130
|
};
|
|
133
|
-
return
|
|
134
|
-
responseId:
|
|
135
|
-
response:
|
|
131
|
+
return f == null || f({
|
|
132
|
+
responseId: C,
|
|
133
|
+
response: le,
|
|
136
134
|
isNewAttempt: !1,
|
|
137
135
|
question: e
|
|
138
136
|
}), {
|
|
139
|
-
|
|
140
|
-
[
|
|
137
|
+
...$,
|
|
138
|
+
[C]: le
|
|
141
139
|
};
|
|
142
|
-
}) :
|
|
140
|
+
}) : G && G(e, s, o));
|
|
143
141
|
},
|
|
144
|
-
[
|
|
145
|
-
),
|
|
146
|
-
(e,
|
|
147
|
-
|
|
148
|
-
const
|
|
149
|
-
return
|
|
150
|
-
...
|
|
142
|
+
[G, f, t]
|
|
143
|
+
), rt = S(
|
|
144
|
+
(e, s) => {
|
|
145
|
+
v((o) => {
|
|
146
|
+
const b = he(t, e);
|
|
147
|
+
return b ? {
|
|
148
|
+
...o,
|
|
151
149
|
[e]: {
|
|
152
|
-
...
|
|
153
|
-
...
|
|
154
|
-
markedForReview:
|
|
150
|
+
...b,
|
|
151
|
+
...o[e],
|
|
152
|
+
markedForReview: s
|
|
155
153
|
}
|
|
156
|
-
} :
|
|
154
|
+
} : o;
|
|
157
155
|
});
|
|
158
156
|
},
|
|
159
157
|
[t]
|
|
160
|
-
),
|
|
161
|
-
|
|
162
|
-
var
|
|
158
|
+
), A = S(() => {
|
|
159
|
+
N((e) => {
|
|
160
|
+
var s;
|
|
163
161
|
if (e) {
|
|
164
|
-
const
|
|
165
|
-
|
|
166
|
-
|
|
162
|
+
const o = (s = t[u]) == null ? void 0 : s.response_id;
|
|
163
|
+
o && setTimeout(() => {
|
|
164
|
+
x(o);
|
|
167
165
|
}, 50);
|
|
168
166
|
}
|
|
169
167
|
});
|
|
170
|
-
}, [
|
|
168
|
+
}, [u, t]), M = S(
|
|
171
169
|
(e) => {
|
|
172
|
-
|
|
170
|
+
X(!1), D ? requestAnimationFrame(() => x(e)) : H(e);
|
|
173
171
|
},
|
|
174
|
-
[
|
|
175
|
-
),
|
|
176
|
-
|
|
177
|
-
}, []),
|
|
178
|
-
|
|
179
|
-
}, []),
|
|
180
|
-
|
|
172
|
+
[D, H]
|
|
173
|
+
), st = S(() => {
|
|
174
|
+
ae(!1);
|
|
175
|
+
}, []), at = S(() => {
|
|
176
|
+
ae(!0);
|
|
177
|
+
}, []), ct = S(() => {
|
|
178
|
+
X(!0);
|
|
181
179
|
}, []);
|
|
182
|
-
return
|
|
183
|
-
const e = t[
|
|
180
|
+
return T(() => {
|
|
181
|
+
const e = t[d];
|
|
184
182
|
e && F && F(e);
|
|
185
|
-
}, [F, t,
|
|
183
|
+
}, [F, t, d]), kt(ge, {
|
|
186
184
|
behavior: a,
|
|
187
185
|
questions: t,
|
|
188
|
-
setResponses:
|
|
189
|
-
onResponseChange:
|
|
190
|
-
onBulkResponsesChange:
|
|
191
|
-
getTimeSpentOnQuestion:
|
|
192
|
-
}),
|
|
193
|
-
|
|
194
|
-
}, [
|
|
195
|
-
|
|
196
|
-
}, [
|
|
197
|
-
|
|
198
|
-
}, [
|
|
186
|
+
setResponses: v,
|
|
187
|
+
onResponseChange: f,
|
|
188
|
+
onBulkResponsesChange: ve,
|
|
189
|
+
getTimeSpentOnQuestion: ce
|
|
190
|
+
}), T(() => () => {
|
|
191
|
+
q.disconnect();
|
|
192
|
+
}, [q]), T(() => {
|
|
193
|
+
Q && c && Q(c);
|
|
194
|
+
}, [Q, c]), T(() => {
|
|
195
|
+
P && v(P);
|
|
196
|
+
}, [P]), ut(() => {
|
|
199
197
|
let e;
|
|
200
|
-
return
|
|
201
|
-
|
|
202
|
-
}, 400) :
|
|
198
|
+
return p && w && (pt().browser_name === "Safari" ? e = setTimeout(() => {
|
|
199
|
+
x(w);
|
|
200
|
+
}, 400) : x(w)), () => {
|
|
203
201
|
clearTimeout(e);
|
|
204
202
|
};
|
|
205
|
-
}, [
|
|
203
|
+
}, [p, w, V]), T(() => {
|
|
206
204
|
if (a.teacherValidationEnabled && l) {
|
|
207
|
-
const { item_type: e, instructor_stimulus:
|
|
208
|
-
|
|
205
|
+
const { item_type: e, instructor_stimulus: s, is_optional: o } = l;
|
|
206
|
+
r === "TEACHER" && (e === "exit-ticket" && s !== "SystemIntro" ? n != null && n.submittedByStudent && !(n != null && n.validatedByTeacher) ? N("exit-ticket-review-available") : n != null && n.validatedByTeacher ? A() : N("exit-ticket-teacher-intervention") : o ? n != null && n.assignStatus ? A() : N("optional-items-assignment") : o || A());
|
|
209
207
|
}
|
|
210
208
|
}, [
|
|
211
209
|
a.teacherValidationEnabled,
|
|
212
|
-
|
|
210
|
+
A,
|
|
213
211
|
l,
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
]),
|
|
212
|
+
n,
|
|
213
|
+
r
|
|
214
|
+
]), T(() => {
|
|
217
215
|
if (a.teacherValidationEnabled && l) {
|
|
218
|
-
const { item_type: e, instructor_stimulus:
|
|
219
|
-
|
|
216
|
+
const { item_type: e, instructor_stimulus: s } = l;
|
|
217
|
+
r === "STUDENT" && e === "exit-ticket" && s !== "SystemIntro" && (n != null && n.submittedByStudent ? _ == null || _() : W == null || W());
|
|
220
218
|
}
|
|
221
219
|
}, [
|
|
222
220
|
a.teacherValidationEnabled,
|
|
223
221
|
l,
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
]),
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
i.length < 3 ? Y(`Diagnostics item has Less than 3 questions: ${e}`, {
|
|
232
|
-
tags: {
|
|
233
|
-
"content-type": "learnosity",
|
|
234
|
-
"activity-reference": E,
|
|
235
|
-
"item-reference": e
|
|
236
|
-
},
|
|
237
|
-
fingerprint: [`diagnostics-item-questions-count-${e}`]
|
|
238
|
-
// Add unique fingerprint
|
|
239
|
-
}) : (((n = i[0]) == null ? void 0 : n.instructor_stimulus) !== "Try" || ((d = i[1]) == null ? void 0 : d.instructor_stimulus) !== "Learn" || ((u = i[2]) == null ? void 0 : u.instructor_stimulus) !== "Apply") && Y(
|
|
240
|
-
`Diagnostics questions sequence is incorrect expected [Try, Learn, Apply]: ${e}`,
|
|
241
|
-
{
|
|
242
|
-
tags: {
|
|
243
|
-
"content-type": "learnosity",
|
|
244
|
-
"activity-reference": E,
|
|
245
|
-
"item-reference": e
|
|
246
|
-
},
|
|
247
|
-
fingerprint: [`diagnostics-item-questions-sequence-${e}`]
|
|
248
|
-
// Add unique fingerprint
|
|
249
|
-
}
|
|
250
|
-
);
|
|
251
|
-
});
|
|
252
|
-
}, [E, k, p]), b(() => {
|
|
253
|
-
t.forEach((e) => {
|
|
254
|
-
const { validation: i, item_reference: n, type: d, question_number: u, metadata: m } = e;
|
|
255
|
-
if ((j ? d !== "clozetext" : !0) && (i != null && i.valid_response)) {
|
|
256
|
-
const _ = i.valid_response.value ?? [];
|
|
257
|
-
(_ == null ? void 0 : _.length) === 0 && ((i.alt_responses ?? []).some((ut) => ut.value.length > 0) || (Y(`Question has no valid response: ${m.widget_reference}`, {
|
|
258
|
-
tags: {
|
|
259
|
-
"content-type": "learnosity",
|
|
260
|
-
"activity-reference": E,
|
|
261
|
-
"item-reference": n,
|
|
262
|
-
"question-number": u,
|
|
263
|
-
"widget-reference": m.widget_reference
|
|
264
|
-
},
|
|
265
|
-
fingerprint: [`no-valid-response-${m.widget_reference}`]
|
|
266
|
-
// Add unique fingerprint
|
|
267
|
-
}), w.current(vt.WORKSHEET_V3_QUESTION_MISSING_VALIDATION, {
|
|
268
|
-
item_reference: n,
|
|
269
|
-
widget_reference: m.widget_reference,
|
|
270
|
-
question_type: d,
|
|
271
|
-
question_number: u
|
|
272
|
-
})));
|
|
273
|
-
}
|
|
274
|
-
});
|
|
275
|
-
}, [E, w, t, j]), S ? /* @__PURE__ */ R(mt, { children: [
|
|
276
|
-
Ee && /* @__PURE__ */ R(
|
|
277
|
-
qt,
|
|
222
|
+
n == null ? void 0 : n.submittedByStudent,
|
|
223
|
+
W,
|
|
224
|
+
_,
|
|
225
|
+
r
|
|
226
|
+
]), p ? /* @__PURE__ */ y(lt, { children: [
|
|
227
|
+
Te && /* @__PURE__ */ y(
|
|
228
|
+
Mt,
|
|
278
229
|
{
|
|
279
230
|
$flexDirection: "row",
|
|
280
231
|
$justifyContent: "center",
|
|
281
232
|
$alignItems: "center",
|
|
282
233
|
$width: "100%",
|
|
283
234
|
$heightX: 1.75,
|
|
284
|
-
$height:
|
|
235
|
+
$height: me,
|
|
285
236
|
$gap: 8,
|
|
286
237
|
$gutter: 8,
|
|
287
238
|
$flexGap: 8,
|
|
288
|
-
$background:
|
|
289
|
-
$topOffset:
|
|
239
|
+
$background: it,
|
|
240
|
+
$topOffset: k.topOffset - me,
|
|
290
241
|
children: [
|
|
291
|
-
|
|
292
|
-
/* @__PURE__ */
|
|
242
|
+
J ? /* @__PURE__ */ i(fe, { children: /* @__PURE__ */ i(ht, { width: 16, height: 16 }) }) : /* @__PURE__ */ i(fe, { children: /* @__PURE__ */ i(ft, { width: 16, height: 16 }) }),
|
|
243
|
+
/* @__PURE__ */ i(bt, { $renderAs: "ub3", children: nt })
|
|
293
244
|
]
|
|
294
245
|
}
|
|
295
246
|
),
|
|
296
|
-
/* @__PURE__ */
|
|
297
|
-
|
|
298
|
-
|
|
247
|
+
/* @__PURE__ */ y(xt, { $background: "WHITE_1", $width: Ue, children: [
|
|
248
|
+
Ye === "top" && /* @__PURE__ */ i(Rt, { $topOffset: V, $height: It, children: /* @__PURE__ */ i(Pt, { children: /* @__PURE__ */ i(
|
|
249
|
+
Ot,
|
|
299
250
|
{
|
|
300
251
|
placement: "top",
|
|
301
252
|
questions: t,
|
|
302
253
|
responses: c,
|
|
303
|
-
activeQuestionIndex:
|
|
304
|
-
lastUnlockedQuestionIndex:
|
|
254
|
+
activeQuestionIndex: d,
|
|
255
|
+
lastUnlockedQuestionIndex: u,
|
|
305
256
|
behavior: a,
|
|
306
|
-
onItemNumberClick:
|
|
307
|
-
userType:
|
|
308
|
-
summaryVisible:
|
|
257
|
+
onItemNumberClick: M,
|
|
258
|
+
userType: r,
|
|
259
|
+
summaryVisible: h
|
|
309
260
|
}
|
|
310
261
|
) }) }),
|
|
311
|
-
|
|
312
|
-
|
|
262
|
+
re && l && /* @__PURE__ */ i(Qt, { $minHeight: ie, $topOffset: V, children: /* @__PURE__ */ i(de, { $width: z, $justifyContent: "center", $alignItems: "center", children: /* @__PURE__ */ i(
|
|
263
|
+
Et,
|
|
313
264
|
{
|
|
314
|
-
blocker:
|
|
265
|
+
blocker: re,
|
|
315
266
|
lastUnlockedQuestion: l,
|
|
316
|
-
studentName:
|
|
317
|
-
onBlockerClose:
|
|
267
|
+
studentName: be,
|
|
268
|
+
onBlockerClose: A,
|
|
318
269
|
onOptionalItemAssignment: we,
|
|
319
|
-
onOptionalItemSkip:
|
|
320
|
-
onTeacherValidation:
|
|
270
|
+
onOptionalItemSkip: Ee,
|
|
271
|
+
onTeacherValidation: Y
|
|
321
272
|
}
|
|
322
273
|
) }) }),
|
|
323
|
-
|
|
324
|
-
|
|
274
|
+
et && /* @__PURE__ */ i(
|
|
275
|
+
Ct,
|
|
325
276
|
{
|
|
326
|
-
activeQuestionIndex:
|
|
327
|
-
onClick:
|
|
277
|
+
activeQuestionIndex: d,
|
|
278
|
+
onClick: M,
|
|
328
279
|
questions: t,
|
|
329
|
-
bottomOffset:
|
|
330
|
-
topOffset:
|
|
331
|
-
userType:
|
|
280
|
+
bottomOffset: g,
|
|
281
|
+
topOffset: V,
|
|
282
|
+
userType: r
|
|
332
283
|
}
|
|
333
284
|
),
|
|
334
|
-
|
|
335
|
-
/* @__PURE__ */
|
|
336
|
-
|
|
285
|
+
se && /* @__PURE__ */ i(Gt, { children: /* @__PURE__ */ i(gt, { initialPosition: St, onClose: st }) }),
|
|
286
|
+
/* @__PURE__ */ y(
|
|
287
|
+
Ft,
|
|
337
288
|
{
|
|
338
|
-
$marginTop:
|
|
339
|
-
$height:
|
|
340
|
-
$isCardView:
|
|
341
|
-
$isPuzzleCard:
|
|
289
|
+
$marginTop: r === "TEACHER" && h ? "0" : g,
|
|
290
|
+
$height: g,
|
|
291
|
+
$isCardView: O === "card",
|
|
292
|
+
$isPuzzleCard: ne,
|
|
342
293
|
children: [
|
|
343
|
-
|
|
344
|
-
|
|
294
|
+
te !== -2 && /* @__PURE__ */ i(
|
|
295
|
+
vt,
|
|
345
296
|
{
|
|
346
|
-
width:
|
|
347
|
-
question: t[
|
|
348
|
-
learnosity:
|
|
349
|
-
userType:
|
|
297
|
+
width: L - 32,
|
|
298
|
+
question: t[d],
|
|
299
|
+
learnosity: p,
|
|
300
|
+
userType: r
|
|
350
301
|
}
|
|
351
302
|
),
|
|
352
|
-
|
|
353
|
-
|
|
303
|
+
qe && /* @__PURE__ */ i(
|
|
304
|
+
jt,
|
|
354
305
|
{
|
|
355
|
-
$height:
|
|
356
|
-
$width:
|
|
357
|
-
$isCardView:
|
|
358
|
-
children: /* @__PURE__ */
|
|
359
|
-
|
|
306
|
+
$height: g,
|
|
307
|
+
$width: O === "card" ? L - 32 : "100%",
|
|
308
|
+
$isCardView: O === "card",
|
|
309
|
+
children: /* @__PURE__ */ i(
|
|
310
|
+
de,
|
|
360
311
|
{
|
|
361
312
|
$gutterX: 1,
|
|
362
313
|
$flexDirection: "row",
|
|
363
314
|
$justifyContent: "space-between",
|
|
364
315
|
$alignItems: "center",
|
|
365
|
-
$width:
|
|
366
|
-
children: /* @__PURE__ */
|
|
367
|
-
|
|
316
|
+
$width: L - 32,
|
|
317
|
+
children: /* @__PURE__ */ i(
|
|
318
|
+
wt,
|
|
368
319
|
{
|
|
369
|
-
userType:
|
|
370
|
-
layout:
|
|
320
|
+
userType: r,
|
|
321
|
+
layout: k,
|
|
371
322
|
behavior: a,
|
|
372
|
-
worksheetName:
|
|
323
|
+
worksheetName: U,
|
|
373
324
|
questions: t,
|
|
374
325
|
responses: c,
|
|
375
|
-
onCalculatorOpen:
|
|
376
|
-
activeQuestionIndex:
|
|
377
|
-
lastUnlockedQuestionIndex:
|
|
378
|
-
appendedQuestionIds:
|
|
379
|
-
learnosity:
|
|
380
|
-
isCanvasEnabled:
|
|
381
|
-
canSubmitWorksheet:
|
|
382
|
-
isScribblingEnabled:
|
|
383
|
-
isSummaryVisible:
|
|
384
|
-
setResponses:
|
|
385
|
-
getTimeSpentOnQuestion:
|
|
386
|
-
setSummaryVisible:
|
|
387
|
-
setBlocker:
|
|
388
|
-
setIsScribblingEnabled:
|
|
389
|
-
setActiveQuestionId:
|
|
390
|
-
onItemNumberClick:
|
|
391
|
-
onGoToReview:
|
|
392
|
-
onResponseChange:
|
|
393
|
-
onHelp:
|
|
394
|
-
onTeacherValidation:
|
|
395
|
-
onSubmit:
|
|
396
|
-
showCalculator:
|
|
397
|
-
loggerRef:
|
|
398
|
-
onSkip:
|
|
399
|
-
onUnassign:
|
|
326
|
+
onCalculatorOpen: at,
|
|
327
|
+
activeQuestionIndex: d,
|
|
328
|
+
lastUnlockedQuestionIndex: u,
|
|
329
|
+
appendedQuestionIds: Z,
|
|
330
|
+
learnosity: p,
|
|
331
|
+
isCanvasEnabled: ee,
|
|
332
|
+
canSubmitWorksheet: xe,
|
|
333
|
+
isScribblingEnabled: oe,
|
|
334
|
+
isSummaryVisible: h,
|
|
335
|
+
setResponses: v,
|
|
336
|
+
getTimeSpentOnQuestion: ce,
|
|
337
|
+
setSummaryVisible: X,
|
|
338
|
+
setBlocker: N,
|
|
339
|
+
setIsScribblingEnabled: tt,
|
|
340
|
+
setActiveQuestionId: H,
|
|
341
|
+
onItemNumberClick: M,
|
|
342
|
+
onGoToReview: ct,
|
|
343
|
+
onResponseChange: f,
|
|
344
|
+
onHelp: Oe,
|
|
345
|
+
onTeacherValidation: Y,
|
|
346
|
+
onSubmit: Ne,
|
|
347
|
+
showCalculator: se,
|
|
348
|
+
loggerRef: j,
|
|
349
|
+
onSkip: Qe,
|
|
350
|
+
onUnassign: Ge,
|
|
400
351
|
onReview: Fe,
|
|
401
352
|
canToggleScribbling: je
|
|
402
353
|
}
|
|
@@ -405,99 +356,99 @@ const Yt = (Ie, Se) => {
|
|
|
405
356
|
)
|
|
406
357
|
}
|
|
407
358
|
),
|
|
408
|
-
!
|
|
359
|
+
!h && D && r === "STUDENT" && /* @__PURE__ */ i(zt, { children: /* @__PURE__ */ i(Vt, {}) })
|
|
409
360
|
]
|
|
410
361
|
}
|
|
411
362
|
),
|
|
412
|
-
/* @__PURE__ */
|
|
413
|
-
|
|
363
|
+
/* @__PURE__ */ y(
|
|
364
|
+
Lt,
|
|
414
365
|
{
|
|
415
|
-
$actionbarHeight:
|
|
416
|
-
$isCardView:
|
|
417
|
-
$isPuzzleCard:
|
|
366
|
+
$actionbarHeight: g,
|
|
367
|
+
$isCardView: O === "card",
|
|
368
|
+
$isPuzzleCard: ne,
|
|
418
369
|
children: [
|
|
419
|
-
|
|
420
|
-
(e,
|
|
421
|
-
var
|
|
422
|
-
const { response_id:
|
|
423
|
-
return a.teacherValidationEnabled && (
|
|
424
|
-
|
|
370
|
+
Wt({ questions: t, lastUnlockedQuestionIndex: u, userType: r }).map(
|
|
371
|
+
(e, s) => {
|
|
372
|
+
var C, B;
|
|
373
|
+
const { response_id: o, is_optional: b } = e, $ = (C = c[o]) == null ? void 0 : C.assignStatus;
|
|
374
|
+
return a.teacherValidationEnabled && ($ === "skipped" || b && $ !== "assigned" && r === "STUDENT") ? null : /* @__PURE__ */ i(
|
|
375
|
+
Dt,
|
|
425
376
|
{
|
|
426
|
-
signedRequest:
|
|
427
|
-
userType:
|
|
428
|
-
worksheetCompleted:
|
|
377
|
+
signedRequest: Ce,
|
|
378
|
+
userType: r,
|
|
379
|
+
worksheetCompleted: Ae,
|
|
429
380
|
question: e,
|
|
430
|
-
response: c[
|
|
431
|
-
nextQuestionId:
|
|
432
|
-
maxQuestionWidth:
|
|
433
|
-
learnosity:
|
|
434
|
-
isActive:
|
|
435
|
-
isHidden: !
|
|
436
|
-
canRender:
|
|
437
|
-
background:
|
|
438
|
-
appended:
|
|
381
|
+
response: c[o],
|
|
382
|
+
nextQuestionId: m === "ADAPTIVE" || m === "CURRENT" ? l == null ? void 0 : l.response_id : s < u ? (B = t[s + 1]) == null ? void 0 : B.response_id : void 0,
|
|
383
|
+
maxQuestionWidth: z,
|
|
384
|
+
learnosity: p,
|
|
385
|
+
isActive: o === E,
|
|
386
|
+
isHidden: !D && o !== E || h,
|
|
387
|
+
canRender: d > -1 && (s === d || m !== "CURRENT" && s === d + 1),
|
|
388
|
+
background: $e,
|
|
389
|
+
appended: Z.includes(o),
|
|
439
390
|
behavior: a,
|
|
440
|
-
layout:
|
|
441
|
-
actionbarHeight:
|
|
442
|
-
intersectionObserver:
|
|
443
|
-
onMarkForReview:
|
|
444
|
-
onMediaStateChange:
|
|
445
|
-
userId:
|
|
446
|
-
isScribblingEnabled:
|
|
447
|
-
onPublishStrokes:
|
|
448
|
-
onReceiveStrokes:
|
|
449
|
-
initialStrokesData:
|
|
450
|
-
isCanvasEnabled:
|
|
451
|
-
onPublishMouseMove:
|
|
452
|
-
onSubscribeMouseMove:
|
|
453
|
-
setActiveQuestionId:
|
|
454
|
-
canResolveDoubt:
|
|
455
|
-
onResolveDoubt:
|
|
456
|
-
studentId:
|
|
457
|
-
subjectiveProps:
|
|
391
|
+
layout: k,
|
|
392
|
+
actionbarHeight: g,
|
|
393
|
+
intersectionObserver: q,
|
|
394
|
+
onMarkForReview: rt,
|
|
395
|
+
onMediaStateChange: ot,
|
|
396
|
+
userId: Be,
|
|
397
|
+
isScribblingEnabled: oe,
|
|
398
|
+
onPublishStrokes: ye,
|
|
399
|
+
onReceiveStrokes: We,
|
|
400
|
+
initialStrokesData: _e,
|
|
401
|
+
isCanvasEnabled: ee,
|
|
402
|
+
onPublishMouseMove: De,
|
|
403
|
+
onSubscribeMouseMove: Ve,
|
|
404
|
+
setActiveQuestionId: H,
|
|
405
|
+
canResolveDoubt: Re,
|
|
406
|
+
onResolveDoubt: Pe,
|
|
407
|
+
studentId: ze,
|
|
408
|
+
subjectiveProps: Le,
|
|
458
409
|
responses: c,
|
|
459
|
-
loggerRef:
|
|
410
|
+
loggerRef: j
|
|
460
411
|
},
|
|
461
|
-
|
|
412
|
+
o
|
|
462
413
|
);
|
|
463
414
|
}
|
|
464
415
|
),
|
|
465
|
-
|
|
466
|
-
|
|
416
|
+
h && /* @__PURE__ */ i(
|
|
417
|
+
qt,
|
|
467
418
|
{
|
|
468
|
-
worksheetName:
|
|
419
|
+
worksheetName: U,
|
|
469
420
|
questions: t,
|
|
470
421
|
responses: c,
|
|
471
|
-
activeQuestionIndex:
|
|
472
|
-
lastUnlockedQuestionIndex:
|
|
473
|
-
onItemNumberClick:
|
|
422
|
+
activeQuestionIndex: d,
|
|
423
|
+
lastUnlockedQuestionIndex: u,
|
|
424
|
+
onItemNumberClick: M,
|
|
474
425
|
behavior: a,
|
|
475
|
-
minHeight:
|
|
476
|
-
summaryDescription:
|
|
477
|
-
summaryVisible:
|
|
426
|
+
minHeight: Je,
|
|
427
|
+
summaryDescription: Me,
|
|
428
|
+
summaryVisible: h
|
|
478
429
|
}
|
|
479
430
|
)
|
|
480
431
|
]
|
|
481
432
|
}
|
|
482
433
|
),
|
|
483
|
-
!
|
|
484
|
-
|
|
434
|
+
!h && Ze && /* @__PURE__ */ i(
|
|
435
|
+
Ht,
|
|
485
436
|
{
|
|
486
|
-
questionWidth:
|
|
437
|
+
questionWidth: z,
|
|
487
438
|
questions: t,
|
|
488
|
-
activeQuestionIndex:
|
|
489
|
-
learnosity:
|
|
490
|
-
userType:
|
|
491
|
-
height:
|
|
492
|
-
actionbarHeight:
|
|
439
|
+
activeQuestionIndex: d,
|
|
440
|
+
learnosity: p,
|
|
441
|
+
userType: r,
|
|
442
|
+
height: ie,
|
|
443
|
+
actionbarHeight: g,
|
|
493
444
|
openQuestionFeedbackModal: He,
|
|
494
|
-
loggerRef:
|
|
445
|
+
loggerRef: j
|
|
495
446
|
}
|
|
496
447
|
)
|
|
497
448
|
] })
|
|
498
449
|
] }) : null;
|
|
499
|
-
},
|
|
450
|
+
}, Ci = dt(mt(Xt));
|
|
500
451
|
export {
|
|
501
|
-
|
|
452
|
+
Ci as default
|
|
502
453
|
};
|
|
503
454
|
//# sourceMappingURL=worksheet.js.map
|