@project-sunbird/collection-editor-react 1.0.8 → 1.0.11
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/collection-editor.umd.js +46 -46
- package/dist/index.cjs +9 -9
- package/dist/index.js +325 -319
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -461,7 +461,7 @@ function df(e) {
|
|
|
461
461
|
h = Promise.reject(v);
|
|
462
462
|
}
|
|
463
463
|
Promise.resolve(h).then(f).catch((v) => {
|
|
464
|
-
var
|
|
464
|
+
var E;
|
|
465
465
|
if (o())
|
|
466
466
|
return;
|
|
467
467
|
const b = e.retry ?? (zi.isServer() ? 0 : 3), C = e.retryDelay ?? Hm, _ = typeof C == "function" ? C(r, v) : C, T = b === !0 || typeof b == "number" && r < b || typeof b == "function" && b(r, v);
|
|
@@ -469,7 +469,7 @@ function df(e) {
|
|
|
469
469
|
m(v);
|
|
470
470
|
return;
|
|
471
471
|
}
|
|
472
|
-
r++, (
|
|
472
|
+
r++, (E = e.onFail) == null || E.call(e, r, v), Bm(_).then(() => c() ? void 0 : p()).then(() => {
|
|
473
473
|
t ? m(v) : y();
|
|
474
474
|
});
|
|
475
475
|
});
|
|
@@ -535,9 +535,9 @@ function Qm(e) {
|
|
|
535
535
|
meta: t.options.meta
|
|
536
536
|
};
|
|
537
537
|
return g(N), N;
|
|
538
|
-
})(),
|
|
538
|
+
})(), A = await v(L), { maxPages: R } = t.options, x = T ? $m : qm;
|
|
539
539
|
return {
|
|
540
|
-
pages: x(C.pages,
|
|
540
|
+
pages: x(C.pages, A, R),
|
|
541
541
|
pageParams: x(C.pageParams, _, R)
|
|
542
542
|
};
|
|
543
543
|
};
|
|
@@ -545,8 +545,8 @@ function Qm(e) {
|
|
|
545
545
|
const C = i === "backward", _ = C ? Wm : bc, T = {
|
|
546
546
|
pages: o,
|
|
547
547
|
pageParams: s
|
|
548
|
-
},
|
|
549
|
-
a = await b(T,
|
|
548
|
+
}, E = _(n, T);
|
|
549
|
+
a = await b(T, E, C);
|
|
550
550
|
} else {
|
|
551
551
|
const C = e ?? o.length;
|
|
552
552
|
do {
|
|
@@ -719,7 +719,7 @@ var Xn, pn, Jn, ir, mn, yt, Xi, gn, Wt, ff, Lr, Xu, Gm = (Xu = class extends uf
|
|
|
719
719
|
get: () => (re(this, gn, !0), n.signal)
|
|
720
720
|
});
|
|
721
721
|
}, o = () => {
|
|
722
|
-
const _ = af(this.options, r),
|
|
722
|
+
const _ = af(this.options, r), E = (() => {
|
|
723
723
|
const L = {
|
|
724
724
|
client: k(this, mn),
|
|
725
725
|
queryKey: this.queryKey,
|
|
@@ -729,9 +729,9 @@ var Xn, pn, Jn, ir, mn, yt, Xi, gn, Wt, ff, Lr, Xu, Gm = (Xu = class extends uf
|
|
|
729
729
|
})();
|
|
730
730
|
return re(this, gn, !1), this.options.persister ? this.options.persister(
|
|
731
731
|
_,
|
|
732
|
-
|
|
732
|
+
E,
|
|
733
733
|
this
|
|
734
|
-
) : _(
|
|
734
|
+
) : _(E);
|
|
735
735
|
}, a = (() => {
|
|
736
736
|
const _ = {
|
|
737
737
|
fetchOptions: r,
|
|
@@ -1058,7 +1058,7 @@ var jt, Me, Ji, Mt, vn, ei, Or, Qr, eo, ti, ri, yn, bn, Wr, ni, He, Pi, Ba, qa,
|
|
|
1058
1058
|
re(this, Qr, x);
|
|
1059
1059
|
}
|
|
1060
1060
|
k(this, Qr) && (y = k(this, Qr), p = k(this, ti), h = Date.now(), g = "error");
|
|
1061
|
-
const b = f.fetchStatus === "fetching", C = g === "pending", _ = g === "error", T = C && b,
|
|
1061
|
+
const b = f.fetchStatus === "fetching", C = g === "pending", _ = g === "error", T = C && b, E = p !== void 0, A = {
|
|
1062
1062
|
status: g,
|
|
1063
1063
|
fetchStatus: f.fetchStatus,
|
|
1064
1064
|
isPending: C,
|
|
@@ -1077,20 +1077,20 @@ var jt, Me, Ji, Mt, vn, ei, Or, Qr, eo, ti, ri, yn, bn, Wr, ni, He, Pi, Ba, qa,
|
|
|
1077
1077
|
isFetchedAfterMount: f.dataUpdateCount > c.dataUpdateCount || f.errorUpdateCount > c.errorUpdateCount,
|
|
1078
1078
|
isFetching: b,
|
|
1079
1079
|
isRefetching: b && !C,
|
|
1080
|
-
isLoadingError: _ && !
|
|
1080
|
+
isLoadingError: _ && !E,
|
|
1081
1081
|
isPaused: f.fetchStatus === "paused",
|
|
1082
1082
|
isPlaceholderData: m,
|
|
1083
|
-
isRefetchError: _ &&
|
|
1083
|
+
isRefetchError: _ && E,
|
|
1084
1084
|
isStale: Dl(t, r),
|
|
1085
1085
|
refetch: this.refetch,
|
|
1086
1086
|
promise: k(this, Or),
|
|
1087
1087
|
isEnabled: Gt(r.enabled, t) !== !1
|
|
1088
1088
|
};
|
|
1089
1089
|
if (this.options.experimental_prefetchInRender) {
|
|
1090
|
-
const x =
|
|
1091
|
-
N ? U.reject(
|
|
1090
|
+
const x = A.data !== void 0, N = A.status === "error" && !x, P = (U) => {
|
|
1091
|
+
N ? U.reject(A.error) : x && U.resolve(A.data);
|
|
1092
1092
|
}, F = () => {
|
|
1093
|
-
const U = re(this, Or,
|
|
1093
|
+
const U = re(this, Or, A.promise = Fa());
|
|
1094
1094
|
P(U);
|
|
1095
1095
|
}, B = k(this, Or);
|
|
1096
1096
|
switch (B.status) {
|
|
@@ -1098,14 +1098,14 @@ var jt, Me, Ji, Mt, vn, ei, Or, Qr, eo, ti, ri, yn, bn, Wr, ni, He, Pi, Ba, qa,
|
|
|
1098
1098
|
t.queryHash === n.queryHash && P(B);
|
|
1099
1099
|
break;
|
|
1100
1100
|
case "fulfilled":
|
|
1101
|
-
(N ||
|
|
1101
|
+
(N || A.data !== B.value) && F();
|
|
1102
1102
|
break;
|
|
1103
1103
|
case "rejected":
|
|
1104
|
-
(!N ||
|
|
1104
|
+
(!N || A.error !== B.reason) && F();
|
|
1105
1105
|
break;
|
|
1106
1106
|
}
|
|
1107
1107
|
}
|
|
1108
|
-
return
|
|
1108
|
+
return A;
|
|
1109
1109
|
}
|
|
1110
1110
|
updateResult() {
|
|
1111
1111
|
const t = k(this, Mt), r = this.createResult(k(this, Me), this.options);
|
|
@@ -1239,7 +1239,7 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1239
1239
|
this.execute(this.state.variables);
|
|
1240
1240
|
}
|
|
1241
1241
|
async execute(t) {
|
|
1242
|
-
var s, a, l, c, d, f, m, p, y, h, g, v, b, C, _, T,
|
|
1242
|
+
var s, a, l, c, d, f, m, p, y, h, g, v, b, C, _, T, E, L;
|
|
1243
1243
|
const r = () => {
|
|
1244
1244
|
Fe(this, Sr, qr).call(this, { type: "continue" });
|
|
1245
1245
|
}, n = {
|
|
@@ -1249,8 +1249,8 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1249
1249
|
};
|
|
1250
1250
|
re(this, Cn, df({
|
|
1251
1251
|
fn: () => this.options.mutationFn ? this.options.mutationFn(t, n) : Promise.reject(new Error("No mutationFn found")),
|
|
1252
|
-
onFail: (
|
|
1253
|
-
Fe(this, Sr, qr).call(this, { type: "failed", failureCount:
|
|
1252
|
+
onFail: (A, R) => {
|
|
1253
|
+
Fe(this, Sr, qr).call(this, { type: "failed", failureCount: A, error: R });
|
|
1254
1254
|
},
|
|
1255
1255
|
onPause: () => {
|
|
1256
1256
|
Fe(this, Sr, qr).call(this, { type: "pause" });
|
|
@@ -1283,23 +1283,23 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1283
1283
|
isPaused: o
|
|
1284
1284
|
});
|
|
1285
1285
|
}
|
|
1286
|
-
const
|
|
1286
|
+
const A = await k(this, Cn).start();
|
|
1287
1287
|
return await ((c = (l = k(this, Nt).config).onSuccess) == null ? void 0 : c.call(
|
|
1288
1288
|
l,
|
|
1289
|
-
|
|
1289
|
+
A,
|
|
1290
1290
|
t,
|
|
1291
1291
|
this.state.context,
|
|
1292
1292
|
this,
|
|
1293
1293
|
n
|
|
1294
1294
|
)), await ((f = (d = this.options).onSuccess) == null ? void 0 : f.call(
|
|
1295
1295
|
d,
|
|
1296
|
-
|
|
1296
|
+
A,
|
|
1297
1297
|
t,
|
|
1298
1298
|
this.state.context,
|
|
1299
1299
|
n
|
|
1300
1300
|
)), await ((p = (m = k(this, Nt).config).onSettled) == null ? void 0 : p.call(
|
|
1301
1301
|
m,
|
|
1302
|
-
|
|
1302
|
+
A,
|
|
1303
1303
|
null,
|
|
1304
1304
|
this.state.variables,
|
|
1305
1305
|
this.state.context,
|
|
@@ -1307,17 +1307,17 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1307
1307
|
n
|
|
1308
1308
|
)), await ((h = (y = this.options).onSettled) == null ? void 0 : h.call(
|
|
1309
1309
|
y,
|
|
1310
|
-
|
|
1310
|
+
A,
|
|
1311
1311
|
null,
|
|
1312
1312
|
t,
|
|
1313
1313
|
this.state.context,
|
|
1314
1314
|
n
|
|
1315
|
-
)), Fe(this, Sr, qr).call(this, { type: "success", data:
|
|
1316
|
-
} catch (
|
|
1315
|
+
)), Fe(this, Sr, qr).call(this, { type: "success", data: A }), A;
|
|
1316
|
+
} catch (A) {
|
|
1317
1317
|
try {
|
|
1318
1318
|
await ((v = (g = k(this, Nt).config).onError) == null ? void 0 : v.call(
|
|
1319
1319
|
g,
|
|
1320
|
-
|
|
1320
|
+
A,
|
|
1321
1321
|
t,
|
|
1322
1322
|
this.state.context,
|
|
1323
1323
|
this,
|
|
@@ -1329,7 +1329,7 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1329
1329
|
try {
|
|
1330
1330
|
await ((C = (b = this.options).onError) == null ? void 0 : C.call(
|
|
1331
1331
|
b,
|
|
1332
|
-
|
|
1332
|
+
A,
|
|
1333
1333
|
t,
|
|
1334
1334
|
this.state.context,
|
|
1335
1335
|
n
|
|
@@ -1341,7 +1341,7 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1341
1341
|
await ((T = (_ = k(this, Nt).config).onSettled) == null ? void 0 : T.call(
|
|
1342
1342
|
_,
|
|
1343
1343
|
void 0,
|
|
1344
|
-
|
|
1344
|
+
A,
|
|
1345
1345
|
this.state.variables,
|
|
1346
1346
|
this.state.context,
|
|
1347
1347
|
this,
|
|
@@ -1351,10 +1351,10 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1351
1351
|
Promise.reject(R);
|
|
1352
1352
|
}
|
|
1353
1353
|
try {
|
|
1354
|
-
await ((L = (
|
|
1355
|
-
A,
|
|
1356
|
-
void 0,
|
|
1354
|
+
await ((L = (E = this.options).onSettled) == null ? void 0 : L.call(
|
|
1357
1355
|
E,
|
|
1356
|
+
void 0,
|
|
1357
|
+
A,
|
|
1358
1358
|
t,
|
|
1359
1359
|
this.state.context,
|
|
1360
1360
|
n
|
|
@@ -1362,7 +1362,7 @@ var to, wr, Nt, Cn, Sr, qr, ef, Xm = (ef = class extends uf {
|
|
|
1362
1362
|
} catch (R) {
|
|
1363
1363
|
Promise.reject(R);
|
|
1364
1364
|
}
|
|
1365
|
-
throw Fe(this, Sr, qr).call(this, { type: "error", error:
|
|
1365
|
+
throw Fe(this, Sr, qr).call(this, { type: "error", error: A }), A;
|
|
1366
1366
|
} finally {
|
|
1367
1367
|
k(this, Nt).runNext(this);
|
|
1368
1368
|
}
|
|
@@ -3329,13 +3329,13 @@ class Rl {
|
|
|
3329
3329
|
isLeft: C,
|
|
3330
3330
|
isBottom: _,
|
|
3331
3331
|
maxScroll: T,
|
|
3332
|
-
minScroll:
|
|
3333
|
-
} = Mf(h), L = Rv(h),
|
|
3332
|
+
minScroll: E
|
|
3333
|
+
} = Mf(h), L = Rv(h), A = {
|
|
3334
3334
|
x: Math.min(g === Be.Right ? L.right - L.width / 2 : L.right, Math.max(g === Be.Right ? L.left : L.left + L.width / 2, f.x)),
|
|
3335
3335
|
y: Math.min(g === Be.Down ? L.bottom - L.height / 2 : L.bottom, Math.max(g === Be.Down ? L.top : L.top + L.height / 2, f.y))
|
|
3336
3336
|
}, R = g === Be.Right && !b || g === Be.Left && !C, x = g === Be.Down && !_ || g === Be.Up && !v;
|
|
3337
|
-
if (R &&
|
|
3338
|
-
const N = h.scrollLeft + m.x, P = g === Be.Right && N <= T.x || g === Be.Left && N >=
|
|
3337
|
+
if (R && A.x !== f.x) {
|
|
3338
|
+
const N = h.scrollLeft + m.x, P = g === Be.Right && N <= T.x || g === Be.Left && N >= E.x;
|
|
3339
3339
|
if (P && !m.y) {
|
|
3340
3340
|
h.scrollTo({
|
|
3341
3341
|
left: N,
|
|
@@ -3343,13 +3343,13 @@ class Rl {
|
|
|
3343
3343
|
});
|
|
3344
3344
|
return;
|
|
3345
3345
|
}
|
|
3346
|
-
P ? p.x = h.scrollLeft - N : p.x = g === Be.Right ? h.scrollLeft - T.x : h.scrollLeft -
|
|
3346
|
+
P ? p.x = h.scrollLeft - N : p.x = g === Be.Right ? h.scrollLeft - T.x : h.scrollLeft - E.x, p.x && h.scrollBy({
|
|
3347
3347
|
left: -p.x,
|
|
3348
3348
|
behavior: a
|
|
3349
3349
|
});
|
|
3350
3350
|
break;
|
|
3351
|
-
} else if (x &&
|
|
3352
|
-
const N = h.scrollTop + m.y, P = g === Be.Down && N <= T.y || g === Be.Up && N >=
|
|
3351
|
+
} else if (x && A.y !== f.y) {
|
|
3352
|
+
const N = h.scrollTop + m.y, P = g === Be.Down && N <= T.y || g === Be.Up && N >= E.y;
|
|
3353
3353
|
if (P && !m.x) {
|
|
3354
3354
|
h.scrollTo({
|
|
3355
3355
|
top: N,
|
|
@@ -3357,7 +3357,7 @@ class Rl {
|
|
|
3357
3357
|
});
|
|
3358
3358
|
return;
|
|
3359
3359
|
}
|
|
3360
|
-
P ? p.y = h.scrollTop - N : p.y = g === Be.Down ? h.scrollTop - T.y : h.scrollTop -
|
|
3360
|
+
P ? p.y = h.scrollTop - N : p.y = g === Be.Down ? h.scrollTop - T.y : h.scrollTop - E.y, p.y && h.scrollBy({
|
|
3361
3361
|
top: -p.y,
|
|
3362
3362
|
behavior: a
|
|
3363
3363
|
});
|
|
@@ -3678,11 +3678,11 @@ function Hv(e) {
|
|
|
3678
3678
|
return i;
|
|
3679
3679
|
}
|
|
3680
3680
|
}, [r, i, l]), C = ie(null), _ = Z(() => {
|
|
3681
|
-
const
|
|
3682
|
-
if (!
|
|
3681
|
+
const E = C.current;
|
|
3682
|
+
if (!E)
|
|
3683
3683
|
return;
|
|
3684
|
-
const L = g.current.x * v.current.x,
|
|
3685
|
-
|
|
3684
|
+
const L = g.current.x * v.current.x, A = g.current.y * v.current.y;
|
|
3685
|
+
E.scrollBy(L, A);
|
|
3686
3686
|
}, []), T = Te(() => a === as.TreeOrder ? [...c].reverse() : c, [a, c]);
|
|
3687
3687
|
ee(
|
|
3688
3688
|
() => {
|
|
@@ -3690,20 +3690,20 @@ function Hv(e) {
|
|
|
3690
3690
|
h();
|
|
3691
3691
|
return;
|
|
3692
3692
|
}
|
|
3693
|
-
for (const
|
|
3694
|
-
if ((n == null ? void 0 : n(
|
|
3693
|
+
for (const E of T) {
|
|
3694
|
+
if ((n == null ? void 0 : n(E)) === !1)
|
|
3695
3695
|
continue;
|
|
3696
|
-
const L = c.indexOf(
|
|
3697
|
-
if (!
|
|
3696
|
+
const L = c.indexOf(E), A = d[L];
|
|
3697
|
+
if (!A)
|
|
3698
3698
|
continue;
|
|
3699
3699
|
const {
|
|
3700
3700
|
direction: R,
|
|
3701
3701
|
speed: x
|
|
3702
|
-
} = Pv(
|
|
3702
|
+
} = Pv(E, A, b, t, m);
|
|
3703
3703
|
for (const N of ["x", "y"])
|
|
3704
3704
|
p[N][R[N]] || (x[N] = 0, R[N] = 0);
|
|
3705
3705
|
if (x.x > 0 || x.y > 0) {
|
|
3706
|
-
h(), C.current =
|
|
3706
|
+
h(), C.current = E, y(_, s), g.current = x, v.current = R;
|
|
3707
3707
|
return;
|
|
3708
3708
|
}
|
|
3709
3709
|
}
|
|
@@ -4408,16 +4408,16 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4408
4408
|
modifiers: p,
|
|
4409
4409
|
...y
|
|
4410
4410
|
} = t;
|
|
4411
|
-
const h = Am(uy, void 0, dy), [g, v] = h, [b, C] = pv(), [_, T] = j(jr.Uninitialized),
|
|
4411
|
+
const h = Am(uy, void 0, dy), [g, v] = h, [b, C] = pv(), [_, T] = j(jr.Uninitialized), E = _ === jr.Initialized, {
|
|
4412
4412
|
draggable: {
|
|
4413
4413
|
active: L,
|
|
4414
|
-
nodes:
|
|
4414
|
+
nodes: A,
|
|
4415
4415
|
translate: R
|
|
4416
4416
|
},
|
|
4417
4417
|
droppable: {
|
|
4418
4418
|
containers: x
|
|
4419
4419
|
}
|
|
4420
|
-
} = g, N = L != null ?
|
|
4420
|
+
} = g, N = L != null ? A.get(L) : null, P = ie({
|
|
4421
4421
|
initial: null,
|
|
4422
4422
|
translated: null
|
|
4423
4423
|
}), F = Te(() => {
|
|
@@ -4433,12 +4433,12 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4433
4433
|
measureDroppableContainers: Se,
|
|
4434
4434
|
measuringScheduled: M
|
|
4435
4435
|
} = Yv(be, {
|
|
4436
|
-
dragging:
|
|
4436
|
+
dragging: E,
|
|
4437
4437
|
dependencies: [R.x, R.y],
|
|
4438
4438
|
config: fe.droppable
|
|
4439
|
-
}), q = Gv(
|
|
4439
|
+
}), q = Gv(A, L), te = Te(() => Q ? os(Q) : null, [Q]), ye = on(), Ae = Zv(q, fe.draggable.measure);
|
|
4440
4440
|
py({
|
|
4441
|
-
activeNode: L != null ?
|
|
4441
|
+
activeNode: L != null ? A.get(L) : null,
|
|
4442
4442
|
config: ye.layoutShiftCompensation,
|
|
4443
4443
|
initialRect: Ae,
|
|
4444
4444
|
measure: fe.draggable.measure
|
|
@@ -4450,7 +4450,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4450
4450
|
collisionRect: null,
|
|
4451
4451
|
collisions: null,
|
|
4452
4452
|
droppableRects: De,
|
|
4453
|
-
draggableNodes:
|
|
4453
|
+
draggableNodes: A,
|
|
4454
4454
|
draggingNode: null,
|
|
4455
4455
|
draggingNodeRect: null,
|
|
4456
4456
|
droppableContainers: x,
|
|
@@ -4459,7 +4459,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4459
4459
|
scrollAdjustedTranslate: null
|
|
4460
4460
|
}), Oe = x.getNodeFor((r = we.current.over) == null ? void 0 : r.id), J = sy({
|
|
4461
4461
|
measure: fe.dragOverlay.measure
|
|
4462
|
-
}), pe = (n = J.nodeRef.current) != null ? n : q, W =
|
|
4462
|
+
}), pe = (n = J.nodeRef.current) != null ? n : q, W = E ? (i = J.rect) != null ? i : Ce : null, Ee = !!(J.nodeRef.current && J.rect), Qe = ey(Ee ? null : Ce), at = jf(pe ? Bt(pe) : null), We = ty(E ? Oe ?? q : null), et = oy(We), lt = Hf(p, {
|
|
4463
4463
|
transform: {
|
|
4464
4464
|
x: R.x - Qe.x,
|
|
4465
4465
|
y: R.y - Qe.y,
|
|
@@ -4490,7 +4490,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4490
4490
|
} = It;
|
|
4491
4491
|
if (B.current == null)
|
|
4492
4492
|
return;
|
|
4493
|
-
const Jt =
|
|
4493
|
+
const Jt = A.get(B.current);
|
|
4494
4494
|
if (!Jt)
|
|
4495
4495
|
return;
|
|
4496
4496
|
const Ht = gt.nativeEvent, vr = new Ft({
|
|
@@ -4502,7 +4502,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4502
4502
|
// otherwise they are frozen in time with the stale arguments
|
|
4503
4503
|
context: we,
|
|
4504
4504
|
onAbort(wt) {
|
|
4505
|
-
if (!
|
|
4505
|
+
if (!A.get(wt))
|
|
4506
4506
|
return;
|
|
4507
4507
|
const {
|
|
4508
4508
|
onDragAbort: yr
|
|
@@ -4515,7 +4515,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4515
4515
|
});
|
|
4516
4516
|
},
|
|
4517
4517
|
onPending(wt, Rr, yr, Dr) {
|
|
4518
|
-
if (!
|
|
4518
|
+
if (!A.get(wt))
|
|
4519
4519
|
return;
|
|
4520
4520
|
const {
|
|
4521
4521
|
onDragPending: wi
|
|
@@ -4534,7 +4534,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4534
4534
|
const Rr = B.current;
|
|
4535
4535
|
if (Rr == null)
|
|
4536
4536
|
return;
|
|
4537
|
-
const yr =
|
|
4537
|
+
const yr = A.get(Rr);
|
|
4538
4538
|
if (!yr)
|
|
4539
4539
|
return;
|
|
4540
4540
|
const {
|
|
@@ -4606,9 +4606,9 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4606
4606
|
}
|
|
4607
4607
|
},
|
|
4608
4608
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
4609
|
-
[
|
|
4609
|
+
[A]
|
|
4610
4610
|
), tt = Z((gt, It) => (Ft, lr) => {
|
|
4611
|
-
const Jt = Ft.nativeEvent, Ht =
|
|
4611
|
+
const Jt = Ft.nativeEvent, Ht = A.get(lr);
|
|
4612
4612
|
if (
|
|
4613
4613
|
// Another sensor is already instantiating
|
|
4614
4614
|
B.current !== null || // No active draggable
|
|
@@ -4622,7 +4622,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4622
4622
|
gt(Ft, It.options, vr) === !0 && (Jt.dndKit = {
|
|
4623
4623
|
capturedBy: It.sensor
|
|
4624
4624
|
}, B.current = lr, $e(Ft, It));
|
|
4625
|
-
}, [
|
|
4625
|
+
}, [A, $e]), ut = Kv(d, tt);
|
|
4626
4626
|
ny(d), hr(() => {
|
|
4627
4627
|
Ce && _ === jr.Initializing && T(jr.Initialized);
|
|
4628
4628
|
}, [Ce, _]), ee(
|
|
@@ -4701,7 +4701,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4701
4701
|
collisionRect: I,
|
|
4702
4702
|
collisions: D,
|
|
4703
4703
|
droppableRects: De,
|
|
4704
|
-
draggableNodes:
|
|
4704
|
+
draggableNodes: A,
|
|
4705
4705
|
draggingNode: pe,
|
|
4706
4706
|
draggingNodeRect: W,
|
|
4707
4707
|
droppableContainers: x,
|
|
@@ -4712,7 +4712,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4712
4712
|
initial: W,
|
|
4713
4713
|
translated: I
|
|
4714
4714
|
};
|
|
4715
|
-
}, [F, q, D, I,
|
|
4715
|
+
}, [F, q, D, I, A, pe, W, De, x, V, We, w]), Hv({
|
|
4716
4716
|
...ye,
|
|
4717
4717
|
delta: R,
|
|
4718
4718
|
draggingRect: I,
|
|
@@ -4728,7 +4728,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4728
4728
|
collisions: D,
|
|
4729
4729
|
containerNodeRect: he,
|
|
4730
4730
|
dragOverlay: J,
|
|
4731
|
-
draggableNodes:
|
|
4731
|
+
draggableNodes: A,
|
|
4732
4732
|
droppableContainers: x,
|
|
4733
4733
|
droppableRects: De,
|
|
4734
4734
|
over: V,
|
|
@@ -4738,7 +4738,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4738
4738
|
measuringConfiguration: fe,
|
|
4739
4739
|
measuringScheduled: M,
|
|
4740
4740
|
windowRect: at
|
|
4741
|
-
}), [F, q, Ce, Q, D, he, J,
|
|
4741
|
+
}), [F, q, Ce, Q, D, he, J, A, x, De, V, Se, We, et, fe, M, at]), Ci = Te(() => ({
|
|
4742
4742
|
activatorEvent: Q,
|
|
4743
4743
|
activators: ut,
|
|
4744
4744
|
active: F,
|
|
@@ -4747,10 +4747,10 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4747
4747
|
draggable: ve
|
|
4748
4748
|
},
|
|
4749
4749
|
dispatch: v,
|
|
4750
|
-
draggableNodes:
|
|
4750
|
+
draggableNodes: A,
|
|
4751
4751
|
over: V,
|
|
4752
4752
|
measureDroppableContainers: Se
|
|
4753
|
-
}), [Q, ut, F, Ce, v, ve,
|
|
4753
|
+
}), [Q, ut, F, Ce, v, ve, A, V, Se]);
|
|
4754
4754
|
return K.createElement(Ef.Provider, {
|
|
4755
4755
|
value: C
|
|
4756
4756
|
}, K.createElement(lo.Provider, {
|
|
@@ -4766,7 +4766,7 @@ const Qf = /* @__PURE__ */ bs(function(t) {
|
|
|
4766
4766
|
hiddenTextDescribedById: ve
|
|
4767
4767
|
}));
|
|
4768
4768
|
function on() {
|
|
4769
|
-
const gt = (U == null ? void 0 : U.autoScrollEnabled) === !1, It = typeof l == "object" ? l.enabled === !1 : l === !1, Ft =
|
|
4769
|
+
const gt = (U == null ? void 0 : U.autoScrollEnabled) === !1, It = typeof l == "object" ? l.enabled === !1 : l === !1, Ft = E && !gt && !It;
|
|
4770
4770
|
return typeof l == "object" ? {
|
|
4771
4771
|
...l,
|
|
4772
4772
|
enabled: Ft
|
|
@@ -4794,7 +4794,7 @@ function Wf(e) {
|
|
|
4794
4794
|
role: p = Bc,
|
|
4795
4795
|
roleDescription: y = "draggable",
|
|
4796
4796
|
tabIndex: h = 0
|
|
4797
|
-
} = i ?? {}, g = (l == null ? void 0 : l.id) === t, v = Zt(g ? Ds : my), [b, C] = ns(), [_, T] = ns(),
|
|
4797
|
+
} = i ?? {}, g = (l == null ? void 0 : l.id) === t, v = Zt(g ? Ds : my), [b, C] = ns(), [_, T] = ns(), E = iy(s, t), L = Vi(r);
|
|
4798
4798
|
hr(
|
|
4799
4799
|
() => (f.set(t, {
|
|
4800
4800
|
id: t,
|
|
@@ -4809,7 +4809,7 @@ function Wf(e) {
|
|
|
4809
4809
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
4810
4810
|
[f, t]
|
|
4811
4811
|
);
|
|
4812
|
-
const
|
|
4812
|
+
const A = Te(() => ({
|
|
4813
4813
|
role: p,
|
|
4814
4814
|
tabIndex: h,
|
|
4815
4815
|
"aria-disabled": n,
|
|
@@ -4821,9 +4821,9 @@ function Wf(e) {
|
|
|
4821
4821
|
active: l,
|
|
4822
4822
|
activatorEvent: a,
|
|
4823
4823
|
activeNodeRect: c,
|
|
4824
|
-
attributes:
|
|
4824
|
+
attributes: A,
|
|
4825
4825
|
isDragging: g,
|
|
4826
|
-
listeners: n ? void 0 :
|
|
4826
|
+
listeners: n ? void 0 : E,
|
|
4827
4827
|
node: b,
|
|
4828
4828
|
over: m,
|
|
4829
4829
|
setNodeRef: C,
|
|
@@ -4873,9 +4873,9 @@ function by(e) {
|
|
|
4873
4873
|
), C = ks({
|
|
4874
4874
|
callback: b,
|
|
4875
4875
|
disabled: y || !s
|
|
4876
|
-
}), _ = Z((
|
|
4877
|
-
C && (R && (C.unobserve(R), f.current = !1),
|
|
4878
|
-
}, [C]), [T,
|
|
4876
|
+
}), _ = Z((A, R) => {
|
|
4877
|
+
C && (R && (C.unobserve(R), f.current = !1), A && C.observe(A));
|
|
4878
|
+
}, [C]), [T, E] = ns(_), L = Vi(t);
|
|
4879
4879
|
return ee(() => {
|
|
4880
4880
|
!C || !T.current || (C.disconnect(), f.current = !1, C.observe(T.current));
|
|
4881
4881
|
}, [T, C]), ee(
|
|
@@ -4909,7 +4909,7 @@ function by(e) {
|
|
|
4909
4909
|
isOver: (l == null ? void 0 : l.id) === n,
|
|
4910
4910
|
node: T,
|
|
4911
4911
|
over: l,
|
|
4912
|
-
setNodeRef:
|
|
4912
|
+
setNodeRef: E
|
|
4913
4913
|
};
|
|
4914
4914
|
}
|
|
4915
4915
|
function Cy(e) {
|
|
@@ -5161,7 +5161,7 @@ const Ny = /* @__PURE__ */ K.memo((e) => {
|
|
|
5161
5161
|
scrollableAncestors: C,
|
|
5162
5162
|
scrollableAncestorRects: _,
|
|
5163
5163
|
windowRect: T
|
|
5164
|
-
} = Gf(),
|
|
5164
|
+
} = Gf(), E = Zt(Ds), L = Oy(f == null ? void 0 : f.id), A = Hf(s, {
|
|
5165
5165
|
activatorEvent: d,
|
|
5166
5166
|
active: f,
|
|
5167
5167
|
activeNodeRect: m,
|
|
@@ -5171,7 +5171,7 @@ const Ny = /* @__PURE__ */ K.memo((e) => {
|
|
|
5171
5171
|
overlayNodeRect: g.rect,
|
|
5172
5172
|
scrollableAncestors: C,
|
|
5173
5173
|
scrollableAncestorRects: _,
|
|
5174
|
-
transform:
|
|
5174
|
+
transform: E,
|
|
5175
5175
|
windowRect: T
|
|
5176
5176
|
}), R = Fl(m), x = Dy({
|
|
5177
5177
|
config: n,
|
|
@@ -5195,7 +5195,7 @@ const Ny = /* @__PURE__ */ K.memo((e) => {
|
|
|
5195
5195
|
zIndex: c,
|
|
5196
5196
|
...i
|
|
5197
5197
|
},
|
|
5198
|
-
transform:
|
|
5198
|
+
transform: A
|
|
5199
5199
|
}, r) : null));
|
|
5200
5200
|
});
|
|
5201
5201
|
/**
|
|
@@ -6172,18 +6172,18 @@ function gb() {
|
|
|
6172
6172
|
} else h = y.current;
|
|
6173
6173
|
y = a(
|
|
6174
6174
|
function() {
|
|
6175
|
-
function v(
|
|
6175
|
+
function v(E) {
|
|
6176
6176
|
if (!b) {
|
|
6177
|
-
if (b = !0, C =
|
|
6177
|
+
if (b = !0, C = E, E = m(E), p !== void 0 && h.hasValue) {
|
|
6178
6178
|
var L = h.value;
|
|
6179
|
-
if (p(L,
|
|
6179
|
+
if (p(L, E))
|
|
6180
6180
|
return _ = L;
|
|
6181
6181
|
}
|
|
6182
|
-
return _ =
|
|
6182
|
+
return _ = E;
|
|
6183
6183
|
}
|
|
6184
|
-
if (L = _, n(C,
|
|
6185
|
-
var
|
|
6186
|
-
return p !== void 0 && p(L,
|
|
6184
|
+
if (L = _, n(C, E)) return L;
|
|
6185
|
+
var A = m(E);
|
|
6186
|
+
return p !== void 0 && p(L, A) ? (C = E, L) : (C = E, _ = A);
|
|
6187
6187
|
}
|
|
6188
6188
|
var b = !1, C, _, T = f === void 0 ? null : f;
|
|
6189
6189
|
return [
|
|
@@ -6232,19 +6232,19 @@ function vb() {
|
|
|
6232
6232
|
} else h = y.current;
|
|
6233
6233
|
y = a(
|
|
6234
6234
|
function() {
|
|
6235
|
-
function v(
|
|
6235
|
+
function v(E) {
|
|
6236
6236
|
if (!b) {
|
|
6237
|
-
if (b = !0, C =
|
|
6237
|
+
if (b = !0, C = E, E = m(E), p !== void 0 && h.hasValue) {
|
|
6238
6238
|
var L = h.value;
|
|
6239
|
-
if (p(L,
|
|
6239
|
+
if (p(L, E))
|
|
6240
6240
|
return _ = L;
|
|
6241
6241
|
}
|
|
6242
|
-
return _ =
|
|
6242
|
+
return _ = E;
|
|
6243
6243
|
}
|
|
6244
|
-
if (L = _, n(C,
|
|
6244
|
+
if (L = _, n(C, E))
|
|
6245
6245
|
return L;
|
|
6246
|
-
var
|
|
6247
|
-
return p !== void 0 && p(L,
|
|
6246
|
+
var A = m(E);
|
|
6247
|
+
return p !== void 0 && p(L, A) ? (C = E, L) : (C = E, _ = A);
|
|
6248
6248
|
}
|
|
6249
6249
|
var b = !1, C, _, T = f === void 0 ? null : f;
|
|
6250
6250
|
return [
|
|
@@ -7330,12 +7330,12 @@ function Ms(e, t, r) {
|
|
|
7330
7330
|
if (l === 1 / 0)
|
|
7331
7331
|
return JSON.stringify(v);
|
|
7332
7332
|
const C = [];
|
|
7333
|
-
return JSON.stringify(v, function(T,
|
|
7334
|
-
if (!O.isObject(
|
|
7335
|
-
return
|
|
7333
|
+
return JSON.stringify(v, function(T, E) {
|
|
7334
|
+
if (!O.isObject(E))
|
|
7335
|
+
return E;
|
|
7336
7336
|
for (; C.length && C[C.length - 1] !== this; )
|
|
7337
7337
|
C.pop();
|
|
7338
|
-
return C.push(
|
|
7338
|
+
return C.push(E), m(b + C.length - 1), E;
|
|
7339
7339
|
});
|
|
7340
7340
|
}
|
|
7341
7341
|
function y(v, b, C) {
|
|
@@ -7346,11 +7346,11 @@ function Ms(e, t, r) {
|
|
|
7346
7346
|
if (O.endsWith(b, "{}"))
|
|
7347
7347
|
b = n ? b : b.slice(0, -2), v = p(v, 1);
|
|
7348
7348
|
else if (O.isArray(v) && S0(v) || (O.isFileList(v) || O.endsWith(b, "[]")) && (_ = O.toArray(v)))
|
|
7349
|
-
return b = vh(b), _.forEach(function(
|
|
7350
|
-
!(O.isUndefined(
|
|
7349
|
+
return b = vh(b), _.forEach(function(E, L) {
|
|
7350
|
+
!(O.isUndefined(E) || E === null) && t.append(
|
|
7351
7351
|
// eslint-disable-next-line no-nested-ternary
|
|
7352
7352
|
s === !0 ? oa([b], L, o) : s === null ? b : b + "[]",
|
|
7353
|
-
f(
|
|
7353
|
+
f(E)
|
|
7354
7354
|
);
|
|
7355
7355
|
}), !1;
|
|
7356
7356
|
}
|
|
@@ -7365,8 +7365,8 @@ function Ms(e, t, r) {
|
|
|
7365
7365
|
if (!O.isUndefined(v)) {
|
|
7366
7366
|
if (m(C), d.indexOf(v) !== -1)
|
|
7367
7367
|
throw new Error("Circular reference detected in " + b.join("."));
|
|
7368
|
-
d.push(v), O.forEach(v, function(T,
|
|
7369
|
-
(!(O.isUndefined(T) || T === null) && i.call(t, T, O.isString(
|
|
7368
|
+
d.push(v), O.forEach(v, function(T, E) {
|
|
7369
|
+
(!(O.isUndefined(T) || T === null) && i.call(t, T, O.isString(E) ? E.trim() : E, b, h)) === !0 && g(T, b ? b.concat(E) : [E], C + 1);
|
|
7370
7370
|
}), d.pop();
|
|
7371
7371
|
}
|
|
7372
7372
|
}
|
|
@@ -7960,8 +7960,8 @@ const X0 = typeof XMLHttpRequest < "u", J0 = X0 && function(e) {
|
|
|
7960
7960
|
}, g.onabort = function() {
|
|
7961
7961
|
g && (n(new ne("Request aborted", ne.ECONNABORTED, e, g)), h(), g = null);
|
|
7962
7962
|
}, g.onerror = function(_) {
|
|
7963
|
-
const T = _ && _.message ? _.message : "Network Error",
|
|
7964
|
-
|
|
7963
|
+
const T = _ && _.message ? _.message : "Network Error", E = new ne(T, ne.ERR_NETWORK, e, g);
|
|
7964
|
+
E.event = _ || null, n(E), h(), g = null;
|
|
7965
7965
|
}, g.ontimeout = function() {
|
|
7966
7966
|
let _ = i.timeout ? "timeout of " + i.timeout + "ms exceeded" : "timeout exceeded";
|
|
7967
7967
|
const T = i.transitional || Ql;
|
|
@@ -8200,9 +8200,9 @@ const Gl = "1.18.0", dd = 64 * 1024, { isFunction: ko } = O, sT = (e) => encodeU
|
|
|
8200
8200
|
method: C,
|
|
8201
8201
|
data: _,
|
|
8202
8202
|
signal: T,
|
|
8203
|
-
cancelToken:
|
|
8203
|
+
cancelToken: E,
|
|
8204
8204
|
timeout: L,
|
|
8205
|
-
onDownloadProgress:
|
|
8205
|
+
onDownloadProgress: A,
|
|
8206
8206
|
onUploadProgress: R,
|
|
8207
8207
|
responseType: x,
|
|
8208
8208
|
headers: N,
|
|
@@ -8215,7 +8215,7 @@ const Gl = "1.18.0", dd = 64 * 1024, { isFunction: ko } = O, sT = (e) => encodeU
|
|
|
8215
8215
|
let ge = i || fetch;
|
|
8216
8216
|
x = x ? (x + "").toLowerCase() : "text";
|
|
8217
8217
|
let ve = eT(
|
|
8218
|
-
[T,
|
|
8218
|
+
[T, E && E.toAbortSignal()],
|
|
8219
8219
|
L
|
|
8220
8220
|
), be = null;
|
|
8221
8221
|
const fe = ve && ve.unsubscribe && (() => {
|
|
@@ -8328,14 +8328,14 @@ const Gl = "1.18.0", dd = 64 * 1024, { isFunction: ko } = O, sT = (e) => encodeU
|
|
|
8328
8328
|
);
|
|
8329
8329
|
}
|
|
8330
8330
|
const J = p && (x === "stream" || x === "response");
|
|
8331
|
-
if (p && we.body && (
|
|
8331
|
+
if (p && we.body && (A || oe || J && fe)) {
|
|
8332
8332
|
const W = {};
|
|
8333
8333
|
["status", "statusText", "headers"].forEach((lt) => {
|
|
8334
8334
|
W[lt] = we[lt];
|
|
8335
8335
|
});
|
|
8336
|
-
const Ee = O.toFiniteNumber(Oe.getContentLength()), [Qe, at] =
|
|
8336
|
+
const Ee = O.toFiniteNumber(Oe.getContentLength()), [Qe, at] = A && od(
|
|
8337
8337
|
Ee,
|
|
8338
|
-
ds(sd(
|
|
8338
|
+
ds(sd(A), !0)
|
|
8339
8339
|
) || [];
|
|
8340
8340
|
let We = 0;
|
|
8341
8341
|
const et = (lt) => {
|
|
@@ -9183,10 +9183,13 @@ function Yl(e, t, r, n = {}) {
|
|
|
9183
9183
|
o || i.push({ code: "policyMissing", message: "Set a consumption policy for this path." });
|
|
9184
9184
|
const s = e.children ?? [], a = s[0], l = s.length > 1 ? s[s.length - 1] : void 0, c = mt(a), d = mt(l);
|
|
9185
9185
|
!c && o && jh.has(o) && i.push({ code: "priorAssessmentRequired", message: "A Prior Assessment is required for the Adaptive policy." }), [[a, "Prior Assessment"], [l, "Outcome Assessment"]].forEach(([b, C]) => {
|
|
9186
|
-
var
|
|
9186
|
+
var E, L;
|
|
9187
9187
|
if (!b) return;
|
|
9188
9188
|
const _ = b.children ?? [];
|
|
9189
|
-
|
|
9189
|
+
_.some((A) => {
|
|
9190
|
+
var R;
|
|
9191
|
+
return !!((R = A.metadata) != null && R.isAssessmentCourse);
|
|
9192
|
+
}) && (_.length !== 1 || !((L = (E = _[0]) == null ? void 0 : E.metadata) != null && L.isAssessmentCourse)) && i.push({ code: "slotNotPure", nodeId: b.id, message: `${C} must contain exactly one question-set-only course.` });
|
|
9190
9193
|
});
|
|
9191
9194
|
const f = /* @__PURE__ */ new Set(), m = (b, C) => {
|
|
9192
9195
|
f.has(b) && i.push({ code: "duplicateCourse", nodeId: C, message: "A course appears more than once in this path." }), f.add(b);
|
|
@@ -9200,22 +9203,22 @@ function Yl(e, t, r, n = {}) {
|
|
|
9200
9203
|
_ || i.push({ code: "levelMissingSkills", nodeId: b.id, message: `"${b.name}" needs at least one skill selected.` });
|
|
9201
9204
|
else {
|
|
9202
9205
|
if (r.length > 0) {
|
|
9203
|
-
const L = T.filter((
|
|
9206
|
+
const L = T.filter((A) => !r.includes(A));
|
|
9204
9207
|
L.length > 0 && i.push({
|
|
9205
9208
|
code: "levelSkillsOutOfScope",
|
|
9206
9209
|
nodeId: b.id,
|
|
9207
9210
|
message: `"${b.name}" has skills outside the current scope: ${L.join(", ")}.`
|
|
9208
9211
|
});
|
|
9209
9212
|
}
|
|
9210
|
-
const
|
|
9211
|
-
|
|
9213
|
+
const E = $h(b, T, t);
|
|
9214
|
+
E.length > 0 && i.push({
|
|
9212
9215
|
code: "levelSkillsUncovered",
|
|
9213
9216
|
nodeId: b.id,
|
|
9214
|
-
message: `"${b.name}" has no course covering: ${
|
|
9217
|
+
message: `"${b.name}" has no course covering: ${E.join(", ")}.`
|
|
9215
9218
|
});
|
|
9216
9219
|
}
|
|
9217
|
-
for (const
|
|
9218
|
-
m(
|
|
9220
|
+
for (const E of C)
|
|
9221
|
+
m(E.id, b.id), (t ? An((v = E.metadata) == null ? void 0 : v[t]) : []).length === 0 && i.push({ code: "courseMissingSkillTag", nodeId: E.id, message: `"${E.name}" has no skill tag.` });
|
|
9219
9222
|
}
|
|
9220
9223
|
return i;
|
|
9221
9224
|
}
|
|
@@ -9437,14 +9440,14 @@ const ae = uo((e, t) => ({
|
|
|
9437
9440
|
const o = X.getState().editorConfig, s = X.getState().editorProfile, a = (y = t().treeData[0]) == null ? void 0 : y.id, l = !!(i != null && i.isAssessmentCourse);
|
|
9438
9441
|
if (s.derivedRoles && n === a) {
|
|
9439
9442
|
if (!l || $t(t().treeData, r.identifier)) return !1;
|
|
9440
|
-
const _ = t().treeData[0], T = (_ == null ? void 0 : _.children) ?? [],
|
|
9441
|
-
if (!
|
|
9443
|
+
const _ = t().treeData[0], T = (_ == null ? void 0 : _.children) ?? [], E = (i == null ? void 0 : i.slot) ?? LT(T);
|
|
9444
|
+
if (!E || Gi(T, E)) return !1;
|
|
9442
9445
|
const L = t().addNode(a, "unit");
|
|
9443
9446
|
if (!L) return !1;
|
|
9444
|
-
const { learningPath:
|
|
9447
|
+
const { learningPath: A } = Ul.getState().labelConfig;
|
|
9445
9448
|
if (t().updateNode(L, {
|
|
9446
|
-
name:
|
|
9447
|
-
}),
|
|
9449
|
+
name: E === "pre" ? A.priorAssessmentLabel : A.outcomeAssessmentLabel
|
|
9450
|
+
}), E === "pre") {
|
|
9448
9451
|
const R = (((g = (h = t().treeData[0]) == null ? void 0 : h.children) == null ? void 0 : g.length) ?? 1) - 1;
|
|
9449
9452
|
e((x) => ({
|
|
9450
9453
|
treeData: cl(x.treeData, a, R, 0)
|
|
@@ -10047,7 +10050,7 @@ const c1 = "_container_1hnn8_1", d1 = "_header_1hnn8_13", u1 = "_title_1hnn8_22"
|
|
|
10047
10050
|
p((P) => P.find((F) => F.identifier === N.identifier) ? P : [...P, N]), c((P) => P.filter((F) => F.identifier !== N.identifier)), C(!1);
|
|
10048
10051
|
},
|
|
10049
10052
|
[]
|
|
10050
|
-
),
|
|
10053
|
+
), E = Z((N) => {
|
|
10051
10054
|
p((P) => P.filter((F) => F.identifier !== N)), C(!1);
|
|
10052
10055
|
}, []), L = Z(async () => {
|
|
10053
10056
|
h(!0), v(""), C(!1);
|
|
@@ -10061,7 +10064,7 @@ const c1 = "_container_1hnn8_1", d1 = "_header_1hnn8_13", u1 = "_title_1hnn8_22"
|
|
|
10061
10064
|
} finally {
|
|
10062
10065
|
h(!1);
|
|
10063
10066
|
}
|
|
10064
|
-
}, [e, m, r.manageCollaborators.saveFailed]),
|
|
10067
|
+
}, [e, m, r.manageCollaborators.saveFailed]), A = (N) => `${N.firstName}${N.lastName ? ` ${N.lastName}` : ""}`;
|
|
10065
10068
|
return /* @__PURE__ */ S("div", { className: je.container, children: [
|
|
10066
10069
|
/* @__PURE__ */ S("div", { className: je.header, children: [
|
|
10067
10070
|
/* @__PURE__ */ u("h2", { className: je.title, children: r.manageCollaborators.title }),
|
|
@@ -10088,7 +10091,7 @@ const c1 = "_container_1hnn8_1", d1 = "_header_1hnn8_13", u1 = "_title_1hnn8_22"
|
|
|
10088
10091
|
var P, F, B, U;
|
|
10089
10092
|
return /* @__PURE__ */ S("li", { className: je.resultItem, role: "option", "aria-selected": "false", children: [
|
|
10090
10093
|
/* @__PURE__ */ S("div", { className: je.userInfo, children: [
|
|
10091
|
-
/* @__PURE__ */ u("span", { className: je.userName, children:
|
|
10094
|
+
/* @__PURE__ */ u("span", { className: je.userName, children: A(N) }),
|
|
10092
10095
|
N.email && /* @__PURE__ */ u("span", { className: je.userEmail, children: N.email }),
|
|
10093
10096
|
(((F = (P = N.organisations) == null ? void 0 : P[0]) == null ? void 0 : F.orgName) ?? N.rootOrgName) && /* @__PURE__ */ u("span", { className: je.userOrg, children: ((U = (B = N.organisations) == null ? void 0 : B[0]) == null ? void 0 : U.orgName) ?? N.rootOrgName })
|
|
10094
10097
|
] }),
|
|
@@ -10113,9 +10116,9 @@ const c1 = "_container_1hnn8_1", d1 = "_header_1hnn8_13", u1 = "_title_1hnn8_22"
|
|
|
10113
10116
|
m.length === 0 ? /* @__PURE__ */ u("p", { className: je.emptyCollab, children: r.manageCollaborators.noCollaboratorsYet }) : /* @__PURE__ */ u("ul", { className: je.collabList, children: m.map((N) => {
|
|
10114
10117
|
var P, F, B, U;
|
|
10115
10118
|
return /* @__PURE__ */ S("li", { className: je.collabItem, children: [
|
|
10116
|
-
/* @__PURE__ */ u("div", { className: je.userAvatar, "aria-hidden": "true", children:
|
|
10119
|
+
/* @__PURE__ */ u("div", { className: je.userAvatar, "aria-hidden": "true", children: A(N).charAt(0).toUpperCase() }),
|
|
10117
10120
|
/* @__PURE__ */ S("div", { className: je.userInfo, children: [
|
|
10118
|
-
/* @__PURE__ */ u("span", { className: je.userName, children:
|
|
10121
|
+
/* @__PURE__ */ u("span", { className: je.userName, children: A(N) }),
|
|
10119
10122
|
N.email && /* @__PURE__ */ u("span", { className: je.userEmail, children: N.email }),
|
|
10120
10123
|
(((F = (P = N.organisations) == null ? void 0 : P[0]) == null ? void 0 : F.orgName) ?? N.rootOrgName) && /* @__PURE__ */ u("span", { className: je.userOrg, children: ((U = (B = N.organisations) == null ? void 0 : B[0]) == null ? void 0 : U.orgName) ?? N.rootOrgName })
|
|
10121
10124
|
] }),
|
|
@@ -10124,7 +10127,7 @@ const c1 = "_container_1hnn8_1", d1 = "_header_1hnn8_13", u1 = "_title_1hnn8_22"
|
|
|
10124
10127
|
{
|
|
10125
10128
|
variant: "danger",
|
|
10126
10129
|
size: "sm",
|
|
10127
|
-
onClick: () =>
|
|
10130
|
+
onClick: () => E(N.identifier),
|
|
10128
10131
|
children: r.manageCollaborators.remove
|
|
10129
10132
|
}
|
|
10130
10133
|
)
|
|
@@ -10349,7 +10352,7 @@ const pA = ({
|
|
|
10349
10352
|
var we, Oe, J, pe;
|
|
10350
10353
|
return ((Oe = (we = he.editorConfig) == null ? void 0 : we.context) == null ? void 0 : Oe.contentId) ?? ((pe = (J = he.editorConfig) == null ? void 0 : J.context) == null ? void 0 : pe.identifier) ?? "";
|
|
10351
10354
|
}
|
|
10352
|
-
), { activeModal: m, modalData: p, closeModal: y, openModal: h } = Er(), g = X((he) => he.buttonLoaders), v = X((he) => he.categoryMeta), b = X((he) => he.editorProfile), C = b.key === "learningPath", _ = b.features.dialcodes && (!v || v.schemaDefaults.generateDIALCodes !== "No"), [T,
|
|
10355
|
+
), { activeModal: m, modalData: p, closeModal: y, openModal: h } = Er(), g = X((he) => he.buttonLoaders), v = X((he) => he.categoryMeta), b = X((he) => he.editorProfile), C = b.key === "learningPath", _ = b.features.dialcodes && (!v || v.schemaDefaults.generateDIALCodes !== "No"), [T, E] = j(!1), [L, A] = j(!1), [R, x] = j(!1), N = ie(null), [P, F] = j(!1);
|
|
10353
10356
|
ee(() => {
|
|
10354
10357
|
if (!R) return;
|
|
10355
10358
|
const he = (we) => {
|
|
@@ -10470,7 +10473,7 @@ const pA = ({
|
|
|
10470
10473
|
{
|
|
10471
10474
|
variant: "primary",
|
|
10472
10475
|
size: "sm",
|
|
10473
|
-
onClick: () =>
|
|
10476
|
+
onClick: () => A(!0),
|
|
10474
10477
|
disabled: g.saveCollection,
|
|
10475
10478
|
isLoading: g.saveCollection,
|
|
10476
10479
|
children: [
|
|
@@ -10564,7 +10567,7 @@ const pA = ({
|
|
|
10564
10567
|
{
|
|
10565
10568
|
variant: "primary",
|
|
10566
10569
|
size: "sm",
|
|
10567
|
-
onClick: () =>
|
|
10570
|
+
onClick: () => E(!0),
|
|
10568
10571
|
disabled: g.rejectCollection,
|
|
10569
10572
|
isLoading: g.rejectCollection,
|
|
10570
10573
|
children: [
|
|
@@ -10644,9 +10647,9 @@ const pA = ({
|
|
|
10644
10647
|
mA,
|
|
10645
10648
|
{
|
|
10646
10649
|
onConfirm: () => {
|
|
10647
|
-
|
|
10650
|
+
A(!1), q("sendForReview");
|
|
10648
10651
|
},
|
|
10649
|
-
onCancel: () =>
|
|
10652
|
+
onCancel: () => A(!1)
|
|
10650
10653
|
}
|
|
10651
10654
|
),
|
|
10652
10655
|
T && /* @__PURE__ */ u(
|
|
@@ -10658,9 +10661,9 @@ const pA = ({
|
|
|
10658
10661
|
submitLabel: s.topbar.requestForChangesButton,
|
|
10659
10662
|
submitVariant: "primary",
|
|
10660
10663
|
onConfirm: (he) => {
|
|
10661
|
-
|
|
10664
|
+
E(!1), q("reject", { comment: he });
|
|
10662
10665
|
},
|
|
10663
|
-
onCancel: () =>
|
|
10666
|
+
onCancel: () => E(!1)
|
|
10664
10667
|
}
|
|
10665
10668
|
),
|
|
10666
10669
|
P && /* @__PURE__ */ u(
|
|
@@ -11346,21 +11349,21 @@ function fp(e) {
|
|
|
11346
11349
|
scrollUpdateWasRequested: b
|
|
11347
11350
|
});
|
|
11348
11351
|
}), h._getItemStyle = void 0, h._getItemStyle = function(g) {
|
|
11349
|
-
var v = h.props, b = v.direction, C = v.itemSize, _ = v.layout, T = h._getItemStyleCache(c && C, c && _, c && b),
|
|
11352
|
+
var v = h.props, b = v.direction, C = v.itemSize, _ = v.layout, T = h._getItemStyleCache(c && C, c && _, c && b), E;
|
|
11350
11353
|
if (T.hasOwnProperty(g))
|
|
11351
|
-
|
|
11354
|
+
E = T[g];
|
|
11352
11355
|
else {
|
|
11353
|
-
var L = r(h.props, g, h._instanceProps),
|
|
11354
|
-
T[g] =
|
|
11356
|
+
var L = r(h.props, g, h._instanceProps), A = i(h.props, g, h._instanceProps), R = b === "horizontal" || _ === "horizontal", x = b === "rtl", N = R ? L : 0;
|
|
11357
|
+
T[g] = E = {
|
|
11355
11358
|
position: "absolute",
|
|
11356
11359
|
left: x ? void 0 : N,
|
|
11357
11360
|
right: x ? N : void 0,
|
|
11358
11361
|
top: R ? 0 : L,
|
|
11359
|
-
height: R ? "100%" :
|
|
11360
|
-
width: R ?
|
|
11362
|
+
height: R ? "100%" : A,
|
|
11363
|
+
width: R ? A : "100%"
|
|
11361
11364
|
};
|
|
11362
11365
|
}
|
|
11363
|
-
return
|
|
11366
|
+
return E;
|
|
11364
11367
|
}, h._getItemStyleCache = void 0, h._getItemStyleCache = ca(function(g, v, b) {
|
|
11365
11368
|
return {};
|
|
11366
11369
|
}), h._onScrollHorizontal = function(g) {
|
|
@@ -11368,8 +11371,8 @@ function fp(e) {
|
|
|
11368
11371
|
h.setState(function(T) {
|
|
11369
11372
|
if (T.scrollOffset === C)
|
|
11370
11373
|
return null;
|
|
11371
|
-
var
|
|
11372
|
-
if (
|
|
11374
|
+
var E = h.props.direction, L = C;
|
|
11375
|
+
if (E === "rtl")
|
|
11373
11376
|
switch (Id()) {
|
|
11374
11377
|
case "negative":
|
|
11375
11378
|
L = -C;
|
|
@@ -11390,11 +11393,11 @@ function fp(e) {
|
|
|
11390
11393
|
h.setState(function(T) {
|
|
11391
11394
|
if (T.scrollOffset === _)
|
|
11392
11395
|
return null;
|
|
11393
|
-
var
|
|
11396
|
+
var E = Math.max(0, Math.min(_, C - b));
|
|
11394
11397
|
return {
|
|
11395
11398
|
isScrolling: !0,
|
|
11396
|
-
scrollDirection: T.scrollOffset <
|
|
11397
|
-
scrollOffset:
|
|
11399
|
+
scrollDirection: T.scrollOffset < E ? "forward" : "backward",
|
|
11400
|
+
scrollOffset: E,
|
|
11398
11401
|
scrollUpdateWasRequested: !1
|
|
11399
11402
|
};
|
|
11400
11403
|
}, h._resetIsScrollingDebounced);
|
|
@@ -11429,8 +11432,8 @@ function fp(e) {
|
|
|
11429
11432
|
h = Math.max(0, Math.min(h, b - 1));
|
|
11430
11433
|
var T = 0;
|
|
11431
11434
|
if (this._outerRef) {
|
|
11432
|
-
var
|
|
11433
|
-
C === "vertical" ? T =
|
|
11435
|
+
var E = this._outerRef;
|
|
11436
|
+
C === "vertical" ? T = E.scrollWidth > E.clientWidth ? Ed() : 0 : T = E.scrollHeight > E.clientHeight ? Ed() : 0;
|
|
11434
11437
|
}
|
|
11435
11438
|
this.scrollTo(o(this.props, h, g, _, this._instanceProps, T));
|
|
11436
11439
|
}, p.componentDidMount = function() {
|
|
@@ -11454,8 +11457,8 @@ function fp(e) {
|
|
|
11454
11457
|
T.scrollLeft = C;
|
|
11455
11458
|
break;
|
|
11456
11459
|
default:
|
|
11457
|
-
var
|
|
11458
|
-
T.scrollLeft = L -
|
|
11460
|
+
var E = T.clientWidth, L = T.scrollWidth;
|
|
11461
|
+
T.scrollLeft = L - E - C;
|
|
11459
11462
|
break;
|
|
11460
11463
|
}
|
|
11461
11464
|
else
|
|
@@ -11467,12 +11470,12 @@ function fp(e) {
|
|
|
11467
11470
|
}, p.componentWillUnmount = function() {
|
|
11468
11471
|
this._resetIsScrollingTimeoutId !== null && Ad(this._resetIsScrollingTimeoutId);
|
|
11469
11472
|
}, p.render = function() {
|
|
11470
|
-
var h = this.props, g = h.children, v = h.className, b = h.direction, C = h.height, _ = h.innerRef, T = h.innerElementType,
|
|
11473
|
+
var h = this.props, g = h.children, v = h.className, b = h.direction, C = h.height, _ = h.innerRef, T = h.innerElementType, E = h.innerTagName, L = h.itemCount, A = h.itemData, R = h.itemKey, x = R === void 0 ? JA : R, N = h.layout, P = h.outerElementType, F = h.outerTagName, B = h.style, U = h.useIsScrolling, oe = h.width, Q = this.state.isScrolling, se = b === "horizontal" || N === "horizontal", ge = se ? this._onScrollHorizontal : this._onScrollVertical, ve = this._getRangeToRender(), be = ve[0], fe = ve[1], De = [];
|
|
11471
11474
|
if (L > 0)
|
|
11472
11475
|
for (var Se = be; Se <= fe; Se++)
|
|
11473
11476
|
De.push(Qn(g, {
|
|
11474
|
-
data:
|
|
11475
|
-
key: x(Se,
|
|
11477
|
+
data: A,
|
|
11478
|
+
key: x(Se, A),
|
|
11476
11479
|
index: Se,
|
|
11477
11480
|
isScrolling: U ? Q : void 0,
|
|
11478
11481
|
style: this._getItemStyle(Se)
|
|
@@ -11491,7 +11494,7 @@ function fp(e) {
|
|
|
11491
11494
|
willChange: "transform",
|
|
11492
11495
|
direction: b
|
|
11493
11496
|
}, B)
|
|
11494
|
-
}, Qn(T ||
|
|
11497
|
+
}, Qn(T || E || "div", {
|
|
11495
11498
|
children: De,
|
|
11496
11499
|
ref: _,
|
|
11497
11500
|
style: {
|
|
@@ -11509,15 +11512,15 @@ function fp(e) {
|
|
|
11509
11512
|
}
|
|
11510
11513
|
}
|
|
11511
11514
|
if (typeof this.props.onScroll == "function") {
|
|
11512
|
-
var T = this.state,
|
|
11513
|
-
this._callOnScroll(
|
|
11515
|
+
var T = this.state, E = T.scrollDirection, L = T.scrollOffset, A = T.scrollUpdateWasRequested;
|
|
11516
|
+
this._callOnScroll(E, L, A);
|
|
11514
11517
|
}
|
|
11515
11518
|
}, p._getRangeToRender = function() {
|
|
11516
11519
|
var h = this.props, g = h.itemCount, v = h.overscanCount, b = this.state, C = b.isScrolling, _ = b.scrollDirection, T = b.scrollOffset;
|
|
11517
11520
|
if (g === 0)
|
|
11518
11521
|
return [0, 0, 0, 0];
|
|
11519
|
-
var
|
|
11520
|
-
return [Math.max(0,
|
|
11522
|
+
var E = s(this.props, T, this._instanceProps), L = a(this.props, E, T, this._instanceProps), A = !C || _ === "backward" ? Math.max(1, v) : 1, R = !C || _ === "forward" ? Math.max(1, v) : 1;
|
|
11523
|
+
return [Math.max(0, E - A), Math.max(0, Math.min(g - 1, L + R)), E, L];
|
|
11521
11524
|
}, m;
|
|
11522
11525
|
})(Em), t.defaultProps = {
|
|
11523
11526
|
direction: "ltr",
|
|
@@ -14288,8 +14291,8 @@ var ou = /* @__PURE__ */ (function() {
|
|
|
14288
14291
|
kD(this, e), Ii(this, "xs", void 0), Ii(this, "ys", void 0), Ii(this, "c1s", void 0), Ii(this, "c2s", void 0), Ii(this, "c3s", void 0);
|
|
14289
14292
|
for (var n = t.length, i = [], o = 0; o < n; o++)
|
|
14290
14293
|
i.push(o);
|
|
14291
|
-
i.sort(function(
|
|
14292
|
-
return t[
|
|
14294
|
+
i.sort(function(A, R) {
|
|
14295
|
+
return t[A] < t[R] ? -1 : 1;
|
|
14293
14296
|
});
|
|
14294
14297
|
for (var s = [], a = [], l, c, d = 0; d < n - 1; d++)
|
|
14295
14298
|
l = t[d + 1] - t[d], c = r[d + 1] - r[d], s.push(l), a.push(c / l);
|
|
@@ -14306,8 +14309,8 @@ var ou = /* @__PURE__ */ (function() {
|
|
|
14306
14309
|
f.push(a[a.length - 1]);
|
|
14307
14310
|
for (var v = [], b = [], C, _ = 0; _ < f.length - 1; _++) {
|
|
14308
14311
|
C = a[_];
|
|
14309
|
-
var T = f[_],
|
|
14310
|
-
v.push((C - T - L) *
|
|
14312
|
+
var T = f[_], E = 1 / s[_], L = T + f[_ + 1] - C - C;
|
|
14313
|
+
v.push((C - T - L) * E), b.push(L * E * E);
|
|
14311
14314
|
}
|
|
14312
14315
|
this.xs = t, this.ys = r, this.c1s = f, this.c2s = v, this.c3s = b;
|
|
14313
14316
|
}
|
|
@@ -14372,8 +14375,8 @@ function RD(e, t, r, n, i) {
|
|
|
14372
14375
|
l.y / d * h,
|
|
14373
14376
|
// Dock to the bottom
|
|
14374
14377
|
l.y + h - d
|
|
14375
|
-
]),
|
|
14376
|
-
return kp() && o && (
|
|
14378
|
+
]), A = L.interpolate(m);
|
|
14379
|
+
return kp() && o && (A += (window.devicePixelRatio - 1) * h), A;
|
|
14377
14380
|
}, v = function() {
|
|
14378
14381
|
var L = new ou([0, 0.5, 1], [
|
|
14379
14382
|
// Dock to the left
|
|
@@ -14662,8 +14665,8 @@ var WD = /* @__PURE__ */ (function() {
|
|
|
14662
14665
|
} catch {
|
|
14663
14666
|
}
|
|
14664
14667
|
i.setCurrentDragSourceNode(o.target);
|
|
14665
|
-
var T = i.getCurrentSourcePreviewNodeOptions(),
|
|
14666
|
-
|
|
14668
|
+
var T = i.getCurrentSourcePreviewNodeOptions(), E = T.captureDraggingState;
|
|
14669
|
+
E ? i.actions.publishDragSource() : setTimeout(function() {
|
|
14667
14670
|
return i.actions.publishDragSource();
|
|
14668
14671
|
}, 0);
|
|
14669
14672
|
} else if (c)
|
|
@@ -16390,7 +16393,7 @@ const RL = "_row_nm332_1", xL = "_grip_nm332_16", FL = "_menuBtn_nm332_19", ML =
|
|
|
16390
16393
|
dragHandle: r,
|
|
16391
16394
|
editorMode: n
|
|
16392
16395
|
}) => {
|
|
16393
|
-
const [i, o] = j(!1), [s, a] = j(!1), [l, c] = j(e.data.name), d = ie(null), f = ue(), m = X((P) => P.editorProfile), p = n === "edit", y = oc(), h = vo(e.data), g = JL[h.key] ?? tn, v = e.isSelected, b = e.level === 0, C = e.data.isFolder ?? (e.children && e.children.length > 0), _ = m.key === "learningPath", T = b ? _ ? Qh : qy : C ? _ ? Ky : Jf : g,
|
|
16396
|
+
const [i, o] = j(!1), [s, a] = j(!1), [l, c] = j(e.data.name), d = ie(null), f = ue(), m = X((P) => P.editorProfile), p = n === "edit", y = oc(), h = vo(e.data), g = JL[h.key] ?? tn, v = e.isSelected, b = e.level === 0, C = e.data.isFolder ?? (e.children && e.children.length > 0), _ = m.key === "learningPath", T = b ? _ ? Qh : qy : C ? _ ? Ky : Jf : g, E = _ && C && !b && !mt(e.data), L = e.level + 1 <= m.maxDepth, A = _ ? f.learningPath.addLevelButton : f.treeNode.addSubunitMenuItem, R = _ ? f.learningPath.addLevelButton : f.treeNode.addSiblingMenuItem;
|
|
16394
16397
|
ee(() => {
|
|
16395
16398
|
if (!i) return;
|
|
16396
16399
|
const P = (F) => {
|
|
@@ -16467,7 +16470,7 @@ const RL = "_row_nm332_1", xL = "_grip_nm332_16", FL = "_menuBtn_nm332_19", ML =
|
|
|
16467
16470
|
className: [
|
|
16468
16471
|
ft.title,
|
|
16469
16472
|
_ ? ft.titleLp : "",
|
|
16470
|
-
|
|
16473
|
+
E ? ft.levelTitle : ""
|
|
16471
16474
|
].filter(Boolean).join(" "),
|
|
16472
16475
|
title: e.data.name,
|
|
16473
16476
|
onDoubleClick: () => p && a(!0),
|
|
@@ -16512,7 +16515,7 @@ const RL = "_row_nm332_1", xL = "_grip_nm332_16", FL = "_menuBtn_nm332_19", ML =
|
|
|
16512
16515
|
children: [
|
|
16513
16516
|
/* @__PURE__ */ u(Xf, { size: 13 }),
|
|
16514
16517
|
" ",
|
|
16515
|
-
|
|
16518
|
+
A
|
|
16516
16519
|
]
|
|
16517
16520
|
}
|
|
16518
16521
|
),
|
|
@@ -16636,7 +16639,7 @@ const sO = "_container_jw2be_1", aO = "_header_jw2be_13", lO = "_title_jw2be_22"
|
|
|
16636
16639
|
ee(() => () => C(), [C]);
|
|
16637
16640
|
const _ = (N) => N.name.toLowerCase().endsWith(".csv") ? N.size > 50 * 1024 * 1024 ? (m(i.csvUpload.fileTooLarge), !1) : !0 : (m(i.csvUpload.invalidFileType), !1), T = Z((N) => {
|
|
16638
16641
|
m(""), y([]), g(null), d("idle"), _(N) && s(N);
|
|
16639
|
-
}, []),
|
|
16642
|
+
}, []), E = Z(
|
|
16640
16643
|
(N) => {
|
|
16641
16644
|
N.preventDefault(), l(!1);
|
|
16642
16645
|
const P = N.dataTransfer.files[0];
|
|
@@ -16650,7 +16653,7 @@ const sO = "_container_jw2be_1", aO = "_header_jw2be_13", lO = "_title_jw2be_22"
|
|
|
16650
16653
|
P && T(P), N.target.value = "";
|
|
16651
16654
|
},
|
|
16652
16655
|
[T]
|
|
16653
|
-
),
|
|
16656
|
+
), A = Z(async () => {
|
|
16654
16657
|
try {
|
|
16655
16658
|
const N = await oO(e), P = document.createElement("a");
|
|
16656
16659
|
P.href = N, P.download = "sample_hierarchy.csv", P.target = "_blank", P.click();
|
|
@@ -16704,7 +16707,7 @@ const sO = "_container_jw2be_1", aO = "_header_jw2be_13", lO = "_title_jw2be_22"
|
|
|
16704
16707
|
onDragLeave: (N) => {
|
|
16705
16708
|
N.preventDefault(), l(!1);
|
|
16706
16709
|
},
|
|
16707
|
-
onDrop:
|
|
16710
|
+
onDrop: E,
|
|
16708
16711
|
onClick: () => {
|
|
16709
16712
|
var N;
|
|
16710
16713
|
return (N = v.current) == null ? void 0 : N.click();
|
|
@@ -16748,7 +16751,7 @@ const sO = "_container_jw2be_1", aO = "_header_jw2be_13", lO = "_title_jw2be_22"
|
|
|
16748
16751
|
"button",
|
|
16749
16752
|
{
|
|
16750
16753
|
className: Ge.sampleLink,
|
|
16751
|
-
onClick:
|
|
16754
|
+
onClick: A,
|
|
16752
16755
|
type: "button",
|
|
16753
16756
|
children: i.csvUpload.downloadSample
|
|
16754
16757
|
}
|
|
@@ -16799,17 +16802,17 @@ const sO = "_container_jw2be_1", aO = "_header_jw2be_13", lO = "_title_jw2be_22"
|
|
|
16799
16802
|
] });
|
|
16800
16803
|
};
|
|
16801
16804
|
function sc() {
|
|
16802
|
-
var g, v, b, C, _, T,
|
|
16805
|
+
var g, v, b, C, _, T, E;
|
|
16803
16806
|
const e = ue(), t = ae((L) => L.treeData), r = ae((L) => L.treeCache), n = ae((L) => L.deleteNode), i = Er((L) => L.activeAssessmentSlot), o = Er((L) => L.setActiveAssessmentSlot), s = Er((L) => L.openModal), a = ((g = t[0]) == null ? void 0 : g.children) ?? [], l = a[0], c = a.length > 1 ? a[a.length - 1] : void 0, d = mt(l), f = mt(c), m = t[0], p = m ? ((v = r[m.id]) == null ? void 0 : v.policy) ?? ((b = m.metadata) == null ? void 0 : b.policy) : void 0, y = !!p && jh.has(p), h = (L) => {
|
|
16804
|
-
const
|
|
16805
|
-
if (!
|
|
16807
|
+
const A = L === "pre" ? l : c;
|
|
16808
|
+
if (!A) return;
|
|
16806
16809
|
const R = L === "pre" && y ? e.learningPath.deletePriorAssessmentConfirm : e.learningPath.deleteAssessmentSlotConfirm;
|
|
16807
|
-
s("confirmDelete", { message: R, onConfirm: () => n(
|
|
16810
|
+
s("confirmDelete", { message: R, onConfirm: () => n(A.id) });
|
|
16808
16811
|
};
|
|
16809
16812
|
return {
|
|
16810
16813
|
pre: { level: l, filled: d, courseName: d ? (_ = (C = l == null ? void 0 : l.children) == null ? void 0 : C[0]) == null ? void 0 : _.name : void 0, required: y },
|
|
16811
16814
|
// Outcome Assessment is optional — never blocks publish/send-for-review.
|
|
16812
|
-
post: { level: c, filled: f, courseName: f ? (
|
|
16815
|
+
post: { level: c, filled: f, courseName: f ? (E = (T = c == null ? void 0 : c.children) == null ? void 0 : T[0]) == null ? void 0 : E.name : void 0, required: !1 },
|
|
16813
16816
|
activeAssessmentSlot: i,
|
|
16814
16817
|
setActiveAssessmentSlot: o,
|
|
16815
16818
|
deleteSlot: h
|
|
@@ -16832,7 +16835,7 @@ const $O = "_container_2qylm_1", jO = "_header_2qylm_8", UO = "_sectionLabel_2qy
|
|
|
16832
16835
|
onToggleCollapse: r
|
|
16833
16836
|
}) => {
|
|
16834
16837
|
var Oe;
|
|
16835
|
-
const n = ue(), i = ie(null), o = ie(null), s = ie(null), [a, l] = j(400), [c, d] = j(!1), [f, m] = j(!1), [p, y] = j("create"), { treeData: h, selectedNodeId: g, selectNode: v, addNode: b, deleteNode: C, getNodeById: _, reorderChildren: T, moveNode:
|
|
16838
|
+
const n = ue(), i = ie(null), o = ie(null), s = ie(null), [a, l] = j(400), [c, d] = j(!1), [f, m] = j(!1), [p, y] = j("create"), { treeData: h, selectedNodeId: g, selectNode: v, addNode: b, deleteNode: C, getNodeById: _, reorderChildren: T, moveNode: E, setTreeData: L } = ae(), A = Er((J) => J.openModal), R = X((J) => J.editorProfile), x = R.key === "learningPath", N = e === "edit", P = oc(), F = N && P, B = x ? n.learningPath.addLevelButton : n.outlineTree.addUnitButton, U = R.maxDepth > 1, oe = (((Oe = h[0]) == null ? void 0 : Oe.children) ?? []).some((J) => J.isFolder), { pre: Q, post: se, deleteSlot: ge } = sc(), { level: ve } = Q, { level: be } = se, fe = X(
|
|
16836
16839
|
(J) => {
|
|
16837
16840
|
var pe, W, Ee, Qe;
|
|
16838
16841
|
return ((W = (pe = J.editorConfig) == null ? void 0 : pe.context) == null ? void 0 : W.contentId) ?? ((Qe = (Ee = J.editorConfig) == null ? void 0 : Ee.context) == null ? void 0 : Qe.identifier) ?? "";
|
|
@@ -16872,9 +16875,9 @@ const $O = "_container_2qylm_1", jO = "_header_2qylm_8", UO = "_sectionLabel_2qy
|
|
|
16872
16875
|
if (et < 0) return;
|
|
16873
16876
|
T(J, et, pe > et ? pe - 1 : pe);
|
|
16874
16877
|
} else
|
|
16875
|
-
|
|
16878
|
+
E(Ee, at ?? "", J);
|
|
16876
16879
|
},
|
|
16877
|
-
[h, T,
|
|
16880
|
+
[h, T, E]
|
|
16878
16881
|
), te = Z(
|
|
16879
16882
|
({ ids: J }) => {
|
|
16880
16883
|
if (!x) {
|
|
@@ -16892,18 +16895,18 @@ const $O = "_container_2qylm_1", jO = "_header_2qylm_8", UO = "_sectionLabel_2qy
|
|
|
16892
16895
|
return;
|
|
16893
16896
|
}
|
|
16894
16897
|
const Ee = _(W), Qe = Ee != null && Ee.isFolder ? n.learningPath.deleteLevelConfirm.replace("{name}", Ee.name) : n.learningPath.deleteCourseConfirm;
|
|
16895
|
-
|
|
16898
|
+
A("confirmDelete", { message: Qe, onConfirm: () => C(W) });
|
|
16896
16899
|
return;
|
|
16897
16900
|
}
|
|
16898
16901
|
const pe = n.learningPath.deleteMultipleConfirm.replace("{count}", String(J.length));
|
|
16899
|
-
|
|
16902
|
+
A("confirmDelete", {
|
|
16900
16903
|
message: pe,
|
|
16901
16904
|
onConfirm: () => {
|
|
16902
16905
|
for (const W of J) C(W);
|
|
16903
16906
|
}
|
|
16904
16907
|
});
|
|
16905
16908
|
},
|
|
16906
|
-
[C, ge, x, ve, be, _,
|
|
16909
|
+
[C, ge, x, ve, be, _, A, n]
|
|
16907
16910
|
), ye = Z(
|
|
16908
16911
|
({ parentId: J }) => {
|
|
16909
16912
|
var Ee;
|
|
@@ -17273,8 +17276,8 @@ function cN(e) {
|
|
|
17273
17276
|
if (!o) {
|
|
17274
17277
|
const T = _l(n, r._names, _ || r._formValues, !1, l.current);
|
|
17275
17278
|
if (c.current) {
|
|
17276
|
-
const
|
|
17277
|
-
Yt(
|
|
17279
|
+
const E = c.current(T);
|
|
17280
|
+
Yt(E, d.current) || (y(E), d.current = E);
|
|
17278
17281
|
} else
|
|
17279
17282
|
y(T);
|
|
17280
17283
|
}
|
|
@@ -17356,7 +17359,7 @@ function Co(e) {
|
|
|
17356
17359
|
_ && (p.current = {
|
|
17357
17360
|
focus: () => Pt(_.focus) && _.focus(),
|
|
17358
17361
|
select: () => Pt(_.select) && _.select(),
|
|
17359
|
-
setCustomValidity: (
|
|
17362
|
+
setCustomValidity: (E) => Pt(_.setCustomValidity) && _.setCustomValidity(E),
|
|
17360
17363
|
reportValidity: () => Pt(_.reportValidity) && _.reportValidity()
|
|
17361
17364
|
});
|
|
17362
17365
|
const T = Y(i._fields, r);
|
|
@@ -17375,17 +17378,17 @@ function Co(e) {
|
|
|
17375
17378
|
...m.current.rules,
|
|
17376
17379
|
...Kt(m.current.disabled) ? { disabled: m.current.disabled } : {}
|
|
17377
17380
|
});
|
|
17378
|
-
const T = (
|
|
17379
|
-
const
|
|
17380
|
-
|
|
17381
|
+
const T = (E, L) => {
|
|
17382
|
+
const A = Y(i._fields, E);
|
|
17383
|
+
A && A._f && (A._f.mount = L);
|
|
17381
17384
|
};
|
|
17382
17385
|
if (T(r, !0), _) {
|
|
17383
|
-
const
|
|
17384
|
-
Ye(i._defaultValues, r,
|
|
17386
|
+
const E = ot(Y(o ? i._defaultValues : i._options.values || i._defaultValues, r, Y(i._options.defaultValues, r, m.current.defaultValue)));
|
|
17387
|
+
Ye(i._defaultValues, r, E), Xe(Y(i._formValues, r)) && Ye(i._formValues, r, E);
|
|
17385
17388
|
}
|
|
17386
17389
|
if (!l && i.register(r), p.current) {
|
|
17387
|
-
const
|
|
17388
|
-
|
|
17390
|
+
const E = Y(i._fields, r);
|
|
17391
|
+
E && E._f && (E._f.ref = p.current);
|
|
17389
17392
|
}
|
|
17390
17393
|
return () => {
|
|
17391
17394
|
(l ? _ && !i._state.action : _) ? i.unregister(r) : T(r, !1);
|
|
@@ -17685,7 +17688,7 @@ var $n = (e) => it(e) && !ms(e) ? e : {
|
|
|
17685
17688
|
const F = Kt(P) ? "" : P || "";
|
|
17686
17689
|
a ? a.forEach((B) => B.setCustomValidity(F)) : C.setCustomValidity(F), C.reportValidity();
|
|
17687
17690
|
}
|
|
17688
|
-
}, T = {},
|
|
17691
|
+
}, T = {}, E = fc(s), L = yo(s), A = E || L, R = (g || uc(s)) && Xe(s.value) && Xe(b) || ps(s) && s.value === "" || b === "" || Array.isArray(b) && !b.length, x = fN.bind(null, h, n, T), N = (P, F, B, U = dr.maxLength, oe = dr.minLength) => {
|
|
17689
17692
|
const Q = P ? F : B;
|
|
17690
17693
|
T[h] = {
|
|
17691
17694
|
type: P ? U : oe,
|
|
@@ -17694,7 +17697,7 @@ var $n = (e) => it(e) && !ms(e) ? e : {
|
|
|
17694
17697
|
...x(P ? U : oe, Q)
|
|
17695
17698
|
};
|
|
17696
17699
|
};
|
|
17697
|
-
if (o ? !Array.isArray(b) || !b.length : l && (!
|
|
17700
|
+
if (o ? !Array.isArray(b) || !b.length : l && (!A && (R || Tt(b)) || Kt(b) && !b || L && !Zp(a).isValid || E && !Jp(a).isValid)) {
|
|
17698
17701
|
const { value: P, message: F } = Rt(l) ? { value: !!l, message: l } : $n(l);
|
|
17699
17702
|
if (P && (T[h] = {
|
|
17700
17703
|
type: dr.required,
|
|
@@ -17870,7 +17873,7 @@ function AN(e = {}) {
|
|
|
17870
17873
|
errors: r.errors,
|
|
17871
17874
|
isValid: !1
|
|
17872
17875
|
});
|
|
17873
|
-
},
|
|
17876
|
+
}, E = (w) => {
|
|
17874
17877
|
const I = bo(w) ? [w] : Ws(w);
|
|
17875
17878
|
let D = o, z = i;
|
|
17876
17879
|
for (let V = 0; V < I.length - 1; V++) {
|
|
@@ -17882,12 +17885,12 @@ function AN(e = {}) {
|
|
|
17882
17885
|
}, L = (w, I, D, z) => {
|
|
17883
17886
|
const V = Y(n, w);
|
|
17884
17887
|
if (V) {
|
|
17885
|
-
if (
|
|
17888
|
+
if (E(w))
|
|
17886
17889
|
return;
|
|
17887
17890
|
const G = Xe(Y(o, w)), H = Y(o, w, Xe(D) ? Y(i, w) : D);
|
|
17888
17891
|
Xe(H) || z && z.defaultChecked || I ? Ye(o, w, I ? H : Au(V._f)) : se(w, H), s.mount && !s.action && (g(), G && r.isDirty && (f.isDirty || m.isDirty) && (U() || (r.isDirty = !1, p.state.next({ ...r }))), e.shouldUnregister && G && !Xe(Y(o, w)) && Aa(w, a) && (s.watch = !0));
|
|
17889
17892
|
}
|
|
17890
|
-
},
|
|
17893
|
+
}, A = (w, I, D, z, V) => {
|
|
17891
17894
|
let G = !1, H = !1;
|
|
17892
17895
|
const le = {
|
|
17893
17896
|
name: w
|
|
@@ -18003,7 +18006,7 @@ function AN(e = {}) {
|
|
|
18003
18006
|
values: z ? o : ot(o)
|
|
18004
18007
|
})));
|
|
18005
18008
|
}
|
|
18006
|
-
(D.shouldDirty || D.shouldTouch) &&
|
|
18009
|
+
(D.shouldDirty || D.shouldTouch) && A(w, G, D.shouldTouch, D.shouldDirty, !0), D.shouldValidate && M(w);
|
|
18007
18010
|
}, ge = (w, I, D, z = !1) => {
|
|
18008
18011
|
for (const V in I) {
|
|
18009
18012
|
if (!I.hasOwnProperty(V))
|
|
@@ -18061,7 +18064,7 @@ function AN(e = {}) {
|
|
|
18061
18064
|
let ce, $e;
|
|
18062
18065
|
const tt = I.type ? Au(V._f) : Cl(w), ut = w.type === Ur.BLUR || w.type === Ur.FOCUS_OUT, Xt = !bN(V._f) && !e.validate && !t.resolver && !Y(r.errors, D) && !V._f.deps || wN(ut, Y(r.touchedFields, D), r.isSubmitted, le, H), Ci = Aa(D, a, ut);
|
|
18063
18066
|
Ye(o, D, tt), ut ? (!I || !I.readOnly) && (V._f.onBlur && V._f.onBlur(w), l && l(0)) : V._f.onChange && V._f.onChange(w);
|
|
18064
|
-
const on =
|
|
18067
|
+
const on = A(D, tt, ut), gt = !bt(on) || Ci;
|
|
18065
18068
|
if (!ut && p.state.next({
|
|
18066
18069
|
name: D,
|
|
18067
18070
|
type: w.type,
|
|
@@ -19465,7 +19468,7 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
19465
19468
|
onSelect: r,
|
|
19466
19469
|
onClose: n
|
|
19467
19470
|
}) => {
|
|
19468
|
-
const i = ue(), [o, s] = j("my"), [a, l] = j(""), [c, d] = j([]), [f, m] = j(0), [p, y] = j(!1), [h, g] = j(null), [v, b] = j(0), [C, _] = j(null), [T,
|
|
19471
|
+
const i = ue(), [o, s] = j("my"), [a, l] = j(""), [c, d] = j([]), [f, m] = j(0), [p, y] = j(!1), [h, g] = j(null), [v, b] = j(0), [C, _] = j(null), [T, E] = j(""), [L, A] = j(!1), [R, x] = j(""), N = ie(null), P = X((M) => {
|
|
19469
19472
|
var q, te;
|
|
19470
19473
|
return ((te = (q = M.editorConfig) == null ? void 0 : q.context) == null ? void 0 : te.channel) ?? "";
|
|
19471
19474
|
}), F = X((M) => {
|
|
@@ -19540,10 +19543,10 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
19540
19543
|
x(i.appIconPickerModal.fileTooLargeError.replace("{size}", Ae));
|
|
19541
19544
|
return;
|
|
19542
19545
|
}
|
|
19543
|
-
T && URL.revokeObjectURL(T), _(q),
|
|
19546
|
+
T && URL.revokeObjectURL(T), _(q), E(URL.createObjectURL(q)), x("");
|
|
19544
19547
|
}, De = async () => {
|
|
19545
19548
|
if (C) {
|
|
19546
|
-
|
|
19549
|
+
A(!0), x("");
|
|
19547
19550
|
try {
|
|
19548
19551
|
const M = await WP(
|
|
19549
19552
|
C.name.split(".").slice(0, -1).join(".") || C.name,
|
|
@@ -19557,7 +19560,7 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
19557
19560
|
} catch (M) {
|
|
19558
19561
|
x(M instanceof Error ? M.message : i.appIconPickerModal.uploadFailedError);
|
|
19559
19562
|
} finally {
|
|
19560
|
-
|
|
19563
|
+
A(!1);
|
|
19561
19564
|
}
|
|
19562
19565
|
}
|
|
19563
19566
|
}, Se = c.length < f;
|
|
@@ -20099,9 +20102,9 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
20099
20102
|
frameworks: C,
|
|
20100
20103
|
collectionAdditionalCategories: _,
|
|
20101
20104
|
contentAdditionalCategories: T,
|
|
20102
|
-
defaultLicense:
|
|
20105
|
+
defaultLicense: E,
|
|
20103
20106
|
name: L
|
|
20104
|
-
} = kN((We = l == null ? void 0 : l.context) == null ? void 0 : We.channel),
|
|
20107
|
+
} = kN((We = l == null ? void 0 : l.context) == null ? void 0 : We.channel), A = DN(
|
|
20105
20108
|
((et = l == null ? void 0 : l.context) == null ? void 0 : et.userId) ?? ((lt = l == null ? void 0 : l.context) == null ? void 0 : lt.uid)
|
|
20106
20109
|
), R = IN(
|
|
20107
20110
|
C,
|
|
@@ -20122,10 +20125,10 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
20122
20125
|
editableFields: Q.editableFields,
|
|
20123
20126
|
objectType: Q.objectType,
|
|
20124
20127
|
setDefaultCopyRight: Q.setDefaultCopyRight === !0,
|
|
20125
|
-
defaultLicense: se.defaultLicense ??
|
|
20128
|
+
defaultLicense: se.defaultLicense ?? E,
|
|
20126
20129
|
contextAdditionalCategories: se.additionalCategories,
|
|
20127
20130
|
// Host-provided name wins; otherwise resolved from the user-read API.
|
|
20128
|
-
userFullName: ((bi = se.user) == null ? void 0 : bi.fullName) ??
|
|
20131
|
+
userFullName: ((bi = se.user) == null ? void 0 : bi.fullName) ?? A,
|
|
20129
20132
|
channelName: L,
|
|
20130
20133
|
collectionAdditionalCategories: _,
|
|
20131
20134
|
contentAdditionalCategories: T,
|
|
@@ -20224,7 +20227,7 @@ const ZP = "_overlay_1bq5u_1", XP = "_modal_1bq5u_12", JP = "_header_1bq5u_24",
|
|
|
20224
20227
|
const D = Se.getValues(w);
|
|
20225
20228
|
(D == null || D === "") && Se.setValue(w, I.currentValue, { shouldDirty: !1 });
|
|
20226
20229
|
}
|
|
20227
|
-
}, [
|
|
20230
|
+
}, [A, L, Se]);
|
|
20228
20231
|
const W = De.reduce(
|
|
20229
20232
|
(w, I) => {
|
|
20230
20233
|
const D = w[w.length - 1];
|
|
@@ -20391,7 +20394,7 @@ function lx(e) {
|
|
|
20391
20394
|
droppableRects: l,
|
|
20392
20395
|
over: c,
|
|
20393
20396
|
measureDroppableContainers: d
|
|
20394
|
-
} = Gf(), f = ao(dm, r), m = a.rect !== null, p = Te(() => n.map((
|
|
20397
|
+
} = Gf(), f = ao(dm, r), m = a.rect !== null, p = Te(() => n.map((E) => typeof E == "object" && "id" in E ? E.id : E), [n]), y = s != null, h = s ? p.indexOf(s.id) : -1, g = c ? p.indexOf(c.id) : -1, v = ie(p), b = !ix(p, v.current), C = g !== -1 && h === -1 || b, _ = ox(o);
|
|
20395
20398
|
hr(() => {
|
|
20396
20399
|
b && y && d(p);
|
|
20397
20400
|
}, [b, p, y, d]), ee(() => {
|
|
@@ -20504,9 +20507,9 @@ function mx(e) {
|
|
|
20504
20507
|
items: d
|
|
20505
20508
|
},
|
|
20506
20509
|
...i
|
|
20507
|
-
}), [f, i, _, d]),
|
|
20510
|
+
}), [f, i, _, d]), E = Te(() => d.slice(d.indexOf(s)), [d, s]), {
|
|
20508
20511
|
rect: L,
|
|
20509
|
-
node:
|
|
20512
|
+
node: A,
|
|
20510
20513
|
isOver: R,
|
|
20511
20514
|
setNodeRef: x
|
|
20512
20515
|
} = by({
|
|
@@ -20514,7 +20517,7 @@ function mx(e) {
|
|
|
20514
20517
|
data: T,
|
|
20515
20518
|
disabled: C.droppable,
|
|
20516
20519
|
resizeObserverConfig: {
|
|
20517
|
-
updateMeasurementsFor:
|
|
20520
|
+
updateMeasurementsFor: E,
|
|
20518
20521
|
...l
|
|
20519
20522
|
}
|
|
20520
20523
|
}), {
|
|
@@ -20568,7 +20571,7 @@ function mx(e) {
|
|
|
20568
20571
|
}), Oe = px({
|
|
20569
20572
|
disabled: !we,
|
|
20570
20573
|
index: _,
|
|
20571
|
-
node:
|
|
20574
|
+
node: A,
|
|
20572
20575
|
rect: L
|
|
20573
20576
|
});
|
|
20574
20577
|
return ee(() => {
|
|
@@ -20597,7 +20600,7 @@ function mx(e) {
|
|
|
20597
20600
|
isSorting: fe,
|
|
20598
20601
|
isDragging: Q,
|
|
20599
20602
|
listeners: oe,
|
|
20600
|
-
node:
|
|
20603
|
+
node: A,
|
|
20601
20604
|
overIndex: g,
|
|
20602
20605
|
over: se,
|
|
20603
20606
|
setNodeRef: be,
|
|
@@ -20682,7 +20685,7 @@ const vx = [Be.Down, Be.Right, Be.Up, Be.Left], yx = (e, t) => {
|
|
|
20682
20685
|
if (d === (s == null ? void 0 : s.id) && c.length > 1 && (d = c[1].id), d != null) {
|
|
20683
20686
|
const f = o.get(r.id), m = o.get(d), p = m ? i.get(m.id) : null, y = m == null ? void 0 : m.node.current;
|
|
20684
20687
|
if (y && p && f && m) {
|
|
20685
|
-
const g = Es(y).some((
|
|
20688
|
+
const g = Es(y).some((E, L) => a[L] !== E), v = hm(f, m), b = bx(f, m), C = g || !v ? {
|
|
20686
20689
|
x: 0,
|
|
20687
20690
|
y: 0
|
|
20688
20691
|
} : {
|
|
@@ -20983,7 +20986,7 @@ const Cx = "_row_1m6cn_1", _x = "_removeBtn_1m6cn_14", wx = "_grip_1m6cn_17", Sx
|
|
|
20983
20986
|
}
|
|
20984
20987
|
);
|
|
20985
20988
|
}, CF = ({ editorMode: e, isRoot: t = !1 }) => {
|
|
20986
|
-
const r = ue(), { selectedNodeId: n, getChildrenOf: i, getNodeById: o, reorderChildren: s, deleteNode: a, activeNodeMeta: l, updateNode: c, treeData: d } = ae(), f = X((F) => F.editorProfile), m = n ? i(n) : [], p = e === "edit", y = n ? o(n) : void 0, h = f.competencyScoped, g = h && !t && !mt(y), v = h && t, { scope: b, source: C } = go(), _ = gr(), T = _ && Array.isArray(l[_.code]) ? l[_.code] : [],
|
|
20989
|
+
const r = ue(), { selectedNodeId: n, getChildrenOf: i, getNodeById: o, reorderChildren: s, deleteNode: a, activeNodeMeta: l, updateNode: c, treeData: d } = ae(), f = X((F) => F.editorProfile), m = n ? i(n) : [], p = e === "edit", y = n ? o(n) : void 0, h = f.competencyScoped, g = h && !t && !mt(y), v = h && t, { scope: b, source: C } = go(), _ = gr(), T = _ && Array.isArray(l[_.code]) ? l[_.code] : [], E = C === "prior" ? T.filter((F) => !b.includes(F)) : [], L = v ? qh(d[0], _ == null ? void 0 : _.code) : [], A = g ? $h(y, T, _ == null ? void 0 : _.code) : [], R = Z((F) => {
|
|
20987
20990
|
!n || !(_ != null && _.code) || c(n, { [_.code]: F }, [_.code]);
|
|
20988
20991
|
}, [n, _ == null ? void 0 : _.code, c]), x = If(
|
|
20989
20992
|
// distance:5 prevents conflict with outer DnD context (distance:8) while still feeling responsive
|
|
@@ -21019,8 +21022,8 @@ const Cx = "_row_1m6cn_1", _x = "_removeBtn_1m6cn_14", wx = "_grip_1m6cn_17", Sx
|
|
|
21019
21022
|
{
|
|
21020
21023
|
options: b,
|
|
21021
21024
|
selected: T,
|
|
21022
|
-
outOfScope:
|
|
21023
|
-
uncovered:
|
|
21025
|
+
outOfScope: E,
|
|
21026
|
+
uncovered: A,
|
|
21024
21027
|
onChange: R,
|
|
21025
21028
|
isEditable: p,
|
|
21026
21029
|
description: C === "prior" ? r.learningPath.skillScopeFromPriorNote : r.learningPath.skillScopeManualNote
|
|
@@ -21770,7 +21773,7 @@ const H2 = ({ onClose: e }) => {
|
|
|
21770
21773
|
h.name ?? e.name ?? ""
|
|
21771
21774
|
), [b, C] = j(""), [_, T] = j(
|
|
21772
21775
|
Array.isArray(h.keywords) ? h.keywords : Array.isArray((F = e.metadata) == null ? void 0 : F.keywords) ? e.metadata.keywords : []
|
|
21773
|
-
), [
|
|
21776
|
+
), [E, L] = j(
|
|
21774
21777
|
!!h.optional
|
|
21775
21778
|
);
|
|
21776
21779
|
ee(() => {
|
|
@@ -21780,7 +21783,7 @@ const H2 = ({ onClose: e }) => {
|
|
|
21780
21783
|
Array.isArray(B.keywords) ? B.keywords : Array.isArray((oe = e.metadata) == null ? void 0 : oe.keywords) ? e.metadata.keywords : []
|
|
21781
21784
|
), L(!!B.optional);
|
|
21782
21785
|
}, [e.id]);
|
|
21783
|
-
const
|
|
21786
|
+
const A = () => {
|
|
21784
21787
|
g.trim() && g !== e.name && (i(e.id, { name: g.trim() }), o());
|
|
21785
21788
|
}, R = () => {
|
|
21786
21789
|
const B = b.trim();
|
|
@@ -21825,7 +21828,7 @@ const H2 = ({ onClose: e }) => {
|
|
|
21825
21828
|
value: g,
|
|
21826
21829
|
disabled: !s,
|
|
21827
21830
|
onChange: (B) => v(B.target.value),
|
|
21828
|
-
onBlur:
|
|
21831
|
+
onBlur: A,
|
|
21829
21832
|
placeholder: l.contentEditForm.contentNamePlaceholder
|
|
21830
21833
|
}
|
|
21831
21834
|
)
|
|
@@ -21865,7 +21868,7 @@ const H2 = ({ onClose: e }) => {
|
|
|
21865
21868
|
{
|
|
21866
21869
|
type: "radio",
|
|
21867
21870
|
name: `optional-${e.id}`,
|
|
21868
|
-
checked:
|
|
21871
|
+
checked: E === !0,
|
|
21869
21872
|
onChange: () => N(!0),
|
|
21870
21873
|
disabled: !s
|
|
21871
21874
|
}
|
|
@@ -21878,7 +21881,7 @@ const H2 = ({ onClose: e }) => {
|
|
|
21878
21881
|
{
|
|
21879
21882
|
type: "radio",
|
|
21880
21883
|
name: `optional-${e.id}`,
|
|
21881
|
-
checked:
|
|
21884
|
+
checked: E === !1,
|
|
21882
21885
|
onChange: () => N(!1),
|
|
21883
21886
|
disabled: !s
|
|
21884
21887
|
}
|
|
@@ -21989,10 +21992,10 @@ const ym = ({ courseId: e, variant: t = "compact", title: r, onLoaded: n }) => {
|
|
|
21989
21992
|
let b = !1;
|
|
21990
21993
|
return a(null), c(""), f(null), Ph(e).then((C) => {
|
|
21991
21994
|
if (b) return;
|
|
21992
|
-
const T = (C.children ?? []).map((
|
|
21993
|
-
a(T), c(C.description ?? ""), p(Object.fromEntries(T.map((
|
|
21994
|
-
var
|
|
21995
|
-
return
|
|
21995
|
+
const T = (C.children ?? []).map((E) => qs(E));
|
|
21996
|
+
a(T), c(C.description ?? ""), p(Object.fromEntries(T.map((E) => [E.id, !0]))), n == null || n({ totalContents: T.reduce((E, L) => {
|
|
21997
|
+
var A;
|
|
21998
|
+
return E + (((A = L.children) == null ? void 0 : A.length) ?? 0);
|
|
21996
21999
|
}, 0) });
|
|
21997
22000
|
}).catch(() => {
|
|
21998
22001
|
b || f(i.learningPath.courseDetailsError);
|
|
@@ -22020,8 +22023,8 @@ const ym = ({ courseId: e, variant: t = "compact", title: r, onLoaded: n }) => {
|
|
|
22020
22023
|
/* @__PURE__ */ u("span", { className: qe.unitsLabel, children: i.learningPath.unitsSectionLabel }),
|
|
22021
22024
|
y && /* @__PURE__ */ u("p", { className: qe.unitsDescription, children: i.learningPath.unitsSectionDescription }),
|
|
22022
22025
|
/* @__PURE__ */ u("div", { className: qe.unitList, children: s.map((b) => {
|
|
22023
|
-
var L,
|
|
22024
|
-
const C = !!m[b.id], _ = (b.children ?? []).length, T = Da((L = b.metadata) == null ? void 0 : L.keywords),
|
|
22026
|
+
var L, A;
|
|
22027
|
+
const C = !!m[b.id], _ = (b.children ?? []).length, T = Da((L = b.metadata) == null ? void 0 : L.keywords), E = Da((A = b.metadata) == null ? void 0 : A.topic);
|
|
22025
22028
|
return /* @__PURE__ */ S("div", { className: qe.unitCard, children: [
|
|
22026
22029
|
/* @__PURE__ */ S(
|
|
22027
22030
|
"button",
|
|
@@ -22041,9 +22044,9 @@ const ym = ({ courseId: e, variant: t = "compact", title: r, onLoaded: n }) => {
|
|
|
22041
22044
|
C && /* @__PURE__ */ S("div", { className: qe.unitBody, children: [
|
|
22042
22045
|
y && b.description && /* @__PURE__ */ u("p", { className: qe.unitDescription, children: b.description }),
|
|
22043
22046
|
y && T.length > 0 && /* @__PURE__ */ u("div", { className: qe.unitKeywords, children: T.map((R) => /* @__PURE__ */ u("span", { className: qe.keywordPill, children: R }, R)) }),
|
|
22044
|
-
y &&
|
|
22047
|
+
y && E.length > 0 && /* @__PURE__ */ S("div", { className: qe.unitTopicsRow, children: [
|
|
22045
22048
|
/* @__PURE__ */ u("span", { className: qe.fieldLabel, children: i.learningPath.unitTopicsFieldLabel }),
|
|
22046
|
-
/* @__PURE__ */ u("span", { children:
|
|
22049
|
+
/* @__PURE__ */ u("span", { children: E.join(", ") })
|
|
22047
22050
|
] }),
|
|
22048
22051
|
/* @__PURE__ */ u("div", { className: qe.unitContents, children: (b.children ?? []).map((R) => {
|
|
22049
22052
|
const x = vo(R), N = KM[x.key] ?? tn, P = g(R);
|
|
@@ -22156,16 +22159,16 @@ function ju(e) {
|
|
|
22156
22159
|
}
|
|
22157
22160
|
const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
22158
22161
|
var ve, be, fe, De, Se;
|
|
22159
|
-
const r = ue(), [n, i] = j("details"), [o, s] = j([]), [a, l] = j(null), [c, d] = j(!1), [f, m] = j(null), p = ie(null), y = ie(), { selectedNodeId: h, breadcrumb: g, activeNodeMeta: v, updateNode: b, treeData: C, selectNode: _ } = ae(), T = Er((M) => M.activeAssessmentSlot),
|
|
22162
|
+
const r = ue(), [n, i] = j("details"), [o, s] = j([]), [a, l] = j(null), [c, d] = j(!1), [f, m] = j(null), p = ie(null), y = ie(), { selectedNodeId: h, breadcrumb: g, activeNodeMeta: v, updateNode: b, treeData: C, selectNode: _ } = ae(), T = Er((M) => M.activeAssessmentSlot), E = X(
|
|
22160
22163
|
(M) => {
|
|
22161
22164
|
var q, te, ye, Ae;
|
|
22162
22165
|
return ((te = (q = M.editorConfig) == null ? void 0 : q.context) == null ? void 0 : te.contentId) ?? ((Ae = (ye = M.editorConfig) == null ? void 0 : ye.context) == null ? void 0 : Ae.identifier) ?? "";
|
|
22163
22166
|
}
|
|
22164
|
-
), L = X((M) => M.editorProfile.competencyScoped),
|
|
22167
|
+
), L = X((M) => M.editorProfile.competencyScoped), A = h ? Cm(C, h) : null;
|
|
22165
22168
|
ee(() => {
|
|
22166
22169
|
m(null);
|
|
22167
|
-
}, [
|
|
22168
|
-
const R = !!
|
|
22170
|
+
}, [A == null ? void 0 : A.identifier]);
|
|
22171
|
+
const R = !!A && !A.parent, x = !!(A != null && A.isFolder), N = A && OB.includes(A.mimeType ?? ""), P = (A == null ? void 0 : A.mimeType) === bm, F = A && !A.isFolder && !N && !R, U = L && x && mt(A ?? void 0) ? ((fe = (be = (ve = C[0]) == null ? void 0 : ve.children) == null ? void 0 : be[0]) == null ? void 0 : fe.id) === (A == null ? void 0 : A.id) ? "pre" : "post" : L ? T : null, oe = ju(A) ?? (R ? ju(C[0]) : void 0), Q = Z(() => {
|
|
22169
22172
|
const M = p.current;
|
|
22170
22173
|
if (!M || !h) return;
|
|
22171
22174
|
const q = M.innerText.trim();
|
|
@@ -22177,27 +22180,27 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22177
22180
|
}, [t]), ge = Z((M, q) => {
|
|
22178
22181
|
s(q), t({ action: "onFormStatusChange", data: { isValid: M, nodeId: h } });
|
|
22179
22182
|
}, [t, h]);
|
|
22180
|
-
if (!
|
|
22183
|
+
if (!A)
|
|
22181
22184
|
return /* @__PURE__ */ u("div", { className: Re.emptyState, children: /* @__PURE__ */ u("p", { children: r.contextualEditor.emptyStateMessage }) });
|
|
22182
22185
|
if (N)
|
|
22183
22186
|
return /* @__PURE__ */ u(
|
|
22184
22187
|
El,
|
|
22185
22188
|
{
|
|
22186
|
-
node:
|
|
22189
|
+
node: A,
|
|
22187
22190
|
editorMode: e,
|
|
22188
22191
|
type: "quml",
|
|
22189
22192
|
singleQuestion: P
|
|
22190
22193
|
}
|
|
22191
22194
|
);
|
|
22192
|
-
if (L && F &&
|
|
22193
|
-
const M =
|
|
22195
|
+
if (L && F && A.primaryCategory === "Course") {
|
|
22196
|
+
const M = A.parent ? DT(((De = C[0]) == null ? void 0 : De.children) ?? [], A.parent) : null, q = (M == null ? void 0 : M.role) === "pre" ? r.learningPath.priorAssessmentLabel : (M == null ? void 0 : M.role) === "post" ? r.learningPath.outcomeAssessmentLabel : (M == null ? void 0 : M.role) === "level" ? r.learningPath.levelNumberPrefix.replace("{n}", String(M.levelNumber)) : null, te = f === null ? "" : ` · ${(f === 1 ? r.learningPath.contentCountLabel : r.learningPath.contentCountLabelPlural).replace("{count}", String(f))}`;
|
|
22194
22197
|
return /* @__PURE__ */ S("div", { className: Re.container, children: [
|
|
22195
22198
|
/* @__PURE__ */ S(
|
|
22196
22199
|
"button",
|
|
22197
22200
|
{
|
|
22198
22201
|
type: "button",
|
|
22199
22202
|
className: Re.backToPathButton,
|
|
22200
|
-
onClick: () =>
|
|
22203
|
+
onClick: () => A.parent && _(A.parent),
|
|
22201
22204
|
children: [
|
|
22202
22205
|
/* @__PURE__ */ u(Ml, { size: 14 }),
|
|
22203
22206
|
q ? r.learningPath.backToLevelButton.replace("{label}", q) : r.learningPath.backToPathButton
|
|
@@ -22207,9 +22210,9 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22207
22210
|
/* @__PURE__ */ S("div", { className: Re.courseDetailHeader, children: [
|
|
22208
22211
|
/* @__PURE__ */ u("span", { className: Re.courseDetailIcon, children: /* @__PURE__ */ u(en, { size: 26 }) }),
|
|
22209
22212
|
/* @__PURE__ */ S("div", { children: [
|
|
22210
|
-
/* @__PURE__ */ u("h2", { className: Re.courseDetailTitle, children:
|
|
22213
|
+
/* @__PURE__ */ u("h2", { className: Re.courseDetailTitle, children: A.name }),
|
|
22211
22214
|
/* @__PURE__ */ S("span", { className: Re.courseDetailMeta, children: [
|
|
22212
|
-
|
|
22215
|
+
A.primaryCategory,
|
|
22213
22216
|
te
|
|
22214
22217
|
] })
|
|
22215
22218
|
] })
|
|
@@ -22217,29 +22220,29 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22217
22220
|
/* @__PURE__ */ u(
|
|
22218
22221
|
ym,
|
|
22219
22222
|
{
|
|
22220
|
-
courseId:
|
|
22223
|
+
courseId: A.identifier,
|
|
22221
22224
|
variant: "full",
|
|
22222
|
-
title:
|
|
22225
|
+
title: A.name,
|
|
22223
22226
|
onLoaded: ({ totalContents: ye }) => m(ye)
|
|
22224
22227
|
},
|
|
22225
|
-
|
|
22228
|
+
A.identifier
|
|
22226
22229
|
)
|
|
22227
22230
|
] });
|
|
22228
22231
|
}
|
|
22229
22232
|
return U ? /* @__PURE__ */ u(DB, { slot: U, isEditable: e === "edit" }) : F ? /* @__PURE__ */ S("div", { className: Re.leafContentLayout, children: [
|
|
22230
|
-
/* @__PURE__ */ u(El, { node:
|
|
22233
|
+
/* @__PURE__ */ u(El, { node: A, editorMode: e, type: "content", layout: "flow" }),
|
|
22231
22234
|
/* @__PURE__ */ u(
|
|
22232
22235
|
fM,
|
|
22233
22236
|
{
|
|
22234
|
-
node:
|
|
22237
|
+
node: A,
|
|
22235
22238
|
editorMode: e,
|
|
22236
|
-
onMoveClick: () => l(
|
|
22239
|
+
onMoveClick: () => l(A.identifier),
|
|
22237
22240
|
reorderDialog: a ? /* @__PURE__ */ u(
|
|
22238
22241
|
P2,
|
|
22239
22242
|
{
|
|
22240
22243
|
resourceId: a,
|
|
22241
|
-
resourceName:
|
|
22242
|
-
currentUnitId:
|
|
22244
|
+
resourceName: A.name,
|
|
22245
|
+
currentUnitId: A.parent ?? "",
|
|
22243
22246
|
onClose: () => l(null)
|
|
22244
22247
|
}
|
|
22245
22248
|
) : null
|
|
@@ -22256,7 +22259,7 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22256
22259
|
yM,
|
|
22257
22260
|
{
|
|
22258
22261
|
nodeId: h,
|
|
22259
|
-
value: String(
|
|
22262
|
+
value: String(A.appIcon ?? ((Se = A.metadata) == null ? void 0 : Se.appIcon) ?? ""),
|
|
22260
22263
|
editable: e === "edit"
|
|
22261
22264
|
}
|
|
22262
22265
|
),
|
|
@@ -22275,7 +22278,7 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22275
22278
|
onBlur: Q,
|
|
22276
22279
|
"data-placeholder": r.contextualEditor.untitledPlaceholder,
|
|
22277
22280
|
"aria-label": r.contextualEditor.nodeTitleAriaLabel,
|
|
22278
|
-
children:
|
|
22281
|
+
children: A.name
|
|
22279
22282
|
}
|
|
22280
22283
|
)
|
|
22281
22284
|
] }),
|
|
@@ -22311,7 +22314,7 @@ const NB = ({ editorMode: e, onToolbarEvent: t }) => {
|
|
|
22311
22314
|
className: Re.dropZone
|
|
22312
22315
|
}
|
|
22313
22316
|
),
|
|
22314
|
-
c && /* @__PURE__ */ u(H2, { contentId:
|
|
22317
|
+
c && /* @__PURE__ */ u(H2, { contentId: E, onClose: () => d(!1) })
|
|
22315
22318
|
] });
|
|
22316
22319
|
};
|
|
22317
22320
|
function Cm(e, t) {
|
|
@@ -22404,17 +22407,17 @@ function _m() {
|
|
|
22404
22407
|
return l != null && l.length ? l : [...bu];
|
|
22405
22408
|
}
|
|
22406
22409
|
function qB() {
|
|
22407
|
-
const e = PB(), t = X((
|
|
22410
|
+
const e = PB(), t = X((A) => {
|
|
22408
22411
|
var R, x;
|
|
22409
|
-
return ((x = (R =
|
|
22410
|
-
}), r = _m(), n = X((
|
|
22412
|
+
return ((x = (R = A.editorConfig) == null ? void 0 : R.context) == null ? void 0 : x.channel) ?? "";
|
|
22413
|
+
}), r = _m(), n = X((A) => A.editorProfile), i = Er((A) => A.activeAssessmentSlot), o = ae((A) => A.activeNodeMeta), s = ae((A) => A.treeData), a = ae((A) => A.treeCache), l = ae((A) => A.selectedNodeId), c = ae((A) => A.getNodeById), d = gr(), f = n.competencyScoped ? Mh(s[0], a) : void 0, m = ie(), p = d && Array.isArray(o[d.code]) ? o[d.code] : BB, y = l ? c(l) : void 0, h = n.competencyScoped && !!(y != null && y.isFolder) && !!y.parent && !mt(y), g = FB(
|
|
22411
22414
|
n.competencyScoped,
|
|
22412
22415
|
f,
|
|
22413
22416
|
h,
|
|
22414
22417
|
i,
|
|
22415
22418
|
p
|
|
22416
22419
|
), v = Z(
|
|
22417
|
-
async (
|
|
22420
|
+
async (A = "", R = "all", x = {}, N = !0, P = !1) => {
|
|
22418
22421
|
var F, B, U, oe, Q;
|
|
22419
22422
|
e.setLoading(!0);
|
|
22420
22423
|
try {
|
|
@@ -22433,8 +22436,8 @@ function qB() {
|
|
|
22433
22436
|
}, (F = x == null ? void 0 : x.board) != null && F.length && (se.board = x.board), (B = x == null ? void 0 : x.medium) != null && B.length && (se.medium = x.medium), (U = x == null ? void 0 : x.gradeLevel) != null && U.length && (se.gradeLevel = x.gradeLevel), (oe = x == null ? void 0 : x.subject) != null && oe.length && (se.subject = x.subject), (Q = x == null ? void 0 : x.primaryCategory) != null && Q.length && (se.primaryCategory = x.primaryCategory);
|
|
22434
22437
|
const ge = N ? 0 : e.offset, { content: ve, count: be } = await TF({
|
|
22435
22438
|
filters: se,
|
|
22436
|
-
query:
|
|
22437
|
-
limit:
|
|
22439
|
+
query: A,
|
|
22440
|
+
limit: A ? 50 : MB,
|
|
22438
22441
|
offset: ge,
|
|
22439
22442
|
channel: t || void 0,
|
|
22440
22443
|
sortBy: P ? { name: "asc" } : { lastUpdatedOn: "desc" },
|
|
@@ -22458,30 +22461,30 @@ function qB() {
|
|
|
22458
22461
|
n.competencyScoped && v();
|
|
22459
22462
|
}, [n.competencyScoped, i, p.join("|"), f, l]);
|
|
22460
22463
|
const b = Z(
|
|
22461
|
-
(
|
|
22462
|
-
e.setSearch(
|
|
22463
|
-
() => v(
|
|
22464
|
+
(A) => {
|
|
22465
|
+
e.setSearch(A), clearTimeout(m.current), m.current = setTimeout(
|
|
22466
|
+
() => v(A, e.activeFilter, e.advancedFilters, !0, e.sortAZ),
|
|
22464
22467
|
300
|
|
22465
22468
|
);
|
|
22466
22469
|
},
|
|
22467
22470
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
22468
22471
|
[e.activeFilter, e.advancedFilters, e.sortAZ, v]
|
|
22469
22472
|
), C = Z(
|
|
22470
|
-
(
|
|
22471
|
-
e.setFilter(
|
|
22473
|
+
(A) => {
|
|
22474
|
+
e.setFilter(A), v(e.searchQuery, A, e.advancedFilters, !0, e.sortAZ);
|
|
22472
22475
|
},
|
|
22473
22476
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
22474
22477
|
[e.searchQuery, e.advancedFilters, e.sortAZ, v]
|
|
22475
22478
|
), _ = Z(
|
|
22476
|
-
(
|
|
22477
|
-
e.setAdvancedFilters(
|
|
22479
|
+
(A) => {
|
|
22480
|
+
e.setAdvancedFilters(A), v(e.searchQuery, e.activeFilter, A, !0, e.sortAZ);
|
|
22478
22481
|
},
|
|
22479
22482
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
22480
22483
|
[e.searchQuery, e.activeFilter, e.sortAZ, v]
|
|
22481
22484
|
), T = Z(() => {
|
|
22482
|
-
const
|
|
22483
|
-
e.setSortAZ(
|
|
22484
|
-
}, [e.sortAZ, e.searchQuery, e.activeFilter, e.advancedFilters, v]),
|
|
22485
|
+
const A = !e.sortAZ;
|
|
22486
|
+
e.setSortAZ(A), v(e.searchQuery, e.activeFilter, e.advancedFilters, !0, A);
|
|
22487
|
+
}, [e.sortAZ, e.searchQuery, e.activeFilter, e.advancedFilters, v]), E = Z(() => {
|
|
22485
22488
|
e.isLoading || v(e.searchQuery, e.activeFilter, e.advancedFilters, !1, e.sortAZ);
|
|
22486
22489
|
}, [e.isLoading, e.searchQuery, e.activeFilter, e.advancedFilters, e.sortAZ, v]), L = e.allContent.length < e.totalCount;
|
|
22487
22490
|
return {
|
|
@@ -22497,7 +22500,7 @@ function qB() {
|
|
|
22497
22500
|
setFilter: C,
|
|
22498
22501
|
applyAdvancedFilters: _,
|
|
22499
22502
|
toggleSort: T,
|
|
22500
|
-
loadMore:
|
|
22503
|
+
loadMore: E,
|
|
22501
22504
|
refetch: () => v(e.searchQuery, e.activeFilter, e.advancedFilters, !0, e.sortAZ),
|
|
22502
22505
|
// LP profile only — drives the dock's "filling the Prior/Outcome
|
|
22503
22506
|
// Assessment slot" banner.
|
|
@@ -22673,8 +22676,8 @@ const $B = "_card_1cmpg_1", jB = "_addBtn_1cmpg_17", UB = "_dragging_1cmpg_24",
|
|
|
22673
22676
|
}, [t]);
|
|
22674
22677
|
const p = (b, C) => {
|
|
22675
22678
|
f((_) => {
|
|
22676
|
-
const T = _[b] ?? [],
|
|
22677
|
-
return { ..._, [b]:
|
|
22679
|
+
const T = _[b] ?? [], E = T.includes(C) ? T.filter((L) => L !== C) : [...T, C];
|
|
22680
|
+
return { ..._, [b]: E };
|
|
22678
22681
|
});
|
|
22679
22682
|
}, y = (c == null ? void 0 : c.categories) ?? [], h = (b) => {
|
|
22680
22683
|
var C;
|
|
@@ -22902,7 +22905,7 @@ const f$ = ({ editorMode: e, collapsed: t = !1, onToggleCollapse: r }) => {
|
|
|
22902
22905
|
loadMore: h,
|
|
22903
22906
|
activeAssessmentSlot: g,
|
|
22904
22907
|
emptyReason: v
|
|
22905
|
-
} = qB(), { addResource: b, selectedNodeId: C, treeData: _, treeCache: T } = ae(),
|
|
22908
|
+
} = qB(), { addResource: b, selectedNodeId: C, treeData: _, treeCache: T } = ae(), E = Er((M) => M.setActiveAssessmentSlot), L = X((M) => M.editorProfile.competencyScoped), A = e === "edit", R = wm(), [x, N] = j(!1), [P, F] = j({}), [B, U] = j(null), [oe, Q] = j(null), se = Te(() => u$(_), [_]), ge = Z(
|
|
22906
22909
|
async (M, q) => {
|
|
22907
22910
|
var ye, Ae;
|
|
22908
22911
|
const te = (ye = _[0]) == null ? void 0 : ye.id;
|
|
@@ -22923,7 +22926,7 @@ const f$ = ({ editorMode: e, collapsed: t = !1, onToggleCollapse: r }) => {
|
|
|
22923
22926
|
Ie.error(n.learningPath.bothSlotsFilledToast);
|
|
22924
22927
|
return;
|
|
22925
22928
|
}
|
|
22926
|
-
Ie.success(n.libraryDock.itemAddedToast.replace("{name}", M.name)),
|
|
22929
|
+
Ie.success(n.libraryDock.itemAddedToast.replace("{name}", M.name)), E(null);
|
|
22927
22930
|
} catch (Ce) {
|
|
22928
22931
|
console.error("[LibraryDock] assessment-course check failed:", Ce), Ie.error(n.learningPath.assessmentCheckFailedToast);
|
|
22929
22932
|
} finally {
|
|
@@ -22931,7 +22934,7 @@ const f$ = ({ editorMode: e, collapsed: t = !1, onToggleCollapse: r }) => {
|
|
|
22931
22934
|
}
|
|
22932
22935
|
}
|
|
22933
22936
|
},
|
|
22934
|
-
[_, b,
|
|
22937
|
+
[_, b, E, oe, n]
|
|
22935
22938
|
), ve = Z(
|
|
22936
22939
|
(M) => {
|
|
22937
22940
|
var Ae, Ce, he;
|
|
@@ -23079,7 +23082,7 @@ const f$ = ({ editorMode: e, collapsed: t = !1, onToggleCollapse: r }) => {
|
|
|
23079
23082
|
item: M,
|
|
23080
23083
|
onAdd: ve,
|
|
23081
23084
|
onPreview: fe,
|
|
23082
|
-
isDraggable:
|
|
23085
|
+
isDraggable: A,
|
|
23083
23086
|
isAdded: se.has(M.identifier)
|
|
23084
23087
|
},
|
|
23085
23088
|
M.identifier
|
|
@@ -23174,6 +23177,9 @@ function h$(e, t, r, n = jl) {
|
|
|
23174
23177
|
"targetMediumIds",
|
|
23175
23178
|
"targetGradeLevelIds",
|
|
23176
23179
|
"targetSubjectIds",
|
|
23180
|
+
// Org-framework fields — new framework category codes
|
|
23181
|
+
"industry",
|
|
23182
|
+
"domain",
|
|
23177
23183
|
// Dial codes
|
|
23178
23184
|
"dialcodes"
|
|
23179
23185
|
]), c = /* @__PURE__ */ new Set(["copyrightYear", "compatibilityLevel", "version"]);
|
|
@@ -23213,9 +23219,9 @@ function h$(e, t, r, n = jl) {
|
|
|
23213
23219
|
var _, T;
|
|
23214
23220
|
const h = p.identifier, g = t[h], v = h.startsWith("temp-") || !!(g != null && g.isNew), b = !p.isFolder && !y;
|
|
23215
23221
|
if (y || v || g && !b) {
|
|
23216
|
-
let
|
|
23222
|
+
let E;
|
|
23217
23223
|
if (v)
|
|
23218
|
-
|
|
23224
|
+
E = {
|
|
23219
23225
|
mimeType: "application/vnd.ekstep.content-collection",
|
|
23220
23226
|
code: h,
|
|
23221
23227
|
contentType: ((_ = p.metadata) == null ? void 0 : _.contentType) ?? n.unitContentType,
|
|
@@ -23226,22 +23232,22 @@ function h$(e, t, r, n = jl) {
|
|
|
23226
23232
|
...d(p.metadata ?? {})
|
|
23227
23233
|
};
|
|
23228
23234
|
else if (y) {
|
|
23229
|
-
const { isNew: L, ...
|
|
23230
|
-
|
|
23235
|
+
const { isNew: L, ...A } = g ?? {};
|
|
23236
|
+
E = {
|
|
23231
23237
|
...d(p.metadata ?? {}, !0),
|
|
23232
|
-
...d(
|
|
23238
|
+
...d(A, !1),
|
|
23233
23239
|
name: p.name
|
|
23234
23240
|
};
|
|
23235
23241
|
} else {
|
|
23236
|
-
const { isNew: L, ...
|
|
23237
|
-
|
|
23242
|
+
const { isNew: L, ...A } = g ?? {};
|
|
23243
|
+
E = {
|
|
23238
23244
|
name: p.name,
|
|
23239
23245
|
visibility: "Parent",
|
|
23240
|
-
...d(
|
|
23246
|
+
...d(A, !0)
|
|
23241
23247
|
};
|
|
23242
23248
|
}
|
|
23243
23249
|
i[h] = {
|
|
23244
|
-
metadata:
|
|
23250
|
+
metadata: E,
|
|
23245
23251
|
objectType: p.objectType || (p.isFolder ? "Collection" : "Content"),
|
|
23246
23252
|
root: y,
|
|
23247
23253
|
isNew: v
|
|
@@ -23250,10 +23256,10 @@ function h$(e, t, r, n = jl) {
|
|
|
23250
23256
|
const C = p.isFolder ? f(p) : {};
|
|
23251
23257
|
o[h] = {
|
|
23252
23258
|
name: p.name,
|
|
23253
|
-
children: (p.children ?? []).map((
|
|
23259
|
+
children: (p.children ?? []).map((E) => E.identifier),
|
|
23254
23260
|
...Object.keys(C).length > 0 ? { relationalMetadata: C } : {},
|
|
23255
23261
|
root: y
|
|
23256
|
-
}, (p.children ?? []).forEach((
|
|
23262
|
+
}, (p.children ?? []).forEach((E) => m(E, !1));
|
|
23257
23263
|
}
|
|
23258
23264
|
return e.forEach((p, y) => m(p, y === 0)), { nodesModified: i, hierarchy: o };
|
|
23259
23265
|
}
|
|
@@ -23326,7 +23332,7 @@ function y$(e) {
|
|
|
23326
23332
|
editorMode: "edit",
|
|
23327
23333
|
objectType: (R = t == null ? void 0 : t.config) == null ? void 0 : R.objectType,
|
|
23328
23334
|
userFullName: (N = (x = t == null ? void 0 : t.context) == null ? void 0 : x.user) == null ? void 0 : N.fullName
|
|
23329
|
-
},
|
|
23335
|
+
}, E = v$(
|
|
23330
23336
|
a,
|
|
23331
23337
|
l,
|
|
23332
23338
|
o,
|
|
@@ -23334,36 +23340,36 @@ function y$(e) {
|
|
|
23334
23340
|
T,
|
|
23335
23341
|
{ organisationFramework: y, targetFrameworks: h }
|
|
23336
23342
|
);
|
|
23337
|
-
if (
|
|
23338
|
-
const L =
|
|
23343
|
+
if (E.length === 0) return !0;
|
|
23344
|
+
const L = E[0];
|
|
23339
23345
|
Ie.error(
|
|
23340
23346
|
`"${L.nodeName}": please fill required field${L.missing.length > 1 ? "s" : ""} — ${L.missing.join(", ")}`
|
|
23341
23347
|
);
|
|
23342
|
-
const { setFormStatus:
|
|
23343
|
-
return
|
|
23348
|
+
const { setFormStatus: A } = X.getState();
|
|
23349
|
+
return E.forEach((P) => A(P.nodeId, !1)), c(L.nodeId), !1;
|
|
23344
23350
|
}, [a, l, o, s, t, c, y, h]), v = Z(() => {
|
|
23345
23351
|
if (r.key !== "learningPath") return !0;
|
|
23346
23352
|
const T = Yl(a[0], d == null ? void 0 : d.code, f, l);
|
|
23347
23353
|
return T.length === 0 ? !0 : (Ie.error(T[0].message), !1);
|
|
23348
23354
|
}, [r.key, a, l, d, f]);
|
|
23349
23355
|
return { runAction: Z(
|
|
23350
|
-
async (T,
|
|
23356
|
+
async (T, E) => {
|
|
23351
23357
|
var R, x, N, P;
|
|
23352
23358
|
const L = ((R = t == null ? void 0 : t.context) == null ? void 0 : R.contentId) ?? ((x = t == null ? void 0 : t.context) == null ? void 0 : x.identifier) ?? "";
|
|
23353
23359
|
if (!L)
|
|
23354
23360
|
return Ie.error("No content identifier found."), !1;
|
|
23355
|
-
const
|
|
23361
|
+
const A = ((N = t == null ? void 0 : t.context) == null ? void 0 : N.userId) ?? ((P = t == null ? void 0 : t.context) == null ? void 0 : P.uid) ?? "";
|
|
23356
23362
|
try {
|
|
23357
23363
|
switch (T) {
|
|
23358
23364
|
case "sendForReview":
|
|
23359
23365
|
return g() ? i(a) ? v() ? (n("saveCollection", !0), await e(), await ST(L), Ie.success("Content sent for review"), !0) : !1 : (Ie.error("Some units have missing required fields. Please fill them before sending for review."), !1) : !1;
|
|
23360
23366
|
case "reject": {
|
|
23361
23367
|
n("rejectCollection", !0);
|
|
23362
|
-
const F = (
|
|
23368
|
+
const F = (E == null ? void 0 : E.comment) ?? "";
|
|
23363
23369
|
return await TT(L, F), Ie.success("Content rejected and sent back to the author"), !0;
|
|
23364
23370
|
}
|
|
23365
23371
|
case "publish":
|
|
23366
|
-
return g() ? i(a) ? v() ? (n("publishCollection", !0), await e(), await _T(L,
|
|
23372
|
+
return g() ? i(a) ? v() ? (n("publishCollection", !0), await e(), await _T(L, A), Ie.success("Content published successfully"), !0) : !1 : (Ie.error("Some units have missing required fields. Please fill them before publishing."), !1) : !1;
|
|
23367
23373
|
default:
|
|
23368
23374
|
return !1;
|
|
23369
23375
|
}
|
|
@@ -23417,7 +23423,7 @@ const _$ = "_shell_fu72l_1", w$ = "_workspace_fu72l_8", S$ = "_sidebarCollapsed_
|
|
|
23417
23423
|
}) => {
|
|
23418
23424
|
const i = ue(), [o, s] = j(null), [a, l] = j(!1), [c, d] = j(!1), [f, m] = j(!1);
|
|
23419
23425
|
b$(), C$();
|
|
23420
|
-
const { addResource: p, treeData: y, treeCache: h } = ae(), g = X((Q) => Q.setFormStatus), v = X((Q) => Q.editorProfile.key === "learningPath"), [b, C] = j(!0), _ = ae((Q) => Q.selectedNodeId), { save: T, isSaving:
|
|
23426
|
+
const { addResource: p, treeData: y, treeCache: h } = ae(), g = X((Q) => Q.setFormStatus), v = X((Q) => Q.editorProfile.key === "learningPath"), [b, C] = j(!0), _ = ae((Q) => Q.selectedNodeId), { save: T, isSaving: E, isDirty: L, lastSaved: A } = p$(), { runAction: R, checkRequiredFields: x } = y$(T);
|
|
23421
23427
|
ee(() => {
|
|
23422
23428
|
if (!L) return;
|
|
23423
23429
|
const Q = (se) => {
|
|
@@ -23510,9 +23516,9 @@ const _$ = "_shell_fu72l_1", w$ = "_workspace_fu72l_8", S$ = "_sidebarCollapsed_
|
|
|
23510
23516
|
vA,
|
|
23511
23517
|
{
|
|
23512
23518
|
editorMode: e,
|
|
23513
|
-
isSaving:
|
|
23519
|
+
isSaving: E,
|
|
23514
23520
|
isDirty: L,
|
|
23515
|
-
lastSaved:
|
|
23521
|
+
lastSaved: A,
|
|
23516
23522
|
isFormValid: b,
|
|
23517
23523
|
onToolbarEvent: B
|
|
23518
23524
|
}
|
|
@@ -23592,7 +23598,7 @@ const _$ = "_shell_fu72l_1", w$ = "_workspace_fu72l_8", S$ = "_sidebarCollapsed_
|
|
|
23592
23598
|
onSave: U,
|
|
23593
23599
|
onDiscard: oe,
|
|
23594
23600
|
onCancel: () => m(!1),
|
|
23595
|
-
isSaving:
|
|
23601
|
+
isSaving: E
|
|
23596
23602
|
}
|
|
23597
23603
|
)
|
|
23598
23604
|
] });
|
|
@@ -23692,21 +23698,21 @@ function $$({ config: e, onError: t }) {
|
|
|
23692
23698
|
try {
|
|
23693
23699
|
n(!0), o(null), e.apiBaseUrl && gT(e.apiBaseUrl), l(e), c(e.config.mode), m(Eb(e));
|
|
23694
23700
|
const _ = e.context.contentId ?? e.context.identifier ?? "", T = e.context.channel ?? "";
|
|
23695
|
-
let
|
|
23701
|
+
let E;
|
|
23696
23702
|
if (T)
|
|
23697
23703
|
try {
|
|
23698
|
-
|
|
23704
|
+
E = (v = await tm(T)) == null ? void 0 : v.defaultFramework;
|
|
23699
23705
|
} catch {
|
|
23700
23706
|
}
|
|
23701
23707
|
let L = !1;
|
|
23702
23708
|
if (_) {
|
|
23703
|
-
const
|
|
23704
|
-
let { rootNode: R } =
|
|
23709
|
+
const A = e.config.objectType === "QuestionSet";
|
|
23710
|
+
let { rootNode: R } = A ? await bT(_) : await Nh(_);
|
|
23705
23711
|
if (R && e.config.primaryCategory === "Learning Path" && (R = await IT(R)), !h && (p(R ? [R] : []), R)) {
|
|
23706
23712
|
y(R.id);
|
|
23707
23713
|
const { framework: B, targetFWIds: U } = Vu(
|
|
23708
23714
|
R.metadata ?? {},
|
|
23709
|
-
|
|
23715
|
+
E,
|
|
23710
23716
|
e.context
|
|
23711
23717
|
);
|
|
23712
23718
|
f(B, U), L = !0;
|
|
@@ -23734,12 +23740,12 @@ function $$({ config: e, onError: t }) {
|
|
|
23734
23740
|
}
|
|
23735
23741
|
}
|
|
23736
23742
|
if (!h && !L) {
|
|
23737
|
-
const { framework:
|
|
23743
|
+
const { framework: A, targetFWIds: R } = Vu(
|
|
23738
23744
|
{},
|
|
23739
|
-
|
|
23745
|
+
E,
|
|
23740
23746
|
e.context
|
|
23741
23747
|
);
|
|
23742
|
-
f(
|
|
23748
|
+
f(A, R);
|
|
23743
23749
|
}
|
|
23744
23750
|
h || a(!0);
|
|
23745
23751
|
} catch (_) {
|