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