@instructure/platform-modules 1.2.0 → 1.3.0
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/adapters/canvasGraphql/index.d.ts +2 -6
- package/dist/adapters/canvasGraphql/index.d.ts.map +1 -1
- package/dist/adapters/canvasGraphql/normalize.d.ts +4 -9
- package/dist/adapters/canvasGraphql/normalize.d.ts.map +1 -1
- package/dist/adapters/canvasGraphql/queries.d.ts.map +1 -1
- package/dist/components/ModuleCard.d.ts.map +1 -1
- package/dist/components/ModuleCard.stories.d.ts +10 -2
- package/dist/components/ModuleCard.stories.d.ts.map +1 -1
- package/dist/components/ModuleItemRow.d.ts +7 -1
- package/dist/components/ModuleItemRow.d.ts.map +1 -1
- package/dist/components/ModulesList.d.ts.map +1 -1
- package/dist/components/ModulesList.stories.d.ts +5 -2
- package/dist/components/ModulesList.stories.d.ts.map +1 -1
- package/dist/components/index.d.ts +1 -2
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/labels.d.ts +1 -2
- package/dist/components/labels.d.ts.map +1 -1
- package/dist/components/storyThemes.d.ts +8 -0
- package/dist/components/storyThemes.d.ts.map +1 -0
- package/dist/config/filters.d.ts +1 -1
- package/dist/config/filters.d.ts.map +1 -1
- package/dist/config/useFormatters.d.ts +1 -0
- package/dist/config/useFormatters.d.ts.map +1 -1
- package/dist/fixtures/scenarios.d.ts.map +1 -1
- package/dist/hooks/useModulesPageData.d.ts +2 -0
- package/dist/hooks/useModulesPageData.d.ts.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1132 -1090
- package/dist/types/domain.d.ts +3 -1
- package/dist/types/domain.d.ts.map +1 -1
- package/dist/types/enums.d.ts +0 -4
- package/dist/types/enums.d.ts.map +1 -1
- package/dist/types/schemas.d.ts.map +1 -1
- package/locales/en.json +5 -4
- package/package.json +3 -1
- package/dist/components/ModuleNumberBadge.d.ts +0 -7
- package/dist/components/ModuleNumberBadge.d.ts.map +0 -1
- package/dist/components/lightThemeDecorator.d.ts +0 -3
- package/dist/components/lightThemeDecorator.d.ts.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import { z as
|
|
2
|
-
import { gql as
|
|
3
|
-
import { jsx as i, jsxs as
|
|
4
|
-
import { createContext as
|
|
5
|
-
import { PlugInstUIIcon as
|
|
6
|
-
import { useInfiniteQuery as
|
|
7
|
-
import
|
|
8
|
-
import { Button as
|
|
9
|
-
import { Flex as
|
|
1
|
+
import { z as d } from "zod";
|
|
2
|
+
import { gql as Me } from "graphql-tag";
|
|
3
|
+
import { jsx as i, jsxs as S, Fragment as it } from "react/jsx-runtime";
|
|
4
|
+
import { createContext as Pt, useContext as Ct, useMemo as N, isValidElement as wt, useCallback as F, useRef as $, useState as Le, useEffect as Ie, useId as vt, memo as Lt, Fragment as At } from "react";
|
|
5
|
+
import { PlugInstUIIcon as Pn, ExternalLinkInstUIIcon as Cn, FileInstUIIcon as wn, FileTextInstUIIcon as vn, MessagesSquareInstUIIcon as Ln, RocketInstUIIcon as An, FilePenLineInstUIIcon as Rn, LockInstUIIcon as Rt, TriangleAlertInstUIIcon as ge, CircleCheckInstUIIcon as xt, ClockFadingInstUIIcon as Nt, CornerDownRightInstUIIcon as xn, IconArrowOpenUpLine as Nn, IconArrowOpenDownLine as qt } from "@instructure/ui-icons";
|
|
6
|
+
import { useInfiniteQuery as Ke, useQueryClient as kt, InfiniteQueryObserver as qn } from "@tanstack/react-query";
|
|
7
|
+
import kn from "p-limit";
|
|
8
|
+
import { Button as he, IconButton as Dn } from "@instructure/ui-buttons/v11_7";
|
|
9
|
+
import { Flex as T } from "@instructure/ui-flex/v11_7";
|
|
10
10
|
import { Text as P } from "@instructure/ui-text/v11_7";
|
|
11
|
-
import { View as
|
|
12
|
-
import { TruncateWithTooltip as
|
|
13
|
-
import { Alert as
|
|
14
|
-
import { Heading as
|
|
15
|
-
import { ProgressBar as
|
|
16
|
-
import { Spinner as
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
const
|
|
25
|
-
target:
|
|
26
|
-
field:
|
|
27
|
-
op:
|
|
28
|
-
value:
|
|
11
|
+
import { View as E } from "@instructure/ui-view/v11_7";
|
|
12
|
+
import { TruncateWithTooltip as On, politeAnnounce as Dt, getLiveRegion as Ot } from "@instructure/platform-instui-bindings";
|
|
13
|
+
import { Alert as Ft } from "@instructure/ui-alerts/v11_7";
|
|
14
|
+
import { Heading as Ut } from "@instructure/ui-heading/v11_7";
|
|
15
|
+
import { ProgressBar as Fn } from "@instructure/ui-progress/v11_7";
|
|
16
|
+
import { Spinner as zt } from "@instructure/ui-spinner/v11_7";
|
|
17
|
+
import { Tooltip as Un } from "@instructure/ui-tooltip/v11_7";
|
|
18
|
+
import { useTheme as $t } from "@instructure/emotion";
|
|
19
|
+
import { ScreenReaderContent as lt } from "@instructure/ui-a11y-content";
|
|
20
|
+
import { Link as zn } from "@instructure/ui-link/v11_7";
|
|
21
|
+
import { Pill as $n } from "@instructure/ui-pill/v11_7";
|
|
22
|
+
import { WithBreakpoints as Bn } from "@instructure/platform-with-breakpoints";
|
|
23
|
+
import { Menu as $e } from "@instructure/ui-menu/v11_7";
|
|
24
|
+
const jn = d.object({
|
|
25
|
+
target: d.enum(["module", "item"]),
|
|
26
|
+
field: d.string(),
|
|
27
|
+
op: d.enum(["eq", "contains"]),
|
|
28
|
+
value: d.union([d.string(), d.boolean()])
|
|
29
29
|
}).strict();
|
|
30
|
-
function
|
|
30
|
+
function Gn(e, t) {
|
|
31
31
|
const n = e == null ? void 0 : e[t.target];
|
|
32
32
|
return !n || !Object.prototype.hasOwnProperty.call(n, t.field) ? !1 : n[t.field].includes(t.op);
|
|
33
33
|
}
|
|
34
|
-
const
|
|
34
|
+
const Yn = d.enum([
|
|
35
35
|
"assignment",
|
|
36
36
|
"quiz",
|
|
37
37
|
"discussion",
|
|
@@ -40,7 +40,7 @@ const kn = c.enum([
|
|
|
40
40
|
"external_url",
|
|
41
41
|
"external_tool",
|
|
42
42
|
"sub_header"
|
|
43
|
-
]),
|
|
43
|
+
]), Wn = d.enum(["not_started", "in_progress", "complete", "incomplete", "missing", "locked"]), Qn = d.enum([
|
|
44
44
|
"not_started",
|
|
45
45
|
"in_progress",
|
|
46
46
|
"complete",
|
|
@@ -48,7 +48,7 @@ const kn = c.enum([
|
|
|
48
48
|
"incomplete",
|
|
49
49
|
"missing_and_incomplete",
|
|
50
50
|
"locked"
|
|
51
|
-
]),
|
|
51
|
+
]), Hn = d.enum([
|
|
52
52
|
"must_view",
|
|
53
53
|
"must_mark_done",
|
|
54
54
|
"must_contribute",
|
|
@@ -56,96 +56,97 @@ const kn = c.enum([
|
|
|
56
56
|
"min_score",
|
|
57
57
|
"min_percentage",
|
|
58
58
|
"unknown"
|
|
59
|
-
]),
|
|
60
|
-
status:
|
|
61
|
-
requirementsMet:
|
|
62
|
-
requirementCount:
|
|
63
|
-
percentComplete:
|
|
64
|
-
|
|
65
|
-
missingCount:
|
|
66
|
-
incompleteCount:
|
|
67
|
-
}),
|
|
68
|
-
itemId:
|
|
69
|
-
type:
|
|
70
|
-
minScore:
|
|
71
|
-
minPercentage:
|
|
72
|
-
}),
|
|
73
|
-
id:
|
|
74
|
-
moduleId:
|
|
75
|
-
title:
|
|
76
|
-
type:
|
|
77
|
-
position:
|
|
78
|
-
indent:
|
|
79
|
-
published:
|
|
80
|
-
url:
|
|
81
|
-
newTab:
|
|
82
|
-
completionRequirement:
|
|
83
|
-
dueAt:
|
|
84
|
-
status:
|
|
85
|
-
pointsPossible:
|
|
86
|
-
extensions:
|
|
87
|
-
}),
|
|
88
|
-
id:
|
|
89
|
-
name:
|
|
90
|
-
}),
|
|
91
|
-
id:
|
|
92
|
-
name:
|
|
93
|
-
position:
|
|
94
|
-
published:
|
|
95
|
-
itemCount:
|
|
96
|
-
items:
|
|
97
|
-
unlockAt:
|
|
98
|
-
prerequisiteModules:
|
|
99
|
-
requirementCount:
|
|
100
|
-
requireSequentialProgress:
|
|
101
|
-
completionRequirements:
|
|
102
|
-
progress:
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
59
|
+
]), Vn = d.object({
|
|
60
|
+
status: Qn.optional(),
|
|
61
|
+
requirementsMet: d.number(),
|
|
62
|
+
requirementCount: d.number(),
|
|
63
|
+
percentComplete: d.number().min(0).max(100),
|
|
64
|
+
nextDueAt: d.string().nullish(),
|
|
65
|
+
missingCount: d.number(),
|
|
66
|
+
incompleteCount: d.number()
|
|
67
|
+
}), Bt = d.object({
|
|
68
|
+
itemId: d.string(),
|
|
69
|
+
type: Hn,
|
|
70
|
+
minScore: d.number().nullish(),
|
|
71
|
+
minPercentage: d.number().nullish()
|
|
72
|
+
}), jt = d.object({
|
|
73
|
+
id: d.string(),
|
|
74
|
+
moduleId: d.string(),
|
|
75
|
+
title: d.string(),
|
|
76
|
+
type: Yn,
|
|
77
|
+
position: d.number(),
|
|
78
|
+
indent: d.number(),
|
|
79
|
+
published: d.boolean(),
|
|
80
|
+
url: d.string().nullish(),
|
|
81
|
+
newTab: d.boolean().nullish(),
|
|
82
|
+
completionRequirement: Bt.nullish(),
|
|
83
|
+
dueAt: d.string().nullish(),
|
|
84
|
+
status: Wn.optional(),
|
|
85
|
+
pointsPossible: d.number().nullish(),
|
|
86
|
+
extensions: d.record(d.unknown()).optional()
|
|
87
|
+
}), Kn = d.object({
|
|
88
|
+
id: d.string(),
|
|
89
|
+
name: d.string()
|
|
90
|
+
}), Zn = d.object({
|
|
91
|
+
id: d.string(),
|
|
92
|
+
name: d.string(),
|
|
93
|
+
position: d.number(),
|
|
94
|
+
published: d.boolean(),
|
|
95
|
+
itemCount: d.number(),
|
|
96
|
+
items: d.array(jt).optional(),
|
|
97
|
+
unlockAt: d.string().nullish(),
|
|
98
|
+
prerequisiteModules: d.array(Kn),
|
|
99
|
+
requirementCount: d.number().nullish(),
|
|
100
|
+
requireSequentialProgress: d.boolean(),
|
|
101
|
+
completionRequirements: d.array(Bt).optional(),
|
|
102
|
+
progress: Vn.optional(),
|
|
103
|
+
collapsed: d.boolean().nullish(),
|
|
104
|
+
extensions: d.record(d.unknown()).optional()
|
|
105
|
+
}), Gt = d.object({
|
|
106
|
+
hasNextPage: d.boolean(),
|
|
107
|
+
endCursor: d.string().nullable()
|
|
107
108
|
}).refine((e) => !e.hasNextPage || e.endCursor !== null, {
|
|
108
109
|
message: 'hasNextPage is true but endCursor is null: there is another page and no cursor to ask for it with, which renders a "Load more" that can never load.',
|
|
109
110
|
path: ["endCursor"]
|
|
110
|
-
}),
|
|
111
|
-
modules:
|
|
112
|
-
pageInfo:
|
|
113
|
-
}),
|
|
114
|
-
items:
|
|
115
|
-
pageInfo:
|
|
116
|
-
}),
|
|
117
|
-
function
|
|
111
|
+
}), Xn = d.object({
|
|
112
|
+
modules: d.array(Zn),
|
|
113
|
+
pageInfo: Gt
|
|
114
|
+
}), Jn = d.object({
|
|
115
|
+
items: d.array(jt),
|
|
116
|
+
pageInfo: Gt
|
|
117
|
+
}), Yt = "career.estimatedDurationMinutes";
|
|
118
|
+
function eo(e) {
|
|
118
119
|
var n;
|
|
119
|
-
const t = (n = e.extensions) == null ? void 0 : n[
|
|
120
|
+
const t = (n = e.extensions) == null ? void 0 : n[Yt];
|
|
120
121
|
return typeof t != "number" || !Number.isFinite(t) || t <= 0 ? null : t;
|
|
121
122
|
}
|
|
122
|
-
function
|
|
123
|
-
return t == null ? e : { ...e, [
|
|
123
|
+
function Ze(e, t) {
|
|
124
|
+
return t == null ? e : { ...e, [Yt]: t };
|
|
124
125
|
}
|
|
125
|
-
const
|
|
126
|
-
class
|
|
126
|
+
const Ge = 100, Xe = 2e3;
|
|
127
|
+
class to extends Error {
|
|
127
128
|
constructor(t, n) {
|
|
128
129
|
super(
|
|
129
130
|
`This in-memory adapter was built for course ${t} but was asked for course ${n}. A fixture serves exactly one course.`
|
|
130
131
|
), this.name = "InMemoryCourseMismatchError", this.expected = t, this.received = n;
|
|
131
132
|
}
|
|
132
133
|
}
|
|
133
|
-
const
|
|
134
|
+
const no = (e) => `offset:${e}`, oo = (e) => {
|
|
134
135
|
if (!e) return 0;
|
|
135
136
|
const t = Number.parseInt(e.replace("offset:", ""), 10);
|
|
136
137
|
return Number.isFinite(t) && t >= 0 ? t : 0;
|
|
137
|
-
},
|
|
138
|
+
}, at = (e) => {
|
|
138
139
|
if (e != null && e.aborted)
|
|
139
140
|
throw new DOMException("The operation was aborted.", "AbortError");
|
|
140
141
|
};
|
|
141
|
-
function
|
|
142
|
-
const o =
|
|
142
|
+
function ut(e, t, n) {
|
|
143
|
+
const o = oo(t), r = e.slice(o, o + n), s = o + r.length, l = s < e.length;
|
|
143
144
|
return {
|
|
144
145
|
slice: r,
|
|
145
|
-
pageInfo: { hasNextPage: l, endCursor: l ?
|
|
146
|
+
pageInfo: { hasNextPage: l, endCursor: l ? no(s) : null }
|
|
146
147
|
};
|
|
147
148
|
}
|
|
148
|
-
const
|
|
149
|
+
const ro = /* @__PURE__ */ new Map([
|
|
149
150
|
["COMPLETED", (e) => {
|
|
150
151
|
var t;
|
|
151
152
|
return ((t = e.progress) == null ? void 0 : t.status) === "complete";
|
|
@@ -165,39 +166,39 @@ const Vn = /* @__PURE__ */ new Map([
|
|
|
165
166
|
return ((t = e.progress) == null ? void 0 : t.status) !== "complete" && ((n = e.progress) == null ? void 0 : n.status) !== "in_progress";
|
|
166
167
|
}
|
|
167
168
|
]
|
|
168
|
-
]),
|
|
169
|
-
function
|
|
169
|
+
]), so = { module: { completionStatus: ["eq"] } };
|
|
170
|
+
function io(e) {
|
|
170
171
|
if (e.target !== "module" || e.field !== "completionStatus" || e.op !== "eq")
|
|
171
172
|
throw new Error(
|
|
172
173
|
`in-memory adapter cannot compile ${e.target}.${e.field} ${e.op}`
|
|
173
174
|
);
|
|
174
|
-
const t = typeof e.value == "string" ?
|
|
175
|
+
const t = typeof e.value == "string" ? ro.get(e.value) : void 0;
|
|
175
176
|
if (!t) throw new Error(`unknown completionStatus "${String(e.value)}"`);
|
|
176
177
|
return t;
|
|
177
178
|
}
|
|
178
|
-
function
|
|
179
|
+
function xl(e, t = {}) {
|
|
179
180
|
const n = (r) => e.itemsByModuleId[r] ?? [], o = (r) => {
|
|
180
181
|
if (r !== e.courseId)
|
|
181
|
-
throw new
|
|
182
|
+
throw new to(e.courseId, r);
|
|
182
183
|
};
|
|
183
184
|
return {
|
|
184
|
-
capabilities:
|
|
185
|
+
capabilities: so,
|
|
185
186
|
async listModules({
|
|
186
187
|
courseId: r,
|
|
187
188
|
cursor: s,
|
|
188
189
|
pageSize: l,
|
|
189
190
|
includeItems: a,
|
|
190
191
|
filter: m,
|
|
191
|
-
inlineItemsFirst:
|
|
192
|
+
inlineItemsFirst: c,
|
|
192
193
|
signal: u
|
|
193
194
|
}) {
|
|
194
|
-
var
|
|
195
|
-
|
|
196
|
-
const p = m ? e.modules.filter(
|
|
197
|
-
return { modules: f.map((
|
|
198
|
-
const
|
|
199
|
-
return { ...
|
|
200
|
-
}), pageInfo:
|
|
195
|
+
var _;
|
|
196
|
+
at(u), o(r), (_ = t.onRequest) == null || _.call(t, "listModules", { operation: "listModules", courseId: r });
|
|
197
|
+
const p = m ? e.modules.filter(io(m)) : e.modules, { slice: f, pageInfo: y } = ut(p, s, l), g = Math.min(c ?? Ge, Ge);
|
|
198
|
+
return { modules: f.map((C) => {
|
|
199
|
+
const b = n(C.id), w = a && b.length <= g;
|
|
200
|
+
return { ...C, itemCount: b.length, items: w ? b : void 0 };
|
|
201
|
+
}), pageInfo: y };
|
|
201
202
|
},
|
|
202
203
|
async listModuleItems({
|
|
203
204
|
courseId: r,
|
|
@@ -207,13 +208,13 @@ function yl(e, t = {}) {
|
|
|
207
208
|
signal: m
|
|
208
209
|
}) {
|
|
209
210
|
var p;
|
|
210
|
-
|
|
211
|
-
const { slice:
|
|
212
|
-
return { items:
|
|
211
|
+
at(m), o(r), (p = t.onRequest) == null || p.call(t, "listModuleItems", { operation: "listModuleItems", courseId: r, moduleId: s });
|
|
212
|
+
const { slice: c, pageInfo: u } = ut(n(s), l, a);
|
|
213
|
+
return { items: c, pageInfo: u };
|
|
213
214
|
}
|
|
214
215
|
};
|
|
215
216
|
}
|
|
216
|
-
class
|
|
217
|
+
class Wt extends Error {
|
|
217
218
|
constructor(t, n, o) {
|
|
218
219
|
const r = t === "module" ? "module" : "module item";
|
|
219
220
|
super(
|
|
@@ -221,11 +222,11 @@ class zt extends Error {
|
|
|
221
222
|
), this.name = "PartialCanvasResponseError", this.subject = t, this.id = n, this.field = o;
|
|
222
223
|
}
|
|
223
224
|
}
|
|
224
|
-
function
|
|
225
|
+
function Qt(e, t, n) {
|
|
225
226
|
if (e != null) return e;
|
|
226
|
-
throw new
|
|
227
|
+
throw new Wt(t, n, "published");
|
|
227
228
|
}
|
|
228
|
-
function
|
|
229
|
+
function lo(e, t) {
|
|
229
230
|
if (e.onUnsupportedItem) {
|
|
230
231
|
e.onUnsupportedItem(t);
|
|
231
232
|
return;
|
|
@@ -234,7 +235,7 @@ function Xn(e, t) {
|
|
|
234
235
|
`[platform-modules] dropped module item ${t.id}: content type "${t.typename ?? "null"}" is outside the closed ModuleItemType enum. Pass \`onUnsupportedItem\` to handle these yourself.`
|
|
235
236
|
);
|
|
236
237
|
}
|
|
237
|
-
const
|
|
238
|
+
const ao = {
|
|
238
239
|
Assignment: "assignment",
|
|
239
240
|
Quiz: "quiz",
|
|
240
241
|
Discussion: "discussion",
|
|
@@ -246,21 +247,21 @@ const Jn = {
|
|
|
246
247
|
SubHeader: "sub_header",
|
|
247
248
|
PeerReviewSubAssignment: "assignment"
|
|
248
249
|
};
|
|
249
|
-
function
|
|
250
|
+
function uo(e) {
|
|
250
251
|
const t = e == null ? void 0 : e.__typename;
|
|
251
252
|
if (!t) return null;
|
|
252
|
-
const n =
|
|
253
|
+
const n = ao[t];
|
|
253
254
|
return n ? n === "assignment" && (e == null ? void 0 : e.isNewQuiz) === !0 ? "quiz" : n : null;
|
|
254
255
|
}
|
|
255
|
-
const
|
|
256
|
-
function
|
|
256
|
+
const co = /^P(?!$)(?:(\d+(?:\.\d+)?)W)?(?:(\d+(?:\.\d+)?)D)?(?:T(?!$)(?:(\d+(?:\.\d+)?)H)?(?:(\d+(?:\.\d+)?)M)?(?:(\d+(?:\.\d+)?)S)?)?$/;
|
|
257
|
+
function mo(e) {
|
|
257
258
|
if (!e) return null;
|
|
258
|
-
const t =
|
|
259
|
+
const t = co.exec(e);
|
|
259
260
|
if (!t) return null;
|
|
260
261
|
const [, n, o, r, s, l] = t, a = Number(n ?? 0) * 7 * 24 * 60 + Number(o ?? 0) * 24 * 60 + Number(r ?? 0) * 60 + Number(s ?? 0) + Number(l ?? 0) / 60;
|
|
261
262
|
return Math.round(a);
|
|
262
263
|
}
|
|
263
|
-
const
|
|
264
|
+
const po = /* @__PURE__ */ new Set([
|
|
264
265
|
"must_view",
|
|
265
266
|
"must_mark_done",
|
|
266
267
|
"must_contribute",
|
|
@@ -268,31 +269,31 @@ const oo = /* @__PURE__ */ new Set([
|
|
|
268
269
|
"min_score",
|
|
269
270
|
"min_percentage"
|
|
270
271
|
]);
|
|
271
|
-
function
|
|
272
|
-
return
|
|
272
|
+
function fo(e) {
|
|
273
|
+
return po.has(e) ? e : "unknown";
|
|
273
274
|
}
|
|
274
|
-
function
|
|
275
|
+
function go(e) {
|
|
275
276
|
return {
|
|
276
277
|
itemId: String(e.id),
|
|
277
|
-
type:
|
|
278
|
+
type: fo(e.type),
|
|
278
279
|
minScore: e.minScore ?? null,
|
|
279
280
|
minPercentage: e.minPercentage ?? null
|
|
280
281
|
};
|
|
281
282
|
}
|
|
282
|
-
function
|
|
283
|
+
function Ht(e) {
|
|
283
284
|
return {
|
|
284
285
|
hasNextPage: (e == null ? void 0 : e.hasNextPage) ?? !1,
|
|
285
286
|
endCursor: (e == null ? void 0 : e.endCursor) ?? null
|
|
286
287
|
};
|
|
287
288
|
}
|
|
288
|
-
const
|
|
289
|
-
function
|
|
289
|
+
const ho = /* @__PURE__ */ new Set(["min_score", "min_percentage"]);
|
|
290
|
+
function Io(e) {
|
|
290
291
|
var t;
|
|
291
292
|
for (const n of ((t = e == null ? void 0 : e.submissionsConnection) == null ? void 0 : t.nodes) ?? [])
|
|
292
293
|
if (n) return n;
|
|
293
294
|
return null;
|
|
294
295
|
}
|
|
295
|
-
function
|
|
296
|
+
function Vt(e, t) {
|
|
296
297
|
if (!e) return;
|
|
297
298
|
const n = new Map(t.map((s) => [s.itemId, s.type])), o = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Map();
|
|
298
299
|
for (const s of e.requirementsMet ?? []) {
|
|
@@ -303,7 +304,7 @@ function Gt(e, t) {
|
|
|
303
304
|
for (const s of e.incompleteRequirements ?? []) {
|
|
304
305
|
if (!s) continue;
|
|
305
306
|
const l = String(s.id);
|
|
306
|
-
n.get(l) === s.type &&
|
|
307
|
+
n.get(l) === s.type && ho.has(s.type) && r.set(l, s.score ?? null);
|
|
307
308
|
}
|
|
308
309
|
return {
|
|
309
310
|
locked: e.locked === !0 || e.workflowState === "locked",
|
|
@@ -314,14 +315,19 @@ function Gt(e, t) {
|
|
|
314
315
|
incompleteRequirementScores: r
|
|
315
316
|
};
|
|
316
317
|
}
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
318
|
+
const bo = {
|
|
319
|
+
LOCKED: "locked",
|
|
320
|
+
MISSING: "missing",
|
|
321
|
+
INCOMPLETE: "incomplete",
|
|
322
|
+
COMPLETE: "complete",
|
|
323
|
+
IN_PROGRESS: "in_progress",
|
|
324
|
+
NOT_STARTED: "not_started"
|
|
325
|
+
};
|
|
326
|
+
function Mo(e) {
|
|
327
|
+
if (e != null)
|
|
328
|
+
return bo[e];
|
|
323
329
|
}
|
|
324
|
-
const
|
|
330
|
+
const yo = {
|
|
325
331
|
LOCKED: "locked",
|
|
326
332
|
MISSING: "missing",
|
|
327
333
|
MISSING_AND_INCOMPLETE: "missing_and_incomplete",
|
|
@@ -330,32 +336,32 @@ const ao = {
|
|
|
330
336
|
IN_PROGRESS: "in_progress",
|
|
331
337
|
NOT_STARTED: "not_started"
|
|
332
338
|
};
|
|
333
|
-
function
|
|
339
|
+
function So(e) {
|
|
334
340
|
if (e != null)
|
|
335
|
-
return
|
|
341
|
+
return yo[e];
|
|
336
342
|
}
|
|
337
|
-
function
|
|
343
|
+
function _o(e, t, n) {
|
|
338
344
|
var a, m;
|
|
339
345
|
if (!n) return;
|
|
340
346
|
const o = e.requirementCount ?? t.length, r = Math.min(n.requirementsMetItemIds.size, o), s = ((a = e.submissionStatistics) == null ? void 0 : a.missingAssignmentCount) ?? 0, l = [...n.incompleteRequirementScores.values()].filter(
|
|
341
|
-
(
|
|
347
|
+
(c) => c != null
|
|
342
348
|
).length;
|
|
343
349
|
return {
|
|
344
|
-
status:
|
|
350
|
+
status: So(e.moduleStatus) ?? (n.locked ? "locked" : void 0),
|
|
345
351
|
requirementsMet: r,
|
|
346
352
|
requirementCount: o,
|
|
347
353
|
percentComplete: o > 0 ? Math.round(r / o * 100) : 0,
|
|
348
|
-
|
|
354
|
+
nextDueAt: ((m = e.submissionStatistics) == null ? void 0 : m.nextDueAt) ?? null,
|
|
349
355
|
missingCount: s,
|
|
350
356
|
incompleteCount: l
|
|
351
357
|
};
|
|
352
358
|
}
|
|
353
|
-
function
|
|
354
|
-
var
|
|
355
|
-
const s = String(e._id), l =
|
|
359
|
+
function To(e, t, n, o = {}, r) {
|
|
360
|
+
var c, u, p;
|
|
361
|
+
const s = String(e._id), l = uo(e.content);
|
|
356
362
|
if (!l)
|
|
357
|
-
return
|
|
358
|
-
const a =
|
|
363
|
+
return lo(o, { id: s, typename: ((c = e.content) == null ? void 0 : c.__typename) ?? null }), null;
|
|
364
|
+
const a = Io(e.content), m = n.get(s) ?? null;
|
|
359
365
|
return {
|
|
360
366
|
id: s,
|
|
361
367
|
moduleId: t,
|
|
@@ -363,24 +369,24 @@ function mo(e, t, n, o = {}, r) {
|
|
|
363
369
|
type: l,
|
|
364
370
|
position: e.position ?? 0,
|
|
365
371
|
indent: e.indent ?? 0,
|
|
366
|
-
published:
|
|
372
|
+
published: Qt(e.published, "moduleItem", s),
|
|
367
373
|
url: e.url ?? null,
|
|
368
374
|
newTab: e.newTab ?? !1,
|
|
369
375
|
completionRequirement: m,
|
|
370
376
|
dueAt: (a == null ? void 0 : a.cachedDueDate) ?? ((u = e.content) == null ? void 0 : u.dueAt) ?? null,
|
|
371
|
-
status: r ?
|
|
377
|
+
status: r ? Mo(e.moduleItemStatus) ?? (r.locked ? "locked" : void 0) : void 0,
|
|
372
378
|
pointsPossible: ((p = e.content) == null ? void 0 : p.pointsPossible) ?? null,
|
|
373
|
-
extensions:
|
|
379
|
+
extensions: Ze(
|
|
374
380
|
void 0,
|
|
375
|
-
|
|
381
|
+
mo(e.estimatedDuration)
|
|
376
382
|
)
|
|
377
383
|
};
|
|
378
384
|
}
|
|
379
|
-
function
|
|
385
|
+
function Kt(e, t, n, o, r) {
|
|
380
386
|
const s = [];
|
|
381
387
|
for (const l of e ?? []) {
|
|
382
388
|
if (!l) continue;
|
|
383
|
-
const a =
|
|
389
|
+
const a = To(
|
|
384
390
|
l,
|
|
385
391
|
t,
|
|
386
392
|
n,
|
|
@@ -391,59 +397,59 @@ function Yt(e, t, n, o, r) {
|
|
|
391
397
|
}
|
|
392
398
|
return s;
|
|
393
399
|
}
|
|
394
|
-
function
|
|
400
|
+
function Zt(e) {
|
|
395
401
|
const t = [], n = /* @__PURE__ */ new Map();
|
|
396
402
|
for (const o of e ?? []) {
|
|
397
403
|
if (!o) continue;
|
|
398
|
-
const r =
|
|
404
|
+
const r = go(o);
|
|
399
405
|
t.push(r), n.set(r.itemId, r);
|
|
400
406
|
}
|
|
401
407
|
return { list: t, byItemId: n };
|
|
402
408
|
}
|
|
403
|
-
function
|
|
404
|
-
var
|
|
409
|
+
function Eo(e, t = {}) {
|
|
410
|
+
var c, u;
|
|
405
411
|
const n = String(e._id);
|
|
406
412
|
if (e.moduleItemsTotalCount == null)
|
|
407
|
-
throw new
|
|
408
|
-
const { list: o, byItemId: r } =
|
|
413
|
+
throw new Wt("module", n, "moduleItemsTotalCount");
|
|
414
|
+
const { list: o, byItemId: r } = Zt(e.completionRequirements), s = e.moduleItemsConnection, l = s != null && !((c = s.pageInfo) != null && c.hasNextPage), a = Vt(e.progression, o), m = l ? Kt(s.nodes, n, r, t, a) : void 0;
|
|
409
415
|
return {
|
|
410
416
|
id: n,
|
|
411
417
|
name: e.name ?? "",
|
|
412
418
|
position: e.position ?? 0,
|
|
413
|
-
published:
|
|
419
|
+
published: Qt(e.published, "module", n),
|
|
414
420
|
itemCount: e.moduleItemsTotalCount,
|
|
415
421
|
items: m,
|
|
416
422
|
unlockAt: e.unlockAt ?? null,
|
|
417
423
|
prerequisiteModules: (e.prerequisites ?? []).filter(
|
|
418
|
-
(
|
|
419
|
-
).map((
|
|
424
|
+
(p) => p != null
|
|
425
|
+
).map((p) => ({ id: String(p.id), name: p.name ?? "" })),
|
|
420
426
|
requirementCount: e.requirementCount ?? null,
|
|
421
427
|
requireSequentialProgress: e.requireSequentialProgress ?? !1,
|
|
422
428
|
completionRequirements: o,
|
|
423
|
-
progress:
|
|
429
|
+
progress: _o(e, o, a),
|
|
430
|
+
collapsed: ((u = e.progression) == null ? void 0 : u.collapsed) ?? null
|
|
424
431
|
};
|
|
425
432
|
}
|
|
426
|
-
function
|
|
433
|
+
function Po(e, t = {}) {
|
|
427
434
|
var r;
|
|
428
435
|
const n = (r = e == null ? void 0 : e.legacyNode) == null ? void 0 : r.modulesConnection, o = [];
|
|
429
436
|
for (const s of (n == null ? void 0 : n.nodes) ?? [])
|
|
430
|
-
s && o.push(
|
|
431
|
-
return { modules: o, pageInfo:
|
|
437
|
+
s && o.push(Eo(s, t));
|
|
438
|
+
return { modules: o, pageInfo: Ht(n == null ? void 0 : n.pageInfo) };
|
|
432
439
|
}
|
|
433
|
-
function
|
|
434
|
-
const o = e == null ? void 0 : e.legacyNode, { list: r, byItemId: s } =
|
|
440
|
+
function Co(e, t, n = {}) {
|
|
441
|
+
const o = e == null ? void 0 : e.legacyNode, { list: r, byItemId: s } = Zt(o == null ? void 0 : o.completionRequirements), l = o == null ? void 0 : o.moduleItemsConnection, a = Vt(o == null ? void 0 : o.progression, r);
|
|
435
442
|
return {
|
|
436
|
-
items:
|
|
437
|
-
pageInfo:
|
|
443
|
+
items: Kt(l == null ? void 0 : l.nodes, t, s, n, a),
|
|
444
|
+
pageInfo: Ht(l == null ? void 0 : l.pageInfo)
|
|
438
445
|
};
|
|
439
446
|
}
|
|
440
|
-
const
|
|
447
|
+
const wo = Me`
|
|
441
448
|
fragment PlatformModulesSubmissionFields on Submission {
|
|
442
449
|
_id
|
|
443
|
-
missing
|
|
444
450
|
cachedDueDate
|
|
445
451
|
}
|
|
446
|
-
`,
|
|
452
|
+
`, Xt = Me`
|
|
447
453
|
fragment PlatformModulesItemFields on ModuleItem {
|
|
448
454
|
_id
|
|
449
455
|
title
|
|
@@ -453,6 +459,7 @@ const ho = ge`
|
|
|
453
459
|
indent
|
|
454
460
|
published
|
|
455
461
|
estimatedDuration
|
|
462
|
+
moduleItemStatus
|
|
456
463
|
content {
|
|
457
464
|
__typename
|
|
458
465
|
pointsPossible
|
|
@@ -490,8 +497,8 @@ const ho = ge`
|
|
|
490
497
|
}
|
|
491
498
|
}
|
|
492
499
|
}
|
|
493
|
-
${
|
|
494
|
-
`,
|
|
500
|
+
${wo}
|
|
501
|
+
`, Jt = Me`
|
|
495
502
|
fragment PlatformModulesProgressionFields on ModuleProgression {
|
|
496
503
|
workflowState
|
|
497
504
|
completed
|
|
@@ -511,7 +518,7 @@ const ho = ge`
|
|
|
511
518
|
score
|
|
512
519
|
}
|
|
513
520
|
}
|
|
514
|
-
`,
|
|
521
|
+
`, vo = Me`
|
|
515
522
|
query PlatformModulesGetModules(
|
|
516
523
|
$courseId: ID!
|
|
517
524
|
$first: Int!
|
|
@@ -546,10 +553,11 @@ const ho = ge`
|
|
|
546
553
|
minPercentage
|
|
547
554
|
}
|
|
548
555
|
progression {
|
|
556
|
+
collapsed
|
|
549
557
|
...PlatformModulesProgressionFields
|
|
550
558
|
}
|
|
551
559
|
submissionStatistics {
|
|
552
|
-
|
|
560
|
+
nextDueAt
|
|
553
561
|
missingAssignmentCount
|
|
554
562
|
}
|
|
555
563
|
moduleItemsConnection(first: $itemsFirst) @include(if: $includeItems) {
|
|
@@ -570,9 +578,9 @@ const ho = ge`
|
|
|
570
578
|
}
|
|
571
579
|
}
|
|
572
580
|
}
|
|
573
|
-
${
|
|
574
|
-
${
|
|
575
|
-
`,
|
|
581
|
+
${Xt}
|
|
582
|
+
${Jt}
|
|
583
|
+
`, Lo = Me`
|
|
576
584
|
query PlatformModulesGetModuleItems(
|
|
577
585
|
$moduleId: ID!
|
|
578
586
|
$first: Int!
|
|
@@ -603,93 +611,93 @@ const ho = ge`
|
|
|
603
611
|
}
|
|
604
612
|
}
|
|
605
613
|
}
|
|
606
|
-
${
|
|
607
|
-
${
|
|
614
|
+
${Xt}
|
|
615
|
+
${Jt}
|
|
608
616
|
`;
|
|
609
|
-
function
|
|
617
|
+
function en() {
|
|
610
618
|
return new DOMException("The operation was aborted.", "AbortError");
|
|
611
619
|
}
|
|
612
620
|
function Ce(e) {
|
|
613
|
-
if (e != null && e.aborted) throw
|
|
621
|
+
if (e != null && e.aborted) throw en();
|
|
614
622
|
}
|
|
615
|
-
function
|
|
623
|
+
function ct(e, t) {
|
|
616
624
|
return t ? new Promise((n, o) => {
|
|
617
|
-
const r = () => o(
|
|
625
|
+
const r = () => o(en());
|
|
618
626
|
t.addEventListener("abort", r, { once: !0 }), e.then(n, o).finally(() => t.removeEventListener("abort", r));
|
|
619
627
|
}) : e;
|
|
620
628
|
}
|
|
621
|
-
const
|
|
629
|
+
const dt = [
|
|
622
630
|
"COMPLETED",
|
|
623
631
|
"INCOMPLETE",
|
|
624
632
|
"IN_PROGRESS",
|
|
625
633
|
"NOT_STARTED"
|
|
626
|
-
],
|
|
634
|
+
], Ao = {
|
|
627
635
|
module: { completionStatus: ["eq"] }
|
|
628
636
|
};
|
|
629
|
-
function
|
|
637
|
+
function Ro(e) {
|
|
630
638
|
if (!e) return null;
|
|
631
639
|
if (e.target !== "module" || e.field !== "completionStatus" || e.op !== "eq")
|
|
632
640
|
throw new Error(
|
|
633
641
|
`Canvas GraphQL cannot serve ${e.target}.${e.field} "${e.op}". Only module.completionStatus eq is compiled here.`
|
|
634
642
|
);
|
|
635
643
|
const t = e.value;
|
|
636
|
-
if (!
|
|
644
|
+
if (!dt.includes(t))
|
|
637
645
|
throw new Error(
|
|
638
|
-
`"${e.value}" is not a ModuleCompletionStatus (${
|
|
646
|
+
`"${e.value}" is not a ModuleCompletionStatus (${dt.join(", ")}).`
|
|
639
647
|
);
|
|
640
648
|
return { completionStatus: t };
|
|
641
649
|
}
|
|
642
|
-
function
|
|
650
|
+
function Nl({
|
|
643
651
|
executeQuery: e,
|
|
644
|
-
inlineItemLimit: t =
|
|
645
|
-
nodeBudget: n =
|
|
652
|
+
inlineItemLimit: t = Ge,
|
|
653
|
+
nodeBudget: n = Xe,
|
|
646
654
|
onUnsupportedItem: o,
|
|
647
655
|
studentId: r,
|
|
648
656
|
validate: s = !0,
|
|
649
|
-
capabilities: l =
|
|
657
|
+
capabilities: l = Ao
|
|
650
658
|
}) {
|
|
651
659
|
const a = r != null, m = { onUnsupportedItem: o };
|
|
652
660
|
return {
|
|
653
661
|
inlineNodeBudget: n,
|
|
654
662
|
capabilities: l,
|
|
655
663
|
async listModules({
|
|
656
|
-
courseId:
|
|
664
|
+
courseId: c,
|
|
657
665
|
cursor: u,
|
|
658
666
|
pageSize: p,
|
|
659
667
|
includeItems: f,
|
|
660
|
-
filter:
|
|
668
|
+
filter: y,
|
|
661
669
|
inlineItemsFirst: g,
|
|
662
670
|
inlineFirst: h,
|
|
663
|
-
signal:
|
|
671
|
+
signal: _
|
|
664
672
|
}) {
|
|
665
|
-
Ce(
|
|
666
|
-
const
|
|
667
|
-
e(
|
|
668
|
-
courseId:
|
|
669
|
-
first:
|
|
673
|
+
Ce(_);
|
|
674
|
+
const C = f ? Math.min(h ?? p, p) : p, b = Math.min(g ?? t, t), w = Math.max(1, Math.min(b, Math.floor(n / C))), k = await ct(
|
|
675
|
+
e(vo, {
|
|
676
|
+
courseId: c,
|
|
677
|
+
first: C,
|
|
670
678
|
after: u ?? null,
|
|
671
679
|
includeItems: f,
|
|
672
|
-
itemsFirst:
|
|
680
|
+
itemsFirst: w,
|
|
673
681
|
includeSubmissions: a,
|
|
674
682
|
studentId: r ?? null,
|
|
675
|
-
filter:
|
|
683
|
+
filter: Ro(y)
|
|
676
684
|
}),
|
|
677
|
-
|
|
685
|
+
_
|
|
678
686
|
);
|
|
679
|
-
Ce(
|
|
680
|
-
const q =
|
|
681
|
-
return s ?
|
|
687
|
+
Ce(_);
|
|
688
|
+
const q = Po(k, m);
|
|
689
|
+
return s ? Xn.parse(q) : q;
|
|
682
690
|
},
|
|
683
691
|
async listModuleItems({
|
|
684
|
-
moduleId:
|
|
692
|
+
moduleId: c,
|
|
685
693
|
cursor: u,
|
|
686
694
|
pageSize: p,
|
|
687
695
|
signal: f
|
|
688
696
|
}) {
|
|
689
697
|
Ce(f);
|
|
690
|
-
const
|
|
691
|
-
e(
|
|
692
|
-
moduleId:
|
|
698
|
+
const y = await ct(
|
|
699
|
+
e(Lo, {
|
|
700
|
+
moduleId: c,
|
|
693
701
|
first: p,
|
|
694
702
|
after: u ?? null,
|
|
695
703
|
includeSubmissions: a,
|
|
@@ -698,169 +706,170 @@ function _l({
|
|
|
698
706
|
f
|
|
699
707
|
);
|
|
700
708
|
Ce(f);
|
|
701
|
-
const g =
|
|
702
|
-
return s ?
|
|
709
|
+
const g = Co(y, c, m);
|
|
710
|
+
return s ? Jn.parse(g) : g;
|
|
703
711
|
}
|
|
704
712
|
};
|
|
705
713
|
}
|
|
706
|
-
const
|
|
707
|
-
pageTitle:
|
|
708
|
-
modulesLoadedAnnouncement:
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
moduleProgressScreenReaderLabel:
|
|
733
|
-
itemsLoadedAnnouncement:
|
|
734
|
-
itemsLoadErrorAlert:
|
|
735
|
-
itemsLoadingSpinnerLabel:
|
|
736
|
-
itemsLoadingText:
|
|
737
|
-
noItemsEmptyState:
|
|
738
|
-
loadMoreItemsLoading:
|
|
739
|
-
loadMoreItems:
|
|
740
|
-
moduleUnpublishedBadge:
|
|
741
|
-
collapseModule:
|
|
742
|
-
expandModule:
|
|
743
|
-
moduleStatusNotStarted:
|
|
744
|
-
moduleStatusInProgress:
|
|
745
|
-
moduleStatusComplete:
|
|
746
|
-
moduleStatusMissing:
|
|
747
|
-
moduleStatusIncomplete:
|
|
748
|
-
moduleStatusMissingAndIncomplete:
|
|
749
|
-
moduleStatusLocked:
|
|
750
|
-
itemStatusNotStarted:
|
|
751
|
-
itemStatusInProgress:
|
|
752
|
-
itemStatusComplete:
|
|
753
|
-
itemStatusIncomplete:
|
|
754
|
-
itemStatusMissing:
|
|
755
|
-
itemStatusLocked:
|
|
756
|
-
itemTypeAssignment:
|
|
757
|
-
itemTypeQuiz:
|
|
758
|
-
itemTypeDiscussion:
|
|
759
|
-
itemTypePage:
|
|
760
|
-
itemTypeFile:
|
|
761
|
-
itemTypeExternalUrl:
|
|
762
|
-
itemTypeExternalTool:
|
|
763
|
-
itemTypeSubHeader:
|
|
764
|
-
metaFieldTypeLabel:
|
|
765
|
-
metaFieldDueAtLabel:
|
|
766
|
-
metaFieldPointsLabel:
|
|
767
|
-
metaFieldRequirementLabel:
|
|
768
|
-
metaFieldDurationLabel:
|
|
769
|
-
metaFieldPublishStateLabel:
|
|
770
|
-
requirementMustView:
|
|
771
|
-
requirementMustSubmit:
|
|
772
|
-
requirementMustContribute:
|
|
773
|
-
requirementMustMarkDone:
|
|
774
|
-
requirementMinScoreUnknown:
|
|
775
|
-
requirementMinScore:
|
|
776
|
-
requirementMinPercentageUnknown:
|
|
777
|
-
requirementMinPercentage:
|
|
778
|
-
requirementUnknown:
|
|
779
|
-
dateTimeToday:
|
|
780
|
-
dateTimeYesterday:
|
|
781
|
-
dateTimeTomorrow:
|
|
782
|
-
dateTimeWithDate:
|
|
783
|
-
timeWithZone:
|
|
784
|
-
dueByline:
|
|
785
|
-
unlockByline:
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
714
|
+
const xo = "Course modules", No = { one: "%{count} module loaded", other: "%{count} modules loaded" }, qo = "Expand / collapse", ko = "Expand all", Do = "Collapse all", Oo = "This filter runs on the modules loaded so far — load more to filter the rest of the course.", Fo = "Modules failed to load: %{message}", Uo = "Loading modules", zo = "This course has no modules.", $o = { one: "The only loaded module does not match this filter.", other: "None of the %{count} loaded modules match this filter." }, Bo = "No modules match this filter.", jo = "Clear filters", Go = "Loading more modules…", Yo = "Load more modules (%{count} loaded)", Wo = { one: "The only module in this course is loaded.", other: "All %{count} modules in this course are loaded." }, Qo = "Filter", Ho = "All", Vo = "In progress", Ko = "Complete", Zo = "Due this week", Xo = "Missing", Jo = "Locked until %{name} is completed.", er = "Locked until %{prerequisites} are completed.", tr = "%{count} prerequisites", nr = "%{label}. %{name}", or = "%{name} progress", rr = { one: "%{loaded} of %{count} item loaded in %{name}", other: "%{loaded} of %{count} items loaded in %{name}" }, sr = "Items failed to load: %{message}", ir = "Loading items", lr = "Loading…", ar = "No items.", ur = "Loading more items…", cr = "Load more items (%{loaded} of %{count} loaded)", dr = "(unpublished)", mr = "Collapse %{name}", pr = "Expand %{name}", fr = "Not started", gr = "In progress", hr = "All completed", Ir = "%{count} Missing", br = "%{count} Incomplete", Mr = "%{missing} & %{incomplete}", yr = "Locked", Sr = "Not started", _r = "In progress", Tr = "Completed", Er = "Incomplete", Pr = "Missing", Cr = "Locked", wr = "Assignment", vr = "Quiz", Lr = "Discussion", Ar = "Page", Rr = "File", xr = "External URL", Nr = "External tool", qr = "Text header", kr = "Item type", Dr = "Due date", Or = "Points", Fr = "Requirement", Ur = "Estimated duration", zr = "Publish state", $r = "View the item", Br = "Submit the assignment", jr = "Contribute to the page", Gr = "Mark as done", Yr = "Score at least the minimum", Wr = "Score at least %{count}", Qr = "Score at least the minimum percentage", Hr = "Score at least %{count}%", Vr = "Complete the requirement", Kr = "today, %{time}", Zr = "yesterday, %{time}", Xr = "tomorrow, %{time}", Jr = "%{date}, %{time}", es = "%{time} (%{zone})", ts = "Due %{when}", ns = "Will unlock on %{when}", os = "Unlocked on %{when}", rs = { one: "%{count} pt", other: "%{count} pts" }, ss = { one: "%{percent}% | %{met} of %{count} requirement met", other: "%{percent}% | %{met} of %{count} requirements met" }, is = { one: "%{percent}% complete, %{met} of %{count} requirement met", other: "%{percent}% complete, %{met} of %{count} requirements met" }, ls = "%{count} min", as = "Unpublished", us = "Untitled item", cs = "opens in a new window", ds = {
|
|
715
|
+
pageTitle: xo,
|
|
716
|
+
modulesLoadedAnnouncement: No,
|
|
717
|
+
expandCollapseTrigger: qo,
|
|
718
|
+
expandAll: ko,
|
|
719
|
+
collapseAll: Do,
|
|
720
|
+
filterScopeHint: Oo,
|
|
721
|
+
modulesLoadErrorAlert: Fo,
|
|
722
|
+
modulesLoadingSpinnerLabel: Uo,
|
|
723
|
+
noModulesEmptyState: zo,
|
|
724
|
+
filteredEmptyState: $o,
|
|
725
|
+
noFilterMatches: Bo,
|
|
726
|
+
clearFilters: jo,
|
|
727
|
+
loadMoreModulesLoading: Go,
|
|
728
|
+
loadMoreModules: Yo,
|
|
729
|
+
allModulesLoaded: Wo,
|
|
730
|
+
filterGroupLabel: Qo,
|
|
731
|
+
filterAll: Ho,
|
|
732
|
+
filterInProgress: Vo,
|
|
733
|
+
filterComplete: Ko,
|
|
734
|
+
filterDueThisWeek: Zo,
|
|
735
|
+
filterMissing: Xo,
|
|
736
|
+
lockedByPrerequisiteByline: Jo,
|
|
737
|
+
lockedByPrerequisitesByline: er,
|
|
738
|
+
lockedByPrerequisitesCount: tr,
|
|
739
|
+
moduleNameWithLabel: nr,
|
|
740
|
+
moduleProgressScreenReaderLabel: or,
|
|
741
|
+
itemsLoadedAnnouncement: rr,
|
|
742
|
+
itemsLoadErrorAlert: sr,
|
|
743
|
+
itemsLoadingSpinnerLabel: ir,
|
|
744
|
+
itemsLoadingText: lr,
|
|
745
|
+
noItemsEmptyState: ar,
|
|
746
|
+
loadMoreItemsLoading: ur,
|
|
747
|
+
loadMoreItems: cr,
|
|
748
|
+
moduleUnpublishedBadge: dr,
|
|
749
|
+
collapseModule: mr,
|
|
750
|
+
expandModule: pr,
|
|
751
|
+
moduleStatusNotStarted: fr,
|
|
752
|
+
moduleStatusInProgress: gr,
|
|
753
|
+
moduleStatusComplete: hr,
|
|
754
|
+
moduleStatusMissing: Ir,
|
|
755
|
+
moduleStatusIncomplete: br,
|
|
756
|
+
moduleStatusMissingAndIncomplete: Mr,
|
|
757
|
+
moduleStatusLocked: yr,
|
|
758
|
+
itemStatusNotStarted: Sr,
|
|
759
|
+
itemStatusInProgress: _r,
|
|
760
|
+
itemStatusComplete: Tr,
|
|
761
|
+
itemStatusIncomplete: Er,
|
|
762
|
+
itemStatusMissing: Pr,
|
|
763
|
+
itemStatusLocked: Cr,
|
|
764
|
+
itemTypeAssignment: wr,
|
|
765
|
+
itemTypeQuiz: vr,
|
|
766
|
+
itemTypeDiscussion: Lr,
|
|
767
|
+
itemTypePage: Ar,
|
|
768
|
+
itemTypeFile: Rr,
|
|
769
|
+
itemTypeExternalUrl: xr,
|
|
770
|
+
itemTypeExternalTool: Nr,
|
|
771
|
+
itemTypeSubHeader: qr,
|
|
772
|
+
metaFieldTypeLabel: kr,
|
|
773
|
+
metaFieldDueAtLabel: Dr,
|
|
774
|
+
metaFieldPointsLabel: Or,
|
|
775
|
+
metaFieldRequirementLabel: Fr,
|
|
776
|
+
metaFieldDurationLabel: Ur,
|
|
777
|
+
metaFieldPublishStateLabel: zr,
|
|
778
|
+
requirementMustView: $r,
|
|
779
|
+
requirementMustSubmit: Br,
|
|
780
|
+
requirementMustContribute: jr,
|
|
781
|
+
requirementMustMarkDone: Gr,
|
|
782
|
+
requirementMinScoreUnknown: Yr,
|
|
783
|
+
requirementMinScore: Wr,
|
|
784
|
+
requirementMinPercentageUnknown: Qr,
|
|
785
|
+
requirementMinPercentage: Hr,
|
|
786
|
+
requirementUnknown: Vr,
|
|
787
|
+
dateTimeToday: Kr,
|
|
788
|
+
dateTimeYesterday: Zr,
|
|
789
|
+
dateTimeTomorrow: Xr,
|
|
790
|
+
dateTimeWithDate: Jr,
|
|
791
|
+
timeWithZone: es,
|
|
792
|
+
dueByline: ts,
|
|
793
|
+
unlockByline: ns,
|
|
794
|
+
unlockedByline: os,
|
|
795
|
+
pointsAbbreviated: rs,
|
|
796
|
+
progressSummary: ss,
|
|
797
|
+
progressScreenReaderValue: is,
|
|
798
|
+
durationMinutes: ls,
|
|
799
|
+
itemUnpublishedLabel: as,
|
|
800
|
+
itemUntitled: us,
|
|
801
|
+
opensInNewWindow: cs
|
|
802
|
+
}, ms = /%\{(\w+)\}/g, ps = ds, oe = "en-US", fs = /* @__PURE__ */ new Map(), gs = /* @__PURE__ */ new Map();
|
|
803
|
+
function tn(e, t, n) {
|
|
795
804
|
const o = e.get(t);
|
|
796
805
|
if (o) return o;
|
|
797
806
|
const r = n();
|
|
798
807
|
return e.set(t, r), r;
|
|
799
808
|
}
|
|
800
|
-
function
|
|
801
|
-
return n ? e.replace(
|
|
809
|
+
function hs(e, t, n) {
|
|
810
|
+
return n ? e.replace(ms, (o, r) => {
|
|
802
811
|
if (!Object.prototype.hasOwnProperty.call(n, r)) return o;
|
|
803
812
|
const s = n[r];
|
|
804
|
-
return typeof s == "number" && Number.isFinite(s) ?
|
|
813
|
+
return typeof s == "number" && Number.isFinite(s) ? tn(gs, t, () => new Intl.NumberFormat(t)).format(s) : String(s);
|
|
805
814
|
}) : e;
|
|
806
815
|
}
|
|
807
|
-
function
|
|
816
|
+
function Is(e, t, n) {
|
|
808
817
|
const o = n == null ? void 0 : n.count;
|
|
809
818
|
if (typeof o == "number" && Number.isFinite(o)) {
|
|
810
|
-
const r =
|
|
819
|
+
const r = tn(fs, t, () => new Intl.PluralRules(t)).select(o), s = e[r];
|
|
811
820
|
if (typeof s == "string") return s;
|
|
812
821
|
}
|
|
813
822
|
return typeof e.other == "string" ? e.other : void 0;
|
|
814
823
|
}
|
|
815
|
-
function
|
|
824
|
+
function mt(e, t, n) {
|
|
816
825
|
if (typeof e == "string") return e;
|
|
817
826
|
if (e !== null && typeof e == "object")
|
|
818
|
-
return
|
|
827
|
+
return Is(e, t, n);
|
|
819
828
|
}
|
|
820
|
-
const
|
|
821
|
-
function
|
|
822
|
-
|
|
829
|
+
const pt = /* @__PURE__ */ new Set();
|
|
830
|
+
function bs(e) {
|
|
831
|
+
pt.has(e) || (pt.add(e), console.warn(
|
|
823
832
|
`[platform-modules] no translation for "${e}"; it will render as itself. Add it to the catalog passed to ModulesI18nProvider.`
|
|
824
833
|
));
|
|
825
834
|
}
|
|
826
|
-
function
|
|
827
|
-
const s =
|
|
835
|
+
function Ms(e, t, n, o, r) {
|
|
836
|
+
const s = mt(e == null ? void 0 : e[t], n, r);
|
|
828
837
|
if (typeof s == "string") return s;
|
|
829
|
-
const l =
|
|
830
|
-
return typeof l == "string" ? l : (o &&
|
|
838
|
+
const l = mt(ps[t], n, r);
|
|
839
|
+
return typeof l == "string" ? l : (o && bs(t), t);
|
|
831
840
|
}
|
|
832
|
-
function
|
|
833
|
-
return (o, r) =>
|
|
841
|
+
function nn(e, t = oe, n = !1) {
|
|
842
|
+
return (o, r) => hs(Ms(e, o, t, n, r), t, r);
|
|
834
843
|
}
|
|
835
|
-
const
|
|
836
|
-
function
|
|
844
|
+
const ys = nn(), Ss = { t: ys, locale: oe }, on = Pt(null);
|
|
845
|
+
function ql({
|
|
837
846
|
translations: e,
|
|
838
847
|
locale: t,
|
|
839
848
|
timezone: n,
|
|
840
849
|
warnOnMissingKey: o,
|
|
841
850
|
children: r
|
|
842
851
|
}) {
|
|
843
|
-
const s =
|
|
844
|
-
const l = t ??
|
|
852
|
+
const s = N(() => {
|
|
853
|
+
const l = t ?? oe;
|
|
845
854
|
return {
|
|
846
|
-
t:
|
|
855
|
+
t: nn(e, l, o),
|
|
847
856
|
locale: l,
|
|
848
857
|
timezone: n
|
|
849
858
|
};
|
|
850
859
|
}, [e, t, n, o]);
|
|
851
|
-
return /* @__PURE__ */ i(
|
|
860
|
+
return /* @__PURE__ */ i(on.Provider, { value: s, children: r });
|
|
852
861
|
}
|
|
853
|
-
function
|
|
854
|
-
return
|
|
862
|
+
function B() {
|
|
863
|
+
return Ct(on) ?? Ss;
|
|
855
864
|
}
|
|
856
|
-
const
|
|
857
|
-
function
|
|
858
|
-
const t =
|
|
865
|
+
const _s = 864e5, Ts = "en-US", ft = /* @__PURE__ */ new Map(), gt = /* @__PURE__ */ new Map();
|
|
866
|
+
function Es(e) {
|
|
867
|
+
const t = gt.get(e);
|
|
859
868
|
if (t) return t;
|
|
860
869
|
const n = new Intl.NumberFormat(e, { minimumIntegerDigits: 2, useGrouping: !1 });
|
|
861
|
-
return
|
|
870
|
+
return gt.set(e, n), n;
|
|
862
871
|
}
|
|
863
|
-
function
|
|
872
|
+
function ht(e, t) {
|
|
864
873
|
return {
|
|
865
874
|
time: new Intl.DateTimeFormat(e, {
|
|
866
875
|
hour: "numeric",
|
|
@@ -875,7 +884,7 @@ function dt(e, t) {
|
|
|
875
884
|
timeZone: t
|
|
876
885
|
}),
|
|
877
886
|
zone: t ? new Intl.DateTimeFormat(e, { timeZone: t, timeZoneName: "short" }) : void 0,
|
|
878
|
-
civilDay: new Intl.DateTimeFormat(
|
|
887
|
+
civilDay: new Intl.DateTimeFormat(Ts, {
|
|
879
888
|
year: "numeric",
|
|
880
889
|
month: "numeric",
|
|
881
890
|
day: "numeric",
|
|
@@ -883,57 +892,57 @@ function dt(e, t) {
|
|
|
883
892
|
})
|
|
884
893
|
};
|
|
885
894
|
}
|
|
886
|
-
function
|
|
887
|
-
const n = t || void 0, o = `${e}|${n ?? ""}`, r =
|
|
895
|
+
function rn(e, t) {
|
|
896
|
+
const n = t || void 0, o = `${e}|${n ?? ""}`, r = ft.get(o);
|
|
888
897
|
if (r) return r;
|
|
889
898
|
let s;
|
|
890
899
|
try {
|
|
891
|
-
s =
|
|
900
|
+
s = ht(e, n);
|
|
892
901
|
} catch {
|
|
893
902
|
console.warn(
|
|
894
903
|
`[platform-modules] Unusable timezone ${JSON.stringify(n)}; rendering dates in the viewer's own clock instead.`
|
|
895
|
-
), s =
|
|
904
|
+
), s = ht(e, void 0);
|
|
896
905
|
}
|
|
897
|
-
return
|
|
906
|
+
return ft.set(o, s), s;
|
|
898
907
|
}
|
|
899
|
-
function
|
|
900
|
-
return new Date(
|
|
908
|
+
function It(e, t) {
|
|
909
|
+
return new Date(Ye(e, t)).getUTCFullYear();
|
|
901
910
|
}
|
|
902
|
-
function
|
|
911
|
+
function Ps(e, t) {
|
|
903
912
|
var o;
|
|
904
913
|
const n = (o = e.zone) == null ? void 0 : o.formatToParts(t).find((r) => r.type === "timeZoneName");
|
|
905
914
|
return (n == null ? void 0 : n.value) ?? null;
|
|
906
915
|
}
|
|
907
|
-
function
|
|
916
|
+
function Ye(e, t) {
|
|
908
917
|
const n = e.civilDay.formatToParts(t), o = (r) => {
|
|
909
918
|
var s;
|
|
910
919
|
return Number((s = n.find((l) => l.type === r)) == null ? void 0 : s.value);
|
|
911
920
|
};
|
|
912
921
|
return Date.UTC(o("year"), o("month") - 1, o("day"));
|
|
913
922
|
}
|
|
914
|
-
function
|
|
915
|
-
return
|
|
923
|
+
function Cs(e, t, n) {
|
|
924
|
+
return sn(rn(oe, n), e, t);
|
|
916
925
|
}
|
|
917
|
-
function
|
|
918
|
-
return Math.round((
|
|
926
|
+
function sn(e, t, n) {
|
|
927
|
+
return Math.round((Ye(e, t) - Ye(e, n)) / _s);
|
|
919
928
|
}
|
|
920
|
-
function
|
|
929
|
+
function ws(e, t, n, { locale: o = oe, timezone: r } = {}) {
|
|
921
930
|
const s = new Date(t);
|
|
922
931
|
if (Number.isNaN(s.getTime())) return t;
|
|
923
|
-
const l =
|
|
924
|
-
if (u === 0) return e("dateTimeToday", { time:
|
|
925
|
-
if (u === -1) return e("dateTimeYesterday", { time:
|
|
926
|
-
if (u === 1) return e("dateTimeTomorrow", { time:
|
|
927
|
-
const f =
|
|
928
|
-
return e("dateTimeWithDate", { date: f, time:
|
|
932
|
+
const l = rn(o, r), a = Ps(l, s), m = l.time.format(s), c = a ? e("timeWithZone", { time: m, zone: a }) : m, u = sn(l, s, n);
|
|
933
|
+
if (u === 0) return e("dateTimeToday", { time: c });
|
|
934
|
+
if (u === -1) return e("dateTimeYesterday", { time: c });
|
|
935
|
+
if (u === 1) return e("dateTimeTomorrow", { time: c });
|
|
936
|
+
const f = It(l, s) === It(l, n) ? l.day.format(s) : l.dayYear.format(s);
|
|
937
|
+
return e("dateTimeWithDate", { date: f, time: c });
|
|
929
938
|
}
|
|
930
|
-
function
|
|
931
|
-
return !Number.isInteger(e) || e < 1 ? null :
|
|
939
|
+
function vs(e, t = oe) {
|
|
940
|
+
return !Number.isInteger(e) || e < 1 ? null : Es(t).format(e);
|
|
932
941
|
}
|
|
933
|
-
function
|
|
942
|
+
function Ls(e, t) {
|
|
934
943
|
return t == null ? null : e("pointsAbbreviated", { count: t });
|
|
935
944
|
}
|
|
936
|
-
function
|
|
945
|
+
function As(e, t) {
|
|
937
946
|
switch (t.type) {
|
|
938
947
|
case "must_view":
|
|
939
948
|
return e("requirementMustView");
|
|
@@ -951,17 +960,13 @@ function bs(e, t) {
|
|
|
951
960
|
return e("requirementUnknown");
|
|
952
961
|
}
|
|
953
962
|
}
|
|
954
|
-
function
|
|
963
|
+
function Rs(e, t, n, o) {
|
|
955
964
|
return e("progressSummary", { percent: t, met: n, count: o });
|
|
956
965
|
}
|
|
957
|
-
function
|
|
966
|
+
function xs(e, t, n, o) {
|
|
958
967
|
return e("progressScreenReaderValue", { percent: t, met: n, count: o });
|
|
959
968
|
}
|
|
960
|
-
|
|
961
|
-
const o = t.trim().toLocaleLowerCase(n);
|
|
962
|
-
return o === "" ? !0 : e.name.toLocaleLowerCase(n).includes(o);
|
|
963
|
-
}
|
|
964
|
-
const J = "all", _s = 7, Ts = {
|
|
969
|
+
const V = "all", Ns = 7, qs = {
|
|
965
970
|
all: {
|
|
966
971
|
label: "filterAll",
|
|
967
972
|
order: 10,
|
|
@@ -991,12 +996,12 @@ const J = "all", _s = 7, Ts = {
|
|
|
991
996
|
order: 40,
|
|
992
997
|
predicate: (e, { today: t, timezone: n }) => {
|
|
993
998
|
var l;
|
|
994
|
-
const o = (l = e.progress) == null ? void 0 : l.
|
|
999
|
+
const o = (l = e.progress) == null ? void 0 : l.nextDueAt;
|
|
995
1000
|
if (!o) return !1;
|
|
996
1001
|
const r = new Date(o);
|
|
997
1002
|
if (Number.isNaN(r.getTime())) return !1;
|
|
998
|
-
const s =
|
|
999
|
-
return s >= 0 && s
|
|
1003
|
+
const s = Cs(r, t, n);
|
|
1004
|
+
return s >= 0 && s < Ns;
|
|
1000
1005
|
}
|
|
1001
1006
|
},
|
|
1002
1007
|
missing: {
|
|
@@ -1008,43 +1013,43 @@ const J = "all", _s = 7, Ts = {
|
|
|
1008
1013
|
}
|
|
1009
1014
|
}
|
|
1010
1015
|
};
|
|
1011
|
-
function
|
|
1016
|
+
function Je(e) {
|
|
1012
1017
|
if (!(!e || e.clientOnly))
|
|
1013
1018
|
return e.query;
|
|
1014
1019
|
}
|
|
1015
|
-
function
|
|
1016
|
-
return e !== void 0 &&
|
|
1020
|
+
function We(e) {
|
|
1021
|
+
return e !== void 0 && Je(e) === void 0;
|
|
1017
1022
|
}
|
|
1018
|
-
const
|
|
1019
|
-
moduleLabel: (e, t, { locale: n }) =>
|
|
1020
|
-
dateTime: (e, t, { t: n, locale: o, timezone: r }) =>
|
|
1021
|
-
points: (e, { t }) =>
|
|
1022
|
-
progress: (e, t, n, { t: o }) =>
|
|
1023
|
+
const ks = {
|
|
1024
|
+
moduleLabel: (e, t, { locale: n }) => vs(e, n),
|
|
1025
|
+
dateTime: (e, t, { t: n, locale: o, timezone: r }) => ws(n, e, t, { locale: o, timezone: r }),
|
|
1026
|
+
points: (e, { t }) => Ls(t, e),
|
|
1027
|
+
progress: (e, t, n, { t: o }) => Rs(o, e, t, n)
|
|
1023
1028
|
}, Ae = (e, t) => Object.prototype.hasOwnProperty.call(e, t);
|
|
1024
|
-
function
|
|
1029
|
+
function Re(e, t) {
|
|
1025
1030
|
const n = Object.entries(t ?? {}).filter(([, o]) => o !== void 0);
|
|
1026
1031
|
return { ...e, ...Object.fromEntries(n) };
|
|
1027
1032
|
}
|
|
1028
|
-
function
|
|
1033
|
+
function ee(e, t = {}) {
|
|
1029
1034
|
const n = Object.keys(e).map((r) => [
|
|
1030
1035
|
r,
|
|
1031
|
-
|
|
1032
|
-
]), o = Object.keys(t).filter((r) => !Ae(e, r)).sort().map((r) => [r,
|
|
1036
|
+
Re(e[r], Ae(t, r) ? t[r] : void 0)
|
|
1037
|
+
]), o = Object.keys(t).filter((r) => !Ae(e, r)).sort().map((r) => [r, Re({}, t[r])]);
|
|
1033
1038
|
return Object.fromEntries([...n, ...o]);
|
|
1034
1039
|
}
|
|
1035
|
-
function
|
|
1040
|
+
function ne(e, t) {
|
|
1036
1041
|
if (!(!Ae(e, t) || e[t].hidden))
|
|
1037
1042
|
return e[t];
|
|
1038
1043
|
}
|
|
1039
|
-
function
|
|
1040
|
-
return Object.keys(e).filter((t) =>
|
|
1044
|
+
function et(e) {
|
|
1045
|
+
return Object.keys(e).filter((t) => ne(e, t) !== void 0).map((t) => ({ ...e[t], key: t })).sort((t, n) => t.order - n.order);
|
|
1041
1046
|
}
|
|
1042
|
-
const
|
|
1047
|
+
const Ds = "type", Os = {
|
|
1043
1048
|
type: {
|
|
1044
1049
|
label: "metaFieldTypeLabel",
|
|
1045
1050
|
order: 10,
|
|
1046
1051
|
render: ({ item: e, t, config: n }) => {
|
|
1047
|
-
const o =
|
|
1052
|
+
const o = ne(n.itemTypes, e.type);
|
|
1048
1053
|
return o ? t(o.label) : null;
|
|
1049
1054
|
}
|
|
1050
1055
|
},
|
|
@@ -1061,13 +1066,13 @@ const Ps = "type", Cs = {
|
|
|
1061
1066
|
requirement: {
|
|
1062
1067
|
label: "metaFieldRequirementLabel",
|
|
1063
1068
|
order: 40,
|
|
1064
|
-
render: ({ item: e, t }) => e.completionRequirement ?
|
|
1069
|
+
render: ({ item: e, t }) => e.completionRequirement ? As(t, e.completionRequirement) : null
|
|
1065
1070
|
},
|
|
1066
1071
|
estimatedDuration: {
|
|
1067
1072
|
label: "metaFieldDurationLabel",
|
|
1068
1073
|
order: 50,
|
|
1069
1074
|
render: ({ item: e, t }) => {
|
|
1070
|
-
const n =
|
|
1075
|
+
const n = eo(e);
|
|
1071
1076
|
return n === null ? null : t("durationMinutes", { count: n });
|
|
1072
1077
|
}
|
|
1073
1078
|
},
|
|
@@ -1076,37 +1081,37 @@ const Ps = "type", Cs = {
|
|
|
1076
1081
|
order: 60,
|
|
1077
1082
|
render: ({ item: e, t }) => e.published ? null : t("itemUnpublishedLabel")
|
|
1078
1083
|
}
|
|
1079
|
-
},
|
|
1084
|
+
}, H = { size: "md", color: "mutedColor" }, Fs = {
|
|
1080
1085
|
assignment: {
|
|
1081
1086
|
label: "itemTypeAssignment",
|
|
1082
1087
|
order: 10,
|
|
1083
|
-
icon: /* @__PURE__ */ i(
|
|
1088
|
+
icon: /* @__PURE__ */ i(Rn, { ...H })
|
|
1084
1089
|
},
|
|
1085
|
-
quiz: { label: "itemTypeQuiz", order: 20, icon: /* @__PURE__ */ i(
|
|
1090
|
+
quiz: { label: "itemTypeQuiz", order: 20, icon: /* @__PURE__ */ i(An, { ...H }) },
|
|
1086
1091
|
discussion: {
|
|
1087
1092
|
label: "itemTypeDiscussion",
|
|
1088
1093
|
order: 30,
|
|
1089
|
-
icon: /* @__PURE__ */ i(
|
|
1094
|
+
icon: /* @__PURE__ */ i(Ln, { ...H })
|
|
1090
1095
|
},
|
|
1091
|
-
page: { label: "itemTypePage", order: 40, icon: /* @__PURE__ */ i(
|
|
1092
|
-
file: { label: "itemTypeFile", order: 50, icon: /* @__PURE__ */ i(
|
|
1096
|
+
page: { label: "itemTypePage", order: 40, icon: /* @__PURE__ */ i(vn, { ...H }) },
|
|
1097
|
+
file: { label: "itemTypeFile", order: 50, icon: /* @__PURE__ */ i(wn, { ...H }) },
|
|
1093
1098
|
external_url: {
|
|
1094
1099
|
label: "itemTypeExternalUrl",
|
|
1095
1100
|
order: 60,
|
|
1096
|
-
icon: /* @__PURE__ */ i(
|
|
1101
|
+
icon: /* @__PURE__ */ i(Cn, { ...H })
|
|
1097
1102
|
},
|
|
1098
1103
|
external_tool: {
|
|
1099
1104
|
label: "itemTypeExternalTool",
|
|
1100
1105
|
order: 70,
|
|
1101
|
-
icon: /* @__PURE__ */ i(
|
|
1106
|
+
icon: /* @__PURE__ */ i(Pn, { ...H })
|
|
1102
1107
|
},
|
|
1103
1108
|
sub_header: { label: "itemTypeSubHeader", order: 80, icon: null }
|
|
1104
1109
|
}, qe = {
|
|
1105
|
-
formatters:
|
|
1106
|
-
itemTypes:
|
|
1110
|
+
formatters: ks,
|
|
1111
|
+
itemTypes: Fs,
|
|
1107
1112
|
itemStatuses: {},
|
|
1108
|
-
itemMeta:
|
|
1109
|
-
filters:
|
|
1113
|
+
itemMeta: Os,
|
|
1114
|
+
filters: qs,
|
|
1110
1115
|
moduleActions: {},
|
|
1111
1116
|
itemActions: {},
|
|
1112
1117
|
navigation: {}
|
|
@@ -1116,131 +1121,132 @@ for (const e of Object.values(qe)) {
|
|
|
1116
1121
|
Object.freeze(e);
|
|
1117
1122
|
for (const t of Object.values(e)) Object.freeze(t);
|
|
1118
1123
|
}
|
|
1119
|
-
function
|
|
1120
|
-
return
|
|
1121
|
-
const o =
|
|
1122
|
-
return o !== void 0 && !
|
|
1124
|
+
function Us(e, t) {
|
|
1125
|
+
return et(e).filter((n) => {
|
|
1126
|
+
const o = Je(n);
|
|
1127
|
+
return o !== void 0 && !Gn(t, o);
|
|
1123
1128
|
}).map((n) => n.key);
|
|
1124
1129
|
}
|
|
1125
|
-
function
|
|
1130
|
+
function bt(e) {
|
|
1126
1131
|
return `[platform-modules] the adapter cannot serve filter(s): ${e.join(", ")}. Add the field to the adapter's capabilities, or set clientOnly on the entry.`;
|
|
1127
1132
|
}
|
|
1128
|
-
function
|
|
1129
|
-
const n =
|
|
1133
|
+
function zs(e, t) {
|
|
1134
|
+
const n = Us(e, t);
|
|
1130
1135
|
if (n.length === 0) return e;
|
|
1131
1136
|
if (process.env.NODE_ENV !== "production")
|
|
1132
|
-
throw new Error(
|
|
1133
|
-
console.warn(
|
|
1137
|
+
throw new Error(bt(n));
|
|
1138
|
+
console.warn(bt(n));
|
|
1134
1139
|
const o = Object.fromEntries(n.map((r) => [r, { ...e[r], hidden: !0 }]));
|
|
1135
1140
|
return { ...e, ...o };
|
|
1136
1141
|
}
|
|
1137
|
-
const
|
|
1138
|
-
function
|
|
1139
|
-
return /* @__PURE__ */ i(
|
|
1142
|
+
const ln = Pt(null);
|
|
1143
|
+
function kl({ value: e, children: t }) {
|
|
1144
|
+
return /* @__PURE__ */ i(ln.Provider, { value: e, children: t });
|
|
1140
1145
|
}
|
|
1141
|
-
function
|
|
1142
|
-
return
|
|
1146
|
+
function ye() {
|
|
1147
|
+
return Ct(ln) ?? qe;
|
|
1143
1148
|
}
|
|
1144
|
-
function
|
|
1145
|
-
return
|
|
1149
|
+
function Dl(e) {
|
|
1150
|
+
return ne(ye().itemMeta, e) !== void 0;
|
|
1146
1151
|
}
|
|
1147
|
-
const
|
|
1148
|
-
label:
|
|
1149
|
-
order:
|
|
1150
|
-
hidden:
|
|
1152
|
+
const ke = d.object({
|
|
1153
|
+
label: d.string(),
|
|
1154
|
+
order: d.number(),
|
|
1155
|
+
hidden: d.boolean().optional()
|
|
1151
1156
|
});
|
|
1152
1157
|
function ve(e) {
|
|
1153
|
-
return
|
|
1158
|
+
return d.record(d.string(), e);
|
|
1154
1159
|
}
|
|
1155
|
-
const
|
|
1160
|
+
const Be = ve(ke.strict()), an = (e) => e == null || typeof e == "string" || typeof e == "number" || typeof e == "bigint" || typeof e == "boolean" || wt(e) || Array.isArray(e) && e.every(an), $s = (e) => {
|
|
1156
1161
|
var t;
|
|
1157
1162
|
return e == null || typeof e == "function" && !((t = e.prototype) != null && t.isReactComponent);
|
|
1158
|
-
},
|
|
1159
|
-
icon:
|
|
1160
|
-
renderIcon:
|
|
1163
|
+
}, Bs = ke.extend({
|
|
1164
|
+
icon: d.custom(an, { message: "icon must be a ReactNode" }),
|
|
1165
|
+
renderIcon: d.custom($s, {
|
|
1161
1166
|
message: "renderIcon must be a function of the item, not a React component"
|
|
1162
1167
|
})
|
|
1163
1168
|
}).strict();
|
|
1164
1169
|
function we() {
|
|
1165
|
-
return
|
|
1170
|
+
return d.custom((e) => typeof e == "function", {
|
|
1166
1171
|
message: "Expected a function"
|
|
1167
1172
|
});
|
|
1168
1173
|
}
|
|
1169
|
-
const
|
|
1170
|
-
render:
|
|
1174
|
+
const js = ke.extend({
|
|
1175
|
+
render: d.custom((e) => typeof e == "function", {
|
|
1171
1176
|
message: "render must be a function taking a MetaFieldContext"
|
|
1172
1177
|
})
|
|
1173
|
-
}).strict(),
|
|
1174
|
-
predicate:
|
|
1178
|
+
}).strict(), Gs = ke.extend({
|
|
1179
|
+
predicate: d.custom((e) => typeof e == "function", {
|
|
1175
1180
|
message: "predicate must be a function of the module and a FilterContext"
|
|
1176
1181
|
}),
|
|
1177
|
-
query:
|
|
1178
|
-
clientOnly:
|
|
1179
|
-
}).strict(),
|
|
1180
|
-
formatters:
|
|
1182
|
+
query: jn.optional(),
|
|
1183
|
+
clientOnly: d.boolean().optional()
|
|
1184
|
+
}).strict(), Ys = d.object({
|
|
1185
|
+
formatters: d.object({
|
|
1181
1186
|
moduleLabel: we(),
|
|
1182
1187
|
dateTime: we(),
|
|
1183
1188
|
points: we(),
|
|
1184
1189
|
progress: we()
|
|
1185
1190
|
}).strict(),
|
|
1186
|
-
itemTypes: ve(
|
|
1187
|
-
itemStatuses:
|
|
1188
|
-
itemMeta: ve(
|
|
1189
|
-
filters: ve(
|
|
1190
|
-
moduleActions:
|
|
1191
|
-
itemActions:
|
|
1192
|
-
navigation:
|
|
1191
|
+
itemTypes: ve(Bs),
|
|
1192
|
+
itemStatuses: Be,
|
|
1193
|
+
itemMeta: ve(js),
|
|
1194
|
+
filters: ve(Gs),
|
|
1195
|
+
moduleActions: Be,
|
|
1196
|
+
itemActions: Be,
|
|
1197
|
+
navigation: d.object({}).strict()
|
|
1193
1198
|
});
|
|
1194
|
-
function
|
|
1199
|
+
function Ws(e, t = {}) {
|
|
1195
1200
|
const n = Object.keys(t).filter((r) => !Ae(e, r));
|
|
1196
1201
|
if (n.length > 0)
|
|
1197
1202
|
throw new Error(
|
|
1198
1203
|
`Unknown modules config key(s): ${n.join(", ")}. Known keys are ${Object.keys(e).join(", ")}.`
|
|
1199
1204
|
);
|
|
1200
1205
|
const o = {
|
|
1201
|
-
formatters:
|
|
1202
|
-
itemTypes:
|
|
1203
|
-
itemStatuses:
|
|
1204
|
-
itemMeta:
|
|
1205
|
-
filters:
|
|
1206
|
-
moduleActions:
|
|
1207
|
-
itemActions:
|
|
1208
|
-
navigation:
|
|
1206
|
+
formatters: Re(e.formatters, t.formatters),
|
|
1207
|
+
itemTypes: ee(e.itemTypes, t.itemTypes),
|
|
1208
|
+
itemStatuses: ee(e.itemStatuses, t.itemStatuses),
|
|
1209
|
+
itemMeta: ee(e.itemMeta, t.itemMeta),
|
|
1210
|
+
filters: ee(e.filters, t.filters),
|
|
1211
|
+
moduleActions: ee(e.moduleActions, t.moduleActions),
|
|
1212
|
+
itemActions: ee(e.itemActions, t.itemActions),
|
|
1213
|
+
navigation: Re(e.navigation, t.navigation)
|
|
1209
1214
|
};
|
|
1210
|
-
return
|
|
1215
|
+
return Ys.parse(o), o;
|
|
1211
1216
|
}
|
|
1212
|
-
function
|
|
1213
|
-
return
|
|
1217
|
+
function Ol(e = {}) {
|
|
1218
|
+
return Ws(qe, e);
|
|
1214
1219
|
}
|
|
1215
|
-
function
|
|
1216
|
-
const { formatters: e } =
|
|
1217
|
-
return
|
|
1220
|
+
function De() {
|
|
1221
|
+
const { formatters: e } = ye(), { t, locale: n, timezone: o } = B();
|
|
1222
|
+
return N(() => {
|
|
1218
1223
|
const r = { t, locale: n, timezone: o }, s = (l, a) => e.dateTime(l, a, r);
|
|
1219
1224
|
return {
|
|
1220
1225
|
moduleLabel: (l, a) => e.moduleLabel(l, a, r) || null,
|
|
1221
1226
|
dueByline: (l, a) => t("dueByline", { when: s(l, a) }),
|
|
1222
1227
|
unlockByline: (l, a) => t("unlockByline", { when: s(l, a) }),
|
|
1228
|
+
unlockedByline: (l, a) => t("unlockedByline", { when: s(l, a) }),
|
|
1223
1229
|
points: (l) => e.points(l, r),
|
|
1224
1230
|
progress: (l, a, m) => e.progress(l, a, m, r)
|
|
1225
1231
|
};
|
|
1226
1232
|
}, [e, t, n, o]);
|
|
1227
1233
|
}
|
|
1228
|
-
const
|
|
1229
|
-
all:
|
|
1230
|
-
course: (e) => [...
|
|
1231
|
-
list: (e, t = {}) => [...
|
|
1232
|
-
items: (e, t, n = {}) => [...
|
|
1234
|
+
const tt = 100, un = 100, cn = 100, Qs = 4, Oe = 5 * 60 * 1e3, dn = 20, xe = { hasNextPage: !1, endCursor: null }, te = ["platform-modules"], Se = {
|
|
1235
|
+
all: te,
|
|
1236
|
+
course: (e) => [...te, e],
|
|
1237
|
+
list: (e, t = {}) => [...te, e, "list", t],
|
|
1238
|
+
items: (e, t, n = {}) => [...te, e, "module", t, "items", n]
|
|
1233
1239
|
};
|
|
1234
|
-
function
|
|
1235
|
-
return [...
|
|
1240
|
+
function Hs(e) {
|
|
1241
|
+
return [...te, e, "list"];
|
|
1236
1242
|
}
|
|
1237
|
-
function
|
|
1238
|
-
return [...
|
|
1243
|
+
function mn(e, t) {
|
|
1244
|
+
return [...te, e, "module", t, "items"];
|
|
1239
1245
|
}
|
|
1240
|
-
function
|
|
1246
|
+
function pn(e) {
|
|
1241
1247
|
return e.pageInfo.hasNextPage ? e.pageInfo.endCursor : null;
|
|
1242
1248
|
}
|
|
1243
|
-
function
|
|
1249
|
+
function fn(e) {
|
|
1244
1250
|
const {
|
|
1245
1251
|
courseId: t,
|
|
1246
1252
|
adapter: n,
|
|
@@ -1250,12 +1256,12 @@ function un(e) {
|
|
|
1250
1256
|
inlineItemsFirst: l,
|
|
1251
1257
|
inlineFirst: a,
|
|
1252
1258
|
view: m,
|
|
1253
|
-
staleTime:
|
|
1259
|
+
staleTime: c,
|
|
1254
1260
|
enabled: u
|
|
1255
1261
|
} = e;
|
|
1256
1262
|
return {
|
|
1257
1263
|
// `inlineItemsFirst` is deliberately out of the key: it is derived from this very list.
|
|
1258
|
-
queryKey:
|
|
1264
|
+
queryKey: Se.list(t, { view: m, pageSize: o, includeItems: r, filter: s }),
|
|
1259
1265
|
initialPageParam: null,
|
|
1260
1266
|
queryFn: ({ pageParam: p, signal: f }) => n.listModules({
|
|
1261
1267
|
courseId: t,
|
|
@@ -1267,46 +1273,46 @@ function un(e) {
|
|
|
1267
1273
|
inlineFirst: a,
|
|
1268
1274
|
signal: f
|
|
1269
1275
|
}),
|
|
1270
|
-
getNextPageParam:
|
|
1276
|
+
getNextPageParam: pn,
|
|
1271
1277
|
enabled: u,
|
|
1272
|
-
staleTime:
|
|
1278
|
+
staleTime: c,
|
|
1273
1279
|
refetchOnWindowFocus: !1
|
|
1274
1280
|
};
|
|
1275
1281
|
}
|
|
1276
|
-
function
|
|
1282
|
+
function gn(e) {
|
|
1277
1283
|
const { courseId: t, moduleId: n, adapter: o, pageSize: r, view: s, staleTime: l, enabled: a, limit: m } = e;
|
|
1278
1284
|
return {
|
|
1279
|
-
queryKey:
|
|
1285
|
+
queryKey: Se.items(t, n, { view: s, pageSize: r }),
|
|
1280
1286
|
initialPageParam: null,
|
|
1281
|
-
queryFn: ({ pageParam:
|
|
1282
|
-
const p = () => o.listModuleItems({ courseId: t, moduleId: n, cursor:
|
|
1287
|
+
queryFn: ({ pageParam: c, signal: u }) => {
|
|
1288
|
+
const p = () => o.listModuleItems({ courseId: t, moduleId: n, cursor: c, pageSize: r, signal: u });
|
|
1283
1289
|
return m ? m(() => {
|
|
1284
1290
|
if (u.aborted)
|
|
1285
1291
|
throw new DOMException("The operation was aborted.", "AbortError");
|
|
1286
1292
|
return p();
|
|
1287
1293
|
}) : p();
|
|
1288
1294
|
},
|
|
1289
|
-
getNextPageParam:
|
|
1295
|
+
getNextPageParam: pn,
|
|
1290
1296
|
enabled: a,
|
|
1291
1297
|
staleTime: l,
|
|
1292
1298
|
refetchOnWindowFocus: !1
|
|
1293
1299
|
};
|
|
1294
1300
|
}
|
|
1295
|
-
function
|
|
1296
|
-
var
|
|
1301
|
+
function Vs(e) {
|
|
1302
|
+
var C;
|
|
1297
1303
|
const {
|
|
1298
1304
|
courseId: t,
|
|
1299
1305
|
adapter: n,
|
|
1300
|
-
pageSize: o =
|
|
1306
|
+
pageSize: o = tt,
|
|
1301
1307
|
includeItems: r = !1,
|
|
1302
1308
|
filter: s,
|
|
1303
1309
|
inlineItemsFirst: l,
|
|
1304
1310
|
inlineFirst: a,
|
|
1305
1311
|
view: m,
|
|
1306
|
-
staleTime:
|
|
1312
|
+
staleTime: c = Oe,
|
|
1307
1313
|
enabled: u = !0
|
|
1308
|
-
} = e, p =
|
|
1309
|
-
|
|
1314
|
+
} = e, p = Ke(
|
|
1315
|
+
fn({
|
|
1310
1316
|
courseId: t,
|
|
1311
1317
|
adapter: n,
|
|
1312
1318
|
pageSize: o,
|
|
@@ -1315,36 +1321,36 @@ function Fs(e) {
|
|
|
1315
1321
|
inlineItemsFirst: l,
|
|
1316
1322
|
inlineFirst: a,
|
|
1317
1323
|
view: m,
|
|
1318
|
-
staleTime:
|
|
1324
|
+
staleTime: c,
|
|
1319
1325
|
enabled: u
|
|
1320
1326
|
})
|
|
1321
|
-
), f = (
|
|
1327
|
+
), f = (C = p.data) == null ? void 0 : C.pages, y = N(() => (f ?? []).flatMap((b) => b.modules), [f]), g = f && f.length > 0 ? f[f.length - 1].pageInfo : xe, h = p.fetchNextPage, _ = F(() => {
|
|
1322
1328
|
h();
|
|
1323
1329
|
}, [h]);
|
|
1324
1330
|
return {
|
|
1325
|
-
modules:
|
|
1331
|
+
modules: y,
|
|
1326
1332
|
pageInfo: g,
|
|
1327
1333
|
hasNextPage: g.hasNextPage,
|
|
1328
|
-
fetchNextPage:
|
|
1334
|
+
fetchNextPage: _,
|
|
1329
1335
|
isLoading: p.isLoading,
|
|
1330
1336
|
isFetchingNextPage: p.isFetchingNextPage,
|
|
1331
1337
|
isPending: p.isPending,
|
|
1332
1338
|
error: p.error
|
|
1333
1339
|
};
|
|
1334
1340
|
}
|
|
1335
|
-
function
|
|
1341
|
+
function Fl(e) {
|
|
1336
1342
|
var h;
|
|
1337
1343
|
const {
|
|
1338
1344
|
courseId: t,
|
|
1339
1345
|
moduleId: n,
|
|
1340
1346
|
adapter: o,
|
|
1341
|
-
pageSize: r =
|
|
1347
|
+
pageSize: r = un,
|
|
1342
1348
|
view: s,
|
|
1343
1349
|
enabled: l = !0,
|
|
1344
1350
|
staleTime: a = Oe,
|
|
1345
1351
|
limit: m
|
|
1346
|
-
} = e,
|
|
1347
|
-
|
|
1352
|
+
} = e, c = Ke(
|
|
1353
|
+
gn({
|
|
1348
1354
|
courseId: t,
|
|
1349
1355
|
moduleId: n,
|
|
1350
1356
|
adapter: o,
|
|
@@ -1354,20 +1360,20 @@ function wl(e) {
|
|
|
1354
1360
|
enabled: l,
|
|
1355
1361
|
limit: m
|
|
1356
1362
|
})
|
|
1357
|
-
), u = (h =
|
|
1358
|
-
|
|
1359
|
-
}, [
|
|
1363
|
+
), u = (h = c.data) == null ? void 0 : h.pages, p = N(() => (u ?? []).flatMap((_) => _.items), [u]), f = u && u.length > 0 ? u[u.length - 1].pageInfo : xe, y = c.fetchNextPage, g = F(() => {
|
|
1364
|
+
y();
|
|
1365
|
+
}, [y]);
|
|
1360
1366
|
return {
|
|
1361
1367
|
items: p,
|
|
1362
1368
|
pageInfo: f,
|
|
1363
1369
|
hasNextPage: f.hasNextPage,
|
|
1364
1370
|
fetchNextPage: g,
|
|
1365
|
-
isLoading:
|
|
1366
|
-
isFetchingNextPage:
|
|
1367
|
-
error:
|
|
1371
|
+
isLoading: c.isLoading,
|
|
1372
|
+
isFetchingNextPage: c.isFetchingNextPage,
|
|
1373
|
+
error: c.error
|
|
1368
1374
|
};
|
|
1369
1375
|
}
|
|
1370
|
-
function
|
|
1376
|
+
function Ks(e, t, n = Xe) {
|
|
1371
1377
|
if (e.pageInfo.hasNextPage) return "onDemand";
|
|
1372
1378
|
let o = 0, r = 0;
|
|
1373
1379
|
for (const s of e.modules) {
|
|
@@ -1376,27 +1382,27 @@ function Us(e, t, n = Ke) {
|
|
|
1376
1382
|
}
|
|
1377
1383
|
return o > t * 2 ? "onDemand" : Math.max(e.modules.length, 1) * Math.max(r, 1) <= n ? "inline" : "onDemand";
|
|
1378
1384
|
}
|
|
1379
|
-
function
|
|
1380
|
-
var
|
|
1385
|
+
function Zs(e) {
|
|
1386
|
+
var y;
|
|
1381
1387
|
const {
|
|
1382
1388
|
courseId: t,
|
|
1383
1389
|
adapter: n,
|
|
1384
1390
|
mode: o = "auto",
|
|
1385
|
-
inlineThreshold: r =
|
|
1386
|
-
nodeBudget: s = n.inlineNodeBudget ??
|
|
1387
|
-
pageSize: l =
|
|
1391
|
+
inlineThreshold: r = cn,
|
|
1392
|
+
nodeBudget: s = n.inlineNodeBudget ?? Xe,
|
|
1393
|
+
pageSize: l = tt,
|
|
1388
1394
|
filter: a,
|
|
1389
1395
|
view: m,
|
|
1390
|
-
staleTime:
|
|
1391
|
-
} = e, u = o === "auto", p =
|
|
1392
|
-
|
|
1396
|
+
staleTime: c = Oe
|
|
1397
|
+
} = e, u = o === "auto", p = Ke(
|
|
1398
|
+
fn({
|
|
1393
1399
|
courseId: t,
|
|
1394
1400
|
adapter: n,
|
|
1395
1401
|
pageSize: l,
|
|
1396
1402
|
includeItems: !1,
|
|
1397
1403
|
filter: a,
|
|
1398
1404
|
view: m,
|
|
1399
|
-
staleTime:
|
|
1405
|
+
staleTime: c,
|
|
1400
1406
|
enabled: u
|
|
1401
1407
|
})
|
|
1402
1408
|
);
|
|
@@ -1416,39 +1422,39 @@ function zs(e) {
|
|
|
1416
1422
|
error: p.error,
|
|
1417
1423
|
inlineShape: null
|
|
1418
1424
|
};
|
|
1419
|
-
const f = (
|
|
1425
|
+
const f = (y = p.data) == null ? void 0 : y.pages[0];
|
|
1420
1426
|
return f ? {
|
|
1421
|
-
resolvedMode:
|
|
1427
|
+
resolvedMode: Ks(f, r, s),
|
|
1422
1428
|
isResolving: !1,
|
|
1423
1429
|
probed: !0,
|
|
1424
1430
|
error: null,
|
|
1425
|
-
inlineShape:
|
|
1431
|
+
inlineShape: Xs(f)
|
|
1426
1432
|
} : { resolvedMode: null, isResolving: !0, probed: !0, error: null, inlineShape: null };
|
|
1427
1433
|
}
|
|
1428
|
-
function
|
|
1434
|
+
function Xs(e) {
|
|
1429
1435
|
let t = 1;
|
|
1430
1436
|
for (const n of e.modules)
|
|
1431
1437
|
n.itemCount > t && (t = n.itemCount);
|
|
1432
1438
|
return { moduleCount: Math.max(e.modules.length, 1), maxItemCount: t };
|
|
1433
1439
|
}
|
|
1434
|
-
const
|
|
1435
|
-
function
|
|
1436
|
-
const o =
|
|
1437
|
-
|
|
1440
|
+
const Mt = "\0", Js = /* @__PURE__ */ new Map();
|
|
1441
|
+
function ei(e, t, n = dn) {
|
|
1442
|
+
const o = kt(), r = $(/* @__PURE__ */ new Map()), [s, l] = Le(Js), a = e.join(Mt), m = N(() => a === "" ? [] : a.split(Mt), [a]);
|
|
1443
|
+
Ie(() => {
|
|
1438
1444
|
const u = r.current, p = () => {
|
|
1439
1445
|
l((g) => {
|
|
1440
1446
|
const h = /* @__PURE__ */ new Map();
|
|
1441
|
-
let
|
|
1442
|
-
for (const [
|
|
1443
|
-
const
|
|
1444
|
-
h.set(
|
|
1447
|
+
let _ = g.size !== u.size;
|
|
1448
|
+
for (const [C, b] of u) {
|
|
1449
|
+
const w = b.getCurrentResult();
|
|
1450
|
+
h.set(C, w), !_ && g.get(C) !== w && (_ = !0);
|
|
1445
1451
|
}
|
|
1446
|
-
return
|
|
1452
|
+
return _ ? h : g;
|
|
1447
1453
|
});
|
|
1448
1454
|
}, f = new Set(m);
|
|
1449
1455
|
for (const g of m) {
|
|
1450
1456
|
if (u.has(g)) continue;
|
|
1451
|
-
const h = new
|
|
1457
|
+
const h = new qn(
|
|
1452
1458
|
o,
|
|
1453
1459
|
t(g, !0)
|
|
1454
1460
|
);
|
|
@@ -1460,194 +1466,209 @@ function js(e, t, n = sn) {
|
|
|
1460
1466
|
const h = u.get(g);
|
|
1461
1467
|
h && (u.delete(g), u.set(g, h));
|
|
1462
1468
|
}
|
|
1463
|
-
let
|
|
1464
|
-
if (
|
|
1469
|
+
let y = u.size - f.size;
|
|
1470
|
+
if (y > n)
|
|
1465
1471
|
for (const [g, h] of u) {
|
|
1466
|
-
if (
|
|
1467
|
-
f.has(g) || (h.destroy(), u.delete(g),
|
|
1472
|
+
if (y <= n) break;
|
|
1473
|
+
f.has(g) || (h.destroy(), u.delete(g), y -= 1);
|
|
1468
1474
|
}
|
|
1469
1475
|
p();
|
|
1470
|
-
}, [o, t, m, n]),
|
|
1476
|
+
}, [o, t, m, n]), Ie(() => {
|
|
1471
1477
|
const u = r.current;
|
|
1472
1478
|
return () => {
|
|
1473
1479
|
for (const p of u.values()) p.destroy();
|
|
1474
1480
|
u.clear();
|
|
1475
1481
|
};
|
|
1476
1482
|
}, []);
|
|
1477
|
-
const
|
|
1483
|
+
const c = F((u) => {
|
|
1478
1484
|
var p;
|
|
1479
1485
|
(p = r.current.get(u)) == null || p.fetchNextPage();
|
|
1480
1486
|
}, []);
|
|
1481
|
-
return { results: s, fetchNextPage:
|
|
1487
|
+
return { results: s, fetchNextPage: c };
|
|
1482
1488
|
}
|
|
1483
|
-
const
|
|
1489
|
+
const ti = [], ni = () => {
|
|
1484
1490
|
};
|
|
1485
|
-
function
|
|
1486
|
-
var
|
|
1491
|
+
function Ul(e) {
|
|
1492
|
+
var Ee, x;
|
|
1487
1493
|
const {
|
|
1488
1494
|
courseId: t,
|
|
1489
1495
|
adapter: n,
|
|
1490
1496
|
view: o,
|
|
1491
1497
|
itemsMode: r = "auto",
|
|
1492
|
-
inlineThreshold: s =
|
|
1493
|
-
pageSize: l =
|
|
1494
|
-
itemPageSize: a =
|
|
1495
|
-
itemConcurrency: m =
|
|
1496
|
-
retainCollapsedLimit:
|
|
1498
|
+
inlineThreshold: s = cn,
|
|
1499
|
+
pageSize: l = tt,
|
|
1500
|
+
itemPageSize: a = un,
|
|
1501
|
+
itemConcurrency: m = Qs,
|
|
1502
|
+
retainCollapsedLimit: c = dn,
|
|
1497
1503
|
staleTime: u = Oe,
|
|
1498
1504
|
initialExpandedModuleIds: p,
|
|
1499
|
-
initialFilter: f =
|
|
1500
|
-
} = e,
|
|
1501
|
-
() =>
|
|
1505
|
+
initialFilter: f = V
|
|
1506
|
+
} = e, y = kt(), g = ye(), [h, _] = Le(f), C = N(
|
|
1507
|
+
() => zs(g.filters, n.capabilities),
|
|
1502
1508
|
[g.filters, n.capabilities]
|
|
1503
|
-
),
|
|
1509
|
+
), b = ne(C, h), w = Je(b), k = Zs({
|
|
1504
1510
|
courseId: t,
|
|
1505
1511
|
adapter: n,
|
|
1506
1512
|
mode: r,
|
|
1507
1513
|
inlineThreshold: s,
|
|
1508
1514
|
pageSize: l,
|
|
1509
|
-
filter:
|
|
1515
|
+
filter: w,
|
|
1510
1516
|
view: o,
|
|
1511
1517
|
staleTime: u
|
|
1512
|
-
}), q =
|
|
1518
|
+
}), q = k.resolvedMode, A = Vs({
|
|
1513
1519
|
courseId: t,
|
|
1514
1520
|
adapter: n,
|
|
1515
1521
|
pageSize: l,
|
|
1516
|
-
filter:
|
|
1522
|
+
filter: w,
|
|
1517
1523
|
view: o,
|
|
1518
1524
|
staleTime: u,
|
|
1519
1525
|
includeItems: q === "inline",
|
|
1520
|
-
inlineItemsFirst: (
|
|
1521
|
-
inlineFirst: (
|
|
1526
|
+
inlineItemsFirst: (Ee = k.inlineShape) == null ? void 0 : Ee.maxItemCount,
|
|
1527
|
+
inlineFirst: (x = k.inlineShape) == null ? void 0 : x.moduleCount,
|
|
1522
1528
|
enabled: q !== null
|
|
1523
|
-
}), [
|
|
1529
|
+
}), [D, j] = Le(
|
|
1524
1530
|
() => p ?? []
|
|
1525
|
-
),
|
|
1531
|
+
), Q = p === void 0, O = $(!1), R = h !== V && b !== void 0;
|
|
1532
|
+
Ie(() => {
|
|
1533
|
+
!Q || O.current || R || j((I) => {
|
|
1534
|
+
const M = new Set(I), v = [...I];
|
|
1535
|
+
for (const W of A.modules)
|
|
1536
|
+
W.collapsed === !1 && !M.has(W.id) && v.push(W.id);
|
|
1537
|
+
return v.length === I.length ? I : v;
|
|
1538
|
+
});
|
|
1539
|
+
}, [A.modules, Q, R]);
|
|
1540
|
+
const G = N(() => {
|
|
1526
1541
|
const I = /* @__PURE__ */ new Map();
|
|
1527
|
-
for (const
|
|
1542
|
+
for (const M of A.modules) I.set(M.id, M);
|
|
1528
1543
|
return I;
|
|
1529
|
-
}, [
|
|
1530
|
-
() =>
|
|
1531
|
-
const
|
|
1532
|
-
return
|
|
1544
|
+
}, [A.modules]), se = N(
|
|
1545
|
+
() => D.filter((I) => {
|
|
1546
|
+
const M = G.get(I);
|
|
1547
|
+
return M !== void 0 && M.items === void 0;
|
|
1533
1548
|
}),
|
|
1534
|
-
[
|
|
1535
|
-
),
|
|
1536
|
-
(I,
|
|
1549
|
+
[D, G]
|
|
1550
|
+
), ie = N(() => new Set(se), [se]), le = N(() => kn(m), [m]), Ue = F(
|
|
1551
|
+
(I, M) => gn({
|
|
1537
1552
|
courseId: t,
|
|
1538
1553
|
moduleId: I,
|
|
1539
1554
|
adapter: n,
|
|
1540
1555
|
pageSize: a,
|
|
1541
1556
|
view: o,
|
|
1542
1557
|
staleTime: u,
|
|
1543
|
-
enabled:
|
|
1544
|
-
limit:
|
|
1558
|
+
enabled: M,
|
|
1559
|
+
limit: le
|
|
1545
1560
|
}),
|
|
1546
|
-
[t, n, a, o, u,
|
|
1547
|
-
),
|
|
1561
|
+
[t, n, a, o, u, le]
|
|
1562
|
+
), K = ei(se, Ue, c), ae = K.fetchNextPage, L = $(/* @__PURE__ */ new Map()), ue = F(
|
|
1548
1563
|
(I) => {
|
|
1549
|
-
let
|
|
1550
|
-
return
|
|
1564
|
+
let M = L.current.get(I);
|
|
1565
|
+
return M || (M = () => ae(I), L.current.set(I, M)), M;
|
|
1551
1566
|
},
|
|
1552
|
-
[
|
|
1553
|
-
),
|
|
1554
|
-
|
|
1555
|
-
(
|
|
1567
|
+
[ae]
|
|
1568
|
+
), Z = F((I) => {
|
|
1569
|
+
O.current = !0, j(
|
|
1570
|
+
(M) => M.includes(I) ? M : [...M, I]
|
|
1556
1571
|
);
|
|
1557
|
-
}, []),
|
|
1572
|
+
}, []), U = F(
|
|
1558
1573
|
(I) => {
|
|
1559
|
-
|
|
1574
|
+
O.current = !0, j((M) => M.filter((v) => v !== I)), y.cancelQueries({ queryKey: mn(t, I) });
|
|
1560
1575
|
},
|
|
1561
|
-
[
|
|
1562
|
-
),
|
|
1563
|
-
|
|
1564
|
-
const
|
|
1565
|
-
|
|
1566
|
-
|
|
1576
|
+
[y, t]
|
|
1577
|
+
), Y = $(D);
|
|
1578
|
+
Y.current = D;
|
|
1579
|
+
const X = F(() => {
|
|
1580
|
+
O.current = !0;
|
|
1581
|
+
for (const I of Y.current) U(I);
|
|
1582
|
+
}, [U]), ce = $(h);
|
|
1583
|
+
ce.current = h;
|
|
1584
|
+
const z = $(null), de = F(
|
|
1567
1585
|
(I) => {
|
|
1568
|
-
if (I ===
|
|
1569
|
-
if (
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1586
|
+
if (I === ce.current) return;
|
|
1587
|
+
if (ce.current = I, I !== V && ne(C, I) !== void 0) {
|
|
1588
|
+
z.current === null && (z.current = Y.current);
|
|
1589
|
+
const v = O.current;
|
|
1590
|
+
for (const W of Y.current) U(W);
|
|
1591
|
+
O.current = v;
|
|
1592
|
+
} else z.current !== null && (j(z.current), Y.current = z.current, z.current = null);
|
|
1593
|
+
_(I);
|
|
1574
1594
|
},
|
|
1575
|
-
[
|
|
1576
|
-
),
|
|
1595
|
+
[C, U]
|
|
1596
|
+
), ze = F(
|
|
1577
1597
|
(I) => {
|
|
1578
|
-
|
|
1598
|
+
Y.current.includes(I) ? U(I) : Z(I);
|
|
1579
1599
|
},
|
|
1580
|
-
[
|
|
1581
|
-
),
|
|
1600
|
+
[U, Z]
|
|
1601
|
+
), _e = K.results, me = $(/* @__PURE__ */ new Map()), Te = F(
|
|
1582
1602
|
(I) => {
|
|
1583
|
-
var
|
|
1584
|
-
const
|
|
1585
|
-
if (
|
|
1586
|
-
return
|
|
1587
|
-
const
|
|
1588
|
-
if ((
|
|
1589
|
-
return
|
|
1590
|
-
items:
|
|
1591
|
-
pageInfo:
|
|
1603
|
+
var st;
|
|
1604
|
+
const M = G.get(I), v = _e.get(I), W = ie.has(I), pe = me.current.get(I);
|
|
1605
|
+
if (pe && pe.items === (M == null ? void 0 : M.items) && pe.result === v && pe.active === W)
|
|
1606
|
+
return pe.value;
|
|
1607
|
+
const ot = (Pe) => (me.current.set(I, { items: M == null ? void 0 : M.items, result: v, active: W, value: Pe }), Pe);
|
|
1608
|
+
if ((M == null ? void 0 : M.items) !== void 0)
|
|
1609
|
+
return ot({
|
|
1610
|
+
items: M.items,
|
|
1611
|
+
pageInfo: xe,
|
|
1592
1612
|
hasNextPage: !1,
|
|
1593
|
-
fetchNextPage:
|
|
1613
|
+
fetchNextPage: ni,
|
|
1594
1614
|
isLoading: !1,
|
|
1595
1615
|
isFetchingNextPage: !1,
|
|
1596
1616
|
error: null,
|
|
1597
1617
|
source: "inline"
|
|
1598
1618
|
});
|
|
1599
|
-
const
|
|
1600
|
-
return
|
|
1601
|
-
items:
|
|
1602
|
-
pageInfo:
|
|
1603
|
-
hasNextPage:
|
|
1604
|
-
fetchNextPage:
|
|
1605
|
-
isLoading:
|
|
1606
|
-
isFetchingNextPage: (
|
|
1607
|
-
error: (
|
|
1619
|
+
const J = (st = v == null ? void 0 : v.data) == null ? void 0 : st.pages, En = J ? J.flatMap((Pe) => Pe.items) : ti, rt = J && J.length > 0 ? J[J.length - 1].pageInfo : xe;
|
|
1620
|
+
return ot({
|
|
1621
|
+
items: En,
|
|
1622
|
+
pageInfo: rt,
|
|
1623
|
+
hasNextPage: rt.hasNextPage,
|
|
1624
|
+
fetchNextPage: ue(I),
|
|
1625
|
+
isLoading: v ? v.isLoading : W,
|
|
1626
|
+
isFetchingNextPage: (v == null ? void 0 : v.isFetchingNextPage) ?? !1,
|
|
1627
|
+
error: (v == null ? void 0 : v.error) ?? null,
|
|
1608
1628
|
source: "onDemand"
|
|
1609
1629
|
});
|
|
1610
1630
|
},
|
|
1611
|
-
[G,
|
|
1631
|
+
[G, _e, ue, ie]
|
|
1612
1632
|
);
|
|
1613
1633
|
return {
|
|
1614
|
-
modules:
|
|
1615
|
-
pageInfo:
|
|
1616
|
-
hasNextPage:
|
|
1617
|
-
fetchNextPage:
|
|
1618
|
-
isLoading:
|
|
1619
|
-
isFetchingNextPage:
|
|
1620
|
-
error:
|
|
1634
|
+
modules: A.modules,
|
|
1635
|
+
pageInfo: A.pageInfo,
|
|
1636
|
+
hasNextPage: A.hasNextPage,
|
|
1637
|
+
fetchNextPage: A.fetchNextPage,
|
|
1638
|
+
isLoading: k.isResolving || A.isPending,
|
|
1639
|
+
isFetchingNextPage: A.isFetchingNextPage,
|
|
1640
|
+
error: A.error ?? k.error,
|
|
1621
1641
|
itemsMode: q,
|
|
1622
|
-
getItems:
|
|
1623
|
-
expandModule:
|
|
1624
|
-
collapseModule:
|
|
1625
|
-
|
|
1626
|
-
|
|
1642
|
+
getItems: Te,
|
|
1643
|
+
expandModule: Z,
|
|
1644
|
+
collapseModule: U,
|
|
1645
|
+
collapseAllModules: X,
|
|
1646
|
+
toggleModule: ze,
|
|
1647
|
+
expandedModuleIds: D,
|
|
1627
1648
|
filter: h,
|
|
1628
|
-
setFilter:
|
|
1629
|
-
filterEntry:
|
|
1630
|
-
filterPredicate:
|
|
1631
|
-
filterResultsArePartial: h !==
|
|
1649
|
+
setFilter: de,
|
|
1650
|
+
filterEntry: b,
|
|
1651
|
+
filterPredicate: We(b) ? b == null ? void 0 : b.predicate : void 0,
|
|
1652
|
+
filterResultsArePartial: h !== V && We(b) && A.hasNextPage
|
|
1632
1653
|
};
|
|
1633
1654
|
}
|
|
1634
|
-
function
|
|
1635
|
-
const r = o ?
|
|
1655
|
+
function zl(e, t, n, o) {
|
|
1656
|
+
const r = o ? Se.items(t, n, o) : mn(t, n);
|
|
1636
1657
|
return e.invalidateQueries({ queryKey: r });
|
|
1637
1658
|
}
|
|
1638
|
-
function
|
|
1639
|
-
const o = n ?
|
|
1659
|
+
function $l(e, t, n) {
|
|
1660
|
+
const o = n ? Se.list(t, n) : Hs(t);
|
|
1640
1661
|
return e.invalidateQueries({ queryKey: o });
|
|
1641
1662
|
}
|
|
1642
|
-
function
|
|
1643
|
-
return e.invalidateQueries({ queryKey:
|
|
1663
|
+
function Bl(e, t) {
|
|
1664
|
+
return e.invalidateQueries({ queryKey: Se.course(t) });
|
|
1644
1665
|
}
|
|
1645
|
-
function
|
|
1646
|
-
const { t: o } =
|
|
1647
|
-
return /* @__PURE__ */
|
|
1648
|
-
/* @__PURE__ */ i(
|
|
1666
|
+
function oi({ value: e, onChange: t, describedBy: n }) {
|
|
1667
|
+
const { t: o } = B(), r = ye(), s = N(() => et(r.filters), [r.filters]), l = vt();
|
|
1668
|
+
return /* @__PURE__ */ S(E, { as: "div", margin: "medium 0 0 0", children: [
|
|
1669
|
+
/* @__PURE__ */ i(E, { as: "div", margin: "0 0 x-small 0", children: /* @__PURE__ */ i(P, { size: "medium", weight: "bold", id: l, children: o("filterGroupLabel") }) }),
|
|
1649
1670
|
/* @__PURE__ */ i(
|
|
1650
|
-
|
|
1671
|
+
T,
|
|
1651
1672
|
{
|
|
1652
1673
|
gap: "space4",
|
|
1653
1674
|
wrap: "wrap",
|
|
@@ -1657,13 +1678,13 @@ function Ws({ value: e, onChange: t, describedBy: n }) {
|
|
|
1657
1678
|
"data-testid": "filter-chips",
|
|
1658
1679
|
children: s.map((a) => {
|
|
1659
1680
|
const m = a.key === e;
|
|
1660
|
-
return /* @__PURE__ */ i(
|
|
1661
|
-
|
|
1681
|
+
return /* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ i(
|
|
1682
|
+
he,
|
|
1662
1683
|
{
|
|
1663
1684
|
size: "medium",
|
|
1664
1685
|
color: m ? "primary" : "secondary",
|
|
1665
1686
|
"aria-pressed": m,
|
|
1666
|
-
"aria-describedby": a.key !==
|
|
1687
|
+
"aria-describedby": a.key !== V && We(a) ? n : void 0,
|
|
1667
1688
|
onClick: () => t(a.key),
|
|
1668
1689
|
"data-testid": `filter-chip-${a.key}`,
|
|
1669
1690
|
themeOverride: { borderRadius: "0.5rem" },
|
|
@@ -1675,29 +1696,29 @@ function Ws({ value: e, onChange: t, describedBy: n }) {
|
|
|
1675
1696
|
)
|
|
1676
1697
|
] });
|
|
1677
1698
|
}
|
|
1678
|
-
const
|
|
1699
|
+
const ri = "#586874", si = "#D7DADE", hn = (e, t) => {
|
|
1679
1700
|
var n, o, r, s;
|
|
1680
1701
|
return {
|
|
1681
|
-
baseTextColor: ((o = (n = t.colors) == null ? void 0 : n.contrasts) == null ? void 0 : o.grey5782) ??
|
|
1682
|
-
baseBorderColor: ((s = (r = t.colors) == null ? void 0 : r.contrasts) == null ? void 0 : s.grey1424) ??
|
|
1702
|
+
baseTextColor: ((o = (n = t.colors) == null ? void 0 : n.contrasts) == null ? void 0 : o.grey5782) ?? ri,
|
|
1703
|
+
baseBorderColor: ((s = (r = t.colors) == null ? void 0 : r.contrasts) == null ? void 0 : s.grey1424) ?? si
|
|
1683
1704
|
};
|
|
1684
|
-
},
|
|
1705
|
+
}, ii = {
|
|
1685
1706
|
not_started: {},
|
|
1686
|
-
in_progress: { color: "info", icon: /* @__PURE__ */ i(
|
|
1687
|
-
complete: { color: "success", icon: /* @__PURE__ */ i(
|
|
1688
|
-
missing: { color: "error", icon: /* @__PURE__ */ i(
|
|
1689
|
-
incomplete: { color: "error", icon: /* @__PURE__ */ i(
|
|
1690
|
-
missing_and_incomplete: { color: "error", icon: /* @__PURE__ */ i(
|
|
1691
|
-
locked: { icon: /* @__PURE__ */ i(
|
|
1692
|
-
},
|
|
1707
|
+
in_progress: { color: "info", icon: /* @__PURE__ */ i(Nt, { size: "sm" }) },
|
|
1708
|
+
complete: { color: "success", icon: /* @__PURE__ */ i(xt, { size: "sm" }) },
|
|
1709
|
+
missing: { color: "error", icon: /* @__PURE__ */ i(ge, { size: "sm" }) },
|
|
1710
|
+
incomplete: { color: "error", icon: /* @__PURE__ */ i(ge, { size: "sm" }) },
|
|
1711
|
+
missing_and_incomplete: { color: "error", icon: /* @__PURE__ */ i(ge, { size: "sm" }) },
|
|
1712
|
+
locked: { icon: /* @__PURE__ */ i(Rt, { size: "sm" }), themeOverride: hn }
|
|
1713
|
+
}, li = {
|
|
1693
1714
|
not_started: {},
|
|
1694
|
-
in_progress: { color: "info", icon: /* @__PURE__ */ i(
|
|
1695
|
-
complete: { color: "success", icon: /* @__PURE__ */ i(
|
|
1696
|
-
incomplete: { color: "error", icon: /* @__PURE__ */ i(
|
|
1697
|
-
missing: { color: "error", icon: /* @__PURE__ */ i(
|
|
1698
|
-
locked: { icon: /* @__PURE__ */ i(
|
|
1715
|
+
in_progress: { color: "info", icon: /* @__PURE__ */ i(Nt, { size: "sm" }) },
|
|
1716
|
+
complete: { color: "success", icon: /* @__PURE__ */ i(xt, { size: "sm" }) },
|
|
1717
|
+
incomplete: { color: "error", icon: /* @__PURE__ */ i(ge, { size: "sm" }) },
|
|
1718
|
+
missing: { color: "error", icon: /* @__PURE__ */ i(ge, { size: "sm" }) },
|
|
1719
|
+
locked: { icon: /* @__PURE__ */ i(Rt, { size: "sm" }), themeOverride: hn }
|
|
1699
1720
|
};
|
|
1700
|
-
function
|
|
1721
|
+
function ai(e, t, n, o) {
|
|
1701
1722
|
switch (t) {
|
|
1702
1723
|
case "not_started":
|
|
1703
1724
|
return e("moduleStatusNotStarted");
|
|
@@ -1718,7 +1739,7 @@ function Zs(e, t, n, o) {
|
|
|
1718
1739
|
return e("moduleStatusLocked");
|
|
1719
1740
|
}
|
|
1720
1741
|
}
|
|
1721
|
-
function
|
|
1742
|
+
function ui(e, t) {
|
|
1722
1743
|
switch (t) {
|
|
1723
1744
|
case "not_started":
|
|
1724
1745
|
return e("itemStatusNotStarted");
|
|
@@ -1734,9 +1755,9 @@ function Xs(e, t) {
|
|
|
1734
1755
|
return e("itemStatusLocked");
|
|
1735
1756
|
}
|
|
1736
1757
|
}
|
|
1737
|
-
function
|
|
1758
|
+
function In(e, t, n) {
|
|
1738
1759
|
return /* @__PURE__ */ i(
|
|
1739
|
-
|
|
1760
|
+
$n,
|
|
1740
1761
|
{
|
|
1741
1762
|
color: e.color,
|
|
1742
1763
|
renderIcon: e.icon,
|
|
@@ -1746,56 +1767,66 @@ function mn(e, t, n) {
|
|
|
1746
1767
|
}
|
|
1747
1768
|
);
|
|
1748
1769
|
}
|
|
1749
|
-
function
|
|
1770
|
+
function ci({
|
|
1750
1771
|
status: e,
|
|
1751
1772
|
missingCount: t,
|
|
1752
1773
|
incompleteCount: n
|
|
1753
1774
|
}) {
|
|
1754
|
-
const { t: o } =
|
|
1755
|
-
return
|
|
1756
|
-
|
|
1757
|
-
|
|
1775
|
+
const { t: o } = B();
|
|
1776
|
+
return In(
|
|
1777
|
+
ii[e],
|
|
1778
|
+
ai(o, e, t, n),
|
|
1758
1779
|
"module-status-pill"
|
|
1759
1780
|
);
|
|
1760
1781
|
}
|
|
1761
|
-
function
|
|
1762
|
-
const { t } =
|
|
1763
|
-
return
|
|
1764
|
-
|
|
1765
|
-
|
|
1782
|
+
function di({ status: e }) {
|
|
1783
|
+
const { t } = B();
|
|
1784
|
+
return In(
|
|
1785
|
+
li[e],
|
|
1786
|
+
ui(t, e),
|
|
1766
1787
|
"item-status-pill"
|
|
1767
1788
|
);
|
|
1768
1789
|
}
|
|
1769
|
-
const
|
|
1790
|
+
const bn = 2.75, je = `${bn}rem`, mi = { lineHeight: 0, display: "block" }, pi = {
|
|
1770
1791
|
display: "inline-block",
|
|
1771
1792
|
paddingLeft: "0.5rem",
|
|
1772
1793
|
marginLeft: "0.5rem"
|
|
1773
|
-
},
|
|
1774
|
-
function
|
|
1775
|
-
return e == null || typeof e == "boolean" || e === "" ? !0 : Array.isArray(e) ? e.every(
|
|
1794
|
+
}, fi = "#D7DADE", gi = "#6A7883", Mn = { fontSize: 0 };
|
|
1795
|
+
function Qe(e) {
|
|
1796
|
+
return e == null || typeof e == "boolean" || e === "" ? !0 : Array.isArray(e) ? e.every(Qe) : wt(e) && e.type === At ? Qe(e.props.children) : !1;
|
|
1776
1797
|
}
|
|
1777
|
-
const
|
|
1798
|
+
const hi = {
|
|
1778
1799
|
contentVisibility: "auto",
|
|
1779
|
-
containIntrinsicSize: "auto
|
|
1780
|
-
};
|
|
1781
|
-
function
|
|
1782
|
-
const e =
|
|
1800
|
+
containIntrinsicSize: "auto 4.25rem"
|
|
1801
|
+
}, Ii = "0.5rem";
|
|
1802
|
+
function bi() {
|
|
1803
|
+
const e = $t();
|
|
1783
1804
|
return "key" in e && e.key === "canvas-high-contrast" ? "inline" : "standalone";
|
|
1784
1805
|
}
|
|
1785
|
-
function
|
|
1786
|
-
var
|
|
1787
|
-
const
|
|
1788
|
-
return ("colors" in
|
|
1789
|
-
}
|
|
1790
|
-
function
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
() => ({ ...
|
|
1794
|
-
[
|
|
1795
|
-
)
|
|
1806
|
+
function yn(e, t) {
|
|
1807
|
+
var o, r;
|
|
1808
|
+
const n = $t();
|
|
1809
|
+
return ("colors" in n ? (r = (o = n.colors) == null ? void 0 : o.contrasts) == null ? void 0 : r[e] : void 0) ?? t;
|
|
1810
|
+
}
|
|
1811
|
+
function Sn() {
|
|
1812
|
+
const e = yn("grey1424", fi);
|
|
1813
|
+
return N(
|
|
1814
|
+
() => ({ ...pi, borderLeft: `1px solid ${e}` }),
|
|
1815
|
+
[e]
|
|
1816
|
+
);
|
|
1817
|
+
}
|
|
1818
|
+
function Mi({
|
|
1819
|
+
item: e,
|
|
1820
|
+
today: t,
|
|
1821
|
+
navigation: n,
|
|
1822
|
+
attachedAbove: o,
|
|
1823
|
+
attachedBelow: r
|
|
1824
|
+
}) {
|
|
1825
|
+
var O;
|
|
1826
|
+
const { t: s, locale: l, timezone: a } = B(), m = bi(), c = yn("grey4570", gi), u = Sn(), p = De(), f = ye(), y = N(() => et(f.itemMeta), [f.itemMeta]), g = e.title || s("itemUntitled");
|
|
1796
1827
|
if (e.type === "sub_header")
|
|
1797
1828
|
return /* @__PURE__ */ i(
|
|
1798
|
-
|
|
1829
|
+
E,
|
|
1799
1830
|
{
|
|
1800
1831
|
as: "div",
|
|
1801
1832
|
padding: "x-small small",
|
|
@@ -1810,121 +1841,132 @@ function ui({ item: e, today: t, navigation: n }) {
|
|
|
1810
1841
|
letterSpacing: "expanded",
|
|
1811
1842
|
"data-testid": "module-item-title",
|
|
1812
1843
|
"data-sub-header": "true",
|
|
1813
|
-
children:
|
|
1844
|
+
children: g
|
|
1814
1845
|
}
|
|
1815
1846
|
)
|
|
1816
1847
|
}
|
|
1817
1848
|
);
|
|
1818
|
-
const
|
|
1819
|
-
return /* @__PURE__ */ i("div", { style: {
|
|
1820
|
-
|
|
1849
|
+
const h = ((O = n == null ? void 0 : n.getItemHref) == null ? void 0 : O.call(n, e)) ?? e.url ?? null, _ = e.status === "locked", C = n == null ? void 0 : n.onItemClick, b = C ? (R) => C(e, R) : void 0, w = ne(f.itemTypes, e.type), k = w != null && w.renderIcon ? w.renderIcon({ item: e }) : w == null ? void 0 : w.icon, q = { item: e, t: s, today: t, locale: l, timezone: a, formatters: p, config: f }, A = y.map((R) => ({ key: R.key, node: R.render(q) })).filter((R) => !Qe(R.node)), D = A.some((R) => R.key === Ds), j = o ? "none" : "large", Q = r ? "none" : "large";
|
|
1850
|
+
return /* @__PURE__ */ i("div", { style: { ...hi, marginTop: o ? void 0 : Ii }, children: /* @__PURE__ */ i(
|
|
1851
|
+
E,
|
|
1821
1852
|
{
|
|
1822
1853
|
as: "div",
|
|
1823
1854
|
background: "secondary",
|
|
1824
|
-
borderRadius:
|
|
1825
|
-
padding: "
|
|
1826
|
-
margin: "x-small 0 0 0",
|
|
1855
|
+
borderRadius: `${j} ${j} ${Q} ${Q}`,
|
|
1856
|
+
padding: "small",
|
|
1827
1857
|
"data-testid": `module-item-${e.id}`,
|
|
1828
|
-
children: /* @__PURE__ */
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
T,
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
/* @__PURE__ */ i(
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1858
|
+
children: /* @__PURE__ */ i("div", { style: { paddingInlineStart: `${Math.max(e.indent - 1, 0) * bn}rem` }, children: /* @__PURE__ */ S(T, { alignItems: "center", gap: "mediumSmall", children: [
|
|
1859
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(T, { alignItems: "center", children: [
|
|
1860
|
+
e.indent > 0 ? /* @__PURE__ */ i(T.Item, { size: je, textAlign: "center", "data-testid": "item-nest-arrow", children: /* @__PURE__ */ i("span", { style: { color: c }, children: /* @__PURE__ */ i(xn, { size: "md", color: "inherit" }) }) }) : null,
|
|
1861
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ i(
|
|
1862
|
+
E,
|
|
1863
|
+
{
|
|
1864
|
+
as: "div",
|
|
1865
|
+
background: "primary",
|
|
1866
|
+
borderWidth: "small",
|
|
1867
|
+
borderRadius: "large",
|
|
1868
|
+
width: je,
|
|
1869
|
+
height: je,
|
|
1870
|
+
children: /* @__PURE__ */ i(T, { height: "100%", alignItems: "center", justifyItems: "center", children: /* @__PURE__ */ S(T.Item, { children: [
|
|
1871
|
+
/* @__PURE__ */ i("span", { style: mi, "data-testid": "item-type-icon", children: k }),
|
|
1872
|
+
w && !D ? /* @__PURE__ */ i(lt, { children: s(w.label) }) : null
|
|
1873
|
+
] }) })
|
|
1874
|
+
}
|
|
1875
|
+
) })
|
|
1876
|
+
] }) }),
|
|
1877
|
+
/* @__PURE__ */ S(T.Item, { shouldGrow: !0, shouldShrink: !0, children: [
|
|
1878
|
+
/* @__PURE__ */ i(E, { as: "div", children: _ || !h ? /* @__PURE__ */ i(
|
|
1847
1879
|
P,
|
|
1848
1880
|
{
|
|
1849
1881
|
weight: "bold",
|
|
1850
|
-
size: "
|
|
1851
|
-
|
|
1882
|
+
size: "medium",
|
|
1883
|
+
lineHeight: "condensed",
|
|
1884
|
+
color: _ ? "secondary" : "primary",
|
|
1852
1885
|
"data-testid": "module-item-title",
|
|
1853
|
-
"data-locked":
|
|
1854
|
-
children:
|
|
1886
|
+
"data-locked": _ ? "true" : void 0,
|
|
1887
|
+
children: g
|
|
1855
1888
|
}
|
|
1856
|
-
) : /* @__PURE__ */
|
|
1857
|
-
|
|
1889
|
+
) : /* @__PURE__ */ S(
|
|
1890
|
+
zn,
|
|
1858
1891
|
{
|
|
1859
|
-
href:
|
|
1860
|
-
onClick:
|
|
1892
|
+
href: h,
|
|
1893
|
+
onClick: b,
|
|
1861
1894
|
forceButtonRole: !1,
|
|
1862
|
-
variant:
|
|
1895
|
+
variant: m,
|
|
1863
1896
|
target: e.newTab ? "_blank" : void 0,
|
|
1864
1897
|
rel: e.newTab ? "noopener noreferrer" : void 0,
|
|
1865
1898
|
children: [
|
|
1866
|
-
/* @__PURE__ */ i(
|
|
1867
|
-
|
|
1899
|
+
/* @__PURE__ */ i(
|
|
1900
|
+
P,
|
|
1901
|
+
{
|
|
1902
|
+
weight: "bold",
|
|
1903
|
+
size: "medium",
|
|
1904
|
+
lineHeight: "condensed",
|
|
1905
|
+
color: "primary",
|
|
1906
|
+
"data-testid": "module-item-title",
|
|
1907
|
+
children: g
|
|
1908
|
+
}
|
|
1909
|
+
),
|
|
1910
|
+
e.newTab ? /* @__PURE__ */ i(lt, { children: ` ${s("opensInNewWindow")}` }) : null
|
|
1868
1911
|
]
|
|
1869
1912
|
}
|
|
1870
1913
|
) }),
|
|
1871
|
-
/* @__PURE__ */ i(
|
|
1872
|
-
|
|
1873
|
-
/* @__PURE__ */ i("span", { style:
|
|
1874
|
-
] },
|
|
1914
|
+
/* @__PURE__ */ i(E, { as: "div", children: /* @__PURE__ */ i(P, { size: "x-small", color: "secondary", "data-testid": "module-item-meta", children: A.map((R, G) => /* @__PURE__ */ S(At, { children: [
|
|
1915
|
+
G > 0 ? /* @__PURE__ */ i("span", { style: Mn, children: " " }) : null,
|
|
1916
|
+
/* @__PURE__ */ i("span", { style: G > 0 ? u : void 0, children: R.node })
|
|
1917
|
+
] }, R.key)) }) })
|
|
1875
1918
|
] }),
|
|
1876
|
-
e.status ? /* @__PURE__ */ i(
|
|
1877
|
-
] })
|
|
1919
|
+
e.status ? /* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ i(di, { status: e.status }) }) : null
|
|
1920
|
+
] }) })
|
|
1878
1921
|
}
|
|
1879
1922
|
) });
|
|
1880
1923
|
}
|
|
1881
|
-
const
|
|
1882
|
-
function
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
minWidth: ht,
|
|
1895
|
-
height: ht,
|
|
1896
|
-
padding: "0 xx-small",
|
|
1897
|
-
"data-testid": "module-number",
|
|
1898
|
-
children: /* @__PURE__ */ i(S, { height: "100%", alignItems: "center", justifyItems: "center", children: /* @__PURE__ */ i(P, { weight: "bold", size: "medium", color: t ? "secondary" : "primary", children: e }) })
|
|
1899
|
-
}
|
|
1900
|
-
);
|
|
1901
|
-
}
|
|
1902
|
-
function mi({ module: e, today: t }) {
|
|
1903
|
-
var a;
|
|
1904
|
-
const { t: n } = O(), o = ke(), r = ((a = e.progress) == null ? void 0 : a.status) === "locked", s = e.unlockAt;
|
|
1905
|
-
let l = null;
|
|
1906
|
-
return r && s ? l = o.unlockByline(s, t) : r ? l = n("lockedByline") : !e.progress && s && (l = o.unlockByline(s, t)), l === null ? null : /* @__PURE__ */ i(T, { as: "div", margin: "xxx-small 0 0 0", children: /* @__PURE__ */ i(P, { size: "small", color: "secondary", "data-testid": "module-byline", children: l }) });
|
|
1924
|
+
const yi = Lt(Mi), yt = "\0", Si = { textDecoration: "underline dotted", cursor: "help" };
|
|
1925
|
+
function _i({ names: e }) {
|
|
1926
|
+
const { t } = B();
|
|
1927
|
+
if (e.length === 1) return /* @__PURE__ */ i(it, { children: t("lockedByPrerequisiteByline", { name: e[0] }) });
|
|
1928
|
+
const n = t("lockedByPrerequisitesByline", {
|
|
1929
|
+
count: e.length,
|
|
1930
|
+
prerequisites: yt
|
|
1931
|
+
}), [o, ...r] = n.split(yt), s = r.length > 0 ? r.join("") : null;
|
|
1932
|
+
return /* @__PURE__ */ S(it, { children: [
|
|
1933
|
+
s === null ? null : o,
|
|
1934
|
+
/* @__PURE__ */ i(Un, { renderTip: e.join(", "), children: /* @__PURE__ */ i("span", { tabIndex: 0, style: Si, "data-testid": "module-byline-prerequisites", children: s === null ? n : t("lockedByPrerequisitesCount", { count: e.length }) }) }),
|
|
1935
|
+
s
|
|
1936
|
+
] });
|
|
1907
1937
|
}
|
|
1908
|
-
|
|
1938
|
+
function Ti({ module: e, today: t }) {
|
|
1939
|
+
var u;
|
|
1940
|
+
const n = De(), o = Sn(), r = ((u = e.progress) == null ? void 0 : u.status) === "locked", s = e.unlockAt ?? null, l = e.prerequisiteModules.map((p) => p.name.trim()).filter((p) => p !== ""), a = s !== null && new Date(s) > t;
|
|
1941
|
+
let m = null;
|
|
1942
|
+
s !== null && a && (r || !e.progress) ? m = n.unlockByline(s, t) : s !== null && !a && !e.progress && (m = n.unlockedByline(s, t));
|
|
1943
|
+
const c = r && l.length > 0;
|
|
1944
|
+
return m === null && !c ? null : /* @__PURE__ */ i(E, { as: "div", margin: "xxx-small 0 0 0", children: /* @__PURE__ */ S(P, { size: "small", color: "secondary", "data-testid": "module-byline", children: [
|
|
1945
|
+
m,
|
|
1946
|
+
m !== null && c ? /* @__PURE__ */ i("span", { style: Mn, children: " " }) : null,
|
|
1947
|
+
c ? /* @__PURE__ */ i("span", { style: m !== null ? o : void 0, children: /* @__PURE__ */ i(_i, { names: l }) }) : null
|
|
1948
|
+
] }) });
|
|
1949
|
+
}
|
|
1950
|
+
const Ei = "#273540", Pi = "#D7DADE", Ci = "0.5rem", wi = (e, t) => {
|
|
1909
1951
|
var n, o, r, s, l;
|
|
1910
1952
|
return {
|
|
1911
|
-
meterColorBrand: ((o = (n = t.colors) == null ? void 0 : n.contrasts) == null ? void 0 : o.grey125125) ??
|
|
1912
|
-
borderRadius: String(((r = t.borders) == null ? void 0 : r.radiusLarge) ??
|
|
1913
|
-
borderColor: ((l = (s = t.colors) == null ? void 0 : s.contrasts) == null ? void 0 : l.grey1424) ??
|
|
1953
|
+
meterColorBrand: ((o = (n = t.colors) == null ? void 0 : n.contrasts) == null ? void 0 : o.grey125125) ?? Ei,
|
|
1954
|
+
borderRadius: String(((r = t.borders) == null ? void 0 : r.radiusLarge) ?? Ci),
|
|
1955
|
+
borderColor: ((l = (s = t.colors) == null ? void 0 : s.contrasts) == null ? void 0 : l.grey1424) ?? Pi,
|
|
1914
1956
|
trackBottomBorderColor: "transparent"
|
|
1915
1957
|
};
|
|
1916
|
-
},
|
|
1917
|
-
function
|
|
1958
|
+
}, vi = "66.667%", Li = "8rem", Ai = 2;
|
|
1959
|
+
function Ri({
|
|
1918
1960
|
module: e,
|
|
1919
1961
|
breakpoints: t
|
|
1920
1962
|
}) {
|
|
1921
|
-
const { t: n } =
|
|
1963
|
+
const { t: n } = B(), o = De(), r = e.progress;
|
|
1922
1964
|
if (!r || r.status === "locked" || r.requirementCount <= 0) return null;
|
|
1923
1965
|
const s = t.mobileOnly, l = Object.keys(t).length === 0 || t.desktop === !0;
|
|
1924
|
-
return /* @__PURE__ */
|
|
1925
|
-
|
|
1966
|
+
return /* @__PURE__ */ S(
|
|
1967
|
+
T,
|
|
1926
1968
|
{
|
|
1927
|
-
width: l ?
|
|
1969
|
+
width: l ? vi : "100%",
|
|
1928
1970
|
direction: s ? "column" : "row",
|
|
1929
1971
|
alignItems: s ? "stretch" : "center",
|
|
1930
1972
|
wrap: "wrap",
|
|
@@ -1932,8 +1974,8 @@ function Si({
|
|
|
1932
1974
|
margin: "small 0 0 0",
|
|
1933
1975
|
"data-testid": "module-progress",
|
|
1934
1976
|
children: [
|
|
1935
|
-
/* @__PURE__ */ i(
|
|
1936
|
-
|
|
1977
|
+
/* @__PURE__ */ i(T.Item, { size: s ? void 0 : Li, shouldGrow: !0, children: /* @__PURE__ */ i(
|
|
1978
|
+
Fn,
|
|
1937
1979
|
{
|
|
1938
1980
|
size: "x-small",
|
|
1939
1981
|
meterColor: "brand",
|
|
@@ -1941,16 +1983,16 @@ function Si({
|
|
|
1941
1983
|
valueMax: r.requirementCount,
|
|
1942
1984
|
shouldAnimate: !1,
|
|
1943
1985
|
screenReaderLabel: n("moduleProgressScreenReaderLabel", { name: e.name }),
|
|
1944
|
-
formatScreenReaderValue: () =>
|
|
1986
|
+
formatScreenReaderValue: () => xs(
|
|
1945
1987
|
n,
|
|
1946
1988
|
r.percentComplete,
|
|
1947
1989
|
r.requirementsMet,
|
|
1948
1990
|
r.requirementCount
|
|
1949
1991
|
),
|
|
1950
|
-
themeOverride:
|
|
1992
|
+
themeOverride: wi
|
|
1951
1993
|
}
|
|
1952
1994
|
) }),
|
|
1953
|
-
/* @__PURE__ */ i(
|
|
1995
|
+
/* @__PURE__ */ i(T.Item, { shouldShrink: !0, "aria-hidden": "true", children: /* @__PURE__ */ i(P, { size: "small", color: "secondary", children: o.progress(
|
|
1954
1996
|
r.percentComplete,
|
|
1955
1997
|
r.requirementsMet,
|
|
1956
1998
|
r.requirementCount
|
|
@@ -1959,39 +2001,45 @@ function Si({
|
|
|
1959
2001
|
}
|
|
1960
2002
|
);
|
|
1961
2003
|
}
|
|
1962
|
-
const
|
|
1963
|
-
function
|
|
2004
|
+
const St = (e) => `platform-modules-panel-${e}`;
|
|
2005
|
+
function He(e) {
|
|
2006
|
+
return e !== void 0 && e.type !== "sub_header";
|
|
2007
|
+
}
|
|
2008
|
+
function _t(e) {
|
|
2009
|
+
return He(e) && e.indent > 0;
|
|
2010
|
+
}
|
|
2011
|
+
function xi({
|
|
1964
2012
|
module: e,
|
|
1965
2013
|
state: t,
|
|
1966
2014
|
today: n,
|
|
1967
2015
|
navigation: o,
|
|
1968
2016
|
showDiagnostics: r
|
|
1969
2017
|
}) {
|
|
1970
|
-
const { t: s } =
|
|
1971
|
-
return
|
|
1972
|
-
!m || a === 0 || l.current !== a && (l.current = a,
|
|
2018
|
+
const { t: s } = B(), l = $(null), a = t.items.length, m = !t.isLoading && !t.isFetchingNextPage;
|
|
2019
|
+
return Ie(() => {
|
|
2020
|
+
!m || a === 0 || l.current !== a && (l.current = a, Dt(
|
|
1973
2021
|
s("itemsLoadedAnnouncement", {
|
|
1974
2022
|
loaded: a,
|
|
1975
2023
|
count: e.itemCount,
|
|
1976
2024
|
name: e.name
|
|
1977
2025
|
})
|
|
1978
2026
|
));
|
|
1979
|
-
}, [m, a, e.itemCount, e.name, s]), t.error ? /* @__PURE__ */ i(
|
|
1980
|
-
|
|
2027
|
+
}, [m, a, e.itemCount, e.name, s]), t.error ? /* @__PURE__ */ i(E, { as: "div", margin: "small 0 0 0", children: /* @__PURE__ */ i(
|
|
2028
|
+
Ft,
|
|
1981
2029
|
{
|
|
1982
2030
|
variant: "error",
|
|
1983
2031
|
margin: "0",
|
|
1984
|
-
liveRegion:
|
|
2032
|
+
liveRegion: Ot,
|
|
1985
2033
|
liveRegionPoliteness: "assertive",
|
|
1986
2034
|
"data-testid": "items-error",
|
|
1987
2035
|
children: s("itemsLoadErrorAlert", { message: t.error.message })
|
|
1988
2036
|
}
|
|
1989
|
-
) }) : t.isLoading ? /* @__PURE__ */
|
|
1990
|
-
/* @__PURE__ */ i(
|
|
2037
|
+
) }) : t.isLoading ? /* @__PURE__ */ S(E, { as: "div", margin: "small 0 0 0", "data-testid": "items-loading", children: [
|
|
2038
|
+
/* @__PURE__ */ i(zt, { size: "x-small", renderTitle: s("itemsLoadingSpinnerLabel") }),
|
|
1991
2039
|
" ",
|
|
1992
2040
|
/* @__PURE__ */ i(P, { size: "small", color: "secondary", children: s("itemsLoadingText") })
|
|
1993
|
-
] }) : /* @__PURE__ */
|
|
1994
|
-
r ? /* @__PURE__ */
|
|
2041
|
+
] }) : /* @__PURE__ */ S(E, { as: "div", margin: "small 0 0 0", children: [
|
|
2042
|
+
r ? /* @__PURE__ */ S(P, { size: "x-small", color: "secondary", "data-testid": "items-source", children: [
|
|
1995
2043
|
"items source: ",
|
|
1996
2044
|
t.source,
|
|
1997
2045
|
" · loaded ",
|
|
@@ -1999,9 +2047,18 @@ function yi({
|
|
|
1999
2047
|
" of ",
|
|
2000
2048
|
e.itemCount
|
|
2001
2049
|
] }) : null,
|
|
2002
|
-
t.items.length === 0 ? /* @__PURE__ */ i(
|
|
2003
|
-
|
|
2004
|
-
|
|
2050
|
+
t.items.length === 0 ? /* @__PURE__ */ i(E, { as: "div", padding: "small", "data-testid": "items-empty", children: /* @__PURE__ */ i(P, { size: "small", color: "secondary", children: s("noItemsEmptyState") }) }) : /* @__PURE__ */ i("ul", { style: { listStyle: "none", margin: 0, padding: 0 }, "data-testid": "items-list", children: t.items.map((c, u) => /* @__PURE__ */ i("li", { children: /* @__PURE__ */ i(
|
|
2051
|
+
yi,
|
|
2052
|
+
{
|
|
2053
|
+
item: c,
|
|
2054
|
+
today: n,
|
|
2055
|
+
navigation: o,
|
|
2056
|
+
attachedAbove: _t(c) && He(t.items[u - 1]),
|
|
2057
|
+
attachedBelow: He(c) && _t(t.items[u + 1])
|
|
2058
|
+
}
|
|
2059
|
+
) }, c.id)) }),
|
|
2060
|
+
t.hasNextPage ? /* @__PURE__ */ i(E, { as: "div", margin: "small 0 0 0", textAlign: "center", children: /* @__PURE__ */ i(
|
|
2061
|
+
he,
|
|
2005
2062
|
{
|
|
2006
2063
|
size: "small",
|
|
2007
2064
|
onClick: t.fetchNextPage,
|
|
@@ -2015,7 +2072,7 @@ function yi({
|
|
|
2015
2072
|
) }) : null
|
|
2016
2073
|
] });
|
|
2017
2074
|
}
|
|
2018
|
-
function
|
|
2075
|
+
function Ni({
|
|
2019
2076
|
module: e,
|
|
2020
2077
|
expanded: t,
|
|
2021
2078
|
onToggle: n,
|
|
@@ -2025,12 +2082,19 @@ function _i({
|
|
|
2025
2082
|
showDiagnostics: l = !1,
|
|
2026
2083
|
headingLevel: a = "h3",
|
|
2027
2084
|
moduleLabel: m,
|
|
2028
|
-
breakpoints:
|
|
2085
|
+
breakpoints: c = {}
|
|
2029
2086
|
}) {
|
|
2030
|
-
var
|
|
2031
|
-
const { t: u } =
|
|
2032
|
-
|
|
2033
|
-
|
|
2087
|
+
var C, b;
|
|
2088
|
+
const { t: u } = B(), p = De(), f = ((C = e.progress) == null ? void 0 : C.status) === "locked", y = m === void 0 ? p.moduleLabel(e.position, e) : m, g = (y == null ? void 0 : y.trim()) || null, h = c.mobileOnly === !0, _ = (b = e.progress) != null && b.status ? /* @__PURE__ */ i(
|
|
2089
|
+
ci,
|
|
2090
|
+
{
|
|
2091
|
+
status: e.progress.status,
|
|
2092
|
+
missingCount: e.progress.missingCount,
|
|
2093
|
+
incompleteCount: e.progress.incompleteCount
|
|
2094
|
+
}
|
|
2095
|
+
) : null;
|
|
2096
|
+
return /* @__PURE__ */ S(
|
|
2097
|
+
E,
|
|
2034
2098
|
{
|
|
2035
2099
|
as: "div",
|
|
2036
2100
|
background: "primary",
|
|
@@ -2041,55 +2105,48 @@ function _i({
|
|
|
2041
2105
|
margin: "0 0 small 0",
|
|
2042
2106
|
"data-testid": `module-card-${e.id}`,
|
|
2043
2107
|
children: [
|
|
2044
|
-
/* @__PURE__ */
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
/* @__PURE__ */ _(T, { as: "div", children: [
|
|
2108
|
+
/* @__PURE__ */ S(T, { alignItems: "start", gap: "mediumSmall", "data-testid": "module-header", children: [
|
|
2109
|
+
/* @__PURE__ */ S(T.Item, { shouldGrow: !0, shouldShrink: !0, children: [
|
|
2110
|
+
/* @__PURE__ */ S(E, { as: "div", children: [
|
|
2048
2111
|
/* @__PURE__ */ i(
|
|
2049
|
-
|
|
2112
|
+
Ut,
|
|
2050
2113
|
{
|
|
2051
2114
|
level: a,
|
|
2052
2115
|
variant: "titleCardRegular",
|
|
2053
2116
|
color: f ? "secondary" : "primary",
|
|
2054
2117
|
"data-testid": "module-name",
|
|
2055
|
-
children: /* @__PURE__ */ i(
|
|
2118
|
+
children: /* @__PURE__ */ i(On, { linesAllowed: Ai, children: g ? u("moduleNameWithLabel", { label: g, name: e.name }) : e.name })
|
|
2056
2119
|
}
|
|
2057
2120
|
),
|
|
2058
|
-
e.published ? null : /* @__PURE__ */
|
|
2121
|
+
e.published ? null : /* @__PURE__ */ S(P, { size: "x-small", color: "secondary", children: [
|
|
2059
2122
|
" ",
|
|
2060
2123
|
u("moduleUnpublishedBadge")
|
|
2061
2124
|
] })
|
|
2062
2125
|
] }),
|
|
2063
|
-
/* @__PURE__ */ i(
|
|
2064
|
-
/* @__PURE__ */ i(
|
|
2126
|
+
/* @__PURE__ */ i(Ti, { module: e, today: r }),
|
|
2127
|
+
h && _ ? /* @__PURE__ */ i(E, { as: "div", margin: "x-small 0 0 0", children: _ }) : null,
|
|
2128
|
+
/* @__PURE__ */ i(Ri, { module: e, breakpoints: c })
|
|
2065
2129
|
] }),
|
|
2066
|
-
/* @__PURE__ */ i(
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
status: e.progress.status,
|
|
2071
|
-
missingCount: e.progress.missingCount,
|
|
2072
|
-
incompleteCount: e.progress.incompleteCount
|
|
2073
|
-
}
|
|
2074
|
-
) }) : null,
|
|
2075
|
-
/* @__PURE__ */ i(S.Item, { children: /* @__PURE__ */ i(
|
|
2076
|
-
wn,
|
|
2130
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(T, { alignItems: "center", gap: "mediumSmall", children: [
|
|
2131
|
+
!h && _ ? /* @__PURE__ */ i(T.Item, { children: _ }) : null,
|
|
2132
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ i(
|
|
2133
|
+
Dn,
|
|
2077
2134
|
{
|
|
2078
2135
|
size: "medium",
|
|
2079
2136
|
withBorder: !0,
|
|
2080
2137
|
withBackground: !1,
|
|
2081
2138
|
screenReaderLabel: t ? u("collapseModule", { name: e.name }) : u("expandModule", { name: e.name }),
|
|
2082
2139
|
"aria-expanded": t,
|
|
2083
|
-
"aria-controls":
|
|
2140
|
+
"aria-controls": St(e.id),
|
|
2084
2141
|
onClick: () => n(e.id),
|
|
2085
2142
|
"data-testid": `toggle-module-${e.id}`,
|
|
2086
|
-
children: t ? /* @__PURE__ */ i(
|
|
2143
|
+
children: t ? /* @__PURE__ */ i(Nn, {}) : /* @__PURE__ */ i(qt, {})
|
|
2087
2144
|
}
|
|
2088
2145
|
) })
|
|
2089
2146
|
] }) })
|
|
2090
2147
|
] }),
|
|
2091
|
-
/* @__PURE__ */ i("div", { id:
|
|
2092
|
-
|
|
2148
|
+
/* @__PURE__ */ i("div", { id: St(e.id), role: "group", "aria-label": e.name, hidden: !t, children: t ? /* @__PURE__ */ i(
|
|
2149
|
+
xi,
|
|
2093
2150
|
{
|
|
2094
2151
|
module: e,
|
|
2095
2152
|
state: o,
|
|
@@ -2102,15 +2159,15 @@ function _i({
|
|
|
2102
2159
|
}
|
|
2103
2160
|
);
|
|
2104
2161
|
}
|
|
2105
|
-
const
|
|
2106
|
-
function
|
|
2162
|
+
const qi = Lt(Ni);
|
|
2163
|
+
function ki({
|
|
2107
2164
|
counts: e,
|
|
2108
2165
|
itemsMode: t,
|
|
2109
2166
|
loadedModules: n
|
|
2110
2167
|
}) {
|
|
2111
2168
|
const o = e.listModules + e.listModuleItems;
|
|
2112
2169
|
return /* @__PURE__ */ i(
|
|
2113
|
-
|
|
2170
|
+
E,
|
|
2114
2171
|
{
|
|
2115
2172
|
as: "div",
|
|
2116
2173
|
background: "secondary",
|
|
@@ -2119,25 +2176,25 @@ function Ei({
|
|
|
2119
2176
|
padding: "x-small small",
|
|
2120
2177
|
margin: "0 0 small 0",
|
|
2121
2178
|
"data-testid": "dev-diagnostics",
|
|
2122
|
-
children: /* @__PURE__ */
|
|
2123
|
-
/* @__PURE__ */ i(
|
|
2124
|
-
/* @__PURE__ */ i(
|
|
2179
|
+
children: /* @__PURE__ */ S(T, { gap: "medium", wrap: "wrap", children: [
|
|
2180
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ i(P, { size: "x-small", weight: "bold", children: "Adapter requests" }) }),
|
|
2181
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(P, { size: "x-small", "data-testid": "request-count-list-modules", children: [
|
|
2125
2182
|
"listModules: ",
|
|
2126
2183
|
e.listModules
|
|
2127
2184
|
] }) }),
|
|
2128
|
-
/* @__PURE__ */ i(
|
|
2185
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(P, { size: "x-small", "data-testid": "request-count-list-module-items", children: [
|
|
2129
2186
|
"listModuleItems: ",
|
|
2130
2187
|
e.listModuleItems
|
|
2131
2188
|
] }) }),
|
|
2132
|
-
/* @__PURE__ */ i(
|
|
2189
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(P, { size: "x-small", weight: "bold", "data-testid": "request-count-total", children: [
|
|
2133
2190
|
"total: ",
|
|
2134
2191
|
o
|
|
2135
2192
|
] }) }),
|
|
2136
|
-
/* @__PURE__ */ i(
|
|
2193
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(P, { size: "x-small", "data-testid": "resolved-items-mode", children: [
|
|
2137
2194
|
"itemsMode: ",
|
|
2138
2195
|
t ?? "probing…"
|
|
2139
2196
|
] }) }),
|
|
2140
|
-
/* @__PURE__ */ i(
|
|
2197
|
+
/* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(P, { size: "x-small", "data-testid": "modules-loaded-count", children: [
|
|
2141
2198
|
"modules loaded: ",
|
|
2142
2199
|
n
|
|
2143
2200
|
] }) })
|
|
@@ -2145,7 +2202,7 @@ function Ei({
|
|
|
2145
2202
|
}
|
|
2146
2203
|
);
|
|
2147
2204
|
}
|
|
2148
|
-
function
|
|
2205
|
+
function Di({
|
|
2149
2206
|
data: e,
|
|
2150
2207
|
courseName: t,
|
|
2151
2208
|
courseContext: n,
|
|
@@ -2155,123 +2212,105 @@ function Pi({
|
|
|
2155
2212
|
navigation: l,
|
|
2156
2213
|
as: a = "div",
|
|
2157
2214
|
headingLevel: m = "h2",
|
|
2158
|
-
breakpoints:
|
|
2215
|
+
breakpoints: c = {}
|
|
2159
2216
|
}) {
|
|
2160
|
-
const { miniTablet: u, tablet: p, desktop: f, desktopNavOpen:
|
|
2161
|
-
() => ({ miniTablet: u, tablet: p, desktop: f, desktopNavOpen:
|
|
2162
|
-
[u, p, f,
|
|
2217
|
+
const { miniTablet: u, tablet: p, desktop: f, desktopNavOpen: y, desktopOnly: g, mobileOnly: h, ICEDesktop: _ } = c, C = N(
|
|
2218
|
+
() => ({ miniTablet: u, tablet: p, desktop: f, desktopNavOpen: y, desktopOnly: g, mobileOnly: h, ICEDesktop: _ }),
|
|
2219
|
+
[u, p, f, y, g, h, _]
|
|
2163
2220
|
), {
|
|
2164
|
-
modules:
|
|
2165
|
-
hasNextPage:
|
|
2166
|
-
fetchNextPage:
|
|
2221
|
+
modules: b,
|
|
2222
|
+
hasNextPage: w,
|
|
2223
|
+
fetchNextPage: k,
|
|
2167
2224
|
isFetchingNextPage: q,
|
|
2168
|
-
isLoading:
|
|
2169
|
-
error:
|
|
2170
|
-
itemsMode:
|
|
2171
|
-
expandedModuleIds:
|
|
2172
|
-
toggleModule:
|
|
2173
|
-
expandModule:
|
|
2174
|
-
|
|
2175
|
-
getItems:
|
|
2176
|
-
filter:
|
|
2177
|
-
setFilter:
|
|
2178
|
-
filterEntry:
|
|
2179
|
-
filterPredicate:
|
|
2180
|
-
filterResultsArePartial:
|
|
2181
|
-
} = e, { t:
|
|
2182
|
-
|
|
2183
|
-
var
|
|
2184
|
-
!
|
|
2185
|
-
}, [q,
|
|
2186
|
-
const
|
|
2187
|
-
() =>
|
|
2188
|
-
(
|
|
2225
|
+
isLoading: A,
|
|
2226
|
+
error: D,
|
|
2227
|
+
itemsMode: j,
|
|
2228
|
+
expandedModuleIds: Q,
|
|
2229
|
+
toggleModule: O,
|
|
2230
|
+
expandModule: R,
|
|
2231
|
+
collapseAllModules: G,
|
|
2232
|
+
getItems: se,
|
|
2233
|
+
filter: ie,
|
|
2234
|
+
setFilter: le,
|
|
2235
|
+
filterEntry: Ue,
|
|
2236
|
+
filterPredicate: K,
|
|
2237
|
+
filterResultsArePartial: ae
|
|
2238
|
+
} = e, { t: L, timezone: ue } = B(), Z = t ?? L("pageTitle"), U = $(null), Y = vt(), X = $(!1), [ce] = Le(() => /* @__PURE__ */ new Date()), z = o ?? ce;
|
|
2239
|
+
Ie(() => {
|
|
2240
|
+
var x;
|
|
2241
|
+
!X.current || q || (X.current = !1, Dt(L("modulesLoadedAnnouncement", { count: b.length })), (x = U.current) == null || x.focus());
|
|
2242
|
+
}, [q, b.length, L]);
|
|
2243
|
+
const de = N(
|
|
2244
|
+
() => b.filter(
|
|
2245
|
+
(x) => K === void 0 || K(x, { today: z, timezone: ue })
|
|
2189
2246
|
),
|
|
2190
|
-
[
|
|
2191
|
-
),
|
|
2192
|
-
for (const
|
|
2193
|
-
},
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
return /* @__PURE__ */ _(T, { as: a, display: "block", "data-testid": "modules-list", children: [
|
|
2197
|
-
n ? /* @__PURE__ */ _(T, { as: "div", children: [
|
|
2247
|
+
[b, K, z, ue]
|
|
2248
|
+
), ze = () => {
|
|
2249
|
+
for (const x of de) R(x.id);
|
|
2250
|
+
}, _e = G, me = Ue !== void 0 && ie !== V, Te = de.length === 0 && !A && !D, Ee = Te && me;
|
|
2251
|
+
return /* @__PURE__ */ S(E, { as: a, display: "block", "data-testid": "modules-list", children: [
|
|
2252
|
+
n ? /* @__PURE__ */ S(E, { as: "div", children: [
|
|
2198
2253
|
/* @__PURE__ */ i(P, { size: "small", color: "brand", children: n }),
|
|
2199
|
-
/* @__PURE__ */
|
|
2254
|
+
/* @__PURE__ */ S(P, { size: "small", color: "secondary", children: [
|
|
2200
2255
|
" ",
|
|
2201
2256
|
"/",
|
|
2202
2257
|
" "
|
|
2203
2258
|
] }),
|
|
2204
|
-
/* @__PURE__ */ i(P, { size: "small", color: "secondary", children:
|
|
2259
|
+
/* @__PURE__ */ i(P, { size: "small", color: "secondary", children: Z })
|
|
2205
2260
|
] }) : null,
|
|
2206
|
-
/* @__PURE__ */ i(
|
|
2261
|
+
/* @__PURE__ */ i(Ut, { level: m, margin: "x-small 0 medium 0", children: Z }),
|
|
2207
2262
|
r ? /* @__PURE__ */ i(
|
|
2208
|
-
|
|
2263
|
+
ki,
|
|
2209
2264
|
{
|
|
2210
2265
|
counts: r,
|
|
2211
|
-
itemsMode:
|
|
2212
|
-
loadedModules:
|
|
2266
|
+
itemsMode: j,
|
|
2267
|
+
loadedModules: b.length
|
|
2213
2268
|
}
|
|
2214
2269
|
) : null,
|
|
2215
|
-
/* @__PURE__ */
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
"
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
}
|
|
2227
|
-
) }),
|
|
2228
|
-
/* @__PURE__ */ i(S.Item, { shouldGrow: !0 }),
|
|
2229
|
-
/* @__PURE__ */ i(S.Item, { children: /* @__PURE__ */ _(
|
|
2230
|
-
ze,
|
|
2231
|
-
{
|
|
2232
|
-
placement: "bottom end",
|
|
2233
|
-
trigger: /* @__PURE__ */ i(me, { renderIcon: /* @__PURE__ */ i(vt, {}), "data-testid": "expand-collapse-trigger", children: C("expandCollapseTrigger") }),
|
|
2234
|
-
children: [
|
|
2235
|
-
/* @__PURE__ */ i(ze.Item, { onSelect: L, "data-testid": "expand-all", children: C("expandAll") }),
|
|
2236
|
-
/* @__PURE__ */ i(ze.Item, { onSelect: ae, "data-testid": "collapse-all", children: C("collapseAll") })
|
|
2237
|
-
]
|
|
2238
|
-
}
|
|
2239
|
-
) })
|
|
2240
|
-
] }),
|
|
2241
|
-
/* @__PURE__ */ i(T, { as: "div", margin: "xx-small 0 0 0", children: /* @__PURE__ */ i(P, { size: "x-small", color: "secondary", id: le, children: C("searchScopeHint") }) }),
|
|
2270
|
+
/* @__PURE__ */ i(T, { justifyItems: "end", children: /* @__PURE__ */ i(T.Item, { children: /* @__PURE__ */ S(
|
|
2271
|
+
$e,
|
|
2272
|
+
{
|
|
2273
|
+
placement: "bottom end",
|
|
2274
|
+
trigger: /* @__PURE__ */ i(he, { renderIcon: /* @__PURE__ */ i(qt, {}), "data-testid": "expand-collapse-trigger", children: L("expandCollapseTrigger") }),
|
|
2275
|
+
children: [
|
|
2276
|
+
/* @__PURE__ */ i($e.Item, { onSelect: ze, "data-testid": "expand-all", children: L("expandAll") }),
|
|
2277
|
+
/* @__PURE__ */ i($e.Item, { onSelect: _e, "data-testid": "collapse-all", children: L("collapseAll") })
|
|
2278
|
+
]
|
|
2279
|
+
}
|
|
2280
|
+
) }) }),
|
|
2242
2281
|
/* @__PURE__ */ i(
|
|
2243
|
-
|
|
2282
|
+
oi,
|
|
2244
2283
|
{
|
|
2245
|
-
value:
|
|
2246
|
-
onChange:
|
|
2247
|
-
describedBy:
|
|
2284
|
+
value: ie,
|
|
2285
|
+
onChange: le,
|
|
2286
|
+
describedBy: ae ? Y : void 0
|
|
2248
2287
|
}
|
|
2249
2288
|
),
|
|
2250
|
-
|
|
2289
|
+
ae ? /* @__PURE__ */ i(E, { as: "div", margin: "x-small 0 0 0", children: /* @__PURE__ */ i(
|
|
2251
2290
|
P,
|
|
2252
2291
|
{
|
|
2253
2292
|
size: "x-small",
|
|
2254
2293
|
color: "secondary",
|
|
2255
|
-
id:
|
|
2294
|
+
id: Y,
|
|
2256
2295
|
"data-testid": "filter-partial-hint",
|
|
2257
|
-
children:
|
|
2296
|
+
children: L("filterScopeHint")
|
|
2258
2297
|
}
|
|
2259
2298
|
) }) : null,
|
|
2260
|
-
/* @__PURE__ */
|
|
2261
|
-
|
|
2262
|
-
|
|
2299
|
+
/* @__PURE__ */ S(E, { as: "div", margin: "medium 0 0 0", children: [
|
|
2300
|
+
D ? /* @__PURE__ */ i(
|
|
2301
|
+
Ft,
|
|
2263
2302
|
{
|
|
2264
2303
|
variant: "error",
|
|
2265
2304
|
margin: "0 0 small 0",
|
|
2266
|
-
liveRegion:
|
|
2305
|
+
liveRegion: Ot,
|
|
2267
2306
|
liveRegionPoliteness: "assertive",
|
|
2268
2307
|
"data-testid": "modules-error",
|
|
2269
|
-
children:
|
|
2308
|
+
children: L("modulesLoadErrorAlert", { message: D.message })
|
|
2270
2309
|
}
|
|
2271
2310
|
) : null,
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2311
|
+
A ? /* @__PURE__ */ i(E, { as: "div", padding: "large", textAlign: "center", "data-testid": "modules-loading", children: /* @__PURE__ */ i(zt, { renderTitle: L("modulesLoadingSpinnerLabel") }) }) : null,
|
|
2312
|
+
Te && !me ? /* @__PURE__ */ i(
|
|
2313
|
+
E,
|
|
2275
2314
|
{
|
|
2276
2315
|
as: "div",
|
|
2277
2316
|
background: "secondary",
|
|
@@ -2279,11 +2318,11 @@ function Pi({
|
|
|
2279
2318
|
padding: "large",
|
|
2280
2319
|
textAlign: "center",
|
|
2281
2320
|
"data-testid": "modules-empty",
|
|
2282
|
-
children: /* @__PURE__ */ i(P, { color: "secondary", children:
|
|
2321
|
+
children: /* @__PURE__ */ i(P, { color: "secondary", children: L("noModulesEmptyState") })
|
|
2283
2322
|
}
|
|
2284
2323
|
) : null,
|
|
2285
|
-
|
|
2286
|
-
|
|
2324
|
+
Ee ? /* @__PURE__ */ S(
|
|
2325
|
+
E,
|
|
2287
2326
|
{
|
|
2288
2327
|
as: "div",
|
|
2289
2328
|
background: "secondary",
|
|
@@ -2292,64 +2331,64 @@ function Pi({
|
|
|
2292
2331
|
textAlign: "center",
|
|
2293
2332
|
"data-testid": "modules-filtered-empty",
|
|
2294
2333
|
children: [
|
|
2295
|
-
/* @__PURE__ */ i(
|
|
2334
|
+
/* @__PURE__ */ i(E, { as: "div", margin: "0 0 small 0", children: /* @__PURE__ */ i(P, { color: "secondary", children: b.length === 0 ? L("noFilterMatches") : L("filteredEmptyState", { count: b.length }) }) }),
|
|
2296
2335
|
/* @__PURE__ */ i(
|
|
2297
|
-
|
|
2336
|
+
he,
|
|
2298
2337
|
{
|
|
2299
2338
|
size: "small",
|
|
2300
2339
|
onClick: () => {
|
|
2301
|
-
|
|
2340
|
+
le(V), X.current = !0;
|
|
2302
2341
|
},
|
|
2303
|
-
children:
|
|
2342
|
+
children: L("clearFilters")
|
|
2304
2343
|
}
|
|
2305
2344
|
)
|
|
2306
2345
|
]
|
|
2307
2346
|
}
|
|
2308
2347
|
) : null,
|
|
2309
|
-
/* @__PURE__ */ i("ul", { style: { listStyle: "none", margin: 0, padding: 0 }, "data-testid": "modules-stack", children:
|
|
2310
|
-
|
|
2348
|
+
/* @__PURE__ */ i("ul", { style: { listStyle: "none", margin: 0, padding: 0 }, "data-testid": "modules-stack", children: de.map((x) => /* @__PURE__ */ i("li", { children: /* @__PURE__ */ i(
|
|
2349
|
+
qi,
|
|
2311
2350
|
{
|
|
2312
|
-
module:
|
|
2313
|
-
expanded:
|
|
2314
|
-
onToggle:
|
|
2315
|
-
itemsState:
|
|
2316
|
-
today:
|
|
2351
|
+
module: x,
|
|
2352
|
+
expanded: Q.includes(x.id),
|
|
2353
|
+
onToggle: O,
|
|
2354
|
+
itemsState: se(x.id),
|
|
2355
|
+
today: z,
|
|
2317
2356
|
showDiagnostics: s,
|
|
2318
2357
|
navigation: l,
|
|
2319
2358
|
headingLevel: m === "h1" ? "h2" : "h3",
|
|
2320
|
-
breakpoints:
|
|
2359
|
+
breakpoints: C
|
|
2321
2360
|
}
|
|
2322
|
-
) },
|
|
2361
|
+
) }, x.id)) })
|
|
2323
2362
|
] }),
|
|
2324
|
-
|
|
2325
|
-
|
|
2363
|
+
w ? /* @__PURE__ */ i(E, { as: "div", textAlign: "center", margin: "small 0 0 0", children: /* @__PURE__ */ i(
|
|
2364
|
+
he,
|
|
2326
2365
|
{
|
|
2327
2366
|
color: "primary",
|
|
2328
2367
|
onClick: () => {
|
|
2329
|
-
|
|
2368
|
+
X.current = !0, k();
|
|
2330
2369
|
},
|
|
2331
2370
|
interaction: q ? "disabled" : "enabled",
|
|
2332
2371
|
"data-testid": "load-more-modules",
|
|
2333
|
-
children: q ?
|
|
2372
|
+
children: q ? L("loadMoreModulesLoading") : L("loadMoreModules", { count: b.length })
|
|
2334
2373
|
}
|
|
2335
|
-
) }) :
|
|
2374
|
+
) }) : b.length > 0 ? /* @__PURE__ */ i(E, { as: "div", textAlign: "center", margin: "small 0 0 0", children: /* @__PURE__ */ i(
|
|
2336
2375
|
P,
|
|
2337
2376
|
{
|
|
2338
2377
|
size: "x-small",
|
|
2339
2378
|
color: "secondary",
|
|
2340
2379
|
"data-testid": "modules-all-loaded",
|
|
2341
|
-
elementRef: (
|
|
2342
|
-
|
|
2380
|
+
elementRef: (x) => {
|
|
2381
|
+
U.current = x;
|
|
2343
2382
|
},
|
|
2344
2383
|
tabIndex: -1,
|
|
2345
|
-
children:
|
|
2384
|
+
children: L("allModulesLoaded", { count: b.length })
|
|
2346
2385
|
}
|
|
2347
2386
|
) }) : null
|
|
2348
2387
|
] });
|
|
2349
2388
|
}
|
|
2350
|
-
const
|
|
2351
|
-
|
|
2352
|
-
),
|
|
2389
|
+
const jl = Bn(
|
|
2390
|
+
Di
|
|
2391
|
+
), be = [
|
|
2353
2392
|
"assignment",
|
|
2354
2393
|
"quiz",
|
|
2355
2394
|
"discussion",
|
|
@@ -2358,7 +2397,7 @@ const Rl = Rn(
|
|
|
2358
2397
|
"external_url",
|
|
2359
2398
|
"external_tool",
|
|
2360
2399
|
"sub_header"
|
|
2361
|
-
],
|
|
2400
|
+
], Ve = [
|
|
2362
2401
|
"not_started",
|
|
2363
2402
|
"in_progress",
|
|
2364
2403
|
"complete",
|
|
@@ -2366,28 +2405,28 @@ const Rl = Rn(
|
|
|
2366
2405
|
"incomplete",
|
|
2367
2406
|
"missing_and_incomplete",
|
|
2368
2407
|
"locked"
|
|
2369
|
-
],
|
|
2408
|
+
], _n = [
|
|
2370
2409
|
"must_view",
|
|
2371
2410
|
"must_submit",
|
|
2372
2411
|
"must_contribute",
|
|
2373
2412
|
"must_mark_done",
|
|
2374
2413
|
"min_score",
|
|
2375
2414
|
"min_percentage"
|
|
2376
|
-
],
|
|
2415
|
+
], Oi = ["assignment", "quiz", "discussion"], Fi = ["external_url", "external_tool"], Ui = ["assignment", "quiz", "discussion"], zi = Date.UTC(2025, 0, 6), $i = 864e5, re = "1", Tn = (e) => new Date(zi + e * $i).toISOString(), Ne = [
|
|
2377
2416
|
"min_score",
|
|
2378
2417
|
"min_percentage"
|
|
2379
|
-
],
|
|
2418
|
+
], Bi = _n.filter(
|
|
2380
2419
|
(e) => !Ne.includes(e)
|
|
2381
|
-
),
|
|
2420
|
+
), ji = [
|
|
2382
2421
|
"in_progress",
|
|
2383
2422
|
"incomplete",
|
|
2384
2423
|
"missing_and_incomplete"
|
|
2385
|
-
],
|
|
2386
|
-
const r = n ?
|
|
2424
|
+
], Gi = (e, t, n, o) => {
|
|
2425
|
+
const r = n ? _n : Bi, s = n && o ? Ne[t % Ne.length] : r[Math.floor(t / 3) % r.length];
|
|
2387
2426
|
return s === "min_score" ? { itemId: e, type: s, minScore: 10 } : s === "min_percentage" ? { itemId: e, type: s, minPercentage: 80 } : { itemId: e, type: s };
|
|
2388
|
-
},
|
|
2427
|
+
}, Yi = (e, t, n, o) => e === "sub_header" ? !1 : n && o || t % 3 === 0, nt = (e) => Ve[(e - 1) % Ve.length], Wi = (e, t) => !Ui.includes(e) || e === "discussion" && Math.floor(t / be.length) % 2 === 1 ? null : 5 + t % 4 * 5, Qi = (e, t, n, o) => t ? e === "missing" ? n != null || o % 2 === 0 : e === "missing_and_incomplete" ? o % 2 === 1 : !1 : !1, Hi = (e, t, n, o) => {
|
|
2389
2428
|
if (e === "locked") return "locked";
|
|
2390
|
-
if (
|
|
2429
|
+
if (Qi(e, t, n, o)) return "missing";
|
|
2391
2430
|
if (!n) return;
|
|
2392
2431
|
const r = t && Ne.includes(n.type);
|
|
2393
2432
|
switch (e) {
|
|
@@ -2404,37 +2443,37 @@ const Rl = Rn(
|
|
|
2404
2443
|
default:
|
|
2405
2444
|
return e;
|
|
2406
2445
|
}
|
|
2407
|
-
},
|
|
2408
|
-
const m = String(e),
|
|
2446
|
+
}, Vi = (e) => e.status === "complete", Ki = (e, t, n, o, r, s, l, a) => {
|
|
2447
|
+
const m = String(e), c = be[o % be.length], u = c === "sub_header", p = Oi.includes(c) && (o % 4 === 0 || r === "missing");
|
|
2409
2448
|
return {
|
|
2410
2449
|
id: n,
|
|
2411
2450
|
moduleId: m,
|
|
2412
|
-
title: `${
|
|
2413
|
-
type:
|
|
2451
|
+
title: `${c} ${t + 1}`,
|
|
2452
|
+
type: c,
|
|
2414
2453
|
position: t + 1,
|
|
2415
2454
|
indent: t % 5 === 4 ? 1 : 0,
|
|
2416
2455
|
published: a === "teacher" ? o % 7 !== 0 : !0,
|
|
2417
|
-
url: u ? null : `/courses/${
|
|
2418
|
-
newTab:
|
|
2456
|
+
url: u ? null : `/courses/${re}/modules/items/${n}`,
|
|
2457
|
+
newTab: Fi.includes(c) && o % 2 === 0,
|
|
2419
2458
|
completionRequirement: l,
|
|
2420
|
-
dueAt: p ?
|
|
2459
|
+
dueAt: p ? Tn(o % 90) : null,
|
|
2421
2460
|
status: r,
|
|
2422
2461
|
pointsPossible: s,
|
|
2423
|
-
extensions:
|
|
2462
|
+
extensions: Ze(
|
|
2424
2463
|
void 0,
|
|
2425
2464
|
o % 37 === 0 ? 5 + o % 4 * 10 : null
|
|
2426
2465
|
)
|
|
2427
2466
|
};
|
|
2428
|
-
},
|
|
2429
|
-
const r =
|
|
2467
|
+
}, Zi = (e, t, n, o) => {
|
|
2468
|
+
const r = nt(e), s = ji.includes(r), l = [];
|
|
2430
2469
|
let a = 0;
|
|
2431
2470
|
for (let m = 0; m < t; m += 1) {
|
|
2432
|
-
const
|
|
2433
|
-
l.push(
|
|
2471
|
+
const c = n + m, u = be[c % be.length], p = Wi(u, c), f = p !== null, y = f ? a++ : m, g = String(e * 1e3 + m + 1), h = Yi(u, c, f, s) ? Gi(g, c, f, s) : null, _ = Hi(r, f, h, y);
|
|
2472
|
+
l.push(Ki(e, m, g, c, _, p, h, o));
|
|
2434
2473
|
}
|
|
2435
2474
|
return l;
|
|
2436
|
-
},
|
|
2437
|
-
const r =
|
|
2475
|
+
}, Xi = (e, t, n, o) => {
|
|
2476
|
+
const r = nt(e);
|
|
2438
2477
|
if (r === "locked" || r === "not_started") return r;
|
|
2439
2478
|
if (t.length === 0) return "not_started";
|
|
2440
2479
|
if (!t.some((s) => s.pointsPossible != null) || r === "missing" && n === 0 || r === "incomplete" && o === 0) return "in_progress";
|
|
@@ -2444,39 +2483,36 @@ const Rl = Rn(
|
|
|
2444
2483
|
if (o === 0) return "missing";
|
|
2445
2484
|
}
|
|
2446
2485
|
return r;
|
|
2447
|
-
},
|
|
2448
|
-
const
|
|
2449
|
-
return t.length > 0 ? t[t.length - 1] : null;
|
|
2450
|
-
}, ji = (e, t, n) => {
|
|
2451
|
-
const o = t.filter((d) => d.completionRequirement), r = n ?? o.length, s = Math.min(o.filter(Fi).length, r), l = t.filter((d) => d.status === "missing").length, a = t.filter((d) => d.status === "incomplete").length;
|
|
2486
|
+
}, Ji = (e) => e.map((n) => n.dueAt).filter((n) => typeof n == "string").sort()[0] ?? null, el = (e, t, n) => {
|
|
2487
|
+
const o = t.filter((c) => c.completionRequirement), r = n ?? o.length, s = Math.min(o.filter(Vi).length, r), l = t.filter((c) => c.status === "missing").length, a = t.filter((c) => c.status === "incomplete").length;
|
|
2452
2488
|
return {
|
|
2453
|
-
status:
|
|
2489
|
+
status: Xi(e, t, l, a),
|
|
2454
2490
|
requirementsMet: s,
|
|
2455
2491
|
requirementCount: r,
|
|
2456
2492
|
percentComplete: r > 0 ? Math.round(s / r * 100) : 0,
|
|
2457
|
-
|
|
2493
|
+
nextDueAt: Ji(t),
|
|
2458
2494
|
missingCount: l,
|
|
2459
2495
|
incompleteCount: a
|
|
2460
2496
|
};
|
|
2461
|
-
},
|
|
2462
|
-
const o =
|
|
2497
|
+
}, tl = (e, t, n) => {
|
|
2498
|
+
const o = nt(e), r = e % 2 !== 0 && o !== "incomplete" && o !== "missing_and_incomplete" ? 1 : null;
|
|
2463
2499
|
return {
|
|
2464
2500
|
id: String(e),
|
|
2465
2501
|
name: `Module ${e}`,
|
|
2466
2502
|
position: e,
|
|
2467
2503
|
published: n === "teacher" ? e % 4 !== 0 : !0,
|
|
2468
2504
|
itemCount: t.length,
|
|
2469
|
-
unlockAt: e % 5 === 0 ?
|
|
2505
|
+
unlockAt: e % 5 === 0 ? Tn(e) : null,
|
|
2470
2506
|
prerequisiteModules: e > 1 && e % 3 === 0 ? [{ id: String(e - 1), name: `Module ${e - 1}` }] : [],
|
|
2471
2507
|
requirementCount: r,
|
|
2472
2508
|
requireSequentialProgress: e % 6 === 0,
|
|
2473
2509
|
completionRequirements: t.flatMap(
|
|
2474
2510
|
(s) => s.completionRequirement ? [s.completionRequirement] : []
|
|
2475
2511
|
),
|
|
2476
|
-
progress:
|
|
2512
|
+
progress: el(e, t, r)
|
|
2477
2513
|
};
|
|
2478
2514
|
};
|
|
2479
|
-
function
|
|
2515
|
+
function nl(e) {
|
|
2480
2516
|
return {
|
|
2481
2517
|
courseId: e.courseId,
|
|
2482
2518
|
modules: e.modules.map(({ progress: t, ...n }) => n),
|
|
@@ -2489,30 +2525,30 @@ function Yi(e) {
|
|
|
2489
2525
|
};
|
|
2490
2526
|
}
|
|
2491
2527
|
function Fe(e, t = {}) {
|
|
2492
|
-
const n = t.view ?? "student", o = t.courseId ??
|
|
2528
|
+
const n = t.view ?? "student", o = t.courseId ?? re, r = [], s = {};
|
|
2493
2529
|
let l = 0;
|
|
2494
|
-
e.forEach((m,
|
|
2495
|
-
const u =
|
|
2496
|
-
l += m, r.push(
|
|
2530
|
+
e.forEach((m, c) => {
|
|
2531
|
+
const u = c + 1, p = Zi(u, m, l, n);
|
|
2532
|
+
l += m, r.push(tl(u, p, n)), s[String(u)] = p;
|
|
2497
2533
|
});
|
|
2498
2534
|
const a = { courseId: o, modules: r, itemsByModuleId: s };
|
|
2499
|
-
return n === "teacher" ?
|
|
2535
|
+
return n === "teacher" ? nl(a) : a;
|
|
2500
2536
|
}
|
|
2501
|
-
const
|
|
2502
|
-
function
|
|
2503
|
-
return Fe(Array.from({ length:
|
|
2537
|
+
const fe = (e) => `/courses/${re}/modules/items/${e}`, Tt = "2099-08-31T06:59:00Z", ol = "2020-01-06T07:00:00Z", rl = Ve.length, sl = 8, il = 120, ll = 25, al = 250, Et = 8;
|
|
2538
|
+
function Gl() {
|
|
2539
|
+
return Fe(Array.from({ length: rl }, () => sl));
|
|
2504
2540
|
}
|
|
2505
|
-
function
|
|
2506
|
-
return Fe(Array.from({ length:
|
|
2541
|
+
function Yl() {
|
|
2542
|
+
return Fe(Array.from({ length: il }, () => ll));
|
|
2507
2543
|
}
|
|
2508
|
-
function
|
|
2544
|
+
function Wl() {
|
|
2509
2545
|
return Fe([
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2546
|
+
Et,
|
|
2547
|
+
al,
|
|
2548
|
+
Et
|
|
2513
2549
|
]);
|
|
2514
2550
|
}
|
|
2515
|
-
function
|
|
2551
|
+
function Ql() {
|
|
2516
2552
|
const e = (r, s, l) => ({
|
|
2517
2553
|
id: String(r),
|
|
2518
2554
|
name: s,
|
|
@@ -2531,27 +2567,27 @@ function kl() {
|
|
|
2531
2567
|
},
|
|
2532
2568
|
...l
|
|
2533
2569
|
}), t = { id: "101", name: "Week 1: Foundations" }, n = { id: "102", name: "Week 2: Derivatives" }, o = [
|
|
2534
|
-
e(1, "Locked by a future date", { unlockAt:
|
|
2570
|
+
e(1, "Locked by a future date", { unlockAt: Tt }),
|
|
2535
2571
|
e(2, "Locked by one prerequisite", { prerequisiteModules: [t] }),
|
|
2536
2572
|
e(3, "Locked by several prerequisites", {
|
|
2537
2573
|
prerequisiteModules: [t, n]
|
|
2538
2574
|
}),
|
|
2539
2575
|
e(4, "Locked by a date and a prerequisite", {
|
|
2540
|
-
unlockAt:
|
|
2576
|
+
unlockAt: Tt,
|
|
2541
2577
|
prerequisiteModules: [t]
|
|
2542
2578
|
}),
|
|
2543
|
-
e(5, "Locked, and the unlock date has passed", { unlockAt:
|
|
2579
|
+
e(5, "Locked, and the unlock date has passed", { unlockAt: ol })
|
|
2544
2580
|
];
|
|
2545
2581
|
return {
|
|
2546
|
-
courseId:
|
|
2582
|
+
courseId: re,
|
|
2547
2583
|
modules: o,
|
|
2548
2584
|
itemsByModuleId: Object.fromEntries(o.map((r) => [r.id, []]))
|
|
2549
2585
|
};
|
|
2550
2586
|
}
|
|
2551
|
-
function
|
|
2587
|
+
function Hl() {
|
|
2552
2588
|
return Fe([]);
|
|
2553
2589
|
}
|
|
2554
|
-
function
|
|
2590
|
+
function Vl() {
|
|
2555
2591
|
const t = [
|
|
2556
2592
|
{
|
|
2557
2593
|
title: "Every fact: type, due date, points, requirement",
|
|
@@ -2580,7 +2616,7 @@ function Fl() {
|
|
|
2580
2616
|
title: "Career item carrying an estimated duration",
|
|
2581
2617
|
type: "external_tool",
|
|
2582
2618
|
completionRequirement: { itemId: "5", type: "must_view" },
|
|
2583
|
-
extensions:
|
|
2619
|
+
extensions: Ze(void 0, 45)
|
|
2584
2620
|
},
|
|
2585
2621
|
{ title: "A file, ungradeable, so no points at all", type: "file" },
|
|
2586
2622
|
{ title: "External link, opens in a new tab", type: "external_url", newTab: !0 },
|
|
@@ -2588,7 +2624,14 @@ function Fl() {
|
|
|
2588
2624
|
title: "A sub-header, which renders no tile and no meta line",
|
|
2589
2625
|
type: "sub_header",
|
|
2590
2626
|
url: null
|
|
2591
|
-
}
|
|
2627
|
+
},
|
|
2628
|
+
{ title: "A parent, with children indented under it", type: "page" },
|
|
2629
|
+
{ title: "Indented one level", type: "assignment", indent: 1 },
|
|
2630
|
+
{ title: "Indented one level, the second child", type: "page", indent: 1 },
|
|
2631
|
+
{ title: "Indented two levels", type: "file", indent: 2 },
|
|
2632
|
+
{ title: "Indented three levels", type: "quiz", indent: 3 },
|
|
2633
|
+
{ title: "Indented four levels", type: "discussion", indent: 4 },
|
|
2634
|
+
{ title: "Indented five levels, the deepest Canvas allows", type: "page", indent: 5 }
|
|
2592
2635
|
].map((n, o) => ({
|
|
2593
2636
|
id: String(o + 1),
|
|
2594
2637
|
moduleId: "1",
|
|
@@ -2596,12 +2639,12 @@ function Fl() {
|
|
|
2596
2639
|
indent: 0,
|
|
2597
2640
|
published: !0,
|
|
2598
2641
|
newTab: !1,
|
|
2599
|
-
url:
|
|
2642
|
+
url: fe(o + 1),
|
|
2600
2643
|
status: "not_started",
|
|
2601
2644
|
...n
|
|
2602
2645
|
}));
|
|
2603
2646
|
return {
|
|
2604
|
-
courseId:
|
|
2647
|
+
courseId: re,
|
|
2605
2648
|
modules: [
|
|
2606
2649
|
{
|
|
2607
2650
|
id: "1",
|
|
@@ -2616,13 +2659,13 @@ function Fl() {
|
|
|
2616
2659
|
itemsByModuleId: { 1: t }
|
|
2617
2660
|
};
|
|
2618
2661
|
}
|
|
2619
|
-
function
|
|
2662
|
+
function Kl() {
|
|
2620
2663
|
const t = [
|
|
2621
|
-
{ title: "Reading: limits from the left and the right", type: "page", url:
|
|
2664
|
+
{ title: "Reading: limits from the left and the right", type: "page", url: fe(1) },
|
|
2622
2665
|
{
|
|
2623
2666
|
title: "Desmos: interactive limit explorer",
|
|
2624
2667
|
type: "external_url",
|
|
2625
|
-
url:
|
|
2668
|
+
url: fe(2),
|
|
2626
2669
|
newTab: !0
|
|
2627
2670
|
},
|
|
2628
2671
|
{ title: "Practice", type: "sub_header", url: null },
|
|
@@ -2630,9 +2673,9 @@ function Ul() {
|
|
|
2630
2673
|
{
|
|
2631
2674
|
title: "Utilizing Triangle Characteristics: Measuring Distances Through Angles, Elevation and the Practical Limits of Indirect Measurement in the Field",
|
|
2632
2675
|
type: "assignment",
|
|
2633
|
-
url:
|
|
2676
|
+
url: fe(5)
|
|
2634
2677
|
},
|
|
2635
|
-
{ title: "Unit test", type: "quiz", url:
|
|
2678
|
+
{ title: "Unit test", type: "quiz", url: fe(6), status: "locked" }
|
|
2636
2679
|
].map((n, o) => ({
|
|
2637
2680
|
id: String(o + 1),
|
|
2638
2681
|
moduleId: "1",
|
|
@@ -2644,7 +2687,7 @@ function Ul() {
|
|
|
2644
2687
|
...n
|
|
2645
2688
|
}));
|
|
2646
2689
|
return {
|
|
2647
|
-
courseId:
|
|
2690
|
+
courseId: re,
|
|
2648
2691
|
modules: [
|
|
2649
2692
|
{
|
|
2650
2693
|
id: "1",
|
|
@@ -2660,92 +2703,91 @@ function Ul() {
|
|
|
2660
2703
|
};
|
|
2661
2704
|
}
|
|
2662
2705
|
export {
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2706
|
+
V as ALL_FILTER,
|
|
2707
|
+
Bt as CompletionRequirementSchema,
|
|
2708
|
+
Hn as CompletionRequirementTypeSchema,
|
|
2709
|
+
cn as DEFAULT_INLINE_THRESHOLD,
|
|
2710
|
+
Qs as DEFAULT_ITEM_CONCURRENCY,
|
|
2711
|
+
un as DEFAULT_ITEM_PAGE_SIZE,
|
|
2712
|
+
oe as DEFAULT_LOCALE,
|
|
2713
|
+
tt as DEFAULT_PAGE_SIZE,
|
|
2714
|
+
dn as DEFAULT_RETAIN_COLLAPSED_LIMIT,
|
|
2672
2715
|
Oe as DEFAULT_STALE_TIME_MS,
|
|
2673
|
-
|
|
2674
|
-
|
|
2675
|
-
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
Ts as baseFilters,
|
|
2716
|
+
Ns as DUE_THIS_WEEK_DAYS,
|
|
2717
|
+
Yt as EXT_CAREER_ESTIMATED_DURATION_MINUTES,
|
|
2718
|
+
re as FIXTURE_COURSE_ID,
|
|
2719
|
+
oi as FilterChips,
|
|
2720
|
+
jn as FilterClauseSchema,
|
|
2721
|
+
Gs as FilterEntrySchema,
|
|
2722
|
+
vo as GET_MODULES,
|
|
2723
|
+
Lo as GET_MODULE_ITEMS,
|
|
2724
|
+
Ge as INLINE_ITEM_LIMIT,
|
|
2725
|
+
Xe as INLINE_QUERY_NODE_BUDGET,
|
|
2726
|
+
to as InMemoryCourseMismatchError,
|
|
2727
|
+
Bs as ItemTypeEntrySchema,
|
|
2728
|
+
js as MetaFieldEntrySchema,
|
|
2729
|
+
qi as ModuleCard,
|
|
2730
|
+
yi as ModuleItemRow,
|
|
2731
|
+
jt as ModuleItemSchema,
|
|
2732
|
+
di as ModuleItemStatusPill,
|
|
2733
|
+
Wn as ModuleItemStatusSchema,
|
|
2734
|
+
Yn as ModuleItemTypeSchema,
|
|
2735
|
+
Jn as ModuleItemsPageSchema,
|
|
2736
|
+
Vn as ModuleProgressSchema,
|
|
2737
|
+
Zn as ModuleSchema,
|
|
2738
|
+
ci as ModuleStatusPill,
|
|
2739
|
+
Qn as ModuleStatusSchema,
|
|
2740
|
+
kl as ModulesConfigProvider,
|
|
2741
|
+
Ys as ModulesConfigSchema,
|
|
2742
|
+
ql as ModulesI18nProvider,
|
|
2743
|
+
jl as ModulesList,
|
|
2744
|
+
Xn as ModulesPageSchema,
|
|
2745
|
+
Gt as PageInfoSchema,
|
|
2746
|
+
Wt as PartialCanvasResponseError,
|
|
2747
|
+
Kn as PrerequisiteModuleSchema,
|
|
2748
|
+
ke as RegistryEntrySchema,
|
|
2749
|
+
Ds as TYPE_FIELD,
|
|
2750
|
+
qs as baseFilters,
|
|
2709
2751
|
qe as baseModulesConfig,
|
|
2710
2752
|
Fe as buildFixture,
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2753
|
+
Hl as courseEmpty,
|
|
2754
|
+
Wl as courseFatModule,
|
|
2755
|
+
Kl as courseItemLinks,
|
|
2756
|
+
Vl as courseItemRowVariants,
|
|
2757
|
+
Yl as courseLarge,
|
|
2758
|
+
Ql as courseLockReasons,
|
|
2759
|
+
Gl as courseSmall,
|
|
2760
|
+
Nl as createCanvasGraphqlAdapter,
|
|
2761
|
+
xl as createInMemoryAdapter,
|
|
2762
|
+
nn as createTranslate,
|
|
2763
|
+
ks as defaultFormatters,
|
|
2764
|
+
ys as defaultTranslate,
|
|
2765
|
+
Je as filterClauseOf,
|
|
2766
|
+
eo as getEstimatedDurationMinutes,
|
|
2767
|
+
zs as hideUnservableFilters,
|
|
2768
|
+
Bl as invalidateCourse,
|
|
2769
|
+
zl as invalidateModuleItems,
|
|
2770
|
+
$l as invalidateModuleList,
|
|
2771
|
+
We as isPredicateServed,
|
|
2772
|
+
ee as mergeRegistry,
|
|
2773
|
+
ui as moduleItemStatusLabel,
|
|
2774
|
+
mn as moduleItemsPrefix,
|
|
2775
|
+
ai as moduleStatusLabel,
|
|
2776
|
+
Se as modulesKeys,
|
|
2777
|
+
Hs as modulesListPrefix,
|
|
2778
|
+
Ol as partialModulesConfig,
|
|
2737
2779
|
ve as registrySchema,
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2780
|
+
Ws as resolveModulesConfig,
|
|
2781
|
+
Gn as servesClause,
|
|
2782
|
+
Us as unservableFilters,
|
|
2783
|
+
Dl as useFieldVisible,
|
|
2784
|
+
De as useFormatters,
|
|
2785
|
+
Fl as useModuleItems,
|
|
2786
|
+
Vs as useModules,
|
|
2787
|
+
ye as useModulesConfig,
|
|
2788
|
+
B as useModulesI18n,
|
|
2789
|
+
Ul as useModulesPageData,
|
|
2790
|
+
et as visibleEntries,
|
|
2791
|
+
ne as visibleEntry,
|
|
2792
|
+
Ze as withEstimatedDurationMinutes
|
|
2751
2793
|
};
|